weizhengliang před 3 roky
rodič
revize
0e7ecc8820

+ 4 - 4
nursehome/src/main/java/com/wdkl/ncs/android/component/nursehome/activity/NurseHomeActivity.kt

@@ -643,11 +643,11 @@ class NurseHomeActivity  : BaseActivity<NurseHomeActivityPresenter, ActivityNurs
 
     inner class TimeReceiver: BroadcastReceiver() {
         override fun onReceive(context: Context, intent: Intent) {
-            if (intent.action == Intent.ACTION_TIME_TICK
+            /*if (intent.action == Intent.ACTION_TIME_TICK
                     || intent.action == Intent.ACTION_TIME_CHANGED
                     || intent.action == Intent.ACTION_TIMEZONE_CHANGED) {
 
-                /*updateTime(false)
+                updateTime(false)
                 updateNetState()
                 updateTcpState()
 
@@ -661,8 +661,8 @@ class NurseHomeActivity  : BaseActivity<NurseHomeActivityPresenter, ActivityNurs
                 //当前不在通话中且laterRestart=true则重启app
                 if (Constants.laterRestart && !DeviceChannel.calling) {
                     AppUpdateHelper.restartApp(activity)
-                }*/
-            } else if (intent.action == Constants.HOOK_ON) {
+                }
+            } else */if (intent.action == Constants.HOOK_ON) {
                 Log.e(TAG,"手柄放下 ")
                 Constants.hookOn = true
                 VoiceManagerUtil.switchAudioMode(activity, true)

+ 2 - 0
nursehome/src/main/java/com/wdkl/ncs/android/component/nursehome/util/XCrashUtils.java

@@ -70,6 +70,8 @@ public class XCrashUtils {
             //非debug版本上传crash日志
             if (!BuildConfig.DEBUG) {
                 uploadCrashLog(logPath);
+            } else {
+                AppUtils.relaunchApp(true);
             }
 
             //restartApp();