解决单据关联跳转的时候优化金额计算精度的问题
This commit is contained in:
@@ -127,7 +127,7 @@
|
||||
selectType: 'list',
|
||||
linkNumber: '',
|
||||
organId: '',
|
||||
discount: '',
|
||||
discountMoney: '',
|
||||
deposit: '',
|
||||
remark: '',
|
||||
queryParam: {
|
||||
@@ -261,7 +261,7 @@
|
||||
let record = this.selectBillRows[0]
|
||||
this.linkNumber = record.number
|
||||
this.organId = record.organId
|
||||
this.discount = record.discount
|
||||
this.discountMoney = record.discountMoney
|
||||
this.deposit = record.changeAmount - record.finishDeposit
|
||||
this.remark = record.remark
|
||||
this.loadDetailData(1)
|
||||
@@ -269,7 +269,7 @@
|
||||
} else {
|
||||
if(this.selectedDetailRowKeys.length) {
|
||||
this.getSelectBillDetailRows()
|
||||
this.$emit('ok', this.selectBillDetailRows, this.linkNumber, this.organId, this.discount, this.deposit, this.remark)
|
||||
this.$emit('ok', this.selectBillDetailRows, this.linkNumber, this.organId, this.discountMoney, this.deposit, this.remark)
|
||||
this.close()
|
||||
} else {
|
||||
this.$message.warning('抱歉,请选择单据明细!')
|
||||
|
||||
@@ -379,7 +379,7 @@
|
||||
this.$refs.linkBillList.show('入库', '采购', '供应商', "1")
|
||||
this.$refs.linkBillList.title = "选择采购入库"
|
||||
},
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discount, deposit, remark) {
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discountMoney, deposit, remark) {
|
||||
this.rowCanEdit = false
|
||||
this.backStatus = false
|
||||
this.materialTable.columns[1].type = FormTypes.normal
|
||||
@@ -405,7 +405,7 @@
|
||||
this.materialTable.dataSource = listEx
|
||||
///给优惠后金额重新赋值
|
||||
allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0
|
||||
let discountMoney = (discount*allTaxLastMoney/100).toFixed(2)-0
|
||||
let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0
|
||||
let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0
|
||||
this.$nextTick(() => {
|
||||
this.form.setFieldsValue({
|
||||
|
||||
@@ -424,7 +424,7 @@
|
||||
this.$refs.linkBillList.show('其它', '采购订单', '供应商', "1,3")
|
||||
this.$refs.linkBillList.title = "选择采购订单"
|
||||
},
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discount, deposit, remark) {
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discountMoney, deposit, remark) {
|
||||
this.rowCanEdit = false
|
||||
this.materialTable.columns[1].type = FormTypes.normal
|
||||
this.changeFormTypes(this.materialTable.columns, 'preNumber', 1)
|
||||
@@ -449,7 +449,7 @@
|
||||
this.materialTable.dataSource = listEx
|
||||
///给优惠后金额重新赋值
|
||||
allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0
|
||||
let discountMoney = (discount*allTaxLastMoney/100).toFixed(2)-0
|
||||
let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0
|
||||
let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0
|
||||
let changeAmount = discountLastMoney
|
||||
if(deposit) {
|
||||
|
||||
@@ -375,7 +375,7 @@
|
||||
this.$refs.linkBillList.show('出库', '零售', '会员', "1")
|
||||
this.$refs.linkBillList.title = "选择零售出库"
|
||||
},
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discount, deposit, remark) {
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discountMoney, deposit, remark) {
|
||||
this.rowCanEdit = false
|
||||
this.materialTable.columns[1].type = FormTypes.normal
|
||||
this.changeFormTypes(this.materialTable.columns, 'preNumber', 1)
|
||||
|
||||
@@ -390,7 +390,7 @@
|
||||
this.$refs.linkBillList.show('出库', '销售', '客户', "1")
|
||||
this.$refs.linkBillList.title = "选择销售出库"
|
||||
},
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discount, deposit, remark) {
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discountMoney, deposit, remark) {
|
||||
this.rowCanEdit = false
|
||||
this.backStatus = false
|
||||
this.materialTable.columns[1].type = FormTypes.normal
|
||||
@@ -416,7 +416,7 @@
|
||||
this.materialTable.dataSource = listEx
|
||||
///给优惠后金额重新赋值
|
||||
allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0
|
||||
let discountMoney = (discount*allTaxLastMoney/100).toFixed(2)-0
|
||||
let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0
|
||||
let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0
|
||||
this.$nextTick(() => {
|
||||
this.form.setFieldsValue({
|
||||
|
||||
@@ -442,7 +442,7 @@
|
||||
this.$refs.linkBillList.show('其它', '销售订单', '客户', "1,3")
|
||||
this.$refs.linkBillList.title = "选择销售订单"
|
||||
},
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discount, deposit, remark) {
|
||||
linkBillListOk(selectBillDetailRows, linkNumber, organId, discountMoney, deposit, remark) {
|
||||
this.rowCanEdit = false
|
||||
this.materialTable.columns[1].type = FormTypes.normal
|
||||
this.changeFormTypes(this.materialTable.columns, 'preNumber', 1)
|
||||
@@ -467,7 +467,7 @@
|
||||
this.materialTable.dataSource = listEx
|
||||
///给优惠后金额重新赋值
|
||||
allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0
|
||||
let discountMoney = (discount*allTaxLastMoney/100).toFixed(2)-0
|
||||
let discount = (discountMoney/allTaxLastMoney*100).toFixed(2)-0
|
||||
let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0
|
||||
let changeAmount = discountLastMoney
|
||||
if(deposit) {
|
||||
|
||||
Reference in New Issue
Block a user