From a28c894d35b5ca697bfe455c2d584c7f28ec3722 Mon Sep 17 00:00:00 2001
From: lige <bestlige@outlook.com>
Date: 星期五, 15 十二月 2023 15:51:59 +0800
Subject: [PATCH] 优化项目列表

---
 ltkj-admin/src/main/java/com/ltkj/web/controller/system/TjCustomerController.java |   25 ++++++++++++++++++++++---
 1 files changed, 22 insertions(+), 3 deletions(-)

diff --git a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/TjCustomerController.java b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/TjCustomerController.java
index cacb0bb..fbb2ab9 100644
--- a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/TjCustomerController.java
+++ b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/TjCustomerController.java
@@ -7,7 +7,10 @@
 import com.ltkj.common.utils.bean.BeanUtils;
 import com.ltkj.framework.config.MatchUtils;
 import com.ltkj.hosp.domain.TjReservation;
+import com.ltkj.hosp.mapper.TestMapper;
 import com.ltkj.hosp.service.ITjReservationService;
+import com.ltkj.hosp.sqlDomain.LtkjTjPat;
+import com.ltkj.system.service.ISysConfigService;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import io.swagger.annotations.ApiParam;
@@ -44,6 +47,12 @@
     @Resource
     private ITjReservationService tjReservationService;
 
+    @Resource
+    private ISysConfigService sysConfigService;
+
+    @Resource
+    private TestMapper testMapper;
+
 
 
     /**
@@ -66,6 +75,13 @@
                     return AjaxResult.error("韬唤璇佸彿鐮侀敊璇�");
                 }
             }
+            //鏍规嵁閰嶇疆璋冨彇瀛樺偍杩囩▼ 灏嗕复鏃惰〃鏁版嵁瀛樺叆棰勭害琛�2023.12.12
+            final String getInfoFromSqlData = sysConfigService.selectConfigByKey("getInfoFromSqlData");
+            if ("Y".equals(getInfoFromSqlData)){
+//                 LtkjTjPat tjPatByIdCard = testMapper.getTjPatByIdCard(cusIdcard);
+                 testMapper.getTjPatByCusId(cusIdcard);
+            }
+            //end====2023.12.12
             LambdaQueryWrapper<TjReservation> wq = new LambdaQueryWrapper<>();
             wq.eq(TjReservation::getIdCard, cusIdcard);
             wq.eq(TjReservation::getIsExpire, 2);
@@ -98,13 +114,14 @@
                     tjCustomer1.setAgeUnit(tjReservation.getAgeUnit());
                     tjCustomer1.setCareer(tjReservation.getCareer());
 
-
                     tjCustomerService.updateById(tjCustomer1);
                     tjCustomer1.setTeamNo(tjReservation.getTeamNo());
                     tjCustomer1.setCompId(tjReservation.getCompanyId());
                     tjCustomer1.setReservationId(tjReservation.getId());
                     tjCustomer1.setDiscount(tjReservation.getDiscount());
                     tjCustomer1.setGroupingId(tjReservation.getGroupingId());
+
+
                     return success(tjCustomer1);
                 }
                 TjCustomer tjCustomer = new TjCustomer();
@@ -122,7 +139,9 @@
                 tjCustomer.setAge(tjReservation.getAge());
                 tjCustomer.setAgeUnit(tjReservation.getAgeUnit());
                 tjCustomer.setCareer(tjReservation.getCareer());
-
+                tjCustomer.setDwPhone(tjReservation.getDwPhone());
+                tjCustomer.setCardId(tjReservation.getCardId());
+                tjCustomer.setIndexCard(tjReservation.getIndexCard());
 
                 //鎴彇瀵嗙爜鑷姩鐢熸垚set杩涘幓
                 String substring = cusIdcard.substring(cusIdcard.length() - 6);
@@ -149,7 +168,7 @@
     /**
      * 鏌ヨ瀹㈡埛淇℃伅鍒楄〃
      */
-    @PreAuthorize("@ss.hasPermi('hosp:customer:list')")
+//    @PreAuthorize("@ss.hasPermi('hosp:customer:list')")
     @GetMapping("/list")
     @ApiOperation(value = "鏌ョ湅瀹㈡埛鍒楄〃")
     public TableDataInfo list(TjCustomer tjCustomer) {

--
Gitblit v1.8.0