0
In my project I have a card to which when I click it appears the information of that user, my purpose is that when clicking it opens only of the user I clicked, but nevertheless, it ends up opening all the users, as in the image below
I wonder if there is a way with the click I just open where I clicked, I did some research, but only found a method of Angularjs, which does not apply in Angular 7. Also follow my HTML and TS to analyze
getTable(){
this.graphicsService.getTabela().subscribe(res => {
this.table = res;
console.table(this.table)
});
}
<div class="content-card" *ngFor="let item of table">
<div class="client" (click)="teste = !teste">
<span>{{ item.IdUser }} {{ item.NameUser }} {{ item.ClientAnswered }}</span>
</div>
<div class="client-info" [hidden]="!teste">
<span>{{ item.DateMessage }}</span>
</div>
</div>
Thanks in advance.
It worked perfectly, thank you very much.
– Renan Santos