From 9e42f79ec214b297bc25a93404a8ce12ece6485f Mon Sep 17 00:00:00 2001
From: xiaoyong931011 <15274802129@163.com>
Date: Thu, 17 Aug 2023 15:22:04 +0800
Subject: [PATCH] 后台修改

---
 src/main/java/cc/mrbird/febs/FebsShiroApplication.java |   43 +++++++++++++++++++++++++++----------------
 1 files changed, 27 insertions(+), 16 deletions(-)

diff --git a/src/main/java/cc/mrbird/febs/FebsShiroApplication.java b/src/main/java/cc/mrbird/febs/FebsShiroApplication.java
index 2363a2d..1cacc07 100644
--- a/src/main/java/cc/mrbird/febs/FebsShiroApplication.java
+++ b/src/main/java/cc/mrbird/febs/FebsShiroApplication.java
@@ -5,6 +5,7 @@
 import cc.mrbird.febs.dapp.entity.DataDictionaryCustom;
 import cc.mrbird.febs.dapp.enumerate.DataDictionaryEnum;
 import cc.mrbird.febs.dapp.mapper.DataDictionaryCustomMapper;
+import cc.mrbird.febs.dapp.service.DappSystemService;
 import cn.hutool.core.util.StrUtil;
 import org.mybatis.spring.annotation.MapperScan;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -30,6 +31,8 @@
 
     @Autowired
     private DataDictionaryCustomMapper dataDictionaryCustomMapper;
+    @Autowired
+    private DappSystemService dappSystemService;
 
     @Autowired
     private SystemConstants systemConstants;
@@ -40,21 +43,29 @@
                 .run(args);
     }
 
-    @PostConstruct
-    public void systemConstantsInit() {
-        DataDictionaryCustom dataDictionaryCustom = dataDictionaryCustomMapper.selectDicDataByTypeAndCode(DataDictionaryEnum.FEE_ADDRESS_KEY.getType(), DataDictionaryEnum.FEE_ADDRESS_KEY.getCode());
-        String key = dataDictionaryCustom.getCode();
-        key = StrUtil.toCamelCase(key);
-        String value = dataDictionaryCustom.getValue();
-        try {
-            Field field = systemConstants.getClass().getDeclaredField(key);
-            field.set(systemConstants, value);
-            AppContants.FEE_ADDRESS_KEY.put("feeAddressKey",systemConstants.getFeeAddressKey());
-            dataDictionaryCustom.setValue("isReady");
-            dataDictionaryCustomMapper.updateById(dataDictionaryCustom);
-        } catch (Exception e) {
-            e.printStackTrace();
-        }
-    }
+//    @PostConstruct
+//    public void systemConstantsInit() {
+//        DataDictionaryCustom dataDictionaryCustom = dataDictionaryCustomMapper.selectDicDataByTypeAndCode(
+//                DataDictionaryEnum.FEE_ADDRESS_KEY.getType(),
+//                DataDictionaryEnum.FEE_ADDRESS_KEY.getCode());
+//        String key = dataDictionaryCustom.getCode();
+//        key = StrUtil.toCamelCase(key);
+//        String value = dataDictionaryCustom.getValue();
+//        try {
+//            Field field = systemConstants.getClass().getDeclaredField(key);
+//            field.set(systemConstants, value);
+//            AppContants.FEE_ADDRESS_KEY.put("feeAddressKey",systemConstants.getFeeAddressKey());
+//            dataDictionaryCustom.setValue("isReady");
+//            dataDictionaryCustomMapper.updateById(dataDictionaryCustom);
+//        } catch (Exception e) {
+//            e.printStackTrace();
+//        }
+//    }
+
+
+//    @PostConstruct
+//    public void systemDicInit() {
+//        dappSystemService.selectAndInsertDics();
+//    }
 
 }

--
Gitblit v1.9.1