Browse Source

重新上报修改审批流程问题

MaiXinRong 1 week ago
parent
commit
2296b1cac9

+ 1 - 0
app/const/source_type.js

@@ -8,6 +8,7 @@ const sourceTypeData = [
     { id: 22, name: '变更立项', key: 'change_project', params: { change_project_id: 1 } },
     { id: 23, name: '变更申请', key: 'change_apply', params: { change_apply_id: 1 } },
     { id: 30, name: '材料调差', key: 'material', params: { material_id: 1 } },
+    { id: 40, name: '安全计量', key: 'safe_stage', params: { safe_stage_id: 'uuid' } },
     { id: 100, name: '支付审批', key: 'payment', params: { tender_id: 1, detail_id: 1 } },
     { id: 101, name: '安全生产费', key: 'payment_safe', params: { tender_id: 1, detail_id: 1 } },
     { id: 200, name: '动态投资', key: 'budget', params: { sp_id: 'uuid', budget_id: 1 } },

+ 16 - 6
app/public/js/shares/common_audit.js

@@ -130,15 +130,25 @@ $(document).ready(function () {
                     html.push('</div>');
                     html.push('</li>');
                 }
-                auditorshtml.push('<li class="list-group-item" data-auditorid="' + data.audit_id + '">');
-                auditorshtml.push('<i class="fa ' + (index+1 === datas.length ? 'fa-stop-circle' : 'fa-chevron-circle-down') + '"></i> ');
-                auditorshtml.push(data.name + ' <small class="text-muted">' + data.role + '</small>');
+                auditorshtml.push('<li class="list-group-item d-flex justify-content-between align-items-center" data-auditorid="' + data[0].audit_id + '">');
                 if (index === 0) {
-                    auditorshtml.push('<span class="pull-right">原报</span>');
+                    auditorshtml.push('<span class="mr-1"><i class="fa fa fa-play-circle fa-rotate-90"></i></span>');
+                } else if (index === datas.length - 1) {
+                    auditorshtml.push('<span class="mr-1"><i class="fa fa fa-stop-circle"></i></span>');
+                } else {
+                    auditorshtml.push('<span class="mr-1"><i class="fa fa-chevron-circle-down"></i></span>');
+                }
+                auditorshtml.push('<span class="text-muted">');
+                for (const auditor of data) {
+                    auditorshtml.push(`<small class="d-inline-block text-dark mx-1" title="${auditor.company}" data-auditorId="${auditor.audit_id}">${auditor.name}</small>`);
+                }
+                auditorshtml.push('</span>');
+                if (index === 0) {
+                    auditorshtml.push('<div class="d-flex ml-auto"><span class="pull-right">原报</span></div>');
                 } else if (index+1 === datas.length) {
-                    auditorshtml.push('<span class="pull-right">终审</span>');
+                    auditorshtml.push('<div class="d-flex ml-auto"><span class="pull-right">终审</span></div>');
                 } else {
-                    auditorshtml.push('<span class="pull-right">'+ transFormToChinese(index) +'审</span>');
+                    auditorshtml.push('<div class="d-flex ml-auto"><span class="pull-right">'+ transFormToChinese(index) +'审</span></div>');
                 }
                 auditorshtml.push('</li>');
             }

+ 3 - 3
app/view/safe_calc/audit_modal.ejs

@@ -101,7 +101,7 @@
                             <ul class="list-group list-group-flush auditors-list" id="auditors-list">
                                 <% ctx.safeStage.userGroups.forEach((item, idx) => { %>
                                 <% if (idx === 0) { %>
-                                <li class="list-group-item d-flex justify-content-between align-items-center">
+                                <li class="list-group-item d-flex justify-content-between align-items-center" data-auditorId="<%- item[0].audit_id%>">
                                     <span class="mr-1"><i class="fa fa fa-play-circle fa-rotate-90"></i></span>
                                     <span class="text-muted">
                                         <% for (const u of item) { %>
@@ -111,7 +111,7 @@
                                     <span class="badge badge-light badge-pill ml-auto"><small>原报</small></span>
                                 </li>
                                 <% } else if(idx === ctx.safeStage.userGroups.length -1 && idx !== 0) { %>
-                                <li class="list-group-item d-flex justify-content-between align-items-center">
+                                <li class="list-group-item d-flex justify-content-between align-items-center" data-auditorId="<%- item[0].audit_id%>">
                                     <span class="mr-1"><i class="fa fa fa-stop-circle"></i></span>
                                     <span class="text-muted">
                                         <% for (const u of item) { %>
@@ -126,7 +126,7 @@
                                     </div>
                                 </li>
                                 <% } else {%>
-                                <li class="list-group-item d-flex justify-content-between align-items-center">
+                                <li class="list-group-item d-flex justify-content-between align-items-center" data-auditorId="<%- item[0].audit_id%>">
                                     <span class="mr-1"><i class="fa fa-chevron-circle-down"></i></span>
                                     <span class="text-muted">
                                         <% for (const u of item) { %>