|
@@ -19,11 +19,11 @@ import java.util.Set;
|
|
|
public class ModuleMappingUtil {
|
|
|
|
|
|
public static final Map<String, Map<Set<String>, String>> xmlDataTypeModuleInfo = Maps.newHashMap();
|
|
|
- public static final Map<String, String> htmlDataTypeModuleInfo = Maps.newHashMap();
|
|
|
- public static final Map<String, String> standardModuleInfo = Maps.newHashMap();
|
|
|
+ public static final Map<String, Map<String, String>> htmlDataTypeModuleInfo = Maps.newHashMap();
|
|
|
+ public static final Map<String, Map<String, String>> standardModuleInfo = Maps.newHashMap();
|
|
|
+ private static final SpecialStorageUtil specialStorageUtil = SpringContextUtil.getBean("specialStorageUtil");
|
|
|
|
|
|
public static String getXmlDataTypeModuleId(Map<String, String> sourceMap) {
|
|
|
- SpecialStorageUtil specialStorageUtil = SpringContextUtil.getBean("specialStorageUtil");
|
|
|
if (MapUtils.isEmpty(sourceMap)
|
|
|
|| MapUtils.isEmpty(xmlDataTypeModuleInfo.get(specialStorageUtil.getHospitalIdThreadLocal().get()))) {
|
|
|
return null;
|
|
@@ -41,11 +41,17 @@ public class ModuleMappingUtil {
|
|
|
}
|
|
|
|
|
|
public static String getHtmlDataTypeModuleId(String recTitle) {
|
|
|
- return htmlDataTypeModuleInfo.get(recTitle);
|
|
|
+ if (MapUtils.isEmpty(htmlDataTypeModuleInfo.get(specialStorageUtil.getHospitalIdThreadLocal().get()))) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+ return htmlDataTypeModuleInfo.get(specialStorageUtil.getHospitalIdThreadLocal().get()).get(recTitle);
|
|
|
}
|
|
|
|
|
|
public static String getStandardModuleId(String modeId) {
|
|
|
- return standardModuleInfo.get(modeId);
|
|
|
+ if (MapUtils.isEmpty(standardModuleInfo.get(specialStorageUtil.getHospitalIdThreadLocal().get()))) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+ return standardModuleInfo.get(specialStorageUtil.getHospitalIdThreadLocal().get()).get(modeId);
|
|
|
}
|
|
|
|
|
|
}
|