1:修改师父标签
2:修改签约房的清除魅力我更新魅力
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 2.4 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 3.2 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 6.0 KiB After Width: | Height: | Size: 6.1 KiB |
@@ -2161,7 +2161,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
|||||||
val typeId = mRoomInfoResp?.room_info?.type_id
|
val typeId = mRoomInfoResp?.room_info?.type_id
|
||||||
if ("2" == typeId) {
|
if ("2" == typeId) {
|
||||||
roomFragment!!.handleRoomMessage(messageEvent)
|
roomFragment!!.handleRoomMessage(messageEvent)
|
||||||
} else if ("1" == typeId || "4" == typeId || "3" == typeId || "8" == typeId || "9" == typeId) {
|
} else if ("1" == typeId || "4" == typeId || "3" == typeId || "8" == typeId || "9" == typeId || "10" == typeId) {
|
||||||
val labelId = mRoomInfoResp!!.room_info.label_id
|
val labelId = mRoomInfoResp!!.room_info.label_id
|
||||||
if ("2" == labelId) {
|
if ("2" == labelId) {
|
||||||
roomFragment!!.handleRoomMessage(messageEvent)
|
roomFragment!!.handleRoomMessage(messageEvent)
|
||||||
|
|||||||
@@ -533,6 +533,7 @@ public class RoomFragment extends BaseMvpFragment<RoomPresenter, FragmentRoomBin
|
|||||||
((RoomActivity) getActivity()).upRoomInfo(mRoomInfoResp);
|
((RoomActivity) getActivity()).upRoomInfo(mRoomInfoResp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//误导
|
//误导
|
||||||
public void updateSeatViewExchangedWithPitArray(RoomInfoResp roomInfoResp) {
|
public void updateSeatViewExchangedWithPitArray(RoomInfoResp roomInfoResp) {
|
||||||
mRoomInfoResp = roomInfoResp;
|
mRoomInfoResp = roomInfoResp;
|
||||||
@@ -540,6 +541,7 @@ public class RoomFragment extends BaseMvpFragment<RoomPresenter, FragmentRoomBin
|
|||||||
loadSubFragment(qxRoomSeatViewType);
|
loadSubFragment(qxRoomSeatViewType);
|
||||||
updateChildFragmentViews();
|
updateChildFragmentViews();
|
||||||
}
|
}
|
||||||
|
|
||||||
//1003 1004
|
//1003 1004
|
||||||
public void upRoomInfoData(RoomInfoResp roomInfoResp) {
|
public void upRoomInfoData(RoomInfoResp roomInfoResp) {
|
||||||
this.mRoomInfoResp = roomInfoResp;
|
this.mRoomInfoResp = roomInfoResp;
|
||||||
@@ -910,11 +912,12 @@ public class RoomFragment extends BaseMvpFragment<RoomPresenter, FragmentRoomBin
|
|||||||
if (roomJukeboxFragment != null) {
|
if (roomJukeboxFragment != null) {
|
||||||
handleJukeboxEvent(messageEvent);
|
handleJukeboxEvent(messageEvent);
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
case SIGNCONTRACT:
|
case SIGNCONTRACT:
|
||||||
if (mentorShipFragment != null) {
|
if (mentorShipFragment != null) {
|
||||||
handleMentorshipEvent(messageEvent);
|
handleMentorshipEvent(messageEvent);
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
case CABIN:
|
case CABIN:
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@@ -936,7 +939,13 @@ public class RoomFragment extends BaseMvpFragment<RoomPresenter, FragmentRoomBin
|
|||||||
mentorShipFragment.event1035(messageEvent);
|
mentorShipFragment.event1035(messageEvent);
|
||||||
break;
|
break;
|
||||||
case 1059:
|
case 1059:
|
||||||
mentorShipFragment.event1039(messageEvent);
|
mentorShipFragment.event1059(messageEvent);
|
||||||
|
break;
|
||||||
|
case 1005:
|
||||||
|
mentorShipFragment.event1005(messageEvent);
|
||||||
|
break;
|
||||||
|
case 1021:
|
||||||
|
mentorShipFragment.event1021(messageEvent);
|
||||||
break;
|
break;
|
||||||
case EMMessageInfo.QXRoomMessageTypeSignStartText:
|
case EMMessageInfo.QXRoomMessageTypeSignStartText:
|
||||||
mentorShipFragment.event1090(messageEvent);
|
mentorShipFragment.event1090(messageEvent);
|
||||||
|
|||||||
@@ -21,6 +21,7 @@ import com.xscm.modulemain.utils.CountdownTimer
|
|||||||
import com.xscm.modulemain.widget.RoomMentorShipWheatView
|
import com.xscm.modulemain.widget.RoomMentorShipWheatView
|
||||||
import com.xscm.moduleutil.base.BaseMvpFragment
|
import com.xscm.moduleutil.base.BaseMvpFragment
|
||||||
import com.xscm.moduleutil.bean.RoomMessageEvent
|
import com.xscm.moduleutil.bean.RoomMessageEvent
|
||||||
|
import com.xscm.moduleutil.bean.UserInfo
|
||||||
import com.xscm.moduleutil.bean.WalletBean
|
import com.xscm.moduleutil.bean.WalletBean
|
||||||
import com.xscm.moduleutil.bean.room.RoomInfoResp
|
import com.xscm.moduleutil.bean.room.RoomInfoResp
|
||||||
import com.xscm.moduleutil.bean.room.RoomPitBean
|
import com.xscm.moduleutil.bean.room.RoomPitBean
|
||||||
@@ -442,8 +443,15 @@ class RoomMentorShipFragment(var mRoomInfo: RoomInfoResp?) :
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun event1039(messageEvent: RoomMessageEvent) {
|
// TODO: 清除个人魅力
|
||||||
|
fun event1059(messageEvent: RoomMessageEvent) {
|
||||||
|
val userId: String? = messageEvent.text.user_id
|
||||||
|
if (mBinding.rmsw1.getUserId() != null && mBinding.rmsw1.getUserId().equals(userId)) {
|
||||||
|
mBinding.rmsw1.setCharm("0")
|
||||||
|
}
|
||||||
|
if (mBinding.rmswMidd.getUserId() != null && mBinding.rmswMidd.getUserId().equals(userId)) {
|
||||||
|
mBinding.rmswMidd.setCharm("0")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -561,5 +569,43 @@ class RoomMentorShipFragment(var mRoomInfo: RoomInfoResp?) :
|
|||||||
scope.cancel()
|
scope.cancel()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fun event1005(message: RoomMessageEvent) {
|
||||||
|
|
||||||
|
|
||||||
|
// 检查是否有多个用户信息
|
||||||
|
if (message.text.toUserInfos != null && !message.text.toUserInfos.isEmpty()
|
||||||
|
) {
|
||||||
|
// 处理多个用户的情况
|
||||||
|
for (userOnlineStatusBean in message.text.toUserInfos) {
|
||||||
|
updateCharmForUser(userOnlineStatusBean)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
// 处理单个用户的情况
|
||||||
|
val toUserInfo: UserInfo? = message.text.toUserInfo
|
||||||
|
if (toUserInfo != null) {
|
||||||
|
updateCharmForUser(toUserInfo)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private fun updateCharmForUser(userInfo: UserInfo) {
|
||||||
|
val userId = userInfo.user_id.toString()
|
||||||
|
val charm = userInfo.charm
|
||||||
|
if (mBinding.rmsw1.getUserId() != null && mBinding.rmsw1.getUserId().equals(userId)) {
|
||||||
|
mBinding.rmsw1.setCharm(charm)
|
||||||
|
}
|
||||||
|
if(mBinding.rmswMidd.userId!=null && mBinding.rmswMidd.userId.equals(userId)){
|
||||||
|
mBinding.rmswMidd.setCharm(charm)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: 清除房间的魅力,一键全清
|
||||||
|
fun event1021(messageEvent: RoomMessageEvent) {
|
||||||
|
if (mBinding.rmsw1.userId.isNotEmpty()) {
|
||||||
|
mBinding.rmsw1.setCharm("0")
|
||||||
|
}
|
||||||
|
if (mBinding.rmswMidd.userId.isNotEmpty()) {
|
||||||
|
mBinding.rmswMidd.setCharm("0")
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -6,6 +6,7 @@ import android.text.Spannable
|
|||||||
import android.text.SpannableString
|
import android.text.SpannableString
|
||||||
import android.text.style.ForegroundColorSpan
|
import android.text.style.ForegroundColorSpan
|
||||||
import android.view.View
|
import android.view.View
|
||||||
|
import android.widget.TextView
|
||||||
import com.blankj.utilcode.util.ActivityUtils
|
import com.blankj.utilcode.util.ActivityUtils
|
||||||
import com.blankj.utilcode.util.ToastUtils
|
import com.blankj.utilcode.util.ToastUtils
|
||||||
import com.tencent.imsdk.v2.V2TIMConversation
|
import com.tencent.imsdk.v2.V2TIMConversation
|
||||||
@@ -26,6 +27,7 @@ import com.xscm.moduleutil.http.BaseObserver
|
|||||||
import com.xscm.moduleutil.http.RetrofitClient
|
import com.xscm.moduleutil.http.RetrofitClient
|
||||||
import com.xscm.moduleutil.widget.CommonEmptyView
|
import com.xscm.moduleutil.widget.CommonEmptyView
|
||||||
import io.reactivex.disposables.Disposable
|
import io.reactivex.disposables.Disposable
|
||||||
|
import kotlin.math.ceil
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Author qx
|
* @Author qx
|
||||||
@@ -156,14 +158,33 @@ class MyFamilyFragment(var data: MyFamilyBean) : BaseFragment<FragmentMyFamilyBi
|
|||||||
commonEmptyView.setTextColor(getResources().getColor(com.xscm.moduleutil.R.color.color_FFBDBDBC))
|
commonEmptyView.setTextColor(getResources().getColor(com.xscm.moduleutil.R.color.color_FFBDBDBC))
|
||||||
adapter?.bindToRecyclerView(mBinding.recyclerView)
|
adapter?.bindToRecyclerView(mBinding.recyclerView)
|
||||||
adapter?.setEmptyView(commonEmptyView)
|
adapter?.setEmptyView(commonEmptyView)
|
||||||
adapter?.setOnItemChildClickListener { adapter, view, position ->
|
adapter?.setOnItemClickListener(object : MyFamilyAdapter.OnItemClickListener {
|
||||||
if (view.id == R.id.tv_renew) {
|
//点击头像展示用户主页
|
||||||
|
override fun onItemClick(position: Int, item: MyFamilyBean.GroupMembersListsBean) {
|
||||||
val item = dataList[position]
|
val item = dataList[position]
|
||||||
|
val intent = Intent(activity, UserHomepageActivity::class.java)
|
||||||
|
intent.putExtra("userId", item.user_id.toString())
|
||||||
|
startActivity(intent)
|
||||||
|
}
|
||||||
|
// 检查点击的是否是续租按钮
|
||||||
|
|
||||||
|
override fun onRenewClick(
|
||||||
|
position: Int,
|
||||||
|
item: MyFamilyBean.GroupMembersListsBean
|
||||||
|
) {
|
||||||
|
//
|
||||||
|
|
||||||
if (item.free_renewal > 0) {
|
if (item.free_renewal > 0) {
|
||||||
queren1(
|
queren1(
|
||||||
1,
|
1,
|
||||||
onMessage(1, item.nickname, item.free_renewal, item.free_re_sign_day, null, null),
|
onMessage(
|
||||||
|
1,
|
||||||
|
item.nickname,
|
||||||
|
item.free_renewal,
|
||||||
|
item.free_re_sign_day,
|
||||||
|
null,
|
||||||
|
null
|
||||||
|
),
|
||||||
item.user_id.toString()
|
item.user_id.toString()
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
@@ -180,14 +201,8 @@ class MyFamilyFragment(var data: MyFamilyBean) : BaseFragment<FragmentMyFamilyBi
|
|||||||
item.user_id.toString()
|
item.user_id.toString()
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
} else if (view.id == R.id.iv_head) {
|
|
||||||
val item = dataList[position]
|
|
||||||
val intent = Intent(activity, UserHomepageActivity::class.java)
|
|
||||||
intent.putExtra("userId", item.user_id.toString())
|
|
||||||
startActivity(intent)
|
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun onMessage(
|
private fun onMessage(
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import android.graphics.Color
|
|||||||
import android.view.View
|
import android.view.View
|
||||||
import android.widget.ImageView
|
import android.widget.ImageView
|
||||||
import android.widget.LinearLayout
|
import android.widget.LinearLayout
|
||||||
|
import android.widget.TextView
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
import com.chad.library.adapter.base.BaseQuickAdapter
|
import com.chad.library.adapter.base.BaseQuickAdapter
|
||||||
@@ -31,6 +32,7 @@ class MyFamilyAdapter(
|
|||||||
// 定义点击事件回调接口
|
// 定义点击事件回调接口
|
||||||
interface OnItemClickListener {
|
interface OnItemClickListener {
|
||||||
fun onItemClick(position: Int, item: MyFamilyBean.GroupMembersListsBean)
|
fun onItemClick(position: Int, item: MyFamilyBean.GroupMembersListsBean)
|
||||||
|
fun onRenewClick(position: Int, item: MyFamilyBean.GroupMembersListsBean)
|
||||||
}
|
}
|
||||||
|
|
||||||
private var onItemClickListener: OnItemClickListener? = null
|
private var onItemClickListener: OnItemClickListener? = null
|
||||||
@@ -44,12 +46,20 @@ class MyFamilyAdapter(
|
|||||||
item: MyFamilyBean.GroupMembersListsBean
|
item: MyFamilyBean.GroupMembersListsBean
|
||||||
) {
|
) {
|
||||||
// 设置整个项的点击事件
|
// 设置整个项的点击事件
|
||||||
helper.itemView.setOnClickListener {
|
helper.getView<MeHeadView>(R.id.iv_head).setOnClickListener {
|
||||||
val position = helper.adapterPosition
|
val position = helper.adapterPosition
|
||||||
if (position != RecyclerView.NO_POSITION) {
|
if (position != RecyclerView.NO_POSITION) {
|
||||||
onItemClickListener?.onItemClick(position, item)
|
onItemClickListener?.onItemClick(position, item)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 设置续租按钮的点击事件
|
||||||
|
helper.getView<TextView>(R.id.tv_renew).setOnClickListener {
|
||||||
|
val position = helper.adapterPosition
|
||||||
|
if (position != RecyclerView.NO_POSITION) {
|
||||||
|
onItemClickListener?.onRenewClick(position, item)
|
||||||
|
}
|
||||||
|
}
|
||||||
var flex_entry: FlexboxLayout=helper.getView(R.id.flex_entry)
|
var flex_entry: FlexboxLayout=helper.getView(R.id.flex_entry)
|
||||||
var meHeadView : MeHeadView= helper.getView(R.id.iv_head)
|
var meHeadView : MeHeadView= helper.getView(R.id.iv_head)
|
||||||
var tvName : ShineTextView =helper.getView(R.id.tv_name)
|
var tvName : ShineTextView =helper.getView(R.id.tv_name)
|
||||||
|
|||||||
@@ -65,10 +65,6 @@ class RoomTalentDialog(context: Context, val roomId: String) :
|
|||||||
|
|
||||||
override fun onNext(t: MutableList<String>) {
|
override fun onNext(t: MutableList<String>) {
|
||||||
if (t.isNotEmpty()) {
|
if (t.isNotEmpty()) {
|
||||||
|
|
||||||
t.addAll(t)
|
|
||||||
t.addAll(t)
|
|
||||||
t.addAll(t)
|
|
||||||
adapter = RoomTalentAdapter(t) { selectedValue, position ->
|
adapter = RoomTalentAdapter(t) { selectedValue, position ->
|
||||||
// 处理选中事件
|
// 处理选中事件
|
||||||
LogUtils.e("选中了: $selectedValue, 位置: $position")
|
LogUtils.e("选中了: $selectedValue, 位置: $position")
|
||||||
|
|||||||
@@ -210,12 +210,12 @@
|
|||||||
android:layout_marginBottom="@dimen/dp_12"
|
android:layout_marginBottom="@dimen/dp_12"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
android:layout_marginEnd="@dimen/dp_8"
|
android:layout_marginEnd="@dimen/dp_8"
|
||||||
android:paddingHorizontal="@dimen/dp_18"
|
android:paddingHorizontal="@dimen/dp_5"
|
||||||
android:paddingVertical="@dimen/dp_6"
|
android:paddingVertical="@dimen/dp_6"
|
||||||
android:textColor="@color/white"
|
android:textColor="@color/white"
|
||||||
android:background="@drawable/cs"
|
android:background="@drawable/cs"
|
||||||
android:textSize="@dimen/sp_14"
|
android:textSize="@dimen/sp_12"
|
||||||
app:layout_constraintHorizontal_weight="0.8"
|
app:layout_constraintHorizontal_weight="0.7"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:visibility="invisible"/>
|
android:visibility="invisible"/>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user