yangfeng
2023-07-06 2605e8abbd4d5c8b6fc7086b05b876ed96917bb4
src/views/sales/salesOpportunity/index.vue
@@ -4,9 +4,8 @@
    <div class="btn-pager">
      <PublicFunctionBtnView
        :duplicate-check="true"
        :list-button="true"
        :map-button="true"
        :statistics="true"
        :custom-funnel="true"
        :operates-list="operatesList"
      />
      <PagerView class="page" />
@@ -22,7 +21,7 @@
      </template>
    </TableCommonView>
    <!-- 新建/编辑 -->
    <AddSalesLeadDialog v-if="editSalesLeadConfig.visible" :edit-sales-lead-config="editSalesLeadConfig" />
    <AddSalesOpportunityDialog v-if="editConfig.visible" :edit-common-config="editConfig" />
  </div>
</template>
@@ -31,7 +30,7 @@
import PublicFunctionBtnView from "@/components/makepager/PublicFunctionBtnView"
import PagerView from "@/components/makepager/PagerView"
import TableCommonView from "@/components/makepager/TableCommonView"
import AddSalesLeadDialog from "@/views/custom/salesLead/AddSalesLeadDialog"
import AddSalesOpportunityDialog from "@/views/sales/salesOpportunity/AddSalesOpportunityDialog"
export default {
  name: "SalesOpportunity",
@@ -41,7 +40,7 @@
    PublicFunctionBtnView,
    PagerView,
    TableCommonView,
    AddSalesLeadDialog
    AddSalesOpportunityDialog
  },
  computed: {
    searchCommonHeight() {
@@ -51,7 +50,21 @@
  data() {
    return {
      tableList: {},
      queryClassOptions: [{ value: "1", label: "全部" }],
      queryClassOptions: [
        { value: "1", label: "全部" },
        { value: "2", label: "初期沟通" },
        { value: "3", label: "商务谈判" },
        { value: "4", label: "成功结案" },
        { value: "5", label: "失败结案" },
        { value: "6", label: "本周创建" },
        { value: "7", label: "本月创建" },
        { value: "8", label: "本周预计成交" },
        { value: "9", label: "本月预计成交" },
        { value: "10", label: "在谈商机" },
        { value: "11", label: "项目暂停" },
        { value: "12", label: "15天未联系商机" },
        { value: "13", label: "预计金额1W以上" }
      ],
      searchOptions: [],
      operatesList: [
        { id: "1", name: "共享" },
@@ -61,9 +74,9 @@
        { id: "5", name: "更改创建人" },
        { id: "6", name: "树结构设置" },
        { id: "7", name: "审批设置" },
        { id: "8", name: "恢復" }
        { id: "8", name: "恢复预设列宽" }
      ],
      editSalesLeadConfig: {
      editConfig: {
        visible: false,
        title: "新建",
        infomation: {}
@@ -78,31 +91,29 @@
      this.tableList = {
        tableInfomation: [
          {
            customName: "123123",
            customType: "普通客户",
            salesHead: "系统管理员",
            modifyTime: "2023-0703 11:22:12",
            customerSize: "499以上",
            importantLevel: "A类客户",
            customNumber: "AC651",
            customStatus: "潜在客户",
            productName: "自动打印机",
            startDate: "2023-06-27",
            endDate: "2024-07-15"
            opportunityName: "123123",
            customName: "上海铃铛",
            salesOpportunityNo: "POT205",
            contactName: "刘总",
            saleStage: "初期沟通",
            possible: "A类客户",
            expectDealDate: "50",
            expectContractAmount: "2023-05-28",
            budgetAbsoluteValue: "¥200,000.00",
            salesHead: "系统管理员"
          }
        ],
        tableColumn: [
          { label: "客户名称", prop: "customName", min: 120 }, // 客户名称
          { label: "客户类型", prop: "customType", min: 90 }, // 客户类型
          { label: "销售负责人", prop: "salesHead" }, // 销售负责人
          { label: "修改时间", prop: "modifyTime", min: 100 }, // 修改时间
          { label: "客户规模", prop: "customerSize" }, // 客户规模
          { label: "重要级别", prop: "importantLevel" }, // 重要级别
          { label: "客户编号", prop: "customNumber" }, // 客户编号
          { label: "客户状态", prop: "customStatus" }, // 客户状态
          { label: "产品名称", prop: "productName" }, // 产品名称
          { label: "服务开始日期", prop: "startDate" }, // 服务开始日期
          { label: "服务到期日", prop: "endDate" } // 服务到期日
          { label: "机会名称", prop: "opportunityName", min: 120 }, // 机会名称
          { label: "客户名称", prop: "customName", min: 90 }, // 客户名称
          { label: "销售机会编号", prop: "salesOpportunityNo" }, // 销售机会编号
          { label: "联系人姓名", prop: "contactName", min: 100 }, // 联系人姓名
          { label: "销售阶段", prop: "saleStage" }, // 销售阶段
          { label: "可能性(%)", prop: "possible" }, // 可能性
          { label: "预计成交日期", prop: "expectDealDate" }, // 预计成交日期
          { label: "预计合同金额", prop: "expectContractAmount" }, // 预计合同金额
          { label: "预算绝对值", prop: "budgetAbsoluteValue" }, // 预算绝对值
          { label: "销售负责人", prop: "salesHead" } // 销售负责人
        ]
      }
      this.searchOptions = []
@@ -113,47 +124,85 @@
    },
    // 新建
    addBtnClick() {
      this.editSalesLeadConfig.visible = true
      this.editSalesLeadConfig.title = "新建"
      this.editSalesLeadConfig.infomation = {
      this.editConfig.visible = true
      this.editConfig.title = "新建"
      this.editConfig.infomation = {
        customName: "",
        saleLeadNumber: "LEA50",
        salesOpportunityNo: "POT521",
        opportunityName: "",
        contactName: "",
        contactDuties: "",
        phoneNumber: "",
        businessStatus: "新建",
        businessSource: "1",
        owner: "",
        businessSource: "",
        businessType: "",
        saleStage: "",
        salesHead: "",
        oldCustomerMarket: "",
        competitor: "",
        possible: "",
        currency: "",
        budgetAbsoluteValue: "",
        expectDealDate: "",
        expectContractAmount: "",
        currentState: "",
        demandPainPoint: "",
        projectApproval: "",
        fundBudget: "",
        decisionMaker: "",
        decisionFactors: "",
        decisionFlow: "",
        programme: "",
        advantage: "",
        disadvantage: "",
        opportunity: "",
        threaten: "",
        position: "",
        map: "",
        country: "1",
        province: "1",
        city: "1",
        region: "1",
        address: ""
        notes: ""
      }
    },
    // 编辑
    handleClick(row) {
      console.log(row)
      this.editSalesLeadConfig.visible = true
      this.editSalesLeadConfig.title = "编辑"
      this.editSalesLeadConfig.infomation = {
        customName: row.customName,
        saleLeadNumber: row.saleLeadNumber,
        contactName: row.contactName,
        contactDuties: row.contactDuties,
        phoneNumber: row.phoneNumber,
        businessStatus: "新建",
        businessSource: row.businessSource,
        owner: row.owner,
      this.editConfig.visible = true
      this.editConfig.title = "编辑"
      this.editConfig.infomation = {
        customName: "",
        salesOpportunityNo: "POT521",
        opportunityName: "",
        contactName: "",
        businessSource: "",
        businessType: "",
        saleStage: "",
        salesHead: "",
        oldCustomerMarket: "",
        competitor: "",
        possible: "",
        currency: "",
        budgetAbsoluteValue: "",
        expectDealDate: "",
        expectContractAmount: "",
        currentState: "",
        demandPainPoint: "",
        projectApproval: "",
        fundBudget: "",
        decisionMaker: "",
        decisionFactors: "",
        decisionFlow: "",
        programme: "",
        advantage: "",
        disadvantage: "",
        opportunity: "",
        threaten: "",
        position: "",
        map: "",
        country: "1",
        province: "1",
        city: "1",
        region: "1",
        address: ""
        notes: ""
      }
    }
  }