Browse Source

版本号

he2802 3 năm trước cách đây
mục cha
commit
f1c8d34e7b

+ 8 - 2
zhongzheng-api/src/main/java/com/zhongzheng/controller/cmmon/CommonController.java

@@ -20,6 +20,7 @@ import com.zhongzheng.modules.exam.vo.ExamActivityVo;
 import com.zhongzheng.modules.goods.vo.GoodsUserVo;
 import com.zhongzheng.modules.goods.vo.GoodsVo;
 import com.zhongzheng.modules.order.domain.Printer;
+import com.zhongzheng.modules.system.service.ISysConfigService;
 import com.zhongzheng.modules.wx.bo.WxServerBody;
 import com.zhongzheng.modules.wx.domain.*;
 import io.swagger.annotations.Api;
@@ -55,6 +56,9 @@ public class CommonController extends BaseController {
     private final IExamActivityService iExamActivityService;
 
 
+    private final ISysConfigService configService;
+
+
     /**
      * 查询课程列表
      */
@@ -120,8 +124,10 @@ public class CommonController extends BaseController {
         Map<String,Object> map = new HashMap<>();
         map.put("hide",false);
         if(Validator.isNotEmpty(bo.getVersion())){
-            if(bo.getVersion().equals("1.3.12")){
-                map.put("hide",false);
+            String hideVersion = configService.selectConfigByKey("version.hide");
+            System.out.println(hideVersion);
+            if(bo.getVersion().equals(hideVersion)){
+                map.put("hide",true);
             }
         }
         return AjaxResult.success(map);