Merge remote-tracking branch 'origin/dev_改版主分支-升级融云SDK&AGP8' into dev_改版主分支-升级融云SDK&AGP8

This commit is contained in:
hch 2024-03-26 17:51:47 +08:00
commit e352e5692c
8 changed files with 60 additions and 17 deletions

View File

@ -194,9 +194,12 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode;
-keep public class com.alibaba.android.arouter.facade.**{*;}
-keep class * implements com.alibaba.android.arouter.facade.template.ISyringe{*;}
# If you use the byType method to obtain Service, add the following rules to protect the interface:
# 如果使用了 byType 的方式获取 Service,需添加下面规则,保护接口
-keep interface * implements com.alibaba.android.arouter.facade.template.IProvider
# 如果使用了 单类注入,即不定义接口实现 IProvider,需添加下面规则,保护实现
-keep class * implements com.alibaba.android.arouter.facade.template.IProvider
# If single-type injection is used, that is, no interface is defined to implement IProvider, the following rules need to be added to protect the implementation
# -keep class * implements com.alibaba.android.arouter.facade.template.IProvider

View File

@ -284,12 +284,27 @@ public class AppContext extends CommonAppContext {
if (message.getReceivedStatus().isRead()) {
return false;
}
RongIMClient.getInstance().getUnreadCount(Conversation.ConversationType.PRIVATE, message.getTargetId(), new RongIMClient.ResultCallback<Integer>() {
@Override
public void onSuccess(Integer integer) {
if (integer > 0) {
MessageChatNotifyManager.getInstance().push(AppManager.getInstance().getLastActivity()
, message.getTargetId(),
content.getContent()
);
}
}
@Override
public void onError(RongIMClient.ErrorCode e) {
}
});
}
}
} catch (Exception e) {
e.printStackTrace();
}

View File

@ -293,9 +293,12 @@ rx.internal.util.atomic.LinkedQueueNode* consumerNode;
-keep public class com.alibaba.android.arouter.facade.**{*;}
-keep class * implements com.alibaba.android.arouter.facade.template.ISyringe{*;}
# If you use the byType method to obtain Service, add the following rules to protect the interface:
# 如果使用了 byType 的方式获取 Service需添加下面规则保护接口
-keep interface * implements com.alibaba.android.arouter.facade.template.IProvider
# 如果使用了 单类注入,即不定义接口实现 IProvider需添加下面规则保护实现
-keep class * implements com.alibaba.android.arouter.facade.template.IProvider
# If single-type injection is used, that is, no interface is defined to implement IProvider, the following rules need to be added to protect the implementation
# -keep class * implements com.alibaba.android.arouter.facade.template.IProvider

View File

@ -77,9 +77,9 @@ public class MessageSayHiNotifyDialog extends AbsDialogCenterPopupWindow {
@Override
protected void onDismiss() {
super.onDismiss();
/*if (onDismissListener != null) {
if (onDismissListener != null) {
onDismissListener.onItemClick(userInfoBean.getUser().getId() + "", isSayHi ? 2 : 1);
}*/
}
}
boolean isSayHi = false;
@ -98,7 +98,7 @@ public class MessageSayHiNotifyDialog extends AbsDialogCenterPopupWindow {
sendMsg(userInfoBean.getSayHiMsg());
dismiss();
});
/* avatar = findViewById(R.id.avatar);
avatar = findViewById(R.id.avatar);
anchorName = findViewById(R.id.anchorName);
ImgLoader.display(mContext, userInfoBean.getUser().getAvatar(), avatar);
anchorName.setText(userInfoBean.getUser().getUserNicename());
@ -110,7 +110,7 @@ public class MessageSayHiNotifyDialog extends AbsDialogCenterPopupWindow {
,WordUtil.isNewZh()?"":"years old"
)
);
showTag();*/
showTag();
}
private void showTag() {

View File

@ -8,15 +8,18 @@ import android.text.TextUtils;
import androidx.annotation.NonNull;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.google.gson.Gson;
import com.lzf.easyfloat.EasyFloat;
import com.lzy.okgo.model.Response;
import com.umeng.analytics.MobclickAgent;
import com.yunbao.common.CommonAppContext;
import com.yunbao.common.bean.IMLoginModel;
import com.yunbao.common.event.DataUserInfoEvent;
import com.yunbao.common.http.HttpCallback;
import com.yunbao.common.http.HttpClient;
import com.yunbao.common.http.JsonBean;
import com.yunbao.common.interfaces.OnItemClickListener;
import com.yunbao.common.manager.base.BaseCacheManager;
import com.yunbao.common.manager.imrongcloud.MessageIMManager;
@ -439,6 +442,11 @@ public class IMLoginManager extends BaseCacheManager {
//兼容老模块(之后要把用户维护的类更换掉
SpUtil.getInstance().setStringValue(SpUtil.USER_INFO, new Gson().toJson(userInfo));
}
@Override
public void onError(Response<JsonBean> response) {
super.onError(response);
}
});
}

