From bce673a558dc1d2ea5283d5a83f847c1bdb9abef Mon Sep 17 00:00:00 2001 From: kylin L <452061493@qq.com> Date: Tue, 30 Jul 2024 18:17:17 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A1=8C=E6=94=BF=E6=89=A7=E6=B3=95=E7=99=BB?= =?UTF-8?q?=E8=AE=B0=E5=8A=9F=E8=83=BD=E4=B8=AD=EF=BC=8C=E6=A3=80=E6=9F=A5?= =?UTF-8?q?=E4=BE=9D=E6=8D=AE=E4=BB=85=E9=80=89=E6=8B=A9=E6=B3=95=E5=BE=8B?= =?UTF-8?q?=E5=90=8D=E7=A7=B0=EF=BC=8C=E4=B8=8D=E5=B1=95=E7=A4=BA=E5=85=B7?= =?UTF-8?q?=E4=BD=93=E7=BB=86=E8=8A=82=E6=9D=A1=E6=AC=BE=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E4=B9=8B=E7=B1=BB=E7=9A=84=EF=BC=8C=E5=90=8C=E6=97=B6=E8=A1=A5?= =?UTF-8?q?=E5=85=85=E4=B8=80=E4=B8=AA=E5=8F=AF=E8=BE=93=E5=85=A5=E6=A1=86?= =?UTF-8?q?=E5=AF=B9=E6=89=A7=E6=B3=95=E4=BE=9D=E6=8D=AE=E7=9A=84=E8=A1=A5?= =?UTF-8?q?=E5=85=85=EF=BC=88=E5=8F=AF=E8=A1=A5=E5=85=85=E5=A4=9A=E4=B8=AA?= =?UTF-8?q?=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AppEnforcementRegistrationController.java | 9 ++++++--- .../app/controller/AppThirdLoginController.java | 6 +++--- .../src/main/resources/application-dev.yml | 10 +++++----- .../src/main/resources/application-druid.yml | 12 ++++++------ .../impl/EnforcementRegistrationServiceImpl.java | 2 +- .../mapper/EnforcementRegistrationMapper.xml | 7 ++++++- .../main/resources/mapper/Zqyjjdm137344Mapper.xml | 13 +++---------- 7 files changed, 30 insertions(+), 29 deletions(-) diff --git a/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppEnforcementRegistrationController.java b/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppEnforcementRegistrationController.java index 5a37ef45..c1ac1b57 100644 --- a/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppEnforcementRegistrationController.java +++ b/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppEnforcementRegistrationController.java @@ -39,6 +39,7 @@ public class AppEnforcementRegistrationController extends BaseController private IEnforcementRegistrationService enforcementRegistrationService; @Autowired private ILinkageDictService iLinkageDictService; @Autowired private IEnterpriseComplaintService enterpriseComplaintService; + @Autowired private IEnterpriseInformationService iEnterpriseInformationService; @Autowired private IZqyjjdm137344Service iZqyjjdm137344Service; @Autowired private UserApi userApi; @@ -296,15 +297,17 @@ public class AppEnforcementRegistrationController extends BaseController @ResponseBody public ZDResponse getByUserIdAndEnterpriseNumber(@PathVariable Long userId, @PathVariable String enterpriseNumber) { + // 拿到的企业编码是加密盐的, 和登记表对不上 + EnterpriseInformation enterpriseInformation = iEnterpriseInformationService.selectEnterpriseInformationBySalt(enterpriseNumber); // 前端似乎没保存部门id, 所以弄个userId上来 通过userId获取其部门id UserBean userBean = userApi.getUserByUserId(userId); - EnforcementRegistration registration = enforcementRegistrationService.getByDeptIdAndEnterpriseNumber(userBean.getDeptId(), enterpriseNumber); + EnforcementRegistration registration = enforcementRegistrationService.getByDeptIdAndEnterpriseNumber(userBean.getDeptId(), enterpriseInformation.getEnterpriseNumber()); if (null!=registration && StringUtils.isNotEmpty(registration.getId())) { Map params = new HashMap<>(); LinkageDict tmp = iLinkageDictService.selectLinkageDictById(registration.getLawEnforcementItem()); params.put("lawEnforcementItemText", null != tmp ? tmp.getTitle() : ""); - tmp = iLinkageDictService.selectLinkageDictById(registration.getLawEnforcementBasis()); - params.put("lawEnforcementBasisText", null != tmp ? tmp.getTitle() : ""); +// tmp = iLinkageDictService.selectLinkageDictById(registration.getLawEnforcementBasis()); +// params.put("lawEnforcementBasisText", null != tmp ? tmp.getTitle() : ""); registration.setParams(params); return ZDResponse.success("查询成功", registration); } diff --git a/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppThirdLoginController.java b/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppThirdLoginController.java index 1e5804a1..d4021ee7 100644 --- a/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppThirdLoginController.java +++ b/lib/EmergencyService/zdxtEmergencyAppService/src/main/java/com/zdxt/app/controller/AppThirdLoginController.java @@ -23,6 +23,7 @@ import com.zdxt.domain.auth.User; import lombok.extern.slf4j.Slf4j; import org.apache.commons.codec.binary.Hex; import org.apache.shiro.SecurityUtils; +import org.apache.shiro.authc.UsernamePasswordToken; import org.apache.shiro.subject.Subject; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -94,7 +95,7 @@ public class AppThirdLoginController { String secretKey = params.get("secretKey"); //解密 secretKey = AesHelper.desEncrypt(secretKey); -// UsernamePasswordToken token = new UsernamePasswordToken(username, password, false); +// UsernamePasswordToken token = new UsernamePasswordToken(secretName, secretKey, false); UserToken token = new UserToken(secretName, secretKey, LoginType.PASSWORD); Subject subject = SecurityUtils.getSubject(); subject.login(token); @@ -104,8 +105,7 @@ public class AppThirdLoginController { } catch (Exception e) { e.printStackTrace(); } - - return ZDResponse.success(); + return ZDResponse.error("登入失败"); } diff --git a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-dev.yml b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-dev.yml index 0518d2d7..a4ad1de8 100644 --- a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-dev.yml +++ b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-dev.yml @@ -3,12 +3,12 @@ spring: # redis配置 redis: database: 0 -# host: 10.76.108.1 -# port: 6379 -# password: ENC(nCzTixQexFdZNVhREOMMps2pNJ5gxrZb) - host: 43.136.51.161 + host: 10.76.108.1 port: 6379 - password: meiyoumima + password: zfjd@123 +# host: 43.136.51.161 +# port: 6379 +# password: meiyoumima timeout: 6000ms # 连接超时时长(毫秒) lettuce: pool: diff --git a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-druid.yml b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-druid.yml index 1d842364..d37e2182 100644 --- a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-druid.yml +++ b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/application-druid.yml @@ -6,13 +6,13 @@ spring: druid: # 主库数据源 master: - url: jdbc:mysql://146.56.223.227:3306/zfjd?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8 - username: ENC(XZ0cNb5wfN9GkTEq+SgVNA==) - password: ENC(+bxT7W35PF0k/5FZBYV0uwFLN+I9kZsF) +# url: jdbc:mysql://146.56.223.227:3306/zfjd?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8 +# username: ENC(XZ0cNb5wfN9GkTEq+SgVNA==) +# password: ENC(+bxT7W35PF0k/5FZBYV0uwFLN+I9kZsF) -# url: ENC(v3oHIZvpj5ZRTcLc41PnMXUVZbXK7dp+IKwsOlJ2bRUf5E5bagEjlB3qNwT7KiAnX3+ugTUeKWt1cVPh1iVLlQE1ELVNILu6k0X4/uH9ao53b4pLlyJsim67HozUikmKDQ/wDMxVUSkBW21g6jcKeEzXgSphxUQvPz/L8KJzzHJvkpDarGwYUZH+sV1VnSkHCHpPqW9wkbD/AN8K+iNiLw==) -# username: ENC(E5mY10bkGFBgN1Pljgzggg==) -# password: ENC(oqD1IasQS57qOeOHFtBdAAemGwJ2I7BV) + url: ENC(v3oHIZvpj5ZRTcLc41PnMXUVZbXK7dp+IKwsOlJ2bRUf5E5bagEjlB3qNwT7KiAnX3+ugTUeKWt1cVPh1iVLlQE1ELVNILu6k0X4/uH9ao53b4pLlyJsim67HozUikmKDQ/wDMxVUSkBW21g6jcKeEzXgSphxUQvPz/L8KJzzHJvkpDarGwYUZH+sV1VnSkHCHpPqW9wkbD/AN8K+iNiLw==) + username: ENC(E5mY10bkGFBgN1Pljgzggg==) + password: ENC(oqD1IasQS57qOeOHFtBdAAemGwJ2I7BV) # 从库数据源 slave: # 从数据源开关/默认关闭 diff --git a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/service/impl/EnforcementRegistrationServiceImpl.java b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/service/impl/EnforcementRegistrationServiceImpl.java index f4701f2c..1071b10a 100644 --- a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/service/impl/EnforcementRegistrationServiceImpl.java +++ b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/service/impl/EnforcementRegistrationServiceImpl.java @@ -200,7 +200,7 @@ public class EnforcementRegistrationServiceImpl implements IEnforcementRegistrat }); } //判断数据修改成功且状态为1时同步推送至 - if(i > 0 && enforcementRegistration.getStatus() == 1){ + if(i > 0 && null != enforcementRegistration.getStatus() && enforcementRegistration.getStatus() == 1){ //TODO 提交相对应的数据到后台管理,同时绑定对应的商户。相关的执法数据推送到其它平台 } diff --git a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/EnforcementRegistrationMapper.xml b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/EnforcementRegistrationMapper.xml index 75d75db9..66690b68 100644 --- a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/EnforcementRegistrationMapper.xml +++ b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/EnforcementRegistrationMapper.xml @@ -26,6 +26,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + @@ -56,7 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" enterprise_number, enforcement_time, create_time, create_by, law_enforcer, law_enforcer_id, law_enforcer_tel, law_enforcer_two, law_enforcer_id_two, law_enforcer_tel_two, subsidiaryer, subsidiaryer_id, subsidiaryer_tel, law_enforcement_item, law_enforcement_item_text, - law_enforcement_basis, remark, reslut, user_id, dept_id, is_delete, status, law_enforcement_code, + law_enforcement_basis, law_enforcement_basis_text, remark, reslut, user_id, dept_id, is_delete, status, law_enforcement_code, is_complaint,is_submit, unite_check,check_css, enforce_reason, law_field,check_category, bureau_dept_id,bureau_dept_name from enforcement_registration @@ -82,6 +83,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and law_enforcement_item = #{lawEnforcementItem} and law_enforcement_item_text like concat('%', #{lawEnforcementItemText,jdbcType=VARCHAR}, '%') and law_enforcement_basis = #{lawEnforcementBasis} + and law_enforcement_basis_text = #{lawEnforcementBasisText} and reslut = #{reslut} and is_submit = #{isSubmit} and user_id = #{userId} @@ -161,6 +163,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" law_enforcement_item, law_enforcement_item_text, law_enforcement_basis, + law_enforcement_basis_text, enforce, check_css, enforce_reason, @@ -201,6 +204,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" #{lawEnforcementItem}, #{lawEnforcementItemText}, #{lawEnforcementBasis}, + #{lawEnforcementBasisText}, #{enforce}, #{checkCss}, #{enforceReason}, @@ -244,6 +248,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" law_enforcement_item = #{lawEnforcementItem}, law_enforcement_item_text = #{lawEnforcementItemText}, law_enforcement_basis = #{lawEnforcementBasis}, + law_enforcement_basis_text = #{lawEnforcementBasisText}, enforce = #{enforce}, check_css = #{checkCss}, enforce_reason = #{enforceReason}, diff --git a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/Zqyjjdm137344Mapper.xml b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/Zqyjjdm137344Mapper.xml index 9e5b140f..f22d6d3f 100755 --- a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/Zqyjjdm137344Mapper.xml +++ b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/resources/mapper/Zqyjjdm137344Mapper.xml @@ -29,20 +29,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"