|
@@ -0,0 +1,355 @@
|
|
|
+'use strict';
|
|
|
+
|
|
|
+/**
|
|
|
+ *
|
|
|
+ *
|
|
|
+ * @author Mai
|
|
|
+ * @date
|
|
|
+ * @version
|
|
|
+ */
|
|
|
+
|
|
|
+const Ledger = require('../lib/ledger');
|
|
|
+const auditConst = require('../const/audit');
|
|
|
+const moment = require('moment');
|
|
|
+const indexPre = 'id_';
|
|
|
+
|
|
|
+const gatherUtils = {
|
|
|
+ gatherStage: function (tender, gatherNode, sourceNode, prefix, helper) {
|
|
|
+ gatherNode[prefix + 'id'] = tender.id;
|
|
|
+ gatherNode[prefix + 'name'] = tender.name;
|
|
|
+
|
|
|
+ gatherNode[prefix + "qty"] = helper.add(gatherNode[prefix + "qty"], sourceNode.quantity);
|
|
|
+ gatherNode[prefix + "tp"] = helper.add(gatherNode[prefix + "tp"], sourceNode.total_price);
|
|
|
+
|
|
|
+ gatherNode[prefix + "contract_qty"] = helper.add(gatherNode[prefix + "contract_qty"], sourceNode.contract_qty);
|
|
|
+ gatherNode[prefix + "contract_tp"] = helper.add(gatherNode[prefix + "contract_tp"], sourceNode.contract_tp);
|
|
|
+ gatherNode[prefix + "qc_qty"] = helper.add(gatherNode[prefix + "qc_qty"], sourceNode.qc_qty);
|
|
|
+ gatherNode[prefix + "qc_tp"] = helper.add(gatherNode[prefix + "qc_tp"], sourceNode.qc_tp);
|
|
|
+ gatherNode[prefix + "gather_qty"] = helper.add(gatherNode[prefix + "gather_qty"], sourceNode.gather_qty);
|
|
|
+ gatherNode[prefix + "gather_tp"] = helper.add(gatherNode[prefix + "gather_tp"], sourceNode.gather_tp);
|
|
|
+
|
|
|
+ gatherNode[prefix + "pre_contract_qty"] = helper.add(gatherNode[prefix + "pre_contract_qty"], sourceNode.pre_contract_qty);
|
|
|
+ gatherNode[prefix + "pre_contract_tp"] = helper.add(gatherNode[prefix + "pre_contract_tp"], sourceNode.pre_contract_tp);
|
|
|
+ gatherNode[prefix + "pre_qc_qty"] = helper.add(gatherNode[prefix + "pre_qc_qty"], sourceNode.pre_qc_qty);
|
|
|
+ gatherNode[prefix + "pre_qc_tp"] = helper.add(gatherNode[prefix + "pre_qc_tp"], sourceNode.pre_qc_tp);
|
|
|
+ gatherNode[prefix + "pre_gather_qty"] = helper.add(gatherNode[prefix + "pre_gather_qty"], sourceNode.pre_gather_qty);
|
|
|
+ gatherNode[prefix + "pre_gather_tp"] = helper.add(gatherNode[prefix + "pre_gather_tp"], sourceNode.pre_gather_tp);
|
|
|
+
|
|
|
+ gatherNode[prefix + "end_contract_qty"] = helper.add(gatherNode[prefix + "end_contract_qty"], sourceNode.end_contract_qty);
|
|
|
+ gatherNode[prefix + "end_contract_tp"] = helper.add(gatherNode[prefix + "end_contract_tp"], sourceNode.end_contract_tp);
|
|
|
+ gatherNode[prefix + "end_qc_qty"] = helper.add(gatherNode[prefix + "end_qc_qty"], sourceNode.end_qc_qty);
|
|
|
+ gatherNode[prefix + "end_qc_tp"] = helper.add(gatherNode[prefix + "end_qc_tp"], sourceNode.end_qc_tp);
|
|
|
+ gatherNode[prefix + "end_gather_qty"] = helper.add(gatherNode[prefix + "end_gather_qty"], sourceNode.end_gather_qty);
|
|
|
+ gatherNode[prefix + "end_gather_tp"] = helper.add(gatherNode[prefix + "end_gather_tp"], sourceNode.end_gather_tp);
|
|
|
+
|
|
|
+ gatherNode['s_' + "qty"] = helper.add(gatherNode['s_' + "qty"], sourceNode.quantity);
|
|
|
+ gatherNode['s_' + "tp"] = helper.add(gatherNode['s_' + "tp"], sourceNode.total_price);
|
|
|
+
|
|
|
+ gatherNode['s_' + "contract_qty"] = helper.add(gatherNode['s_' + "contract_qty"], sourceNode.contract_qty);
|
|
|
+ gatherNode['s_' + "contract_tp"] = helper.add(gatherNode['s_' + "contract_tp"], sourceNode.contract_tp);
|
|
|
+ gatherNode['s_' + "qc_qty"] = helper.add(gatherNode['s_' + "qc_qty"], sourceNode.qc_qty);
|
|
|
+ gatherNode['s_' + "qc_tp"] = helper.add(gatherNode['s_' + "qc_tp"], sourceNode.qc_tp);
|
|
|
+ gatherNode['s_' + "gather_qty"] = helper.add(gatherNode['s_' + "gather_qty"], sourceNode.gather_qty);
|
|
|
+ gatherNode['s_' + "gather_tp"] = helper.add(gatherNode['s_' + "gather_tp"], sourceNode.gather_tp);
|
|
|
+
|
|
|
+ gatherNode['s_' + "pre_contract_qty"] = helper.add(gatherNode['s_' + "pre_contract_qty"], sourceNode.pre_contract_qty);
|
|
|
+ gatherNode['s_' + "pre_contract_tp"] = helper.add(gatherNode['s_' + "pre_contract_tp"], sourceNode.pre_contract_tp);
|
|
|
+ gatherNode['s_' + "pre_qc_qty"] = helper.add(gatherNode['s_' + "pre_qc_qty"], sourceNode.pre_qc_qty);
|
|
|
+ gatherNode['s_' + "pre_qc_tp"] = helper.add(gatherNode['s_' + "pre_qc_tp"], sourceNode.pre_qc_tp);
|
|
|
+ gatherNode['s_' + "pre_gather_qty"] = helper.add(gatherNode['s_' + "pre_gather_qty"], sourceNode.pre_gather_qty);
|
|
|
+ gatherNode['s_' + "pre_gather_tp"] = helper.add(gatherNode['s_' + "pre_gather_tp"], sourceNode.pre_gather_tp);
|
|
|
+
|
|
|
+ gatherNode['s_' + "end_contract_qty"] = helper.add(gatherNode['s_' + "end_contract_qty"], sourceNode.end_contract_qty);
|
|
|
+ gatherNode['s_' + "end_contract_tp"] = helper.add(gatherNode['s_' + "end_contract_tp"], sourceNode.end_contract_tp);
|
|
|
+ gatherNode['s_' + "end_qc_qty"] = helper.add(gatherNode['s_' + "end_qc_qty"], sourceNode.end_qc_qty);
|
|
|
+ gatherNode['s_' + "end_qc_tp"] = helper.add(gatherNode['s_' + "end_qc_tp"], sourceNode.end_qc_tp);
|
|
|
+ gatherNode['s_' + "end_gather_qty"] = helper.add(gatherNode['s_' + "end_gather_qty"], sourceNode.end_gather_qty);
|
|
|
+ gatherNode['s_' + "end_gather_tp"] = helper.add(gatherNode['s_' + "end_gather_tp"], sourceNode.end_gather_tp);
|
|
|
+ },
|
|
|
+ gatherZone: function (tender, gatherNode, sourceNode, prefix, helper) {
|
|
|
+ gatherNode[prefix + 'id'] = tender.id;
|
|
|
+ gatherNode[prefix + 'name'] = tender.name;
|
|
|
+
|
|
|
+ gatherNode[prefix + "qty"] = helper.add(gatherNode[prefix + "qty"], sourceNode.quantity);
|
|
|
+ gatherNode[prefix + "tp"] = helper.add(gatherNode[prefix + "tp"], sourceNode.total_price);
|
|
|
+
|
|
|
+ gatherNode[prefix + "contract_qty"] = helper.add(gatherNode[prefix + "contract_qty"], sourceNode.contract_qty);
|
|
|
+ gatherNode[prefix + "contract_tp"] = helper.add(gatherNode[prefix + "contract_tp"], sourceNode.contract_tp);
|
|
|
+ gatherNode[prefix + "qc_qty"] = helper.add(gatherNode[prefix + "qc_qty"], sourceNode.qc_qty);
|
|
|
+ gatherNode[prefix + "qc_tp"] = helper.add(gatherNode[prefix + "qc_tp"], sourceNode.qc_tp);
|
|
|
+ gatherNode[prefix + "gather_qty"] = helper.add(gatherNode[prefix + "gather_qty"], sourceNode.gather_qty);
|
|
|
+ gatherNode[prefix + "gather_tp"] = helper.add(gatherNode[prefix + "gather_tp"], sourceNode.gather_tp);
|
|
|
+
|
|
|
+ gatherNode['s_' + "qty"] = helper.add(gatherNode['s_' + "qty"], sourceNode.quantity);
|
|
|
+ gatherNode['s_' + "tp"] = helper.add(gatherNode['s_' + "tp"], sourceNode.total_price);
|
|
|
+
|
|
|
+ gatherNode['s_' + "contract_qty"] = helper.add(gatherNode['s_' + "contract_qty"], sourceNode.contract_qty);
|
|
|
+ gatherNode['s_' + "contract_tp"] = helper.add(gatherNode['s_' + "contract_tp"], sourceNode.contract_tp);
|
|
|
+ gatherNode['s_' + "qc_qty"] = helper.add(gatherNode['s_' + "qc_qty"], sourceNode.qc_qty);
|
|
|
+ gatherNode['s_' + "qc_tp"] = helper.add(gatherNode['s_' + "qc_tp"], sourceNode.qc_tp);
|
|
|
+ gatherNode['s_' + "gather_qty"] = helper.add(gatherNode['s_' + "gather_qty"], sourceNode.gather_qty);
|
|
|
+ gatherNode['s_' + "gather_tp"] = helper.add(gatherNode['s_' + "gather_tp"], sourceNode.gather_tp);
|
|
|
+ },
|
|
|
+ gatherSpecial: function (gatherNode, sourceNode, prefix, helper) {
|
|
|
+ gatherNode[prefix + "qty"] = helper.add(gatherNode[prefix + "qty"], sourceNode.quantity);
|
|
|
+ gatherNode[prefix + "tp"] = helper.add(gatherNode[prefix + "tp"], sourceNode.total_price);
|
|
|
+ },
|
|
|
+};
|
|
|
+
|
|
|
+module.exports = app => {
|
|
|
+ class RptGatherMemory extends app.BaseService {
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 构造函数
|
|
|
+ *
|
|
|
+ * @param {Object} ctx - egg全局context
|
|
|
+ * @return {void}
|
|
|
+ */
|
|
|
+ constructor(ctx) {
|
|
|
+ super(ctx);
|
|
|
+ this.resultTree = new Ledger.gatherTree(ctx, {
|
|
|
+ id: 'id',
|
|
|
+ pid: 'pid',
|
|
|
+ order: 'order',
|
|
|
+ level: 'level',
|
|
|
+ rootId: -1
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ _checkSpecialTender(tender, special) {
|
|
|
+ for (const spec of special) {
|
|
|
+ if (tender[spec.key] === true) return spec.key;
|
|
|
+ }
|
|
|
+ return '';
|
|
|
+ }
|
|
|
+
|
|
|
+ async _gatherStageData(index, tender, stage, hasPre) {
|
|
|
+ const helper = this.ctx.helper;
|
|
|
+ const billsTree = new Ledger.billsTree(this.ctx, {
|
|
|
+ id: 'ledger_id',
|
|
|
+ pid: 'ledger_pid',
|
|
|
+ order: 'order',
|
|
|
+ level: 'level',
|
|
|
+ rootId: -1,
|
|
|
+ keys: ['id', 'tender_id', 'ledger_id'],
|
|
|
+ stageId: 'id',
|
|
|
+ calcFields: ['deal_tp', 'total_price', 'contract_tp', 'qc_tp', 'gather_tp', 'pre_contract_tp', 'pre_qc_tp', 'pre_gather_tp'],
|
|
|
+ calc: function (node) {
|
|
|
+ if (node.children && node.children.length === 0) {
|
|
|
+ node.pre_gather_qty = helper.add(node.pre_contract_qty, node.pre_qc_qty);
|
|
|
+ node.gather_qty = helper.add(node.contract_qty, node.qc_qty);
|
|
|
+ node.end_contract_qty = helper.add(node.pre_contract_qty, node.contract_qty);
|
|
|
+ node.end_qc_qty = helper.add(node.pre_qc_qty, node.qc_qty);
|
|
|
+ node.end_gather_qty = helper.add(node.pre_gather_qty, node.gather_qty);
|
|
|
+ }
|
|
|
+ node.pre_gather_tp = helper.add(node.pre_contract_tp, node.pre_qc_tp);
|
|
|
+ node.gather_tp = helper.add(node.contract_tp, node.qc_tp);
|
|
|
+ node.end_contract_tp = helper.add(node.pre_contract_tp, node.contract_tp);
|
|
|
+ node.end_qc_tp = helper.add(node.pre_qc_tp, node.qc_tp);
|
|
|
+ node.end_gather_tp = helper.add(node.pre_gather_tp, node.gather_tp);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ const billsData = await this.ctx.service.ledger.getData(tender.id);
|
|
|
+ if (stage) {
|
|
|
+ await this.ctx.service.stage.doCheckStage(stage);
|
|
|
+ if (stage.readOnly) {
|
|
|
+ const curStage = await this.ctx.service.stageBills.getAuditorStageData(tender.id,
|
|
|
+ stage.id, stage.curTimes, stage.curOrder);
|
|
|
+ this.ctx.helper.assignRelaData(billsData, [
|
|
|
+ {data: curStage, fields: ['contract_qty', 'contract_tp', 'qc_qty', 'qc_tp'], prefix: '', relaId: 'lid'}
|
|
|
+ ]);
|
|
|
+ } else {
|
|
|
+ const curStage = await this.ctx.service.stageBills.getLastestStageData(tender.id, stage.id);
|
|
|
+ this.ctx.helper.assignRelaData(billsData, [
|
|
|
+ {data: curStage, fields: ['contract_qty', 'contract_tp', 'qc_qty', 'qc_tp'], prefix: '', relaId: 'lid'}
|
|
|
+ ]);
|
|
|
+ }
|
|
|
+ if (hasPre) {
|
|
|
+ const preStage = stage.order > 1 ? await this.ctx.service.stageBillsFinal.getFinalData(tender, stage.order - 1) : [];
|
|
|
+ this.ctx.helper.assignRelaData(posData, [
|
|
|
+ {data: preStage, fields: ['contract_qty', 'qc_qty'], prefix: 'pre_', relaId: 'pid'}
|
|
|
+ ]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ billsTree.loadDatas(billsData);
|
|
|
+ billsTree.calculateAll();
|
|
|
+ this.resultTree.loadGatherTree(billsTree, function (gatherNode, sourceNode) {
|
|
|
+ gatherUtils.gatherStage(tender, gatherNode, sourceNode, 't_' + index + '_', helper);
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ async _gatherMonthData(sTender, index, month, hasPre) {
|
|
|
+ const tender = await this.ctx.service.tender.getCheckTender(sTender.tid);
|
|
|
+ const stage = await this.ctx.service.stage.getDataByCondition({tid: tender.id, s_time: month});
|
|
|
+ await this._gatherStageData(index, tender, stage, hasPre);
|
|
|
+ }
|
|
|
+
|
|
|
+ async _gatherZoneData(sTender, index, zone) {
|
|
|
+ const helper = this.ctx.helper;
|
|
|
+ /**
|
|
|
+ * 汇总并合并 相关数据
|
|
|
+ * @param {Array} index - 主数据
|
|
|
+ * @param {Array[]}rela - 相关数据 {data, fields, prefix, relaId}
|
|
|
+ */
|
|
|
+ const sumAssignRelaData = function (index, rela) {
|
|
|
+ const loadFields = function (datas, fields, prefix, relaId) {
|
|
|
+ for (const d of datas) {
|
|
|
+ const key = indexPre + d[relaId];
|
|
|
+ const m = index[key];
|
|
|
+ if (m) {
|
|
|
+ for (const f of fields) {
|
|
|
+ if (d[f] !== undefined) {
|
|
|
+ m[prefix + f] = helper.add(m[prefix + f], d[f]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ };
|
|
|
+ for (const r of rela) {
|
|
|
+ loadFields(r.data, r.fields, r.prefix, r.relaId);
|
|
|
+ }
|
|
|
+ };
|
|
|
+
|
|
|
+ const billsTree = new Ledger.billsTree(this.ctx, {
|
|
|
+ id: 'ledger_id',
|
|
|
+ pid: 'ledger_pid',
|
|
|
+ order: 'order',
|
|
|
+ level: 'level',
|
|
|
+ rootId: -1,
|
|
|
+ keys: ['id', 'tender_id', 'ledger_id'],
|
|
|
+ stageId: 'id',
|
|
|
+ calcFields: ['deal_tp', 'total_price', 'contract_tp', 'qc_tp', 'gather_tp'],
|
|
|
+ calc: function (node) {
|
|
|
+ if (node.children && node.children.length === 0) {
|
|
|
+ node.gather_qty = helper.add(node.contract_qty, node.qc_qty);
|
|
|
+ }
|
|
|
+ node.gather_tp = helper.add(node.contract_tp, node.qc_tp);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ const tender = await this.ctx.service.tender.getCheckTender(sTender.tid);
|
|
|
+ const billsData = await this.ctx.service.ledger.getData(tender.id);
|
|
|
+
|
|
|
+ let billsIndexData = {};
|
|
|
+ for (const bd of billsData) {
|
|
|
+ billsIndexData[indexPre + bd.id] = bd;
|
|
|
+ }
|
|
|
+
|
|
|
+ const times = zone.split(' - ');
|
|
|
+ if (times.length !== 2) throw '选择的汇总周期无效';
|
|
|
+ const beginTime = moment(times[0], 'YYYY-MM').date();
|
|
|
+ const endTime = moment(times[1], 'YYYY-MM').date();
|
|
|
+
|
|
|
+
|
|
|
+ const stages = await this.ctx.service.stage.getAllDataByCondition({ where: { tid: tender.id } });
|
|
|
+ for (const stage of stages) {
|
|
|
+ const sTime = moment(stage.s_time, 'YYYY-MM').date();
|
|
|
+ if (sTime >= beginTime && sTime <= endTime) {
|
|
|
+ await this.ctx.service.stage.doCheckStage(stage);
|
|
|
+ if (stage.readOnly) {
|
|
|
+ const curStage = await this.ctx.service.stageBills.getAuditorStageData(tender.id,
|
|
|
+ stage.id, stage.curTimes, stage.curOrder);
|
|
|
+ sumAssignRelaData(billsIndexData, [
|
|
|
+ {data: curStage, fields: ['contract_qty', 'contract_tp', 'qc_qty', 'qc_tp'], prefix: '', relaId: 'lid'}
|
|
|
+ ]);
|
|
|
+ } else {
|
|
|
+ const curStage = await this.ctx.service.stageBills.getLastestStageData(tender.id, stage.id);
|
|
|
+ sumAssignRelaData(billsIndexData, [
|
|
|
+ {data: curStage, fields: ['contract_qty', 'contract_tp', 'qc_qty', 'qc_tp'], prefix: '', relaId: 'lid'}
|
|
|
+ ]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ billsTree.loadDatas(billsData);
|
|
|
+ billsTree.calculateAll();
|
|
|
+ this.resultTree.loadGatherTree(billsTree, function (gatherNode, sourceNode) {
|
|
|
+ gatherUtils.gatherZone(gatherNode, sourceNode, 't_' + index + '_', helper);
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ async _gatherFinalData(sTender, index, hasPre) {
|
|
|
+ const tender = await this.ctx.service.tender.getCheckTender(sTender.tid);
|
|
|
+ const stages = await this.db.select(this.tableName, {
|
|
|
+ where: { tid: tender.id },
|
|
|
+ orders: [['order', 'desc']],
|
|
|
+ });
|
|
|
+ if (stages.length !== 0) {
|
|
|
+ const lastStage = stages[stages.length - 1];
|
|
|
+ if (lastStage.status === auditConst.stage.status.uncheck && lastStage.user_id !== this.ctx.session.sessionUser.accountId) {
|
|
|
+ stages.splice(stages.length - 1, 1);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ await this._gatherStageData(index, tender, stages[0], hasPre);
|
|
|
+ }
|
|
|
+
|
|
|
+ async _gatherCheckedFinalData(sTender, index, hasPre) {
|
|
|
+ const tender = await this.ctx.service.tender.getCheckTender(sTender.tid);
|
|
|
+ const stages = await this.db.select(this.tableName, {
|
|
|
+ where: { tid: tender.id },
|
|
|
+ orders: [['order', 'desc']],
|
|
|
+ });
|
|
|
+ if (stages.length !== 0) {
|
|
|
+ const lastStage = stages[stages.length - 1];
|
|
|
+ if (lastStage.status !== auditConst.stage.status.checked) {
|
|
|
+ stages.splice(stages.length - 1, 1);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ await this._gatherStageData(index, tender, stages[0], hasPre);
|
|
|
+ }
|
|
|
+
|
|
|
+ async _gatherSpecialData(sTender, sKey) {
|
|
|
+ const helper = this.ctx.helper;
|
|
|
+ const billsTree = new Ledger.billsTree(this.ctx, {
|
|
|
+ id: 'ledger_id',
|
|
|
+ pid: 'ledger_pid',
|
|
|
+ order: 'order',
|
|
|
+ level: 'level',
|
|
|
+ rootId: -1,
|
|
|
+ keys: ['id', 'tender_id', 'ledger_id'],
|
|
|
+ stageId: 'id',
|
|
|
+ calcFields: ['deal_tp', 'total_price', 'contract_tp', 'qc_tp', 'gather_tp', 'pre_contract_tp', 'pre_qc_tp', 'pre_gather_tp'],
|
|
|
+ });
|
|
|
+ const tender = await this.ctx.service.tender.getCheckTender(sTender.tid);
|
|
|
+ const billsData = await this.ctx.service.ledger.getData(tender.id);
|
|
|
+ billsTree.loadDatas(billsData);
|
|
|
+ billsTree.calculateAll();
|
|
|
+ this.resultTree.loadGatherTree(billsTree, function (gatherNode, sourceNode) {
|
|
|
+ gatherUtils.gatherSpecial(gatherNode, sourceNode, 'ts_' + sKey + '_', helper);
|
|
|
+ })
|
|
|
+ }
|
|
|
+
|
|
|
+ async getGatherStageBills(memFieldKeys, gsDefine, gsCustom) {
|
|
|
+ if (!gsDefine || !gsDefine.enable) return [];
|
|
|
+ if (!gsCustom || !gsCustom.tenders || gsCustom.tenders.length === 0) return [];
|
|
|
+
|
|
|
+ let commonIndex = 0;
|
|
|
+ for (const tender of gsCustom.tenders) {
|
|
|
+ const specialKey = this._checkSpecialTender(tender, gsDefine.setting.special);
|
|
|
+ if (specialKey === '') {
|
|
|
+ switch (gsDefine.setting.type) {
|
|
|
+ case 'month':
|
|
|
+ await this._gatherMonthData(tender, commonIndex, gsCustom.month, gsDefine.hasPre);
|
|
|
+ break;
|
|
|
+ case 'zone':
|
|
|
+ await this._gatherZoneData(tender, commonIndex, gsCustom.zone);
|
|
|
+ break;
|
|
|
+ case 'final':
|
|
|
+ await this._gatherFinalData(tender, commonIndex, gsDefine.hasPre);
|
|
|
+ break;
|
|
|
+ case 'checked-final':
|
|
|
+ await this._gatherCheckedFinalData(tender, commonIndex, gsDefine.hasPre);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ commonIndex++;
|
|
|
+ } else {
|
|
|
+ await this._gatherSpecialData(tender, specialKey);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ this.resultTree.generateSortNodes();
|
|
|
+ return this.resultTree.getDefaultDatas();
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ return RptGatherMemory;
|
|
|
+};
|