From a9bf47642abf1e40a74beb44e891a3e01834e81c Mon Sep 17 00:00:00 2001 From: ly19960718 <1622779752@qq.com> Date: Thu, 17 Jun 2021 16:35:39 +0800 Subject: [PATCH] =?UTF-8?q?web=E9=A1=B5=E9=9D=A2=E6=9D=83=E9=99=90?= =?UTF-8?q?=E5=88=86=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/indexaudit/IndexAuditController.java | 69 +++++++++ .../IndexAuditLogController.java | 19 +++ .../IndexTemplateController.java | 12 ++ .../controller/route/indexWebController.java | 34 +++-- .../pojo/dtos/indexaudit/IndexAuditDTO.java | 29 ++++ .../dtos/indexauditlog/IndexAuditLogDTO.java | 8 + .../twoduty/pojo/vos/indexaudit/AuditVO.java | 38 +++++ .../pojo/vos/indexaudit/IndexAuditVO.java | 10 -- .../indexaudit/IIndexAuditService.java | 9 ++ .../impl/IndexAuditServiceImpl.java | 37 ++++- .../impl/IndexGeneralServiceImpl.java | 18 ++- .../twoduty/utils/AuditStatusEnum.java | 2 +- .../mapper/indexaudit/index-audit-mapper.xml | 25 ++-- .../indexauditlog/index-audit-log-mapper.xml | 14 +- .../static/route/indexaudit/audit.html | 137 +++++++++++++++++ .../static/route/indexaudit/list_1.html | 141 ++++++++---------- .../static/route/indexaudit/list_2.html | 127 +++++++--------- .../static/route/indexaudit/list_3.html | 126 +++++++--------- .../static/route/indexaudit/list_4.html | 132 +++++++--------- .../static/route/indexauditlog/show.html | 127 ++++++++++++++++ 20 files changed, 775 insertions(+), 339 deletions(-) create mode 100644 src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/AuditVO.java create mode 100644 src/main/resources/static/route/indexaudit/audit.html create mode 100644 src/main/resources/static/route/indexauditlog/show.html diff --git a/src/main/java/com/tenlion/twoduty/controller/api/indexaudit/IndexAuditController.java b/src/main/java/com/tenlion/twoduty/controller/api/indexaudit/IndexAuditController.java index 94ca7a5..4cac926 100644 --- a/src/main/java/com/tenlion/twoduty/controller/api/indexaudit/IndexAuditController.java +++ b/src/main/java/com/tenlion/twoduty/controller/api/indexaudit/IndexAuditController.java @@ -1,7 +1,13 @@ package com.tenlion.twoduty.controller.api.indexaudit; +import com.tenlion.twoduty.pojo.dtos.indexlib.IndexLibDTO; +import com.tenlion.twoduty.pojo.dtos.indextemplate.IndexTemplateDTO; +import com.tenlion.twoduty.pojo.vos.indexaudit.AuditVO; +import com.tenlion.twoduty.service.indexlib.IIndexLibService; +import com.tenlion.twoduty.service.indextemplate.IIndexTemplateService; import ink.wgink.annotation.CheckRequestBodyAnnotation; import ink.wgink.common.base.DefaultBaseController; +import ink.wgink.exceptions.SearchException; import ink.wgink.interfaces.consts.ISystemConstant; import ink.wgink.pojo.ListPage; import ink.wgink.pojo.result.ErrorResult; @@ -12,6 +18,7 @@ import com.tenlion.twoduty.pojo.dtos.indexaudit.IndexAuditDTO; import com.tenlion.twoduty.pojo.vos.indexaudit.IndexAuditVO; import com.tenlion.twoduty.service.indexaudit.IIndexAuditService; import io.swagger.annotations.*; +import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; @@ -33,6 +40,68 @@ public class IndexAuditController extends DefaultBaseController { @Autowired private IIndexAuditService indexAuditService; + @Autowired + private IIndexLibService iIndexLibService; + @Autowired + private IIndexTemplateService iIndexTemplateService; + + + + + @ApiOperation(value = "审核指标配置详情", notes = "审核指标配置详情接口") + @ApiImplicitParams({ + @ApiImplicitParam(name = "indexAuditId", value = "指标审核表ID", paramType = "path") + }) + @ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)}) + @GetMapping("getAuditIndexConfig/{indexAuditId}") + public IndexTemplateDTO getAuditIndexConfig(@PathVariable("indexAuditId") String indexAuditId){ + IndexAuditDTO indexAuditDTO = indexAuditService.get(indexAuditId); + if(indexAuditDTO == null){ + throw new SearchException("系统错误-1"); + } + String indexLibId = indexAuditDTO.getIndexLibId(); + if(StringUtils.isBlank(indexLibId)){ + throw new SearchException("系统错误-2"); + } + IndexLibDTO indexLibDTO = iIndexLibService.get(indexLibId); + if(indexLibDTO == null){ + throw new SearchException("系统错误-3"); + } + String indexTemplateId = indexLibDTO.getIndexTemplateId(); + if(StringUtils.isBlank(indexTemplateId)){ + throw new SearchException("该指标未绑定模板"); + } + IndexTemplateDTO indexTemplateDTO = iIndexTemplateService.get(indexTemplateId); + if(indexTemplateDTO == null){ + throw new SearchException("未获取到模板信息"); + } + return indexTemplateDTO; + } + + + + + + + + + + + @ApiOperation(value = "审核指标审核表", notes = "审核指标审核表接口") + @ApiImplicitParams({ + @ApiImplicitParam(name = "indexAuditId", value = "指标审核表ID", paramType = "path") + }) + @ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)}) + @PutMapping("audit/{indexAuditId}") + @CheckRequestBodyAnnotation + public SuccessResult audit(@PathVariable("indexAuditId") String indexAuditId, @RequestBody AuditVO auditVO) { + indexAuditService.audit(null,indexAuditId, auditVO); + return new SuccessResult(); + } + + + + @ApiOperation(value = "新增指标审核表", notes = "新增指标审核表接口") @ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)}) diff --git a/src/main/java/com/tenlion/twoduty/controller/api/indexauditlog/IndexAuditLogController.java b/src/main/java/com/tenlion/twoduty/controller/api/indexauditlog/IndexAuditLogController.java index 9a1f750..8d7558f 100644 --- a/src/main/java/com/tenlion/twoduty/controller/api/indexauditlog/IndexAuditLogController.java +++ b/src/main/java/com/tenlion/twoduty/controller/api/indexauditlog/IndexAuditLogController.java @@ -16,6 +16,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; import java.util.Arrays; +import java.util.HashMap; import java.util.List; import java.util.Map; @@ -34,6 +35,24 @@ public class IndexAuditLogController extends DefaultBaseController { @Autowired private IIndexAuditLogService indexAuditLogService; + @ApiOperation(value = "指标审核日志表详情", notes = "指标审核日志表详情接口") + @ApiImplicitParams({ + @ApiImplicitParam(name = "indexAuditLogId", value = "指标审核日志表ID", paramType = "path") + }) + @ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)}) + @GetMapping("list_by_indexauditid/{indexAuditId}") + public List listByIndexAuditId(@PathVariable("indexAuditId") String indexAuditId){ + Map params = new HashMap<>(1); + params.put("indexAuditId",indexAuditId); + return indexAuditLogService.list(params); + } + + + + + + + @ApiOperation(value = "新增指标审核日志表", notes = "新增指标审核日志表接口") @ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)}) @PostMapping("save") diff --git a/src/main/java/com/tenlion/twoduty/controller/api/indextemplate/IndexTemplateController.java b/src/main/java/com/tenlion/twoduty/controller/api/indextemplate/IndexTemplateController.java index 8a4b454..791ed19 100644 --- a/src/main/java/com/tenlion/twoduty/controller/api/indextemplate/IndexTemplateController.java +++ b/src/main/java/com/tenlion/twoduty/controller/api/indextemplate/IndexTemplateController.java @@ -34,6 +34,18 @@ public class IndexTemplateController extends DefaultBaseController { @Autowired private IIndexTemplateService indexTemplateService; + + + + + + + + + + + + @ApiOperation(value = "新增", notes = "新增接口") @ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)}) @PostMapping("save") diff --git a/src/main/java/com/tenlion/twoduty/controller/route/indexWebController.java b/src/main/java/com/tenlion/twoduty/controller/route/indexWebController.java index 1cbb10d..930a068 100644 --- a/src/main/java/com/tenlion/twoduty/controller/route/indexWebController.java +++ b/src/main/java/com/tenlion/twoduty/controller/route/indexWebController.java @@ -5,6 +5,7 @@ import ink.wgink.common.base.DefaultBaseController; import ink.wgink.common.component.SecurityComponent; import ink.wgink.interfaces.consts.ISystemConstant; import ink.wgink.pojo.bos.UserInfoBO; +import ink.wgink.pojo.pos.DepartmentPO; import ink.wgink.pojo.pos.RolePO; import ink.wgink.properties.ServerProperties; import io.swagger.annotations.Api; @@ -16,7 +17,9 @@ import org.springframework.web.bind.annotation.RestController; import org.springframework.web.servlet.ModelAndView; import java.util.ArrayList; +import java.util.HashMap; import java.util.List; +import java.util.Map; /** * TODO @@ -48,12 +51,8 @@ public class indexWebController extends DefaultBaseController { @GetMapping("indexweb") public ModelAndView indexWeb(){ ModelAndView mv = new ModelAndView("index"); - UserInfoBO currentUser = securityComponent.getCurrentUser(); - - - mv.addObject("userName",currentUser.getUserName()); - mv.addObject("userUserName",currentUser.getUserUsername()); mv.addObject("systemTitle",serverProperties.getSystemTitle()); + mv.addObject("userParams",this.initUserParams()); return mv; } @@ -81,6 +80,17 @@ public class indexWebController extends DefaultBaseController { } + public Map initUserParams(){ + Map params = new HashMap<>(10); + UserInfoBO currentUser = securityComponent.getCurrentUser(); + params.put("userName",currentUser.getUserName()); + params.put("userUserName",currentUser.getUserUsername()); + params.put("departmentId",this.initDepartmentId(currentUser)); + params.put("initButton",this.initWebButton(currentUser)); + return params; + } + + public List initWebButton(UserInfoBO currentUser){ @@ -90,16 +100,22 @@ public class indexWebController extends DefaultBaseController { return list; } for (RolePO role : roles) { - if(ROLE_CODE_1.equals(role.getRoleCode())){ + if(ROLE_CODE_2.equals(role.getRoleCode())){ list.add("1"); list.add("2"); } - if(ROLE_CODE_2.equals(role.getRoleCode())){ - list.add("3"); - } } return list; } + public String initDepartmentId(UserInfoBO currentUser){ + List departments = currentUser.getDepartments(); + if(departments.size() == 0){ + return "0"; + } + return departments.get(0).getDepartmentId(); + } + + } diff --git a/src/main/java/com/tenlion/twoduty/pojo/dtos/indexaudit/IndexAuditDTO.java b/src/main/java/com/tenlion/twoduty/pojo/dtos/indexaudit/IndexAuditDTO.java index d8f7fac..44ef2d1 100644 --- a/src/main/java/com/tenlion/twoduty/pojo/dtos/indexaudit/IndexAuditDTO.java +++ b/src/main/java/com/tenlion/twoduty/pojo/dtos/indexaudit/IndexAuditDTO.java @@ -18,6 +18,8 @@ public class IndexAuditDTO { private String indexAuditId; @ApiModelProperty(name = "indexLibId", value = "指标ID") private String indexLibId; + @ApiModelProperty(name = "indexLibName", value = "指标名称") + private String indexLibName; @ApiModelProperty(name = "indexBId", value = "指标业务ID") private String indexBId; @ApiModelProperty(name = "indexBTitle", value = "上报标题") @@ -26,6 +28,10 @@ public class IndexAuditDTO { private Integer indexAuditStatus; @ApiModelProperty(name = "indexAuditUserId", value = "审核人ID") private String indexAuditUserId; + @ApiModelProperty(name = "creatorName", value = "上报人") + private String creatorName; + @ApiModelProperty(name = "gmtCreate", value = "上报时间") + private String gmtCreate; public String getIndexAuditId() { return indexAuditId == null ? "" : indexAuditId.trim(); @@ -76,4 +82,27 @@ public class IndexAuditDTO { } + public String getIndexLibName() { + return indexLibName; + } + + public void setIndexLibName(String indexLibName) { + this.indexLibName = indexLibName; + } + + public String getCreatorName() { + return creatorName; + } + + public void setCreatorName(String creatorName) { + this.creatorName = creatorName; + } + + public String getGmtCreate() { + return gmtCreate; + } + + public void setGmtCreate(String gmtCreate) { + this.gmtCreate = gmtCreate; + } } diff --git a/src/main/java/com/tenlion/twoduty/pojo/dtos/indexauditlog/IndexAuditLogDTO.java b/src/main/java/com/tenlion/twoduty/pojo/dtos/indexauditlog/IndexAuditLogDTO.java index 7edf511..e2bc747 100644 --- a/src/main/java/com/tenlion/twoduty/pojo/dtos/indexauditlog/IndexAuditLogDTO.java +++ b/src/main/java/com/tenlion/twoduty/pojo/dtos/indexauditlog/IndexAuditLogDTO.java @@ -24,6 +24,8 @@ public class IndexAuditLogDTO { private String indexAuditStates; @ApiModelProperty(name = "creator", value = "创建人") private String creator; + @ApiModelProperty(name = "creatorName", value = "创建人中文") + private String creatorName; @ApiModelProperty(name = "gmtModified", value = "创建时间") private String gmtModified; @@ -75,5 +77,11 @@ public class IndexAuditLogDTO { this.gmtModified = gmtModified; } + public String getCreatorName() { + return creatorName; + } + public void setCreatorName(String creatorName) { + this.creatorName = creatorName; + } } diff --git a/src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/AuditVO.java b/src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/AuditVO.java new file mode 100644 index 0000000..4488aa8 --- /dev/null +++ b/src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/AuditVO.java @@ -0,0 +1,38 @@ +package com.tenlion.twoduty.pojo.vos.indexaudit; + + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; + +/** + * + * @ClassName: AuditVO + * @Description: 审核实体 + * @Author: CodeFactory + * @Date: 2021-06-16 17:31:45 + * @Version: 3.0 + **/ +@ApiModel +public class AuditVO { + @ApiModelProperty(name = "indexAuditStates", value = "审核状态") + private String indexAuditStates; + @ApiModelProperty(name = "indexAuditContent", value = "审核内容") + private String indexAuditContent; + + + public String getIndexAuditStates() { + return indexAuditStates; + } + + public void setIndexAuditStates(String indexAuditStates) { + this.indexAuditStates = indexAuditStates; + } + + public String getIndexAuditContent() { + return indexAuditContent; + } + + public void setIndexAuditContent(String indexAuditContent) { + this.indexAuditContent = indexAuditContent; + } +} diff --git a/src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/IndexAuditVO.java b/src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/IndexAuditVO.java index 9af358f..742ba7e 100644 --- a/src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/IndexAuditVO.java +++ b/src/main/java/com/tenlion/twoduty/pojo/vos/indexaudit/IndexAuditVO.java @@ -22,9 +22,6 @@ public class IndexAuditVO { private String indexBId; @ApiModelProperty(name = "indexBTitle", value = "上报标题") private String indexBTitle; - @ApiModelProperty(name = "indexAuditStatus", value = "审核状态:0 待审核 1审核通过 2已归档 -1审核不通过") - @CheckNumberAnnotation(name = "审核状态:0 待审核 1审核通过 2已归档 -1审核不通过") - private Integer indexAuditStatus; @ApiModelProperty(name = "indexAuditUserId", value = "审核人ID") private String indexAuditUserId; @@ -52,13 +49,6 @@ public class IndexAuditVO { this.indexBTitle = indexBTitle; } - public Integer getIndexAuditStatus() { - return indexAuditStatus == null ? 0 : indexAuditStatus; - } - - public void setIndexAuditStatus(Integer indexAuditStatus) { - this.indexAuditStatus = indexAuditStatus; - } public String getIndexAuditUserId() { return indexAuditUserId == null ? "" : indexAuditUserId.trim(); diff --git a/src/main/java/com/tenlion/twoduty/service/indexaudit/IIndexAuditService.java b/src/main/java/com/tenlion/twoduty/service/indexaudit/IIndexAuditService.java index a98c44d..67c5b40 100644 --- a/src/main/java/com/tenlion/twoduty/service/indexaudit/IIndexAuditService.java +++ b/src/main/java/com/tenlion/twoduty/service/indexaudit/IIndexAuditService.java @@ -1,5 +1,6 @@ package com.tenlion.twoduty.service.indexaudit; +import com.tenlion.twoduty.pojo.vos.indexaudit.AuditVO; import ink.wgink.pojo.ListPage; import ink.wgink.pojo.result.SuccessResultList; import com.tenlion.twoduty.pojo.dtos.indexaudit.IndexAuditDTO; @@ -19,6 +20,14 @@ import java.util.Map; **/ public interface IIndexAuditService { + /** + * 审核接口 + * @param token + * @param indexAuditId + * @param auditVO + */ + void audit(String token, String indexAuditId, AuditVO auditVO); + /** * 新增指标审核表 * diff --git a/src/main/java/com/tenlion/twoduty/service/indexaudit/impl/IndexAuditServiceImpl.java b/src/main/java/com/tenlion/twoduty/service/indexaudit/impl/IndexAuditServiceImpl.java index a514cfd..845e72d 100644 --- a/src/main/java/com/tenlion/twoduty/service/indexaudit/impl/IndexAuditServiceImpl.java +++ b/src/main/java/com/tenlion/twoduty/service/indexaudit/impl/IndexAuditServiceImpl.java @@ -1,7 +1,9 @@ package com.tenlion.twoduty.service.indexaudit.impl; +import com.tenlion.twoduty.pojo.vos.indexaudit.AuditVO; import com.tenlion.twoduty.pojo.vos.indexauditlog.IndexAuditLogVO; import com.tenlion.twoduty.service.indexauditlog.IIndexAuditLogService; +import com.tenlion.twoduty.utils.AuditStatusEnum; import ink.wgink.common.base.DefaultBaseService; import ink.wgink.pojo.ListPage; import ink.wgink.pojo.result.SuccessResult; @@ -40,6 +42,25 @@ public class IndexAuditServiceImpl extends DefaultBaseService implements IIndexA + public void audit(String token,String indexAuditId,AuditVO auditVO){ + Map params = new HashMap<>(5); + params.put("indexAuditId",indexAuditId); + params.put("indexAuditStatus",auditVO.getIndexAuditStates()); + if (StringUtils.isBlank(token)) { + setSaveInfo(params); + } else { + setAppSaveInfo(token, params); + } + indexAuditDao.update(params); + //新增审核日志 + this.saveAuditLog(indexAuditId,auditVO.getIndexAuditStates(),auditVO.getIndexAuditContent()); + //修改业务表状态 + + + + + + } @@ -67,6 +88,7 @@ public class IndexAuditServiceImpl extends DefaultBaseService implements IIndexA String indexAuditId = UUIDUtil.getUUID(); Map params = HashMapUtil.beanToMap(indexAuditVO); params.put("indexAuditId", indexAuditId); + params.put("indexAuditStatus", AuditStatusEnum.NORMAL.getAuditStatus()); if (StringUtils.isBlank(token)) { setSaveInfo(params); } else { @@ -74,10 +96,7 @@ public class IndexAuditServiceImpl extends DefaultBaseService implements IIndexA } indexAuditDao.save(params); //新增上报日志 - IndexAuditLogVO indexAuditLogVO = new IndexAuditLogVO(); - indexAuditLogVO.setIndexAuditStates("0"); - indexAuditLogVO.setIndexAuditContent("上报指标"); - iIndexAuditLogService.save(indexAuditLogVO); + this.saveAuditLog(indexAuditId,"00","上报指标"); return indexAuditId; } @@ -187,4 +206,14 @@ public class IndexAuditServiceImpl extends DefaultBaseService implements IIndexA return count == null ? 0 : count; } + + public void saveAuditLog(String auditId,String states,String content){ + IndexAuditLogVO indexAuditLogVO = new IndexAuditLogVO(); + indexAuditLogVO.setIndexAuditId(auditId); + indexAuditLogVO.setIndexAuditStates(states); + indexAuditLogVO.setIndexAuditContent(content); + iIndexAuditLogService.save(indexAuditLogVO); + } + + } \ No newline at end of file diff --git a/src/main/java/com/tenlion/twoduty/service/indexgeneral/impl/IndexGeneralServiceImpl.java b/src/main/java/com/tenlion/twoduty/service/indexgeneral/impl/IndexGeneralServiceImpl.java index 737d69e..59ba167 100644 --- a/src/main/java/com/tenlion/twoduty/service/indexgeneral/impl/IndexGeneralServiceImpl.java +++ b/src/main/java/com/tenlion/twoduty/service/indexgeneral/impl/IndexGeneralServiceImpl.java @@ -1,6 +1,8 @@ package com.tenlion.twoduty.service.indexgeneral.impl; +import com.tenlion.twoduty.pojo.vos.indexaudit.IndexAuditVO; import com.tenlion.twoduty.pojo.vos.indexauditlog.IndexAuditLogVO; +import com.tenlion.twoduty.service.indexaudit.IIndexAuditService; import com.tenlion.twoduty.service.indexauditlog.IIndexAuditLogService; import com.tenlion.twoduty.utils.AuditStatusEnum; import ink.wgink.common.base.DefaultBaseService; @@ -37,7 +39,7 @@ public class IndexGeneralServiceImpl extends DefaultBaseService implements IInde @Autowired private IIndexGeneralDao indexGeneralDao; @Autowired - private IIndexAuditLogService iIndexAuditLogService; + private IIndexAuditService iIndexAuditService; @Override public void save(IndexGeneralVO indexGeneralVO) { @@ -66,9 +68,23 @@ public class IndexGeneralServiceImpl extends DefaultBaseService implements IInde setAppSaveInfo(token, params); } indexGeneralDao.save(params); + this.saveAudit(indexGeneralId,indexGeneralVO.getIndexGeneralTitle(),indexGeneralVO.getDutyIndexLibId()); return indexGeneralId; } + + public void saveAudit(String bId,String bTitle,String indexLibId){ + IndexAuditVO indexAuditVO = new IndexAuditVO(); + indexAuditVO.setIndexAuditUserId(""); + indexAuditVO.setIndexBId(bId); + indexAuditVO.setIndexBTitle(bTitle); + indexAuditVO.setIndexLibId(indexLibId); + iIndexAuditService.save(indexAuditVO); + } + + + + @Override public void remove(List ids) { remove(null, ids); diff --git a/src/main/java/com/tenlion/twoduty/utils/AuditStatusEnum.java b/src/main/java/com/tenlion/twoduty/utils/AuditStatusEnum.java index 89338b6..02d86d2 100644 --- a/src/main/java/com/tenlion/twoduty/utils/AuditStatusEnum.java +++ b/src/main/java/com/tenlion/twoduty/utils/AuditStatusEnum.java @@ -9,7 +9,7 @@ package com.tenlion.twoduty.utils; */ public enum AuditStatusEnum { - NORMAL("0"),WAIT("1"), PASS("2"), UN_PASS("-1"),; + NORMAL("0"),WAIT("1"), PASS("2"), UN_PASS("-1"); private final String auditStatus; diff --git a/src/main/resources/mybatis/mapper/indexaudit/index-audit-mapper.xml b/src/main/resources/mybatis/mapper/indexaudit/index-audit-mapper.xml index 6e3875a..0901864 100644 --- a/src/main/resources/mybatis/mapper/indexaudit/index-audit-mapper.xml +++ b/src/main/resources/mybatis/mapper/indexaudit/index-audit-mapper.xml @@ -5,10 +5,14 @@ + + + + @@ -99,24 +103,14 @@ UPDATE duty_index_audit SET - - index_lib_id = #{indexLibId}, - - - index_b_id = #{indexBId}, - index_b_title = #{indexBTitle}, index_audit_status = #{indexAuditStatus}, - - - index_audit_user_id = #{indexAuditUserId}, gmt_modified = #{gmtModified}, - modifier = #{modifier}, - index_audit_id = index_audit_id + modifier = #{modifier} WHERE index_audit_id = #{indexAuditId} @@ -196,9 +190,16 @@ t1.index_b_id, t1.index_b_title, t1.index_audit_status, - t1.index_audit_user_id + t1.index_audit_user_id, + t1.gmt_create, + su.user_name AS creator_name, + t2.index_lib_name FROM duty_index_audit t1 + LEFT JOIN sys_user su + ON t1.creator = su.user_id + LEFT JOIN duty_index_lib t2 + ON t1.index_lib_id = t2.index_lib_id WHERE t1.is_delete = 0 diff --git a/src/main/resources/mybatis/mapper/indexauditlog/index-audit-log-mapper.xml b/src/main/resources/mybatis/mapper/indexauditlog/index-audit-log-mapper.xml index b23c441..2113d4d 100644 --- a/src/main/resources/mybatis/mapper/indexauditlog/index-audit-log-mapper.xml +++ b/src/main/resources/mybatis/mapper/indexauditlog/index-audit-log-mapper.xml @@ -8,6 +8,7 @@ + @@ -163,9 +164,11 @@ t1.index_audit_states, t1.creator, t1.gmt_modified, - 1 + su.user_name AS creator_name FROM duty_index_audit_log t1 + LEFT JOIN sys_user su + ON t1.creator = su.user_id WHERE t1.is_delete = 0 @@ -174,13 +177,10 @@ t1.id LIKE CONCAT('%', #{keywords}, '%') ) - - AND - t1.index_audit_log_id IN - - #{indexAuditLogIds[${index}]} - + + AND t1.index_audit_id = #{indexAuditId} + ORDER BY t1.gmt_modified diff --git a/src/main/resources/static/route/indexaudit/audit.html b/src/main/resources/static/route/indexaudit/audit.html new file mode 100644 index 0000000..4749d62 --- /dev/null +++ b/src/main/resources/static/route/indexaudit/audit.html @@ -0,0 +1,137 @@ + + + + + + + + + + + + + + +
+
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+
+ +
+
+
+
+
+
+ + + + + + + \ No newline at end of file diff --git a/src/main/resources/static/route/indexaudit/list_1.html b/src/main/resources/static/route/indexaudit/list_1.html index 72f32ce..a0d9d15 100644 --- a/src/main/resources/static/route/indexaudit/list_1.html +++ b/src/main/resources/static/route/indexaudit/list_1.html @@ -31,20 +31,6 @@
- - @@ -67,14 +53,7 @@ var resizeTimeout = null; var tableUrl = 'api/indexaudit/listpage'; var indexAuditStatus = '0'; - var departmentId = top.restAjax.params(window.location.href).departmentId; - if(departmentId){ - - } - - - var indexLibIdParentId = top.restAjax.params(window.location.href).indexLibIdParentId; @@ -104,7 +83,7 @@ [ {type:'checkbox', fixed: 'left'}, {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'indexAuditId', width: 180, title: '主键', align:'center', + {field: 'indexLibName', width: 300, title: '所属指标', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -113,7 +92,7 @@ return rowData; } }, - {field: 'indexLibId', width: 180, title: '指标ID', align:'center', + {field: 'indexBTitle', width: 500, title: '上报标题', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -122,7 +101,13 @@ return rowData; } }, - {field: 'indexBId', width: 180, title: '指标业务ID', align:'center', + {field: 'indexAuditStatus', width: 180, title: '审核状态', align:'center', + templet: function(row) { + var rowData = row[this.field]; + return '待审核'; + } + }, + {field: 'creatorName', width: 100, title: '上报人', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -131,7 +116,7 @@ return rowData; } }, - {field: 'indexBTitle', width: 180, title: '上报标题', align:'center', + {field: 'gmtCreate', width: 180, title: '上报时间', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -140,24 +125,17 @@ return rowData; } }, - {field: 'indexAuditStatus', width: 180, title: '审核状态:0 待审核 1审核通过 2已归档 -1审核不通过', align:'center', + {field: 'cz', width: 140, title: '操作', align:'center',fixed: 'right', templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } - return rowData; - } - }, - {field: 'indexAuditUserId', width: 180, title: '审核人ID', align:'center', - templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } + var rowData = '
'; + rowData +=''; + rowData +=''; + rowData +=''; + rowData +='
'; return rowData; } }, + ] ], page: true, @@ -237,11 +215,10 @@ reloadTable(1); }); // 事件 - 增删改 - table.on('toolbar(dataTable)', function(obj) { + table.on('tool(dataTable)', function(obj) { var layEvent = obj.event; - var checkStatus = table.checkStatus('dataTable'); - var checkDatas = checkStatus.data; - if(layEvent === 'saveEvent') { + var data = obj.data; + if(layEvent === 'audit') { layer.open({ type: 2, title: false, @@ -249,45 +226,59 @@ area: ['100%', '100%'], shadeClose: true, anim: 2, - content: top.restAjax.path('route/indexaudit/save.html', []), + content: top.restAjax.path('route/indexaudit/audit.html?indexAuditId={indexAuditId}', [data.indexAuditId]), end: function() { reloadTable(); } }); - } else if(layEvent === 'updateEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectEdit); - } else if(checkDatas.length > 1) { - top.dialog.msg(top.dataMessage.table.selectOneEdit); - } else { - layer.open({ - type: 2, - title: false, - closeBtn: 0, - area: ['100%', '100%'], - shadeClose: true, - anim: 2, - content: top.restAjax.path('route/indexaudit/update.html?indexAuditId={indexAuditId}', [checkDatas[0].indexAuditId]), - end: function() { - reloadTable(); - } - }); - } - } else if(layEvent === 'removeEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectDelete); - } else { - var ids = ''; - for(var i = 0, item; item = checkDatas[i++];) { - if(i > 1) { - ids += '_'; - } - ids += item['indexAuditId']; + } else if(layEvent === 'log') { + layer.open({ + type: 2, + title: false, + closeBtn: 1, + area: ['80%', '80%'], + shadeClose: true, + anim: 2, + content: top.restAjax.path('route/indexauditlog/show.html?indexAuditId={indexAuditId}', [data.indexAuditId]), + end: function() { + reloadTable(); } - removeData(ids); - } + }); + }else if(layEvent === 'show'){ + var indexBId = data.indexBId + var loadLayerIndex; + top.restAjax.get(top.restAjax.path('api/indexaudit/getAuditIndexConfig/{indexAuditId}', [data.indexAuditId]), {}, null, function(code, data) { + show(data.indexTemplateShowPath+indexBId); + }, function(code, data) { + top.dialog.msg(data.msg); + }, function() { + loadLayerIndex = top.dialog.msg(top.dataMessage.loading, {icon: 16, time: 0, shade: 0.3}); + }, function() { + top.dialog.close(loadLayerIndex); + }); } }); + + + function show(path){ + if(!path){ + top.dialog.msg("未查询到模板,请联系管理员"); + } + layer.open({ + type: 2, + title: false, + closeBtn: 0, + area: ['100%', '100%'], + shadeClose: true, + anim: 2, + content: path, + end: function() { + reloadTable(); + } + }); + } + + }); diff --git a/src/main/resources/static/route/indexaudit/list_2.html b/src/main/resources/static/route/indexaudit/list_2.html index c521064..5591e4a 100644 --- a/src/main/resources/static/route/indexaudit/list_2.html +++ b/src/main/resources/static/route/indexaudit/list_2.html @@ -32,19 +32,7 @@
- + @@ -76,7 +64,6 @@ var indexLibIdParentId = top.restAjax.params(window.location.href).indexLibIdParentId; - var indexAuditStatus = top.restAjax.params(window.location.href).indexAuditStatus; @@ -105,7 +92,7 @@ [ {type:'checkbox', fixed: 'left'}, {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'indexAuditId', width: 180, title: '主键', align:'center', + {field: 'indexLibName', width: 300, title: '所属指标', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -114,7 +101,7 @@ return rowData; } }, - {field: 'indexLibId', width: 180, title: '指标ID', align:'center', + {field: 'indexBTitle', width: 500, title: '上报标题', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -123,7 +110,14 @@ return rowData; } }, - {field: 'indexBId', width: 180, title: '指标业务ID', align:'center', + + {field: 'indexAuditStatus', width: 180, title: '审核状态', align:'center', + templet: function(row) { + var rowData = row[this.field]; + return '审核通过'; + } + }, + {field: 'creatorName', width: 100, title: '上报人', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -132,7 +126,7 @@ return rowData; } }, - {field: 'indexBTitle', width: 180, title: '上报标题', align:'center', + {field: 'gmtCreate', width: 180, title: '上报时间', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -141,24 +135,16 @@ return rowData; } }, - {field: 'indexAuditStatus', width: 180, title: '审核状态:0 待审核 1审核通过 2已归档 -1审核不通过', align:'center', + {field: 'cz', width: 120, title: '操作', align:'center',fixed: 'right', templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } - return rowData; - } - }, - {field: 'indexAuditUserId', width: 180, title: '审核人ID', align:'center', - templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } + var rowData = '
'; + rowData +=''; + rowData +=''; + rowData +='
'; return rowData; } }, + ] ], page: true, @@ -238,57 +224,56 @@ reloadTable(1); }); // 事件 - 增删改 - table.on('toolbar(dataTable)', function(obj) { + table.on('tool(dataTable)', function(obj) { var layEvent = obj.event; - var checkStatus = table.checkStatus('dataTable'); - var checkDatas = checkStatus.data; - if(layEvent === 'saveEvent') { + var data = obj.data; + if(layEvent === 'show'){ + var indexBId = data.indexBId + var loadLayerIndex; + top.restAjax.get(top.restAjax.path('api/indexaudit/getAuditIndexConfig/{indexAuditId}', [data.indexAuditId]), {}, null, function(code, data) { + show(data.indexTemplateShowPath+indexBId); + }, function(code, data) { + top.dialog.msg(data.msg); + }, function() { + loadLayerIndex = top.dialog.msg(top.dataMessage.loading, {icon: 16, time: 0, shade: 0.3}); + }, function() { + top.dialog.close(loadLayerIndex); + }); + }else if(layEvent === 'log'){ layer.open({ type: 2, title: false, - closeBtn: 0, - area: ['100%', '100%'], + closeBtn: 1, + area: ['80%', '80%'], shadeClose: true, anim: 2, - content: top.restAjax.path('route/indexaudit/save.html', []), + content: top.restAjax.path('route/indexauditlog/show.html?indexAuditId={indexAuditId}', [data.indexAuditId]), end: function() { reloadTable(); } }); - } else if(layEvent === 'updateEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectEdit); - } else if(checkDatas.length > 1) { - top.dialog.msg(top.dataMessage.table.selectOneEdit); - } else { - layer.open({ - type: 2, - title: false, - closeBtn: 0, - area: ['100%', '100%'], - shadeClose: true, - anim: 2, - content: top.restAjax.path('route/indexaudit/update.html?indexAuditId={indexAuditId}', [checkDatas[0].indexAuditId]), - end: function() { - reloadTable(); - } - }); - } - } else if(layEvent === 'removeEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectDelete); - } else { - var ids = ''; - for(var i = 0, item; item = checkDatas[i++];) { - if(i > 1) { - ids += '_'; - } - ids += item['indexAuditId']; - } - removeData(ids); - } } }); + + + + function show(path){ + if(!path){ + top.dialog.msg("未查询到模板,请联系管理员"); + } + layer.open({ + type: 2, + title: false, + closeBtn: 0, + area: ['100%', '100%'], + shadeClose: true, + anim: 2, + content: path, + end: function() { + reloadTable(); + } + }); + } }); diff --git a/src/main/resources/static/route/indexaudit/list_3.html b/src/main/resources/static/route/indexaudit/list_3.html index 8df121d..43a61d7 100644 --- a/src/main/resources/static/route/indexaudit/list_3.html +++ b/src/main/resources/static/route/indexaudit/list_3.html @@ -32,19 +32,7 @@
- + @@ -76,7 +64,6 @@ var indexLibIdParentId = top.restAjax.params(window.location.href).indexLibIdParentId; - var indexAuditStatus = top.restAjax.params(window.location.href).indexAuditStatus; @@ -105,7 +92,7 @@ [ {type:'checkbox', fixed: 'left'}, {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'indexAuditId', width: 180, title: '主键', align:'center', + {field: 'indexLibName', width: 300, title: '所属指标', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -114,7 +101,7 @@ return rowData; } }, - {field: 'indexLibId', width: 180, title: '指标ID', align:'center', + {field: 'indexBTitle', width: 500, title: '上报标题', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -123,7 +110,14 @@ return rowData; } }, - {field: 'indexBId', width: 180, title: '指标业务ID', align:'center', + + {field: 'indexAuditStatus', width: 180, title: '审核状态', align:'center', + templet: function(row) { + var rowData = row[this.field]; + return '以归档'; + } + }, + {field: 'creatorName', width: 100, title: '上报人', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -132,7 +126,7 @@ return rowData; } }, - {field: 'indexBTitle', width: 180, title: '上报标题', align:'center', + {field: 'gmtCreate', width: 180, title: '上报时间', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -141,24 +135,16 @@ return rowData; } }, - {field: 'indexAuditStatus', width: 180, title: '审核状态:0 待审核 1审核通过 2已归档 -1审核不通过', align:'center', + {field: 'cz', width: 120, title: '操作', align:'center',fixed: 'right', templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } - return rowData; - } - }, - {field: 'indexAuditUserId', width: 180, title: '审核人ID', align:'center', - templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } + var rowData = '
'; + rowData +=''; + rowData +=''; + rowData +='
'; return rowData; } }, + ] ], page: true, @@ -238,57 +224,55 @@ reloadTable(1); }); // 事件 - 增删改 - table.on('toolbar(dataTable)', function(obj) { + table.on('tool(dataTable)', function(obj) { var layEvent = obj.event; - var checkStatus = table.checkStatus('dataTable'); - var checkDatas = checkStatus.data; - if(layEvent === 'saveEvent') { + var data = obj.data; + if(layEvent === 'show'){ + var indexBId = data.indexBId + var loadLayerIndex; + top.restAjax.get(top.restAjax.path('api/indexaudit/getAuditIndexConfig/{indexAuditId}', [data.indexAuditId]), {}, null, function(code, data) { + show(data.indexTemplateShowPath+indexBId); + }, function(code, data) { + top.dialog.msg(data.msg); + }, function() { + loadLayerIndex = top.dialog.msg(top.dataMessage.loading, {icon: 16, time: 0, shade: 0.3}); + }, function() { + top.dialog.close(loadLayerIndex); + }); + }else if(layEvent === 'log'){ layer.open({ type: 2, title: false, - closeBtn: 0, - area: ['100%', '100%'], + closeBtn: 1, + area: ['80%', '80%'], shadeClose: true, anim: 2, - content: top.restAjax.path('route/indexaudit/save.html', []), + content: top.restAjax.path('route/indexauditlog/show.html?indexAuditId={indexAuditId}', [data.indexAuditId]), end: function() { reloadTable(); } }); - } else if(layEvent === 'updateEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectEdit); - } else if(checkDatas.length > 1) { - top.dialog.msg(top.dataMessage.table.selectOneEdit); - } else { - layer.open({ - type: 2, - title: false, - closeBtn: 0, - area: ['100%', '100%'], - shadeClose: true, - anim: 2, - content: top.restAjax.path('route/indexaudit/update.html?indexAuditId={indexAuditId}', [checkDatas[0].indexAuditId]), - end: function() { - reloadTable(); - } - }); - } - } else if(layEvent === 'removeEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectDelete); - } else { - var ids = ''; - for(var i = 0, item; item = checkDatas[i++];) { - if(i > 1) { - ids += '_'; - } - ids += item['indexAuditId']; - } - removeData(ids); - } } }); + + function show(path){ + if(!path){ + top.dialog.msg("未查询到模板,请联系管理员"); + } + layer.open({ + type: 2, + title: false, + closeBtn: 0, + area: ['100%', '100%'], + shadeClose: true, + anim: 2, + content: path, + end: function() { + reloadTable(); + } + }); + } + }); diff --git a/src/main/resources/static/route/indexaudit/list_4.html b/src/main/resources/static/route/indexaudit/list_4.html index 3491e09..1de0e92 100644 --- a/src/main/resources/static/route/indexaudit/list_4.html +++ b/src/main/resources/static/route/indexaudit/list_4.html @@ -31,20 +31,6 @@
- - @@ -72,14 +58,7 @@ if(departmentId){ } - - - var indexLibIdParentId = top.restAjax.params(window.location.href).indexLibIdParentId; - var indexAuditStatus = top.restAjax.params(window.location.href).indexAuditStatus; - - - // 初始化表格 function initTable() { @@ -105,7 +84,7 @@ [ {type:'checkbox', fixed: 'left'}, {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'indexAuditId', width: 180, title: '主键', align:'center', + {field: 'indexLibName', width: 300, title: '所属指标', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -114,7 +93,7 @@ return rowData; } }, - {field: 'indexLibId', width: 180, title: '指标ID', align:'center', + {field: 'indexBTitle', width: 500, title: '上报标题', align:'center', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -123,7 +102,14 @@ return rowData; } }, - {field: 'indexBId', width: 180, title: '指标业务ID', align:'center', + + {field: 'indexAuditStatus', width: 180, title: '审核状态', align:'center', + templet: function(row) { + var rowData = row[this.field]; + return '审核不通过'; + } + }, + {field: 'creatorName', width: 100, title: '上报人', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -132,7 +118,7 @@ return rowData; } }, - {field: 'indexBTitle', width: 180, title: '上报标题', align:'center', + {field: 'gmtCreate', width: 180, title: '上报时间', align:'center',fixed: 'right', templet: function(row) { var rowData = row[this.field]; if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { @@ -141,24 +127,16 @@ return rowData; } }, - {field: 'indexAuditStatus', width: 180, title: '审核状态:0 待审核 1审核通过 2已归档 -1审核不通过', align:'center', + {field: 'cz', width: 120, title: '操作', align:'center',fixed: 'right', templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } - return rowData; - } - }, - {field: 'indexAuditUserId', width: 180, title: '审核人ID', align:'center', - templet: function(row) { - var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { - return '-'; - } + var rowData = '
'; + rowData +=''; + rowData +=''; + rowData +='
'; return rowData; } }, + ] ], page: true, @@ -238,57 +216,55 @@ reloadTable(1); }); // 事件 - 增删改 - table.on('toolbar(dataTable)', function(obj) { + table.on('tool(dataTable)', function(obj) { var layEvent = obj.event; - var checkStatus = table.checkStatus('dataTable'); - var checkDatas = checkStatus.data; - if(layEvent === 'saveEvent') { + var data = obj.data; + if(layEvent === 'show'){ + var indexBId = data.indexBId + var loadLayerIndex; + top.restAjax.get(top.restAjax.path('api/indexaudit/getAuditIndexConfig/{indexAuditId}', [data.indexAuditId]), {}, null, function(code, data) { + show(data.indexTemplateShowPath+indexBId); + }, function(code, data) { + top.dialog.msg(data.msg); + }, function() { + loadLayerIndex = top.dialog.msg(top.dataMessage.loading, {icon: 16, time: 0, shade: 0.3}); + }, function() { + top.dialog.close(loadLayerIndex); + }); + }else if(layEvent === 'log'){ layer.open({ type: 2, title: false, - closeBtn: 0, - area: ['100%', '100%'], + closeBtn: 1, + area: ['80%', '80%'], shadeClose: true, anim: 2, - content: top.restAjax.path('route/indexaudit/save.html', []), + content: top.restAjax.path('route/indexauditlog/show.html?indexAuditId={indexAuditId}', [data.indexAuditId]), end: function() { reloadTable(); } }); - } else if(layEvent === 'updateEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectEdit); - } else if(checkDatas.length > 1) { - top.dialog.msg(top.dataMessage.table.selectOneEdit); - } else { - layer.open({ - type: 2, - title: false, - closeBtn: 0, - area: ['100%', '100%'], - shadeClose: true, - anim: 2, - content: top.restAjax.path('route/indexaudit/update.html?indexAuditId={indexAuditId}', [checkDatas[0].indexAuditId]), - end: function() { - reloadTable(); - } - }); - } - } else if(layEvent === 'removeEvent') { - if(checkDatas.length === 0) { - top.dialog.msg(top.dataMessage.table.selectDelete); - } else { - var ids = ''; - for(var i = 0, item; item = checkDatas[i++];) { - if(i > 1) { - ids += '_'; - } - ids += item['indexAuditId']; - } - removeData(ids); - } } }); + + function show(path){ + if(!path){ + top.dialog.msg("未查询到模板,请联系管理员"); + } + layer.open({ + type: 2, + title: false, + closeBtn: 0, + area: ['100%', '100%'], + shadeClose: true, + anim: 2, + content: path, + end: function() { + reloadTable(); + } + }); + } + }); diff --git a/src/main/resources/static/route/indexauditlog/show.html b/src/main/resources/static/route/indexauditlog/show.html new file mode 100644 index 0000000..80a58f1 --- /dev/null +++ b/src/main/resources/static/route/indexauditlog/show.html @@ -0,0 +1,127 @@ + + + + + + + + + + + + + + +
+
+
+ + 上级列表 + +
+
+
+
    +
    + +
+
+
+
+
+ + + + + + + \ No newline at end of file