-
- {{ motion.state.name | translate }}
-
-
- {{ motion.state.name | translate }}
-
+
+
+ {{ stateLabel }}
+
+
+
+
+
+
+
+
+
+
+ {{ stateLabel }}
+
+
@@ -251,6 +258,7 @@
(click)="setRecommendation(recommendation.id)"
>
{{ recommendation.recommendation_label | translate }}
+ ...
-
- {{
- motion.recommendation
- ? (motion.recommendation.recommendation_label | translate)
- : ('not set' | translate)
- }}
-
-
- {{
- motion.recommendation
- ? (motion.recommendation.recommendation_label | translate)
- : ('not set' | translate)
- }}
-
-
+
+
+ {{ recommendationLabel }}
+
+
+
+
+
+
+
+
+
+
+ {{ recommendationLabel }}
+
+
diff --git a/client/src/app/site/motions/components/motion-detail/motion-detail.component.ts b/client/src/app/site/motions/components/motion-detail/motion-detail.component.ts
index 5ac67ffc1..74a662dbc 100644
--- a/client/src/app/site/motions/components/motion-detail/motion-detail.component.ts
+++ b/client/src/app/site/motions/components/motion-detail/motion-detail.component.ts
@@ -114,6 +114,20 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit {
return false;
}
+ /**
+ * @returns the current recommendation label (with extension)
+ */
+ public get recommendationLabel(): string {
+ return this.repo.getExtendedRecommendationLabel(this.motion);
+ }
+
+ /**
+ * @returns the current state label (with extension)
+ */
+ public get stateLabel(): string {
+ return this.repo.getExtendedStateLabel(this.motion);
+ }
+
/**
* Saves the target motion. Accessed via the getter and setter.
*/
@@ -286,6 +300,16 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit {
*/
public personalNoteContent: PersonalNoteContent;
+ /**
+ * new state extension label to be submitted, if state extensions can be set
+ */
+ public newStateExtension = '';
+
+ /**
+ * new recommendation extension label to be submitted, if recommendation extensions can be set
+ */
+ public newRecommendationExtension = '';
+
/**
* Constuct the detail view.
*
@@ -460,6 +484,8 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit {
this.repo.getViewModelObservable(motionId).subscribe(newViewMotion => {
if (newViewMotion) {
this.motion = newViewMotion;
+ this.newStateExtension = this.motion.stateExtension;
+ this.newRecommendationExtension = this.motion.recommendationExtension;
this.personalNoteService.getPersonalNoteObserver(this.motion.motion).subscribe(pn => {
this.personalNoteContent = pn;
});
@@ -906,6 +932,14 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit {
this.repo.setState(this.motion, id);
}
+ /**
+ * triggers the update this motion's state extension according to the current string
+ * in {@link newStateExtension}
+ */
+ public setStateExtension(): void {
+ this.repo.setStateExtension(this.motion, this.newStateExtension);
+ }
+
/**
* Sets the recommendation
*
@@ -915,6 +949,14 @@ export class MotionDetailComponent extends BaseViewComponent implements OnInit {
this.repo.setRecommendation(this.motion, id);
}
+ /**
+ * triggers the update this motion's recommendation extension according to the current string
+ * in {@link newRecommendationExtension}
+ */
+ public setRecommendationExtension(): void {
+ this.repo.setRecommendationExtension(this.motion, this.newRecommendationExtension);
+ }
+
/**
* Sets the category for current motion
*
diff --git a/client/src/app/site/motions/components/motion-list/motion-list.component.html b/client/src/app/site/motions/components/motion-list/motion-list.component.html
index 047c98f6a..db46bb07d 100644
--- a/client/src/app/site/motions/components/motion-list/motion-list.component.html
+++ b/client/src/app/site/motions/components/motion-list/motion-list.component.html
@@ -17,8 +17,11 @@
-
+
@@ -30,7 +33,7 @@
-
+
Projector
@@ -82,14 +85,12 @@
lightblue: motion.state.css_class === 'primary'
}"
>
- {{ motion.state.name | translate }}
+ {{ getStateLabel(motion) }}
- {{
- motion.recommendation.recommendation_label | translate
- }}
+ {{ getRecommendationLabel(motion) }}
@@ -198,20 +199,29 @@
label
Set status
-