|
@@ -212,12 +212,14 @@ async function getAllPagesCommon(construct_id, user_id, prj_id, prj_ids, rpt_id,
|
|
let promiseArr = [null, null, null];
|
|
let promiseArr = [null, null, null];
|
|
if (summaryRst.length > 0) {
|
|
if (summaryRst.length > 0) {
|
|
if (summaryRst.indexOf(`Budget`) >= 0 || summaryRst.indexOf(`BudgetDetail`) >= 0) {
|
|
if (summaryRst.indexOf(`Budget`) >= 0 || summaryRst.indexOf(`BudgetDetail`) >= 0) {
|
|
- if (flag.budgetSumType && flag.budgetSumType === 'budget_single') {
|
|
|
|
- //单项工程
|
|
|
|
- promiseArr[0] = bill_facade.getSinglesBudgetSummary(construct_id); //与其他汇总类的请求互斥,不能同时出现!
|
|
|
|
- } else {
|
|
|
|
- promiseArr[0] = bill_facade.getBudgetSummary(construct_id); //与其他汇总类的请求互斥,不能同时出现!
|
|
|
|
- }
|
|
|
|
|
|
+ promiseArr[0] = bill_facade.getBudgetSummary(construct_id); //与其他汇总类的请求互斥,不能同时出现!
|
|
|
|
+ // if (flag.budgetSumType && flag.budgetSumType === 'budget_construct') {
|
|
|
|
+ // //建设项目level
|
|
|
|
+ // promiseArr[0] = bill_facade.getBudgetSummary(construct_id); //与其他汇总类的请求互斥,不能同时出现!
|
|
|
|
+ // } else {
|
|
|
|
+ // //单项工程level
|
|
|
|
+ // promiseArr[0] = bill_facade.getSinglesBudgetSummary(construct_id); //与其他汇总类的请求互斥,不能同时出现!
|
|
|
|
+ // }
|
|
}
|
|
}
|
|
if (summaryRst.indexOf(`Construct`) >= 0 || summaryRst.indexOf(`ConstructDetail`) >= 0) {
|
|
if (summaryRst.indexOf(`Construct`) >= 0 || summaryRst.indexOf(`ConstructDetail`) >= 0) {
|
|
promiseArr[0] = pm_facade.getSummaryInfoByTender(prj_id, pm_facade.projectType.project);
|
|
promiseArr[0] = pm_facade.getSummaryInfoByTender(prj_id, pm_facade.projectType.project);
|
|
@@ -402,10 +404,11 @@ async function getAllPagesCommon(construct_id, user_id, prj_id, prj_ids, rpt_id,
|
|
rawDataObj.BudgetCalcTypeDetail = [];
|
|
rawDataObj.BudgetCalcTypeDetail = [];
|
|
for (let doc of rst) {
|
|
for (let doc of rst) {
|
|
for (let calc of doc.calcPrograms) {
|
|
for (let calc of doc.calcPrograms) {
|
|
- rawDataObj.BudgetCalcType.push({projectID: doc.projectID, name: calc.name, totalFee: calc.totalFee});
|
|
|
|
|
|
+ rawDataObj.BudgetCalcType.push({projectID: doc.projectID, bID: (doc.projectID + '_' + calc.ID), name: calc.name, totalFee: calc.totalFee});
|
|
if (calc.calcItems && calc.calcItems.length > 0) {
|
|
if (calc.calcItems && calc.calcItems.length > 0) {
|
|
for (let cdtlItem of calc.calcItems) {
|
|
for (let cdtlItem of calc.calcItems) {
|
|
cdtlItem.projectID = doc.projectID; //额外加的所属projectID
|
|
cdtlItem.projectID = doc.projectID; //额外加的所属projectID
|
|
|
|
+ cdtlItem.bID = (doc.projectID + '_' + calc.ID); //额外加的所属父节点ID,projectID + calc本身ID
|
|
rawDataObj.BudgetCalcTypeDetail.push(cdtlItem);
|
|
rawDataObj.BudgetCalcTypeDetail.push(cdtlItem);
|
|
}
|
|
}
|
|
// rawDataObj.BudgetCalcTypeDetail.push(calc.calcItems);
|
|
// rawDataObj.BudgetCalcTypeDetail.push(calc.calcItems);
|