From 166a00fd377a34282602c02722b5e5271f68a805 Mon Sep 17 00:00:00 2001 From: 马宇豪 <978517621@qq.com> Date: 星期二, 18 六月 2024 16:18:02 +0800 Subject: [PATCH] 添加 --- src/main/resources/templates/tr/tbBaseCheckScore/edit.html | 23 src/main/resources/templates/tr/tbBaseCheckItem/detail.html | 83 +++++ src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/detail.html | 83 +++++ src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/edit.html | 88 +++++ src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/add.html | 78 +++++ src/main/resources/templates/tr/tbBaseCheckScore/selectTbBaseCheckScorePage.html | 35 + src/main/resources/templates/tr/tbBaseCheckItem/selectTbBaseCheckItemPage.html | 130 ++++++++ src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/specialCheckScoreAndDangerLog.html | 157 ++++++++++ src/main/resources/templates/tr/tbBaseCheckItem/edit.html | 88 +++++ src/main/resources/templates/tr/tbBaseCheckItem/add.html | 78 +++++ src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBBaseCheckScoreController.java | 16 + src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBSpecialCheckScoreAndDangerLogController.java | 2 src/main/resources/templates/tr/specialCheckItemDangerLog/specialCheckItemDangerLog.html | 2 src/main/resources/templates/tr/tbBaseCheckScore/add.html | 16 14 files changed, 851 insertions(+), 28 deletions(-) diff --git a/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBBaseCheckScoreController.java b/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBBaseCheckScoreController.java index a765a94..2641d36 100644 --- a/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBBaseCheckScoreController.java +++ b/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBBaseCheckScoreController.java @@ -1,11 +1,14 @@ package com.ruoyi.project.tr.specialCheck.controller; +import com.ruoyi.doublePrevention.entity.CJReport.PreventCJReportDangerInfo; import com.ruoyi.doublePrevention.vo.ResultVO; import com.ruoyi.framework.web.controller.BaseController; import com.ruoyi.framework.web.page.TableDataInfo; +import com.ruoyi.project.tr.riskList.domain.RiskList; import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckScoreBO; import com.ruoyi.project.tr.specialCheck.domin.DTO.TbBaseCheckScoreDTO; import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckScore; +import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog; import com.ruoyi.project.tr.specialCheck.service.TbBaseCheckService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -52,6 +55,19 @@ return dataTable; } + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Long indexId, ModelMap mmap) + { +// TbSpecialCheckItemDangerLog specialCheckItem = itemDangerLogService.getSpecialCheckItemDangerLogByIndexId(indexId); +// mmap.put("specialCheckItem",specialCheckItem); + +// TbBaseCheckTaskBO tbBaseCheckTaskBO = new TbBaseCheckTaskBO(); +// ResultVO<List<TbBaseCheckTask>> listResultVO = tbBaseCheckService.selectTbBaseCheckTaskPage(tbBaseCheckTaskBO); +// Object data = listResultVO.getData(); +// mmap.put("tbBaseCheckTask", data); + return prefix + "/edit"; + } + } diff --git a/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBSpecialCheckScoreAndDangerLogController.java b/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBSpecialCheckScoreAndDangerLogController.java index 29cebe8..90437fd 100644 --- a/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBSpecialCheckScoreAndDangerLogController.java +++ b/src/main/java/com/ruoyi/project/tr/specialCheck/controller/TBSpecialCheckScoreAndDangerLogController.java @@ -31,7 +31,7 @@ @RequestMapping("/tr/TBSpecialCheckScoreAndDangerLog") public class TBSpecialCheckScoreAndDangerLogController extends BaseController { - private String prefix = "tr/specialCheckScoreAndDangerLog"; + private String prefix = "tr/TBSpecialCheckScoreAndDangerLog"; @Autowired private SpecialCheckScoreAndDangerDangerLogService scoreAndDangerDangerLogService; diff --git a/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/add.html b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/add.html new file mode 100644 index 0000000..25f77f0 --- /dev/null +++ b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/add.html @@ -0,0 +1,78 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org"> +<head> + <th:block th:include="include :: header('新增评分')"/> + <th:block th:include="include :: datetimepicker-css"/> +</head> +<body class="white-bg"> +<div class="wrapper wrapper-content animated fadeInRight ibox-content"> + <form class="form-horizontal m" id="form-job-add"> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">关联隐患:</label> + <div class="col-sm-8"> + <select id="dangerId" name="dangerId" class="form-control" required> + <option th:each="danger : ${dangerList}" th:text="${danger.dangerName}" th:value="${danger.id}"></option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查类型:</label> + <div class="col-sm-8"> + <select name="checkType" class="form-control m-b" required id="checkType"> + <option value="">请选择</option> + <option value="1">企业自查</option> + <option value="2">市级及以下检查</option> + <option value="3">省级检查</option> + <option value="4">部级检查</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查日期:</label> + <div class="col-sm-8"> + <div class="input-group date"> + <span class="input-group-addon"><i class="fa fa-calendar"></i></span> + <input name="checkDate" class="form-control" placeholder="yyyy-MM-dd" type="text" required> + </div> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">危害类型:</label> + <div class="col-sm-8"> + <select name="harmType" class="form-control m-b" required id="harmType"> + <option value="">请选择</option> + <option value="1">事故隐患</option> + <option value="2">火灾隐患</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">罚款金额(元):</label> + <div class="col-sm-8"> + <input class="form-control" type="number" name="checkPay" id="checkPay" required> + </div> + </div> + </form> +</div> +<th:block th:include="include :: footer"/> +<th:block th:include="include :: datetimepicker-js"/> +<script type="text/javascript"> + $("input[name='checkDate']").datetimepicker({ + format: "yyyy-mm-dd", + minView: "month", + autoclose: true + }); + + $("#form-job-add").validate({ + onkeyup: false, + focusCleanup: true + }); + + function submitHandler() { + if ($.validate.form()){ + $.operate.save(prefix + "/add", $('#form-job-add').serialize()); + } + } +</script> +</body> +</html> diff --git a/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/detail.html b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/detail.html new file mode 100644 index 0000000..2d27487 --- /dev/null +++ b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/detail.html @@ -0,0 +1,83 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org"> +<head> + <th:block th:include="include :: header('修改检查任务')"/> + <th:block th:include="include :: datetimepicker-css"/> +</head> +<body class="white-bg"> +<div class="wrapper wrapper-content animated fadeInRight ibox-content"> + <form class="form-horizontal m" id="form-job-edit" th:object="${specialCheckTaskLog}"> + <input id="indexId" name="indexId" type="hidden" th:field="*{indexId}"/> + + + <!-- <input id="createUserId" name="createUserId" type="hidden" th:field="*{createUserId}"/>--> + <!-- <input id="createBy" name="createBy" type="hidden" th:field="*{createBy}"/>--> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">风险分析对象:</label> + <div class="col-sm-8"> + <select id="hazardCode" name="hazardCode" th:field="*{hazardCode}" class="form-control" required readonly="readonly"> + <option th:each="hazard : ${hazardList}" th:text="${hazard.riskListName}" th:value="${hazard.riskListNum}"></option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查类型:</label> + <div class="col-sm-8"> + <select name="checkType" th:field="*{checkType}" class="form-control m-b" required id="checkType" readonly="readonly"> + <option value="">请选择</option> + <option value="1">企业自查</option> + <option value="2">市级及以下检查</option> + <option value="3">省级检查</option> + <option value="4">部级检查</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查日期:</label> + <div class="col-sm-8"> + <div class="input-group date"> + <span class="input-group-addon"><i class="fa fa-calendar"></i></span> + <input name="checkDate" th:value="${#dates.format(specialCheckTaskLog.checkDate, 'yyyy-MM-dd')}" class="form-control" type="text" required readonly="readonly"> + </div> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">是否停产整顿:</label> + <div class="col-sm-8"> + <select name="resultStatus" th:field="*{resultStatus}" class="form-control m-b" required id="resultStatus" readonly="readonly"> + <option value="">请选择</option> + <option value="0">否</option> + <option value="1">是</option> + </select> + </div> + </div> + + <!-- <input id="jobGroup" name="jobGroup" type="hidden" value="specialCheckTaskLog"/>--> + + </form> +</div> +<th:block th:include="include :: footer"/> +<th:block th:include="include :: datetimepicker-js"/> +<script th:inline="javascript"> + var prefix = ctx + "tr/specialCheckTaskLog"; + + $("input[name='checkDate']").datetimepicker({ + format: "yyyy-mm-dd", + minView: "month", + autoclose: true + }); + + + $("#form-job-edit").validate({ + onkeyup: false, + focusCleanup: true + }); + + function submitHandler() { + if ($.validate.form()){ + $.operate.save(prefix + "/edit", $('#form-job-edit').serialize()); + } + } +</script> +</body> +</html> diff --git a/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/edit.html b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/edit.html new file mode 100644 index 0000000..6fcf470 --- /dev/null +++ b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/edit.html @@ -0,0 +1,88 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org"> +<head> + <th:block th:include="include :: header('检查项评分')"/> + <th:block th:include="include :: datetimepicker-css"/> +</head> +<body class="white-bg"> +<div class="wrapper wrapper-content animated fadeInRight ibox-content"> + <form class="form-horizontal m" id="form-job-edit" th:object="${specialCheckTaskLog}"> + <input id="id" name="id" type="hidden" th:field="*{id}"/> + + +<!-- <input id="createUserId" name="createUserId" type="hidden" th:field="*{createUserId}"/>--> +<!-- <input id="createBy" name="createBy" type="hidden" th:field="*{createBy}"/>--> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">关联隐患:</label> + <div class="col-sm-8"> + <select id="hazardCode" name="hazardCode" th:field="*{hazardCode}" class="form-control" required> + <option th:each="hazard : ${hazardList}" th:text="${hazard.riskListName}" th:value="${hazard.riskListNum}"></option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查类型:</label> + <div class="col-sm-8"> + <select name="checkType" th:field="*{checkType}" class="form-control m-b" required id="checkType"> + <option value="">请选择</option> + <option value="1">企业自查</option> + <option value="2">市级及以下检查</option> + <option value="3">省级检查</option> + <option value="4">部级检查</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查日期:</label> + <div class="col-sm-8"> + <div class="input-group date"> + <span class="input-group-addon"><i class="fa fa-calendar"></i></span> + <input name="checkDate" th:value="${#dates.format(specialCheckTaskLog.checkDate, 'yyyy-MM-dd')}" class="form-control" type="text" required> + </div> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">危害类型:</label> + <div class="col-sm-8"> + <select name="checkType" th:field="*{checkType}" class="form-control m-b" required id="checkType"> + <option value="">请选择</option> + <option value="1">事故隐患</option> + <option value="2">火灾隐患</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">罚款金额(元):</label> + <div class="col-sm-8"> + <input class="form-control" th:field="*{jobName}" type="number" name="jobName" id="jobName" required> + </div> + </div> +<!-- <input id="jobGroup" name="jobGroup" type="hidden" value="specialCheckTaskLog"/>--> + + </form> +</div> +<th:block th:include="include :: footer"/> +<th:block th:include="include :: datetimepicker-js"/> +<script th:inline="javascript"> + var prefix = ctx + "tr/tbBaseCheckScore"; + + $("input[name='checkDate']").datetimepicker({ + format: "yyyy-mm-dd", + minView: "month", + autoclose: true + }); + + + $("#form-job-edit").validate({ + onkeyup: false, + focusCleanup: true + }); + + function submitHandler() { + if ($.validate.form()){ + $.operate.save(prefix + "/edit", $('#form-job-edit').serialize()); + } + } +</script> +</body> +</html> diff --git a/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/specialCheckScoreAndDangerLog.html b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/specialCheckScoreAndDangerLog.html new file mode 100644 index 0000000..3bcffc0 --- /dev/null +++ b/src/main/resources/templates/tr/TBSpecialCheckScoreAndDangerLog/specialCheckScoreAndDangerLog.html @@ -0,0 +1,157 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro"> +<head> + <th:block th:include="include :: header('执行情况列表')"/> +</head> +<body class="gray-bg"> +<div class="container-div"> + <div class="row"> +<!-- <div class="col-sm-12 search-collapse">--> +<!-- <form id="jobLog-form">--> +<!-- <div class="select-list">--> +<!-- <ul>--> +<!-- <input id="jobId" name="jobId" type="hidden" th:value="${job!=null?job.jobId:''}"/>--> +<!-- <li>--> +<!-- 状态:<select name="scheduleCheckStatus">--> +<!-- <option value="">所有</option>--> +<!-- <option value="0">未排查</option>--> +<!-- <option value="1">已排查</option>--> +<!-- </select>--> +<!-- </li>--> +<!-- <li>--> +<!-- <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i--> +<!-- class="fa fa-search"></i> 搜索</a>--> +<!-- <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i--> +<!-- class="fa fa-refresh"></i> 重置</a>--> +<!-- </li>--> +<!-- </ul>--> +<!-- </div>--> +<!-- </form>--> +<!-- </div>--> + <div class="col-sm-12 search-collapse" style="display: none"> + <form id="formId"> + <div class="select-list"> + <ul> + + <input type="hidden" id="riskId" name="id" th:value="${id}"/> + + <li> + <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a> + <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a> + </li> + </ul> + </div> + </form> + </div> + <div class="btn-group-sm" id="toolbar" role="group"> + <a class="btn btn-success" onclick="$.operate.add()"> + <i class="fa fa-plus"></i> 新增 + </a> + </div> + <div class="col-sm-12 select-table table-striped"> + <table id="bootstrap-table"></table> + </div> + </div> +</div> +<th:block th:include="include :: footer"/> +<script th:inline="javascript"> + var prefix = ctx + "tr/TBSpecialCheckScoreAndDangerLog"; + + $(function () { + var options = { + url: prefix + "/list", + queryParams: queryParams, + cleanUrl: prefix + "/clean", + createUrl: prefix + "/add", + detailUrl: prefix + "/detail/{id}", + updateUrl: prefix + "/edit/{id}", + removeUrl: prefix + "/remove", + exportUrl: prefix + "/export", + sortName: "createTime", + sortOrder: "desc", + modalName: "评分记录", + columns: [ + { + title: "序号", + formatter: function (value, row, index) { + return $.table.serialNumber(index); + } + }, + { + field: 'dangerName', + title: '关联隐患信息' + }, + { + field: 'checkType', + title: '检查类型', + formatter: function (value, row, index) { + if (value == "1") { + return "企业自查"; + } else if (value == "2") { + return "市级及以下检查"; + } else if (value == "3") { + return "省级检查"; + } else{ + return "部级检查"; + } + } + }, + { + field: 'checkDate', + title: '检查日期' + }, + { + field: 'checkPay', + title: '罚款金额' + }, + { + field: 'harmType', + title: '危害类型', + align: 'center', + formatter: function (value, row, index) { + if (value == "1") { + return "事故隐患"; + } else if (value == "0") { + return "火灾隐患"; + } + } + }, + { + field: 'createBy', + title: '创建人' + }, + { + field: 'createDate', + title: '创建时间' + }, + { + field: 'updateBy', + title: '最后修改人' + }, + { + field: 'updateDate', + title: '修改时间' + }, + { + title: '操作', + align: 'center', + formatter: function (value, row, index) { + var actions = []; + actions.push('<a class="btn btn-success btn-xs" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> '); + actions.push('<a class="btn btn-info btn-xs" href="javascript:void(0)" onclick="$.operate.detail(\'' + row.id + '\')"><i class="fa fa-search"></i>详情</a> '); + return actions.join(''); + } + } + ] + }; + $.table.init(options); + }); + function queryParams(params) { + var search = $.table.queryParams(params); + // 所属风险单元 + search.id = $("#riskId").val(); + return search; + } +</script> +</body> +</html> \ No newline at end of file diff --git a/src/main/resources/templates/tr/specialCheckItemDangerLog/specialCheckItemDangerLog.html b/src/main/resources/templates/tr/specialCheckItemDangerLog/specialCheckItemDangerLog.html index 8076bac..88bbbfa 100644 --- a/src/main/resources/templates/tr/specialCheckItemDangerLog/specialCheckItemDangerLog.html +++ b/src/main/resources/templates/tr/specialCheckItemDangerLog/specialCheckItemDangerLog.html @@ -70,7 +70,7 @@ exportUrl: prefix + "/export", sortName: "createTime", sortOrder: "desc", - modalName: "任务上报", + modalName: "检查项上报", columns: [ { field: 'indexId', diff --git a/src/main/resources/templates/tr/tbBaseCheckItem/add.html b/src/main/resources/templates/tr/tbBaseCheckItem/add.html new file mode 100644 index 0000000..adc28c1 --- /dev/null +++ b/src/main/resources/templates/tr/tbBaseCheckItem/add.html @@ -0,0 +1,78 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org"> +<head> + <th:block th:include="include :: header('新增任务上报')"/> + <th:block th:include="include :: datetimepicker-css"/> +</head> +<body class="white-bg"> +<div class="wrapper wrapper-content animated fadeInRight ibox-content"> + <form class="form-horizontal m" id="form-job-add"> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">关联隐患:</label> + <div class="col-sm-8"> + <select id="hazardCode" name="hazardCode" class="form-control" required> + <option th:each="hazard : ${hazardList}" th:text="${hazard.riskListName}" th:value="${hazard.riskListNum}"></option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查类型:</label> + <div class="col-sm-8"> + <select name="checkType" class="form-control m-b" required id="checkType"> + <option value="">请选择</option> + <option value="1">企业自查</option> + <option value="2">市级及以下检查</option> + <option value="3">省级检查</option> + <option value="4">部级检查</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查日期:</label> + <div class="col-sm-8"> + <div class="input-group date"> + <span class="input-group-addon"><i class="fa fa-calendar"></i></span> + <input name="checkDate" class="form-control" placeholder="yyyy-MM-dd" type="text" required> + </div> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">危害类型:</label> + <div class="col-sm-8"> + <select name="checkType" class="form-control m-b" required id="checkType"> + <option value="">请选择</option> + <option value="1">事故隐患</option> + <option value="2">火灾隐患</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">罚款金额(元):</label> + <div class="col-sm-8"> + <input class="form-control" type="number" name="jobName" id="jobName" required> + </div> + </div> + </form> +</div> +<th:block th:include="include :: footer"/> +<th:block th:include="include :: datetimepicker-js"/> +<script type="text/javascript"> + $("input[name='checkDate']").datetimepicker({ + format: "yyyy-mm-dd", + minView: "month", + autoclose: true + }); + + $("#form-job-add").validate({ + onkeyup: false, + focusCleanup: true + }); + + function submitHandler() { + if ($.validate.form()){ + $.operate.save(prefix + "/add", $('#form-job-add').serialize()); + } + } +</script> +</body> +</html> diff --git a/src/main/resources/templates/tr/tbBaseCheckItem/detail.html b/src/main/resources/templates/tr/tbBaseCheckItem/detail.html new file mode 100644 index 0000000..2d27487 --- /dev/null +++ b/src/main/resources/templates/tr/tbBaseCheckItem/detail.html @@ -0,0 +1,83 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org"> +<head> + <th:block th:include="include :: header('修改检查任务')"/> + <th:block th:include="include :: datetimepicker-css"/> +</head> +<body class="white-bg"> +<div class="wrapper wrapper-content animated fadeInRight ibox-content"> + <form class="form-horizontal m" id="form-job-edit" th:object="${specialCheckTaskLog}"> + <input id="indexId" name="indexId" type="hidden" th:field="*{indexId}"/> + + + <!-- <input id="createUserId" name="createUserId" type="hidden" th:field="*{createUserId}"/>--> + <!-- <input id="createBy" name="createBy" type="hidden" th:field="*{createBy}"/>--> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">风险分析对象:</label> + <div class="col-sm-8"> + <select id="hazardCode" name="hazardCode" th:field="*{hazardCode}" class="form-control" required readonly="readonly"> + <option th:each="hazard : ${hazardList}" th:text="${hazard.riskListName}" th:value="${hazard.riskListNum}"></option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查类型:</label> + <div class="col-sm-8"> + <select name="checkType" th:field="*{checkType}" class="form-control m-b" required id="checkType" readonly="readonly"> + <option value="">请选择</option> + <option value="1">企业自查</option> + <option value="2">市级及以下检查</option> + <option value="3">省级检查</option> + <option value="4">部级检查</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查日期:</label> + <div class="col-sm-8"> + <div class="input-group date"> + <span class="input-group-addon"><i class="fa fa-calendar"></i></span> + <input name="checkDate" th:value="${#dates.format(specialCheckTaskLog.checkDate, 'yyyy-MM-dd')}" class="form-control" type="text" required readonly="readonly"> + </div> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">是否停产整顿:</label> + <div class="col-sm-8"> + <select name="resultStatus" th:field="*{resultStatus}" class="form-control m-b" required id="resultStatus" readonly="readonly"> + <option value="">请选择</option> + <option value="0">否</option> + <option value="1">是</option> + </select> + </div> + </div> + + <!-- <input id="jobGroup" name="jobGroup" type="hidden" value="specialCheckTaskLog"/>--> + + </form> +</div> +<th:block th:include="include :: footer"/> +<th:block th:include="include :: datetimepicker-js"/> +<script th:inline="javascript"> + var prefix = ctx + "tr/specialCheckTaskLog"; + + $("input[name='checkDate']").datetimepicker({ + format: "yyyy-mm-dd", + minView: "month", + autoclose: true + }); + + + $("#form-job-edit").validate({ + onkeyup: false, + focusCleanup: true + }); + + function submitHandler() { + if ($.validate.form()){ + $.operate.save(prefix + "/edit", $('#form-job-edit').serialize()); + } + } +</script> +</body> +</html> diff --git a/src/main/resources/templates/tr/tbBaseCheckItem/edit.html b/src/main/resources/templates/tr/tbBaseCheckItem/edit.html new file mode 100644 index 0000000..6fcf470 --- /dev/null +++ b/src/main/resources/templates/tr/tbBaseCheckItem/edit.html @@ -0,0 +1,88 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org"> +<head> + <th:block th:include="include :: header('检查项评分')"/> + <th:block th:include="include :: datetimepicker-css"/> +</head> +<body class="white-bg"> +<div class="wrapper wrapper-content animated fadeInRight ibox-content"> + <form class="form-horizontal m" id="form-job-edit" th:object="${specialCheckTaskLog}"> + <input id="id" name="id" type="hidden" th:field="*{id}"/> + + +<!-- <input id="createUserId" name="createUserId" type="hidden" th:field="*{createUserId}"/>--> +<!-- <input id="createBy" name="createBy" type="hidden" th:field="*{createBy}"/>--> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">关联隐患:</label> + <div class="col-sm-8"> + <select id="hazardCode" name="hazardCode" th:field="*{hazardCode}" class="form-control" required> + <option th:each="hazard : ${hazardList}" th:text="${hazard.riskListName}" th:value="${hazard.riskListNum}"></option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查类型:</label> + <div class="col-sm-8"> + <select name="checkType" th:field="*{checkType}" class="form-control m-b" required id="checkType"> + <option value="">请选择</option> + <option value="1">企业自查</option> + <option value="2">市级及以下检查</option> + <option value="3">省级检查</option> + <option value="4">部级检查</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">检查日期:</label> + <div class="col-sm-8"> + <div class="input-group date"> + <span class="input-group-addon"><i class="fa fa-calendar"></i></span> + <input name="checkDate" th:value="${#dates.format(specialCheckTaskLog.checkDate, 'yyyy-MM-dd')}" class="form-control" type="text" required> + </div> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">危害类型:</label> + <div class="col-sm-8"> + <select name="checkType" th:field="*{checkType}" class="form-control m-b" required id="checkType"> + <option value="">请选择</option> + <option value="1">事故隐患</option> + <option value="2">火灾隐患</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">罚款金额(元):</label> + <div class="col-sm-8"> + <input class="form-control" th:field="*{jobName}" type="number" name="jobName" id="jobName" required> + </div> + </div> +<!-- <input id="jobGroup" name="jobGroup" type="hidden" value="specialCheckTaskLog"/>--> + + </form> +</div> +<th:block th:include="include :: footer"/> +<th:block th:include="include :: datetimepicker-js"/> +<script th:inline="javascript"> + var prefix = ctx + "tr/tbBaseCheckScore"; + + $("input[name='checkDate']").datetimepicker({ + format: "yyyy-mm-dd", + minView: "month", + autoclose: true + }); + + + $("#form-job-edit").validate({ + onkeyup: false, + focusCleanup: true + }); + + function submitHandler() { + if ($.validate.form()){ + $.operate.save(prefix + "/edit", $('#form-job-edit').serialize()); + } + } +</script> +</body> +</html> diff --git a/src/main/resources/templates/tr/tbBaseCheckItem/selectTbBaseCheckItemPage.html b/src/main/resources/templates/tr/tbBaseCheckItem/selectTbBaseCheckItemPage.html new file mode 100644 index 0000000..03ca3c7 --- /dev/null +++ b/src/main/resources/templates/tr/tbBaseCheckItem/selectTbBaseCheckItemPage.html @@ -0,0 +1,130 @@ +<!DOCTYPE html> +<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro"> +<head> + <th:block th:include="include :: header('执行情况列表')"/> +</head> +<body class="gray-bg"> +<div class="container-div"> + <div class="row"> +<!-- <div class="col-sm-12 search-collapse">--> +<!-- <form id="jobLog-form">--> +<!-- <div class="select-list">--> +<!-- <ul>--> +<!-- <input id="jobId" name="jobId" type="hidden" th:value="${job!=null?job.jobId:''}"/>--> +<!-- <li>--> +<!-- 状态:<select name="scheduleCheckStatus">--> +<!-- <option value="">所有</option>--> +<!-- <option value="0">未排查</option>--> +<!-- <option value="1">已排查</option>--> +<!-- </select>--> +<!-- </li>--> +<!-- <li>--> +<!-- <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i--> +<!-- class="fa fa-search"></i> 搜索</a>--> +<!-- <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i--> +<!-- class="fa fa-refresh"></i> 重置</a>--> +<!-- </li>--> +<!-- </ul>--> +<!-- </div>--> +<!-- </form>--> +<!-- </div>--> + <div class="col-sm-12 search-collapse" style="display: none"> + <form id="formId"> + <div class="select-list"> + <ul> + + <input type="hidden" id="riskId" name="id" th:value="${id}"/> + + <li> + <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a> + <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a> + </li> + </ul> + </div> + </form> + </div> +<!-- <div class="btn-group-sm" id="toolbar" role="group">--> +<!-- <a class="btn btn-success" onclick="$.operate.add()">--> +<!-- <i class="fa fa-plus"></i> 新增--> +<!-- </a>--> +<!-- </div>--> + <div class="col-sm-12 select-table table-striped"> + <table id="bootstrap-table"></table> + </div> + </div> +</div> +<th:block th:include="include :: footer"/> +<script th:inline="javascript"> + var prefix = ctx + "tr/tbBaseCheckScore"; + + $(function () { + var options = { + url: prefix + "/list", + queryParams: queryParams, + cleanUrl: prefix + "/clean", + createUrl: prefix + "/add", + detailUrl: prefix + "/detail/{id}", + updateUrl: prefix + "/edit/{id}", + removeUrl: prefix + "/remove", + exportUrl: prefix + "/export", + sortName: "createTime", + sortOrder: "desc", + modalName: "任务上报", + columns: [ + { + title: "序号", + formatter: function (value, row, index) { + return $.table.serialNumber(index); + } + }, + { + field: 'isReject', + title: '是否为否决项', + align: 'center', + formatter: function (value, row, index) { + if (value == "1") { + return "是"; + } else if (value == "0") { + return "否"; + } + } + }, + { + field: 'deductIllustrate', + title: '扣分说明' + }, + { + field: 'deductPoint', + title: '扣分分值' + }, + { + field: 'createDate', + title: '创建时间' + }, + { + field: 'updateDate', + title: '修改时间' + }, + { + title: '操作', + align: 'center', + formatter: function (value, row, index) { + var actions = []; + actions.push('<a class="btn btn-success btn-xs" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>评分</a> '); + actions.push("<a class='btn btn-warning btn-xs' href='#' onclick='$.operate.detail(" + row.id + ")'><i class='fa fa-search'></i>评分记录</a> "); + return actions.join(''); + } + } + ] + }; + $.table.init(options); + }); + function queryParams(params) { + var search = $.table.queryParams(params); + // 所属风险单元 + search.id = $("#riskId").val(); + return search; + } +</script> +</body> +</html> \ No newline at end of file diff --git a/src/main/resources/templates/tr/tbBaseCheckScore/add.html b/src/main/resources/templates/tr/tbBaseCheckScore/add.html index 71df032..adc28c1 100644 --- a/src/main/resources/templates/tr/tbBaseCheckScore/add.html +++ b/src/main/resources/templates/tr/tbBaseCheckScore/add.html @@ -8,7 +8,7 @@ <div class="wrapper wrapper-content animated fadeInRight ibox-content"> <form class="form-horizontal m" id="form-job-add"> <div class="form-group"> - <label class="col-sm-3 control-label is-required">风险分析对象:</label> + <label class="col-sm-3 control-label is-required">关联隐患:</label> <div class="col-sm-8"> <select id="hazardCode" name="hazardCode" class="form-control" required> <option th:each="hazard : ${hazardList}" th:text="${hazard.riskListName}" th:value="${hazard.riskListNum}"></option> @@ -37,15 +37,21 @@ </div> </div> <div class="form-group"> - <label class="col-sm-3 control-label is-required">是否停产整顿:</label> + <label class="col-sm-3 control-label is-required">危害类型:</label> <div class="col-sm-8"> - <select name="resultStatus" class="form-control m-b" required id="resultStatus"> + <select name="checkType" class="form-control m-b" required id="checkType"> <option value="">请选择</option> - <option value="0">否</option> - <option value="1">是</option> + <option value="1">事故隐患</option> + <option value="2">火灾隐患</option> </select> </div> </div> + <div class="form-group"> + <label class="col-sm-3 control-label is-required">罚款金额(元):</label> + <div class="col-sm-8"> + <input class="form-control" type="number" name="jobName" id="jobName" required> + </div> + </div> </form> </div> <th:block th:include="include :: footer"/> diff --git a/src/main/resources/templates/tr/tbBaseCheckScore/edit.html b/src/main/resources/templates/tr/tbBaseCheckScore/edit.html index fbbfe9a..6fcf470 100644 --- a/src/main/resources/templates/tr/tbBaseCheckScore/edit.html +++ b/src/main/resources/templates/tr/tbBaseCheckScore/edit.html @@ -1,19 +1,19 @@ <!DOCTYPE html> <html lang="zh" xmlns:th="http://www.thymeleaf.org"> <head> - <th:block th:include="include :: header('修改检查任务')"/> + <th:block th:include="include :: header('检查项评分')"/> <th:block th:include="include :: datetimepicker-css"/> </head> <body class="white-bg"> <div class="wrapper wrapper-content animated fadeInRight ibox-content"> <form class="form-horizontal m" id="form-job-edit" th:object="${specialCheckTaskLog}"> - <input id="indexId" name="indexId" type="hidden" th:field="*{indexId}"/> + <input id="id" name="id" type="hidden" th:field="*{id}"/> <!-- <input id="createUserId" name="createUserId" type="hidden" th:field="*{createUserId}"/>--> <!-- <input id="createBy" name="createBy" type="hidden" th:field="*{createBy}"/>--> <div class="form-group"> - <label class="col-sm-3 control-label is-required">风险分析对象:</label> + <label class="col-sm-3 control-label is-required">关联隐患:</label> <div class="col-sm-8"> <select id="hazardCode" name="hazardCode" th:field="*{hazardCode}" class="form-control" required> <option th:each="hazard : ${hazardList}" th:text="${hazard.riskListName}" th:value="${hazard.riskListNum}"></option> @@ -42,16 +42,21 @@ </div> </div> <div class="form-group"> - <label class="col-sm-3 control-label is-required">是否停产整顿:</label> + <label class="col-sm-3 control-label is-required">危害类型:</label> <div class="col-sm-8"> - <select name="resultStatus" th:field="*{resultStatus}" class="form-control m-b" required id="resultStatus"> + <select name="checkType" th:field="*{checkType}" class="form-control m-b" required id="checkType"> <option value="">请选择</option> - <option value="0">否</option> - <option value="1">是</option> + <option value="1">事故隐患</option> + <option value="2">火灾隐患</option> </select> </div> </div> - + <div class="form-group"> + <label class="col-sm-3 control-label is-required">罚款金额(元):</label> + <div class="col-sm-8"> + <input class="form-control" th:field="*{jobName}" type="number" name="jobName" id="jobName" required> + </div> + </div> <!-- <input id="jobGroup" name="jobGroup" type="hidden" value="specialCheckTaskLog"/>--> </form> @@ -59,7 +64,7 @@ <th:block th:include="include :: footer"/> <th:block th:include="include :: datetimepicker-js"/> <script th:inline="javascript"> - var prefix = ctx + "tr/specialCheckTaskLog"; + var prefix = ctx + "tr/tbBaseCheckScore"; $("input[name='checkDate']").datetimepicker({ format: "yyyy-mm-dd", diff --git a/src/main/resources/templates/tr/tbBaseCheckScore/selectTbBaseCheckScorePage.html b/src/main/resources/templates/tr/tbBaseCheckScore/selectTbBaseCheckScorePage.html index 9fb9a07..795acc5 100644 --- a/src/main/resources/templates/tr/tbBaseCheckScore/selectTbBaseCheckScorePage.html +++ b/src/main/resources/templates/tr/tbBaseCheckScore/selectTbBaseCheckScorePage.html @@ -63,29 +63,39 @@ queryParams: queryParams, cleanUrl: prefix + "/clean", createUrl: prefix + "/add", - detailUrl: prefix + "/detail/{id}", + detailUrl: "/tr/TBSpecialCheckScoreAndDangerLog/{id}", updateUrl: prefix + "/edit/{id}", removeUrl: prefix + "/remove", exportUrl: prefix + "/export", sortName: "createTime", sortOrder: "desc", - modalName: "任务上报", + modalName: "评分细则", columns: [ { - field: 'indexId', - title: '检查序号' + title: "序号", + formatter: function (value, row, index) { + return $.table.serialNumber(index); + } }, { - field: 'checkContent', - title: '检查内容' + field: 'isReject', + title: '是否为否决项', + align: 'center', + formatter: function (value, row, index) { + if (value == "1") { + return "是"; + } else if (value == "0") { + return "否"; + } + } }, { - field: 'checkBasis', - title: '检查依据' + field: 'deductIllustrate', + title: '扣分说明' }, { - field: 'applicablePlace', - title: '适用场所' + field: 'deductPoint', + title: '扣分分值' }, { field: 'createDate', @@ -100,8 +110,8 @@ align: 'center', formatter: function (value, row, index) { var actions = []; - actions.push("<a class='btn btn-warning btn-xs' href='#' onclick='$.operate.edit(" + row.id + ")'><i class='fa fa-edit'></i>评分</a> "); - actions.push("<a class='btn btn-warning btn-xs' href='#' onclick='$.operate.detail(" + row.id + ")'><i class='fa fa-search'></i>评分记录</a> "); + // actions.push('<a class="btn btn-success btn-xs" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>评分</a> '); + actions.push('<a class="btn btn-info btn-xs " href="javascript:void(0)" onclick="$.operate.detail(\'' + row.id + '\',1600)"><i class="fa fa-edit"></i>评分记录</a> '); return actions.join(''); } } @@ -109,6 +119,7 @@ }; $.table.init(options); }); + function queryParams(params) { var search = $.table.queryParams(params); // 所属风险单元 -- Gitblit v1.9.2