|
|
|
|
@ -628,6 +628,7 @@ import addContractLedger from '@/views/contract/components/addContractLedger.vue
|
|
|
|
|
import EditContract from './components/EditContract.vue'
|
|
|
|
|
import { show } from "@/api/away";
|
|
|
|
|
import {flowStatusConfig} from "@/api/common";
|
|
|
|
|
import {getFundLog} from "@/api/paymentRegistration/fundLog";
|
|
|
|
|
let iframe;
|
|
|
|
|
export default {
|
|
|
|
|
components: {
|
|
|
|
|
@ -1676,24 +1677,38 @@ export default {
|
|
|
|
|
//付款流程
|
|
|
|
|
async paying(row) {
|
|
|
|
|
// 75
|
|
|
|
|
let payments = [];
|
|
|
|
|
const actNumsTotal = () => {
|
|
|
|
|
return payments.reduce((pre,cur) => {
|
|
|
|
|
return pre + (!!Number(cur.act_money) ? Number(cur.act_money) : 0);
|
|
|
|
|
},0);
|
|
|
|
|
};
|
|
|
|
|
let contract;
|
|
|
|
|
if (row.contract_id) {
|
|
|
|
|
contract = await detailContract({ id: row.contract_id });
|
|
|
|
|
} else {
|
|
|
|
|
contract = await show({ id: row.away_id });
|
|
|
|
|
}
|
|
|
|
|
payments =
|
|
|
|
|
(
|
|
|
|
|
await getFundLog({
|
|
|
|
|
contract_id: row.contract_id,
|
|
|
|
|
show_type: 1
|
|
|
|
|
})
|
|
|
|
|
)?.data || [];
|
|
|
|
|
let baseInfo = {
|
|
|
|
|
title: row?.name,
|
|
|
|
|
things: row?.name,
|
|
|
|
|
"contractno": row?.number,
|
|
|
|
|
out_pay_id: row?.out_pay_id,
|
|
|
|
|
"xiangxishuoming": row?.reason,
|
|
|
|
|
"cishu": row?.yizhifucishu,
|
|
|
|
|
"yifujine": row?.yizhifujine,
|
|
|
|
|
"xiangmuzonge": row?.zongjia,
|
|
|
|
|
"zhifucishu": row?.zhifucishu,
|
|
|
|
|
"amt": row?.applyMoney,
|
|
|
|
|
"liezhiqudao": contract?.plans.map(i => i.name)?.toString()
|
|
|
|
|
"oaUrl": row?.contract?.number,
|
|
|
|
|
"zhifutitle": contract?.name,
|
|
|
|
|
out_pay_id: row?.id,
|
|
|
|
|
"xiangxishuoming": row?.remark,
|
|
|
|
|
"yifujine": actNumsTotal(),
|
|
|
|
|
"xiangmuzonge": contract.money,
|
|
|
|
|
"zhifucishu": contract?.sign_plan?.length,
|
|
|
|
|
"cishu": payments.length,
|
|
|
|
|
"amt": row?.apply_money,
|
|
|
|
|
"liezhiqudao": contract?.plans.map(i => i.name)?.toString(),
|
|
|
|
|
"contractno": contract?.number,
|
|
|
|
|
"guanlianliucheng": contract?.contract_flow_links?.map(i => i.flow_id)
|
|
|
|
|
};
|
|
|
|
|
let url = `${process.env.VUE_APP_OUT_OLD}/#/flow/create?auth_token=${window.encodeURIComponent(getToken())}&module_name=oa&isSinglePage=1&module_id=75&out_away_id=${row.id}&default_json=${JSON.stringify(baseInfo)}`;
|
|
|
|
|
|
|
|
|
|
|