make finalize description editor button disabled

This commit is contained in:
CITE\amentis 2024-10-04 15:04:19 +03:00
parent 3c0efa35d3
commit 9f22d3742a
12 changed files with 48 additions and 13 deletions

View File

@ -67,9 +67,11 @@
<button [disabled]="saving" mat-menu-item (click)="saveAndClose()" type="button">{{ 'DESCRIPTION-EDITOR.ACTIONS.SAVE-AND-CLOSE' | translate }}</button>
<button [disabled]="saving" mat-menu-item (click)="saveAndContinue()" type="button">{{ 'DESCRIPTION-EDITOR.ACTIONS.SAVE-AND-CONTINUE' | translate }}</button>
</mat-menu>
<button [disabled]="saving" *ngIf="canEdit && !isLocked && !viewOnly && hasReversableStatus() == false && canEdit" mat-button class="rounded-btn neutral mr-2" type="button" (click)="finalize()">{{ 'DESCRIPTION-EDITOR.ACTIONS.FINALIZE' | translate }}</button>
<div [matTooltipDisabled]="formGroup.pristine" matTooltip="{{'PLAN-EDITOR.ACTIONS.FINALIZE.CAN-NOT-FINALIZE' | translate}}" >
<button [disabled]="saving || isDirty()" *ngIf="canEdit && !isLocked && !viewOnly && hasReversableStatus() == false && canEdit" mat-button class="rounded-btn neutral mr-2" type="button" (click)="finalize()">{{ 'DESCRIPTION-EDITOR.ACTIONS.FINALIZE.FINALIZE' | translate }}</button>
</div>
<button [disabled]="saving" *ngIf="isLocked" mat-button disabled class="rounded-btn neutral cursor-default" type="button">{{ 'PLAN-OVERVIEW.LOCKED' | translate}}</button>
<button [disabled]="saving" *ngIf="hasReversableStatus() && !isLocked && canEdit" mat-button class="rounded-btn neutral mr-2" (click)="reverse()" type="button">{{ 'DESCRIPTION-EDITOR.ACTIONS.REVERSE' | translate }}</button>
<button [disabled]="saving || isDirty()" *ngIf="hasReversableStatus() && !isLocked && canEdit" mat-button class="rounded-btn neutral mr-2" (click)="reverse()" type="button">{{ 'DESCRIPTION-EDITOR.ACTIONS.REVERSE' | translate }}</button>
</div>
</div>
</div>

View File

@ -1145,7 +1145,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1146,7 +1146,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",

View File

@ -1148,7 +1148,10 @@
"CANCEL": "Cancel",
"SAVE-AND-CONTINUE": "Save & Continue",
"SAVE-AND-CLOSE": "Save & Close",
"FINALIZE": "Finalize",
"FINALIZE": {
"FINALIZE": "Finalize",
"CAN-NOT-FINALIZE": "Save your changes first"
},
"DISCARD": {
"DISCARD": "Discard",
"DISCARD-NEW-MESSAGE": "All unsaved changes will be lost. Would you like to proceed?",