@@ -12,21 +12,59 @@ <h4 class="mat-h4 flex-98">
1212
1313 < mat-form-field class ="flex-31 ">
1414 < mat-label > {{ 'labels.inputs.Minimum' | translate }}</ mat-label >
15- < input type ="number " matInput formControlName ="minimumShares " />
15+ < input type ="number " matInput formControlName ="minimumShares " min ="1 " step ="1 " required />
16+ < mat-error *ngIf ="shareProductSettingsForm.get('minimumShares').hasError('required') ">
17+ {{ 'labels.inputs.Minimum Shares per Client' | translate }} {{ 'labels.commons.is' | translate }}
18+ < strong > {{ 'labels.commons.required' | translate }}</ strong >
19+ </ mat-error >
20+ < mat-error *ngIf ="shareProductSettingsForm.get('minimumShares').hasError('min') ">
21+ {{ 'labels.inputs.Minimum Shares per Client' | translate }}
22+ {{ 'labels.commons.must be greater than zero' | translate }}
23+ </ mat-error >
24+ < mat-error *ngIf ="shareProductSettingsForm.get('minimumShares').hasError('pattern') ">
25+ {{ 'labels.inputs.Minimum Shares per Client' | translate }}
26+ {{ 'labels.commons.must be an integer' | translate }}
27+ </ mat-error >
1628 </ mat-form-field >
1729
1830 < mat-form-field class ="flex-31 ">
1931 < mat-label > {{ 'labels.inputs.Default' | translate }}</ mat-label >
20- < input type ="number " matInput formControlName ="nominalShares " required />
21- < mat-error >
32+ < input type ="number " matInput formControlName ="nominalShares " min =" 1 " step =" 1 " required />
33+ < mat-error *ngIf =" shareProductSettingsForm.get('nominalShares').hasError('required') " >
2234 {{ 'labels.inputs.Default Shares per Client' | translate }} {{ 'labels.commons.is' | translate }}
2335 < strong > {{ 'labels.commons.required' | translate }}</ strong >
2436 </ mat-error >
37+ < mat-error *ngIf ="shareProductSettingsForm.get('nominalShares').hasError('min') ">
38+ {{ 'labels.inputs.Default Shares per Client' | translate }}
39+ {{ 'labels.commons.must be greater than zero' | translate }}
40+ </ mat-error >
41+ < mat-error *ngIf ="shareProductSettingsForm.get('nominalShares').hasError('pattern') ">
42+ {{ 'labels.inputs.Default Shares per Client' | translate }}
43+ {{ 'labels.commons.must be an integer' | translate }}
44+ </ mat-error >
2545 </ mat-form-field >
2646
2747 < mat-form-field class ="flex-31 ">
2848 < mat-label > {{ 'labels.inputs.Maximum' | translate }}</ mat-label >
29- < input type ="number " matInput formControlName ="maximumShares " />
49+ < input type ="number " matInput formControlName ="maximumShares " min ="1 " step ="1 " required />
50+ < mat-error *ngIf ="shareProductSettingsForm.get('maximumShares').hasError('required') ">
51+ {{ 'labels.inputs.Maximum Shares per Client' | translate }} {{ 'labels.commons.is' | translate }}
52+ < strong > {{ 'labels.commons.required' | translate }}</ strong >
53+ </ mat-error >
54+ < mat-error *ngIf ="shareProductSettingsForm.get('maximumShares').hasError('min') ">
55+ {{ 'labels.inputs.Maximum Shares per Client' | translate }}
56+ {{ 'labels.commons.must be greater than zero' | translate }}
57+ </ mat-error >
58+ < mat-error *ngIf ="shareProductSettingsForm.get('maximumShares').hasError('pattern') ">
59+ {{ 'labels.inputs.Maximum Shares per Client' | translate }}
60+ {{ 'labels.commons.must be an integer' | translate }}
61+ </ mat-error >
62+ < mat-error *ngIf ="shareProductSettingsForm.hasError('sharesOrder') ">
63+ {{
64+ 'labels.commons.minimum must be less than or equal to default and default must be less than or equal to maximum'
65+ | translate
66+ }}
67+ </ mat-error >
3068 </ mat-form-field >
3169
3270 < h4 class ="mat-h4 flex-98 ">
0 commit comments