Browse Source

Merge remote-tracking branch 'origin/ScrmStores' into ScrmStores

吴树波 4 tuần trước cách đây
mục cha
commit
6e841d2d8b

+ 2 - 2
fs-admin/src/main/java/com/fs/api/controller/IndexStatisticsController.java

@@ -70,7 +70,7 @@ public class IndexStatisticsController {
         }
         SysConfig config = sysConfigService.selectConfigByConfigKey("medicalMall.func.switch");
         MedicalMallConfig medicalMallConfig = JSON.parseObject(config.getConfigValue(), MedicalMallConfig.class);
-        if(medicalMallConfig.isStatics()|| (param.getCompanyId() == null && param.getDeptId() == null) || (param.getCompanyId() == null && param.getDeptId() == 1)){
+        if(!medicalMallConfig.isStatics()|| (param.getCompanyId() == null && param.getDeptId() == null) || (param.getCompanyId() == null && param.getDeptId() == 1)){
             analysisPreviewDTO = redisCache.getCacheObject(String.format("%s:%d:%d",DATA_OVERVIEW_DEALER_ANALYSISPREVIEW,type,userType));
         }else if(param.getCompanyId() != null){
             analysisPreviewDTO = redisCache.getCacheObject(String.format("%s:%d:%d:%d",DATA_OVERVIEW_DEALER_ANALYSISPREVIEW,type,userType,param.getCompanyId()));
@@ -146,7 +146,7 @@ public class IndexStatisticsController {
         ConsumptionBalanceDataDTO consumptionBalanceDataDTO = new ConsumptionBalanceDataDTO();
         SysConfig config = sysConfigService.selectConfigByConfigKey("medicalMall.func.switch");
         MedicalMallConfig medicalMallConfig = JSON.parseObject(config.getConfigValue(), MedicalMallConfig.class);
-        if(medicalMallConfig.isStatics() || (param.getCompanyId() == null && param.getDeptId() == null) || (param.getCompanyId() == null && param.getDeptId() == 1)) {
+        if(!medicalMallConfig.isStatics() || (param.getCompanyId() == null && param.getDeptId() == null) || (param.getCompanyId() == null && param.getDeptId() == 1)) {
             consumptionBalanceDataDTO = redisCache.getCacheObject(StatisticsRedisConstant.DATA_OVERVIEW_DEALER_BALANCE);
         }else if(param.getCompanyId() != null){
             consumptionBalanceDataDTO = redisCache.getCacheObject(String.format("%s:%d",DATA_OVERVIEW_DEALER_BALANCE,param.getCompanyId()));