i18n: Adding new languages: Part 2 (#1885)
Co-authored-by: radhathakare <radhathakare322@gmail.com>
This commit is contained in:
co-authored by
radhathakare
parent
408f004450
commit
3c625d81c4
@@ -9,61 +9,61 @@
|
||||
<div fxLayout="column">
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Name</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.name' | translate }}</mat-label>
|
||||
<input matInput required autofocus formControlName="name">
|
||||
<mat-error *ngIf="holidayForm.controls.name.hasError('required')">
|
||||
Name <strong>is required</strong>
|
||||
{{ 'labels.inputs.name' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field (click)="fromDatePicker.open()">
|
||||
<mat-label>From Date</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.From Date' | translate }}</mat-label>
|
||||
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="fromDatePicker" required formControlName="fromDate">
|
||||
<mat-datepicker-toggle matSuffix [for]="fromDatePicker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #fromDatePicker></mat-datepicker>
|
||||
<mat-error *ngIf="holidayForm.controls.fromDate.hasError('required')">
|
||||
From Date <strong>is required</strong>
|
||||
{{ 'labels.inputs.From Date' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field (click)="toDatePicker.open()">
|
||||
<mat-label>To Date</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.To Date' | translate }}</mat-label>
|
||||
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="toDatePicker" required formControlName="toDate">
|
||||
<mat-datepicker-toggle matSuffix [for]="toDatePicker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #toDatePicker></mat-datepicker>
|
||||
<mat-error *ngIf="holidayForm.controls.toDate.hasError('required')">
|
||||
To Date <strong>is required</strong>
|
||||
{{ 'labels.inputs.To Date' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Repayment Scheduling Type</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.Repayment Scheduling Type' | translate }}</mat-label>
|
||||
<mat-select required formControlName="reschedulingType">
|
||||
<mat-option *ngFor="let repayments of repaymentSchedulingTypes" [value]="repayments.id">
|
||||
{{ repayments.value }}
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
<mat-error *ngIf="holidayForm.controls.reschedulingType.hasError('required')">
|
||||
Repayment Scheduling Type is <strong>required</strong>
|
||||
{{ 'labels.inputs.Repayment Scheduling Type' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field *ngIf="holidayForm.contains('repaymentsRescheduledTo')" (click)="repaymentDatePicker.open()">
|
||||
<mat-label>Repayment scheduled to</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.Repayment scheduled to' | translate }}</mat-label>
|
||||
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="repaymentDatePicker" required formControlName="repaymentsRescheduledTo">
|
||||
<mat-datepicker-toggle matSuffix [for]="repaymentDatePicker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #repaymentDatePicker></mat-datepicker>
|
||||
<mat-error *ngIf="holidayForm.controls.repaymentsRescheduledTo.hasError('required')">
|
||||
Repayment Scheduled To <strong>is required</strong>
|
||||
{{ 'labels.inputs.Repayment scheduled to' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Description</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.Description' | translate }}</mat-label>
|
||||
<input matInput formControlName="description">
|
||||
</mat-form-field>
|
||||
|
||||
<label>Select applicable offices</label>
|
||||
<label>{{ 'labels.inputs.Select applicable offices' | translate }}</label>
|
||||
|
||||
<mat-tree [dataSource]="dataSource" [treeControl]="treeControl">
|
||||
<mat-tree-node *matTreeNodeDef="let node" matTreeNodeToggle matTreeNodePadding>
|
||||
@@ -90,8 +90,8 @@
|
||||
</mat-card-content>
|
||||
|
||||
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
|
||||
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
|
||||
<button mat-raised-button color="primary" [disabled]="!holidayForm.valid" *mifosxHasPermission="'CREATE_HOLIDAY'">Submit</button>
|
||||
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
|
||||
<button mat-raised-button color="primary" [disabled]="!holidayForm.valid" *mifosxHasPermission="'CREATE_HOLIDAY'">{{'labels.buttons.Submit' | translate }}</button>
|
||||
</mat-card-actions>
|
||||
|
||||
</form>
|
||||
|
||||
@@ -9,57 +9,57 @@
|
||||
<div fxLayout="column">
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Name</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.name' | translate }}</mat-label>
|
||||
<input matInput required autofocus formControlName="name">
|
||||
<mat-error *ngIf="holidayForm.controls.name.hasError('required')">
|
||||
Name <strong>is required</strong>
|
||||
{{ 'labels.inputs.name' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field *ngIf="!isActiveHoliday" (click)="fromDatePicker.open()">
|
||||
<mat-label>From Date</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.From Date' | translate }}</mat-label>
|
||||
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="fromDatePicker" required formControlName="fromDate">
|
||||
<mat-datepicker-toggle matSuffix [for]="fromDatePicker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #fromDatePicker></mat-datepicker>
|
||||
<mat-error *ngIf="holidayForm.controls.fromDate.hasError('required')">
|
||||
From Date <strong>is required</strong>
|
||||
{{ 'labels.inputs.From Date' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field *ngIf="!isActiveHoliday" (click)="toDatePicker.open()">
|
||||
<mat-label>To Date</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.To Date' | translate }}</mat-label>
|
||||
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="toDatePicker" required formControlName="toDate">
|
||||
<mat-datepicker-toggle matSuffix [for]="toDatePicker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #toDatePicker></mat-datepicker>
|
||||
<mat-error *ngIf="holidayForm.controls.toDate.hasError('required')">
|
||||
To Date <strong>is required</strong>
|
||||
{{ 'labels.inputs.To Date' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field *ngIf="!isActiveHoliday">
|
||||
<mat-label>Repayment Scheduling Type</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.Repayment Scheduling Type' | translate }}</mat-label>
|
||||
<mat-select required formControlName="reschedulingType">
|
||||
<mat-option *ngFor="let repayments of holidayData.repaymentSchedulingTypes" [value]="repayments.id">
|
||||
{{ repayments.value }}
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
<mat-error *ngIf="holidayForm.controls.reschedulingType.hasError('required')">
|
||||
Repayment Scheduling Type is <strong>required</strong>
|
||||
{{ 'labels.inputs.Repayment Scheduling Type' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field *ngIf="!isActiveHoliday && reSchedulingType === 2" (click)="repaymentDatePicker.open()">
|
||||
<mat-label>Repayment scheduled to</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.Repayment scheduled to' | translate }}</mat-label>
|
||||
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="repaymentDatePicker" required formControlName="repaymentsRescheduledTo">
|
||||
<mat-datepicker-toggle matSuffix [for]="repaymentDatePicker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #repaymentDatePicker></mat-datepicker>
|
||||
<mat-error *ngIf="holidayForm.controls.repaymentsRescheduledTo.hasError('required')">
|
||||
Repayment Scheduled To <strong>is required</strong>
|
||||
{{ 'labels.inputs.Repayment scheduled to' | translate }} {{'labels.commons.is' | translate }} <strong>{{'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Description</mat-label>
|
||||
<mat-label>{{ 'labels.inputs.Description' | translate }}</mat-label>
|
||||
<input matInput formControlName="description">
|
||||
</mat-form-field>
|
||||
|
||||
@@ -68,8 +68,8 @@
|
||||
</mat-card-content>
|
||||
|
||||
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
|
||||
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
|
||||
<button mat-raised-button color="primary" [disabled]="!holidayForm.valid" *mifosxHasPermission="'UPDATE_HOLIDAY'">Submit</button>
|
||||
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
|
||||
<button mat-raised-button color="primary" [disabled]="!holidayForm.valid" *mifosxHasPermission="'UPDATE_HOLIDAY'">{{'labels.buttons.Submit' | translate }}</button>
|
||||
</mat-card-actions>
|
||||
|
||||
</form>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<div #buttonCreateHoliday class="in-block">
|
||||
<button mat-raised-button color="primary" [routerLink]="['create']" *mifosxHasPermission="'CREATE_HOLIDAY'">
|
||||
<fa-icon icon="plus" class="m-r-10"></fa-icon>
|
||||
Create Holiday
|
||||
{{'labels.buttons.Create Holiday' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
<input matInput (keyup)="applyFilter($event.target.value)">
|
||||
</mat-form-field>
|
||||
<mat-form-field>
|
||||
<mat-label> Select Office </mat-label>
|
||||
<mat-label> {{ 'labels.inputs.Select Office' | translate }} </mat-label>
|
||||
<mat-select [formControl]="officeSelector">
|
||||
<mat-option *ngFor="let office of officeData" [value]="office.id">
|
||||
{{ office.name }}
|
||||
@@ -33,27 +33,27 @@
|
||||
<table mat-table [dataSource]="dataSource" matSort>
|
||||
|
||||
<ng-container matColumnDef="name">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Holiday Name </th>
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Holiday Name' | translate }} </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.name }} </td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="fromDate">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Start Date </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.fromDate | dateFormat }} </td>
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Start Date' | translate }} </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.fromDate | dateFormat }} </td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="toDate">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> End Date </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.toDate | dateFormat }} </td>
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.End Date' | translate }} </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.toDate | dateFormat }} </td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="repaymentsRescheduledTo">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Repayments Scheduled To </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.reschedulingType === 1 ? 'Next Repayment Date' : holidays.repaymentsRescheduledTo | dateFormat }} </td>
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Repayments Scheduled To' | translate }} </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.reschedulingType === 1 ? 'Next Repayment Date' : holidays.repaymentsRescheduledTo | dateFormat }} </td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="status">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Status </th>
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Status' | translate }} </th>
|
||||
<td mat-cell *matCellDef="let holidays"> {{ holidays.status.value }} </td>
|
||||
</ng-container>
|
||||
|
||||
@@ -69,20 +69,20 @@
|
||||
</div>
|
||||
|
||||
<ng-template #templateButtonCreateHoliday let-popover="popover">
|
||||
<h2>Create Holiday</h2>
|
||||
<p class="mw300">This option allows you to create holidays for different offices in your organization.</p>
|
||||
<h2>{{'labels.heading.Create Holiday' | translate }}</h2>
|
||||
<p class="mw300">{{'labels.text.Create holidays for different offices' | translate }}</p>
|
||||
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
|
||||
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();previousStep();">Back</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateFilterRef,filterRef,'bottom', true);">Next</button>
|
||||
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate }}</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();previousStep();">{{'labels.buttons.Back' | translate }}</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateFilterRef,filterRef,'bottom', true);">{{'labels.buttons.Next' | translate }}</button>
|
||||
</div>
|
||||
</ng-template>
|
||||
|
||||
<ng-template #templateFilterRef let-popover="popover">
|
||||
<h4>Search bar to filter holidays based on different offices.</h4>
|
||||
<h4>{{'labels.heading.Filter holidays' | translate }}</h4>
|
||||
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
|
||||
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateButtonCreateHoliday,buttonCreateHoliday,'bottom', true);">Back</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();nextStep();">Next</button>
|
||||
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate }}</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateButtonCreateHoliday,buttonCreateHoliday,'bottom', true);">{{'labels.buttons.Back' | translate }}</button>
|
||||
<button mat-raised-button color="primary" (click)="popover.close();nextStep();">{{'labels.buttons.Next' | translate }}</button>
|
||||
</div>
|
||||
</ng-template>
|
||||
|
||||
@@ -2,16 +2,16 @@
|
||||
<span *mifosxHasPermission="'ACTIVATE_HOLIDAY'">
|
||||
<button mat-raised-button color="accent" (click)="activateHoliday()" *ngIf="holidayData.status.value !== 'Active'">
|
||||
<fa-icon icon="lock-open" class="m-r-10"></fa-icon>
|
||||
Activate
|
||||
{{'labels.buttons.Activate' | translate }}
|
||||
</button>
|
||||
</span>
|
||||
<button mat-raised-button color="primary" [routerLink]="['edit']" *mifosxHasPermission="'UPDATE_HOLIDAY'">
|
||||
<fa-icon icon="edit" class="m-r-10"></fa-icon>
|
||||
Edit
|
||||
{{'labels.buttons.Edit' | translate }}
|
||||
</button>
|
||||
<button mat-raised-button color="warn" (click)="deleteHoliday()" *mifosxHasPermission="'DELETE_HOLIDAY'">
|
||||
<fa-icon icon="trash" class="m-r-10"></fa-icon>
|
||||
Delete
|
||||
{{'labels.buttons.Delete' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
<div fxLayout="row wrap" class="content">
|
||||
|
||||
<div fxFlex="50%" class="header">
|
||||
Name
|
||||
{{ 'labels.inputs.Name' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%">
|
||||
@@ -32,7 +32,7 @@
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="header">
|
||||
From Date
|
||||
{{ 'labels.inputs.From Date' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%">
|
||||
@@ -40,7 +40,7 @@
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="header">
|
||||
To Date
|
||||
{{ 'labels.inputs.To Date' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%">
|
||||
@@ -48,7 +48,7 @@
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="header">
|
||||
Repayments Scheduled To
|
||||
{{ 'labels.inputs.Repayments Scheduled To' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" *ngIf="holidayData.repaymentsRescheduledTo !== undefined && holidayData.repaymentsRescheduledTo !== null">
|
||||
@@ -56,7 +56,7 @@
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" *ngIf="holidayData.repaymentsRescheduledTo === undefined || holidayData.repaymentsRescheduledTo === null">
|
||||
Next Repayment Date
|
||||
{{ 'labels.inputs.Next Repayment Date' | translate }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user