| | |
| | | order.setTjCustomerAge(DateUtil.ageOfNow(tjCustomer.getCusBrithday())); |
| | | order.setTjCustomerName(MatchUtils.hideCusName(tjCustomer.getCusName())); |
| | | order.setTjCustomerPhone(MatchUtils.hidePhoneNum(tjCustomer.getCusPhone())); |
| | | order.setTjCusIdCard(MatchUtils.hideIdCardNum(tjCustomer.getCusIdcard())); |
| | | if (tjCustomer.getCusIdcard()!=null){ |
| | | order.setTjCusIdCard(MatchUtils.hideIdCardNum(tjCustomer.getCusIdcard())); |
| | | } |
| | | } |
| | | String firmId = order.getFirmId(); |
| | | if (firmId != null && null != iDictCompService.getById(String.valueOf(order.getFirmId()))) { |
| | |
| | | druid: |
| | | # 主库数据源 |
| | | master: |
| | | # url: jdbc:mysql://101.42.27.146:3306/ltkj_tj1.0?serverTimezone=GMT%2B8 |
| | | url: jdbc:mysql://localhost:3306/ltkj_tj1.0?serverTimezone=GMT%2B8 |
| | | url: jdbc:mysql://101.42.27.146:3306/ltkj_tj1.0?serverTimezone=GMT%2B8 |
| | | # url: jdbc:mysql://localhost:3306/ltkj_tj1.0?serverTimezone=GMT%2B8 |
| | | username: root |
| | | #password: Root_ltkj123 |
| | | password: Root_ltkj123 |
| | |
| | | private String secret; |
| | | @Test |
| | | public void test() { |
| | | // List<DictHosp> list = dictHospService.list(); |
| | | // for (DictHosp dictHosp : list) { |
| | | List<DictHosp> list = dictHospService.list(); |
| | | for (DictHosp dictHosp : list) { |
| | | // DateTime dateTime1 = DateUtil.offsetMonth(new Date(),6); |
| | | // String mallMerchantSecretKey = SecurityUtils.getMallMerchantSecretKey(secret,dictHosp.getHospAreaId(),dictHosp.getHospAreaName(),dictHosp.getExpirationTime()); |
| | | // dictHosp.setSecretKey(mallMerchantSecretKey); |
| | | String mallMerchantSecretKey = SecurityUtils.getMallMerchantSecretKey(secret,dictHosp.getHospAreaId(),dictHosp.getHospAreaName(),dictHosp.getExpirationTime()); |
| | | dictHosp.setSecretKey(mallMerchantSecretKey); |
| | | // dictHosp.setExpirationTime(DateUtil.offsetDay(new Date(),30)); |
| | | // dictHospService.updateById(dictHosp); |
| | | // System.out.println(dateTime1); |
| | | // System.out.println("================================================="); |
| | | // System.out.println(mallMerchantSecretKey); |
| | | // } |
| | | } |
| | | } |
| | | |
| | | |
| | |
| | | * @return |
| | | */ |
| | | public static String hidePhoneNum(String phoneNum){ |
| | | if (phoneNum==null){ |
| | | return ""; |
| | | } |
| | | if(phoneNum.contains("*")){ |
| | | return phoneNum; |
| | | } |
| | | |
| | | Pattern pattern = Pattern.compile("((13[0-9])|(14[5,7,9])|(15([0-3]|[5-9]))|(17[0,1,3,5,6,7,8])|(18[0-9])|(19[8|9]))\\d{8}"); |
| | | Matcher matcher = pattern.matcher(phoneNum); |
| | | StringBuffer sb = new StringBuffer(); |
| | |
| | | */ |
| | | public static String hideIdCardNum(String idCardNum){ |
| | | |
| | | if (idCardNum==null){ |
| | | return ""; |
| | | } |
| | | if(idCardNum.contains("*")){ |
| | | return idCardNum; |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | public static String hideCusName(String cusName){ |
| | | if (cusName==null){ |
| | | return ""; |
| | | } |
| | | if(cusName.contains("*")){ |
| | | return cusName; |
| | | } |
| | | |
| | | String realname=null; |
| | | char[] r = cusName.toCharArray(); |
| | | if(r.length ==1){ |