浏览代码

滋补养生+鼎盛联盟+精品大仓底部加上没有更多了

许雷 2 年之前
父节点
当前提交
b6bcceaf11
共有 2 个文件被更改,包括 18 次插入2 次删除
  1. 8 0
      src/pages/product/dingshenglianmeng.vue
  2. 10 2
      src/pages/product/zibuyangsheng.vue

+ 8 - 0
src/pages/product/dingshenglianmeng.vue

@@ -44,6 +44,14 @@
44
               </div>
44
               </div>
45
             </div>
45
             </div>
46
           </grid-view>
46
           </grid-view>
47
+          <div class="pb-safe flex justify-center items-center text-[12px] text-gray-500" >
48
+            <div v-if="state.status === 'loading'">
49
+              加载中...
50
+            </div>
51
+            <div v-if="state.status === 'noMore'">
52
+              没有更多了~
53
+            </div>
54
+          </div>
47
         </div>
55
         </div>
48
       </div>
56
       </div>
49
       <CXBEmpty v-else/>
57
       <CXBEmpty v-else/>

+ 10 - 2
src/pages/product/zibuyangsheng.vue

@@ -30,7 +30,7 @@ function loadList(action: 'page' | 'reload', callback?: (items) => void) {
30
 	if (action === 'reload') {
30
 	if (action === 'reload') {
31
 		state.currentPage = 1
31
 		state.currentPage = 1
32
 	}
32
 	}
33
-	
33
+
34
 	getProductList(state.id,state.currentPage,state.pageSize).then(res => {
34
 	getProductList(state.id,state.currentPage,state.pageSize).then(res => {
35
 		if (res) {
35
 		if (res) {
36
 			if (action === 'reload') {
36
 			if (action === 'reload') {
@@ -40,7 +40,7 @@ function loadList(action: 'page' | 'reload', callback?: (items) => void) {
40
 			}
40
 			}
41
 			state.totalPage = Math.ceil(res.count / state.pageSize);
41
 			state.totalPage = Math.ceil(res.count / state.pageSize);
42
 			state.status = 'more'
42
 			state.status = 'more'
43
-			
43
+
44
 			if (callback) {
44
 			if (callback) {
45
 			      callback(res.list)
45
 			      callback(res.list)
46
 			}
46
 			}
@@ -126,6 +126,14 @@ onPullDownRefresh(() => {
126
               </div>
126
               </div>
127
             </div>
127
             </div>
128
           </grid-view>
128
           </grid-view>
129
+          <div class="pb-safe flex justify-center items-center text-[12px] text-gray-500" >
130
+            <div v-if="state.status === 'loading'">
131
+              加载中...
132
+            </div>
133
+            <div v-if="state.status === 'noMore'">
134
+              没有更多了~
135
+            </div>
136
+          </div>
129
         </div>
137
         </div>
130
       </div>
138
       </div>
131
     </scroll-view>
139
     </scroll-view>