KKSU
2024-05-11 9af9ab4d7a638687024437a9e1d1e742fe1b4bb2
src/main/java/cc/mrbird/febs/FebsShiroApplication.java
@@ -27,6 +27,7 @@
@SpringBootApplication
@EnableTransactionManagement
@MapperScan("cc.mrbird.febs.*.mapper")
@MapperScan("cc.mrbird.febs.dapp.*.mapper")
public class FebsShiroApplication {
    @Autowired
@@ -43,24 +44,24 @@
                .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