xiaochan 1 anno fa
parent
commit
512ef15d5f

+ 8 - 2
src/main/java/thyyxxk/webserver/controller/zhuyuanyizheng/YizhuLuRuController.java

@@ -6,6 +6,7 @@ import org.springframework.validation.annotation.Validated;
 import org.springframework.web.bind.annotation.*;
 import thyyxxk.webserver.config.auth.PassToken;
 import thyyxxk.webserver.config.exception.ExceptionEnum;
+import thyyxxk.webserver.dao.his.zhuyuanyisheng.YiZhuLuRuDao;
 import thyyxxk.webserver.entity.ResultVo;
 import thyyxxk.webserver.entity.datamodify.GetDropdownBox;
 import thyyxxk.webserver.entity.datamodify.SelectV2;
@@ -36,12 +37,13 @@ import java.util.Map;
 @RequestMapping("/yiZhuLuRu")
 public class YizhuLuRuController {
     private final YiZhuLuRuServer server;
+    private final YiZhuLuRuDao dao;
 
-    public YizhuLuRuController(YiZhuLuRuServer server) {
+    public YizhuLuRuController(YiZhuLuRuServer server, YiZhuLuRuDao dao) {
         this.server = server;
+        this.dao = dao;
     }
 
-
     @GetMapping("/getOrderNo")
     public ResultVo<String> getOrderNo() {
         return server.getOrderNo();
@@ -235,5 +237,9 @@ public class YizhuLuRuController {
         return server.copyTableOrder(param);
     }
 
+    @GetMapping("/getItemInstructions")
+    public ResultVo<List<JSONObject>> getItemInstructions(@RequestParam(value = "code", defaultValue = "") String code) {
+        return ResultVoUtil.success(dao.getItemInstructions(code));
+    }
 
 }

+ 14 - 0
src/main/java/thyyxxk/webserver/dao/his/zhuyuanyisheng/YiZhuLuRuDao.java

@@ -1,5 +1,6 @@
 package thyyxxk.webserver.dao.his.zhuyuanyisheng;
 
+import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.core.conditions.Wrapper;
 import com.baomidou.mybatisplus.core.toolkit.Constants;
 import org.apache.ibatis.annotations.*;
@@ -1455,4 +1456,17 @@ public interface YiZhuLuRuDao {
             "order_code = '${orderCode}' and serial = '00'")
     Integer selectCountByOrderCode(String patNo, Integer times, String orderCode);
 
+    @Select("SELECT 收费编码=a.occ_code,\n" +
+            "       项目名称=b.name,\n" +
+            "       数量=a.amount,\n" +
+            "       单价=b.charge_amount,\n" +
+            "       个人自付比例=selfpay_prop + '%',\n" +
+            "       医保说明=isnull(b.connotation, '无') + '|' + isnull(b.descriptions, '无'),\n" +
+            "       医保编码=national_code\n" +
+            "FROM yz_order_occurence a,\n" +
+            "     zd_charge_item b\n" +
+            "where a.order_code = '${code}'\n" +
+            "  and a.occ_code = b.code")
+    List<JSONObject> getItemInstructions(String code);
+
 }