diff --git a/package.json b/package.json index f56ee93..c85669a 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,7 @@ "author": "Pan ", "scripts": { "dev": "vue-cli-service serve", + "dev:prod": "vue-cli-service serve --mode production", "build:prod": "vue-cli-service build", "build:stage": "vue-cli-service build --mode staging", "preview": "node build/index.js --preview", diff --git a/src/views/away/component/examineAway.vue b/src/views/away/component/examineAway.vue index a47f14f..5a697d0 100644 --- a/src/views/away/component/examineAway.vue +++ b/src/views/away/component/examineAway.vue @@ -2,7 +2,7 @@
*申请付款金额 + >确认金额
@@ -233,6 +233,7 @@ import {deepCopy, parseTime} from "@/utils"; import {getOatoken} from "@/api/oatoken"; import {listdeptNoAuth} from "@/api/system/department"; import { save } from "@/api/away"; +import {httpCurl} from "@/api/out"; export default { data() { @@ -357,6 +358,17 @@ export default { } }, + async getOaApplyMoney() { + let url = `${process.env.VUE_APP_OUT_URL}/flow/view/${this.contract.expense_flow_id}` + const res = await httpCurl({ auth_token: this.$store.getters.oa_token ,get_raw:1 },true,"/Api/flowDetail", "GET",url) + try { + const data = JSON.parse(res.flow['出差报销明细'])[0] + this.paymentRegistrationForm.applyMoney = data['tAmt'] + } catch (err) { + console.error(err) + } + + }, async getPlanTypes() { const res = await getparameterTree({ id: 3 @@ -582,6 +594,7 @@ export default { isShowPaymentRegistration(newVal) { if (newVal) { this.getBudgets(); + this.getOaApplyMoney(); if (this.type === "detail") { this.getDetail() diff --git a/src/views/finance/components/examineRegistration.vue b/src/views/finance/components/examineRegistration.vue index aa5aefa..9ed2c38 100644 --- a/src/views/finance/components/examineRegistration.vue +++ b/src/views/finance/components/examineRegistration.vue @@ -562,7 +562,7 @@ import {listdeptNoAuth} from "@/api/system/department"; }) this.paymentRegistrationForm.type = res.type this.paymentRegistrationForm.isLast = res.is_end === 1 - this.paymentRegistrationForm.deductionMoney = res.discount_money + this.paymentRegistrationForm.deductionMoney = res.discount_money || res.apply_money this.paymentRegistrationForm.applyMoney = res.apply_money this.paymentRegistrationForm.remark = res.remark for (var m of res.plan_link) { @@ -571,10 +571,10 @@ import {listdeptNoAuth} from "@/api/system/department"; this.paymentRegistrationForm.plan = res.plan_link this.paymentRegistrationForm.actMoney = res.apply_money - this.paymentRegistrationForm.moneyWay = res.money_way_id?.split(',').map(item => Number(item)) + this.paymentRegistrationForm.moneyWay = res.money_way_id ? res.money_way_id?.split(',').map(item => Number(item)) : [Number(res.contract?.money_way_id)] await this.getContract(res.contract) - await this.moneyWayChange() + await this.moneyWayChange(this.paymentRegistrationForm.moneyWay) }, //获取合同信息 diff --git a/src/views/system/workerComponents/toDo.vue b/src/views/system/workerComponents/toDo.vue index ba78e4e..581a007 100644 --- a/src/views/system/workerComponents/toDo.vue +++ b/src/views/system/workerComponents/toDo.vue @@ -149,12 +149,17 @@ export default { on: { ["click"]: (_) => { if(row.from_type === 'contract') { - this.$router.push({ + let toUrl = this.$router.resolve({ path: '/contract/contract/contractList', query: { keyword:/\[(.*?)\]/.exec(row.title) ? /\[(.*?)\]/.exec(row.title)[1] : '' } }) + window.open( + toUrl.href, + "edit", + `top=${this.window.top},left=${this.window.left},width=${this.window.width},height=${this.window.height},location=0` + ); } else { window.open( `${process.env.VUE_APP_OUT_OLD}/flow/deal/${row.id}?auth_token=${this.$store.getters.oa_token}`,