ソースを参照

[医保代码]

wangzhinan 3 年 前
コミット
a35145ccdd

+ 36 - 23
business/base-service/src/main/java/com/yihu/jw/order/BusinessOrderService.java

@ -2024,6 +2024,15 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
        sql+=" order by t.create_time desc ";
        List<Map<String,Object>> list = hibenateUtils.createSQLQuery(sql,page,pageSize);
        for (Map<String,Object> map:list){
            if (map.get("orderCategory")!=null){
                String orderCategoryFlag = map.get("orderCategory").toString();
                if (!orderCategoryFlag.equalsIgnoreCase("5")){
                    Integer price = Integer.parseInt(map.get("payPrice").toString());
                    map.put("payPrice",price/100);
                }
            }
        }
        /*for (Map<String,Object> map:list){
            if (map.get("createTime")!=null){
                map.put("createTime",);
@ -2048,25 +2057,25 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
                "\t' '\n" +
                "ELSE\n" +
                "\tt.id\n" +
                "END id,\n" +
                "END \"id\",\n" +
                " CASE t.patient\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.patient\n" +
                "END patient,\n" +
                "END \"patient\",\n" +
                " CASE t.patient_name\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.patient_name\n" +
                "END patientName,\n" +
                "END \"patientName\",\n" +
                " CASE t.order_no\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.order_no\n" +
                "END orderNo,\n" +
                "END \"orderNo\",\n" +
                /*" CASE t.order_type\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
@ -2078,85 +2087,85 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
                "\t' '\n" +
                "ELSE\n" +
                "\tt.relation_code\n" +
                "END relationCode,\n" +
                "END \"relationCode\",\n" +
                " CASE t.relation_name\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.relation_name\n" +
                "END relationName,\n" +
                "END \"relationName\",\n" +
                " CASE t.description\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.description\n" +
                "END description,\n" +
                "END \"description\",\n" +
                " CASE t.pay_type\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.pay_type\n" +
                "END payType,\n" +
                "END \"payType\",\n" +
                " CASE t.pay_price\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.pay_price\n" +
                "END payPrice,\n" +
                "END \"payPrice\",\n" +
                " CASE t.pay_time\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.pay_time\n" +
                "END payTime,\n" +
                "END \"payTime\",\n" +
                " CASE t.upload_status\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.upload_status\n" +
                "END uploadStatus,\n" +
                "END \"uploadStatus\",\n" +
                " CASE t.create_time\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.create_time\n" +
                "END createTime,\n" +
                "END \"createTime\",\n" +
                " CASE t.remark\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.remark\n" +
                "END remark,\n" +
                "END \"remark\",\n" +
                " CASE t.relation_code\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.relation_code\n" +
                "END medicard,\n" +
                "END \"medicard\",\n" +
                " CASE t.yk_order_no\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.yk_order_no\n" +
                "END ykOrderNo,\n" +
                "END \"ykOrderNo\",\n" +
                " CASE t.yk_order_id\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tt.yk_order_id\n" +
                "END ykOrderId,\n" +
                "END \"ykOrderId\",\n" +
                " CASE b.idcard\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tb.idcard\n" +
                "END idcard,\n" +
                "END \"idcard\",\n" +
                " CASE b.mobile\n" +
                "WHEN NULL THEN\n" +
                "\t' '\n" +
                "ELSE\n" +
                "\tb.mobile\n" +
                "END mobile,\n" +
                "END \"mobile\",\n" +
                " CASE t. STATUS\n" +
                "WHEN 0 THEN\n" +
                "\t'未支付'\n" +
@ -2188,7 +2197,7 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
                "\t' '\n" +
                "ELSE\n" +
                "\tt.order_category\n" +
                "END orderCategory\n" +
                "END \"orderCategory\" \n" +
                "FROM\n" +
                "\tbase_business_order_pay t\n" +
                "LEFT JOIN base_patient b ON t.patient = b.id\n" +
@ -2248,11 +2257,15 @@ public class BusinessOrderService extends BaseJpaService<BusinessOrderDO,Busines
        sql+=" order by t.create_time desc ";
        List<Map<String,Object>> mapList = hibenateUtils.createSQLQuery(sql);
        /*for (Map<String,Object> map:list){
            if (map.get("createTime")!=null){
                map.put("createTime",);
        for (Map<String,Object> map:mapList){
            if (map.get("orderCategory")!=null){
                String orderCategoryFlag = map.get("orderCategory").toString();
                if (!orderCategoryFlag.equalsIgnoreCase("5")){
                    Integer price = Integer.parseInt(map.get("payPrice").toString());
                    map.put("payPrice",price/100);
                }
            }
        }*/
        }
        return MixEnvelop.getSuccessListWithPage2(BaseHospitalRequestMapping.Prescription.api_success, mapList);
    }