zjh
2024-06-13 1502f0836f5d2703881e00c500b66a86ed84c989
zjh 本地 2024/06/13 --2
1个文件已修改
14 ■■■■ 已修改文件
ltkj-admin/src/main/java/com/ltkj/web/controller/system/TjCustomerController.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ltkj-admin/src/main/java/com/ltkj/web/controller/system/TjCustomerController.java
@@ -28,6 +28,7 @@
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.DigestUtils;
import org.springframework.web.bind.annotation.*;
import com.ltkj.common.core.controller.BaseController;
@@ -349,6 +350,7 @@
     */
    @PostMapping
    @ApiOperation(value = "新增客户")
    @Transactional
    public AjaxResult add(@RequestBody @ApiParam(value = "客户对象信息") TjCustomer tjCustomer) {
        if (null == tjCustomer.getCusIdcard() || null == tjCustomer.getCusPhone()) {
            return AjaxResult.error("请输入身份证号或手机号");
@@ -400,6 +402,10 @@
        if(null !=config && config.equals("Y")){
            AjaxResult tjCustomer1 = suijieHisXinXi(tjCustomer, date);
            if (tjCustomer1 != null) return tjCustomer1;
        }else {
            if (tjCustomerService.save(tjCustomer)) {
                return AjaxResult.success(tjCustomer);
            }
        }
        return AjaxResult.error();
}
@@ -438,15 +444,15 @@
                                String hisRegistrationId = resultDatasss.get("his_registration_id").toString();
                                if (null != hisRegistrationId) {
                                    //门诊医生接诊
                                    AjaxResult result3 = controller.Outpinconapply(hisRegistrationId, date, SecurityUtils.getUsername());
                                    AjaxResult result3 = controller.Outpinconapply(hisRegistrationId, date,"00029");
                                    String result4 = getAjaxResult(result3);
                                    JSONObject object2 = getJSONObject(result4);
                                    String code2 = object2.getStr("ResultCode");
                                    if (code2.equals("0")) {
                                        Map<String, Object> data = object2.getJSONObject("ResultData");
                                        String toString = data.get("his_registration_id").toString();
//                                        tjCustomer.setPationId(pationid);
                                        tjCustomer.setCardId(toString);
                                        String hisRegistrationId1 = data.get("his_registration_id").toString();
                                        tjCustomer.setPationId(pationid);
                                        tjCustomer.setCardId(hisRegistrationId1);
//                                        tjCustomerService.updateById(tjCustomer);
                                    }
                                }