From 971162978842f8cf87d34f99da8c529e2e945da8 Mon Sep 17 00:00:00 2001 From: zjh <1084500556@qq.com> Date: 星期二, 15 四月 2025 08:46:57 +0800 Subject: [PATCH] zjh20250415 --- ltkj-admin/src/main/java/com/ltkj/web/controller/system/DictSfxmController.java | 53 +++++++++++++++++++++++++++++++++++++++++++++++++---- 1 files changed, 49 insertions(+), 4 deletions(-) diff --git a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/DictSfxmController.java b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/DictSfxmController.java index 7a9403b..b8cbecc 100644 --- a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/DictSfxmController.java +++ b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/DictSfxmController.java @@ -6,11 +6,13 @@ import javax.servlet.http.HttpServletResponse; import cn.hutool.extra.pinyin.PinyinUtil; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.ltkj.common.core.redis.RedisCache; import com.ltkj.framework.config.MatchUtils; import com.ltkj.hosp.domain.DictHosp; import com.ltkj.hosp.domain.DictSfxm; import com.ltkj.hosp.domain.TjCustomer; +import com.ltkj.hosp.domain.TjOrder; import com.ltkj.hosp.service.IDictHospService; import com.ltkj.hosp.service.IDictSfxmService; import com.ltkj.hosp.service.TjAsyncService; @@ -56,12 +58,12 @@ public TableDataInfo list(@RequestBody DictSfxm dictSfxm) { startPage(); String pym = dictSfxm.getPym(); - if(null !=pym && !"".equals(pym)) { + if(null !=pym && !pym.isEmpty()) { pym=dictSfxm.getPym().toUpperCase(Locale.ROOT); dictSfxm.setPym(pym); } List<DictSfxm> list = dictSfxmService.selectDictSfxmList(dictSfxm); - if (null != list && list.size() > 0) { + if (null != list && !list.isEmpty()) { for (DictSfxm sfxm : list) { DictHosp hosp = dictHospService.getById(sfxm.getYqid()); if (null != hosp) { @@ -186,7 +188,7 @@ map.put("date", sfxmList); map.put("total", sfxms.size()); } else { - map.put("date", 0); + map.put("date", null); map.put("total", 0); } return AjaxResult.success(map); @@ -207,11 +209,54 @@ map.put("date", sfxmList); map.put("total", sfx.size()); } else { - map.put("date", 0); + map.put("date", null); map.put("total", 0); } return AjaxResult.success(map); } return AjaxResult.success(map); } + + +// /** +// * 鏌ヨ鏀惰垂椤圭洰鍒楄〃 +// */ +// @PostMapping("/getSfxmList") +// @ApiOperation(value = "鏌ヨ") +// public AjaxResult getSfxmList(@ApiParam(value = "椤电爜鏁�(榛樿1)") @RequestParam(defaultValue = "1") Integer page, +// @ApiParam(value = "鏄剧ず鏉℃暟(榛樿10)") @RequestParam(defaultValue = "10") Integer pageSize, +// @ApiParam(value = "鎷奸煶鐮�") @RequestParam(required = false) String pym, +// @ApiParam(value = "鍚嶇О") @RequestParam(required = false) String xmmc, +// @ApiParam(value = "id") @RequestParam(required = false) String id) { +// Map<String, Object> map = new HashMap<>(); +// List<DictSfxm> collect = null; +// LambdaQueryWrapper<DictSfxm> wq=new LambdaQueryWrapper<>(); +// if(null !=pym && !"".equals(pym)) { +// pym=pym.toUpperCase(Locale.ROOT); +// wq.like(DictSfxm::getPym,pym); +// } +// if(null !=xmmc && !"".equals(xmmc)) { +// wq.like(DictSfxm::getXmmc,xmmc); +// } +// if(null !=id && !"".equals(id)) { +// wq.like(DictSfxm::getId,id); +// } +// List<DictSfxm> list = dictSfxmService.list(wq); +// if (null != list && list.size() > 0) { +// for (DictSfxm sfxm : list) { +// DictHosp hosp = dictHospService.getById(sfxm.getYqid()); +// if (null != hosp) { +// sfxm.setYqName(hosp.getHospAreaName()); +// } +// } +// } +// collect = list.stream().skip((long) (page - 1) * pageSize).limit(pageSize).collect(Collectors.toList()); +// if (null != collect) { +// map.put("total", collect.size()); +// } else { +// map.put("total", 0); +// } +// map.put("list", collect); +// return AjaxResult.success(map); +// } } -- Gitblit v1.8.0