cert_modal.ejs 3.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. <!--导入-->
  2. <div class="modal fade" id="import" data-backdrop="static">
  3. <div class="modal-dialog" role="document">
  4. <div class="modal-content">
  5. <div class="modal-header">
  6. <h5 class="modal-title">添加用户</h5>
  7. </div>
  8. <div class="modal-body pt-1">
  9. <div class="d-flex flex-row bg-graye">
  10. <div class="p-2 dropdown">
  11. <button class="btn btn-outline-primary btn-sm dropdown-toggle" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
  12. 添加用户
  13. </button>
  14. <div class="dropdown-menu" aria-labelledby="dropdownMenuButton" style="width:220px">
  15. <div class="mb-2 p-2"><input class="form-control form-control-sm" placeholder="姓名/手机 检索" id="gr-search" autocomplete="off"></div>
  16. <dl class="list-unstyled book-list">
  17. <% accountGroup.forEach((group, idx) => { %>
  18. <dt><a href="javascript: void(0);" class="acc-btn" data-groupid="<%- idx %>" data-type="hide"><i class="fa fa-plus-square"></i></a> <%- group.groupName %></dt>
  19. <div class="dd-content" data-toggleid="<%- idx %>">
  20. <% group.groupList.forEach(item => { %>
  21. <dd class="border-bottom p-2 mb-0 " data-id="<%- item.id %>" >
  22. <p class="mb-0 d-flex"><span class="text-primary"><%- item.name %></span><span
  23. class="ml-auto"><%- item.mobile %></span></p>
  24. <span class="text-muted"><%- item.role %></span>
  25. </dd>
  26. <% });%>
  27. </div>
  28. <% }) %>
  29. </dl>
  30. </div>
  31. </div>
  32. </div>
  33. <table class="table table-bordered">
  34. <thead>
  35. <tr>
  36. <th>用户名</th>
  37. <th>角色/职位</th>
  38. <th>选择证书</th>
  39. <th>操作</th>
  40. </tr>
  41. </thead>
  42. <tbody id="select-certs-table">
  43. <% for (const tc of tenderCertList) { %>
  44. <tr class="text-center">
  45. <td><%- tc.account_info.name %></td>
  46. <td><%- tc.account_info.role %></td>
  47. <td>
  48. <select class="form-control form-control-sm">
  49. <% for (const c of tc.account_info.certs) { %>
  50. <option value="<%- c.id %>" <% if (tc.cert_id === c.id) { %>selected<% } %>><%- ctx.helper.showCol4ObjArray(certSourceConst, c.name, 'value', 'name') %></option>
  51. <% } %>
  52. </select>
  53. </td>
  54. <td class="text-danger">移除</td>
  55. </tr>
  56. <% } %>
  57. </tbody>
  58. </table>
  59. </div>
  60. <div class="modal-footer d-flex justify-content-between">
  61. <div class="ml-auto">
  62. <button type="button" class="btn btn-sm btn-secondary" data-dismiss="modal">取消</button>
  63. <button type="button" class="btn btn-sm btn-primary" id="add_cert_btn">确认</button>
  64. </div>
  65. </div>
  66. </div>
  67. </div>
  68. </div>