From 5a9d0ba0f6ea45bfca0d1f7cf2f11e8045405d38 Mon Sep 17 00:00:00 2001 From: dshclm <3321914460@qq.com> Date: Wed, 15 May 2024 10:37:28 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B6=89=E5=AF=86=E6=96=87=E4=BB=B6=E6=8E=A5?= =?UTF-8?q?=E6=94=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../filemanager/TdFileReceiveController.java | 6 +- .../templates/system/fileprovide/add.html | 4 +- .../templates/system/filereceive/edit.html | 76 +++---------------- .../system/filereceive/filereceive.html | 4 +- 4 files changed, 19 insertions(+), 71 deletions(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileReceiveController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileReceiveController.java index 48f15cd..80400a5 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileReceiveController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileReceiveController.java @@ -1,6 +1,9 @@ package com.ruoyi.web.controller.system.filemanager; import java.util.List; + +import com.ruoyi.common.core.domain.entity.SysDept; +import com.ruoyi.system.service.ISysDeptService; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -21,7 +24,7 @@ import com.ruoyi.common.core.page.TableDataInfo; /** * 涉密文件接收Controller - * + * * @author ruoyi * @date 2024-05-14 */ @@ -98,6 +101,7 @@ public class TdFileReceiveController extends BaseController { TdFileReceive tdFileReceive = tdFileReceiveService.selectTdFileReceiveByReceiveId(receiveId); mmap.put("tdFileReceive", tdFileReceive); + mmap.put("user",getSysUser()); return prefix + "/edit"; } diff --git a/ruoyi-admin/src/main/resources/templates/system/fileprovide/add.html b/ruoyi-admin/src/main/resources/templates/system/fileprovide/add.html index 1a39fe8..e392283 100644 --- a/ruoyi-admin/src/main/resources/templates/system/fileprovide/add.html +++ b/ruoyi-admin/src/main/resources/templates/system/fileprovide/add.html @@ -23,13 +23,13 @@ <div class="form-group"> <label class="col-sm-3 control-label">发文单位:</label> <div class="col-sm-8"> - <input name="provideDepart" class="form-control" type="text"> + <input name="provideDepart" readonly th:value="${user.dept.deptName}" class="form-control" type="text"> </div> </div> <div class="form-group"> <label class="col-sm-3 control-label">发文人员:</label> <div class="col-sm-8"> - <input name="provideUserid" class="form-control" type="text"> + <input name="provideUserid" readonly th:value="${user.userName}" class="form-control" type="text"> </div> </div> <div class="form-group"> diff --git a/ruoyi-admin/src/main/resources/templates/system/filereceive/edit.html b/ruoyi-admin/src/main/resources/templates/system/filereceive/edit.html index 0f71128..e2aa39c 100644 --- a/ruoyi-admin/src/main/resources/templates/system/filereceive/edit.html +++ b/ruoyi-admin/src/main/resources/templates/system/filereceive/edit.html @@ -8,91 +8,47 @@ <div class="wrapper wrapper-content animated fadeInRight ibox-content"> <form class="form-horizontal m" id="form-filereceive-edit" th:object="${tdFileReceive}"> <input name="receiveId" th:field="*{receiveId}" type="hidden"> + <input name="receiveState" th:value="'1'" class="form-control" type="hidden"> <div class="form-group"> <label class="col-sm-3 control-label">文件编号:</label> <div class="col-sm-8"> - <input name="fileId" th:field="*{fileId}" class="form-control" type="text"> + <input name="fileId" readonly th:field="*{fileId}" class="form-control" type="text"> </div> </div> <div class="form-group"> <label class="col-sm-3 control-label">文件名称:</label> <div class="col-sm-8"> - <input name="fileName" th:field="*{fileName}" class="form-control" type="text"> + <input name="fileName" readonly th:field="*{fileName}" class="form-control" type="text"> </div> </div> <div class="form-group"> <label class="col-sm-3 control-label">发文单位:</label> <div class="col-sm-8"> - <input name="provideDepart" th:field="*{provideDepart}" class="form-control" type="text"> + <input name="provideDepart" readonly th:field="*{provideDepart}" class="form-control" type="text"> </div> </div> <div class="form-group"> <label class="col-sm-3 control-label">发文日期:</label> <div class="col-sm-8"> - <div class="input-group date"> - <input name="provideDate" th:value="${#dates.format(tdFileReceive.provideDate, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text"> - <span class="input-group-addon"><i class="fa fa-calendar"></i></span> - </div> + <input name="provideDate" readonly th:value="${#dates.format(tdFileReceive.provideDate, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text"> </div> </div> <div class="form-group"> <label class="col-sm-3 control-label">接收单位:</label> <div class="col-sm-8"> - <input name="receiveDepartid" th:field="*{receiveDepartid}" class="form-control" type="text"> - </div> - </div> - <div class="form-group"> - <label class="col-sm-3 control-label">接收状态:</label> - <div class="col-sm-8"> - <input name="receiveState" th:field="*{receiveState}" class="form-control" type="text"> + <input name="receiveDepartid" readonly th:field="*{receiveDepartid}" class="form-control" type="text"> </div> </div> <div class="form-group"> <label class="col-sm-3 control-label">接收人员:</label> <div class="col-sm-8"> - <input name="receiveUserid" th:field="*{receiveUserid}" class="form-control" type="text"> + <input name="receiveUserid" th:value="${user.userName}" readonly class="form-control" type="text"> </div> </div> <div class="form-group"> <label class="col-sm-3 control-label">接收日期:</label> <div class="col-sm-8"> - <div class="input-group date"> - <input name="receiveDate" th:value="${#dates.format(tdFileReceive.receiveDate, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text"> - <span class="input-group-addon"><i class="fa fa-calendar"></i></span> - </div> - </div> - </div> - <div class="form-group"> - <label class="col-sm-3 control-label">提取状态:</label> - <div class="col-sm-8"> - <input name="extractState" th:field="*{extractState}" class="form-control" type="text"> - </div> - </div> - <div class="form-group"> - <label class="col-sm-3 control-label">提取单位:</label> - <div class="col-sm-8"> - <input name="extractDepartid" th:field="*{extractDepartid}" class="form-control" type="text"> - </div> - </div> - <div class="form-group"> - <label class="col-sm-3 control-label">提取人员:</label> - <div class="col-sm-8"> - <input name="extractUserid" th:field="*{extractUserid}" class="form-control" type="text"> - </div> - </div> - <div class="form-group"> - <label class="col-sm-3 control-label">提取日期:</label> - <div class="col-sm-8"> - <div class="input-group date"> - <input name="extractDate" th:value="${#dates.format(tdFileReceive.extractDate, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text"> - <span class="input-group-addon"><i class="fa fa-calendar"></i></span> - </div> - </div> - </div> - <div class="form-group"> - <label class="col-sm-3 control-label">销毁状态:</label> - <div class="col-sm-8"> - <input name="destoryState" th:field="*{destoryState}" class="form-control" type="text"> + <input name="receiveDate" readonly class="form-control" placeholder="yyyy-MM-dd" type="text"> </div> </div> </form> @@ -110,19 +66,7 @@ $.operate.save(prefix + "/edit", $('#form-filereceive-edit').serialize()); } } - - $("input[name='provideDate']").datetimepicker({ - format: "yyyy-mm-dd", - minView: "month", - autoclose: true - }); - - $("input[name='receiveDate']").datetimepicker({ - format: "yyyy-mm-dd", - minView: "month", - autoclose: true - }); - + $("input[name='receiveDate']").val($.common.dateFormat(new Date(),"yyyy-MM-dd")); $("input[name='extractDate']").datetimepicker({ format: "yyyy-mm-dd", minView: "month", @@ -130,4 +74,4 @@ }); </script> </body> -</html> \ No newline at end of file +</html> diff --git a/ruoyi-admin/src/main/resources/templates/system/filereceive/filereceive.html b/ruoyi-admin/src/main/resources/templates/system/filereceive/filereceive.html index 7f59bc0..e9af521 100644 --- a/ruoyi-admin/src/main/resources/templates/system/filereceive/filereceive.html +++ b/ruoyi-admin/src/main/resources/templates/system/filereceive/filereceive.html @@ -114,7 +114,7 @@ align: 'center', formatter: function(value, row, index) { var actions = []; - actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.receiveId + '\')"><i class="fa fa-edit"></i>编辑</a> '); + actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.receiveId + '\')"><i class="fa fa-edit"></i>接收</a> '); actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.receiveId + '\')"><i class="fa fa-remove"></i>删除</a>'); return actions.join(''); } @@ -124,4 +124,4 @@ }); </script> </body> -</html> \ No newline at end of file +</html>