|
@@ -94,10 +94,10 @@ class loadStageExcelTree {
|
|
|
}
|
|
|
} else {
|
|
|
if (!node.contract_qty && !node.contract_tp) return;
|
|
|
- const contract_qty = node.contract_qty;
|
|
|
+ const contract_qty = source.is_tp ? 0 : node.contract_qty;
|
|
|
const contract_tp = contract_qty
|
|
|
? this.ctx.helper.mul(contract_qty, source.unit_price, this.decimal.tp)
|
|
|
- : this.ctx.helper.round(contract_tp, this.decimal.tp);
|
|
|
+ : this.ctx.helper.round(node.contract_tp, this.decimal.tp);
|
|
|
|
|
|
if (curStageBills) {
|
|
|
this.updateBills.push({ id: curStageBills.id, contract_qty: contract_qty, contract_tp: contract_tp, postil: node.postil || curStageBills.postil || '' });
|
|
@@ -336,7 +336,7 @@ module.exports = app => {
|
|
|
});
|
|
|
const extraData = await this.ctx.service.ledgerExtra.getData(this.ctx.tender.id, ['is_tp']);
|
|
|
this.ctx.helper.assignRelaData(ledgerData, [
|
|
|
- { data: extraData, fields: ['is_import'], prefix: '', relaId: 'id' },
|
|
|
+ { data: extraData, fields: ['is_tp'], prefix: '', relaId: 'id' },
|
|
|
]);
|
|
|
const posData = await this.ctx.service.pos.getAllDataByCondition({
|
|
|
columns: ['id', 'lid', 'name', 'porder'],
|