| | |
| | | //判断身份证号格式是否正确 |
| | | if(sfjysfzh.equalsIgnoreCase("Y")){ |
| | | if(cusIdcard.length()==18){ |
| | | if (! MatchUtils.isIdCard(cusIdcard)) { |
| | | if (!MatchUtils.isIdCard(cusIdcard)) { |
| | | return AjaxResult.error("身份证号码错误"); |
| | | } |
| | | } |
| | | if(cusIdcard.length()==9){ |
| | | if (!MatchUtils.cardValidates(cusIdcard)) { |
| | | return AjaxResult.error("身份证号码错误"); |
| | | } |
| | | } |
| | | // if(cusIdcard.length()==9){ |
| | | // if (!MatchUtils.cardValidates(cusIdcard)) { |
| | | // return AjaxResult.error("身份证号码错误"); |
| | | // } |
| | | // } |
| | | } |
| | | |
| | | |
| | |
| | | |
| | | //判断身份证号格式是否正确 |
| | | if(sfjysfzh.equalsIgnoreCase("Y")){ |
| | | if(tjCustomer.getCusIdcard().length()==18){ |
| | | if(customer.getIdType().equals("1")){ |
| | | if (!(MatchUtils.isIdCard(tjCustomer.getCusIdcard()))) |
| | | return AjaxResult.error("身份证号错误"); |
| | | } |
| | | |
| | | if(tjCustomer.getCusIdcard().length()==9){ |
| | | if (!MatchUtils.cardValidates(tjCustomer.getCusIdcard())) { |
| | | return AjaxResult.error("身份证号码错误"); |
| | | } |
| | | } |
| | | // if(tjCustomer.getCusIdcard().length()==9){ |
| | | // if (!MatchUtils.cardValidates(tjCustomer.getCusIdcard())) { |
| | | // return AjaxResult.error("身份证号码错误"); |
| | | // } |
| | | // } |
| | | } |
| | | |
| | | |