|
|
@@ -128,11 +128,14 @@ module.exports = app => {
|
|
|
const stage_type = this.ctx.service.costStage.stageType.book.key;
|
|
|
const stages = await this.getTypeStages(ctx, stage_type);
|
|
|
const validLedgerStages = await this.ctx.service.costStage.getAllCheckedStages(ctx.tender.id, 'ledger', 'DESC');
|
|
|
+ for (const vls of validLedgerStages) {
|
|
|
+ vls.beenRela = stages.findIndex(x => { return x.rela_stage.sid === vls.id; }) >= 0;
|
|
|
+ }
|
|
|
const renderData = {
|
|
|
stage_type,
|
|
|
auditType: audit.auditType,
|
|
|
stages,
|
|
|
- validLedgerStages,
|
|
|
+ validLedgerStages: validLedgerStages.filter(x => { return !x.beenRela; }),
|
|
|
auditConst: audit.common,
|
|
|
jsFiles: this.app.jsFiles.common.concat(this.app.jsFiles.cost.cost_stage)
|
|
|
};
|