Commit 74e5fcedc9bf2cb55304ebcc809a137bcdaa996a
1 parent
e6a465e0
优化一些已知问题
Showing
1 changed file
with
14 additions
and
8 deletions
src/pages/myGiftBox/myGiftBox.vue
| @@ -317,14 +317,17 @@ export default { | @@ -317,14 +317,17 @@ export default { | ||
| 317 | } else { | 317 | } else { |
| 318 | this.$set(this, "receivingGiftsInfo", datas.list); | 318 | this.$set(this, "receivingGiftsInfo", datas.list); |
| 319 | } | 319 | } |
| 320 | + // 判断是否显示没有更多 | ||
| 321 | + if(datas.list.length<20){ | ||
| 322 | + this.receivingGifts.tipText = "已经全部加载完毕"; | ||
| 323 | + }else{ | ||
| 324 | + this.receivingGifts.tipText = ""; | ||
| 325 | + } | ||
| 320 | }else{ | 326 | }else{ |
| 321 | // this.receivingGifts.pages = 1; // 数据为空时页脚从1开始计算 | 327 | // this.receivingGifts.pages = 1; // 数据为空时页脚从1开始计算 |
| 322 | - if(this.receivingGifts.pages>1){ | ||
| 323 | - this.receivingGifts.tipText = "已经全部加载完毕"; //提示全部加载为空 | ||
| 324 | - }else{ | 328 | + if(this.receivingGifts.pages==1){ |
| 325 | //页脚等于1的时候会出现数据获取为空 | 329 | //页脚等于1的时候会出现数据获取为空 |
| 326 | this.receivingGiftsInfo = datas.list; | 330 | this.receivingGiftsInfo = datas.list; |
| 327 | - this.receivingGifts.tipText = ""; //不提示数据加载完 | ||
| 328 | } | 331 | } |
| 329 | console.log(this.receivingGifts.tipText); | 332 | console.log(this.receivingGifts.tipText); |
| 330 | } | 333 | } |
| @@ -451,12 +454,15 @@ export default { | @@ -451,12 +454,15 @@ export default { | ||
| 451 | } else { | 454 | } else { |
| 452 | this.$set(this, "giftGivingItem", datas.list); | 455 | this.$set(this, "giftGivingItem", datas.list); |
| 453 | } | 456 | } |
| 457 | + // 判断是否显示没有更多 | ||
| 458 | + if(datas.list.length<20){ | ||
| 459 | + this.giftGiving.tipText = "已经全部加载完毕"; | ||
| 460 | + }else{ | ||
| 461 | + this.giftGiving.tipText = ""; | ||
| 462 | + } | ||
| 454 | }else{ | 463 | }else{ |
| 455 | // this.giftGiving.pages = 1;// 数据为空时设置分页数为1 | 464 | // this.giftGiving.pages = 1;// 数据为空时设置分页数为1 |
| 456 | - if(this.giftGiving.pages>1){ | ||
| 457 | - this.giftGiving.tipText = "已经全部加载完毕"; //提示全部加载为空 | ||
| 458 | - }else{ | ||
| 459 | - this.giftGiving.tipText = ""; | 465 | + if(this.giftGiving.pages==1){ |
| 460 | //页脚等于1的时候会出现数据获取为空 | 466 | //页脚等于1的时候会出现数据获取为空 |
| 461 | this.giftGivingItem = datas.list; | 467 | this.giftGivingItem = datas.list; |
| 462 | } | 468 | } |