gestion de l'affichage des annonces dans la partie user

This commit is contained in:
MiharyR 2021-12-15 00:49:33 +01:00
parent 7ea0a5eb97
commit b0b17c062d
14 changed files with 57 additions and 101 deletions

View file

@ -84,9 +84,12 @@ export class PageAdListAdvertiserComponent implements AfterViewInit
console.log(retour);
}
else {
for(let advert of retour.data) this.tabAdvertWithCountViews.push(this.advertToAdvertWithCountViews(advert));
this.dataSource = new MatTableDataSource<AdvertWithCountViews>();
this.onFilter();
if(retour.data.length !== 0)
{
for(let advert of retour.data) this.tabAdvertWithCountViews.push(this.advertToAdvertWithCountViews(advert));
this.dataSource = new MatTableDataSource<AdvertWithCountViews>();
this.onFilter();
}
}
}