workAttendanceAudit.jsp 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. <%@ page contentType="text/html;charset=UTF-8" %>
  2. <%@ include file="/webpage/include/taglib.jsp"%>
  3. <html>
  4. <head>
  5. <title>考勤规则</title>
  6. <meta name="decorator" content="default"/>
  7. <style type="text/css">
  8. img {width: 50px; height: 50px;}
  9. </style>
  10. <script type="text/javascript" src="${ctxStatic}/ckeditor/ckeditor.js"></script>
  11. <script type="text/javascript" language="JavaScript" for="window" event="onload">
  12. var validateForm;
  13. function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
  14. if(validateForm.form()){
  15. if(obj == 1){
  16. $('#flag').val('yes');
  17. }else{
  18. $('#flag').val('no');
  19. }
  20. $("#inputForm").submit();
  21. return true;
  22. }
  23. return false;
  24. }
  25. $(document).ready(function() {
  26. validateForm = $("#inputForm").validate({
  27. submitHandler: function(form){
  28. loading('正在提交,请稍等...');
  29. form.submit();
  30. },
  31. errorContainer: "#messageBox",
  32. errorPlacement: function(error, element) {
  33. $("#messageBox").text("输入有误,请先更正。");
  34. if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
  35. error.appendTo(element.parent().parent());
  36. } else {
  37. error.insertAfter(element);
  38. }
  39. }
  40. });
  41. });
  42. </script>
  43. </head>
  44. <body >
  45. <div class="single-form">
  46. <div class="container view-form">
  47. <form:form id="inputForm" modelAttribute="workAttendanceInfo" enctype="multipart/form-data" action="${ctx}/workattendance/workAttendanceInfo/saveAudit" method="post" class="form-horizontal">
  48. <form:hidden path="id"/>
  49. <form:hidden path="ids"/>
  50. <form:hidden path="flag"/>
  51. <form:hidden path="home"/>
  52. <sys:message content="${message}"/>
  53. <div class="form-group layui-row first">
  54. <div class="form-group-label"><h2>补卡信息</h2></div>
  55. <div class="layui-item layui-col-sm6">
  56. <label class="layui-form-label"><span class="require-item">*</span>补卡类型:</label>
  57. <div class="layui-input-block with-icon">
  58. <input htmlEscape="false" readonly="true" class="form-control layui-input" value="${fns:getDictLabel(workAttendanceInfo.type, 'attendance_type', '')}"/>
  59. </div>
  60. </div>
  61. <div class="layui-item layui-col-sm6">
  62. <label class="layui-form-label"><span class="require-item">*</span>上午/下午:</label>
  63. <div class="layui-input-block">
  64. <input htmlEscape="false" readonly="true" class="form-control layui-input" value="${fns:getDictLabel(workAttendanceInfo.morningAfternoon, 'am_pm', '')}"/>
  65. </div>
  66. </div>
  67. <div class="layui-item layui-col-sm6">
  68. <label class="layui-form-label"><span class="require-item">*</span>考勤类型:</label>
  69. <div class="layui-input-block">
  70. <input htmlEscape="false" readonly="true" class="form-control layui-input" value="${fns:getDictLabel(workAttendanceInfo.attendanceType, 'attendance_info_type', '')}"/>
  71. </div>
  72. </div>
  73. <div class="layui-item layui-col-sm6">
  74. <label class="layui-form-label"><span class="require-item">*</span>补卡时间:</label>
  75. <div class="layui-input-block">
  76. <input htmlEscape="false" readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${workAttendanceInfo.updateDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
  77. </div>
  78. </div>
  79. <div class="layui-item layui-col-sm6">
  80. <label class="layui-form-label"><span class="require-item">*</span>补卡原因:</label>
  81. <div class="layui-input-block">
  82. <input htmlEscape="false" readonly="true" class="form-control layui-input" value="${workAttendanceInfo.remarks}"/>
  83. </div>
  84. </div>
  85. </div>
  86. <div class="form-group layui-row">
  87. <div class="form-group-label"><h2>图片</h2></div>
  88. <div class="layui-item layui-col-xs12 form-table-container" >
  89. <table id="upTable" class="table table-bordered table-condensed details">
  90. <thead>
  91. <tr>
  92. <th>文件预览</th>
  93. <th>上传人</th>
  94. <th>上传时间</th>
  95. <th width="150px">操作</th>
  96. </tr>
  97. </thead>
  98. <tbody id="file_attachment">
  99. <c:forEach items="${workAttendanceInfo.workAttachments}" var = "workClientAttachment" varStatus="status">
  100. <tr>
  101. <c:choose>
  102. <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
  103. or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
  104. or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
  105. or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
  106. or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
  107. <td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}">
  108. <td>${workClientAttachment.createBy.name}</td>
  109. <td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
  110. <td class="op-td">
  111. <div class="op-btn-box" >
  112. <a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
  113. </div>
  114. </td>
  115. </c:when>
  116. <c:otherwise>
  117. </c:otherwise>
  118. </c:choose>
  119. </tr>
  120. </c:forEach>
  121. </tbody>
  122. </table>
  123. </div>
  124. </div>
  125. <div class="form-group layui-row page-end"></div>
  126. </form:form>
  127. </div>
  128. </div>
  129. </body>
  130. </html>