From b02beccf4567068cb47a3f1181a00039456c872d Mon Sep 17 00:00:00 2001
From: zqy <2522236926@qq.com>
Date: 星期三, 06 八月 2025 15:37:20 +0800
Subject: [PATCH] 用户修改姓名和电话同步修改uaid

---
 ruoyi-admin/src/main/java/com/ruoyi/web/controller/zhang/ZfDoctorController.java |   29 ++++++++++++++++++-----------
 1 files changed, 18 insertions(+), 11 deletions(-)

diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/zhang/ZfDoctorController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/zhang/ZfDoctorController.java
index 9a197dd..9e60a80 100644
--- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/zhang/ZfDoctorController.java
+++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/zhang/ZfDoctorController.java
@@ -46,6 +46,11 @@
         return zfDoctorService.selectDoctorList(zfDoctor, pageNum, pageSize);
     }
 
+    @GetMapping("/type")
+    public AjaxResult listType(){
+        return zfDoctorService.listType();
+    }
+
     /**
      * 鑾峰彇瀵煎叆妯℃澘
      */
@@ -76,7 +81,7 @@
 //    @PreAuthorize("@ss.hasPermi('system:property:export')")
     @Log(title = "瀹跺涵灏忓尰鐢熻褰�", businessType = BusinessType.EXPORT)
     @PostMapping("/export1/{ids}")
-    public void export1(HttpServletResponse response, @PathVariable Long[] ids)
+    public void export(HttpServletResponse response, @PathVariable Long[] ids)
     {
         List<ZfDoctor> list = zfDoctorService.selectByIds(ids);
         log.info("瀵煎嚭璁板綍涓�:{}",list);
@@ -90,14 +95,16 @@
     @PostMapping("/importData")
     public AjaxResult importData(@RequestParam("excelImport") MultipartFile file) throws Exception
     {
-        ExcelUtil<ZfDoctor> util = new ExcelUtil<>(ZfDoctor.class);
-        List<ZfDoctor> eventList = util.importExcel(file.getInputStream());
-        log.info("瀹跺涵灏忓尰鐢熷垪琛ㄤ负锛歿}",eventList);
+//        ExcelUtil<ZfDoctor> util = new ExcelUtil<>(ZfDoctor.class);
+//        List<ZfDoctor> eventList = util.importExcel(file.getInputStream());
+//        log.info("瀹跺涵灏忓尰鐢熷垪琛ㄤ负锛歿}",eventList);
+//
+//        if (zfDoctorService.saveBatch(eventList)) {
+//            return AjaxResult.success("瀵煎叆鏁版嵁鎴愬姛");
+//        }
+//        return AjaxResult.error("瀵煎叆鏁版嵁澶辫触");
 
-        if (zfDoctorService.saveBatch(eventList)) {
-            return AjaxResult.success("瀵煎叆鏁版嵁鎴愬姛");
-        }
-        return AjaxResult.error("瀵煎叆鏁版嵁澶辫触");
+        return zfDoctorService.importExcel(file);
     }
 
     /**
@@ -118,7 +125,7 @@
     @PostMapping
     public AjaxResult add(@RequestBody ZfDoctor zfDoctor)
     {
-        return zfDoctorService.mySave(zfDoctor);
+        return zfDoctorService.addData(zfDoctor);
     }
 
     /**
@@ -129,7 +136,7 @@
     @PutMapping
     public AjaxResult edit(@RequestBody ZfDoctor zfDoctor)
     {
-        return toAjax(zfDoctorService.updateById(zfDoctor));
+        return zfDoctorService.updateData(zfDoctor);
     }
 //
     /**
@@ -140,7 +147,7 @@
     @DeleteMapping("/{ids}")
     public AjaxResult remove(@PathVariable Long[] ids)
     {
-        return toAjax(zfDoctorService.removeByIds(Arrays.asList(ids)));
+        return zfDoctorService.deleteData(ids);
     }
 
 }

--
Gitblit v1.9.1