|
@@ -273,6 +273,8 @@ module.exports = app => {
|
|
|
project_id: tender.data.project_id,
|
|
|
tender_id: tender.id,
|
|
|
tender_name: tender.data.name,
|
|
|
+ budget_id: -1,
|
|
|
+ sp_id: -1,
|
|
|
detail_id: -1,
|
|
|
stg_id: stage_id,
|
|
|
stg_order: stage_order,
|
|
@@ -308,6 +310,7 @@ module.exports = app => {
|
|
|
OSS_PATH: ctx.app.config.fujianOssPath,
|
|
|
viewPmData: PermissionCheck.viewPmData(this.ctx.session.sessionUser.permission),
|
|
|
auditType: auditConst.auditType,
|
|
|
+ source_type: 1,
|
|
|
};
|
|
|
await this.layout('report/index.ejs', renderData, 'report/rpt_all_popup.ejs');
|
|
|
// await this.layout('report/index.ejs', renderData);
|
|
@@ -456,6 +459,8 @@ module.exports = app => {
|
|
|
tender_name: tender.name,
|
|
|
detail_id: paymentDetail_id,
|
|
|
stg_id: stage_id,
|
|
|
+ budget_id: -1,
|
|
|
+ sp_id: -1,
|
|
|
stg_order: stage_order,
|
|
|
cur_order: sorder,
|
|
|
stg_times: stage_times,
|
|
@@ -487,6 +492,7 @@ module.exports = app => {
|
|
|
prePay: JSON.stringify(advance),
|
|
|
OSS_PATH: ctx.app.config.fujianOssPath,
|
|
|
viewPmData: PermissionCheck.viewPmData(this.ctx.session.sessionUser.permission),
|
|
|
+ source_type: 101,
|
|
|
};
|
|
|
/*
|
|
|
//*/
|
|
@@ -509,6 +515,9 @@ module.exports = app => {
|
|
|
const paymentDetail_id = -1;
|
|
|
// const tender = ctx.paymentTender;
|
|
|
const pid = ctx.budget.pid;
|
|
|
+ const budget_id = ctx.budget.id;
|
|
|
+ const subProj = await ctx.service.subProject.getDataByCondition({ budget_id });
|
|
|
+ const sp_id = subProj.id;
|
|
|
const treeNodes = await ctx.service.rptTreeNode.getNodesBySourceType([pid], 200); // 这个查定制的
|
|
|
const commonTreeNodes = await ctx.service.rptTreeNode.getNodesByProjectId([-1]); // 这个查通用的
|
|
|
const nodeItems = JSON.parse(commonTreeNodes[0].items);
|
|
@@ -619,6 +628,8 @@ module.exports = app => {
|
|
|
cust_cfg: JSON.stringify(custCfg),
|
|
|
project_id: pid,
|
|
|
tender_id: tenderId,
|
|
|
+ budget_id,
|
|
|
+ sp_id,
|
|
|
tender_name: '',
|
|
|
detail_id: paymentDetail_id,
|
|
|
stg_id: stage_id,
|
|
@@ -653,6 +664,7 @@ module.exports = app => {
|
|
|
prePay: JSON.stringify(advance),
|
|
|
OSS_PATH: ctx.app.config.fujianOssPath,
|
|
|
viewPmData: PermissionCheck.viewPmData(this.ctx.session.sessionUser.permission),
|
|
|
+ source_type: 200,
|
|
|
};
|
|
|
await this.layout('report/index.ejs', renderData, 'report/rpt_all_popup.ejs');
|
|
|
|
|
@@ -707,7 +719,7 @@ module.exports = app => {
|
|
|
if (!rptTpl || rptTpl.length !== 1) {
|
|
|
throw '获取模板失败';
|
|
|
}
|
|
|
- const source_type = rptTpl[0].source_type;
|
|
|
+ const source_type = params.source_type ? params.source_type : rptTpl[0].source_type;
|
|
|
rptTpl = JSON.parse(rptTpl[0].rpt_content);
|
|
|
rptTpl.source_type = source_type || sourceTypeConst.defaultSourceType;
|
|
|
rptTpl.id = params.rpt_tpl_id;
|