|
@@ -76,7 +76,7 @@ module.exports = app => {
|
|
|
const tid = ctx.tender.id;
|
|
|
const latestOrder = await this.getLastestAdvance(tid, type);
|
|
|
const order = !latestOrder ? 1 : latestOrder.order + 1;
|
|
|
- const record = await this.db.insert(this.tableName, { type, uid, tid, status: auditConst.status.uncheck, order });
|
|
|
+ const record = await this.db.insert(this.tableName, { type, uid, tid, status: auditConst.status.uncheck, order, prev_amount: latestOrder.prev_total_amount });
|
|
|
return await this.getDataById(record.insertId);
|
|
|
}
|
|
|
|