| | |
| | | @PostMapping(value = "/cusIdcard") |
| | | @ApiOperation(value = "根据身份证号获取用户信息") |
| | | // @Log(title = "客户身份信息", businessType = BusinessType.EXPORT) |
| | | @RepeatSubmit |
| | | public AjaxResult getInfoByIdCard(@RequestParam @ApiParam(value = "客户身份证号") String cusIdcard) { |
| | | if (!"".equals(cusIdcard) && cusIdcard != null) { |
| | | |
| | |
| | | return AjaxResult.error("身份证号码错误"); |
| | | } |
| | | } |
| | | // if(cusIdcard.length()==9){ |
| | | // if (!MatchUtils.cardValidates(cusIdcard)) { |
| | | // return AjaxResult.error("身份证号码错误"); |
| | | // } |
| | | // } |
| | | } |
| | | |
| | | |
| | |
| | | tjReservationService.updateById(tjReservation); |
| | | return AjaxResult.error("对不起您的预约已超时请重新预约"); |
| | | } |
| | | LambdaQueryWrapper<TjCustomer> qw = new LambdaQueryWrapper<>(); |
| | | qw.eq(TjCustomer::getCusIdcard, cusIdcard); |
| | | TjCustomer tjCustomer1 = tjCustomerService.getOne(qw); |
| | | TjCustomer tjCustomer1 = tjCustomerService.getTjCustomerByCusIdCard(cusIdcard); |
| | | if (tjCustomer1 != null) { |
| | | // if (null != tjReservation.getCompanyId()) tjCustomer1.setDictCompId(Long.valueOf(tjReservation.getCompanyId())); |
| | | // if (null != tjReservation.getCompany()) tjCustomer1.setCompName(tjReservation.getCompany()); |
| | |
| | | tjCustomer.setCusPhone(tjReservation.getPhoe()); |
| | | tjCustomer.setCusEmail(tjReservation.getEmail()); |
| | | tjCustomer.setCusAddr(tjReservation.getAddress()); |
| | | tjCustomer.setCusMarryStatus(String.valueOf(tjReservation.getMarriage())); |
| | | tjCustomer.setCusNational(String.valueOf(tjReservation.getNation())); |
| | | tjCustomer.setCusMarryStatus(String.valueOf(tjReservation.getMarriage())==null ?"0": tjReservation.getMarriage().toString()); |
| | | tjCustomer.setCusNational(String.valueOf(tjReservation.getNation()) ==null ? "0": tjReservation.getNation().toString()); |
| | | |
| | | tjCustomer.setIdType(tjReservation.getIdType()); |
| | | tjCustomer.setAge(tjReservation.getAge()); |
| | |
| | | String pationid = resultData.get("PationId").toString(); |
| | | if (null != pationid) { |
| | | tjCustomer.setPationId(pationid); |
| | | tjCustomerService.save(tjCustomer); |
| | | // tjCustomerService.save(tjCustomer); |
| | | //保存注册入参出参 |
| | | resultData.put("cardId",pationid); |
| | | JSONObject object4 = JSONUtil.parseObj(resultData); |
| | |
| | | } else if(null != s && s.equalsIgnoreCase("Y")) { |
| | | tjCustomer = isRequestCommonHisApi(tjCustomer); |
| | | } |
| | | if(null != tjCustomer){ |
| | | tjCustomerService.save(tjCustomer); |
| | | // TjCustomer tjCustomerByCusIdCard = tjCustomerService.getTjCustomerByCusIdCard(cusIdcard); |
| | | // if(null != tjCustomerByCusIdCard) |
| | | tjCustomerService.save(tjCustomer); |
| | | tjCustomer.setTeamNo(tjReservation.getTeamNo()); |
| | | tjCustomer.setCompId(tjReservation.getCompanyId()); |
| | | tjCustomer.setReservationId(tjReservation.getId()); |
| | | tjCustomer.setDiscount(tjReservation.getDiscount()); |
| | | tjCustomer.setGroupingId(tjReservation.getGroupingId()); |
| | | } |
| | | |
| | | return success(tjCustomer); |
| | | } |
| | | |