|
@@ -1,4 +1,4 @@
|
|
|
-<% if (ctx.stage.status === auditConst.status.uncheck || ctx.stage.status === auditConst.status.checkNo) { %>
|
|
|
+<% if (ctx.stage && (ctx.stage.status === auditConst.status.uncheck || ctx.stage.status === auditConst.status.checkNo)) { %>
|
|
|
<% if (ctx.session.sessionUser.accountId === ctx.stage.user_id) {%>
|
|
|
<!--上报审批-->
|
|
|
<div class="modal fade" id="sub-sp" data-backdrop="static">
|
|
@@ -75,7 +75,7 @@
|
|
|
</div>
|
|
|
<% } %>
|
|
|
<% } %>
|
|
|
-<% if (ctx.stage.status === auditConst.status.checking) { %>
|
|
|
+<% if (ctx.stage && (ctx.stage.status === auditConst.status.checking)) { %>
|
|
|
<% if (ctx.stage.curAuditor && ctx.stage.curAuditor.aid === ctx.session.sessionUser.accountId) { %>
|
|
|
<!--审批通过-->
|
|
|
<div class="modal fade sp-location-list" id="sp-done" data-backdrop="static">
|
|
@@ -565,7 +565,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<% } %>
|
|
|
-<% } else if (ctx.stage.status === auditConst.status.checked) { %>
|
|
|
+<% } else if (ctx.stage && (ctx.stage.status === auditConst.status.checked)) { %>
|
|
|
<!--审批流程/结果-->
|
|
|
<div class="modal fade" id="sp-list" data-backdrop="static">
|
|
|
<div class="modal-dialog modal-lg" role="document">
|
|
@@ -718,7 +718,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
-<% } else if (ctx.stage.status === auditConst.status.checkNo) { %>
|
|
|
+<% } else if (ctx.stage && (ctx.stage.status === auditConst.status.checkNo)) { %>
|
|
|
<!--审批流程/结果-->
|
|
|
<div class="modal fade" id="sp-list" data-backdrop="static">
|
|
|
<div class="modal-dialog modal-lg" role="document">
|
|
@@ -948,7 +948,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<% } %>
|
|
|
-<% } else if (ctx.stage.status === auditConst.status.checkNoPre) { %>
|
|
|
+<% } else if (ctx.stage && (ctx.stage.status === auditConst.status.checkNoPre)) { %>
|
|
|
<!--审批流程/结果-->
|
|
|
<div class="modal fade" id="sp-list" data-backdrop="static">
|
|
|
<div class="modal-dialog modal-lg" role="document">
|
|
@@ -1435,7 +1435,7 @@
|
|
|
</div>
|
|
|
<% } %>
|
|
|
<% } %>
|
|
|
-<% if (ctx.stage.auditors !== undefined && ctx.stage.auditors.length !== 0 && ctx.stage.auditors[ctx.stage.auditors.length-1].aid === ctx.session.sessionUser.accountId && ctx.stage.status === auditConst.status.checked && ctx.stage.order === ctx.stage.highOrder) { %>
|
|
|
+<% if (ctx.stage && ctx.stage.auditors !== undefined && ctx.stage.auditors.length !== 0 && ctx.stage.auditors[ctx.stage.auditors.length-1].aid === ctx.session.sessionUser.accountId && ctx.stage.status === auditConst.status.checked && ctx.stage.order === ctx.stage.highOrder) { %>
|
|
|
<% if (ctx.stage.hadMaterial) { %>
|
|
|
<div class="modal fade" id="sp-down-back" data-backdrop="static">
|
|
|
<div class="modal-dialog" role="document">
|
|
@@ -1452,7 +1452,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <% } else if (!authMobile && ctx.session.sessionUser.loginStatus === 0) { %>
|
|
|
+ <% } else if (ctx.stage && !authMobile && ctx.session.sessionUser.loginStatus === 0) { %>
|
|
|
<!--终审重新审批-->
|
|
|
<div class="modal fade" id="sp-down-back" data-backdrop="static">
|
|
|
<div class="modal-dialog" role="document">
|
|
@@ -1471,7 +1471,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <% } else { %>
|
|
|
+ <% } else if(ctx.stage) { %>
|
|
|
<div class="modal fade" id="sp-down-back" data-backdrop="static">
|
|
|
<div class="modal-dialog" role="document">
|
|
|
<div class="modal-content">
|
|
@@ -1502,7 +1502,7 @@
|
|
|
</div>
|
|
|
<% } %>
|
|
|
<% } %>
|
|
|
-<% if (ctx.stage.user_id === ctx.session.sessionUser.accountId && ctx.stage.order === ctx.stage.highOrder && (ctx.stage.status === auditConst.status.checkNo || ctx.stage.status === auditConst.status.uncheck)) { %>
|
|
|
+<% if (ctx.stage && ctx.stage.user_id === ctx.session.sessionUser.accountId && ctx.stage.order === ctx.stage.highOrder && (ctx.stage.status === auditConst.status.checkNo || ctx.stage.status === auditConst.status.uncheck)) { %>
|
|
|
<!--删除期-->
|
|
|
<% if (ctx.stage.hadMaterial) { %>
|
|
|
<div class="modal fade" id="del-qi" data-backdrop="static">
|
|
@@ -1548,7 +1548,7 @@
|
|
|
const authMobile = '<%= authMobile %>';
|
|
|
</script>
|
|
|
<script>
|
|
|
- <% if (ctx.url !== '/tender/' + ctx.tender.id + '/measure/stage/' + ctx.stage.order) { %>
|
|
|
+ <% if (ctx.stage && ctx.url !== '/tender/' + ctx.tender.id + '/measure/stage/' + ctx.stage.order) { %>
|
|
|
const dataChecker = DataChecker({
|
|
|
checkUrl: '/tender/<%- ctx.tender.id %>/measure/stage/<%- ctx.stage.order %>/check',
|
|
|
errorList: $.cs_errorList({
|