Merge branch 'dev' of http://192.168.5.5:10010/r/web/crm-web into wn
| | |
| | | :table-list="tableList" |
| | | :select-box="false" |
| | | @selCommonClick="selNameClick" |
| | | @selTableCol="selTableCol" |
| | | > |
| | | </TableCommonView> |
| | | <div slot="footer" class="dialog-footer"> |
| | | <div class="remark">说明:支持多字段模糊查询,仅显示符合条件的前5条数据</div> |
| | | <!-- <div class="remark">说明:支持多字段模糊查询,仅显示符合条件的前5条数据</div> --> |
| | | <div class="btn-pager"> |
| | | <PagerView class="page" :pager-options="pagerOptions" v-on="pagerEvents" /> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </el-dialog> |
| | |
| | | |
| | | <script> |
| | | import { getSaleChanceList } from "@/api/sales/salesOpportunity" |
| | | import pageMixin from "@/components/makepager/pager/mixin/pageMixin" |
| | | export default { |
| | | name: "EditSelChanceDialog", |
| | | mixins: [pageMixin], |
| | | props: { |
| | | editCommonConfig: { |
| | | type: Object, |
| | |
| | | tableList: [], |
| | | searchSelOptions: [], |
| | | loading: false, |
| | | search_map: {} |
| | | search_map: {}, |
| | | tableColumn: [ |
| | | { label: "销售机会编号", prop: "number" }, // 销售机会编号 |
| | | { label: "机会名称", prop: "name", isCommonClick: true, default: true }, // 机会名称 |
| | | { label: "销售阶段", prop: "sale_stage_name" }, // 销售阶段 |
| | | { label: "销售负责人", prop: "member_name" }, // 销售负责人 |
| | | { label: "预计成交日期", prop: "expected_time" } // 预计成交日期 |
| | | ], |
| | | showCol: ["销售机会编号", "机会名称", "销售阶段", "销售负责人", "预计成交日期"] |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | selectIndex: true, |
| | | tableInfomation: [], |
| | | tableColumn: [ |
| | | { label: "销售机会编号", prop: "number" }, // 销售机会编号 |
| | | { label: "机会名称", prop: "name", isCommonClick: true }, // 机会名称 |
| | | { label: "销售阶段", prop: "sale_stage_name" }, // 销售阶段 |
| | | { label: "销售负责人", prop: "member_name" }, // 销售负责人 |
| | | { label: "预计成交日期", prop: "expected_time" } // 预计成交日期 |
| | | ] |
| | | allcol: [], |
| | | showcol: this.showCol, |
| | | tableColumn: this.setColumnVisible(this.showCol) |
| | | } |
| | | this.tableList.allcol = this.tableList.tableColumn.filter((ele) => !ele.default).map((ele) => ele.label) |
| | | this.searchOptions = [] |
| | | for (let i = 0; i < this.tableList.tableColumn.length; i++) { |
| | | const label = this.tableList.tableColumn[i].label |
| | | const value = this.tableList.tableColumn[i].prop |
| | | this.searchOptions.push({ value: value, label: label }) |
| | | } |
| | | }, |
| | | setColumnVisible(showCol) { |
| | | return this.tableColumn.map((ele) => { |
| | | return { |
| | | ...ele, |
| | | isShowColumn: showCol.includes(ele.label) |
| | | } |
| | | }) |
| | | }, |
| | | selTableCol(val) { |
| | | this.showcol = val |
| | | this.tableList.tableColumn = this.setColumnVisible(val) |
| | | }, |
| | | handleClose() { |
| | | this.editConfig.editVisible = false |
| | |
| | | this.loading = true |
| | | await getSaleChanceList({ |
| | | search_map: this.search_map, |
| | | page: 0, |
| | | pageSize: 0 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }) |
| | | .then((res) => { |
| | | console.log(res) |
| | |
| | | sale_stage_name: item.sale_stage.name |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | cursor: pointer; |
| | | } |
| | | .dialog-footer { |
| | | height: 40px; |
| | | line-height: 40px; |
| | | height: 50px; |
| | | line-height: 50px; |
| | | color: red; |
| | | .btn-pager { |
| | | display: flex; |
| | | margin-top: 0px; |
| | | .page { |
| | | margin-left: auto; |
| | | } |
| | | } |
| | | } |
| | | ::v-deep { |
| | | .input-with-select .el-input-group__prepend { |
| | |
| | | await getServiceContractList({ |
| | | keyword: this.keyword, |
| | | keywordType: this.keywordType, |
| | | page: 0, |
| | | pageSize: 0 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | |
| | | serviceContractStatus: item.serviceContractStatus.name |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | async getQuotationList() { |
| | | await getQuotationList({ |
| | | search_map: this.search_map, |
| | | page: 0, |
| | | pageSize: 0 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | |
| | | member_name: item.member.username |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | await getSalesDetailsList({ |
| | | keyword: this.keyword, |
| | | keywordType: this.keywordType, |
| | | page: 0, |
| | | pageSize: 0 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | |
| | | member_name: item.Member.username |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | await getServiceOrderList({ |
| | | keyword: this.keyword, |
| | | keywordType: this.keywordType, |
| | | page: 0, |
| | | pageSize: 0 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | if (res.data.data && res.data.data.length > 0) { |
| | |
| | | serviceOrderStatus_name: item.ServiceOrderStatus_name |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | await getProductList({ |
| | | productName: this.keywordType === "产品名称" ? this.keyword : "", |
| | | productNumber: this.keywordType === "产品编号" ? this.keyword : "", |
| | | page: 1, |
| | | pageSize: 5 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }).then((res) => { |
| | | console.log(res.data) |
| | | if (res.data.code === 200) { |
| | |
| | | ...item |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | await getSalesReturnList({ |
| | | keyword: this.keyword, |
| | | keywordType: this.keywordType, |
| | | page: 0, |
| | | pageSize: 0 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | if (res.data.list && res.data.list.length > 0) { |
| | |
| | | salesReturnStatus_name: item.SalesReturnStatus.name |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | this.loading = true |
| | | await getContactList({ |
| | | search_map: this.search_map, |
| | | page: 0, |
| | | pageSize: 0 |
| | | page: this.pagerOptions.currPage, |
| | | pageSize: this.pagerOptions.pageSize |
| | | }) |
| | | .then((res) => { |
| | | console.log(res) |
| | |
| | | client_name: item.Client.name |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list.slice(0, 5) || [] |
| | | this.tableList.tableInfomation = list || [] |
| | | this.pagerOptions.totalCount = res.data.count |
| | | } else { |
| | | this.tableList.tableInfomation = [] |
| | | } |
| | |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | label-width="168px" |
| | | size="mini" |
| | | style="height: 60vh; overflow-x: hidden" |
| | | > |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('client', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('client')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('serviceContract', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('serviceContract')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('contract', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('contract')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | v-model="editConfig.infomation.principalId" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | |
| | | value-format="yyyy-MM-dd" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | v-model="editConfig.infomation.paymentTypeId" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="item in paymentTypeListOptions" |
| | |
| | | v-model="editConfig.infomation.bankAccountId" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in bankAccountOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | <div class="basic-info-title">收款信息</div> |
| | | <div class="basic-info-view"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-col :span="12"> |
| | | <el-form-item label="本次收款金额" prop="amount"> |
| | | <el-input-number |
| | | v-model="editConfig.infomation.amount" |
| | |
| | | :min="0" |
| | | :precision="2" |
| | | :controls="false" |
| | | style="width: 25%; margin-right: 5px" |
| | | style="width: 100%" |
| | | ></el-input-number> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | dialogWidth: "50%", |
| | | editConfig: this.editCommonConfig, |
| | | rules: { |
| | | client_name: [{ required: true, message: "请选择客户名称", trigger: "change" }], |
| | |
| | | <div v-else class="filter"> |
| | | <div class="filter-card"> |
| | | <CommonSearch |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入收款单编号" |
| | | @searchClick="onFilterSearch" |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入收款单编号" |
| | | @searchClick="onFilterSearch" |
| | | > |
| | | <template slot="leftButton"> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <!-- <el-button size="small" @click="delClick">删除</el-button>--> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <!-- <el-button size="small" @click="delClick">删除</el-button>--> |
| | | </template> |
| | | </CommonSearch> |
| | | </div> |
| | |
| | | <div class="body-card"> |
| | | <div class="list-view"> |
| | | <TableCommonView |
| | | ref="tableListRef" |
| | | v-loading="loading" |
| | | :table-list="tableList" |
| | | :select-box="!isDetail" |
| | | @getSelectArray="getSelectArray" |
| | | @selTableCol="selTableCol" |
| | | ref="tableListRef" |
| | | v-loading="loading" |
| | | :table-list="tableList" |
| | | :select-box="!isDetail" |
| | | @getSelectArray="getSelectArray" |
| | | @selTableCol="selTableCol" |
| | | > |
| | | <!-- <template slot="tableButton"> |
| | | <el-table-column label="操作" width="60" fixed="right"> |
| | |
| | | keyword: "", |
| | | keywordType: "", |
| | | tableColumn: [ |
| | | { label: "收款单编号", prop: "number", default: true}, |
| | | { label: "收款单编号", prop: "number", default: true }, |
| | | { label: "客户名称", prop: "client_name" }, |
| | | { label: "选择源单", prop: "sourceId" }, |
| | | { label: "实际收款金额", prop: "amount" }, |
| | |
| | | { label: "销售负责人", prop: "principal_name" }, |
| | | { label: "收款日期", prop: "receiptDate" } |
| | | ], |
| | | showCol:["收款单编号", "客户名称", "选择源单", "实际收款金额", "收款方式", "销售负责人", "收款日期"] |
| | | showCol: ["收款单编号", "客户名称", "选择源单", "实际收款金额", "收款方式", "销售负责人", "收款日期"] |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | tableInfomation: [], |
| | | allcol: [], |
| | | showcol: this.showCol, |
| | | tableColumn:this.setColumnVisible(this.showCol) |
| | | tableColumn: this.setColumnVisible(this.showCol) |
| | | } |
| | | this.tableList.allcol = this.tableList.tableColumn.filter(ele=>!ele.default).map(ele=>ele.label); |
| | | this.tableList.allcol = this.tableList.tableColumn.filter((ele) => !ele.default).map((ele) => ele.label) |
| | | this.searchOptions = [] |
| | | for (let i = 0; i < this.tableList.tableColumn.length; i++) { |
| | | const label = this.tableList.tableColumn[i].label |
| | |
| | | this.searchOptions.push({ value: value, label: label }) |
| | | } |
| | | }, |
| | | setColumnVisible(showCol){ |
| | | return this.tableColumn.map(ele=>{ |
| | | setColumnVisible(showCol) { |
| | | return this.tableColumn.map((ele) => { |
| | | return { |
| | | ...ele, |
| | | isShowColumn:showCol.includes(ele.label) |
| | | isShowColumn: showCol.includes(ele.label) |
| | | } |
| | | }) |
| | | }, |
| | | selTableCol(val) { |
| | | this.showcol = val; |
| | | this.tableList.tableColumn = this.setColumnVisible(val); |
| | | this.showcol = val |
| | | this.tableList.tableColumn = this.setColumnVisible(val) |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | |
| | | }) |
| | | }, |
| | | // 搜索 |
| | | onFilterSearch(searchText){ |
| | | onFilterSearch(searchText) { |
| | | this.keyword = searchText ?? "" |
| | | this.keywordType = "收款单编号" |
| | | this.pagerOptions.currPage = 1 |
| | |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.sourceType = this.sourceType |
| | | this.editConfig.infomation = { ...this.addConfig } |
| | | this.editConfig.infomation = { ...this.addConfig, number: "" } |
| | | } |
| | | } |
| | | } |
| | |
| | | |
| | | <!-- Add "scoped" attribute to limit CSS to this component only --> |
| | | <style lang="scss" scoped> |
| | | .receipt{ |
| | | .receipt { |
| | | height: 100%; |
| | | overflow: hidden; |
| | | .filter{ |
| | | .filter { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | | padding: 12px 20px 0 20px; |
| | | &-card{ |
| | | &-card { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | |
| | | background-color: #fff; |
| | | } |
| | | } |
| | | .body{ |
| | | .body { |
| | | box-sizing: border-box; |
| | | padding: 10px 20px; |
| | | border-radius: 12px; |
| | |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | label-width="168px" |
| | | size="mini" |
| | | style="height: 60vh; overflow-x: hidden" |
| | | > |
| | |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="主题" prop="subject"> |
| | | <el-input v-model="editConfig.infomation.subject"></el-input> |
| | | <el-input v-model="editConfig.infomation.subject" style="width: 100%"></el-input> |
| | | </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-input v-model="editConfig.infomation.number" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('client', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('client')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in invoiceTypeOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="item in invoiceStatusOptions" |
| | |
| | | v-model="editConfig.infomation.principalId" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('serviceContract', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('serviceContract')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('contract', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('contract')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="纳税识别号" prop="taxpayerIdNumber"> |
| | | <el-input v-model="editConfig.infomation.taxpayerIdNumber"></el-input> |
| | | <el-input v-model="editConfig.infomation.taxpayerIdNumber" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="item in courierCompanyOptions" |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="物流单号" prop="courierNumber"> |
| | | <el-input v-model="editConfig.infomation.courierNumber"></el-input> |
| | | <el-input v-model="editConfig.infomation.courierNumber" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | value-format="yyyy-MM-dd" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="发票号码" prop="invoiceNumber"> |
| | | <el-input v-model="editConfig.infomation.invoiceNumber"></el-input> |
| | | <el-input v-model="editConfig.infomation.invoiceNumber" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | dialogWidth: "50%", |
| | | editConfig: this.editCommonConfig, |
| | | rules: { |
| | | subject: [{ required: true, message: "请输入主题", trigger: "blur" }], |
| | |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.sourceType = this.sourceType |
| | | this.editConfig.infomation = { ...this.addConfig } |
| | | this.editConfig.infomation = { ...this.addConfig, number: "" } |
| | | } |
| | | } |
| | | } |
| | |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | label-width="168px" |
| | | size="mini" |
| | | > |
| | | <!-- 信息 --> |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('client', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('client')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="单据编号" prop="number"> |
| | | <el-input v-model="editConfig.infomation.number"></el-input> |
| | | <el-input v-model="editConfig.infomation.number" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | v-model="editConfig.infomation.memberId" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in statusOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('quotation', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('quotation')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | dialogWidth: "50%", |
| | | editConfig: this.editCommonConfig, |
| | | rules: { |
| | | number: [{ required: true, message: "请输入", trigger: "blur" }], |
| | |
| | | } |
| | | }, |
| | | handleSelectClient(value, item) { |
| | | console.log(value) |
| | | console.log(item) |
| | | if (value === "client") { |
| | | this.editConfig.infomation.client_name = item.name |
| | | this.clientId = item.id |
| | | } else if (value === "quotation") { |
| | | this.editConfig.infomation.quotation_number = item.number |
| | | this.quotationId = item.id |
| | | } |
| | | }, |
| | | selClientClick(value) { |
| | | console.log("aaaa") |
| | | if (value === "client") { |
| | | this.editSelectClientConfig.editVisible = true |
| | | } else if (value === "quotation") { |
| | |
| | | } |
| | | }, |
| | | selClient(row, value) { |
| | | console.log("bbbb") |
| | | console.log(value) |
| | | if (value === "client") { |
| | | this.editConfig.infomation.client_name = row.name |
| | |
| | | }, |
| | | // 清除已选择用户 |
| | | clearupClient(value) { |
| | | console.log(value) |
| | | if (value === "client") { |
| | | console.log("ss88888") |
| | | this.editConfig.infomation.client_name = "" |
| | | this.clientId = 0 |
| | | } else if (value === "quotation") { |
| | |
| | | <div class="filter"> |
| | | <div class="filter-card"> |
| | | <CommonSearch |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入单据编号" |
| | | @searchClick="onFilterSearch" |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入单据编号" |
| | | @searchClick="onFilterSearch" |
| | | > |
| | | <template slot="leftButton"> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <el-button size="small" @click="delClick">删除</el-button> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <!-- <el-button size="small" @click="delClick">删除</el-button> --> |
| | | </template> |
| | | </CommonSearch> |
| | | </div> |
| | |
| | | <div class="body-card"> |
| | | <div class="list-view"> |
| | | <TableCommonView |
| | | ref="tableListRef" |
| | | :table-list="tableList" |
| | | @selCommonClick="selCommonClick" |
| | | @getSelectArray="getSelectArray" |
| | | @selTableCol="selTableCol" |
| | | ref="tableListRef" |
| | | :table-list="tableList" |
| | | @selCommonClick="selCommonClick" |
| | | @getSelectArray="getSelectArray" |
| | | @selTableCol="selTableCol" |
| | | > |
| | | <template slot="tableButton"> |
| | | <el-table-column label="操作" width="100"> |
| | | <template slot-scope="scope"> |
| | | <el-button @click="handleClick(scope.row)" type="text" size="small">编辑</el-button> |
| | | <!-- <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> --> |
| | | <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </template> |
| | |
| | | { label: "合同状态", prop: "serviceContractStatus_name", min: 100 }, |
| | | { label: "创建时间", prop: "created_at" } |
| | | ], |
| | | showCol:["单据编号", "负责人", "客户名称", "合同状态", "创建时间"] |
| | | showCol: ["单据编号", "负责人", "客户名称", "合同状态", "创建时间"] |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | setTable() { |
| | | this.tableList = { |
| | | tableInfomation: [], |
| | | selectIndex: true, |
| | | allcol: [], |
| | | showcol: this.showCol, |
| | | tableColumn:this.setColumnVisible(this.showCol) |
| | | tableColumn: this.setColumnVisible(this.showCol) |
| | | } |
| | | this.tableList.allcol = this.tableList.tableColumn.filter(ele=>!ele.default).map(ele=>ele.label); |
| | | this.tableList.allcol = this.tableList.tableColumn.filter((ele) => !ele.default).map((ele) => ele.label) |
| | | this.searchOptions = [] |
| | | for (let i = 0; i < this.tableList.tableColumn.length; i++) { |
| | | const label = this.tableList.tableColumn[i].label |
| | |
| | | this.searchOptions.push({ value: value, label: label }) |
| | | } |
| | | }, |
| | | setColumnVisible(showCol){ |
| | | return this.tableColumn.map(ele=>{ |
| | | setColumnVisible(showCol) { |
| | | return this.tableColumn.map((ele) => { |
| | | return { |
| | | ...ele, |
| | | isShowColumn:showCol.includes(ele.label) |
| | | isShowColumn: showCol.includes(ele.label) |
| | | } |
| | | }) |
| | | }, |
| | | selTableCol(val) { |
| | | this.showcol = val; |
| | | this.tableList.tableColumn = this.setColumnVisible(val); |
| | | this.showcol = val |
| | | this.tableList.tableColumn = this.setColumnVisible(val) |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | |
| | | }) |
| | | }, |
| | | // 搜索 |
| | | onFilterSearch(searchText){ |
| | | this.search_map.number = searchText ?? '' |
| | | onFilterSearch(searchText) { |
| | | this.search_map.number = searchText ?? "" |
| | | this.pagerOptions.currPage = 1 |
| | | this.getData() |
| | | }, |
| | |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.infomation = {} |
| | | this.editConfig.infomation = { client_name: "", quotation_number: "" } |
| | | }, |
| | | // 编辑 |
| | | handleClick(row) { |
| | |
| | | this.editConfig.infomation = { ...row } |
| | | }, |
| | | // 删除 |
| | | delClick() { |
| | | if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelContract({ ids: this.selValueList }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | delClick(id) { |
| | | // if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelContract({ ids: [id] }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | } else { |
| | | this.$message.warning("请至少选择一条记录") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | // } else { |
| | | // this.$message.warning("请至少选择一条记录") |
| | | // } |
| | | }, |
| | | getSelectArray(val) { |
| | | console.log(val) |
| | |
| | | |
| | | <!-- Add "scoped" attribute to limit CSS to this component only --> |
| | | <style lang="scss" scoped> |
| | | .contract-manage{ |
| | | .contract-manage { |
| | | height: 100%; |
| | | overflow: hidden; |
| | | .filter{ |
| | | .filter { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | | padding: 12px 20px 0 20px; |
| | | &-card{ |
| | | &-card { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | |
| | | background-color: #fff; |
| | | } |
| | | } |
| | | .body{ |
| | | .body { |
| | | box-sizing: border-box; |
| | | padding: 10px 20px; |
| | | border-radius: 12px; |
| | |
| | | this.editConfig.infomation = { ...row, currency: "人民币", sale_return_nunber: row.Source.number } |
| | | }, |
| | | // 删除 |
| | | delClick() { |
| | | if (this.selValueList && this.selValueList.length > 0) { |
| | | delClick(rowID) { |
| | | // if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelSalesRefund({ ids: this.selValueList }).then((response) => { |
| | | getDelSalesRefund({ ids: [rowID] }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | } else { |
| | | this.$message.warning("请至少选择一条记录") |
| | | } |
| | | // } else { |
| | | // this.$message.warning("请至少选择一条记录") |
| | | // } |
| | | }, |
| | | getSelectArray(val) { |
| | | console.log(val) |
| | |
| | | this.editConfig.infomation = { ...row, sale_chance_name: "", currency: "人民币" } |
| | | }, |
| | | // 删除 |
| | | delClick() { |
| | | if (this.selValueList && this.selValueList.length > 0) { |
| | | delClick(rowID) { |
| | | console.log(rowID,"xxxxshanchu") |
| | | // if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelSalesDetails({ ids: this.selValueList }).then((response) => { |
| | | getDelSalesDetails({ ids: [rowID] }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | } else { |
| | | this.$message.warning("请至少选择一条记录") |
| | | } |
| | | // } else { |
| | | // this.$message.warning("请至少选择一条记录") |
| | | // } |
| | | }, |
| | | getSelectArray(val) { |
| | | console.log(val) |
| | |
| | | this.editConfig.infomation = { ...row, currency: "人民币", salesDetailNumber: row.Source.number } |
| | | }, |
| | | // 删除 |
| | | delClick() { |
| | | if (this.selValueList && this.selValueList.length > 0) { |
| | | delClick(rowID) { |
| | | // if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelSalesReturn({ ids: this.selValueList }).then((response) => { |
| | | getDelSalesReturn({ ids:[rowID] }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | } else { |
| | | this.$message.warning("请至少选择一条记录") |
| | | } |
| | | // } else { |
| | | // this.$message.warning("请至少选择一条记录") |
| | | // } |
| | | }, |
| | | getSelectArray(val) { |
| | | console.log(val) |
| | |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | label-width="168px" |
| | | size="mini" |
| | | style="height: 60vh; overflow-x: hidden" |
| | | > |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('client', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('client')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="服务单编号" prop="serviceNumber"> |
| | | <el-input v-model="editConfig.infomation.serviceNumber"></el-input> |
| | | <el-input v-model="editConfig.infomation.serviceNumber" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('serviceContract', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('serviceContract')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <!-- @focus="getFaultTypeList" --> |
| | | <el-option v-for="item in faultTypeOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="主题" prop="subject"> |
| | | <el-input v-model="editConfig.infomation.subject"></el-input> |
| | | <el-input v-model="editConfig.infomation.subject" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('contract', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('contract')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | </el-form-item> |
| | | </el-col> --> |
| | | <el-col :span="12"> |
| | | <el-form-item label="产品名称" prop="product_name"> |
| | | <el-form-item label="产品名称" prop="productName"> |
| | | <div class="custom-name"> |
| | | <el-autocomplete |
| | | v-model="editConfig.infomation.product_name" |
| | | v-model="editConfig.infomation.productName" |
| | | :fetch-suggestions=" |
| | | (queryString, callback) => { |
| | | querySearchAsync(queryString, callback, 'productName') |
| | | } |
| | | " |
| | | value-key="Name" |
| | | value-key="name" |
| | | @select="handleSelectClient('productName', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('productName')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | | </div> |
| | | <div |
| | | v-if="editConfig.infomation.product_name && editConfig.infomation.product_name.length > 0" |
| | | v-if="editConfig.infomation.productName && editConfig.infomation.productName.length > 0" |
| | | class="common-select-btn" |
| | | @click="clearupClient('productName')" |
| | | > |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in serviceTypeOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="item in serviceManOptions" |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('contact', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('contact')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in severityOptions" :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="address"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | placeholder="请输入内容" |
| | | v-model="editConfig.infomation.address" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="item in priorityLevelOptions" |
| | |
| | | v-model="editConfig.infomation.appointmentTime" |
| | | type="datetime" |
| | | placeholder="选择日期" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('chance', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('chance')"> |
| | | <i class="el-icon-circle-plus-outline"></i> |
| | |
| | | <i class="el-icon-remove-outline"></i> |
| | | </div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="上门地址" prop="address"> |
| | | <el-input |
| | | type="textarea" |
| | | :autosize="{ minRows: 2, maxRows: 4 }" |
| | | placeholder="请输入内容" |
| | | v-model="editConfig.infomation.address" |
| | | ></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in statusOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="datetime" |
| | | placeholder="选择时间" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="datetime" |
| | | placeholder="选择时间" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | placeholder="请输入" |
| | | :min="0" |
| | | :controls="false" |
| | | style="width: 100%; margin-right: 5px" |
| | | style="width: 100%" |
| | | ></el-input-number> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | placeholder="请输入" |
| | | :min="0" |
| | | :controls="false" |
| | | style="width: 100%; margin-right: 5px" |
| | | style="width: 100%" |
| | | ></el-input-number> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in timeSpentOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in faqOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | dialogWidth: "50%", |
| | | editConfig: this.editCommonConfig, |
| | | rules: { |
| | | serviceNumber: [{ required: true, message: "请输入服务单编号", trigger: "blur" }], |
| | |
| | | if (value === "serviceContract" || value === "contract") { |
| | | return state.number.toLowerCase().indexOf(queryString.toLowerCase()) === 0 |
| | | } else if (value === "productName") { |
| | | return state.Name.toLowerCase().indexOf(queryString.toLowerCase()) === 0 |
| | | return state.name.toLowerCase().indexOf(queryString.toLowerCase()) === 0 |
| | | } else { |
| | | return state.name.toLowerCase().indexOf(queryString.toLowerCase()) === 0 |
| | | } |
| | |
| | | } else if (value === "contract") { |
| | | this.SalesDetailsId = item.id |
| | | } else if (value === "productName") { |
| | | this.productName = item.Name |
| | | this.productName = item.name |
| | | } else if (value === "contact") { |
| | | this.contactId = item.id |
| | | } else if (value === "chance") { |
| | |
| | | this.editConfig.infomation.number = row.number |
| | | this.SalesDetailsId = row.id |
| | | } else if (value === "productName") { |
| | | this.editConfig.infomation.product_name = row.Name |
| | | this.editConfig.infomation.productName = row.name |
| | | this.productName = row.Name |
| | | } else if (value === "chance") { |
| | | this.editConfig.infomation.sale_chance_name = row.name |
| | |
| | | this.editConfig.infomation.number = "" |
| | | this.SalesDetailsId = 0 |
| | | } else if (value === "productName") { |
| | | this.editConfig.infomation.product_name = "" |
| | | this.editConfig.infomation.productName = "" |
| | | this.productName = "" |
| | | } else if (value === "contact") { |
| | | this.editConfig.infomation.contact_name = "" |
| | |
| | | <div v-else class="filter"> |
| | | <div class="filter-card"> |
| | | <CommonSearch |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入服务单编号" |
| | | @searchClick="onFilterSearch" |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入服务单编号" |
| | | @searchClick="onFilterSearch" |
| | | > |
| | | <template slot="leftButton"> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <el-button size="small" @click="delClick">删除</el-button> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <!-- <el-button size="small" @click="delClick">删除</el-button> --> |
| | | </template> |
| | | </CommonSearch> |
| | | </div> |
| | |
| | | <TableCommonView |
| | | ref="tableListRef" |
| | | :table-list="tableList" |
| | | :select-box="!isDetail" |
| | | @selClientClick="selClientClick" |
| | | @selCommonClick="selCommonClick" |
| | | @getSelectArray="getSelectArray" |
| | | @selTableCol="selTableCol" |
| | | > |
| | | <template slot="tableButton"> |
| | | <el-table-column label="操作" width="60"> |
| | | <el-table-column label="操作" width="100"> |
| | | <template slot-scope="scope"> |
| | | <el-button @click="handleClick(scope.row)" type="text" size="small">编辑</el-button> |
| | | <!-- <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> --> |
| | | <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </template> |
| | |
| | | <div class="btn-pager"> |
| | | <PagerView class="page" :pager-options="pagerOptions" v-on="pagerEvents" /> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | // { label: "产品类别", prop: "reportSourceId" }, // 产品类别 |
| | | { label: "故障类别", prop: "faultType_name" } // 故障类别 |
| | | ], |
| | | showCol:["服务单编号", "主题", "客户名称", "实际处理时间", "服务人员", "服务方式", "故障类别"] |
| | | showCol: ["服务单编号", "主题", "客户名称", "实际处理时间", "服务人员", "服务方式", "故障类别"] |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | selectIndex: true, |
| | | tableInfomation: [], |
| | | allcol: [], |
| | | showcol: this.showCol, |
| | | tableColumn:this.setColumnVisible(this.showCol) |
| | | tableColumn: this.setColumnVisible(this.showCol) |
| | | } |
| | | this.tableList.allcol = this.tableList.tableColumn.filter(ele=>!ele.default).map(ele=>ele.label); |
| | | this.tableList.allcol = this.tableList.tableColumn.filter((ele) => !ele.default).map((ele) => ele.label) |
| | | this.searchOptions = [] |
| | | for (let i = 0; i < this.tableList.tableColumn.length; i++) { |
| | | const label = this.tableList.tableColumn[i].label |
| | |
| | | this.searchOptions.push({ value: value, label: label }) |
| | | } |
| | | }, |
| | | setColumnVisible(showCol){ |
| | | return this.tableColumn.map(ele=>{ |
| | | setColumnVisible(showCol) { |
| | | return this.tableColumn.map((ele) => { |
| | | return { |
| | | ...ele, |
| | | isShowColumn:showCol.includes(ele.label) |
| | | isShowColumn: showCol.includes(ele.label) |
| | | } |
| | | }) |
| | | }, |
| | | selTableCol(val) { |
| | | this.showcol = val; |
| | | this.tableList.tableColumn = this.setColumnVisible(val); |
| | | this.showcol = val |
| | | this.tableList.tableColumn = this.setColumnVisible(val) |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | |
| | | console.log(tab, event) |
| | | }, |
| | | // 搜索 |
| | | onFilterSearch(searchText){ |
| | | onFilterSearch(searchText) { |
| | | this.keyword = searchText ?? "" |
| | | this.keywordType =searchText ? "服务单编号" : '' |
| | | this.keywordType = searchText ? "服务单编号" : "" |
| | | this.pagerOptions.currPage = 1 |
| | | this.getData() |
| | | }, |
| | |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.infomation = {} |
| | | this.editConfig.infomation = { |
| | | client_name: "", |
| | | serviceContract_Number: "", |
| | | number: "", |
| | | productName: "", |
| | | contact_name: "", |
| | | sale_chance_name: "" |
| | | } |
| | | }, |
| | | // 编辑 |
| | | handleClick(row) { |
| | | console.log(row) |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "编辑" |
| | | this.editConfig.infomation = { ...row, contact_name: row.Contact.name, service_number: row.serviceContractId } |
| | | this.editConfig.infomation = { |
| | | ...row, |
| | | contact_name: row.Contact.name, |
| | | service_number: row.serviceContractId, |
| | | number: row.SalesDetails.number, |
| | | sale_chance_name: row.SaleChance.name |
| | | } |
| | | }, |
| | | // 删除 |
| | | delClick() { |
| | | if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelServiceOrder({ ids: this.selValueList }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | delClick(id) { |
| | | // if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelServiceOrder({ ids: [id] }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | } else { |
| | | this.$message.warning("请至少选择一条记录") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | // } else { |
| | | // this.$message.warning("请至少选择一条记录") |
| | | // } |
| | | }, |
| | | getSelectArray(val) { |
| | | console.log(val) |
| | |
| | | } |
| | | } |
| | | |
| | | .sales-lead{ |
| | | .sales-lead { |
| | | height: 100%; |
| | | overflow: hidden; |
| | | .filter{ |
| | | .filter { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | | padding: 12px 20px 0 20px; |
| | | &-card{ |
| | | &-card { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | |
| | | background-color: #fff; |
| | | } |
| | | } |
| | | .body{ |
| | | .body { |
| | | box-sizing: border-box; |
| | | padding: 10px 20px; |
| | | border-radius: 12px; |
| | |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | label-width="168px" |
| | | size="mini" |
| | | style="height: 60vh; overflow-x: hidden" |
| | | > |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('client', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('client')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="服务合同编号" prop="number"> |
| | | <el-input v-model="editConfig.infomation.number"></el-input> |
| | | <el-input v-model="editConfig.infomation.number" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | v-model="editConfig.infomation.memberId" |
| | | placeholder="请选择" |
| | | size="mini" |
| | | style="width: 63%" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('contact', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('contact')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('chance', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('chance')"> |
| | | <i class="el-icon-circle-plus-outline"></i> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('contract', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('contract')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | " |
| | | value-key="number" |
| | | @select="handleSelectClient('quotation', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('quotation')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in contractTypeOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | value-format="yyyy-MM-dd" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | value-format="yyyy-MM-dd" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | value-format="yyyy-MM-dd" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | style="width: 100%" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | v-for="item in contractStatusOptions" |
| | |
| | | :min="0" |
| | | :precision="2" |
| | | :controls="false" |
| | | style="width: 100%; margin-right: 5px" |
| | | style="width: 100%" |
| | | ></el-input-number> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | dialogWidth: "50%", |
| | | editConfig: this.editCommonConfig, |
| | | rules: { |
| | | number: [{ required: true, message: "请输入服务合同编号", trigger: "blur" }], |
| | |
| | | @searchClick="onFilterSearch" |
| | | > |
| | | <template slot="leftButton"> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <el-button size="small" @click="delClick">删除</el-button> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <!-- <el-button size="small" @click="delClick">删除</el-button> --> |
| | | </template> |
| | | </CommonSearch> |
| | | </div> |
| | |
| | | <div class="body-card"> |
| | | <div class="list-view"> |
| | | <TableCommonView |
| | | ref="tableListRef" |
| | | :table-list="tableList" |
| | | :select-box="!isDetail" |
| | | @selClientClick="selClientClick" |
| | | @selCommonClick="selCommonClick" |
| | | @getSelectArray="getSelectArray" |
| | | @selTableCol="selTableCol" |
| | | ref="tableListRef" |
| | | :table-list="tableList" |
| | | @selClientClick="selClientClick" |
| | | @selCommonClick="selCommonClick" |
| | | @getSelectArray="getSelectArray" |
| | | @selTableCol="selTableCol" |
| | | > |
| | | <template slot="tableButton"> |
| | | <el-table-column label="操作" width="60"> |
| | | <el-table-column label="操作" width="100"> |
| | | <template slot-scope="scope"> |
| | | <el-button @click="handleClick(scope.row)" type="text" size="small">编辑</el-button> |
| | | <!-- <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> --> |
| | | <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </template> |
| | | </TableCommonView> |
| | | </div> |
| | | <div class="btn-pager"> |
| | | <PagerView class="page" :pager-options="pagerOptions" v-on="pagerEvents" /> |
| | | </div> |
| | | <div class="btn-pager"> |
| | | <PagerView class="page" :pager-options="pagerOptions" v-on="pagerEvents" /> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <!-- 新建/编辑 --> |
| | |
| | | { label: "服务到期日", prop: "endTime" }, // 服务到期日 |
| | | { label: "价税合计", prop: "amountTotal" } // 价税合计 |
| | | ], |
| | | showCol:["服务合同编号", "客户名称", "签约日期", "合同类型", "合同状态", "负责人", "产品名称", "服务开始日", "服务到期日", "价税合计"] |
| | | showCol: [ |
| | | "服务合同编号", |
| | | "客户名称", |
| | | "签约日期", |
| | | "合同类型", |
| | | "合同状态", |
| | | "负责人", |
| | | "产品名称", |
| | | "服务开始日", |
| | | "服务到期日", |
| | | "价税合计" |
| | | ] |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | selectIndex: true, |
| | | tableInfomation: [], |
| | | allcol: [], |
| | | showcol: this.showCol, |
| | | tableColumn:this.setColumnVisible(this.showCol) |
| | | tableColumn: this.setColumnVisible(this.showCol) |
| | | } |
| | | this.tableList.allcol = this.tableList.tableColumn.filter(ele=>!ele.default).map(ele=>ele.label); |
| | | this.tableList.allcol = this.tableList.tableColumn.filter((ele) => !ele.default).map((ele) => ele.label) |
| | | this.searchOptions = [] |
| | | for (let i = 0; i < this.tableList.tableColumn.length; i++) { |
| | | const label = this.tableList.tableColumn[i].label |
| | |
| | | this.searchOptions.push({ value: value, label: label }) |
| | | } |
| | | }, |
| | | setColumnVisible(showCol){ |
| | | return this.tableColumn.map(ele=>{ |
| | | setColumnVisible(showCol) { |
| | | return this.tableColumn.map((ele) => { |
| | | return { |
| | | ...ele, |
| | | isShowColumn:showCol.includes(ele.label) |
| | | isShowColumn: showCol.includes(ele.label) |
| | | } |
| | | }) |
| | | }, |
| | | selTableCol(val) { |
| | | this.showcol = val; |
| | | this.tableList.tableColumn = this.setColumnVisible(val); |
| | | this.showcol = val |
| | | this.tableList.tableColumn = this.setColumnVisible(val) |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | |
| | | }) |
| | | }, |
| | | // 搜索 |
| | | onFilterSearch(searchText){ |
| | | onFilterSearch(searchText) { |
| | | this.keyword = searchText ?? "" |
| | | this.keywordType = "服务合同编号" |
| | | this.pagerOptions.currPage = 1 |
| | |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.infomation = { ...this.addConfig, currency: "人民币" } |
| | | this.editConfig.infomation = { |
| | | ...this.addConfig, |
| | | currency: "人民币", |
| | | client_name: "", |
| | | contact_name: "", |
| | | sale_chance_name: "", |
| | | contract_number: "", |
| | | quotation_number: "" |
| | | } |
| | | }, |
| | | // 编辑 |
| | | handleClick(row) { |
| | |
| | | ...row, |
| | | contract_number: row.salesDetails.number, |
| | | quotation_number: row.quotation.number, |
| | | currency: "人民币" |
| | | currency: "人民币", |
| | | sale_chance_name: row.SaleChance.name, |
| | | contact_name: row.contact.name |
| | | } |
| | | }, |
| | | // 删除 |
| | | delClick() { |
| | | if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelServiceContract({ ids: this.selValueList }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | delClick(id) { |
| | | // if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelServiceContract({ ids: [id] }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | } else { |
| | | this.$message.warning("请至少选择一条记录") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | // } else { |
| | | // this.$message.warning("请至少选择一条记录") |
| | | // } |
| | | }, |
| | | getSelectArray(val) { |
| | | console.log(val) |
| | |
| | | |
| | | <!-- Add "scoped" attribute to limit CSS to this component only --> |
| | | <style lang="scss" scoped> |
| | | .service-contract{ |
| | | .service-contract { |
| | | height: 100%; |
| | | overflow: hidden; |
| | | .filter{ |
| | | .filter { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | | padding: 12px 20px 0 20px; |
| | | &-card{ |
| | | &-card { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | |
| | | background-color: #fff; |
| | | } |
| | | } |
| | | .body{ |
| | | .body { |
| | | box-sizing: border-box; |
| | | padding: 10px 20px; |
| | | border-radius: 12px; |
| | |
| | | :model="editConfig.infomation" |
| | | :rules="rules" |
| | | label-position="right" |
| | | label-width="308px" |
| | | label-width="168px" |
| | | size="mini" |
| | | style="height: 60vh; overflow-x: hidden" |
| | | > |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('client', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('client')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="回访单编号" prop="number"> |
| | | <el-input v-model="editConfig.infomation.number"></el-input> |
| | | <el-input v-model="editConfig.infomation.number" style="width: 100%"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | " |
| | | value-key="name" |
| | | @select="handleSelectClient('contact', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('contact')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | " |
| | | value-key="serviceNumber" |
| | | @select="handleSelectClient('customService', $event)" |
| | | style="width: 100%" |
| | | ></el-autocomplete> |
| | | <div class="common-select-btn" @click="selClientClick('customService')"> |
| | | <i class="el-icon-circle-plus-outline" title="选择"></i> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="回访人" prop="memberId"> |
| | | <el-select v-model="editConfig.infomation.memberId" size="mini"> |
| | | <el-select v-model="editConfig.infomation.memberId" size="mini" style="width: 100%"> |
| | | <el-option v-for="item in memberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in satisfactionOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in timelyRateOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in solveRateOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="原服务人员" prop="oldMemberId"> |
| | | <el-select v-model="editConfig.infomation.oldMemberId" size="mini"> |
| | | <el-select v-model="editConfig.infomation.oldMemberId" size="mini" style="width: 100%"> |
| | | <el-option v-for="item in oldMemberOptions" :key="item.id" :label="item.username" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | |
| | | placeholder="请选择" |
| | | class="common-select-sel" |
| | | size="mini" |
| | | style="width: 100%" |
| | | > |
| | | <el-option v-for="item in isVisitOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | dialogWidth: "80%", |
| | | dialogWidth: "50%", |
| | | editConfig: this.editCommonConfig, |
| | | rules: { |
| | | number: [{ required: true, message: "请输入回访单单编号", trigger: "blur" }], |
| | |
| | | <div v-else class="filter"> |
| | | <div class="filter-card"> |
| | | <CommonSearch |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入服务单编号" |
| | | @searchClick="onFilterSearch" |
| | | :show-add="false" |
| | | :show-download="false" |
| | | :amount-view="false" |
| | | :show-action-btn="false" |
| | | placeholder="请输入服务单编号" |
| | | @searchClick="onFilterSearch" |
| | | > |
| | | <template slot="leftButton"> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <el-button size="small" @click="delClick">删除</el-button> |
| | | <el-button size="small" type="primary" @click="addBtnClick">新建</el-button> |
| | | <!-- <el-button size="small" @click="delClick">删除</el-button> --> |
| | | </template> |
| | | </CommonSearch> |
| | | </div> |
| | |
| | | <TableCommonView |
| | | ref="tableListRef" |
| | | :table-list="tableList" |
| | | :select-box="!isDetail" |
| | | @selClientClick="selClientClick" |
| | | @selCommonClick="selCommonClick" |
| | | @selContactsClick="selContactsClick" |
| | |
| | | @selTableCol="selTableCol" |
| | | > |
| | | <template slot="tableButton"> |
| | | <el-table-column label="操作" width="60"> |
| | | <el-table-column label="操作" width="100"> |
| | | <template slot-scope="scope"> |
| | | <el-button @click="handleClick(scope.row)" type="text" size="small">编辑</el-button> |
| | | <!-- <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> --> |
| | | <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </template> |
| | |
| | | { label: "满意度", prop: "satisfaction_name" } // 满意度 |
| | | // { label: "修改时间", prop: "modifyTime" } // 修改时间 |
| | | ], |
| | | showCol:["回访单编号", "客户名称", "联系人姓名", "客户服务单", "回访人", "满意度"] |
| | | showCol: ["回访单编号", "客户名称", "联系人姓名", "客户服务单", "回访人", "满意度"] |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | methods: { |
| | | setTable() { |
| | | this.tableList = { |
| | | selectIndex: true, |
| | | tableInfomation: [], |
| | | allcol: [], |
| | | showcol: this.showCol, |
| | | tableColumn:this.setColumnVisible(this.showCol) |
| | | tableColumn: this.setColumnVisible(this.showCol) |
| | | } |
| | | this.tableList.allcol = this.tableList.tableColumn.filter(ele=>!ele.default).map(ele=>ele.label); |
| | | this.tableList.allcol = this.tableList.tableColumn.filter((ele) => !ele.default).map((ele) => ele.label) |
| | | this.searchOptions = [] |
| | | for (let i = 0; i < this.tableList.tableColumn.length; i++) { |
| | | const label = this.tableList.tableColumn[i].label |
| | |
| | | this.searchOptions.push({ value: value, label: label }) |
| | | } |
| | | }, |
| | | setColumnVisible(showCol){ |
| | | return this.tableColumn.map(ele=>{ |
| | | setColumnVisible(showCol) { |
| | | return this.tableColumn.map((ele) => { |
| | | return { |
| | | ...ele, |
| | | isShowColumn:showCol.includes(ele.label) |
| | | isShowColumn: showCol.includes(ele.label) |
| | | } |
| | | }) |
| | | }, |
| | | selTableCol(val) { |
| | | this.showcol = val; |
| | | this.tableList.tableColumn = this.setColumnVisible(val); |
| | | this.showcol = val |
| | | this.tableList.tableColumn = this.setColumnVisible(val) |
| | | }, |
| | | // 请求数据 |
| | | async getData() { |
| | |
| | | }) |
| | | }, |
| | | // 搜索 |
| | | onFilterSearch(searchText){ |
| | | onFilterSearch(searchText) { |
| | | this.keyword = searchText ?? "" |
| | | this.keywordType =searchText ? "回访单编号" : '' |
| | | this.keywordType = searchText ? "回访单编号" : "" |
| | | this.pagerOptions.currPage = 1 |
| | | this.getData() |
| | | }, |
| | |
| | | addBtnClick() { |
| | | this.editConfig.visible = true |
| | | this.editConfig.title = "新建" |
| | | this.editConfig.infomation = { ...this.addConfig } |
| | | this.editConfig.infomation = { ...this.addConfig, client_name: "", contact_name: "", service_number: "" } |
| | | }, |
| | | // 编辑 |
| | | handleClick(row) { |
| | |
| | | this.editConfig.infomation = { ...row, service_number: row.ServiceOrder.serviceNumber } |
| | | }, |
| | | // 删除 |
| | | delClick() { |
| | | if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelServiceFollowup({ ids: this.selValueList }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | delClick(id) { |
| | | // if (this.selValueList && this.selValueList.length > 0) { |
| | | this.$confirm("是否确认删除?", "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | getDelServiceFollowup({ ids: [id] }).then((response) => { |
| | | if (response.code === 200) { |
| | | this.$message.success("删除成功") |
| | | this.getData() |
| | | } else { |
| | | this.$message.warning("删除失败") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | } else { |
| | | this.$message.warning("请至少选择一条记录") |
| | | } |
| | | }) |
| | | .catch(() => {}) |
| | | // } else { |
| | | // this.$message.warning("请至少选择一条记录") |
| | | // } |
| | | }, |
| | | getSelectArray(val) { |
| | | console.log(val) |
| | |
| | | .sales-lead { |
| | | height: 100%; |
| | | overflow: hidden; |
| | | .filter{ |
| | | .filter { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | | padding: 12px 20px 0 20px; |
| | | &-card{ |
| | | &-card { |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | |
| | | background-color: #fff; |
| | | } |
| | | } |
| | | .body{ |
| | | .body { |
| | | box-sizing: border-box; |
| | | padding: 10px 20px; |
| | | border-radius: 12px; |