diff --git a/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.html b/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.html index b89bdf8b43bca9bf28b079dd857ff625b3f44324..ebc57a529d423ea6df017904ae43c981c863e715 100644 --- a/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.html +++ b/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.html @@ -51,10 +51,10 @@ <mat-form-field> <input matInput class="form-control" type="number" inputmode="numeric" name="step-value" step="0.01" [placeholder]="uitextPasVariation" [(ngModel)]="stepValue" #step="ngModel" name="step" - required pattern="^-?([0-9]*\.)?([0-9]+[Ee]-?)?[0-9]+$"> + required pattern="^([0-9]*\.)?([0-9]+[Ee]-?)?[0-9]+$"> <mat-error *ngIf="step.errors"> - {{ uitextMustBeANumber }} + {{ uitextMustBePositive }} </mat-error> </mat-form-field> </form> diff --git a/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.ts b/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.ts index 803de5b0be298d58fe5de40432f1fa401afa4a6d..fc2ec72e615931502751c2e177598cf7e4ed3c4c 100644 --- a/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.ts +++ b/src/app/components/dialog-edit-param-values/dialog-edit-param-values.component.ts @@ -437,6 +437,10 @@ export class DialogEditParamValuesComponent implements OnInit { return this.intlService.localizeText("INFO_PARAMFIELD_PARAMVARIER_EXT_STRATEGY"); } + public get uitextMustBePositive() { + return this.intlService.localizeText("ERROR_PARAM_MUST_BE_POSITIVE"); + } + public ngOnInit() { this.initVariableValues(); }