优化-待测试
This commit is contained in:
@@ -384,14 +384,14 @@ class FoodCollectionActivity : ComponentActivity() {
|
||||
) { records ->
|
||||
finishRefresh()
|
||||
binding.etGoodsInput.hideKeyboard()
|
||||
if (pageNo == 1 && records.isEmpty()) {
|
||||
loadEmptyView()
|
||||
return@searchGoods
|
||||
}
|
||||
if (pageNo == 1) {
|
||||
searchGoodsList.clear()
|
||||
}
|
||||
searchGoodsList.addAll(records)
|
||||
if (pageNo == 1 && searchGoodsList.isEmpty()) {
|
||||
loadEmptyView()
|
||||
return@searchGoods
|
||||
}
|
||||
val enableLoadMore = records.size >= PAGE_SIZE
|
||||
binding.refreshLayout.setEnableLoadMore(enableLoadMore)
|
||||
if (enableLoadMore) {
|
||||
|
||||
Reference in New Issue
Block a user