|
@@ -64,7 +64,7 @@ module.exports = app => {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
async _getLedgerUpdateData(data, ledger_id, details) {
|
|
async _getLedgerUpdateData(data, ledger_id, details) {
|
|
|
- const detailDatas = details || await this.getAllDataByCondition({ columns: ['id', 'ledger_id', ...costFields.calcFields], where: { ledger_id, stage_id: this.ctx.costStage.id } });
|
|
|
|
|
|
|
+ const detailDatas = details || await this.getAllDataByCondition({ columns: ['id', 'ledger_id', ...costFields.calcFields, ...costFields.selfCalcFields], where: { ledger_id, stage_id: this.ctx.costStage.id } });
|
|
|
|
|
|
|
|
const curCalcFields = costFields.selfCalcFields.filter(x => { return data[0][x] !== undefined; });
|
|
const curCalcFields = costFields.selfCalcFields.filter(x => { return data[0][x] !== undefined; });
|
|
|
const updateData = { id: ledger_id, update_user_id: this.ctx.session.sessionUser.accountId };
|
|
const updateData = { id: ledger_id, update_user_id: this.ctx.session.sessionUser.accountId };
|