浏览代码

审批退回显示问题

MaiXinRong 4 年之前
父节点
当前提交
b02ac29caf
共有 1 个文件被更改,包括 14 次插入2 次删除
  1. 14 2
      app/view/stage/audit_modal.ejs

+ 14 - 2
app/view/stage/audit_modal.ejs

@@ -572,7 +572,13 @@
                                                                 id="inlineRadio2"
                                                                 id="inlineRadio2"
                                                                 value="<%- auditConst.status.checkNoPre %>">
                                                                 value="<%- auditConst.status.checkNoPre %>">
                                                             <label class="form-check-label" for="inlineRadio2">退回上一审批人
                                                             <label class="form-check-label" for="inlineRadio2">退回上一审批人
-                                                                <%- auditors[index-1].status === auditConst.status.checkAgain ? auditors[index-3].name : auditors[index-1].name %></label>
+                                                                <% for (const [i, a] of auditors.entries()) { %>
+                                                                    <% if (a.aid === ctx.stage.curAuditor.aid) { %>
+                                                                        <%- auditors[i-1].name %>
+                                                                        <% break; %>
+                                                                    <% } %>
+                                                                <% } %>
+                                                            </label>
                                                         </div>
                                                         </div>
                                                         <% } %>
                                                         <% } %>
                                                     </div>
                                                     </div>
@@ -646,7 +652,13 @@
                                                                 id="inlineRadio2"
                                                                 id="inlineRadio2"
                                                                 value="<%- auditConst.status.checkNoPre %>">
                                                                 value="<%- auditConst.status.checkNoPre %>">
                                                             <label class="form-check-label" for="inlineRadio2">退回上一审批人
                                                             <label class="form-check-label" for="inlineRadio2">退回上一审批人
-                                                                <%- auditors[index-1].status === auditConst.status.checkAgain || auditors[index-1].status === auditConst.status.checkNoPre ? auditors[index-3].name : auditors[index-1].name %></label>
+                                                                <% for (const [i, a] of auditors.entries()) { %>
+                                                                    <% if (a.aid === ctx.stage.curAuditor.aid) { %>
+                                                                        <%- auditors[i-1].name %>
+                                                                        <% break; %>
+                                                                    <% } %>
+                                                                <% } %>
+                                                            </label>
                                                         </div>
                                                         </div>
                                                         <% } %>
                                                         <% } %>
                                                     </div>
                                                     </div>