diff --git a/client/src/app/site/motions/models/view-motion.ts b/client/src/app/site/motions/models/view-motion.ts index a519b8851..0a14acbc4 100644 --- a/client/src/app/site/motions/models/view-motion.ts +++ b/client/src/app/site/motions/models/view-motion.ts @@ -142,6 +142,10 @@ export class ViewMotion extends BaseViewModelWithAgendaItemAndListOfSpeakers 0; } + public get showPreamble(): boolean { + return !this.state?.isFinalState ?? true; + } + /** * Translate the state's css class into a color * diff --git a/client/src/app/site/motions/modules/motion-detail/components/motion-detail-diff/motion-detail-diff.component.html b/client/src/app/site/motions/modules/motion-detail/components/motion-detail-diff/motion-detail-diff.component.html index cfde3008a..a6f4afa66 100644 --- a/client/src/app/site/motions/modules/motion-detail/components/motion-detail-diff/motion-detail-diff.component.html +++ b/client/src/app/site/motions/modules/motion-detail/components/motion-detail-diff/motion-detail-diff.component.html @@ -40,7 +40,7 @@
{{ 'No change recommendations yet' | translate }}
-{{ preamble | translate }} +{{ preamble | translate }}
@@ -126,7 +126,7 @@
{{ 'Rejected' | translate }}
- + - {{ preamble | translate }} + {{ preamble | translate }} diff --git a/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.ts b/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.ts index 0735c7f71..c325c7fbb 100644 --- a/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.ts +++ b/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.ts @@ -167,6 +167,10 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit, ); } + public get showPreamble(): boolean { + return this.motion.showPreamble; + } + /** * Saves the target motion. Accessed via the getter and setter. */ diff --git a/client/src/app/site/motions/services/motion-pdf.service.ts b/client/src/app/site/motions/services/motion-pdf.service.ts index b4d99f411..a4a97a571 100644 --- a/client/src/app/site/motions/services/motion-pdf.service.ts +++ b/client/src/app/site/motions/services/motion-pdf.service.ts @@ -132,8 +132,10 @@ export class MotionPdfService { } if (!contentToExport || contentToExport.includes('text')) { - const preamble = this.createPreamble(motion); - motionPdfContent.push(preamble); + if (motion.showPreamble) { + const preamble = this.createPreamble(motion); + motionPdfContent.push(preamble); + } const text = this.createText(motion, lineLength, lnMode, crMode); motionPdfContent.push(text); }