fix
This commit is contained in:
@@ -65,7 +65,7 @@
|
||||
<a-checkbox v-model:checked="item.pin">{{ $t('Material.PIN') }}</a-checkbox>
|
||||
</div>
|
||||
</div>
|
||||
<div v-show="total > imgList?.length" class="material_content_list_loding" v-observe>
|
||||
<div v-show="total > imgList?.length && total != 0" class="material_content_list_loding" v-observe>
|
||||
<img src="@/assets/images/homePage/loading.gif" alt="">
|
||||
</div>
|
||||
</div>
|
||||
@@ -95,6 +95,7 @@ export default defineComponent({
|
||||
let selectCode:any = ref('')
|
||||
let currentPage:any = ref(1)
|
||||
let searchPictureName = ref('')
|
||||
let isOldSearchPictureName = ref('')
|
||||
let pageSize = ref(12)
|
||||
let total = ref(0)
|
||||
let searcMaterialhName:any = ref('') //搜索名字
|
||||
@@ -112,6 +113,7 @@ export default defineComponent({
|
||||
selectCode,
|
||||
currentPage,
|
||||
searchPictureName,
|
||||
isOldSearchPictureName,
|
||||
pageSize,
|
||||
total,
|
||||
searcMaterialhName,
|
||||
@@ -287,6 +289,7 @@ export default defineComponent({
|
||||
this.isShowLoading = true
|
||||
Https.axiosPost(Https.httpUrls.queryLibraryPage,data).then(
|
||||
(rv: any) => {
|
||||
this.total = rv.total
|
||||
let aa:any = []
|
||||
rv.content.forEach((item:any,index:any) => {
|
||||
let arr
|
||||
@@ -315,13 +318,16 @@ export default defineComponent({
|
||||
}
|
||||
aa.push(item)
|
||||
});
|
||||
if(aa[aa.length-1].id == this.imgList[this.imgList.length-1]?.id){
|
||||
|
||||
if(this.searchPictureName != this.isOldSearchPictureName){
|
||||
this.imgList = []
|
||||
}else{
|
||||
}
|
||||
this.isOldSearchPictureName = this.searchPictureName
|
||||
if((aa[aa.length-1].id == this.imgList[this.imgList.length-1]?.id) && aa?.[aa.length-1]?.id){
|
||||
}else{
|
||||
this.imgList.push(...aa)
|
||||
}
|
||||
// this.imgList = aa
|
||||
this.total = rv.total
|
||||
this.isShowLoading = false
|
||||
}
|
||||
).catch((res)=>{
|
||||
|
||||
Reference in New Issue
Block a user