| | |
| | | user.setClinicId(clinic.getId()); |
| | | userMapper.insert(user); |
| | | |
| | | Integer provinceCode = parseRegionCode(clinic.getProvinceCode(), "省编码"); |
| | | Integer cityCode = parseRegionCode(clinic.getCityCode(), "市编码"); |
| | | Integer areaCode = parseRegionCode(clinic.getDistrictCode(), "区县编码"); |
| | | log.info("调用微赞创建门店,入参 title={}, provinceCode={}, cityCode={}, areaCode={}, address={}, telephone={}", |
| | | clinic.getName(), provinceCode, cityCode, areaCode, clinic.getAddress(), clinic.getContactPhone()); |
| | | try { |
| | | JsonNode vzanResponse = vzanHttpUtil.createStore(clinic.getName(), provinceCode, cityCode, areaCode, clinic.getAddress(), clinic.getContactPhone()); |
| | | log.info("微赞创建门店成功,出参={}", vzanResponse); |
| | | } catch (RuntimeException ex) { |
| | | log.error("微赞创建门店失败,本地事务将回滚,入参 title={}, provinceCode={}, cityCode={}, areaCode={}, address={}, telephone={}", |
| | | clinic.getName(), provinceCode, cityCode, areaCode, clinic.getAddress(), clinic.getContactPhone(), ex); |
| | | throw new IllegalStateException("微赞创建门店失败", ex); |
| | | } |
| | | // Integer provinceCode = parseRegionCode(clinic.getProvinceCode(), "省编码"); |
| | | // Integer cityCode = parseRegionCode(clinic.getCityCode(), "市编码"); |
| | | // Integer areaCode = parseRegionCode(clinic.getDistrictCode(), "区县编码"); |
| | | // log.info("调用微赞创建门店,入参 title={}, provinceCode={}, cityCode={}, areaCode={}, address={}, telephone={}", |
| | | // clinic.getName(), provinceCode, cityCode, areaCode, clinic.getAddress(), clinic.getContactPhone()); |
| | | // try { |
| | | // JsonNode vzanResponse = vzanHttpUtil.createStore(clinic.getName(), provinceCode, cityCode, areaCode, clinic.getAddress(), clinic.getContactPhone()); |
| | | // log.info("微赞创建门店成功,出参={}", vzanResponse); |
| | | // } catch (RuntimeException ex) { |
| | | // log.error("微赞创建门店失败,本地事务将回滚,入参 title={}, provinceCode={}, cityCode={}, areaCode={}, address={}, telephone={}", |
| | | // clinic.getName(), provinceCode, cityCode, areaCode, clinic.getAddress(), clinic.getContactPhone(), ex); |
| | | // throw new IllegalStateException("微赞创建门店失败", ex); |
| | | // } |
| | | |
| | | clearDraft(request.getRegisterTicket()); |
| | | return createLoginResponse(user); |