WEB-452 Validation Error: Total Number of Shares Allows Zero or Negative Values (#2843)
This commit is contained in:
+5
-1
@@ -8,11 +8,15 @@
|
||||
matTooltip="{{ 'tooltips.Total number of shares that a product is offering' | translate }}"
|
||||
formControlName="totalShares"
|
||||
required
|
||||
min="1"
|
||||
/>
|
||||
<mat-error>
|
||||
<mat-error *ngIf="shareProductTermsForm.get('totalShares').hasError('required')">
|
||||
{{ 'labels.inputs.Total Number of Shares' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
<mat-error *ngIf="shareProductTermsForm.get('totalShares').hasError('min')">
|
||||
{{ 'labels.inputs.Total Number of Shares' | translate }} must be at least <strong>1</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field class="flex-48">
|
||||
|
||||
+3
-1
@@ -56,7 +56,9 @@ export class ShareProductTermsStepComponent implements OnInit {
|
||||
this.shareProductTermsForm = this.formBuilder.group({
|
||||
totalShares: [
|
||||
'',
|
||||
Validators.required
|
||||
[
|
||||
Validators.required,
|
||||
Validators.min(1)]
|
||||
],
|
||||
sharesIssued: [
|
||||
'',
|
||||
|
||||
Reference in New Issue
Block a user