Add item number to topic title, hide clos slide for one projector
This commit is contained in:
parent
a9de755047
commit
3f77cc7b24
@ -25,7 +25,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</mat-card>
|
</mat-card>
|
||||||
|
|
||||||
<h1 class="title on-transition-fade" *ngIf="viewItem">{{ viewItem.getTitle() }}</h1>
|
<h1 class="title on-transition-fade" *ngIf="viewItem">{{ viewItem.contentObject.getTitle() }}</h1>
|
||||||
|
|
||||||
<mat-card class="speaker-card" *ngIf="viewItem">
|
<mat-card class="speaker-card" *ngIf="viewItem">
|
||||||
<!-- List of finished speakers -->
|
<!-- List of finished speakers -->
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
|
|
||||||
<mat-card *ngIf="topic || editTopic" [ngClass]="editTopic ? 'os-form-card' : 'os-card'" class="on-transition-fade">
|
<mat-card *ngIf="topic || editTopic" [ngClass]="editTopic ? 'os-form-card' : 'os-card'" class="on-transition-fade">
|
||||||
<div *ngIf="!editTopic">
|
<div *ngIf="!editTopic">
|
||||||
<h1>{{ topic.title }}</h1>
|
<h1>{{ topic.getTitle() }}</h1>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<span *ngIf="!editTopic">
|
<span *ngIf="!editTopic">
|
||||||
|
@ -64,7 +64,11 @@ export class ViewTopic extends BaseAgendaViewModel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public getTitle = () => {
|
public getTitle = () => {
|
||||||
|
if (this.agendaItem) {
|
||||||
|
return this.agendaItem.itemNumber + ' · ' + this.title;
|
||||||
|
} else {
|
||||||
return this.title;
|
return this.title;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
public getAgendaItem(): ViewItem {
|
public getAgendaItem(): ViewItem {
|
||||||
|
@ -117,12 +117,12 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<div class="name">
|
<div class="name">
|
||||||
{{ i + 1 }}. <span>{{ getSlideTitle(element) }}</span>
|
<span>{{ getSlideTitle(element) }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="button-right" *ngIf="editQueue">
|
<div class="button-right" *ngIf="editQueue">
|
||||||
<div>
|
<div>
|
||||||
<button type="button" mat-icon-button (click)="removePreviewElement(i)">
|
<button type="button" mat-icon-button (click)="removePreviewElement(i)">
|
||||||
<mat-icon>close</mat-icon>
|
<mat-icon>delete</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -144,7 +144,7 @@
|
|||||||
<span translate>History</span>
|
<span translate>History</span>
|
||||||
</mat-expansion-panel-header>
|
</mat-expansion-panel-header>
|
||||||
<p *ngFor="let elements of projector.elements_history; let i = index">
|
<p *ngFor="let elements of projector.elements_history; let i = index">
|
||||||
{{ i + 1 }}. {{ getSlideTitle(elements[0]) }}
|
{{ i + 1 }}. {{ getSlideTitle(elements[0]) }}
|
||||||
</p>
|
</p>
|
||||||
</mat-expansion-panel>
|
</mat-expansion-panel>
|
||||||
|
|
||||||
@ -191,7 +191,7 @@
|
|||||||
</mat-action-row>
|
</mat-action-row>
|
||||||
</mat-expansion-panel>
|
</mat-expansion-panel>
|
||||||
|
|
||||||
<!-- Current List of Speakers -->
|
<!-- Current list of speakers -->
|
||||||
<mat-expansion-panel>
|
<mat-expansion-panel>
|
||||||
<mat-expansion-panel-header>
|
<mat-expansion-panel-header>
|
||||||
<span translate>Current list of speakers</span>
|
<span translate>Current list of speakers</span>
|
||||||
@ -207,8 +207,8 @@
|
|||||||
</mat-list-item>
|
</mat-list-item>
|
||||||
</mat-list>
|
</mat-list>
|
||||||
|
|
||||||
<!-- Current Speaker -->
|
<!-- Slide-->
|
||||||
<mat-list>
|
<mat-list *ngIf="projectorCount > 1">
|
||||||
<mat-list-item [ngClass]="{ projected: isClosProjected(false) }">
|
<mat-list-item [ngClass]="{ projected: isClosProjected(false) }">
|
||||||
<button type="button" mat-icon-button (click)="toggleClos(false)">
|
<button type="button" mat-icon-button (click)="toggleClos(false)">
|
||||||
<mat-icon>videocam</mat-icon>
|
<mat-icon>videocam</mat-icon>
|
||||||
|
@ -43,6 +43,8 @@ export class ProjectorDetailComponent extends BaseViewComponent implements OnIni
|
|||||||
|
|
||||||
public messages: ViewProjectorMessage[] = [];
|
public messages: ViewProjectorMessage[] = [];
|
||||||
|
|
||||||
|
public projectorCount: number;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* true if the queue might be altered
|
* true if the queue might be altered
|
||||||
*/
|
*/
|
||||||
@ -72,6 +74,7 @@ export class ProjectorDetailComponent extends BaseViewComponent implements OnIni
|
|||||||
|
|
||||||
this.countdownRepo.getViewModelListObservable().subscribe(countdowns => (this.countdowns = countdowns));
|
this.countdownRepo.getViewModelListObservable().subscribe(countdowns => (this.countdowns = countdowns));
|
||||||
this.messageRepo.getViewModelListObservable().subscribe(messages => (this.messages = messages));
|
this.messageRepo.getViewModelListObservable().subscribe(messages => (this.messages = messages));
|
||||||
|
this.repo.getViewModelListObservable().subscribe(projectors => (this.projectorCount = projectors.length));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
export interface TopicSlideData {
|
export interface TopicSlideData {
|
||||||
title: string;
|
title: string;
|
||||||
text: string;
|
text: string;
|
||||||
|
item_number: string;
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,10 @@
|
|||||||
<div *ngIf="data">
|
<div *ngIf="data">
|
||||||
<h1>{{ data.data.title }}</h1>
|
<h1>
|
||||||
|
<span *ngIf="data.data.item_number">
|
||||||
|
{{ data.data.item_number }} ·
|
||||||
|
</span>
|
||||||
|
{{ data.data.title }}
|
||||||
|
</h1>
|
||||||
|
|
||||||
<div [innerHTML]="sanitizedText(data.data.text)"></div>
|
<div [innerHTML]="sanitizedText(data.data.text)"></div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -33,7 +33,17 @@ def topic_slide(
|
|||||||
except KeyError:
|
except KeyError:
|
||||||
raise ProjectorElementException(f"topic with id {topic_id} does not exist")
|
raise ProjectorElementException(f"topic with id {topic_id} does not exist")
|
||||||
|
|
||||||
return {"title": topic["title"], "text": topic["text"]}
|
item_id = topic["agenda_item_id"]
|
||||||
|
try:
|
||||||
|
item = all_data["agenda/item"][item_id]
|
||||||
|
except KeyError:
|
||||||
|
raise ProjectorElementException(f"item with id {item_id} does not exist")
|
||||||
|
|
||||||
|
return {
|
||||||
|
"title": topic["title"],
|
||||||
|
"text": topic["text"],
|
||||||
|
"item_number": item["item_number"],
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
def register_projector_slides() -> None:
|
def register_projector_slides() -> None:
|
||||||
|
Loading…
Reference in New Issue
Block a user