Commit add592e4 by fengquan

feat: 倾诉列表搜索

parent 8f4e2322
...@@ -452,6 +452,21 @@ class ConfideHomeActivity : ...@@ -452,6 +452,21 @@ class ConfideHomeActivity :
val keyWord = data?.getStringExtra(FinalString.CONFIDE_SEARCH_KEY_WORD) val keyWord = data?.getStringExtra(FinalString.CONFIDE_SEARCH_KEY_WORD)
if (keyWord != null){ if (keyWord != null){
keyword = keyWord keyword = keyWord
page = 1
allFiltersBean = ConfideHomeAllFiltersBean(
page,
"",
ConfideHomeFiterItemBean().apply {
id = "-1"
name = ""
},
ConfideHomeFiterItemBean().apply {
id = "-1"
name = ""
},
ArrayList(),
ArrayList()
)
rl_search_head.findViewById<TextView>(R.id.etSearch).setText(keyword) rl_search_head.findViewById<TextView>(R.id.etSearch).setText(keyword)
onRefresh() onRefresh()
} }
...@@ -526,7 +541,22 @@ class ConfideHomeActivity : ...@@ -526,7 +541,22 @@ class ConfideHomeActivity :
} }
if (bean?.body != null && bean?.body.size == 0) { if (bean?.body != null && bean?.body.size == 0) {
cacheList?.add(ConfideHomeDataBean(IConfideHomeConfig.TYPE_EMPTY,null,null,null, -1)) var hasEmptyLayout : Boolean = false
for (index in (0..(cacheList!!.size - 1)).reversed()) {
if (cacheList!![index].type == IConfideHomeConfig.TYPE_EMPTY) {
hasEmptyLayout = true
break
}
}
if (!hasEmptyLayout){
cacheList?.add(ConfideHomeDataBean(IConfideHomeConfig.TYPE_EMPTY,null,null,null, -1))
}
}else{
for (index in (0..(cacheList!!.size - 1)).reversed()) {
if (cacheList!![index].type == IConfideHomeConfig.TYPE_EMPTY) {
cacheList!!.removeAt(index)
}
}
} }
listScrollListener?.moveToPosition(rv_list) listScrollListener?.moveToPosition(rv_list)
......
...@@ -690,7 +690,7 @@ public class ErrorMessageConverter { ...@@ -690,7 +690,7 @@ public class ErrorMessageConverter {
return getLocalizedString(R.string.TUIKitErrorSVRNoSuccessResult); // @"批量操作无成功结果"; return getLocalizedString(R.string.TUIKitErrorSVRNoSuccessResult); // @"批量操作无成功结果";
case BaseConstants.ERR_TO_USER_INVALID: case BaseConstants.ERR_TO_USER_INVALID:
return getLocalizedString(R.string.TUIKitErrorSVRToUserInvalid); // @"IM: 无效接收方"; return getLocalizedString(R.string.TUIKitErrorSVRToUserInvalid); // @"IM: 无效接收方";
case BaseConstants.ERR_REQUEST_TIMEOUT: case BaseConstants.ERR_REQUEST_TIME_OUT:
return getLocalizedString(R.string.TUIKitErrorSVRRequestTimeout); // @"请求超时"; return getLocalizedString(R.string.TUIKitErrorSVRRequestTimeout); // @"请求超时";
case BaseConstants.ERR_INIT_CORE_FAIL: case BaseConstants.ERR_INIT_CORE_FAIL:
return getLocalizedString(R.string.TUIKitErrorSVRInitCoreFail); // @"INIT CORE模块失败"; return getLocalizedString(R.string.TUIKitErrorSVRInitCoreFail); // @"INIT CORE模块失败";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment