| | |
| | | v-else-if="item.productName" |
| | | label=" " |
| | | :prop="'tableData.' + scope.$index + '.' + item.prop" |
| | | :rules="[{ required: item.isRequird ? true : false, message: '产品名称不能为空' }]" |
| | | > |
| | | <div class="custom-name"> |
| | | <el-autocomplete |
| | |
| | | <el-button size="small" type="primary" @click="add">新增</el-button> |
| | | <!-- <el-button size="small" type="primary" disabled>导入明细</el-button> --> |
| | | <el-button size="small" type="primary" @click="empty">清空</el-button> |
| | | <el-button size="small" type="primary" @click="recalculate">重算</el-button> |
| | | <el-button size="small" type="primary" @click="recalculate" :disabled="isRecalculate ? false : true" |
| | | >重算</el-button |
| | | > |
| | | </div> |
| | | <div v-if="showSummary.total || showSummary.refundable" style="height: 42px; line-height: 42px"> |
| | | <el-row :gutter="10"> |
| | |
| | | title: "", |
| | | infomation: {} |
| | | }, |
| | | productIndex: 0 |
| | | productIndex: 0, |
| | | isRecalculate: true |
| | | } |
| | | }, |
| | | created() { |
| | | this.getProductList() |
| | | this.tableList = this.productTableList |
| | | if (this.tableList.tableData.length === 1 && this.tableList.tableData[0].name === "") { |
| | | this.isRecalculate = false |
| | | } else { |
| | | this.isRecalculate = true |
| | | } |
| | | }, |
| | | computed: {}, |
| | | methods: { |
| | |
| | | sums[index] = "小计:" |
| | | return |
| | | } |
| | | const title = ["#"] |
| | | const title = ["#", "产品名称"] |
| | | // 去除某些不需要计算的数据 |
| | | if (title.includes(column.label)) { |
| | | sums[index] = "" |
| | |
| | | }, |
| | | // 清空 |
| | | empty() { |
| | | this.isRecalculate = false |
| | | this.$emit("emptyProductClick") |
| | | }, |
| | | // 重算 |
| | |
| | | }, |
| | | handleSelectClient(item, prop, row) { |
| | | // this.clientId = item.id |
| | | this.isRecalculate = true |
| | | console.log(item, prop, row) |
| | | this.tableList.tableData.map((ite) => { |
| | | if (ite.name === item.name) { |
| | |
| | | selClient(item) { |
| | | console.log(item) |
| | | console.log(this.tableList.tableData) |
| | | this.isRecalculate = true |
| | | // this.editConfig.infomation.client_name = row.name |
| | | this.tableList.tableData.map((ite, index) => { |
| | | if (index === this.productIndex) { |
| | |
| | | member_id: data.memberId || 0, |
| | | number: data.number || "", |
| | | quotation_id: this.quotationId || 0, |
| | | status_id: data.status_id || 0 |
| | | status_id: data.statusId || 0 |
| | | } |
| | | return params |
| | | }, |
| | |
| | | <template slot="title"> |
| | | <div class="header"> |
| | | <span class="header-label">单据编号</span> |
| | | <span class="header-title">{{ detailConfig.infomation.name }}</span> |
| | | <span class="header-title">{{ detailConfig.infomation.number }}</span> |
| | | </div> |
| | | </template> |
| | | <div class="content"> |
| | |
| | | showSummary: { |
| | | show: true, |
| | | total: true, |
| | | sumProp: ["other1", "other2", "other3", "other4"], |
| | | mergeNumber: 3 |
| | | sumProp: ["amount", "price", "total"], |
| | | mergeNumber: 1 |
| | | }, |
| | | productTableList: {}, |
| | | addConfig: {} |
| | |
| | | showSummary: { |
| | | show: true, |
| | | total: true, |
| | | sumProp: ["other1", "other2", "other3", "other4"], |
| | | mergeNumber: 3 |
| | | sumProp: ["amount", "price", "total"], |
| | | mergeNumber: 1 |
| | | }, |
| | | productTableList: {} |
| | | } |
| | |
| | | showSummary: { |
| | | show: true, |
| | | total: true, |
| | | sumProp: ["other1", "other2", "other3", "other4"], |
| | | mergeNumber: 3 |
| | | sumProp: ["amount", "price", "total"], |
| | | mergeNumber: 1 |
| | | }, |
| | | productTableList: {}, |
| | | addConfig: {} |
| | |
| | | showSummary: { |
| | | show: true, |
| | | total: true, |
| | | sumProp: ["other1", "other2", "other3", "other4"], |
| | | mergeNumber: 3 |
| | | sumProp: ["amount", "price", "total"], |
| | | mergeNumber: 1 |
| | | }, |
| | | productTableList: {}, |
| | | addConfig: {} |
| | |
| | | showSummary: { |
| | | show: true, |
| | | total: true, |
| | | sumProp: ["other1", "other2", "other3", "other4"], |
| | | mergeNumber: 3 |
| | | sumProp: ["amount", "price", "total"], |
| | | mergeNumber: 1 |
| | | }, |
| | | productTableList: {}, |
| | | addConfig: {} |
| | |
| | | <template slot="title"> |
| | | <div class="header"> |
| | | <span class="header-label">服务单编号</span> |
| | | <span class="header-title">{{ detailConfig.infomation.number }}</span> |
| | | <span class="header-title">{{ detailConfig.infomation.serviceNumber }}</span> |
| | | </div> |
| | | </template> |
| | | <div class="content"> |
| | |
| | | showSummary: { |
| | | show: true, |
| | | total: true, |
| | | sumProp: ["other1", "other2", "other3", "other4"], |
| | | mergeNumber: 3 |
| | | sumProp: ["amount", "price", "total"], |
| | | mergeNumber: 1 |
| | | }, |
| | | productTableList: {}, |
| | | addConfig: {} |