diff --git a/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.html b/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.html index 2690aa81f..d93adc60c 100644 --- a/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.html +++ b/client/src/app/site/motions/modules/motion-detail/components/motion-detail/motion-detail.component.html @@ -517,8 +517,7 @@ *ngIf=" motion && !motion.isParagraphBasedAmendment() && - allChangingObjects && - allChangingObjects.length > 0 + ((allChangingObjects && allChangingObjects.length) || motion.modified_final_version) " > rate_review @@ -527,17 +526,18 @@ -
+
+ @@ -964,6 +965,7 @@ translate (click)="setChangeRecoMode(ChangeRecoMode.Diff)" [ngClass]="{ selected: crMode === ChangeRecoMode.Diff }" + *ngIf="allChangingObjects && allChangingObjects.length" > Diff version @@ -972,6 +974,7 @@ translate (click)="setChangeRecoMode(ChangeRecoMode.Final)" [ngClass]="{ selected: crMode === ChangeRecoMode.Final }" + *ngIf="allChangingObjects && allChangingObjects.length" > Final version 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 3705d09c4..751edd041 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 @@ -504,7 +504,7 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit, .subscribe(mode => (this.lnMode = mode)); this.configService .get('motions_recommendation_text_mode') - .subscribe(mode => (this.crMode = mode)); + .subscribe(mode => (this.crMode = this.determineCrMode(mode))); this.configService .get('motions_show_sequential_numbers') .subscribe(shown => (this.showSequential = shown)); @@ -1418,6 +1418,21 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit, } } + /** + * Tries to determine the realistic CR-Mode from a given CR mode + */ + private determineCrMode(mode: ChangeRecoMode): ChangeRecoMode { + if (this.motion) { + if (mode === ChangeRecoMode.Final && this.motion.modified_final_version) { + return ChangeRecoMode.ModifiedFinal; + } + if ((mode === ChangeRecoMode.Diff || mode === ChangeRecoMode.Changed) && !this.allChangingObjects.length) { + return ChangeRecoMode.Original; + } + } + return mode; + } + /** * Function to listen to notifications if the user edits this motion. * Handles the notification messages.