|
|
@@ -185,7 +185,7 @@ module.exports = app => {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- advance.advancePayTotal = this.ctx.tender.info.deal_param[ advanceConst.typeCol[advance.type].key + 'Advance'];
|
|
|
+ advance.advancePayTotal = this.ctx.tender.info.deal_param[advanceConst.typeCol[advance.type].key + 'Advance'];
|
|
|
if (advance.status === auditConst.advance.status.checkNo) {
|
|
|
advance.curAuditor = await this.service.advanceAudit.getAuditorByStatus(advance.id, advance.status, times);
|
|
|
advance.auditHistory = await this.service.advanceAudit.getAuditors(advance.id, times);
|
|
|
@@ -306,6 +306,56 @@ module.exports = app => {
|
|
|
await ctx.service.reviseAudit.loadReviseUser(revise);
|
|
|
await ctx.service.reviseAudit.loadReviseAuditViewData(revise);
|
|
|
|
|
|
+ revise.auditHistory = revise.auditors.reduce((prev, curr, idx) => {
|
|
|
+ if (idx === 0) {
|
|
|
+ const reportor = {
|
|
|
+ audit_id: revise.uid,
|
|
|
+ audit_order: 0,
|
|
|
+ audit_type: 1,
|
|
|
+ status: revise.status === auditConst.revise.status.uncheck ? auditConst.revise.status.uncheck : auditConst.revise.status.checked,
|
|
|
+ times: curr.times,
|
|
|
+ begin_time: revise.in_time,
|
|
|
+ end_time: revise.auditors.length ? revise.auditors[0].begin_time : null,
|
|
|
+ name: revise.user.name,
|
|
|
+ company: revise.user.company,
|
|
|
+ role: revise.user.role,
|
|
|
+ mobile: '',
|
|
|
+ opinion: '',
|
|
|
+
|
|
|
+ };
|
|
|
+ prev.push({
|
|
|
+ name: '原报',
|
|
|
+ status: reportor.status,
|
|
|
+ audit_type: reportor.audit_type,
|
|
|
+ auditors: [reportor],
|
|
|
+ });
|
|
|
+ }
|
|
|
+ const currentOrder = curr.audit_order;
|
|
|
+ prev.push(
|
|
|
+ {
|
|
|
+ name: currentOrder === curr.max_sort ? '终审' : `${currentOrder}审`,
|
|
|
+ status: curr.status,
|
|
|
+ audit_type: 1,
|
|
|
+ auditors: [{
|
|
|
+ audit_id: curr.audit_id,
|
|
|
+ audit_order: curr.audit_order,
|
|
|
+ audit_type: curr.audit_type,
|
|
|
+ status: curr.status,
|
|
|
+ max_sort: curr.max_sort,
|
|
|
+ begin_time: curr.begin_time,
|
|
|
+ end_time: curr.end_time,
|
|
|
+ name: curr.name,
|
|
|
+ company: curr.company,
|
|
|
+ mobile: curr.mobile,
|
|
|
+ opinion: curr.opinion,
|
|
|
+ role: curr.role,
|
|
|
+ times: curr.times,
|
|
|
+ }],
|
|
|
+ }
|
|
|
+ );
|
|
|
+ return prev;
|
|
|
+ }, []);
|
|
|
+
|
|
|
const GclGather = require('../lib/gcl_gather');
|
|
|
const gclGatherModal = new GclGather.gclCompareGather(this.ctx);
|
|
|
const spec = { zlj: stdConst.zlj, jrg: stdConst.jrg };
|
|
|
@@ -325,7 +375,8 @@ module.exports = app => {
|
|
|
revise.chapterList = gclGatherModal.chapterData();
|
|
|
revise.new_tp = gclGatherModal.otherChapter.hj.new_total_price || 0;
|
|
|
revise.org_tp = gclGatherModal.otherChapter.hj.org_total_price || 0;
|
|
|
-
|
|
|
+ console.log(ctx.tender.data.name);
|
|
|
+ revise.tenderName = ctx.tender.data.name;
|
|
|
ctx.body = { code: 0, msg: '', data: { revise } };
|
|
|
} catch (error) {
|
|
|
ctx.log(error);
|