Browse Source

1.判断机型初始化csdkmanager

20241218TB223FC(测试jar包)
wangwanlei 9 months ago
parent
commit
30f954b84b
1 changed files with 5 additions and 3 deletions
  1. 5
    3
      app/src/main/java/com/xhly/manageapp/ManageApplication.kt

+ 5
- 3
app/src/main/java/com/xhly/manageapp/ManageApplication.kt View File

624
         val exitControlFlag = currentSpUtils.getParam(Const.EXIT_CONTROL, false) as Boolean
624
         val exitControlFlag = currentSpUtils.getParam(Const.EXIT_CONTROL, false) as Boolean
625
         Toaster.init(this)
625
         Toaster.init(this)
626
         DialogX.init(this)
626
         DialogX.init(this)
627
-        csdkManager = CSDKManager(this)
627
+        if (ModelNameUtils.IS_LianxX505f()){
628
+            csdkManager = CSDKManager(this)
629
+            //允许运行时权限
630
+            setRuntimePermissions(true)
631
+        }
628
         //如果解除管控为真,则不在执行以下代码
632
         //如果解除管控为真,则不在执行以下代码
629
         try {
633
         try {
630
             val userBean = spUtils.getFromJson(
634
             val userBean = spUtils.getFromJson(
641
         }catch (e:Exception){
645
         }catch (e:Exception){
642
 
646
 
643
         }
647
         }
644
-        //允许运行时权限
645
-        setRuntimePermissions(true)
646
         if (!exitControlFlag){
648
         if (!exitControlFlag){
647
              StrategyUtils.initControlStrategy()
649
              StrategyUtils.initControlStrategy()
648
         }
650
         }

Loading…
Cancel
Save