| | |
| | | <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; |