|
@@ -500,7 +500,7 @@ module.exports = app => {
|
|
* @param period - 开始-截止日期
|
|
* @param period - 开始-截止日期
|
|
* @return {Promise<void>}
|
|
* @return {Promise<void>}
|
|
*/
|
|
*/
|
|
- async addStage(tenderId, date, period) {
|
|
|
|
|
|
+ async addStage(tender, date, period) {
|
|
const stages = await this.getAllDataByCondition({
|
|
const stages = await this.getAllDataByCondition({
|
|
where: { tid: tenderId },
|
|
where: { tid: tenderId },
|
|
orders: [['order', 'DESC']],
|
|
orders: [['order', 'DESC']],
|
|
@@ -510,14 +510,14 @@ module.exports = app => {
|
|
const order = stages.length + 1;
|
|
const order = stages.length + 1;
|
|
const newStage = {
|
|
const newStage = {
|
|
sid: this.uuid.v4(),
|
|
sid: this.uuid.v4(),
|
|
- tid: tenderId,
|
|
|
|
|
|
+ tid: tender.id,
|
|
order,
|
|
order,
|
|
in_time: new Date(),
|
|
in_time: new Date(),
|
|
s_time: date,
|
|
s_time: date,
|
|
period,
|
|
period,
|
|
times: 1,
|
|
times: 1,
|
|
status: auditConst.stage.status.uncheck,
|
|
status: auditConst.stage.status.uncheck,
|
|
- user_id: this.ctx.session.sessionUser.accountId,
|
|
|
|
|
|
+ user_id: tender.user_id, // this.ctx.session.sessionUser.accountId,
|
|
check_calc: false,
|
|
check_calc: false,
|
|
};
|
|
};
|
|
newStage.cache_time_l = newStage.in_time;
|
|
newStage.cache_time_l = newStage.in_time;
|