publish show

This commit is contained in:
2020-04-17 15:13:39 +02:00
committed by smuddy
parent b8fbcb4b9a
commit c5748d5e34
19 changed files with 126 additions and 63 deletions

View File

@@ -69,4 +69,18 @@ export class ShowComponent implements OnInit {
const filtered = this.songs.filter(_ => _.id === songId);
return filtered.length > 0 ? filtered[0] : null;
}
public async onArchive(archived: boolean): Promise<void> {
await this.showService.update$(this.showId, {archived});
}
public async onPublish(published: boolean): Promise<void> {
await this.showService.update$(this.showId, {published});
}
public getStatus(show: Show): string {
if (show.published) return 'veröffentlicht';
if (show.reported) return 'gemeldet';
return 'entwurf';
}
}