|
|
@@ -66,19 +66,43 @@
|
|
|
<BaseIndexButtonGroup ref="BaseIndexButtonGroup" id="BaseIndexButtonGroup">
|
|
|
<template #left>
|
|
|
<BaseIndexButton ref="chooseReceivableInvoice" name="chooseReceivableInvoice"
|
|
|
- @click="chooseReceivableInvoice"></BaseIndexButton>
|
|
|
+ @click="openReceivableModal"></BaseIndexButton>
|
|
|
</template>
|
|
|
</BaseIndexButtonGroup>
|
|
|
-
|
|
|
+ <DkForm ref="receivableFootFormData" v-model="receivableFootFormData" :labelMaxWords="6" name="dk-form"
|
|
|
+ class="form-content-class">
|
|
|
+ <!--总可用金额-->
|
|
|
+ <DkFormItem prop="sumReceiptResidue">
|
|
|
+ <InputNumberPop ref="sumReceiptResidue" v-model="receivableFootFormData.sumReceiptResidue" :clearable="false"
|
|
|
+ :digits="2" :readonly="true"/>
|
|
|
+ </DkFormItem>
|
|
|
+ <!--总剩余应收-->
|
|
|
+ <DkFormItem prop="sumReceivableResidue">
|
|
|
+ <InputNumberPop ref="sumReceivableResidue" v-model="receivableFootFormData.sumReceivableResidue"
|
|
|
+ :clearable="false"
|
|
|
+ :digits="2" :readonly="true"/>
|
|
|
+ </DkFormItem>
|
|
|
+ <!--总本次核销金额-->
|
|
|
+ <DkFormItem prop="sumAmtReceivableHandle">
|
|
|
+ <InputNumberPop ref="sumAmtReceivableHandle" v-model="receivableFootFormData.sumAmtReceivableHandle"
|
|
|
+ :digits="2"
|
|
|
+ @on-change="sumAmtReceivableHandleChange"/>
|
|
|
+ </DkFormItem>
|
|
|
+ <!--总本次优惠金额-->
|
|
|
+ <DkFormItem prop="sumAmtWaiveHandle">
|
|
|
+ <InputNumberPop ref="sumAmtWaiveHandle" v-model="receivableFootFormData.sumAmtWaiveHandle" :digits="2"
|
|
|
+ @on-change="sumAmtWaiveHandleChange"/>
|
|
|
+ </DkFormItem>
|
|
|
+ </DkForm>
|
|
|
<!--应收款单-->
|
|
|
<DkPanel prop="receivableInvoice">
|
|
|
+
|
|
|
<div id="search-cond-div-receivable-info" ref="search-cond-div-goods-info" slot="content">
|
|
|
- <EditTable ref="receivableTable" :data="formData.receivableList" showFooter
|
|
|
- major-field="receiptId"
|
|
|
- :height="this.tableHeight/2"
|
|
|
- :new-row-flag="true"
|
|
|
- :columns="receivableColumns"
|
|
|
- controlId="macId" @on-choose="getTotals" @changeValue="getTotals"/>
|
|
|
+ <EditTable ref="receivableTable" :data="formData.receivableList" showFooter major-field="itemId"
|
|
|
+ :new-row-flag="false" :add-flag="false"
|
|
|
+ :columns="receivableColumns" controlId="itemId" @on-choose="getReceivableTotals"
|
|
|
+ @changeValue="getReceivableTotals"
|
|
|
+ :height="this.tableHeight/2"/>
|
|
|
</div>
|
|
|
</DkPanel>
|
|
|
</DkCollapse>
|
|
|
@@ -95,11 +119,11 @@
|
|
|
</template>
|
|
|
</BaseIndexButtonGroup>
|
|
|
<DkTable :id="'table-'+$options.name" ref="detail-select" :pageFlag="false"
|
|
|
- :data="tableData_receivable" :height="this.tableHeight" primaryKey="item_id" name="table">
|
|
|
+ :data="tableData_receivable" :height="this.tableHeight" primaryKey="itemId" name="table">
|
|
|
<DkTableColumn field="biznisNo"/>
|
|
|
<DkTableColumn field="accDate"/>
|
|
|
- <DkTableColumn field="recStatus"/>
|
|
|
- <DkTableColumn field="amtShould"/>
|
|
|
+ <DkTableColumn field="recStatusName"/>
|
|
|
+ <DkTableColumn field="amtShould" :title="$t('amtShouldReceivable')"/>
|
|
|
<DkTableColumn field="amtHandle"/>
|
|
|
<DkTableColumn field="amtWaive"/>
|
|
|
<DkTableColumn field="amtResidue"/>
|
|
|
@@ -146,6 +170,13 @@ export default {
|
|
|
itemList: [],
|
|
|
receivableList: [],
|
|
|
},
|
|
|
+ // 应收合计信息
|
|
|
+ receivableFootFormData: {
|
|
|
+ sumReceiptResidue: 0,
|
|
|
+ sumReceivableResidue: 0,
|
|
|
+ sumAmtReceivableHandle: 0,
|
|
|
+ sumAmtWaiveHandle: 0,
|
|
|
+ },
|
|
|
receiptColumns: [
|
|
|
{
|
|
|
field: 'macName',
|
|
|
@@ -156,13 +187,6 @@ export default {
|
|
|
fieldUpdate: self.$updateColumns.receiptChooseMac,
|
|
|
searchDetailFlag: true
|
|
|
},
|
|
|
- // //账户余额
|
|
|
- // {
|
|
|
- // field: 'balance',
|
|
|
- // type: 'disabled',
|
|
|
- // digits: 2,
|
|
|
- // title: this.$t('accountBalance'),
|
|
|
- // },
|
|
|
//收款金额
|
|
|
{
|
|
|
field: 'amtRec',
|
|
|
@@ -178,54 +202,37 @@ export default {
|
|
|
receivableColumns: [
|
|
|
{field: 'biznisNo', type: 'disabled'},
|
|
|
{field: 'accDate', type: 'disabled'},
|
|
|
- {field: 'recStatus', type: 'disabled'},
|
|
|
- {field: 'amtShould', type: 'disabled'},
|
|
|
+ {field: 'recStatusName', type: 'disabled'},
|
|
|
+ {field: 'amtShould', title: self.$t('amtShouldReceivable'), type: 'disabled'},
|
|
|
{field: 'amtHandle', type: 'disabled'},
|
|
|
{field: 'amtWaive', type: 'disabled'},
|
|
|
+ // 本次核销金额
|
|
|
+ {
|
|
|
+ field: 'amtReceivableHandle',
|
|
|
+ type: 'number',
|
|
|
+ digits: 2,
|
|
|
+ number: true,
|
|
|
+ sum: true,
|
|
|
+ formula: {
|
|
|
+ amtResidue: ['amtShould-amtHandle-amtWaive-amtReceivableHandle-amtWaiveHandle', 'amtShould', 'amtHandle', 'amtWaive', 'amtReceivableHandle', 'amtWaiveHandle'],
|
|
|
+ },
|
|
|
+ },
|
|
|
+ // 本次优惠金额
|
|
|
+ {
|
|
|
+ field: 'amtWaiveHandle',
|
|
|
+ type: 'number',
|
|
|
+ digits: 2,
|
|
|
+ number: true,
|
|
|
+ sum: true,
|
|
|
+ formula: {
|
|
|
+ amtResidue: ['amtShould-amtHandle-amtWaive-amtReceivableHandle-amtWaiveHandle', 'amtShould', 'amtHandle', 'amtWaive', 'amtReceivableHandle', 'amtWaiveHandle'],
|
|
|
+ },
|
|
|
+ },
|
|
|
{field: 'amtResidue', type: 'disabled'},
|
|
|
],
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
- chooseReceivableInvoice() {
|
|
|
- this.receivableModal = true
|
|
|
- },
|
|
|
- /**
|
|
|
- * @desc : 获取应收款单
|
|
|
- * @author : 付斌
|
|
|
- * @date : 2024-03-22 16:42
|
|
|
- */
|
|
|
- getReceivableInvoice() {
|
|
|
- // 查询客户可用余额
|
|
|
- let params = {
|
|
|
- 'objectId': this.formData.objectId
|
|
|
- }
|
|
|
- this.excute(this.$service.accountService, this.$service.accountService.getReceivableAccountItem, params).then(res => {
|
|
|
- if (res.code === this.$config.SUCCESS_CODE) {
|
|
|
- this.tableData_receivable = res.data
|
|
|
- }
|
|
|
- })
|
|
|
- },
|
|
|
- receivableOk() {
|
|
|
- let self = this;
|
|
|
- let sensitiveList = self.sensitiveList
|
|
|
- this.params = {
|
|
|
- roleId: this.roleId
|
|
|
- }
|
|
|
- let roleSensitiveList = []
|
|
|
- for (let it of sensitiveList) {
|
|
|
- if (it.checked) {
|
|
|
- let list = {
|
|
|
- roleId: this.roleId,
|
|
|
- senItemCode: it.itemCode,
|
|
|
- flgShow: true,
|
|
|
- }
|
|
|
- roleSensitiveList.push(list)
|
|
|
- }
|
|
|
- }
|
|
|
- this.params.roleSensitiveList = roleSensitiveList;
|
|
|
- return this.excute(this.$service.roleSensitiveService, this.$service.roleSensitiveService.updateBatch, this.params, true, 'save')
|
|
|
- },
|
|
|
/**
|
|
|
* @desc : 加载数据
|
|
|
* @author : 付斌
|
|
|
@@ -256,12 +263,13 @@ export default {
|
|
|
this.excute(this.$service.accountService, this.$service.accountService.selectByCond, params).then(res => {
|
|
|
if (res.code === this.$config.SUCCESS_CODE && res.data.list.length > 0) {
|
|
|
this.formData.receiptResidue = res.data.list[0].receiptResidue
|
|
|
+ this.receivableFootFormData.sumReceiptResidue = this.formData.receiptResidue + this.formData.sumAmtRec
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
/**
|
|
|
- * @desc : 计算合计
|
|
|
+ * @desc : 收款计算合计
|
|
|
* @date : 2022/5/30 15:31
|
|
|
* @author : 付斌
|
|
|
*/
|
|
|
@@ -275,35 +283,141 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
this.formData.sumAmtRec = sumAmtRec;
|
|
|
+ this.receivableFootFormData.sumReceiptResidue = this.formData.receiptResidue + this.formData.sumAmtRec
|
|
|
}
|
|
|
},
|
|
|
/**
|
|
|
- * @desc : 通过id查询
|
|
|
+ * @desc : 应收计算合计
|
|
|
* @author : 付斌
|
|
|
- * @date : 2022/03/04 13:17
|
|
|
+ * @date : 2024-03-23 13:21
|
|
|
*/
|
|
|
- detail(id) {
|
|
|
- return this.excuteNoParam(this.$service.cusReceiptService, this.$service.cusReceiptService.getRpForUpdate, [id]);
|
|
|
+ getReceivableTotals(field, row, rowIndex) {
|
|
|
+ let table = this.$refs['receivableTable'].getTableDataFilter();
|
|
|
+ let sumAmtReceivableHandle = 0; // 本次核销金额
|
|
|
+ let sumAmtWaiveHandle = 0; // 本次优惠金额
|
|
|
+ if (table && table.length > 0) {
|
|
|
+ table.forEach(row => {
|
|
|
+ if (row["amtReceivableHandle"]) {
|
|
|
+ sumAmtReceivableHandle += parseFloat(row["amtReceivableHandle"]);
|
|
|
+ }
|
|
|
+ if (row["amtWaiveHandle"]) {
|
|
|
+ sumAmtWaiveHandle += parseFloat(row["amtWaiveHandle"]);
|
|
|
+ }
|
|
|
+ })
|
|
|
+ this.receivableFootFormData.sumAmtReceivableHandle = sumAmtReceivableHandle
|
|
|
+ this.receivableFootFormData.sumAmtWaiveHandle = sumAmtWaiveHandle
|
|
|
+ }
|
|
|
},
|
|
|
/**
|
|
|
- * @desc : 编辑页面赋值
|
|
|
+ * @desc : 打开选择应收单据的Modal
|
|
|
* @author : 付斌
|
|
|
- * @date : 2024-03-03 9:33
|
|
|
+ * @date : 2024-03-23 11:10
|
|
|
*/
|
|
|
- setValuesByEdit(data) {
|
|
|
- if (data) {
|
|
|
- this.formData = data["data"];
|
|
|
- this.formData.itemList = data["dataItem"];
|
|
|
+ openReceivableModal() {
|
|
|
+ this.receivableModal = true
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @desc : 获取应收单据
|
|
|
+ * @author : 付斌
|
|
|
+ * @date : 2024-03-22 16:42
|
|
|
+ */
|
|
|
+ getReceivableInvoice() {
|
|
|
+ // 查询客户可用余额
|
|
|
+ let params = {
|
|
|
+ 'objectId': this.formData.objectId
|
|
|
+ }
|
|
|
+ this.excute(this.$service.accountService, this.$service.accountService.getReceivableAccountItem, params).then(res => {
|
|
|
+ if (res.code === this.$config.SUCCESS_CODE) {
|
|
|
+ this.tableData_receivable = res.data
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @desc : 选择应收单据
|
|
|
+ * @author : 付斌
|
|
|
+ * @date : 2024-03-23 11:10
|
|
|
+ */
|
|
|
+ receivableOk() {
|
|
|
+ this.formData.receivableList = this.$refs['detail-select'].batchRows
|
|
|
+ let sumReceivableResidue = 0; // 合计数量
|
|
|
+ this.formData.receivableList.forEach(row => {
|
|
|
+ this.$set(row, 'amtReceivableHandle', row["amtResidue"]);
|
|
|
+ this.$set(row, 'amtResidue', 0);
|
|
|
+ sumReceivableResidue += parseFloat(row["amtReceivableHandle"]);
|
|
|
+ })
|
|
|
+ this.receivableFootFormData.sumReceivableResidue = sumReceivableResidue
|
|
|
+ this.receivableFootFormData.sumAmtReceivableHandle = sumReceivableResidue
|
|
|
+ this.receivableModal = false
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @desc : 核销金额改变事件
|
|
|
+ * @author : 付斌
|
|
|
+ * @date : 2024-03-23 13:10
|
|
|
+ */
|
|
|
+ sumAmtReceivableHandleChange(val) {
|
|
|
+ this.formData.receivableList.forEach(row => {
|
|
|
+ // 先把本次核销金额清0
|
|
|
+ this.$set(row, 'amtReceivableHandle', 0);
|
|
|
+ // 如果本次优惠没有数值,则置为0
|
|
|
+ if (!row['amtWaiveHandle'] || row['amtWaiveHandle'] === '') {
|
|
|
+ this.$set(row, 'amtWaiveHandle', 0);
|
|
|
+ }
|
|
|
+ // 设置剩余应收 = 应收-已核销-已优惠-本次优惠
|
|
|
+ this.$set(row, 'amtResidue', parseFloat(row['amtShould']) - parseFloat(row['amtHandle'])
|
|
|
+ - parseFloat(row['amtWaive']) - parseFloat(row['amtWaiveHandle']));
|
|
|
|
|
|
- // 如果是退款,editTable要输入负数
|
|
|
- if (this.formData.rpType === this.$config.rpType.tuiShouKuan) {
|
|
|
- this.showEditTable = false
|
|
|
- this.negativeFlag = true;
|
|
|
- setTimeout(() => {
|
|
|
- this.showEditTable = true;
|
|
|
- }, 50)
|
|
|
+ // 剩余应收
|
|
|
+ let amtResidue = parseFloat(row['amtResidue']);
|
|
|
+ if (amtResidue > 0) {
|
|
|
+ // 如果剩余应收比输入的值大,则把输入的值赋给本次应收,然后剩余应收减输入的值
|
|
|
+ if (amtResidue > val) {
|
|
|
+ this.$set(row, 'amtReceivableHandle', val);
|
|
|
+ this.$set(row, 'amtResidue', amtResidue - val);
|
|
|
+ val = 0;
|
|
|
+ }
|
|
|
+ // 否则把剩余应收赋给本次应收,然后剩余应收为0
|
|
|
+ else {
|
|
|
+ this.$set(row, 'amtReceivableHandle', amtResidue);
|
|
|
+ this.$set(row, 'amtResidue', 0);
|
|
|
+ val = val - amtResidue;
|
|
|
+ }
|
|
|
}
|
|
|
- }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @desc : 优惠金额改变事件
|
|
|
+ * @author : 付斌
|
|
|
+ * @date : 2024-03-23 13:10
|
|
|
+ */
|
|
|
+ sumAmtWaiveHandleChange(val) {
|
|
|
+ this.formData.receivableList.forEach(row => {
|
|
|
+ // 先把本次优惠金额清0
|
|
|
+ this.$set(row, 'amtWaiveHandle', 0);
|
|
|
+ // 如果本次核销没有数值,则置为0
|
|
|
+ if (!row['amtReceivableHandle'] || row['amtReceivableHandle'] === '') {
|
|
|
+ this.$set(row, 'amtReceivableHandle', 0);
|
|
|
+ }
|
|
|
+ // 设置剩余应收 = 应收-已核销-已优惠-本次核销
|
|
|
+ this.$set(row, 'amtResidue', parseFloat(row['amtShould']) - parseFloat(row['amtHandle'])
|
|
|
+ - parseFloat(row['amtWaive']) - parseFloat(row['amtReceivableHandle']));
|
|
|
+
|
|
|
+ // 剩余应收
|
|
|
+ let amtResidue = parseFloat(row['amtResidue']);
|
|
|
+ if (amtResidue > 0) {
|
|
|
+ // 如果剩余应收比输入的值大,则把输入的值赋给本次优惠,然后剩余应收减输入的值
|
|
|
+ if (amtResidue > val) {
|
|
|
+ this.$set(row, 'amtWaiveHandle', val);
|
|
|
+ this.$set(row, 'amtResidue', amtResidue - val);
|
|
|
+ val = 0;
|
|
|
+ }
|
|
|
+ // 否则把剩余应收赋给本次优惠,然后剩余应收为0
|
|
|
+ else {
|
|
|
+ this.$set(row, 'amtWaiveHandle', amtResidue);
|
|
|
+ this.$set(row, 'amtResidue', 0);
|
|
|
+ val = val - amtResidue;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
},
|
|
|
/**
|
|
|
* @desc : 校验数据
|
|
|
@@ -312,13 +426,57 @@ export default {
|
|
|
*/
|
|
|
validData() {
|
|
|
let itemTable = this.$refs['receiptTable'].getTableDataFilter();
|
|
|
- if (!itemTable || itemTable.length == 0) {
|
|
|
- this.$Message.warning(this.$t('W_012'))
|
|
|
+ if (itemTable && itemTable.length > 0) {
|
|
|
+ for (let it of itemTable) {
|
|
|
+ if (!it.amtRec || it.amtRec === '') {
|
|
|
+ this.$Message.warning(this.$t('W_042', {'param': '收款金额不能'}))
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ let sumAmtReceivableHandle = 0; // 本次核销金额
|
|
|
+ let sumAmtWaiveHandle = 0; // 本次优惠金额
|
|
|
+ // 先把为空的单元格设置成0
|
|
|
+ this.formData.receivableList.forEach(row => {
|
|
|
+ // 如果本次核销没有数值,则置为0
|
|
|
+ if (!row['amtReceivableHandle'] || row['amtReceivableHandle'] === '') {
|
|
|
+ this.$set(row, 'amtReceivableHandle', 0);
|
|
|
+ }
|
|
|
+ // 如果本次优惠没有数值,则置为0
|
|
|
+ if (!row['amtWaiveHandle'] || row['amtWaiveHandle'] === '') {
|
|
|
+ this.$set(row, 'amtWaiveHandle', 0);
|
|
|
+ }
|
|
|
+ // 将优惠金额设置成保存时需要的列名
|
|
|
+ this.$set(row, 'amtWaive', row['amtWaiveHandle']);
|
|
|
+ sumAmtReceivableHandle += parseFloat(row["amtReceivableHandle"]);
|
|
|
+ sumAmtWaiveHandle += parseFloat(row["amtWaiveHandle"]);
|
|
|
+ })
|
|
|
+ if (this.receivableFootFormData.sumAmtReceivableHandle != sumAmtReceivableHandle) {
|
|
|
+ this.$Message.warning('本次核销金额合计与本次总核销金额不一致')
|
|
|
return false;
|
|
|
}
|
|
|
- for (let it of itemTable) {
|
|
|
- if (!it.amtRec || it.amtRec === '') {
|
|
|
- this.$Message.warning(this.$t('W_042', {'param': '收款金额不能'}))
|
|
|
+ if (this.receivableFootFormData.sumAmtWaiveHandle != sumAmtWaiveHandle) {
|
|
|
+ this.$Message.warning('本次优惠金额合计与本次总优惠金额不一致')
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ if (this.receivableFootFormData.sumAmtReceivableHandle > this.receivableFootFormData.sumReceiptResidue) {
|
|
|
+ this.$Message.warning('本次总核销金额不能大于总可用金额')
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ let receivableTable = this.$refs['receivableTable'].getTableDataFilter();
|
|
|
+ if (!receivableTable || receivableTable.length == 0) {
|
|
|
+ this.$Message.warning(this.$t('W_042', {'param': '应收款单不能'}))
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ for (let it of receivableTable) {
|
|
|
+ if (!it.amtReceivableHandle === 0 && it.amtWaiveHandle === '') {
|
|
|
+ this.$Message.warning('本次核销金额和本次优惠金额不能都为0')
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ if (!it.amtResidue < 0) {
|
|
|
+ this.$Message.warning('剩余应收不能小于0')
|
|
|
return false;
|
|
|
}
|
|
|
}
|
|
|
@@ -330,21 +488,17 @@ export default {
|
|
|
* @date : 2023/6/25 14:31
|
|
|
*/
|
|
|
setParams(arg) {
|
|
|
- if (this.type === this.$config.formMode.receipt) {
|
|
|
+ if (this.type === this.$config.formMode.add) {
|
|
|
this.formData.rpType = this.$config.rpType.shouKuan
|
|
|
- } else if (this.type === this.$config.formMode.refund) {
|
|
|
- this.formData.rpType = this.$config.rpType.tuiShouKuan
|
|
|
}
|
|
|
this.formData.accDate = new Date(this.formData.accDate).toDateStr();
|
|
|
// 修改新增的表数据
|
|
|
let itemTable = this.$refs['receiptTable'].getTableDataFilter();
|
|
|
+ let receivableTable = this.$refs['receivableTable'].getTableDataFilter();
|
|
|
+
|
|
|
this.formData.itemList = itemTable
|
|
|
- this.params = {...this.formData}
|
|
|
- // itemTable.forEach((it, index) => {
|
|
|
- // this.$set(it, 'residueAmt', it["amtRec"]);
|
|
|
- // Object.assign(it, it, this.formData)
|
|
|
- // });
|
|
|
- // this.params = {"itemList": itemTable}
|
|
|
+ this.formData.receivableList = receivableTable
|
|
|
+ Object.assign(this.params, this.formData, this.receivableFootFormData)
|
|
|
},
|
|
|
/**
|
|
|
* @desc : 保存数据
|
|
|
@@ -352,12 +506,8 @@ export default {
|
|
|
* @date : 2023/6/25 14:31
|
|
|
*/
|
|
|
saveData() {
|
|
|
- if (this.type === this.$config.formMode.receipt) {
|
|
|
- return this.excute(this.$service.cusReceiptService, this.$service.cusReceiptService.insertReceipt, this.params);
|
|
|
- } else if (this.type === this.$config.formMode.refund) {
|
|
|
- return this.excute(this.$service.cusReceiptService, this.$service.cusReceiptService.insertRefund, this.params)
|
|
|
- } else if (this.type === this.$config.formMode.edit) {
|
|
|
- return this.excute(this.$service.cusReceiptService, this.$service.cusReceiptService.update, this.params)
|
|
|
+ if (this.type === this.$config.formMode.add) {
|
|
|
+ return this.excute(this.$service.receiptService, this.$service.receiptService.insertReceivableReceipt, this.params);
|
|
|
}
|
|
|
},
|
|
|
/**
|
|
|
@@ -385,10 +535,10 @@ export default {
|
|
|
makeStaff: self.$store.state.user.id,
|
|
|
cpId: self.$store.state.user.cpId,
|
|
|
itemList: [],
|
|
|
+ receivableList: [],
|
|
|
}
|
|
|
},
|
|
|
- }
|
|
|
- ,
|
|
|
+ },
|
|
|
/**
|
|
|
* @desc : 在实例创建完成后被立即同步调用
|
|
|
* @author : 付斌
|
|
|
@@ -397,7 +547,6 @@ export default {
|
|
|
created() {
|
|
|
this.focusItem = 'receiptId'; // 给第一个组件赋值,可以在混入中自动去聚焦
|
|
|
this.primaryKey = 'receiptId' // 设置主键Id
|
|
|
- this.routeObjName = 'receipt' // 设置路由名称
|
|
|
}
|
|
|
}
|
|
|
</script>
|