Commit 8a8a8778 authored by Romain DELEAU's avatar Romain DELEAU

add repeatMissionLimit in repeat siderpiece of tasks

parent 20e3bb43
......@@ -2,5 +2,6 @@ export class Repeat {
iteration: number = 0;
while: string = '';
limitMissionRepeat: number = 1;
}
......@@ -119,6 +119,7 @@
<div class="piece-form-top-title">{{'annexeTask_title' | translate}}</div>
<mat-icon class="piece-form-top-comment" fontIcon="comment" *ngIf="task.comments.length > 0"></mat-icon>
<mat-icon class="piece-form-top-repeat" fontIcon="refresh" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive"></mat-icon>
<span class="piece-form-top-repeat-off" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive && task.repeat.limitMissionRepeat == 1"></span>
</div>
<textarea class="piece-form-content" [(ngModel)]="task.objective" (change)="editTrace($event,'Task_action')" [style.background-image]="(i == findFirstIndexOfTaskType('annexe')[0] && j == findFirstIndexOfTaskType('annexe')[1]) ? urlIcon : ''"
*ngIf="!unityService.unity_isActive"
......
......@@ -262,6 +262,16 @@
background-color: white;
border-radius: 50%;
padding: 4px;
&-off {
height: 3px;
width: 35px;
background-color: black;
top: 57px;
right: 19px;
position: absolute;
transform: rotateZ(45deg);
}
}
&-symbol {
......
......@@ -147,6 +147,7 @@
<div class="piece-form-top-title">{{'finalTask_title' | translate}}</div>
<mat-icon class="piece-form-top-comment" fontIcon="comment" *ngIf="task.comments.length > 0"></mat-icon>
<mat-icon class="piece-form-top-repeat" fontIcon="refresh" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive"></mat-icon>
<span class="piece-form-top-repeat-off" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive && task.repeat.limitMissionRepeat == 1"></span>
<button mat-button class="piece-form-top-symbol" (click)="changeDisplaySymbolChoice()"
[matTooltip]="translate.instant('task_common_tooltip')"
matTooltipPosition="above" [matTooltipDisabled]="!tooltipService.activatedTooltips">
......
......@@ -303,6 +303,16 @@
border-radius: 50%;
background-color: white;
padding: 4px;
&-off {
height: 3px;
width: 35px;
background-color: black;
top: 57px;
right: 99px;
position: absolute;
transform: rotateZ(45deg);
}
}
&-symbol {
......
......@@ -148,6 +148,7 @@
<div class="piece-form-top-title">{{'optionnalTask_title1' | translate}}<br>{{'optionnalTask_title2' | translate}}</div>
<mat-icon class="piece-form-top-comment" fontIcon="comment" *ngIf="task.comments.length > 0"></mat-icon>
<mat-icon class="piece-form-top-repeat" fontIcon="refresh" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive"></mat-icon>
<span class="piece-form-top-repeat-off" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive && task.repeat.limitMissionRepeat == 1"></span>
<button mat-button class="piece-form-top-symbol" (click)="changeDisplaySymbolChoice()"
[matTooltip]="translate.instant('task_common_tooltip')"
matTooltipPosition="above" [matTooltipDisabled]="!tooltipService.activatedTooltips">
......
......@@ -314,6 +314,16 @@
border-radius: 50%;
background-color: white;
padding: 4px;
&-off {
height: 3px;
width: 35px;
background-color: black;
top: 57px;
right: 99px;
position: absolute;
transform: rotateZ(45deg);
}
}
&-symbol {
......
......@@ -136,6 +136,7 @@
<div class="piece-form-top-title">{{'randomEvent_title1' | translate}}<br>{{'randomEvent_title2' | translate}}</div>
<mat-icon class="piece-form-top-comment" fontIcon="comment" *ngIf="task.comments.length > 0"></mat-icon>
<mat-icon class="piece-form-top-repeat" fontIcon="refresh" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive"></mat-icon>
<span class="piece-form-top-repeat-off" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive && task.repeat.limitMissionRepeat == 1"></span>
<button mat-button class="piece-form-top-symbol" (click)="changeDisplaySymbolChoice()"
[matTooltip]="translate.instant('task_common_tooltip')"
matTooltipPosition="above" [matTooltipDisabled]="!tooltipService.activatedTooltips">
......
......@@ -305,6 +305,16 @@
border-radius: 50%;
background-color: white;
padding: 4px;
&-off {
height: 3px;
width: 35px;
background-color: black;
top: 57px;
right: 99px;
position: absolute;
transform: rotateZ(45deg);
}
}
&-symbol {
......
......@@ -44,6 +44,7 @@
</div>
<mat-icon class="piece-form-comment" fontIcon="comment" *ngIf="task.comments.length > 0"></mat-icon>
<mat-icon class="piece-form-repeat" fontIcon="refresh" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive"></mat-icon>
<span class="piece-form-repeat-off" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive && task.repeat.limitMissionRepeat == 1"></span>
<mat-icon class="piece-form-character" fontIcon="person" *ngIf="task.characters.length > 0 && !unityService.unity_isActive"
[style.color]="task.characters.length == 1 ? task.characters[0].color : 'black'"
[style.background]="task.characters.length > 1 ? 'linear-gradient('+ task.characters[0].color +','+ task.characters[task.characters.length-1].color +')' : 'white'"></mat-icon>
......
......@@ -124,6 +124,16 @@
background-color: white;
padding: 4px;
border-radius: 50%;
&-off {
height: 3px;
width: 35px;
background-color: black;
bottom: 50px;
left: 99px;
position: absolute;
transform: rotateZ(45deg);
}
}
&-character {
......
......@@ -146,6 +146,7 @@
<div class="piece-form-top-title">{{'normalTask_title' | translate}}</div>
<mat-icon class="piece-form-top-comment" fontIcon="comment" *ngIf="task.comments.length > 0"></mat-icon>
<mat-icon class="piece-form-top-repeat" fontIcon="refresh" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive"></mat-icon>
<span class="piece-form-top-repeat-off" *ngIf="(task.repeat.iteration > 0 || task.repeat.while != '') && !unityService.unity_isActive && task.repeat.limitMissionRepeat == 1"></span>
<button mat-button class="piece-form-top-symbol" (click)="changeDisplaySymbolChoice()"
[matTooltip]="translate.instant('task_common_tooltip')"
matTooltipPosition="above" [matTooltipDisabled]="!tooltipService.activatedTooltips">
......
......@@ -311,6 +311,16 @@
border-radius: 50%;
background-color: white;
padding: 4px;
&-off {
height: 3px;
width: 35px;
background-color: black;
top: 57px;
right: 99px;
position: absolute;
transform: rotateZ(45deg);
}
}
&-symbol {
......
......@@ -6,13 +6,18 @@ matTooltipPosition="before" [matTooltipDisabled]="!tooltipService.activatedToolt
<mat-icon fontIcon="refresh"></mat-icon>
<div class="piece-form-header-for">
<label>{{'repeat_title1' | translate}}</label>
<input type="text" [(ngModel)]="task.repeat.iteration" (change)="editTrace($event,'repeat_nbTimes')"/>
<input type="text" min="1" [max]="task.repeat.limitMissionRepeat" [(ngModel)]="task.repeat.iteration" (change)="editTrace($event,'repeat_nbTimes')"/>
<label>{{'repeat_title2' | translate}}</label>
</div>
</div>
<div class="piece-form-while">
<label>{{'repeat_title3' | translate}}</label>
<textarea [(ngModel)]="task.repeat.while" (change)="editTrace($event,'repeat_stopCondition')"></textarea>
</div>
</div>
<div class="piece-form-missionRepeatLimit">
<label>{{'repeat_missionRepeatLimit1' | translate}}</label>
<input type="text" min="1" [(ngModel)]="task.repeat.limitMissionRepeat" (change)="editTrace($event, 'repeat_missionRepeatLimit')"/>
<label>{{'repeat_missionRepeatLimit2' | translate}}</label>
</div>
</div>
</div>
\ No newline at end of file
......@@ -11,6 +11,16 @@
position: relative;
text-align: center;
margin: 10px 5px 10px 5px;
input {
width: 25px;
border: none;
border-radius: 10px;
background-color: white;
margin-left: 5px;
margin-right: 5px;
text-align: center;
}
&-header {
display: flex;
......@@ -28,17 +38,6 @@
position: relative;
left: 50%;
transform: translateX(-50%);
input {
width: 25px;
border: none;
border-radius: 10px;
background-color: white;
margin-left: 5px;
margin-right: 5px;
text-align: center;
}
}
}
......@@ -61,5 +60,9 @@
background-size: 20%;
}
}
&-missionRepeatLimit {
margin-top: 5px;
}
}
}
\ No newline at end of file
......@@ -298,6 +298,8 @@
"repeat_title1": "Repeat",
"repeat_title2": "times",
"repeat_title3": "or until:",
"repeat_missionRepeatLimit1": "Can only be repeated",
"repeat_missionRepeatLimit2": "times in the mission",
"supplementaryRole_title": "Task related to the additional role",
"supplementaryRole_tooltip": "Used to associate or not associate a task with an additional role.",
......
......@@ -298,6 +298,8 @@
"repeat_title1": "Répéter",
"repeat_title2": "fois",
"repeat_title3": "ou jusqu'à ce que :",
"repeat_missionRepeatLimit1": "Ne peut être répétée que",
"repeat_missionRepeatLimit2": "fois dans la mission",
"supplementaryRole_title": "Tâche liée au rôle supplémentaire",
"supplementaryRole_tooltip": "Sert à associer ou non une tâche à un Rôle supplémentaire.",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment