|
@@ -335,7 +335,7 @@ INTERFACE_EXPORT = (() => {
|
|
|
}
|
|
}
|
|
|
return node.data.code;
|
|
return node.data.code;
|
|
|
}
|
|
}
|
|
|
- function GongCLQDMX(node) {
|
|
|
|
|
|
|
+ function GongCLQDMX(node, lnStr) {
|
|
|
const { mainFee, assFee } = getMaterialFee(node);
|
|
const { mainFee, assFee } = getMaterialFee(node);
|
|
|
const billDataType = getBillDataType(node);
|
|
const billDataType = getBillDataType(node);
|
|
|
let unitFee = 0;
|
|
let unitFee = 0;
|
|
@@ -351,7 +351,8 @@ INTERFACE_EXPORT = (() => {
|
|
|
'100', '200', '300', '400', '500', '600', '700', '800', '900', '1000', '1100',
|
|
'100', '200', '300', '400', '500', '600', '700', '800', '900', '1000', '1100',
|
|
|
'1200', '1300', '1400', '1500', '1600', '1700', '1800', '1900', '2000',
|
|
'1200', '1300', '1400', '1500', '1600', '1700', '1800', '1900', '2000',
|
|
|
]},
|
|
]},
|
|
|
- {name: '子目长编号', value: divideObj.getExeBillCode(node.data.ID, node. tree)},
|
|
|
|
|
|
|
+ // {name: '子目长编号', value: divideObj.getExeBillCode(node.data.ID, node. tree)},
|
|
|
|
|
+ {name: '子目长编号', value: lnStr},
|
|
|
{name: '子目号', value: getBillCode(node), minLen: 1},
|
|
{name: '子目号', value: getBillCode(node), minLen: 1},
|
|
|
{name: '子目名称', value: node.data.name, minLen: 1},
|
|
{name: '子目名称', value: node.data.name, minLen: 1},
|
|
|
{name: '单位', value: node.data.unit},
|
|
{name: '单位', value: node.data.unit},
|
|
@@ -475,13 +476,19 @@ INTERFACE_EXPORT = (() => {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
- function ZJHZMX(node) {
|
|
|
|
|
|
|
+ function ZJHZMX(node, index = 0, isOneSeven) {
|
|
|
|
|
+ let chaptNo = getSection(node);
|
|
|
|
|
+ let lb = getLB(node);
|
|
|
|
|
+ if (isOneSeven) {
|
|
|
|
|
+ chaptNo = `${(index + 1) * 100}`;
|
|
|
|
|
+ lb = chaptNo;
|
|
|
|
|
+ }
|
|
|
const attrs = [
|
|
const attrs = [
|
|
|
{name: '序号', value: hzSeq++ },
|
|
{name: '序号', value: hzSeq++ },
|
|
|
- {name: '章次', value: getSection(node) },
|
|
|
|
|
|
|
+ {name: '章次', value: chaptNo },
|
|
|
{name: '名称', value: node.data.name, minLen: 1 },
|
|
{name: '名称', value: node.data.name, minLen: 1 },
|
|
|
{name: '金额', value: getFee(node.data.fees, 'common.tenderTotalFee'), type: TYPE.DECIMAL },
|
|
{name: '金额', value: getFee(node.data.fees, 'common.tenderTotalFee'), type: TYPE.DECIMAL },
|
|
|
- {name: '类别', value: getLB(node) },
|
|
|
|
|
|
|
+ {name: '类别', value: lb },
|
|
|
{name: '备注', value: node.data.remark },
|
|
{name: '备注', value: node.data.remark },
|
|
|
|
|
|
|
|
];
|
|
];
|
|
@@ -600,10 +607,14 @@ INTERFACE_EXPORT = (() => {
|
|
|
/* 生成工程量清单表 */
|
|
/* 生成工程量清单表 */
|
|
|
function createGCLQD() {
|
|
function createGCLQD() {
|
|
|
// 设置工程量清单明细
|
|
// 设置工程量清单明细
|
|
|
- function setupGCLQDMX(nodes) {
|
|
|
|
|
|
|
+ function setupGCLQDMX(nodes, longNoStr = '') {
|
|
|
const rst = [];
|
|
const rst = [];
|
|
|
- nodes.forEach(node => {
|
|
|
|
|
- const glcqdmx = new GongCLQDMX(node);
|
|
|
|
|
|
|
+ nodes.forEach((node, index) => {
|
|
|
|
|
+ let lnStr = longNoStr;
|
|
|
|
|
+ if (longNoStr === '') {
|
|
|
|
|
+ lnStr = `${(index + 1) * 100}`;
|
|
|
|
|
+ }
|
|
|
|
|
+ const glcqdmx = new GongCLQDMX(node, lnStr);
|
|
|
rst.push(glcqdmx);
|
|
rst.push(glcqdmx);
|
|
|
if (!node.source.children.length && node.children.length) {
|
|
if (!node.source.children.length && node.children.length) {
|
|
|
// 清单主材表
|
|
// 清单主材表
|
|
@@ -615,7 +626,7 @@ INTERFACE_EXPORT = (() => {
|
|
|
glcqdmx.children.push(...createDEXXB(node));
|
|
glcqdmx.children.push(...createDEXXB(node));
|
|
|
} else {
|
|
} else {
|
|
|
// 子清单
|
|
// 子清单
|
|
|
- glcqdmx.children.push(...setupGCLQDMX(node.children));
|
|
|
|
|
|
|
+ glcqdmx.children.push(...setupGCLQDMX(node.children, lnStr));
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
return rst;
|
|
return rst;
|
|
@@ -697,13 +708,22 @@ INTERFACE_EXPORT = (() => {
|
|
|
const zjhzb = new Element('造价汇总表');
|
|
const zjhzb = new Element('造价汇总表');
|
|
|
// 提取需要显示的数据
|
|
// 提取需要显示的数据
|
|
|
const nodes = [];
|
|
const nodes = [];
|
|
|
|
|
+ let oneSevenMin = -1, oneSevenMax = -1;
|
|
|
curTender.mainTree.roots.forEach(node => {
|
|
curTender.mainTree.roots.forEach(node => {
|
|
|
nodes.push(node);
|
|
nodes.push(node);
|
|
|
if (node.getFlag() === fixedFlag.ONE_SEVEN_BILLS) {
|
|
if (node.getFlag() === fixedFlag.ONE_SEVEN_BILLS) {
|
|
|
|
|
+ oneSevenMin = nodes.length;
|
|
|
nodes.push(...node.children);
|
|
nodes.push(...node.children);
|
|
|
|
|
+ oneSevenMax = nodes.length - 1;
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
- zjhzb.children = nodes.map(node => new ZJHZMX(node));
|
|
|
|
|
|
|
+ // zjhzb.children = nodes.map(node => new ZJHZMX(node));
|
|
|
|
|
+ let startIdx = 0;
|
|
|
|
|
+ nodes.forEach((node, index) => {
|
|
|
|
|
+ const isOneSeven = index >= oneSevenMin && index <= oneSevenMax
|
|
|
|
|
+ zjhzb.children.push(new ZJHZMX(node, startIdx, isOneSeven));
|
|
|
|
|
+ if (isOneSeven) startIdx++;
|
|
|
|
|
+ });
|
|
|
return zjhzb;
|
|
return zjhzb;
|
|
|
}
|
|
}
|
|
|
|
|
|