|
@@ -9,6 +9,7 @@ import com.yingyang.push.entity.PushMessageBean
|
|
|
import com.yingyang.push.entity.PushMessageTypeBean
|
|
|
import com.yingyang.push.net.XPushServiceFactory
|
|
|
import com.yingyangfly.baselib.ext.setOnSingleClickListener
|
|
|
+import com.yingyangfly.baselib.ext.show
|
|
|
import com.yingyangfly.baselib.ext.toast
|
|
|
import com.yingyangfly.baselib.mvvm.BaseMVVMActivity
|
|
|
import com.yingyangfly.baselib.net.BaseObserver
|
|
@@ -51,10 +52,13 @@ class MessgeListActivity : BaseMVVMActivity<ActivityMessgeListBinding, PushViewM
|
|
|
pushTypeAdapter.setData(pushTypeList)
|
|
|
pushTypeAdapter.onPushClickListener = { bean ->
|
|
|
msgType = bean.dictValue
|
|
|
+ binding {
|
|
|
+ rvPush.show(true)
|
|
|
+ emptyLayout.show(false)
|
|
|
+ }
|
|
|
getMeaageList()
|
|
|
}
|
|
|
//消息列表
|
|
|
- pushListAdapter.showEmptyView = true
|
|
|
rvPush.adapter = pushListAdapter
|
|
|
pushListAdapter.onPushClickListener = { bean ->
|
|
|
if (TextUtils.equals("0", bean.status).not()) {
|
|
@@ -120,6 +124,10 @@ class MessgeListActivity : BaseMVVMActivity<ActivityMessgeListBinding, PushViewM
|
|
|
if (it.isNullOrEmpty().not()) {
|
|
|
pushList.addAll(it)
|
|
|
}
|
|
|
+ binding {
|
|
|
+ rvPush.show(pushList.isNullOrEmpty().not())
|
|
|
+ emptyLayout.show(pushList.isNullOrEmpty())
|
|
|
+ }
|
|
|
pushListAdapter.setData(pushList)
|
|
|
})
|
|
|
}
|