View File

@ -4,12 +4,16 @@ import android.content.Context;
import android.os.Handler;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.TypeReference;
import com.google.gson.Gson;
import com.lzy.okgo.model.Response;
import com.yunbao.common.bean.IMLoginModel;
import com.yunbao.common.http.HttpCallback;
import com.yunbao.common.http.HttpClient;
import com.yunbao.common.http.JsonBean;
import com.yunbao.common.manager.base.BaseCacheManager;
import com.yunbao.common.utils.StringUtil;
import java.util.HashMap;
import java.util.Map;
@ -36,9 +40,13 @@ public class InstructorRemarkManager extends BaseCacheManager {
*/
public Map<String, String> getInstructorRemark() {
if (null == instructorRemarkMap) {
instructorRemarkMap = JSON.parseObject(getString(KEY_INSTRUCTOR_REMARK), new TypeReference<Map<String, String>>() {
String string = getString(KEY_INSTRUCTOR_REMARK);
if (!StringUtil.isEmpty(string)) {
instructorRemarkMap = JSON.parseObject(string, new TypeReference<Map<String, String>>() {
});
}
}
if (instructorRemarkMap == null) {
instructorRemarkMap = new HashMap<>();
}
@ -103,8 +111,8 @@ public class InstructorRemarkManager extends BaseCacheManager {
public void run() {
IMLoginModel userInfo = IMLoginManager.get(context).getUserInfo();
HttpClient.getInstance().get("User.getInstructorRemark", "getInstructorRemark")
.params("uid", userInfo.getId(),true)
.params("token", userInfo.getToken(),true)
.params("uid", userInfo.getId(), true)
.params("token", userInfo.getToken(), true)
.execute(new HttpCallback() {
@Override
public void onSuccess(int code, String msg, String[] info) {
@ -116,6 +124,11 @@ public class InstructorRemarkManager extends BaseCacheManager {
}
}
@Override
public void onError(Response<JsonBean> response) {
super.onError(response);
}
});

View File

@ -880,8 +880,9 @@ public class EditProfileActivity extends AbsActivity {
userInfoBean = data;
((TextView) findViewById(R.id.occupation)).setText(data.getInfo().getCareer());
String height = data.getInfo().getHeight();
if("0".equals(height)||StringUtil.isEmpty(height)){
height="170";
if ("0".equals(height) || StringUtil.isEmpty(height)) {
// height="170";
((TextView) findViewById(R.id.height)).setVisibility(View.GONE);
}
((TextView) findViewById(R.id.height)).setText(height + "cm");
List<String> tags = WordUtil.isNewZh() ? data.getInfo().getCn_label() : data.getInfo().getEn_label();

View File

@ -332,7 +332,7 @@ public class PDLiveConversationActivity extends AbsActivity implements View.OnCl
tags.add(userInfoBean.getInfo().getCareer());
}
if (!StringUtil.isEmpty(userInfoBean.getInfo().getHeight()) && !userInfoBean.getInfo().getHeight().equals("0")) {
tags.add(userInfoBean.getInfo().getHeight());
tags.add(userInfoBean.getInfo().getHeight()+"cm");
}
List<String> t;
if (WordUtil.isNewZh()) {