|
|
|
@ -1152,6 +1152,7 @@ import {
|
|
|
|
delContract,
|
|
|
|
delContract,
|
|
|
|
checkContractName,
|
|
|
|
checkContractName,
|
|
|
|
updateStatus,
|
|
|
|
updateStatus,
|
|
|
|
|
|
|
|
detailContract
|
|
|
|
} from "@/api/contract/contract";
|
|
|
|
} from "@/api/contract/contract";
|
|
|
|
import { getparameter } from "@/api/system/dictionary";
|
|
|
|
import { getparameter } from "@/api/system/dictionary";
|
|
|
|
import { listdeptNoAuth } from "@/api/system/department";
|
|
|
|
import { listdeptNoAuth } from "@/api/system/department";
|
|
|
|
@ -2253,6 +2254,14 @@ export default {
|
|
|
|
|
|
|
|
|
|
|
|
//采购流程
|
|
|
|
//采购流程
|
|
|
|
async buyProcess(row) {
|
|
|
|
async buyProcess(row) {
|
|
|
|
|
|
|
|
let zijinlaiyuanjuti;
|
|
|
|
|
|
|
|
if (row.to_contracts instanceof Array && row.to_contracts.length > 0) {
|
|
|
|
|
|
|
|
let toContractIds = row.to_contracts.map((item) => item.to_contract_id)
|
|
|
|
|
|
|
|
const toContracts = await Promise.all(toContractIds.map((id) => detailContract({ id },true)))
|
|
|
|
|
|
|
|
let plans = toContracts.map(i => (i.plans)).flat()
|
|
|
|
|
|
|
|
zijinlaiyuanjuti = plans.reduce((pre,cur,index)=>(index === 0 ? (`【${cur?.year}】${cur?.name}`) : (pre+`,【${cur?.year}】${cur?.name}`)),"")
|
|
|
|
|
|
|
|
console.log(zijinlaiyuanjuti)
|
|
|
|
|
|
|
|
}
|
|
|
|
this.setNowContract(row, "caigou");
|
|
|
|
this.setNowContract(row, "caigou");
|
|
|
|
let baseInfo = {
|
|
|
|
let baseInfo = {
|
|
|
|
title: row?.name,
|
|
|
|
title: row?.name,
|
|
|
|
@ -2271,7 +2280,7 @@ export default {
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}, ""),
|
|
|
|
}, ""),
|
|
|
|
zijinlaiyuanjuti: row?.plans.reduce((pre,cur,index)=>(index === 0 ? (`【${cur?.year}】${cur?.name}`) : (pre+`,【${cur?.year}】${cur?.name}`)),"")
|
|
|
|
zijinlaiyuanjuti: zijinlaiyuanjuti ? zijinlaiyuanjuti : row?.plans.reduce((pre,cur,index)=>(index === 0 ? (`【${cur?.year}】${cur?.name}`) : (pre+`,【${cur?.year}】${cur?.name}`)),"")
|
|
|
|
};
|
|
|
|
};
|
|
|
|
console.log(baseInfo.zijinlaiyuanjuti)
|
|
|
|
console.log(baseInfo.zijinlaiyuanjuti)
|
|
|
|
// let res = await getOatoken()
|
|
|
|
// let res = await getOatoken()
|
|
|
|
|