fix bugs.3
This commit is contained in:
@@ -23,7 +23,7 @@ object WebUrlConstants {
|
||||
val WEB_PROP_MALL_URL = BASE_URL + "/web/index.html#/pages/prop/propMall?id=%s"
|
||||
|
||||
/**公会*/
|
||||
val WEB_GUILD_URL = BASE_URL + "/web/index.html#/pages/union/index?id=%s"
|
||||
val WEB_GUILD_URL = BASE_URL + "/web/index.html#/pages/union/index?id=%s&guild_id=%s"
|
||||
|
||||
/**等级*/
|
||||
val WEB_GRADE_URL = BASE_URL + "/web/index.html#/pages/other/grade?id=%s"
|
||||
|
||||
@@ -50,7 +50,10 @@ public class UserInfo extends BaseEvent implements Serializable {
|
||||
private String chat_bubble;//聊天气泡
|
||||
private String charm;//魅力值
|
||||
private String room_id;
|
||||
private String guild = "";//公会名称
|
||||
private String guild_name = "";//公会名称
|
||||
private int guild_id = 0;//公会id
|
||||
private String me_guild_name = "";//公会名称
|
||||
private int me_guild_id = 0;//公会id
|
||||
private String is_mute;//禁言状态 0否 1是
|
||||
private String is_mute_pit;//禁麦状态 0否 1是
|
||||
private String is_manager;//是否是管理员 0否 1是
|
||||
|
||||
@@ -26,7 +26,6 @@ public class GsonUtils {
|
||||
GSON = new GsonBuilder()
|
||||
.serializeNulls() // 序列化 null 值
|
||||
.registerTypeAdapterFactory(new BaseModelTypeAdapterFactory())
|
||||
.registerTypeAdapter(String.class,new NullToEmptyStringAdapter())
|
||||
.create();
|
||||
}
|
||||
return GSON;
|
||||
|
||||
@@ -3947,20 +3947,6 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
ConstraintLayout.LayoutParams.MATCH_PARENT,
|
||||
ConstraintLayout.LayoutParams.WRAP_CONTENT
|
||||
)
|
||||
// params.dimensionRatio = "W,1:0.85"
|
||||
// when (mRoomInfoResp?.room_info?.type_id) {
|
||||
// "1", "3", "4", "8" ->
|
||||
// if (mRoomInfoResp?.room_info?.label_id == "1")
|
||||
// params.dimensionRatio = "W,1:0.88"
|
||||
// else
|
||||
// params.dimensionRatio = "W,1:0.82"
|
||||
//
|
||||
// "2" -> params.dimensionRatio = "W,1:0.85"
|
||||
// "6" -> params.dimensionRatio = "W,1:1"
|
||||
// "7" -> params.dimensionRatio = "W,1:0.88"
|
||||
// "9" -> params.dimensionRatio = "W,1:0.85"
|
||||
// "10" -> params.dimensionRatio = "W,1:0.88"
|
||||
// }
|
||||
vpRoomPager.layoutParams = params
|
||||
// if (mRoomInfoResp?.room_info?.type_id == "1" || mRoomInfoResp?.room_info?.type_id == "3" || mRoomInfoResp?.room_info?.type_id == "4"
|
||||
// || mRoomInfoResp?.room_info?.type_id == "8"
|
||||
|
||||
@@ -285,7 +285,7 @@ class RoomMentorShipFragment(var mRoomInfo: RoomInfoResp?) :
|
||||
setIvForMai(0)
|
||||
}
|
||||
|
||||
if (mRoomInfo?.user_info?.pit_number == 9 && !mSignPitBean?.user_id.equals("0")) {
|
||||
if (viewList[0].pitBean.user_id.equals(mRoomInfo?.user_info?.user_id.toString())){
|
||||
mBinding.tvTimeLeft.visibility = View.VISIBLE
|
||||
} else {
|
||||
mBinding.tvTimeLeft.visibility = View.GONE
|
||||
|
||||
@@ -229,11 +229,11 @@ public class UserHomepageFragment extends BaseMvpFragment<UserHomepagePresenter,
|
||||
mBinding.headerInfo.tvGsSx.setOnClickListener(this::onClick);
|
||||
mBinding.headerInfo.ivRightAvatar.setOnClickListener(this::onClick);
|
||||
refreshView();
|
||||
if (userInfo.getGuild() == null || userInfo.getGuild().isEmpty()) {
|
||||
if (userInfo.getGuild_name() == null || userInfo.getGuild_name().isEmpty()) {
|
||||
mBinding.headerInfo.ctlGuild.setVisibility(View.GONE);
|
||||
} else {
|
||||
mBinding.headerInfo.ctlGuild.setVisibility(View.VISIBLE);
|
||||
mBinding.headerInfo.tvGH.setText(userInfo.getGuild());
|
||||
mBinding.headerInfo.tvGH.setText(userInfo.getGuild_name());
|
||||
}
|
||||
|
||||
showCp();
|
||||
|
||||
@@ -192,7 +192,7 @@ public class VocalRangeFragment extends BaseMvpFragment<MePresenter, FragmentVoc
|
||||
startActivity(intent);
|
||||
} else if (id==R.id.ll_me_guild){
|
||||
Intent intent=new Intent(getContext(), WebViewActivity.class);
|
||||
intent.putExtra("url", String.format(WebUrlConstants.INSTANCE.getWEB_GUILD_URL(),SpUtil.getToken()));
|
||||
intent.putExtra("url", String.format(WebUrlConstants.INSTANCE.getWEB_GUILD_URL(),SpUtil.getToken(),""));
|
||||
intent.putExtra("title", "公会");
|
||||
startActivity(intent);
|
||||
}else if (id==R.id.ll_my_shopping){
|
||||
|
||||
@@ -508,14 +508,14 @@ public class RoomUserInfoFragment extends BaseMvpDialogFragment<RoomUserPresente
|
||||
if (userInfo != null) {
|
||||
mBinding.tvGh.setVisibility(VISIBLE);
|
||||
mBinding.tvJoinGuild.setVisibility(GONE);
|
||||
if (userInfo.getGuild().isEmpty()) {
|
||||
if (userInfo.getGuild_name() == null ||userInfo.getGuild_name().isEmpty()) {
|
||||
mBinding.tvGh.setText("所属公会:无");
|
||||
} else {
|
||||
if (userInfo.getUser_id() != SpUtil.getUserId() && !userInfo.getGuild().equals(SpUtil.getUserInfo().getGuild())) {
|
||||
if (userInfo.getUser_id() != SpUtil.getUserId() || (userInfo.getMe_guild_name() != null && !userInfo.getMe_guild_name().isEmpty())) {
|
||||
mBinding.tvJoinGuild.setVisibility(VISIBLE);
|
||||
}
|
||||
|
||||
mBinding.tvGh.setText("所属公会:" + userInfo.getGuild());
|
||||
mBinding.tvGh.setText("所属公会:" + userInfo.getGuild_name());
|
||||
}
|
||||
} else {
|
||||
mBinding.tvGh.setVisibility(GONE);
|
||||
@@ -526,7 +526,7 @@ public class RoomUserInfoFragment extends BaseMvpDialogFragment<RoomUserPresente
|
||||
mBinding.tvJoinGuild.setOnClickListener(v -> {
|
||||
//跳转加入公会
|
||||
Intent intent = new Intent(getContext(), WebViewActivity.class);
|
||||
intent.putExtra("url", String.format(WebUrlConstants.INSTANCE.getWEB_GUILD_URL(), SpUtil.getToken()));
|
||||
intent.putExtra("url", String.format(WebUrlConstants.INSTANCE.getWEB_GUILD_URL(), SpUtil.getToken(), userInfo.getGuild_id()));
|
||||
intent.putExtra("title", "公会");
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
android:id="@+id/tv_time"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="倒计时 00:00"
|
||||
android:text="倒计时 00:00:00"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_12"
|
||||
android:visibility="gone" />
|
||||
|
||||
@@ -20,10 +20,11 @@
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/cl_bj"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:background="@drawable/bg_r8_tm"
|
||||
android:layout_marginTop="@dimen/dp_25"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintDimensionRatio="1.4:1.5"
|
||||
app:layout_constraintDimensionRatio="1:1"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
@@ -314,10 +315,8 @@
|
||||
android:id="@+id/mu_zc"
|
||||
android:layout_width="@dimen/dp_62"
|
||||
android:layout_height="@dimen/dp_88"
|
||||
android:layout_marginTop="-25dp"
|
||||
android:layout_marginEnd="@dimen/dp_5"
|
||||
android:foreground="?android:attr/selectableItemBackground"
|
||||
android:translationZ="30dp"
|
||||
app:layout_constraintDimensionRatio="1:1"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/cl_bj"
|
||||
|
||||
Reference in New Issue
Block a user