Guest User

Untitled

a guest
May 24th, 2018
92
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.86 KB | None | 0 0
  1. <tbody>
  2. <ng-container *ngIf="matches">
  3. <tr *ngFor="let meci of matches">
  4. <td>{{ meci.id }}</td>
  5. <td>{{ meci.echipa1 }}</td>
  6. <td>{{ meci.echipa2 }}</td>
  7. <td>{{ meci.tip }}</td>
  8. <td>{{ meci.pretBilet }}</td>
  9. <td>{{ meci.nrLocuri }}</td>
  10. <td>{{ meci.data }}</td>
  11. <td class="ui center aligned">
  12. <span class="fas fa-trash red icon"></span>
  13. <span class="fas fa-edit teal icon" (click)="edit(meci)"></span>
  14. </td>
  15. </tr>
  16. </ng-container>
  17. </tbody>
  18.  
  19. export class MatchesComponent implements OnInit {
  20. matches: Meci[];
  21.  
  22. constructor(private service: MatchesService, private modalService: SuiModalService) { }
  23.  
  24. ngOnInit() {
  25. this.service.getAll().subscribe(matches => this.matches = matches);
  26. }
  27.  
  28. edit(meci: Meci) {
  29. console.log('edit');
  30. }
  31.  
  32. }
  33.  
  34. <ng-container *ngIf="matches.length > 0">
Add Comment
Please, Sign In to add comment