|
|
@@ -2,15 +2,19 @@ package org.jeecg.modules.medical.common;
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.jeecg.common.system.vo.DictModel;
|
|
|
import org.jeecg.common.util.SpringContextUtils;
|
|
|
import org.jeecg.modules.medical.Constant;
|
|
|
import org.jeecg.modules.medical.ruleengine.SPELUtil;
|
|
|
+import org.jeecg.modules.system.service.ISysDictService;
|
|
|
import org.quartz.DisallowConcurrentExecution;
|
|
|
import org.springframework.data.redis.core.RedisTemplate;
|
|
|
|
|
|
import java.time.LocalDate;
|
|
|
import java.time.Period;
|
|
|
import java.util.Date;
|
|
|
+import java.util.HashMap;
|
|
|
+import java.util.List;
|
|
|
import java.util.Map;
|
|
|
|
|
|
@Slf4j
|
|
|
@@ -19,6 +23,8 @@ public class CommonUtil {
|
|
|
|
|
|
static RedisTemplate redisTemplate = (RedisTemplate) SpringContextUtils.getBean("redisTemplate");
|
|
|
|
|
|
+ static ISysDictService sysDictService = SpringContextUtils.getBean(ISysDictService.class);
|
|
|
+
|
|
|
public static String getProjectType(String projectCode) {
|
|
|
String projectType = null;
|
|
|
if (projectCode.startsWith(Constant.CONSUMABLE_START_KEY)) {
|
|
|
@@ -128,6 +134,19 @@ public class CommonUtil {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ public static Map<String, String> getCategoriesItemsMap(){
|
|
|
+ List<DictModel> cateGoriesList = sysDictService.getDictItems(Constant.DICT_CATEGORIES_ITEMS_KEY);
|
|
|
+ Map<String, String> cateGoriesMap = new HashMap<>();
|
|
|
+ for (DictModel dictModel : cateGoriesList) {
|
|
|
+ cateGoriesMap.put(dictModel.getText(), dictModel.getValue());
|
|
|
+ }
|
|
|
+ cateGoriesMap.put("中草药","10");
|
|
|
+ cateGoriesMap.put("其他","1415");
|
|
|
+ cateGoriesMap.put("其它医疗费","1415");
|
|
|
+ cateGoriesMap.put("中成药","11");
|
|
|
+ return cateGoriesMap;
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
public static void main(String[] args) {
|
|
|
// String day = "2023-11-09 19:10:11";
|