From b02cbd7831e7b95b2c1785711cce6b7afe593175 Mon Sep 17 00:00:00 2001 From: zlzw <583819556@qq.com> Date: Sat, 3 Jun 2023 14:13:29 +0800 Subject: [PATCH] =?UTF-8?q?Home.getConfig=E6=8E=A5=E5=8F=A3=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E5=AF=B91000=E9=94=99=E8=AF=AF=E7=A0=81=E7=9A=84?= =?UTF-8?q?=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../yunbao/common/http/CommonHttpUtil.java | 22 ++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/common/src/main/java/com/yunbao/common/http/CommonHttpUtil.java b/common/src/main/java/com/yunbao/common/http/CommonHttpUtil.java index c9d01ec8c..88f66388d 100644 --- a/common/src/main/java/com/yunbao/common/http/CommonHttpUtil.java +++ b/common/src/main/java/com/yunbao/common/http/CommonHttpUtil.java @@ -1,5 +1,6 @@ package com.yunbao.common.http; +import android.app.Dialog; import android.content.Context; import android.os.Build; import android.util.Log; @@ -21,6 +22,8 @@ import com.yunbao.common.manager.APKManager; import com.yunbao.common.manager.IMLoginManager; import com.yunbao.common.manager.LiveClassManager; import com.yunbao.common.manager.NewLevelManager; +import com.yunbao.common.utils.AppManager; +import com.yunbao.common.utils.DialogUitl; import com.yunbao.common.utils.L; import com.yunbao.common.utils.MD5Util; import com.yunbao.common.utils.SpUtil; @@ -224,7 +227,8 @@ public class CommonHttpUtil { } if (obj.containsKey("clarity")) { IMLoginManager.get(context).setClarity(obj.getString("clarity")); - } if (obj.containsKey("defaultBubbleUrl")) { + } + if (obj.containsKey("defaultBubbleUrl")) { IMLoginManager.get(context).setDefaultBubbleUrl(obj.getString("defaultBubbleUrl")); } } catch (Exception e) { @@ -232,6 +236,22 @@ public class CommonHttpUtil { String error = "info[0]:" + info[0] + "\n\n\n" + "Exception:" + e.getClass() + "---message--->" + e.getMessage(); ErrorActivity.forward("GetConfig接口返回数据异常", error); } + } else if (code == 1000) { + new DialogUitl + .Builder(context) + .setContent(msg) + .setCancelable(false) + .setClickCallback3(new DialogUitl.SimpleCallback3() { + @Override + public void onConfirmClick(Dialog dialog) { + AppManager.getInstance().AppExit(); + } + + @Override + public void onCancel() { + AppManager.getInstance().AppExit(); + } + }).build().show(); } }