Merge pull request #5367 from tsiegleauq/hide-submitter-in-projector
Hide the submitter-box in motion slide if empty
This commit is contained in:
commit
d1b6ed8d29
@ -63,7 +63,7 @@ export interface MotionSlideData {
|
|||||||
reason?: string;
|
reason?: string;
|
||||||
is_child: boolean;
|
is_child: boolean;
|
||||||
show_meta_box: boolean;
|
show_meta_box: boolean;
|
||||||
submitter?: string[];
|
submitters?: string[];
|
||||||
recommender?: string;
|
recommender?: string;
|
||||||
recommendation?: string;
|
recommendation?: string;
|
||||||
recommendation_extension?: string;
|
recommendation_extension?: string;
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
[ngStyle]="{ 'margin-top': projector.show_header_footer ? '144px' : '94px' }"
|
[ngStyle]="{ 'margin-top': projector.show_header_footer ? '144px' : '94px' }"
|
||||||
>
|
>
|
||||||
<!-- Submitters -->
|
<!-- Submitters -->
|
||||||
<h3>{{ 'Submitters' | translate }}</h3>
|
<h3 *ngIf="data.data?.submitters?.length > 0">{{ 'Submitters' | translate }}</h3>
|
||||||
<span *ngFor="let submitter of data.data.submitters; let last = last">
|
<span *ngFor="let submitter of data.data.submitters; let last = last">
|
||||||
{{ submitter }}<span *ngIf="!last">, </span>
|
{{ submitter }}<span *ngIf="!last">, </span>
|
||||||
</span>
|
</span>
|
||||||
@ -34,41 +34,41 @@
|
|||||||
</span>
|
</span>
|
||||||
</h2>
|
</h2>
|
||||||
|
|
||||||
<div *ngIf="!data.data.show_meta_box">
|
<!-- Metainfo as table -->
|
||||||
<table class="metatable spacer-top-20" cellpadding="0" cellspacing="0">
|
<table *ngIf="showMetaTable" class="metatable spacer-top-20" cellpadding="0" cellspacing="0">
|
||||||
<!-- Submitters -->
|
<!-- Submitters -->
|
||||||
<tr>
|
<tr *ngIf="data.data?.submitters?.length > 0">
|
||||||
<td class="min">
|
<td class="min">
|
||||||
<b>{{ 'Submitters' | translate }}:</b>
|
<b>{{ 'Submitters' | translate }}:</b>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<span *ngFor="let submitter of data.data.submitters; let last = last">
|
<span *ngFor="let submitter of data.data.submitters; let last = last">
|
||||||
{{ submitter }}<span *ngIf="!last">, </span>
|
{{ submitter }}<span *ngIf="!last">, </span>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<!-- Recommendation -->
|
<!-- Recommendation -->
|
||||||
<tr *ngIf="data.data.recommendation && data.data.recommender">
|
<tr *ngIf="data.data.recommendation && data.data.recommender">
|
||||||
<td class="min">
|
<td class="min">
|
||||||
<b>{{ data.data.recommender }}:</b>
|
<b>{{ data.data.recommender }}:</b>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
{{ getRecommendationLabel() }}
|
{{ getRecommendationLabel() }}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<!-- recommendation referencing motions -->
|
<!-- recommendation referencing motions -->
|
||||||
<tr *ngIf="data.data.recommendation_referencing_motions">
|
<tr *ngIf="data.data.recommendation_referencing_motions">
|
||||||
<td class="min">
|
<td class="min">
|
||||||
<b>{{ 'Referring motions' | translate }}:</b>
|
<b>{{ 'Referring motions' | translate }}:</b>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<span *ngFor="let titleInformation of referencingMotions; let last = last">
|
<span *ngFor="let titleInformation of referencingMotions; let last = last">
|
||||||
{{ getIdentifierOrTitle(titleInformation) }}<span *ngIf="!last">,</span>
|
{{ getIdentifierOrTitle(titleInformation) }}<span *ngIf="!last">,</span>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -85,6 +85,15 @@ export class MotionSlideComponent extends BaseMotionSlideComponent<MotionSlideDa
|
|||||||
return this._data;
|
return this._data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public get showMetaTable(): boolean {
|
||||||
|
return (
|
||||||
|
!this.data.data.show_meta_box &&
|
||||||
|
(this.data.data?.submitters.length > 0 ||
|
||||||
|
(!!this.data.data.recommendation && !!this.data.data.recommender) ||
|
||||||
|
!!this.data.data.recommendation_referencing_motions)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
private _scroll = 0;
|
private _scroll = 0;
|
||||||
|
|
||||||
@Input()
|
@Input()
|
||||||
|
Loading…
Reference in New Issue
Block a user