|  |  | 
 |  |  |     <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() { | 
 |  |  | 
 |  |  |     } | 
 |  |  |     this.getData() | 
 |  |  |   }, | 
 |  |  |   mounted() {}, | 
 |  |  |   methods: { | 
 |  |  |     setTable() { | 
 |  |  |       this.tableList = { | 
 |  |  |         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() | 
 |  |  |       this.loading = true | 
 |  |  |       await getReceiptList({ | 
 |  |  |         keyword: this.keyword, | 
 |  |  |         keywordType: this.keywordType, | 
 |  |  |         page: this.pagerOptions.currPage, | 
 |  |  |         pageSize: this.pagerOptions.pageSize | 
 |  |  |       }) | 
 |  |  |       let params = {} | 
 |  |  |       let sourceTyle = this.addConfig.keywordType === "销售明细单" || this.addConfig.keywordType === "客户名称" ? 1 : 2 | 
 |  |  |       if (this.addConfig.id) { | 
 |  |  |         params = { | 
 |  |  |           sourceId: this.addConfig.id, | 
 |  |  |           sourceType: sourceTyle, | 
 |  |  |           page: this.pagerOptions.currPage, | 
 |  |  |           pageSize: this.pagerOptions.pageSize, | 
 |  |  |           client_id: this.addConfig.client_id | 
 |  |  |         } | 
 |  |  |       } else { | 
 |  |  |         params = { | 
 |  |  |           keyword: this.keyword, | 
 |  |  |           keywordType: this.keywordType, | 
 |  |  |           page: this.pagerOptions.currPage, | 
 |  |  |           pageSize: this.pagerOptions.pageSize, | 
 |  |  |           client_id: this.addConfig.client_id | 
 |  |  |         } | 
 |  |  |       } | 
 |  |  |       await getReceiptList(params) | 
 |  |  |         .then((res) => { | 
 |  |  |           if (res.data.code === 200) { | 
 |  |  |             const resList = res?.data?.data?.data ?? [] | 
 |  |  |           if (res.code === 200) { | 
 |  |  |             const resList = res?.data?.data ?? [] | 
 |  |  |             if (resList.length > 0) { | 
 |  |  |               const list = resList.map((item) => { | 
 |  |  |                 return { | 
 |  |  | 
 |  |  |                 } | 
 |  |  |               }) | 
 |  |  |               this.tableList.tableInfomation = list || [] | 
 |  |  |               this.pagerOptions.totalCount = res.data.data.count | 
 |  |  |               this.pagerOptions.totalCount = res.data.count | 
 |  |  |             } else { | 
 |  |  |               this.tableList.tableInfomation = [] | 
 |  |  |             } | 
 |  |  | 
 |  |  |         }) | 
 |  |  |     }, | 
 |  |  |     // 搜索 | 
 |  |  |     onFilterSearch(searchText){ | 
 |  |  |     onFilterSearch(searchText) { | 
 |  |  |       this.keyword = searchText ?? "" | 
 |  |  |       this.keywordType = "收款单编号" | 
 |  |  |       this.pagerOptions.currPage = 1 | 
 |  |  | 
 |  |  |     addBtnClick() { | 
 |  |  |       this.editConfig.visible = true | 
 |  |  |       this.editConfig.title = "新建" | 
 |  |  |       this.editConfig.sourceType = this.sourceType | 
 |  |  |       this.editConfig.infomation = { ...this.addConfig } | 
 |  |  |       this.editConfig.sourceType = this.addConfig.keywordType === "客户名称" ? 1 : this.sourceType | 
 |  |  |       console.log(this.addConfig) | 
 |  |  |       this.editConfig.infomation = { ...this.addConfig, saleDetailNumber: "" } | 
 |  |  |     } | 
 |  |  |   } | 
 |  |  | } | 
 |  |  | 
 |  |  |  | 
 |  |  | <!-- 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; |