Merge pull request #2728 from JaySoni1/WEB-358-wrong-text-for-field-validation-when-adding-codes
WEB-358 Wrong text for field validation when adding codes
This commit is contained in:
@@ -31,7 +31,7 @@
|
|||||||
<div class="flex-fill layout-row-wrap gap-2percent responsive-column" [formGroupName]="i">
|
<div class="flex-fill layout-row-wrap gap-2percent responsive-column" [formGroupName]="i">
|
||||||
<mat-form-field class="flex-fill flex-20">
|
<mat-form-field class="flex-fill flex-20">
|
||||||
<mat-label>{{ 'labels.inputs.name' | translate }}</mat-label>
|
<mat-label>{{ 'labels.inputs.name' | translate }}</mat-label>
|
||||||
<input required matInput formControlName="name" />
|
<input required matInput formControlName="name" placeholder="{{ 'labels.inputs.name' | translate }}" />
|
||||||
<mat-error *ngIf="codeValues.at(i).controls.name.hasError('required')">
|
<mat-error *ngIf="codeValues.at(i).controls.name.hasError('required')">
|
||||||
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||||
@@ -40,12 +40,22 @@
|
|||||||
|
|
||||||
<mat-form-field class="flex-fill flex-22">
|
<mat-form-field class="flex-fill flex-22">
|
||||||
<mat-label>{{ 'labels.inputs.Description' | translate }}</mat-label>
|
<mat-label>{{ 'labels.inputs.Description' | translate }}</mat-label>
|
||||||
<input matInput formControlName="description" />
|
<input
|
||||||
|
matInput
|
||||||
|
formControlName="description"
|
||||||
|
placeholder="{{ 'labels.inputs.Description' | translate }}"
|
||||||
|
/>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<mat-form-field class="flex-fill flex-18">
|
<mat-form-field class="flex-fill flex-18">
|
||||||
<mat-label>{{ 'labels.inputs.Position' | translate }}</mat-label>
|
<mat-label>{{ 'labels.inputs.Position' | translate }}</mat-label>
|
||||||
<input required matInput formControlName="position" type="number" />
|
<input
|
||||||
|
required
|
||||||
|
matInput
|
||||||
|
formControlName="position"
|
||||||
|
type="number"
|
||||||
|
placeholder="{{ 'labels.inputs.Position' | translate }}"
|
||||||
|
/>
|
||||||
<mat-error *ngIf="codeValues.at(i).controls.position.hasError('required')">
|
<mat-error *ngIf="codeValues.at(i).controls.position.hasError('required')">
|
||||||
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||||
@@ -63,19 +73,22 @@
|
|||||||
<button
|
<button
|
||||||
mat-stroked-button
|
mat-stroked-button
|
||||||
color="primary"
|
color="primary"
|
||||||
[disabled]="codeValues.at(i).pristine"
|
type="button"
|
||||||
|
[disabled]="!codeValues.at(i).valid || codeValues.at(i).pristine"
|
||||||
(click)="updateCodeValue(i)"
|
(click)="updateCodeValue(i)"
|
||||||
*mifosxHasPermission="'UPDATE_CODEVALUE'"
|
*mifosxHasPermission="'UPDATE_CODEVALUE'"
|
||||||
>
|
>
|
||||||
{{ 'labels.buttons.Submit' | translate }}
|
{{ 'labels.buttons.Submit' | translate }}
|
||||||
</button>
|
</button>
|
||||||
</span>
|
</span>
|
||||||
<button mat-button *ngIf="codeValueRowStatus[i] === 'edit'" (click)="disableRow(i)">
|
<button mat-button type="button" *ngIf="codeValueRowStatus[i] === 'edit'" (click)="disableRow(i)">
|
||||||
{{ 'labels.buttons.Cancel' | translate }}
|
{{ 'labels.buttons.Cancel' | translate }}
|
||||||
</button>
|
</button>
|
||||||
<button
|
<button
|
||||||
mat-icon-button
|
mat-icon-button
|
||||||
color="primary"
|
color="primary"
|
||||||
|
type="button"
|
||||||
|
title="{{ 'tooltips.Add' | translate }}"
|
||||||
[disabled]="!codeValuesForm.get('codeValues').at(i).valid"
|
[disabled]="!codeValuesForm.get('codeValues').at(i).valid"
|
||||||
*ngIf="codeValueRowStatus[i] === 'new'"
|
*ngIf="codeValueRowStatus[i] === 'new'"
|
||||||
matTooltip="{{ 'tooltips.Add' | translate }}"
|
matTooltip="{{ 'tooltips.Add' | translate }}"
|
||||||
@@ -87,6 +100,7 @@
|
|||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
color="primary"
|
color="primary"
|
||||||
|
title="{{ 'tooltips.Edit' | translate }}"
|
||||||
*ngIf="codeValueRowStatus[i] === 'disabled'"
|
*ngIf="codeValueRowStatus[i] === 'disabled'"
|
||||||
mat-icon-button
|
mat-icon-button
|
||||||
matTooltip="{{ 'tooltips.Edit' | translate }}"
|
matTooltip="{{ 'tooltips.Edit' | translate }}"
|
||||||
@@ -98,6 +112,7 @@
|
|||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
color="warn"
|
color="warn"
|
||||||
|
title="{{ 'tooltips.Delete' | translate }}"
|
||||||
mat-icon-button
|
mat-icon-button
|
||||||
matTooltip="{{ 'tooltips.Delete' | translate }}"
|
matTooltip="{{ 'tooltips.Delete' | translate }}"
|
||||||
*mifosxHasPermission="'DELETE_CODEVALUE'"
|
*mifosxHasPermission="'DELETE_CODEVALUE'"
|
||||||
|
|||||||
Reference in New Issue
Block a user