10 文件已重命名
15个文件已修改
17个文件已添加
4个文件已删除
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 客户管理列表 |
| | | export function getClientList() { |
| | | return request({ |
| | | url: "/api/client/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加客户管理 |
| | | export function getAddClient(data) { |
| | | return request({ |
| | | url: "/api/client/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除客户管理 |
| | | export function getDeleteClient(data) { |
| | | return request({ |
| | | url: "/api/client/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新客户管理 |
| | | export function getUpdateClient(data) { |
| | | return request({ |
| | | url: "/api/client/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| | | |
| | | // 获取客户来源列表 |
| | | export function getClientOrigin() { |
| | | return request({ |
| | | url: "/api/clientOrigin/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | |
| | | // 获取客户状态列表 |
| | | export function getClientStatus() { |
| | | return request({ |
| | | url: "/api/clientStatus/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | |
| | | // 获取客户来源等所有数据 |
| | | export function getAllData() { |
| | | return request({ |
| | | url: "/api/data/getAllData", |
| | | method: "get" |
| | | }) |
| | | } |
| File was renamed from src/api/custom/contacts.js |
| | |
| | | }) |
| | | } |
| | | // 添加联系人 |
| | | export function getAddContact() { |
| | | export function getAddContact(data) { |
| | | return request({ |
| | | url: "/api/contact/add", |
| | | method: "post" |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除联系人 |
| | |
| | | }) |
| | | } |
| | | // 更新联系人 |
| | | export function getUpdateContact() { |
| | | export function getUpdateContact(data) { |
| | | return request({ |
| | | url: "/api/contact/update", |
| | | method: "put" |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| File was renamed from src/api/custom/followupRecords.js |
| | |
| | | }) |
| | | } |
| | | // 添加跟进记录 |
| | | export function getAddFollowRecord() { |
| | | export function getAddFollowRecord(data) { |
| | | return request({ |
| | | url: "/api/followRecord/add", |
| | | method: "post" |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除跟进记录 |
| | |
| | | }) |
| | | } |
| | | // 更新跟进记录 |
| | | export function getUpdateFollowRecord() { |
| | | export function getUpdateFollowRecord(data) { |
| | | return request({ |
| | | url: "/api/followRecord/update", |
| | | method: "put" |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| | |
| | | }) |
| | | } |
| | | // 添加国家 |
| | | export function getAddCountry() { |
| | | export function getAddCountry(data) { |
| | | return request({ |
| | | url: "/api/country/add", |
| | | method: "post" |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除国家 |
| | |
| | | }) |
| | | } |
| | | // 设置国家 |
| | | export function getSetCountry() { |
| | | export function getSetCountry(data) { |
| | | return request({ |
| | | url: "/api/country/set", |
| | | method: "put" |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| | | // 更新国家 |
| | | export function getUpdateCountry() { |
| | | export function getUpdateCountry(data) { |
| | | return request({ |
| | | url: "/api/country/update", |
| | | method: "put" |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| | | |
| | |
| | | }) |
| | | } |
| | | // 添加省份 |
| | | export function getAddProvince() { |
| | | export function getAddProvince(data) { |
| | | return request({ |
| | | url: "/api/province/add", |
| | | method: "post" |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除省份 |
| | |
| | | }) |
| | | } |
| | | // 设置省份 |
| | | export function getSetProvince() { |
| | | export function getSetProvince(data) { |
| | | return request({ |
| | | url: "/api/province/set", |
| | | method: "put" |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| | | // 更新省份 |
| | | export function getUpdateProvince() { |
| | | export function getUpdateProvince(data) { |
| | | return request({ |
| | | url: "/api/province/update", |
| | | method: "put" |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 销售机会列表 |
| | | export function getContractList() { |
| | | return request({ |
| | | url: "/api/contract/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加销售机会 |
| | | export function getAddContract(data) { |
| | | return request({ |
| | | url: "/api/contract/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除销售机会 |
| | | export function getDelContract(data) { |
| | | return request({ |
| | | url: "/api/contract/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新销售机会 |
| | | export function getUpdateContract(data) { |
| | | return request({ |
| | | url: "/api/contract/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 生成计划列表 |
| | | export function getPlanList() { |
| | | return request({ |
| | | url: "/api/plan/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加生成计划 |
| | | export function getAddPlan(data) { |
| | | return request({ |
| | | url: "/api/plan/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除生成计划 |
| | | export function getDelPlan(data) { |
| | | return request({ |
| | | url: "/api/plan/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新生成计划 |
| | | export function getUpdatePlan(data) { |
| | | return request({ |
| | | url: "/api/plan/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 主订单列表 |
| | | export function getMasterOrderList() { |
| | | return request({ |
| | | url: "/api/masterOrder/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加主订单 |
| | | export function getAddMasterOrder(data) { |
| | | return request({ |
| | | url: "/api/masterOrder/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除主订单 |
| | | export function getDelMasterOrder(data) { |
| | | return request({ |
| | | url: "/api/masterOrder/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新主订单 |
| | | export function getUpdateMasterOrder(data) { |
| | | return request({ |
| | | url: "/api/masterOrder/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 报价单列表 |
| | | export function getQuotationList() { |
| | | return request({ |
| | | url: "/api/quotation/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加报价单 |
| | | export function getAddQuotation(data) { |
| | | return request({ |
| | | url: "/api/quotation/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除报价单 |
| | | export function getDelQuotation(data) { |
| | | return request({ |
| | | url: "/api/quotation/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新报价单 |
| | | export function getUpdateQuotation(data) { |
| | | return request({ |
| | | url: "/api/quotation/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 销售退款单列表 |
| | | export function getSalesRefundList() { |
| | | return request({ |
| | | url: "/api/salesRefund/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加销售退款单 |
| | | export function getAddSalesRefund(data) { |
| | | return request({ |
| | | url: "/api/salesRefund/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除销售退款单 |
| | | export function getDelSalesRefund(data) { |
| | | return request({ |
| | | url: "/api/salesRefund/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新销售退款单 |
| | | export function getUpdateSalesRefund(data) { |
| | | return request({ |
| | | url: "/api/salesRefund/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 销售明细列表 |
| | | export function getSalesDetailsList() { |
| | | return request({ |
| | | url: "/api/salesDetails/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加销售明细 |
| | | export function getAddSalesDetails(data) { |
| | | return request({ |
| | | url: "/api/salesDetails/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除销售明细 |
| | | export function getDelSalesDetails(data) { |
| | | return request({ |
| | | url: "/api/salesDetails/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新销售明细 |
| | | export function getUpdateSalesDetails(data) { |
| | | return request({ |
| | | url: "/api/salesDetails/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 销售机会列表 |
| | | export function getSaleChanceList() { |
| | | return request({ |
| | | url: "/api/saleChance/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加销售机会 |
| | | export function getAddSaleChance(data) { |
| | | return request({ |
| | | url: "/api/saleChance/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除销售机会 |
| | | export function getDelSaleChance(data) { |
| | | return request({ |
| | | url: "/api/saleChance/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新销售机会 |
| | | export function getUpdateSaleChance(data) { |
| | | return request({ |
| | | url: "/api/saleChance/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 销售退货单列表 |
| | | export function getSalesReturnList() { |
| | | return request({ |
| | | url: "/api/salesReturn/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加销售退货单 |
| | | export function getAddSalesReturn(data) { |
| | | return request({ |
| | | url: "/api/salesReturn/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除销售退货单 |
| | | export function getDelSalesReturn(data) { |
| | | return request({ |
| | | url: "/api/salesReturn/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新销售退货单 |
| | | export function getUpdateSalesReturn(data) { |
| | | return request({ |
| | | url: "/api/salesReturn/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 销售子单列表 |
| | | export function getSubOrderList() { |
| | | return request({ |
| | | url: "/api/subOrder/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加销售子单 |
| | | export function getAddSubOrder(data) { |
| | | return request({ |
| | | url: "/api/subOrder/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除销售子单 |
| | | export function getDelSubOrder(data) { |
| | | return request({ |
| | | url: "/api/subOrder/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新销售子单 |
| | | export function getUpdateSubOrder(data) { |
| | | return request({ |
| | | url: "/api/subOrder/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 工单管理列表 |
| | | export function getOrderManageList() { |
| | | return request({ |
| | | url: "/api/orderManage/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加工单管理 |
| | | export function getAddOrderManage(data) { |
| | | return request({ |
| | | url: "/api/orderManage/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除工单管理 |
| | | export function getDelOrderManage(data) { |
| | | return request({ |
| | | url: "/api/orderManage/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新工单管理 |
| | | export function getUpdateOrderManage(data) { |
| | | return request({ |
| | | url: "/api/orderManage/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 服务合同列表 |
| | | export function getServiceContractList() { |
| | | return request({ |
| | | url: "/api/serviceContract/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加服务合同 |
| | | export function getAddServiceContract(data) { |
| | | return request({ |
| | | url: "/api/serviceContract/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除服务合同 |
| | | export function getDelServiceContract(data) { |
| | | return request({ |
| | | url: "/api/serviceContract/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新服务合同 |
| | | export function getUpdateServiceContract(data) { |
| | | return request({ |
| | | url: "/api/serviceContract/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 服务收费管理列表 |
| | | export function getServiceFeeManageList() { |
| | | return request({ |
| | | url: "/api/serviceFeeManage/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加服务收费管理 |
| | | export function getAddServiceFeeManage(data) { |
| | | return request({ |
| | | url: "/api/serviceFeeManage/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除服务收费管理 |
| | | export function getDelServiceFeeManage(data) { |
| | | return request({ |
| | | url: "/api/serviceFeeManage/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新服务收费管理 |
| | | export function getUpdateServiceFeeManage(data) { |
| | | return request({ |
| | | url: "/api/serviceFeeManage/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "@/common/untils/request.js" |
| | | |
| | | // 服务回访单列表 |
| | | export function getServiceFollowupList() { |
| | | return request({ |
| | | url: "/api/serviceFollowup/list", |
| | | method: "get" |
| | | }) |
| | | } |
| | | // 添加服务回访单 |
| | | export function getAddServiceFollowup(data) { |
| | | return request({ |
| | | url: "/api/serviceFollowup/add", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 删除服务回访单 |
| | | export function getDelServiceFollowup(data) { |
| | | return request({ |
| | | url: "/api/serviceFollowup/delete", |
| | | method: "delete", |
| | | data |
| | | }) |
| | | } |
| | | // 更新服务回访单 |
| | | export function getUpdateServiceFollowup(data) { |
| | | return request({ |
| | | url: "/api/serviceFollowup/update", |
| | | method: "put", |
| | | data |
| | | }) |
| | | } |
| | |
| | | <i class="el-icon-location"></i> |
| | | <span>客户管理</span> |
| | | </template> |
| | | <el-menu-item index="/custom/salesLead">销售线索</el-menu-item> |
| | | <el-menu-item index="/custom/clientManage">客户管理</el-menu-item> |
| | | <el-menu-item index="/custom/contacts">联系人</el-menu-item> |
| | | <el-menu-item index="/custom/followupRecords">跟进记录</el-menu-item> |
| | | <el-menu-item index="/client/salesLead">销售线索</el-menu-item> |
| | | <el-menu-item index="/client/clientManage">客户管理</el-menu-item> |
| | | <el-menu-item index="/client/contacts">联系人</el-menu-item> |
| | | <el-menu-item index="/client/followupRecords">跟进记录</el-menu-item> |
| | | </el-submenu> |
| | | <el-submenu index="2"> |
| | | <template slot="title"> |
| File was renamed from src/router/custom/index.js |
| | |
| | | // const type from '@/router/deployCode' |
| | | |
| | | const salesLead = (resolve) => require(["@/views/custom/salesLead/index"], resolve) // 销售线索 |
| | | const clientManage = (resolve) => require(["@/views/custom/client/index"], resolve) // 客户管理 |
| | | const contacts = (resolve) => require(["@/views/custom/contacts/index"], resolve) // 联系人 |
| | | const followupRecords = (resolve) => require(["@/views/custom/followupRecords/index"], resolve) // 跟进记录 |
| | | const salesLead = (resolve) => require(["@/views/client/salesLead/index"], resolve) // 销售线索 |
| | | const clientManage = (resolve) => require(["@/views/client/client/index"], resolve) // 客户管理 |
| | | const contacts = (resolve) => require(["@/views/client/contacts/index"], resolve) // 联系人 |
| | | const followupRecords = (resolve) => require(["@/views/client/followupRecords/index"], resolve) // 跟进记录 |
| | | |
| | | const appconfig = [ |
| | | { |
| | | path: "/custom/salesLead", |
| | | path: "/client/salesLead", |
| | | name: "salesLead", |
| | | component: salesLead, |
| | | meta: { |
| | |
| | | } |
| | | }, |
| | | { |
| | | path: "/custom/clientManage", |
| | | path: "/client/clientManage", |
| | | name: "clientManage", |
| | | component: clientManage, |
| | | meta: { |
| | |
| | | } |
| | | }, |
| | | { |
| | | path: "/custom/contacts", |
| | | path: "/client/contacts", |
| | | name: "contacts", |
| | | component: contacts, |
| | | meta: { |
| | |
| | | } |
| | | }, |
| | | { |
| | | path: "/custom/followupRecords", |
| | | path: "/client/followupRecords", |
| | | name: "followupRecords", |
| | | component: followupRecords, |
| | | meta: { |
| | |
| | | import Router from "vue-router" |
| | | // import type from "@/router/deployCode" |
| | | |
| | | import customRouter from "./custom/index.js" |
| | | import clientRouter from "./client/index.js" |
| | | import salesRouter from "./sales/index.js" |
| | | import serviceRouter from "./service/index.js" |
| | | import backgroundConfigRouter from "./backgroundConfig/index.js" |
| | | |
| | | Vue.use(Router) |
| | | const login = (resolve) => require(["@/views/other/login/index"], resolve) |
| | | const custom = (resolve) => require(["@/views/custom/index"], resolve) |
| | | const client = (resolve) => require(["@/views/client/index"], resolve) |
| | | const sales = (resolve) => require(["@/views/sales/index"], resolve) |
| | | const service = (resolve) => require(["@/views/service/index"], resolve) |
| | | const background = (resolve) => require(["@/views/backgroundConfig/index"], resolve) |
| | | |
| | | export const routes = [ |
| | | { |
| | | path: "custom", // 客户管理 |
| | | name: "custom", |
| | | component: custom, |
| | | children: customRouter, |
| | | path: "client", // 客户管理 |
| | | name: "client", |
| | | component: client, |
| | | children: clientRouter, |
| | | meta: { |
| | | title: "客户管理", |
| | | isAllways: true |
| New file |
| | |
| | | <template> |
| | | <div class="add-client-manage"> |
| | | <el-dialog |
| | | :title="editClientManageConfig.title + '客户管理'" |
| | | :visible.sync="editConfig.visible" |
| | | :width="dialogWidth" |
| | | :before-close="handleClose" |
| | | > |
| | | <el-form |
| | | ref="form" |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | size="mini" |
| | | style="height: 60vh; overflow-x: hidden" |
| | | > |
| | | <!-- 信息 --> |
| | | <div class="basic-info"> |
| | | <!-- 基本信息 --> |
| | | <div class="basic-info-title">基本信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户名称" prop="name"> |
| | | <div class="client-name"> |
| | | <el-input v-model="editConfig.infomation.name"></el-input> |
| | | <div class="common-select-btn"><i class="el-icon-house" title="工商查询"></i></div> |
| | | <div class="common-select-btn"><i class="el-icon-search" title="查重"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户编号" prop="number"> |
| | | <el-input v-model="editConfig.infomation.number"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户状态" prop="client_status_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.client_status_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in clientStatusOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="销售负责人" prop="member_id"> |
| | | <el-select |
| | | v-model="editConfig.infomation.member_id" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | > |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户类型" prop="client_type_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.client_type_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in clientTypeOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户来源" prop="client_origin_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.client_origin_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in clientSourceOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn" @click="editDropdownBox"> |
| | | <i class="el-icon-setting"></i> |
| | | </div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="重要级别" prop="client_level_id"> |
| | | <el-select |
| | | v-model="editConfig.infomation.client_level_id" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | > |
| | | <el-option v-for="item in importantLevelOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <!-- <el-col :span="12"> |
| | | <el-form-item label="服务代表" prop="service_member_id"> |
| | | <el-select |
| | | v-model="editConfig.infomation.service_member_id" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | > |
| | | <el-option v-for="item in serviceAgentOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> --> |
| | | <el-col :span="12"> |
| | | <el-form-item label="下次回访日期" prop="next_visit_time"> |
| | | <el-date-picker v-model="editConfig.infomation.next_visit_time" type="date" placeholder="选择日期"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="最晚服务到期日" prop="latest_service_time"> |
| | | <el-date-picker |
| | | v-model="editConfig.infomation.latest_service_time" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 客户首要联系人 --> |
| | | <div class="basic-info-title">客户首要联系人</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人姓名" prop="contact_name"> |
| | | <el-input v-model="editConfig.infomation.contact_name"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人手机" prop="contact_phone"> |
| | | <el-input v-model="editConfig.infomation.contact_phone"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人职务" prop="contact_duties"> |
| | | <el-input v-model="editConfig.infomation.contact_duties"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人微信" prop="contact_wechat"> |
| | | <el-input v-model="editConfig.infomation.contact_wechat"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人Email" prop="contact_email"> |
| | | <el-input v-model="editConfig.infomation.contact_email"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 工商信息 --> |
| | | <div class="basic-info-title">工商信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="所属行业" prop="industry_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.industry_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in industryOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="法定代表人" prop="representative"> |
| | | <el-input v-model="editConfig.infomation.representative"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="注册时间" prop="registration_time"> |
| | | <el-date-picker |
| | | v-model="editConfig.infomation.registration_time" |
| | | type="datetime" |
| | | placeholder="选择日期时间" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="注册资金" prop="registered_capital_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.registered_capital_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option |
| | | v-for="item in registerCapitalOptions" |
| | | :key="item.id" |
| | | :label="item.name" |
| | | :value="item.id" |
| | | > |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="公司性质" prop="enterprise_nature_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.enterprise_nature_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option |
| | | v-for="item in enterpriseNatureOptions" |
| | | :key="item.id" |
| | | :label="item.name" |
| | | :value="item.id" |
| | | > |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户规模" prop="enterprise_scale_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.enterprise_scale_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option |
| | | v-for="item in enterpriseScaleOptions" |
| | | :key="item.id" |
| | | :label="item.name" |
| | | :value="item.id" |
| | | > |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="经营范围" prop="business_scope"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | placeholder="请输入内容" |
| | | v-model="editConfig.infomation.business_scope" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 地址信息 --> |
| | | <div class="basic-info-title">地址信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <!-- <el-col :span="24"> |
| | | <el-form-item label="定位" prop="position"> |
| | | <el-input v-model="editConfig.infomation.position"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="地图" prop="map"> |
| | | <div style="height: 100px"></div> |
| | | </el-form-item> |
| | | </el-col> --> |
| | | <el-col :span="12"> |
| | | <el-form-item label="国家" prop="country_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.country_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in countryOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="省份" prop="province_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.province_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in provinceOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="城市" prop="city_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.city_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in cityOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="区域" prop="region_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.region_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in regionOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="详细地址" prop="detail_address"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | placeholder="请输入内容" |
| | | v-model="editConfig.infomation.detail_address" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 备注信息 --> |
| | | <div class="basic-info-title">备注信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="备注" prop="remark"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | placeholder="请输入内容" |
| | | v-model="editConfig.infomation.remark" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 附件信息 --> |
| | | <!-- <div class="basic-info-title">附件信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="附件" prop=""> |
| | | <template slot="label"> |
| | | <div style="display: flex; float: right"> |
| | | <div style="font-size: 16px"> |
| | | <i class="el-icon-warning-outline" title="最多上传20个附件,最大限制5MB"></i> |
| | | </div> |
| | | <span style="margin-left: 5px">附件</span> |
| | | </div> |
| | | </template> |
| | | <div class="annex-view"> |
| | | <div @click="addAnnexClick"> |
| | | <div style="display: flex; float: right"> |
| | | <div style="font-size: 16px"><i class="el-icon-paperclip"></i></div> |
| | | <span>添加</span> |
| | | </div> |
| | | </div> |
| | | <div class="setFormat" @click="setFormatClick">设置允许上传的文件格式</div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> --> |
| | | <!-- 选择审批流程 --> |
| | | <!-- <div class="basic-info-title">选择审批流程</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="20"> |
| | | <el-form-item label="审批流程" prop="approvalWorkflow"> |
| | | <el-select |
| | | v-model="editConfig.infomation.approvalWorkflow" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="item in approvalWorkflowOptions" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value" |
| | | > |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="20"> |
| | | <el-form-item label="审批步骤" prop="approvalSteps"> |
| | | <el-input v-model="editConfig.infomation.approvalSteps"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="20"> |
| | | <el-form-item label="审批人" prop="approvalPerson"> |
| | | <el-input v-model="editConfig.infomation.approvalPerson"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="20"> |
| | | <el-form-item label="需要加急审批" prop="approvalUrgent"> |
| | | <el-checkbox v-model="editConfig.infomation.approvalUrgent"></el-checkbox> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="20"> |
| | | <el-form-item label="审批意见" prop="approvalOpinion"> |
| | | <el-input v-model="editConfig.infomation.approvalOpinion" type="textarea" :rows="2"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> --> |
| | | </div> |
| | | </el-form> |
| | | |
| | | <div slot="footer" class="dialog-footer"> |
| | | <!-- <el-button type="primary" size="small" @click="editConfig.visible = false">保并提交审批</el-button> --> |
| | | <el-button type="primary" size="small" @click="saveClick('form')">保存</el-button> |
| | | <el-button size="small" @click="editConfig.visible = false">取消</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { getAllData, getAddClient, getUpdateClient } from "@/api/client/client" |
| | | import { dateFormat } from "@/common/config/index" |
| | | export default { |
| | | name: "AddClientManageDialog", |
| | | props: { |
| | | editClientManageConfig: { |
| | | type: Object, |
| | | default: () => { |
| | | return { |
| | | visible: false, |
| | | title: "新建", |
| | | infomation: { |
| | | name: "", |
| | | number: "AC6521", |
| | | client_status_id: "", |
| | | member_id: "5", |
| | | client_type_id: "", |
| | | clientSource: "", |
| | | client_level_id: "", |
| | | service_member_id: "", |
| | | next_visit_time: "", |
| | | latest_service_time: "", |
| | | contact_name: "", |
| | | contact_phone: "", |
| | | contact_duties: "", |
| | | contact_wechat: "1", |
| | | contact_email: "", |
| | | industry_id: "", |
| | | representative: "", |
| | | registration_time: "", |
| | | registered_capital_id: "", |
| | | enterprise_nature_id: "", |
| | | enterprise_scale_id: "", |
| | | business_scope: "", |
| | | country_id: "", |
| | | province_id: "", |
| | | city_id: "", |
| | | region_id: "", |
| | | detail_address: "", |
| | | remark: "" |
| | | } |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | components: {}, |
| | | computed: { |
| | | searchCommonHeight() { |
| | | return this.$refs.searchCommonView.offsetHeight |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | editConfig: this.editClientManageConfig, |
| | | rules: { |
| | | name: [{ required: true, message: "请输入客户名称", trigger: "blur" }], |
| | | client_status_id: [{ required: true, message: "请选择客户状态", trigger: "change" }], |
| | | member_id: [{ required: true, message: "请选择销售负责人", trigger: "change" }], |
| | | approvalOpinion: [{ required: true, message: "请输入审批意见", trigger: "blur" }] |
| | | }, |
| | | memberOptions: [], |
| | | clientStatusOptions: [], // 客户状态 |
| | | clientTypeOptions: [], // 客户类型 |
| | | clientSourceOptions: [], // 客户来源 |
| | | importantLevelOptions: [], // 重要级别 |
| | | // serviceAgentOptions: [], // 服务代表 |
| | | industryOptions: [], // 所属行业 |
| | | registerCapitalOptions: [], // 注册资金 |
| | | enterpriseNatureOptions: [], // 公司性质 |
| | | enterpriseScaleOptions: [], // 客户规模 |
| | | countryOptions: [], // 国家 |
| | | provinceOptions: [], // 省份 |
| | | cityOptions: [], // 城市 |
| | | regionOptions: [], // 区域 |
| | | approvalWorkflowOptions: [] // 审批流程 |
| | | } |
| | | }, |
| | | created() { |
| | | this.getCommonData() |
| | | }, |
| | | methods: { |
| | | getCommonData() { |
| | | getAllData() |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.memberOptions = res.data.member |
| | | this.clientSourceOptions = res.data.client_origin |
| | | this.clientStatusOptions = res.data.client_status |
| | | this.importantLevelOptions = res.data.client_level |
| | | this.clientTypeOptions = res.data.client_type |
| | | this.industryOptions = res.data.industry |
| | | this.registerCapitalOptions = res.data.registered_capital |
| | | this.enterpriseNatureOptions = res.data.enterprise_nature |
| | | this.enterpriseScaleOptions = res.data.enterprise_scale |
| | | this.countryOptions = res.data.country |
| | | this.provinceOptions = res.data.province |
| | | this.cityOptions = res.data.city |
| | | this.regionOptions = res.data.region |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | }, |
| | | handleClose() { |
| | | this.editConfig.visible = false |
| | | }, |
| | | // 保存 |
| | | saveClick(formName) { |
| | | this.$refs[formName].validate((valid) => { |
| | | if (valid) { |
| | | console.log(this.editConfig.infomation) |
| | | const params = this.saveParams() |
| | | console.log(params) |
| | | if (this.editConfig.title === "新建") { |
| | | getAddClient(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | message: "添加成功", |
| | | type: "success" |
| | | }) |
| | | this.$parent.getData() |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | } else { |
| | | getUpdateClient(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | message: "编辑成功", |
| | | type: "success" |
| | | }) |
| | | this.$parent.getData() |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | } |
| | | } else { |
| | | console.log("error submit") |
| | | return false |
| | | } |
| | | }) |
| | | }, |
| | | saveParams() { |
| | | let data = this.editConfig.infomation |
| | | let params = { |
| | | id: this.editConfig.title === "新建" ? 0 : data.id, |
| | | business_scope: data.business_scope, |
| | | city_id: 0, |
| | | client_level_id: data.client_level_id || 0, |
| | | client_origin_id: data.client_origin_id || 0, |
| | | client_status_id: data.client_status_id || 0, |
| | | client_type_id: data.client_type_id || 0, |
| | | contact: { |
| | | birthday: "1970-01-01 08:00:00", |
| | | city_id: 0, |
| | | client_id: 0, |
| | | country_id: 0, |
| | | desc: "string", |
| | | email: data.contact_email || "", |
| | | is_first: true, |
| | | member_id: 0, |
| | | name: data.contact_name || "", |
| | | number: "string", |
| | | phone: data.contact_phone || "", |
| | | position: data.contact_duties || "", |
| | | province_id: 0, |
| | | region_id: 0, |
| | | wechat: data.contact_wechat || "" |
| | | }, |
| | | country_id: 0, |
| | | detail_address: data.detail_address || "", |
| | | enterprise_nature_id: data.enterprise_nature_id || 0, |
| | | enterprise_scale_id: data.enterprise_scale_id || 0, |
| | | industry_id: data.industry_id || 0, |
| | | latest_service_time: dateFormat("YYYY-mm-dd HH:MM:ss", data.latest_service_time) || "", |
| | | member_id: parseInt(data.member_id) || 0, |
| | | name: data.name || "", |
| | | next_visit_time: data.next_visit_time || "", |
| | | number: data.number || "", |
| | | province_id: 0, |
| | | region_id: 0, |
| | | registered_capital_id: data.registered_capital_id || 0, |
| | | registration_time: data.registration_time || "", |
| | | remark: data.remark || "", |
| | | representative: data.representative || "", |
| | | service_member_id: data.service_member_id || 0 |
| | | } |
| | | return params |
| | | }, |
| | | // 添加附件 |
| | | addAnnexClick() {}, |
| | | // 设置允许上传文件格式 |
| | | setFormatClick() {}, |
| | | // 编辑下拉框 |
| | | editDropdownBox() { |
| | | console.log("aaa") |
| | | this.editDropdownConfig.editVisible = true |
| | | this.editDropdownConfig.title = "客户来源" |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <!-- Add "scoped" attribute to limit CSS to this component only --> |
| | | <style lang="scss" scoped> |
| | | .add-client-manage { |
| | | .basic-info { |
| | | .basic-info-title { |
| | | background-color: #f4f8fe; |
| | | padding-left: 10px; |
| | | font-size: 15px; |
| | | font-weight: bold; |
| | | color: #666; |
| | | height: 42px; |
| | | line-height: 42px; |
| | | } |
| | | .basic-info-view { |
| | | margin-top: 10px; |
| | | padding-right: 40px; |
| | | .client-name { |
| | | display: flex; |
| | | .common-select-btn { |
| | | margin-left: 5px; |
| | | font-size: 18px; |
| | | } |
| | | } |
| | | .common-select { |
| | | display: flex; |
| | | .common-select-sel { |
| | | width: 270px; |
| | | } |
| | | .common-select-btn { |
| | | margin-left: 5px; |
| | | font-size: 16px; |
| | | cursor: pointer; |
| | | } |
| | | } |
| | | } |
| | | // .address-view { |
| | | // margin-top: 10px; |
| | | // padding-right: 40px; |
| | | // } |
| | | .annex-view { |
| | | display: flex; |
| | | color: #6166d3; |
| | | .setFormat { |
| | | margin-left: 10px; |
| | | } |
| | | } |
| | | } |
| | | .unflod-collapse { |
| | | display: flex; |
| | | height: 30px; |
| | | justify-content: center; |
| | | align-items: center; |
| | | color: #6166d3; |
| | | } |
| | | .dialog-footer { |
| | | background-color: #f5f5f5; |
| | | height: 55px; |
| | | line-height: 55px; |
| | | } |
| | | } |
| | | </style> |
| File was renamed from src/views/custom/client/index.vue |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import AddClientManageDialog from "@/views/custom/client/AddClientManageDialog" |
| | | import { getClientList } from "@/api/custom/client" |
| | | import AddClientManageDialog from "@/views/client/client/AddClientManageDialog.vue" |
| | | import { getClientList } from "@/api/client/client" |
| | | import { dateFormat } from "@/common/config/index" |
| | | export default { |
| | | name: "CustomManage", |
| | |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "客户名称", prop: "name", min: 100 }, // 客户名称 |
| | | { label: "销售负责人", prop: "service_member_id" }, // 销售负责人 |
| | | { label: "重要级别", prop: "importantLevel" }, // 重要级别 |
| | | { label: "销售负责人", prop: "member_id" }, // 销售负责人 |
| | | { label: "重要级别", prop: "client_level_id" }, // 重要级别 |
| | | { label: "下次回访日期", prop: "next_visit_time", min: 90 }, // 下次回访日期 |
| | | { label: "手机号码", prop: "phoneNumber" }, // 手机号码 |
| | | { label: "详细地址", prop: "detail_address", min: 200 }, // 详细地址 |
| | | { label: "客户状态", prop: "client_status_id" }, // 客户状态 |
| | | { label: "联系人姓名", prop: "contact_name" }, // 联系人姓名 |
| | | { label: "手机", prop: "phone" } // 手机号码 |
| | | { label: "手机号码", prop: "contact_phone" } // 手机号码 |
| | | ] |
| | | } |
| | | this.searchOptions = [] |
| | |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | let contact_name = "" |
| | | let contact_phone = "" |
| | | if (item.contacts.length !== 0) { |
| | | for (let i = 0; i < item.contacts.length; i++) { |
| | | if (item.contacts[i].is_first) { |
| | | contact_name = item.contacts[i].name |
| | | contact_phone = item.contacts[i].phone |
| | | } |
| | | } |
| | | } |
| | | |
| | | return { |
| | | name: item.name, |
| | | service_member_id: item.service_member_id, |
| | | importantLevel: "", |
| | | next_visit_time: dateFormat("YYYY-mm-dd HH:MM", item.next_visit_time), |
| | | phoneNumber: "", |
| | | detail_address: item.detail_address, |
| | | client_status_id: item.client_status_id, |
| | | contact_name: "", |
| | | phone: "" |
| | | ...item, |
| | | next_visit_time: dateFormat("YYYY-mm-dd HH:MM:ss", item.next_visit_time), |
| | | contact_name: contact_name, |
| | | contact_phone: contact_phone |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.infomation = { |
| | | customName: "", |
| | | customNumber: "AC6521", |
| | | customStatus: "", |
| | | salesHead: "5", |
| | | customType: "", |
| | | customSource: "", |
| | | importantLevel: "", |
| | | serviceAgent: "", |
| | | nextFollowupDate: "", |
| | | latestServiceDate: "", |
| | | contactName: "", |
| | | phoneNumber: "", |
| | | duties: "", |
| | | wechat: "1", |
| | | contactsEmail: "", |
| | | industry: "", |
| | | legalPerson: "", |
| | | registerTime: "", |
| | | registerCapital: "", |
| | | companyNature: "", |
| | | customerSize: "", |
| | | operateRange: "", |
| | | position: "", |
| | | map: "", |
| | | country: "1", |
| | | province: "1", |
| | | city: "1", |
| | | region: "1", |
| | | notes: "", |
| | | approvalWorkflow: "", |
| | | approvalSteps: "", |
| | | approvalPerson: "", |
| | | approvalUrgent: "", |
| | | approvalOpinion: "" |
| | | name: "", |
| | | number: "", |
| | | client_status_id: "", |
| | | member_id: "", |
| | | client_type_id: "", |
| | | clientSource: "", |
| | | client_level_id: "", |
| | | service_member_id: "", |
| | | next_visit_time: "", |
| | | latest_service_time: "", |
| | | contact_name: "", |
| | | contact_phone: "", |
| | | contact_duties: "", |
| | | contact_wechat: "", |
| | | contact_email: "", |
| | | industry_id: "", |
| | | representative: "", |
| | | registration_time: "", |
| | | registered_capital_id: "", |
| | | enterprise_nature_id: "", |
| | | enterprise_scale_id: "", |
| | | business_scope: "", |
| | | country: "", |
| | | province: "", |
| | | city: "", |
| | | region: "", |
| | | detail_address: "", |
| | | remark: "" |
| | | } |
| | | }, |
| | | // 编辑 |
| | |
| | | console.log(row) |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "编辑" |
| | | let contactObj = {} |
| | | if (row.contacts.length > 0) { |
| | | row.contacts.forEach((ele) => { |
| | | if (ele.is_first) { |
| | | contactObj = { ...ele } |
| | | } |
| | | }) |
| | | } |
| | | console.log(contactObj) |
| | | this.editConfig.infomation = { |
| | | customName: row.customName, |
| | | customNumber: "AC6521", |
| | | customStatus: "", |
| | | salesHead: row.salesHead, |
| | | customType: "", |
| | | customSource: "", |
| | | importantLevel: "", |
| | | serviceAgent: "", |
| | | nextFollowupDate: row.nextFollowupDate, |
| | | latestServiceDate: "", |
| | | contactName: row.contactName, |
| | | phoneNumber: row.phoneNumber, |
| | | duties: "", |
| | | wechat: "1", |
| | | contactsEmail: "", |
| | | industry: "", |
| | | legalPerson: "", |
| | | registerTime: "", |
| | | registerCapital: "", |
| | | companyNature: "", |
| | | customerSize: "", |
| | | operateRange: "", |
| | | position: "", |
| | | map: "", |
| | | country: "1", |
| | | province: "1", |
| | | city: "1", |
| | | region: "1", |
| | | notes: "", |
| | | approvalWorkflow: "", |
| | | approvalSteps: "", |
| | | approvalPerson: "", |
| | | approvalUrgent: "", |
| | | approvalOpinion: "" |
| | | id: row.id, |
| | | name: row.name, |
| | | number: row.number, |
| | | client_status_id: row.client_status_id, |
| | | member_id: row.member_id, |
| | | client_type_id: row.client_type_id, |
| | | clientSource: row.clientSource, |
| | | client_level_id: row.client_level_id, |
| | | service_member_id: row.service_member_id, |
| | | next_visit_time: row.next_visit_time, |
| | | latest_service_time: row.latest_service_time, |
| | | contact_name: row.contact_name, |
| | | contact_phone: row.contact_phone, |
| | | contact_duties: "", |
| | | contact_wechat: contactObj.length > 0 ? contactObj.wechat : "", |
| | | contact_email: contactObj.length > 0 ? contactObj.email : "", |
| | | industry_id: row.industry_id, |
| | | representative: row.representative, |
| | | registration_time: row.registration_time, |
| | | registered_capital_id: row.registered_capital_id, |
| | | enterprise_nature_id: row.enterprise_nature_id, |
| | | enterprise_scale_id: row.enterprise_scale_id, |
| | | business_scope: row.business_scope, |
| | | country: row.country, |
| | | province: row.province, |
| | | city: row.city, |
| | | region: row.region, |
| | | detail_address: row.detail_address, |
| | | remark: row.remark |
| | | } |
| | | } |
| | | } |
| New file |
| | |
| | | <template> |
| | | <div class="add-contacts"> |
| | | <el-dialog |
| | | :title="editContactsConfig.title + '联系人'" |
| | | :visible.sync="editConfig.visible" |
| | | :width="dialogWidth" |
| | | :before-close="handleClose" |
| | | > |
| | | <el-form |
| | | ref="form" |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | size="mini" |
| | | > |
| | | <!-- 信息 --> |
| | | <div class="basic-info"> |
| | | <!-- 基本信息 --> |
| | | <div v-if="isUnflod" class="basic-info-title">基本信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人姓名" prop="name"> |
| | | <el-input v-model="editConfig.infomation.name"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12" v-if="isUnflod"> |
| | | <el-form-item label="联系人编号" prop="number"> |
| | | <el-input v-model="editConfig.infomation.number"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户名称" prop="client_id"> |
| | | <div class="custom-name"> |
| | | <el-input v-model="editConfig.infomation.client_id"></el-input> |
| | | <div class="common-select-btn"> |
| | | <i class="el-icon-circle-plus-outline"></i> |
| | | </div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="手机" prop="phone"> |
| | | <el-input v-model="editConfig.infomation.phone"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="职务" prop="position"> |
| | | <el-input v-model="editConfig.infomation.position"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item v-if="isUnflod" label="销售负责人" prop="member_id"> |
| | | <el-select v-model="editConfig.infomation.member_id" placeholder="请选择" size="mini"> |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item v-if="isUnflod" label="首要联系人" prop="is_first"> |
| | | <el-switch v-model="editConfig.infomation.is_first" active-color="#2E68DB" inactive-color="#AEB9CA"> |
| | | </el-switch> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item v-if="isUnflod" label="微信号" prop="wechat"> |
| | | <el-input v-model="editConfig.infomation.wechat"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item v-if="isUnflod" label="生日" prop="birthday"> |
| | | <el-date-picker v-model="editConfig.infomation.birthday" type="date" placeholder="选择日期"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人Email" prop="email"> |
| | | <el-input v-model="editConfig.infomation.email"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 地址信息 --> |
| | | <div v-if="isUnflod" class="basic-info-title">地址信息</div> |
| | | <div v-if="isUnflod" class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="国家" prop="country_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.country_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in countryOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="省份" prop="province_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.province_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in provinceOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="城市" prop="city_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.city_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in cityOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="区域" prop="region_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.region_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in regionOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <!-- <el-col :span="12"> |
| | | <el-form-item label="邮编" prop="postalCode"> |
| | | <el-input v-model="editConfig.infomation.postalCode"></el-input> |
| | | </el-form-item> |
| | | </el-col> --> |
| | | </el-row> |
| | | </div> |
| | | <!-- 备注信息 --> |
| | | <div v-if="isUnflod" class="basic-info-title">备注信息</div> |
| | | <div v-if="isUnflod" class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="备注" prop="notes"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | placeholder="请输入内容" |
| | | v-model="editConfig.infomation.notes" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 附件信息 --> |
| | | <!-- <div v-if="isUnflod" class="basic-info-title">附件信息</div> |
| | | <div v-if="isUnflod" class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="附件" prop=""> |
| | | <template slot="label"> |
| | | <div style="display: flex; float: right"> |
| | | <div style="font-size: 16px"> |
| | | <i class="el-icon-warning-outline" title="最多上传20个附件,最大限制5MB"></i> |
| | | </div> |
| | | <span style="margin-left: 5px">附件</span> |
| | | </div> |
| | | </template> |
| | | <div class="annex-view"> |
| | | <div @click="addAnnexClick"> |
| | | <div style="display: flex; float: right"> |
| | | <div style="font-size: 16px"><i class="el-icon-paperclip"></i></div> |
| | | <span>添加</span> |
| | | </div> |
| | | </div> |
| | | <div class="setFormat" @click="setFormatClick">设置允许上传的文件格式</div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> --> |
| | | </div> |
| | | <!-- 展开收起 --> |
| | | <div v-if="editConfig.title === '新建'" class="unflod-collapse" @click="unflodCollapseClick"> |
| | | <div>{{ unflodCollapseStr }}</div> |
| | | <div v-if="isUnflod"><i class="el-icon-arrow-up"></i></div> |
| | | <div v-else><i class="el-icon-arrow-down"></i></div> |
| | | </div> |
| | | </el-form> |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" size="small" @click="saveClick('form')">保 存</el-button> |
| | | <el-button size="small" @click="editConfig.visible = false">取 消</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { getAddContact, getUpdateContact } from "@/api/client/contacts" |
| | | import { getAllData } from "@/api/client/client" |
| | | export default { |
| | | name: "AddContactsDialog", |
| | | props: { |
| | | editContactsConfig: { |
| | | type: Object, |
| | | default: () => { |
| | | return { |
| | | visible: false, |
| | | title: "新建", |
| | | infomation: { |
| | | name: "", |
| | | number: "LEA50", |
| | | client_id: "", |
| | | phone: "", |
| | | position: "", |
| | | member_id: "5", |
| | | is_first: false, |
| | | wechat: "1", |
| | | birthday: "", |
| | | email: "", |
| | | nextFollowupDate: "", |
| | | country_id: "", |
| | | province_id: "", |
| | | city_id: "", |
| | | region_id: "", |
| | | postalCode: "", |
| | | notes: "" |
| | | } |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | components: {}, |
| | | computed: {}, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | editConfig: this.editContactsConfig, |
| | | rules: { |
| | | name: [{ required: true, message: "请输入", trigger: "blur" }], |
| | | number: [{ required: true, message: "请输入", trigger: "blur" }], |
| | | member_id: [{ required: true, message: "请选择", trigger: "change" }] |
| | | }, |
| | | businessSourceOptions: [ |
| | | { value: "1", label: "后台注册" }, |
| | | { value: "2", label: "代理商客户" }, |
| | | { value: "3", label: "电话陌生拜访" }, |
| | | { value: "4", label: "直接访问" }, |
| | | { value: "5", label: "项目合作" }, |
| | | { value: "6", label: "个人自找" }, |
| | | { value: "7", label: "二次销售" }, |
| | | { value: "8", label: "公司电话" } |
| | | ], |
| | | memberOptions: [], |
| | | countryOptions: [], // 国家 |
| | | provinceOptions: [], // 省份 |
| | | cityOptions: [], // 城市 |
| | | regionOptions: [], // 区域 |
| | | unflodCollapseStr: "收起", |
| | | isUnflod: true |
| | | } |
| | | }, |
| | | created() { |
| | | this.getCommonData() |
| | | }, |
| | | methods: { |
| | | getCommonData() { |
| | | getAllData() |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.memberOptions = res.data.member |
| | | this.countryOptions = res.data.country |
| | | this.provinceOptions = res.data.province |
| | | this.cityOptions = res.data.city |
| | | this.regionOptions = res.data.region |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | }, |
| | | handleClose() { |
| | | this.editConfig.visible = false |
| | | }, |
| | | // 保存 |
| | | saveClick(formName) { |
| | | this.$refs[formName].validate((valid) => { |
| | | if (valid) { |
| | | console.log(this.editConfig.infomation) |
| | | const params = this.saveParams() |
| | | console.log(params) |
| | | if (this.editConfig.title === "新建") { |
| | | getAddContact(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | message: "添加成功", |
| | | type: "success" |
| | | }) |
| | | this.$parent.getData() |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | } else { |
| | | getUpdateContact(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | message: "编辑成功", |
| | | type: "success" |
| | | }) |
| | | this.$parent.getData() |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | } |
| | | } else { |
| | | console.log("error submit") |
| | | return false |
| | | } |
| | | }) |
| | | }, |
| | | saveParams() { |
| | | let data = this.editConfig.infomation |
| | | let params = { |
| | | birthday: data.birthday || "", |
| | | city_id: data.city_id || 0, |
| | | client_id: 0, |
| | | country_id: data.country_id || 0, |
| | | desc: data.desc || "", |
| | | email: data.email || "", |
| | | is_first: data.is_first || false, |
| | | member_id: data.member_id || 0, |
| | | name: data.name || "", |
| | | number: data.number || "", |
| | | phone: data.phone || "", |
| | | position: data.position || "", |
| | | province_id: data.province_id || 0, |
| | | region_id: data.region_id || 0, |
| | | wechat: data.wechat || "" |
| | | } |
| | | return params |
| | | }, |
| | | // 添加附件 |
| | | addAnnexClick() {}, |
| | | // 设置允许上传文件格式 |
| | | setFormatClick() {}, |
| | | // 展开收起 |
| | | unflodCollapseClick() { |
| | | if (this.unflodCollapseStr === "收起") { |
| | | this.unflodCollapseStr = "展开更多栏目" |
| | | this.isUnflod = false |
| | | } else { |
| | | this.unflodCollapseStr = "收起" |
| | | this.isUnflod = true |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <!-- Add "scoped" attribute to limit CSS to this component only --> |
| | | <style lang="scss" scoped> |
| | | .add-contacts { |
| | | .basic-info { |
| | | .basic-info-title { |
| | | background-color: #f4f8fe; |
| | | padding-left: 10px; |
| | | font-size: 15px; |
| | | font-weight: bold; |
| | | color: #666; |
| | | height: 42px; |
| | | line-height: 42px; |
| | | } |
| | | .basic-info-view { |
| | | margin-top: 10px; |
| | | padding-right: 40px; |
| | | .custom-name { |
| | | display: flex; |
| | | .common-select-btn { |
| | | margin-left: 5px; |
| | | font-size: 16px; |
| | | } |
| | | } |
| | | .common-select { |
| | | display: flex; |
| | | .common-select-sel { |
| | | width: 270px; |
| | | } |
| | | .common-select-btn { |
| | | margin-left: 5px; |
| | | font-size: 16px; |
| | | cursor: pointer; |
| | | } |
| | | } |
| | | } |
| | | .annex-view { |
| | | display: flex; |
| | | color: #6166d3; |
| | | .setFormat { |
| | | margin-left: 10px; |
| | | } |
| | | } |
| | | } |
| | | .unflod-collapse { |
| | | display: flex; |
| | | height: 30px; |
| | | justify-content: center; |
| | | align-items: center; |
| | | color: #6166d3; |
| | | } |
| | | .dialog-footer { |
| | | background-color: #f5f5f5; |
| | | height: 55px; |
| | | line-height: 55px; |
| | | } |
| | | } |
| | | </style> |
| File was renamed from src/views/custom/contacts/index.vue |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import AddContactsDialog from "@/views/custom/contacts/AddContactsDialog" |
| | | import { getContactList } from "@/api/custom/contacts" |
| | | import AddContactsDialog from "@/views/client/contacts/AddContactsDialog" |
| | | import { getContactList } from "@/api/client/contacts" |
| | | export default { |
| | | name: "ContactsView", |
| | | props: {}, |
| | |
| | | this.tableList = { |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "联系人姓名", prop: "contactName", min: 100 }, // 联系人姓名 |
| | | { label: "联系人姓名", prop: "name", min: 100 }, // 联系人姓名 |
| | | { label: "客户名称", prop: "client_name", min: 190 }, // 客户名称 |
| | | { label: "联系人编号", prop: "number", min: 100 }, // 联系人编号 |
| | | { label: "职务", prop: "duties", min: 120 }, // 职务 |
| | | { label: "职务", prop: "position", min: 120 }, // 职务 |
| | | { label: "手机", prop: "phone", min: 100 }, // 手机号码 |
| | | { label: "销售负责人", prop: "salesHead", min: 120 }, // 销售负责人 |
| | | { label: "首要联系人", prop: "name", min: 90 } // 首要联系人 |
| | | { label: "销售负责人", prop: "member_id", min: 120 }, // 销售负责人 |
| | | { label: "首要联系人", prop: "is_first", min: 90 } // 首要联系人 |
| | | ] |
| | | } |
| | | this.searchOptions = [] |
| | |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | contactName: "", |
| | | ...item, |
| | | client_name: item.Client.name, |
| | | number: item.number, |
| | | duties: "", |
| | | phone: item.phone, |
| | | salesHead: "", |
| | | name: item.name |
| | | is_first: item.is_first ? "是" : "否" |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| New file |
| | |
| | | <template> |
| | | <div class="add-followup-records"> |
| | | <el-dialog |
| | | :title="editContactsConfig.title + '跟进记录'" |
| | | :visible.sync="editConfig.visible" |
| | | :width="dialogWidth" |
| | | :before-close="handleClose" |
| | | > |
| | | <el-form |
| | | ref="form" |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | size="mini" |
| | | > |
| | | <!-- 信息 --> |
| | | <div class="basic-info"> |
| | | <!-- 基本信息 --> |
| | | <div v-if="isUnflod" class="basic-info-title">基本信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="客户名称" prop="client_id"> |
| | | <div class="custom-name"> |
| | | <el-input v-model="editConfig.infomation.client_id"></el-input> |
| | | <div class="common-select-btn"><i class="el-icon-circle-plus-outline"></i></div> |
| | | <div class="common-select-btn"><i class="el-icon-edit-outline"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12" v-if="isUnflod"> |
| | | <el-form-item label="跟进记录编号" prop="number"> |
| | | <el-input v-model="editConfig.infomation.number"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col v-if="isUnflod" :span="12"> |
| | | <el-form-item label="客户状态" prop="client_status_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.client_status_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in clientStatusOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系人姓名" prop="contact_id"> |
| | | <div class="custom-name"> |
| | | <el-input v-model="editConfig.infomation.contact_id"></el-input> |
| | | <div class="common-select-btn"><i class="el-icon-circle-plus-outline"></i></div> |
| | | <div class="common-select-btn"><i class="el-icon-edit-outline"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item v-if="isUnflod" label="负责人" prop="member_id"> |
| | | <el-select v-model="editConfig.infomation.member_id" placeholder="请选择" size="mini"> |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="主题" prop="topic"> |
| | | <el-input v-model="editConfig.infomation.topic"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="isUnflod ? 24 : 12"> |
| | | <el-form-item label="跟进记录" prop="record"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | v-model="editConfig.infomation.record" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系方式" prop="phoneNumber"> |
| | | <el-input v-model="editConfig.infomation.phoneNumber"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col v-if="isUnflod" :span="12"> |
| | | <el-form-item label="销售机会" prop="sale_chance_id"> |
| | | <div class="custom-name"> |
| | | <el-input v-model="editConfig.infomation.sale_chance_id"></el-input> |
| | | <div class="common-select-btn"><i class="el-icon-circle-plus-outline"></i></div> |
| | | <div class="common-select-btn"><i class="el-icon-edit-outline"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="销售线索" prop="sales_leads_id"> |
| | | <div class="custom-name"> |
| | | <el-input v-model="editConfig.infomation.sales_leads_id"></el-input> |
| | | <div class="common-select-btn"><i class="el-icon-circle-plus-outline"></i></div> |
| | | <div class="common-select-btn"><i class="el-icon-edit-outline"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="联系日期" prop="follow_time"> |
| | | <el-date-picker v-model="editConfig.infomation.follow_time" type="date" placeholder="选择日期"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="下次回访日期" prop="next_follow_time"> |
| | | <el-date-picker v-model="editConfig.infomation.next_follow_time" type="date" placeholder="选择日期"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 备注信息 --> |
| | | <div v-if="isUnflod" class="basic-info-title">备注信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="拜访目的" prop="purpose"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | v-model="editConfig.infomation.purpose" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="内容" prop="content"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | v-model="editConfig.infomation.content" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <!-- 附件信息 --> |
| | | <!-- <div v-if="isUnflod" class="basic-info-title">附件信息</div> |
| | | <div v-if="isUnflod" class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="附件" prop=""> |
| | | <template slot="label"> |
| | | <div style="display: flex; float: right"> |
| | | <div style="font-size: 16px"> |
| | | <i class="el-icon-warning-outline" title="最多上传20个附件,最大限制5MB"></i> |
| | | </div> |
| | | <span style="margin-left: 5px">附件</span> |
| | | </div> |
| | | </template> |
| | | <div class="annex-view"> |
| | | <div @click="addAnnexClick"> |
| | | <div style="display: flex; float: right"> |
| | | <div style="font-size: 16px"><i class="el-icon-paperclip"></i></div> |
| | | <span>添加</span> |
| | | </div> |
| | | </div> |
| | | <div class="setFormat" @click="setFormatClick">设置允许上传的文件格式</div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </div> --> |
| | | </div> |
| | | <!-- 展开收起 --> |
| | | <div v-if="editConfig.title === '新建'" class="unflod-collapse" @click="unflodCollapseClick"> |
| | | <div>{{ unflodCollapseStr }}</div> |
| | | <div v-if="isUnflod"><i class="el-icon-arrow-up"></i></div> |
| | | <div v-else><i class="el-icon-arrow-down"></i></div> |
| | | </div> |
| | | </el-form> |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" size="small" @click="saveClick('form')">保 存</el-button> |
| | | <el-button size="small" @click="editConfig.visible = false">取 消</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { getAllData } from "@/api/client/client" |
| | | import { getAddFollowRecord, getUpdateFollowRecord } from "@/api/client/followupRecords" |
| | | export default { |
| | | name: "AddFollowupRecordsDialog", |
| | | props: { |
| | | editContactsConfig: { |
| | | type: Object, |
| | | default: () => { |
| | | return { |
| | | visible: false, |
| | | title: "新建", |
| | | infomation: { |
| | | client_id: "", |
| | | number: "", |
| | | client_status_id: "", |
| | | contact_id: "", |
| | | member_id: "", |
| | | topic: "", |
| | | record: "", |
| | | phoneNumber: "", |
| | | sale_chance_id: "", |
| | | sales_leads_id: "", |
| | | follow_time: "", |
| | | next_follow_time: "", |
| | | purpose: "", |
| | | content: "" |
| | | } |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | components: {}, |
| | | computed: { |
| | | searchCommonHeight() { |
| | | return this.$refs.searchCommonView.offsetHeight |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | editConfig: this.editContactsConfig, |
| | | rules: { |
| | | number: [{ required: true, message: "请输入跟进记录编号", trigger: "blur" }], |
| | | member_id: [{ required: true, message: "请选择负责人", trigger: "change" }], |
| | | record: [{ required: true, message: "请输入跟进记录", trigger: "blur" }] |
| | | }, |
| | | clientStatusOptions: [], // 客户状态 |
| | | memberOptions: [], |
| | | unflodCollapseStr: "收起", |
| | | isUnflod: true |
| | | } |
| | | }, |
| | | created() { |
| | | this.getCommonData() |
| | | }, |
| | | methods: { |
| | | getCommonData() { |
| | | getAllData() |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.clientStatusOptions = res.data.client_status |
| | | this.memberOptions = res.data.member |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | }, |
| | | handleClose() { |
| | | this.editConfig.visible = false |
| | | }, |
| | | // 保存 |
| | | saveClick(formName) { |
| | | this.$refs[formName].validate((valid) => { |
| | | if (valid) { |
| | | console.log(this.editConfig.infomation) |
| | | const params = this.saveParams() |
| | | console.log(params) |
| | | if (this.editConfig.title === "新建") { |
| | | getAddFollowRecord(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | message: "添加成功", |
| | | type: "success" |
| | | }) |
| | | this.$parent.getData() |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | } else { |
| | | getUpdateFollowRecord(params) |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.editConfig.visible = false |
| | | if (res.code === 200) { |
| | | this.$message({ |
| | | message: "编辑成功", |
| | | type: "success" |
| | | }) |
| | | this.$parent.getData() |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | }) |
| | | } |
| | | } else { |
| | | console.log("error submit") |
| | | return false |
| | | } |
| | | }) |
| | | }, |
| | | saveParams() { |
| | | let data = this.editConfig.infomation |
| | | let params = { |
| | | id: this.editConfig.title === "新建" ? 0 : data.id, |
| | | follow_record: { |
| | | client_id: data.client_id || 0, |
| | | client_status_id: data.client_status_id || 0, |
| | | contact_id: data.contact_id || 0, |
| | | contact_information_id: data.contact_information_id || 0, |
| | | content: data.content || "", |
| | | follow_time: data.follow_time || "", |
| | | member_id: data.member_id || 0, |
| | | next_follow_time: data.next_follow_time || "", |
| | | number: data.number || "", |
| | | purpose: data.purpose || "", |
| | | record: data.record || "", |
| | | sale_chance_id: data.sale_chance_id || 0, |
| | | sales_leads_id: data.sales_leads_id || 0, |
| | | topic: data.topic || "" |
| | | } |
| | | } |
| | | return params |
| | | }, |
| | | // 添加附件 |
| | | addAnnexClick() {}, |
| | | // 设置允许上传文件格式 |
| | | setFormatClick() {}, |
| | | // 展开收起 |
| | | unflodCollapseClick() { |
| | | if (this.unflodCollapseStr === "收起") { |
| | | this.unflodCollapseStr = "展开更多栏目" |
| | | this.isUnflod = false |
| | | } else { |
| | | this.unflodCollapseStr = "收起" |
| | | this.isUnflod = true |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <!-- Add "scoped" attribute to limit CSS to this component only --> |
| | | <style lang="scss" scoped> |
| | | .add-followup-records { |
| | | .basic-info { |
| | | .basic-info-title { |
| | | background-color: #f4f8fe; |
| | | padding-left: 10px; |
| | | font-size: 15px; |
| | | font-weight: bold; |
| | | color: #666; |
| | | height: 42px; |
| | | line-height: 42px; |
| | | } |
| | | .basic-info-view { |
| | | margin-top: 10px; |
| | | padding-right: 40px; |
| | | .custom-name { |
| | | display: flex; |
| | | .common-select-btn { |
| | | margin-left: 5px; |
| | | font-size: 16px; |
| | | } |
| | | } |
| | | .common-select { |
| | | display: flex; |
| | | .common-select-sel { |
| | | width: 270px; |
| | | } |
| | | .common-select-btn { |
| | | margin-left: 5px; |
| | | font-size: 16px; |
| | | cursor: pointer; |
| | | } |
| | | } |
| | | } |
| | | .address-view { |
| | | margin-top: 10px; |
| | | padding-right: 40px; |
| | | } |
| | | .annex-view { |
| | | display: flex; |
| | | color: #6166d3; |
| | | .setFormat { |
| | | margin-left: 10px; |
| | | } |
| | | } |
| | | } |
| | | .unflod-collapse { |
| | | display: flex; |
| | | height: 30px; |
| | | justify-content: center; |
| | | align-items: center; |
| | | color: #6166d3; |
| | | } |
| | | .dialog-footer { |
| | | background-color: #f5f5f5; |
| | | height: 55px; |
| | | line-height: 55px; |
| | | } |
| | | } |
| | | </style> |
| File was renamed from src/views/custom/followupRecords/index.vue |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import AddFollowupRecordsDialog from "@/views/custom/followupRecords/AddFollowupRecordsDialog" |
| | | import { getFollowRecordList } from "@/api/custom/followupRecords.js" |
| | | import AddFollowupRecordsDialog from "@/views/client/followupRecords/AddFollowupRecordsDialog" |
| | | import { getFollowRecordList } from "@/api/client/followupRecords.js" |
| | | import { dateFormat } from "@/common/config/index" |
| | | |
| | | export default { |
| | |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | topic: item.topic, |
| | | ...item, |
| | | client_name: item.client.name, |
| | | contact_name: item.contact.name, |
| | | client_status_id: item.client.client_status_id, |
| | | phone: item.contact.phone, |
| | | follow_time: dateFormat("YYYY-mm-dd HH:MM", item.follow_time), |
| | | next_follow_time: dateFormat("YYYY-mm-dd HH:MM", item.next_follow_time), |
| | | member_id: item.member_id, |
| | | record: item.record |
| | | next_follow_time: dateFormat("YYYY-mm-dd HH:MM", item.next_follow_time) |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.infomation = { |
| | | customName: "", |
| | | followupRecordsNumber: "LEA50", |
| | | customStatus: "", |
| | | contactName: "", |
| | | owner: "", |
| | | theme: "", |
| | | followupRecords: "", |
| | | client_id: "", |
| | | number: "", |
| | | client_status_id: "", |
| | | contact_id: "", |
| | | member_id: "", |
| | | topic: "", |
| | | record: "", |
| | | phoneNumber: "", |
| | | salesOpportunity: "", |
| | | salesClue: "", |
| | | contactDate: "", |
| | | nextFollowupDate: "", |
| | | visitPurpose: "", |
| | | sale_chance_id: "", |
| | | sales_leads_id: "", |
| | | follow_time: "", |
| | | next_follow_time: "", |
| | | purpose: "", |
| | | content: "" |
| | | } |
| | | }, |
| | |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "编辑" |
| | | this.editConfig.infomation = { |
| | | customName: row.customName, |
| | | followupRecordsNumber: "LEA50", |
| | | customStatus: row.customStatus, |
| | | contactName: row.contactName, |
| | | owner: row.owner, |
| | | theme: row.theme, |
| | | followupRecords: row.followupRecords, |
| | | phoneNumber: row.phoneNumber, |
| | | salesOpportunity: "", |
| | | salesClue: "", |
| | | contactDate: row.contactDate, |
| | | nextFollowupDate: row.nextFollowupDate, |
| | | visitPurpose: "", |
| | | content: "" |
| | | id: row.id, |
| | | client_id: row.client_id, |
| | | number: row.number, |
| | | client_status_id: row.client_status_id, |
| | | contact_id: row.contact_id, |
| | | member_id: row.member_id, |
| | | topic: row.topic, |
| | | record: row.record, |
| | | phoneNumber: "", |
| | | sale_chance_id: row.sale_chance_id, |
| | | sales_leads_id: row.sales_leads_id, |
| | | follow_time: row.follow_time, |
| | | next_follow_time: row.next_follow_time, |
| | | purpose: row.purpose, |
| | | content: row.content |
| | | } |
| | | } |
| | | } |
| File was renamed from src/views/custom/salesLead/AddSalesLeadDialog.vue |
| | |
| | | <el-col :span="12"> |
| | | <el-form-item label="负责人" prop="member_id"> |
| | | <el-select v-model="editConfig.infomation.member_id" placeholder="请选择" size="mini"> |
| | | <el-option v-for="item in ownerOptions" :key="item.value" :label="item.label" :value="item.value"> |
| | | <el-option v-for="item in ownerOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | |
| | | </el-row> --> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="国家" prop="country"> |
| | | <CommonSelectView :common-value="editConfig.infomation.country" :common-options="countryOptions" /> |
| | | <el-form-item label="国家" prop="country_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.country_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in countryOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="省份" prop="province"> |
| | | <CommonSelectView :common-value="editConfig.infomation.province" :common-options="provinceOptions" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="城市" prop="city"> |
| | | <CommonSelectView :common-value="editConfig.infomation.city" :common-options="cityOptions" /> |
| | | <el-form-item label="省份" prop="province_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.province_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in provinceOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="区域" prop="region"> |
| | | <CommonSelectView :common-value="editConfig.infomation.region" :common-options="regionOptions" /> |
| | | <el-form-item label="城市" prop="city_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.city_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in cityOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="区域" prop="region_id"> |
| | | <div class="common-select"> |
| | | <el-select |
| | | v-model="editConfig.infomation.region_id" |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | > |
| | | <el-option v-for="item in regionOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | <div class="common-select-btn"><i class="el-icon-setting"></i></div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import CommonSelectView from "@/components/makepager/CommonSelectView" |
| | | import EditDropdownDialog from "@/views/other/commonDialog/EditDropdownDialog" |
| | | import { getSalesSourcesList, getAddSalesLeads, getUpdateSalesLeads } from "@/api/custom/salesLead" |
| | | import { getAddSalesLeads, getUpdateSalesLeads } from "@/api/client/salesLead" |
| | | import { getAllData } from "@/api/client/client" |
| | | |
| | | export default { |
| | | name: "AddSalesLeadDialog", |
| | |
| | | businessStatus: "", |
| | | sales_sources_id: "", |
| | | member_id: "", |
| | | country: "", |
| | | province: "", |
| | | city: "", |
| | | region: "", |
| | | country_id: "", |
| | | province_id: "", |
| | | city_id: "", |
| | | region_id: "", |
| | | address: "", |
| | | desc: "", |
| | | id: "" |
| | |
| | | } |
| | | } |
| | | }, |
| | | components: { CommonSelectView, EditDropdownDialog }, |
| | | components: { EditDropdownDialog }, |
| | | computed: { |
| | | searchCommonHeight() { |
| | | return this.$refs.searchCommonView.offsetHeight |
| | |
| | | businessStatus: [{ required: true, message: "请输入商机状态", trigger: "blur" }], |
| | | sales_sources_id: [{ required: true, message: "请选择商机来源", trigger: "change" }] |
| | | }, |
| | | businessSourceOptions: [ |
| | | { id: "1", name: "后台注册" }, |
| | | { id: "2", name: "代理商客户" }, |
| | | { id: "3", name: "电话陌生拜访" }, |
| | | { id: "4", name: "直接访问" }, |
| | | { id: "5", name: "项目合作" }, |
| | | { id: "6", name: "个人自找" }, |
| | | { id: "7", name: "二次销售" }, |
| | | { id: "8", name: "公司电话" } |
| | | ], |
| | | businessSourceOptions: [], |
| | | ownerOptions: [ |
| | | { value: "1", label: "BOSS" }, |
| | | { value: "2", label: "Mia" }, |
| | |
| | | { value: "6", label: "销售" }, |
| | | { value: "7", label: "销售总监" } |
| | | ], |
| | | countryOptions: [{ value: "1", label: "中国" }], // 国家 |
| | | provinceOptions: [ |
| | | { value: "1", label: "北京市" }, |
| | | { value: "2", label: "上海市" }, |
| | | { value: "3", label: "吉林省" }, |
| | | { value: "4", label: "陕西省" } |
| | | ], // 省份 |
| | | cityOptions: [ |
| | | { value: "1", label: "北京市" }, |
| | | { value: "2", label: "上海市" }, |
| | | { value: "3", label: "吉林市" }, |
| | | { value: "4", label: "西安市" } |
| | | ], // 城市 |
| | | regionOptions: [ |
| | | { value: "1", label: "朝阳区" }, |
| | | { value: "2", label: "海淀区" }, |
| | | { value: "3", label: "通州区" }, |
| | | { value: "4", label: "西城区" } |
| | | ], // 区域 |
| | | countryOptions: [], // 国家 |
| | | provinceOptions: [], // 省份 |
| | | cityOptions: [], // 城市 |
| | | regionOptions: [], // 区域 |
| | | unflodCollapseStr: "收起", |
| | | isUnflod: true, |
| | | editDropdownConfig: { |
| | |
| | | }, |
| | | methods: { |
| | | getCommonData() { |
| | | getSalesSourcesList() |
| | | getAllData() |
| | | .then((res) => { |
| | | console.log(res) |
| | | this.businessSourceOptions = res.data.list |
| | | this.businessSourceOptions = res.data.sales_source |
| | | this.countryOptions = res.data.country |
| | | this.provinceOptions = res.data.province |
| | | this.cityOptions = res.data.city |
| | | this.regionOptions = res.data.region |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | |
| | | if (valid) { |
| | | console.log(this.editConfig.infomation) |
| | | let params = { |
| | | city_id: 0, |
| | | city_id: this.editConfig.infomation.city_id || 0, |
| | | contact_name: this.editConfig.infomation.contact_name || "", |
| | | contact_phone: this.editConfig.infomation.contact_phone || "", |
| | | contact_position: this.editConfig.infomation.contact_position || "", |
| | | country_id: 0, |
| | | country_id: this.editConfig.infomation.country_id || 0, |
| | | id: this.editConfig.title === "新建" ? 0 : this.editConfig.infomation.id, |
| | | desc: this.editConfig.infomation.desc || "", |
| | | member_id: parseInt(this.editConfig.infomation.member_id) || 0, |
| | | name: this.editConfig.infomation.name || "", |
| | | number: this.editConfig.infomation.number || "", |
| | | province_id: 0, |
| | | region_id: 0, |
| | | province_id: this.editConfig.infomation.province_id || 0, |
| | | region_id: this.editConfig.infomation.region_id || 0, |
| | | sales_sources_id: this.editConfig.infomation.sales_sources_id || 0 |
| | | } |
| | | console.log(params) |
| File was renamed from src/views/custom/salesLead/index.vue |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import AddSalesLeadDialog from "@/views/custom/salesLead/AddSalesLeadDialog" |
| | | import AddSalesLeadDialog from "@/views/client/salesLead/AddSalesLeadDialog" |
| | | import pageMixin from "@/components/makepager/pager/mixin/pageMixin" |
| | | import ImportFileDialog from "@/views/other/commonDialog/ImportFileDialog" |
| | | import { getSalesLeadsList } from "@/api/custom/salesLead" |
| | | import { getSalesLeadsList } from "@/api/client/salesLead" |
| | | |
| | | export default { |
| | | name: "SalesLead", |
| | |
| | | |
| | | <script> |
| | | import AddGeneratePlanDialog from "@/views/sales/generatePlan/AddGeneratePlanDialog" |
| | | import { getPlanList } from "@/api/sales/generatePlan" |
| | | |
| | | export default { |
| | | name: "GeneratePlan", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | documentNumber: "ZDYB04-2", |
| | | owner: "系统管理员", |
| | | approvalStatus: "未提交", |
| | | creator: "系统管理员", |
| | | createTime: "2023-0703 11:22:12" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "单据编号", prop: "documentNumber", min: 120 }, |
| | | { label: "负责人", prop: "owner", min: 90 }, |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getPlanList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddMasterOrderDialog from "@/views/sales/masterOrder/AddMasterOrderDialog" |
| | | import { getMasterOrderList } from "@/api/sales/masterOrder" |
| | | |
| | | export default { |
| | | name: "MasterOrder", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | documentNumber: "ZDYBD03-1", |
| | | customName: "张三", |
| | | serviceStartTime: "2023-0703 11:22:12", |
| | | serviceDeadline: "2023-0703 11:22:12", |
| | | contractAmount: 13000.0, |
| | | owner: "系统管理员", |
| | | approvalStatus: "未提交" |
| | | }, |
| | | { |
| | | documentNumber: "", |
| | | customName: "", |
| | | serviceStartTime: "", |
| | | serviceDeadline: "", |
| | | contractAmount: 13000.0, |
| | | owner: "", |
| | | approvalStatus: "" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "单据编号", prop: "documentNumber", min: 120 }, // 单据编号 |
| | | { label: "客户名称", prop: "customName", min: 120 }, // 客户名称 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getMasterOrderList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddQuotationDialog from "@/views/sales/quotation/AddQuotationDialog" |
| | | import { getQuotationList } from "@/api/sales/quotation" |
| | | |
| | | export default { |
| | | name: "QuotationView", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | quotationNo: "QUO109", |
| | | customName: "123123", |
| | | contactName: "马里奥", |
| | | salesHead: "系统管理员", |
| | | modifyTime: "2023-0703 11:22:12", |
| | | subTotal: "¥9,499.00", |
| | | total: "¥9,499.00", |
| | | productName: "自动打印机", |
| | | number: "1.00", |
| | | priceTax: "¥9499.00" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "报价单号", prop: "quotationNo", min: 90 }, // 报价单号 |
| | | { label: "客户名称", prop: "customName", min: 120 }, // 客户名称 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getQuotationList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddRefundFormDialog from "@/views/sales/refundForm/AddRefundFormDialog" |
| | | import { getSalesRefundList } from "@/api/sales/refundForm" |
| | | |
| | | export default { |
| | | name: "RefundForm", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | refundOrderNo: "TKD20220118-44", |
| | | customName: "万科物料发展有限公司", |
| | | refundDate: "2022-01-18", |
| | | account: "人民币账户", |
| | | whetherInvoicing: "未开", |
| | | paymentMethod: "现金", |
| | | salesHead: "系统管理员", |
| | | modifyTime: "202-01-18 13:11:05", |
| | | priceTax: "¥12.00" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "退款单编号", prop: "refundOrderNo" }, |
| | | { label: "客户名称", prop: "customName", min: 120 }, |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getSalesRefundList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddSalesDetailsDialog from "@/views/sales/salesDetails/AddSalesDetailsDialog" |
| | | import { getSalesDetailsList } from "@/api/sales/salesDetails" |
| | | |
| | | export default { |
| | | name: "SalesDetails", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getSalesDetailsList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddSalesOpportunityDialog from "@/views/sales/salesOpportunity/AddSalesOpportunityDialog" |
| | | import { getSaleChanceList } from "@/api/sales/salesOpportunity" |
| | | |
| | | export default { |
| | | name: "SalesOpportunity", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | opportunityName: "123123", |
| | | customName: "上海铃铛", |
| | | salesOpportunityNo: "POT205", |
| | | contactName: "刘总", |
| | | saleStage: "初期沟通", |
| | | possible: "A类客户", |
| | | expectDealDate: "50", |
| | | expectContractAmount: "2023-05-28", |
| | | budgetAbsoluteValue: "¥200,000.00", |
| | | salesHead: "系统管理员" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "机会名称", prop: "opportunityName", min: 120 }, // 机会名称 |
| | | { label: "客户名称", prop: "customName", min: 90 }, // 客户名称 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getSaleChanceList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddSalesReturnDialog from "@/views/sales/salesReturn/AddSalesReturnDialog" |
| | | import { getSalesReturnList } from "@/api/sales/salesReturn" |
| | | |
| | | export default { |
| | | name: "SalesReturn", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | salesReturnOrderNo: "THD20230607-44", |
| | | customName: "欧克科技股份有限公司", |
| | | returnDate: "2023-06-07", |
| | | state: "未入库", |
| | | returnWarehouse: "总仓", |
| | | refundabe: "¥9,499.00", |
| | | refunded: "¥1,499.00", |
| | | salesHead: "系统管理员", |
| | | modifyTime: "2023-06-07 11:10:25" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "销售退货单编号", prop: "salesReturnOrderNo", min: 120 }, |
| | | { label: "客户名称", prop: "customName", min: 90 }, |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getSalesReturnList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddSubOrderDialog from "@/views/sales/subOrder/AddSubOrderDialog" |
| | | import { getSubOrderList } from "@/api/sales/subOrder" |
| | | |
| | | export default { |
| | | name: "SubOrder", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | documentNumber: "ZDYBD12-1", |
| | | customName: "上海有限公司", |
| | | masterOrder: "ZDYBD03-1", |
| | | owner: "系统管理员", |
| | | approvalStatus: "未提交", |
| | | productName: "自动打印机", |
| | | number: "2.00" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "单据编号", prop: "documentNumber", min: 120 }, // 单据编号 |
| | | { label: "客户名称", prop: "customName", min: 120 }, // 客户名称 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getSubOrderList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddOrderManageDialog from "@/views/service/orderManage/AddOrderManageDialog" |
| | | import { getOrderManageList } from "@/api/serviceManage/orderManage" |
| | | |
| | | export default { |
| | | name: "SalesLead", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | orderNumber: "LEA110", |
| | | customName: "上海通用机械有限公司", |
| | | contactName: "董奇伟", |
| | | servicePerson: "系统管理员", |
| | | orderStatus: "已结单", |
| | | repairSource: "电话报修", |
| | | orderType: "保内收费" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "工单编号", prop: "orderNumber", min: 100 }, // 工单编号 |
| | | { label: "客户名称", prop: "customName", min: 130 }, // 客户名称 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getOrderManageList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // tab切换 |
| | | tabsClick(tab, event) { |
| | | console.log(tab, event) |
| | |
| | | |
| | | <script> |
| | | import AddServiceContractDialog from "@/views/service/serviceContract/AddServiceContractDialog" |
| | | import { getServiceContractList } from "@/api/serviceManage/serviceContract" |
| | | |
| | | export default { |
| | | name: "ServiceContract", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | serviceContractNumber: "FWHT20230703123", |
| | | customName: "上海铃铛信息科技有限公司", |
| | | signDate: "2023-06-26", |
| | | contractType: "按年", |
| | | contractStatus: "已创建", |
| | | owner: "Boss", |
| | | productName: "软件", |
| | | startDate: "2023-06-26", |
| | | endDate: "2024-06-25", |
| | | priceTax: "¥5,000.00" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "服务合同编号", prop: "serviceContractNumber", min: 100 }, // 服务合同编号 |
| | | { label: "客户名称", prop: "customName", min: 120 }, // 客户名称 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getServiceContractList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddServiceFeeManageDialog from "@/views/service/serviceFeeManage/AddServiceFeeManageDialog" |
| | | import { getServiceFeeManageList } from "@/api/serviceManage/serviceFeeManage" |
| | | |
| | | export default { |
| | | name: "ServiceFeeManage", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | 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", |
| | | status: "blue" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "客户名称", prop: "customName", min: 120 }, // 客户名称 |
| | | { label: "客户类型", prop: "customType", min: 90, status: true }, // 客户类型 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getServiceFeeManageList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | |
| | | |
| | | <script> |
| | | import AddServiceFollowupDialog from "@/views/service/serviceFollowup/AddServiceFollowupDialog" |
| | | import { getServiceFollowupList } from "@/api/serviceManage/serviceFollowup" |
| | | |
| | | export default { |
| | | name: "SalesLead", |
| | |
| | | }, |
| | | created() { |
| | | this.setTable() |
| | | this.getData() |
| | | }, |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [ |
| | | { |
| | | followupNumber: "HF30", |
| | | customName: "上海通用机械有限公司", |
| | | contactName: "董奇伟", |
| | | customServiceForm: "TT5031", |
| | | visitor: "系统管理员", |
| | | satisfaction: "100%", |
| | | modifyTime: "2023-0703 11:22:12" |
| | | } |
| | | ], |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "回访单编号", prop: "followupNumber", min: 80 }, // 回访单编号 |
| | | { label: "客户名称", prop: "customName", min: 130 }, // 客户名称 |
| | |
| | | this.searchOptions.push({ value: (i + 1).toString(), label: label }) |
| | | } |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | | this.loading = true |
| | | await getServiceFollowupList() |
| | | .then((res) => { |
| | | console.log(res) |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | | const list = res.data.list.map((item) => { |
| | | return { |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | | this.loading = false |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err) |
| | | this.tableList.tableInfomation = [] |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | // 新建 |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |