diff --git a/ruoyi-admin/src/main/java/com/ruoyi/api/labour/controller/LabourApiController.java b/ruoyi-admin/src/main/java/com/ruoyi/api/labour/controller/LabourApiController.java index b3d76347..1a18b409 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/api/labour/controller/LabourApiController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/api/labour/controller/LabourApiController.java @@ -837,7 +837,29 @@ public class LabourApiController extends BaseController { } public static void main(String[] args) { - pushLabourGroup(); + String baseUrl = "https://szgc.jhncidg.com/jhapi"; + String timestamp = String.valueOf(System.currentTimeMillis()); + String appId = "jhcf17054840354615gUkkFJvTn003"; + try { + // 明文信息->公钥加密 + String encryptByPublicKeyStr = AuthRsaUtils.encryptByPublicKey(publicKey, appId+timestamp); + log.info("公钥加密...{}" , encryptByPublicKeyStr); + // redis中查询->未查询到则重新获取 + String url = baseUrl + "/api/labour/v1/getToken"; + Map body = new HashMap<>(); + body.put("appId",appId); + body.put("sign",encryptByPublicKeyStr); + body.put("timestamp",timestamp); + String result = HttpClientUtil.doPost(url, null, com.alibaba.fastjson2.JSON.toJSONString(body)); + JSONObject jsonObject = JSONObject.parseObject(result); + if(jsonObject.getInteger("code")==200){ + // 获取到存入redis,设置30分钟有效期 + String token = jsonObject.getString("Authorization"); + log.info("Authorization...{}" , token); + } + }catch (Exception e){ + e.printStackTrace(); + } } } diff --git a/ruoyi-ui/src/views/trouble/pshProblemmodify/index.vue b/ruoyi-ui/src/views/trouble/pshProblemmodify/index.vue index c3709046..0978a736 100644 --- a/ruoyi-ui/src/views/trouble/pshProblemmodify/index.vue +++ b/ruoyi-ui/src/views/trouble/pshProblemmodify/index.vue @@ -44,6 +44,14 @@ /> + + + - + + + + { - this.form = response.data; + that.form = response.data; let depts = []; - this.form.workTrainDeptList.forEach((item) => { + that.form.workTrainDeptList.forEach((item) => { depts.push(item.deptId); }); - this.form.workTrainDeptList = depts; + that.form.workTrainDeptList = depts; if (that.form.trainFile) { that.files = that.form.trainFile.split(","); } diff --git a/ruoyi-wechat/src/main/java/com/ruoyi/web/common/CaptchaController.java b/ruoyi-wechat/src/main/java/com/ruoyi/web/common/CaptchaController.java index 87d33ac7..d77aa2c0 100644 --- a/ruoyi-wechat/src/main/java/com/ruoyi/web/common/CaptchaController.java +++ b/ruoyi-wechat/src/main/java/com/ruoyi/web/common/CaptchaController.java @@ -77,7 +77,6 @@ public class CaptchaController capStr = code = captchaProducer.createText(); image = captchaProducer.createImage(capStr); } - System.out.println("CODE======================>>>>"+code); redisCache.setCacheObject(verifyKey, code, Constants.CAPTCHA_EXPIRATION, TimeUnit.MINUTES); // 转换流信息写出 FastByteArrayOutputStream os = new FastByteArrayOutputStream(); diff --git a/yanzhu-jh/src/main/resources/mapper/trouble/SmzSspProblemmodifyMapper.xml b/yanzhu-jh/src/main/resources/mapper/trouble/SmzSspProblemmodifyMapper.xml index 8c05417d..cb0062b6 100644 --- a/yanzhu-jh/src/main/resources/mapper/trouble/SmzSspProblemmodifyMapper.xml +++ b/yanzhu-jh/src/main/resources/mapper/trouble/SmzSspProblemmodifyMapper.xml @@ -69,7 +69,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and ssp.problemArea like concat('%', #{problemArea}, '%') and ssp.workParts like concat('%', #{workParts}, '%') and ssp.changeInfo like concat('%', #{changeInfo}, '%') - and ssp.lordSent = #{lordSent} + and (ssp.lordSent like concat('%', #{lordSent}, '%') or ssp.lordSentUser like concat('%', #{lordSent}, '%')) and ssp.lordSentUser = #{lordSentUser} and ssp.copySend = #{copySend} and ssp.copySendUser = #{copySendUser} @@ -215,6 +215,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and ssp.workParts like concat('%', #{workParts}, '%') and ssp.createUser like concat('%', #{createUser}, '%') and ssp.danger_type = #{dangerType} + and (ssp.lordSent like concat('%', #{lordSent}, '%') or ssp.lordSentUser like concat('%', #{lordSent}, '%')) and date(ssp.createTime) between #{params.beginMarksTime} and #{params.endMarksTime} and sp.deptId = #{projectDeptId} @@ -241,6 +242,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and ssp.projectId = #{projectId} and (date(NOW()) ]]> date(ssp.nickedTime) and (ssp.updateTime is null or date(ssp.updateTime) ]]> date(ssp.nickedTime))) and infoType=#{infoType} + and (ssp.lordSent like concat('%', #{lordSent}, '%') or ssp.lordSentUser like concat('%', #{lordSent}, '%')) and ssp.problemArea like concat('%', #{problemArea}, '%') and ssp.workParts like concat('%', #{workParts}, '%') and ssp.createUser like concat('%', #{createUser}, '%') diff --git a/yanzhu-jh/src/main/resources/mapper/work/WorkTrainMapper.xml b/yanzhu-jh/src/main/resources/mapper/work/WorkTrainMapper.xml index d93b5939..fe5b82dd 100644 --- a/yanzhu-jh/src/main/resources/mapper/work/WorkTrainMapper.xml +++ b/yanzhu-jh/src/main/resources/mapper/work/WorkTrainMapper.xml @@ -45,7 +45,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"