| | |
| | | <el-date-picker |
| | | v-model="form.taxedtime" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="datetime" |
| | | type="datetime" format="yyyy-MM-dd HH:mm" |
| | | :disabled="true" |
| | | placeholder="选择时间" |
| | | > |
| | |
| | | import Li_area_select from "@/components/Address"; |
| | | import { getUserProfile } from "@/api/system/user"; |
| | | import { getToken } from "@/utils/auth"; |
| | | import { moneySum, moneyRound } from "@/utils/money"; |
| | | import { |
| | | ExpertfeeListnb, |
| | | getFundtax, |
| | |
| | | handleUploadError() {}, |
| | | // 弹框添加 |
| | | AddDispatchpatients() { |
| | | this.donorchargeorgans = this.donorchargeorgans.concat(this.overallCase); |
| | | console.log(this.donorchargeorgans, "donorchargeorgans"); |
| | | this.donorchargeorgans.forEach(item => { |
| | | CalculationDetail({ id: item.id, fundTaxId: this.form.id }); |
| | | let newArr = this.donorchargeorgans.concat(this.overallCase); |
| | | this.donorchargeorgans = newArr.filter((item, index, self) => { |
| | | return !self.slice(index + 1).some(other => other.id === item.id); |
| | | }); |
| | | |
| | | console.log(this.donorchargeorgans, "donorchargeorgans"); |
| | | if (this.form.id) { |
| | | this.donorchargeorgans.forEach(item => { |
| | | CalculationDetail({ id: item.id, fundTaxId: this.form.id }); |
| | | }); |
| | | } |
| | | this.donorchargeorgans.forEach(item => { |
| | | item.taXmoney = item.pretaxcost - item.taxedcost; |
| | | item.taXmoney = item.taXmoney.toFixed(2); |
| | |
| | | if (this.multipleSelection.length <= selection.length) { |
| | | this.multipleSelection = selection; |
| | | } else { |
| | | console.log(11); |
| | | this.multipleSelection.forEach(item => { |
| | | if (selection.includes(item)) { |
| | | } else { |
| | |
| | | this.$modal.msgError("注意实收金额不等于应收金额,请核对数据!"); |
| | | } |
| | | }, |
| | | //修改实收或应收后触发 |
| | | //修改实收或应收后触发(金额一律走精确运算) |
| | | chargeSum() { |
| | | let ChargeSum = 0; |
| | | let ChargeamountSum = 0; |
| | | |
| | | //费用合计 |
| | | try { |
| | | for (let i = 0; i < this.donorchargeorgans.length; i++) { |
| | | if (!isNaN(parseFloat(this.donorchargeorgans[i].organcharge))) { |
| | | ChargeSum += parseFloat(this.donorchargeorgans[i].organcharge); |
| | | } |
| | | if (!isNaN(parseFloat(this.donorchargeorgans[i].amount))) { |
| | | ChargeamountSum += parseFloat(this.donorchargeorgans[i].amount); |
| | | } |
| | | } |
| | | this.form.receivableamount = ChargeSum.toFixed(2); |
| | | this.form.receivedamount = ChargeamountSum.toFixed(2); |
| | | this.form.receivableamount = moneyRound( |
| | | moneySum(this.donorchargeorgans, "organcharge") |
| | | ).toFixed(2); |
| | | this.form.receivedamount = moneyRound( |
| | | moneySum(this.donorchargeorgans, "amount") |
| | | ).toFixed(2); |
| | | } catch {} |
| | | }, |
| | | |