From 627d6282bdfc8b38687731412dd0a335a0968e87 Mon Sep 17 00:00:00 2001 From: songwenxuan <1924103812@qq.com> Date: Tue, 11 Jun 2024 18:04:01 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E4=B8=BA3=E7=BA=A7=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=20=E4=B8=80=E7=BA=A7=E5=88=97=E8=A1=A8=E6=94=B9=E6=88=90?= =?UTF-8?q?=E4=BD=9C=E4=B8=9A=E5=8D=95=E4=BD=8D=20=E4=BA=8C=E7=BA=A7?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E6=94=B9=E6=88=90=E4=BD=9C=E4=B8=9A=E5=8D=95?= =?UTF-8?q?=E4=BD=8D=EF=BC=8C=E4=BD=9C=E4=B8=9A=E7=B1=BB=E5=88=AB=EF=BC=8C?= =?UTF-8?q?=E4=BD=9C=E4=B8=9A=E4=BA=BA=E6=95=B0=20=E4=B8=89=E7=BA=A7?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E5=B1=95=E7=A4=BA=20=E5=8D=95=E4=BD=8D=20?= =?UTF-8?q?=E7=B1=BB=E5=88=AB=20=E6=93=8D=E4=BD=9C=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=EF=BC=8C=E5=A7=93=E5=90=8D=EF=BC=8C=E7=89=B9=E7=A7=8D=E4=BD=9C?= =?UTF-8?q?=E4=B8=9A=E7=BC=96=E5=8F=B7=EF=BC=8C=E8=AF=81=E4=B9=A6=E6=9C=89?= =?UTF-8?q?=E6=95=88=E6=9C=9F=EF=BC=8C=E5=A4=8D=E5=AE=A1=E6=97=B6=E9=97=B4?= =?UTF-8?q?=EF=BC=8C=E7=8A=B6=E6=80=81=EF=BC=88=E6=98=AF=E5=90=A6=E6=9C=89?= =?UTF-8?q?=E6=95=88=EF=BC=89=20=E6=96=B0=E5=A2=9E=E6=88=96=E4=BF=AE?= =?UTF-8?q?=E6=94=B9=E4=BA=BA=E5=91=98=E5=A2=9E=E5=8A=A0=E6=98=AF=E5=90=A6?= =?UTF-8?q?=E5=A4=8D=E5=AE=A1=E7=9A=84=E7=A1=AE=E8=AE=A4=E6=A1=86=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/bus/CorpPromiseController.java | 62 ++++++ .../bus/CorpResponsibilityController.java | 62 ++++++ .../controller/bus/SpecialUserController.java | 76 ++++++++ .../datasource/bus/CorpPromiseMapper.java | 7 + .../bus/CorpResponsibilityMapper.java | 4 + .../datasource/bus/SpecialUserMapper.java | 6 + .../service/bus/CorpPromiseService.java | 4 + .../bus/CorpResponsibilityService.java | 4 + .../service/bus/SpecialUserService.java | 6 + .../bus/impl/CorpPromiseServiceImpl.java | 8 + .../impl/CorpResponsibilityServiceImpl.java | 35 ++-- .../bus/impl/SpecialUserServiceImpl.java | 24 +++ .../zcloud/util/SpecialReviewScheduled.java | 36 ++++ .../datasource/bus/CorpPromiseMapper.xml | 182 ++++++++++++++++++ .../bus/CorpResponsibilityMapper.xml | 181 +++++++++++++++++ .../datasource/bus/SpecialUserMapper.xml | 83 ++++++++ 16 files changed, 767 insertions(+), 13 deletions(-) create mode 100644 src/main/java/com/zcloud/util/SpecialReviewScheduled.java diff --git a/src/main/java/com/zcloud/controller/bus/CorpPromiseController.java b/src/main/java/com/zcloud/controller/bus/CorpPromiseController.java index 0d675cdf..89e5142a 100644 --- a/src/main/java/com/zcloud/controller/bus/CorpPromiseController.java +++ b/src/main/java/com/zcloud/controller/bus/CorpPromiseController.java @@ -6,10 +6,12 @@ import com.zcloud.aspect.DockAnnotation; import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; +import com.zcloud.entity.system.Role; import com.zcloud.service.bus.CorpPromiseDetailsService; import com.zcloud.service.bus.CorpPromisePeopleService; import com.zcloud.service.bus.CorpPromiseService; import com.zcloud.service.bus.ImgFilesService; +import com.zcloud.service.system.RoleService; import com.zcloud.util.*; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; @@ -38,6 +40,8 @@ public class CorpPromiseController extends BaseController { private CorpPromisePeopleService corpPromisePeopleService; @Autowired private ImgFilesService imgFilesService; + @Autowired + private RoleService roleService; /** * 新增 @@ -178,6 +182,64 @@ public class CorpPromiseController extends BaseController { return map; } + @RequestMapping("/userPromiseList") + @ResponseBody + public Object userPromiseList(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + if (pd.get("YEAR").equals("")){ + String year = DateUtil.getYear(); + pd.put("YEAR",year); + } + /*检索条件*/ + String ROLE_ID = pd.getString("ROLE_ID"); //角色ID + String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件 + if (Tools.notEmpty(KEYWORDS)) pd.put("KEYWORDS", KEYWORDS.trim()); + String DEPARTMENT_ID = pd.getString("DEPARTMENT_ID"); //关键词检索条件 + String USER_ID = pd.getString("USER_ID"); + if (Tools.notEmpty(DEPARTMENT_ID)) pd.put("DEPARTMENT_ID", DEPARTMENT_ID.trim()); + String STRARTTIME = pd.getString("STRARTTIME"); //开始时间 + String ENDTIME = pd.getString("ENDTIME"); //结束时间 + if (Tools.notEmpty(STRARTTIME)) pd.put("STRARTTIME", STRARTTIME + " 00:00:00"); + if (Tools.notEmpty(ENDTIME)) pd.put("ENDTIME", ENDTIME + " 00:00:00"); + pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); + page.setPd(pd); + List userList = corpPromiseService.userpromiselistPage(page); //列出用户列表 + pd.put("ROLE_ID", "1"); + List roleList = roleService.listAllRolesByPId(pd); //列出所有系统用户角色 + + map.put("userList", userList); + map.put("roleList", roleList); + map.put("ROLE_ID", ROLE_ID); + map.put("page", page); + map.put("pd", pd); + + map.put("result", errInfo); + return map; + } + + @RequestMapping("/userpromisedetaillistPage") + @ResponseBody + public Object userpromisedetaillistPage(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + if (pd.get("YEAR").equals("")){ + String year = DateUtil.getYear(); + pd.put("YEAR",year); + } + pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); + page.setPd(pd); + List varList = corpPromiseService.userpromisedetaillistPage(page); //列出用户列表 + map.put("varList", varList); + map.put("page", page); + map.put("result", errInfo); + return map; + } + /** * 启用禁用 * diff --git a/src/main/java/com/zcloud/controller/bus/CorpResponsibilityController.java b/src/main/java/com/zcloud/controller/bus/CorpResponsibilityController.java index 2fcb2234..7ba14396 100644 --- a/src/main/java/com/zcloud/controller/bus/CorpResponsibilityController.java +++ b/src/main/java/com/zcloud/controller/bus/CorpResponsibilityController.java @@ -5,7 +5,9 @@ import com.alibaba.fastjson.JSONObject; import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; +import com.zcloud.entity.system.Role; import com.zcloud.service.bus.*; +import com.zcloud.service.system.RoleService; import com.zcloud.util.*; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -34,6 +36,8 @@ public class CorpResponsibilityController extends BaseController { private CorpResponsibilityFinalsService corpResponsibilityFinalsService; @Autowired private ImgFilesService imgFilesService; + @Autowired + private RoleService roleService; /** * 新增 @@ -572,4 +576,62 @@ public class CorpResponsibilityController extends BaseController { mv = new ModelAndView(erv,dataMap); return mv; } + + @RequestMapping("/userResponsibilityList") + @ResponseBody + public Object userResponsibilityList(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + if (pd.get("YEAR").equals("")){ + String year = DateUtil.getYear(); + pd.put("YEAR",year); + } + /*检索条件*/ + String ROLE_ID = pd.getString("ROLE_ID"); //角色ID + String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件 + if (Tools.notEmpty(KEYWORDS)) pd.put("KEYWORDS", KEYWORDS.trim()); + String DEPARTMENT_ID = pd.getString("DEPARTMENT_ID"); //关键词检索条件 + String USER_ID = pd.getString("USER_ID"); + if (Tools.notEmpty(DEPARTMENT_ID)) pd.put("DEPARTMENT_ID", DEPARTMENT_ID.trim()); + String STRARTTIME = pd.getString("STRARTTIME"); //开始时间 + String ENDTIME = pd.getString("ENDTIME"); //结束时间 + if (Tools.notEmpty(STRARTTIME)) pd.put("STRARTTIME", STRARTTIME + " 00:00:00"); + if (Tools.notEmpty(ENDTIME)) pd.put("ENDTIME", ENDTIME + " 00:00:00"); + pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); + page.setPd(pd); + List userList = corpResponsibilityService.userResponsibilitylistPage(page); //列出用户列表 + pd.put("ROLE_ID", "1"); + List roleList = roleService.listAllRolesByPId(pd); //列出所有系统用户角色 + + map.put("userList", userList); + map.put("roleList", roleList); + map.put("ROLE_ID", ROLE_ID); + map.put("page", page); + map.put("pd", pd); + + map.put("result", errInfo); + return map; + } + + @RequestMapping("/userresponsibilitydetaillistPage") + @ResponseBody + public Object userresponsibilitydetaillistPage(Page page) throws Exception { + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + if (pd.get("YEAR").equals("")){ + String year = DateUtil.getYear(); + pd.put("YEAR",year); + } + pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); + page.setPd(pd); + List varList = corpResponsibilityService.userResponsibilitydetaillistPage(page); //列出用户列表 + map.put("varList", varList); + map.put("page", page); + map.put("result", errInfo); + return map; + } } diff --git a/src/main/java/com/zcloud/controller/bus/SpecialUserController.java b/src/main/java/com/zcloud/controller/bus/SpecialUserController.java index a9ec9962..2b96d966 100644 --- a/src/main/java/com/zcloud/controller/bus/SpecialUserController.java +++ b/src/main/java/com/zcloud/controller/bus/SpecialUserController.java @@ -1,5 +1,6 @@ package com.zcloud.controller.bus; +import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Date; import java.util.HashMap; @@ -53,6 +54,11 @@ public class SpecialUserController extends BaseController { String errInfo = "success"; PageData pd = new PageData(); pd = this.getPageData(); + if (pd.getString("ISREVIEW").equals("true")) { + pd.put("ISREVIEW","1"); + }else { + pd.put("ISREVIEW","0"); + } PageData dockData = new PageData(); // 主要对接数据 PageData blindPageData = new PageData(); // pd对接数据 @@ -138,6 +144,11 @@ public class SpecialUserController extends BaseController { PageData pd = new PageData(); pd = this.getPageData(); PageData dockData = new PageData(); + if (pd.getString("ISREVIEW").equals("true")) { + pd.put("ISREVIEW","1"); + }else { + pd.put("ISREVIEW","0"); + } // 修改与删除功能仅企业主账号可操作,并仅可修改与删除本单位添加的特种人员信息 String corpID = Jurisdiction.getCORPINFO_ID(); // 登录企业信息 @@ -189,6 +200,71 @@ public class SpecialUserController extends BaseController { pd.put("keyTypeIn1And2","1"); page.setPd(pd); List varList = specialuserService.list(page); //列出SpecialUser列表 + + //判断证件是否有效(先判断有效期是否符合,再判断是否复审过) + for (PageData pageData : varList) { + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); + String validity_time_start = pageData.getString("VALIDITY_TIME_START"); + Date startTime = sdf.parse(validity_time_start); + String validity_time_end = pageData.getString("VALIDITY_TIME_END"); + Date endTime = sdf.parse(validity_time_end); + Date currentTime = new Date(); + if (startTime.compareTo(currentTime) >= 1 && currentTime.compareTo(endTime) >= 1) { + if (pageData.get("ISREVIEW").equals("1")){ + pageData.put("ISEFFECTIVE","是"); + } else { + pageData.put("ISEFFECTIVE","否"); + } + } else { + pageData.put("ISEFFECTIVE","否"); + } + } + map.put("varList", varList); + map.put("page", page); + map.put("result", errInfo); + return map; + } + + /**列表 + * @param page + * @throws Exception + */ + @RequestMapping(value="/listByDept") + @RequiresPermissions("specialuser:list") + @ResponseBody + public Object listByDept(Page page) throws Exception{ + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件 + if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim()); + pd.put("keyTypeIn1And2","1"); + page.setPd(pd); + List varList = specialuserService.listByDept(page); //列出SpecialUser列表 + map.put("varList", varList); + map.put("page", page); + map.put("result", errInfo); + return map; + } + + /**列表 + * @param page + * @throws Exception + */ + @RequestMapping(value="/listByOperation") + @RequiresPermissions("specialuser:list") + @ResponseBody + public Object listByOperation(Page page) throws Exception{ + Map map = new HashMap(); + String errInfo = "success"; + PageData pd = new PageData(); + pd = this.getPageData(); + String KEYWORDS = pd.getString("KEYWORDS"); //关键词检索条件 + if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim()); + pd.put("keyTypeIn1And2","1"); + page.setPd(pd); + List varList = specialuserService.listByOperation(page); //列出SpecialUser列表 map.put("varList", varList); map.put("page", page); map.put("result", errInfo); diff --git a/src/main/java/com/zcloud/mapper/datasource/bus/CorpPromiseMapper.java b/src/main/java/com/zcloud/mapper/datasource/bus/CorpPromiseMapper.java index 131efc61..7c75a4b4 100644 --- a/src/main/java/com/zcloud/mapper/datasource/bus/CorpPromiseMapper.java +++ b/src/main/java/com/zcloud/mapper/datasource/bus/CorpPromiseMapper.java @@ -44,5 +44,12 @@ public interface CorpPromiseMapper { void decPeoplenumInvolved(PageData pd); + /**用户列表 + * @param page + * @return + */ + List userpromiselistPage(Page page); + + List userpromisedetaillistPage(Page page); } diff --git a/src/main/java/com/zcloud/mapper/datasource/bus/CorpResponsibilityMapper.java b/src/main/java/com/zcloud/mapper/datasource/bus/CorpResponsibilityMapper.java index 178e4c5e..35872131 100644 --- a/src/main/java/com/zcloud/mapper/datasource/bus/CorpResponsibilityMapper.java +++ b/src/main/java/com/zcloud/mapper/datasource/bus/CorpResponsibilityMapper.java @@ -45,5 +45,9 @@ public interface CorpResponsibilityMapper { List getAllSignatureStatuslistPage(Page page); List getAllSignatureStatus(PageData pd); + + List userResponsibilitylistPage(Page page); + + List userResponsibilitydetaillistPage(Page page); } diff --git a/src/main/java/com/zcloud/mapper/datasource/bus/SpecialUserMapper.java b/src/main/java/com/zcloud/mapper/datasource/bus/SpecialUserMapper.java index 39a683be..82aaed73 100644 --- a/src/main/java/com/zcloud/mapper/datasource/bus/SpecialUserMapper.java +++ b/src/main/java/com/zcloud/mapper/datasource/bus/SpecialUserMapper.java @@ -30,12 +30,18 @@ public interface SpecialUserMapper{ */ void edit(PageData pd); + void editIsReview(PageData pd); + /**列表 * @param page * @throws Exception */ List datalistPage(Page page); + List listByDeptlistPage(Page page); + + List listByOperationlistPage(Page page); + /**列表(全部) * @param pd * @throws Exception diff --git a/src/main/java/com/zcloud/service/bus/CorpPromiseService.java b/src/main/java/com/zcloud/service/bus/CorpPromiseService.java index 1e1a608f..fc5c61a4 100644 --- a/src/main/java/com/zcloud/service/bus/CorpPromiseService.java +++ b/src/main/java/com/zcloud/service/bus/CorpPromiseService.java @@ -58,4 +58,8 @@ public interface CorpPromiseService { * @throws Exception */ void delete(PageData pd)throws Exception; + + public List userpromiselistPage(Page page)throws Exception; + + public List userpromisedetaillistPage(Page page)throws Exception; } diff --git a/src/main/java/com/zcloud/service/bus/CorpResponsibilityService.java b/src/main/java/com/zcloud/service/bus/CorpResponsibilityService.java index ded66587..b17aa22a 100644 --- a/src/main/java/com/zcloud/service/bus/CorpResponsibilityService.java +++ b/src/main/java/com/zcloud/service/bus/CorpResponsibilityService.java @@ -60,4 +60,8 @@ public interface CorpResponsibilityService { List listAllSignatureStatus(Page page)throws Exception; List listAllSignatureStatus(PageData pd)throws Exception; + + public List userResponsibilitylistPage(Page page)throws Exception; + + public List userResponsibilitydetaillistPage(Page page)throws Exception; } diff --git a/src/main/java/com/zcloud/service/bus/SpecialUserService.java b/src/main/java/com/zcloud/service/bus/SpecialUserService.java index 25821548..3ce84eb4 100644 --- a/src/main/java/com/zcloud/service/bus/SpecialUserService.java +++ b/src/main/java/com/zcloud/service/bus/SpecialUserService.java @@ -30,12 +30,18 @@ public interface SpecialUserService{ */ public void edit(PageData pd)throws Exception; + public void editIsReview(PageData pd)throws Exception; + /**列表 * @param page * @throws Exception */ public List list(Page page)throws Exception; + public List listByDept(Page page)throws Exception; + + public List listByOperation(Page page)throws Exception; + /**列表(全部) * @param pd * @throws Exception diff --git a/src/main/java/com/zcloud/service/bus/impl/CorpPromiseServiceImpl.java b/src/main/java/com/zcloud/service/bus/impl/CorpPromiseServiceImpl.java index 7ea15b23..8460ab58 100644 --- a/src/main/java/com/zcloud/service/bus/impl/CorpPromiseServiceImpl.java +++ b/src/main/java/com/zcloud/service/bus/impl/CorpPromiseServiceImpl.java @@ -76,4 +76,12 @@ public class CorpPromiseServiceImpl implements CorpPromiseService { public void delete(PageData pd) throws Exception { corpPromiseMapper.delete(pd); } + + public List userpromiselistPage(Page page) throws Exception { + return corpPromiseMapper.userpromiselistPage(page); + } + + public List userpromisedetaillistPage(Page page) throws Exception { + return corpPromiseMapper.userpromisedetaillistPage(page); + } } diff --git a/src/main/java/com/zcloud/service/bus/impl/CorpResponsibilityServiceImpl.java b/src/main/java/com/zcloud/service/bus/impl/CorpResponsibilityServiceImpl.java index 2718cd4d..80b43a73 100644 --- a/src/main/java/com/zcloud/service/bus/impl/CorpResponsibilityServiceImpl.java +++ b/src/main/java/com/zcloud/service/bus/impl/CorpResponsibilityServiceImpl.java @@ -22,65 +22,74 @@ import java.util.List; public class CorpResponsibilityServiceImpl implements CorpResponsibilityService { @Autowired - private CorpResponsibilityMapper corpPromiseMapper; + private CorpResponsibilityMapper corpResponsibilityMapper; @Override public void save(PageData pd) throws Exception { - corpPromiseMapper.save(pd); + corpResponsibilityMapper.save(pd); } @Override public List list(Page page) throws Exception { - return corpPromiseMapper.datalistPage(page); + return corpResponsibilityMapper.datalistPage(page); } @Override public void editdelete(PageData pd) throws Exception { - corpPromiseMapper.editdelete(pd); + corpResponsibilityMapper.editdelete(pd); } @Override public PageData findById(PageData pd) throws Exception { - return corpPromiseMapper.findById(pd); + return corpResponsibilityMapper.findById(pd); } @Override public void edit(PageData pd) throws Exception { - corpPromiseMapper.edit(pd); + corpResponsibilityMapper.edit(pd); } @Override public List listAll(Page page) throws Exception { - return corpPromiseMapper.dataAlllistPage(page); + return corpResponsibilityMapper.dataAlllistPage(page); } @Override public List collateralall(PageData pd) throws Exception { - return corpPromiseMapper.collateralall(pd); + return corpResponsibilityMapper.collateralall(pd); } @Override public List collateralAllFinal(PageData pd) throws Exception { - return corpPromiseMapper.collateralAllFinal(pd); + return corpResponsibilityMapper.collateralAllFinal(pd); } @Override public void editpeople(PageData pd) throws Exception { - corpPromiseMapper.editpeople(pd); + corpResponsibilityMapper.editpeople(pd); } public void delete(PageData pd) throws Exception { - corpPromiseMapper.delete(pd); + corpResponsibilityMapper.delete(pd); } @Override public List listAllSignatureStatus(Page page) throws Exception { - return corpPromiseMapper.getAllSignatureStatuslistPage(page); + return corpResponsibilityMapper.getAllSignatureStatuslistPage(page); } @Override public List listAllSignatureStatus(PageData pd) throws Exception { - return corpPromiseMapper.getAllSignatureStatus(pd); + return corpResponsibilityMapper.getAllSignatureStatus(pd); } + public List userResponsibilitylistPage(Page page) throws Exception { + return corpResponsibilityMapper.userResponsibilitylistPage(page); + } + + public List userResponsibilitydetaillistPage(Page page) throws Exception { + return corpResponsibilityMapper.userResponsibilitydetaillistPage(page); + } + + } diff --git a/src/main/java/com/zcloud/service/bus/impl/SpecialUserServiceImpl.java b/src/main/java/com/zcloud/service/bus/impl/SpecialUserServiceImpl.java index 4de404bd..4cefabfb 100644 --- a/src/main/java/com/zcloud/service/bus/impl/SpecialUserServiceImpl.java +++ b/src/main/java/com/zcloud/service/bus/impl/SpecialUserServiceImpl.java @@ -46,6 +46,14 @@ public class SpecialUserServiceImpl implements SpecialUserService{ specialuserMapper.edit(pd); } + /**修改 + * @param pd + * @throws Exception + */ + public void editIsReview(PageData pd)throws Exception{ + specialuserMapper.editIsReview(pd); + } + /**列表 * @param page * @throws Exception @@ -54,6 +62,22 @@ public class SpecialUserServiceImpl implements SpecialUserService{ return specialuserMapper.datalistPage(page); } + /**列表 + * @param page + * @throws Exception + */ + public List listByDept(Page page)throws Exception{ + return specialuserMapper.listByDeptlistPage(page); + } + + /**列表 + * @param page + * @throws Exception + */ + public List listByOperation(Page page)throws Exception{ + return specialuserMapper.listByOperationlistPage(page); + } + /**列表(全部) * @param pd * @throws Exception diff --git a/src/main/java/com/zcloud/util/SpecialReviewScheduled.java b/src/main/java/com/zcloud/util/SpecialReviewScheduled.java new file mode 100644 index 00000000..dfa56459 --- /dev/null +++ b/src/main/java/com/zcloud/util/SpecialReviewScheduled.java @@ -0,0 +1,36 @@ +package com.zcloud.util; + +import com.zcloud.entity.PageData; +import com.zcloud.service.bus.SpecialUserService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.scheduling.annotation.Scheduled; +import org.springframework.stereotype.Component; + +import java.text.SimpleDateFormat; +import java.util.Date; + +@Component +public class SpecialReviewScheduled { + @Autowired + private SpecialUserService specialuserService; + + @Scheduled(cron ="0 35 0 * * ?")//每天12点35 +// @Scheduled(cron ="* * * * * ?")//每15秒 + public void scheduled() throws Exception { + System.out.println("============判断证书复审时间是否有效========"); + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); + PageData pd = new PageData(); + Date currentTime = new Date(); + String format = sdf.format(currentTime); + pd.put("currentTime",format); + specialuserService.editIsReview(pd); + System.out.println("============证书判断结束========"); + } + + /**得到32位的uuid + * @return + */ + public String get32UUID(){ + return UuidUtil.get32UUID(); + } +} diff --git a/src/main/resources/mybatis/datasource/bus/CorpPromiseMapper.xml b/src/main/resources/mybatis/datasource/bus/CorpPromiseMapper.xml index d870ef74..f4802cd6 100644 --- a/src/main/resources/mybatis/datasource/bus/CorpPromiseMapper.xml +++ b/src/main/resources/mybatis/datasource/bus/CorpPromiseMapper.xml @@ -296,4 +296,186 @@ where PROMISE_ID = #{PROMISE_ID} + + + + + + diff --git a/src/main/resources/mybatis/datasource/bus/CorpResponsibilityMapper.xml b/src/main/resources/mybatis/datasource/bus/CorpResponsibilityMapper.xml index ca3bd814..1846a410 100644 --- a/src/main/resources/mybatis/datasource/bus/CorpResponsibilityMapper.xml +++ b/src/main/resources/mybatis/datasource/bus/CorpResponsibilityMapper.xml @@ -310,4 +310,185 @@ ORDER BY NEED_SINGED DESC,SIGNED_COUNT DESC, ALL_SIGN_COUNT DESC + + + + + diff --git a/src/main/resources/mybatis/datasource/bus/SpecialUserMapper.xml b/src/main/resources/mybatis/datasource/bus/SpecialUserMapper.xml index b7dadf55..365b6eb1 100644 --- a/src/main/resources/mybatis/datasource/bus/SpecialUserMapper.xml +++ b/src/main/resources/mybatis/datasource/bus/SpecialUserMapper.xml @@ -21,6 +21,7 @@ f.SPECIAL_TYPE, f.OPERATION_TYPE, f.ISSUING_AUTHORITY, + f.ISREVIEW, f.REVIEW_TIME, f.VALIDITY_TIME_END, f.VALIDITY_TIME_START, @@ -49,6 +50,7 @@ SPECIAL_TYPE, OPERATION_TYPE, ISSUING_AUTHORITY, + ISREVIEW, REVIEW_TIME, USER_ID, USER_TYPE, @@ -78,6 +80,7 @@ #{SPECIAL_TYPE}, #{OPERATION_TYPE}, #{ISSUING_AUTHORITY}, + #{ISREVIEW}, #{REVIEW_TIME}, #{USER_ID}, #{USER_TYPE}, @@ -133,6 +136,7 @@ ISSUING_AUTHORITY = #{ISSUING_AUTHORITY}, VALIDITY_TIME_END = #{VALIDITY_TIME_END}, VALIDITY_TIME_START = #{VALIDITY_TIME_START}, + ISREVIEW = #{ISREVIEW}, REVIEW_TIME = #{REVIEW_TIME}, SPECIAL_NUMBER = #{SPECIAL_NUMBER}, USER_ID = #{USER_ID}, @@ -151,6 +155,16 @@ SPECIALUSER_ID = #{SPECIALUSER_ID} + + + update + + set + ISREVIEW = "0" + where + #{currentTime} > REVIEW_TIME + + + + + + + +