|
@@ -649,16 +649,32 @@ export default {
|
|
|
this.form.auditDateTo = this.form.auditDateTo ? this.form.auditDateTo.slice(0, 10) + ' 00:00:00' : null
|
|
|
this.form.settlementType = this.settlementType
|
|
|
if (this.form.id) {
|
|
|
- this.form.finStlBillsItemsList = this.form.finStlBillsItemsList.map((item, index) => {
|
|
|
- if (item.currentStlCurCode == 'CNY') {
|
|
|
+ if (this.form.finStlBillsItemsList.length != 0) {
|
|
|
+ this.form.finStlBillsItemsList = this.form.finStlBillsItemsList.map((item, index) => {
|
|
|
+ if (item.currentStlCurCode == 'CNY') {
|
|
|
|
|
|
- item.currentStlAmount = item.currentStlAmountRMB
|
|
|
- console.log(1, item.currentStlAmount, item.currentStlAmountRMB)
|
|
|
- } else {
|
|
|
- item.currentStlAmount = item.currentStlAmountUSD
|
|
|
- }
|
|
|
- return item
|
|
|
- })
|
|
|
+ item.currentStlAmount = item.currentStlAmountRMB
|
|
|
+ console.log(1, item.currentStlAmount, item.currentStlAmountRMB)
|
|
|
+ } else {
|
|
|
+ item.currentStlAmount = item.currentStlAmountUSD
|
|
|
+ }
|
|
|
+ return item
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.form.finStlBillsItemsList = this.handleSelectionData.map((item, index) => {
|
|
|
+ if (item.currentStlCurCode == 'CNY') {
|
|
|
+ item.currentStlAmount = item.currentStlAmountRMB
|
|
|
+ } else {
|
|
|
+ item.currentStlAmount = item.currentStlAmountUSD
|
|
|
+ }
|
|
|
+ if (!this.form.id) {
|
|
|
+ delete item.businessType
|
|
|
+ delete item.billDate
|
|
|
+ delete item.accountDc
|
|
|
+ }
|
|
|
+ return item
|
|
|
+ })
|
|
|
+ }
|
|
|
} else {
|
|
|
this.form.finStlBillsItemsList = this.handleSelectionData.map((item, index) => {
|
|
|
if (item.currentStlCurCode == 'CNY') {
|
|
@@ -718,6 +734,7 @@ export default {
|
|
|
})
|
|
|
|
|
|
} else {
|
|
|
+ console.log(3333333333333)
|
|
|
finstlbillsSubmit(this.form).then(res => {
|
|
|
this.$message.success('操作成功');
|
|
|
this.finstlbillsDetailfun(res.data.data.id)
|