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 @@ /> + + + - + + + + >>>"+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..e45f554d 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}