Accounting translate module (#1799)

* feat:Accounting Translate Module

* feat:Accounting Translate Module Updated Chart Account
This commit is contained in:
RADHA THAKARE
2023-09-15 14:15:42 -06:00
committed by GitHub
parent f997f39094
commit 02bae35c33
27 changed files with 400 additions and 398 deletions
@@ -9,18 +9,18 @@
<div fxLayout="column">
<mat-form-field fxFlex (click)="datePicker.open()">
<mat-label>Date</mat-label>
<mat-label>{{"labels.inputs.Date" |translate}}</mat-label>
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="datePicker" required formControlName="date">
<mat-datepicker-toggle matSuffix [for]="datePicker"></mat-datepicker-toggle>
<mat-datepicker #datePicker></mat-datepicker>
<mat-error *ngIf="provisioningEntryForm.controls.date.hasError('required')">
Date is <strong>required</strong>
{{"labels.inputs.Date" |translate}} {{ "labels.commons.is" |translate}} <strong>{{ "labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<div fxFlex>
<mat-checkbox labelPosition="before" formControlName="createjournalentries">
Create Journal Entries
{{"labels.inputs.Create Journal Entries" |translate}}
</mat-checkbox>
</div>
@@ -29,8 +29,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]="!provisioningEntryForm.valid" *mifosxHasPermission="'CREATE_PROVISIONING_ENTRIES'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{ "labels.buttons.Cancel" | translate}}</button>
<button mat-raised-button color="primary" [disabled]="!provisioningEntryForm.valid" *mifosxHasPermission="'CREATE_PROVISIONING_ENTRIES'">{{"labels.buttons.Submit" | translate}}</button>
</mat-card-actions>
</form>
@@ -1,7 +1,7 @@
<div class="container m-b-20" fxLayout="row" fxLayoutAlign="end" fxLayoutGap="20px">
<button mat-raised-button color="primary" [routerLink]="['create']" *mifosxHasPermission="'VIEW_ALL_PROVISIONING_ENTRIES'">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Create Provisioning Entry
{{"labels.buttons.Create Provisioning Entry" |translate}}
</button>
</div>
@@ -19,45 +19,45 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="createdUser">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Created By </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Created By" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.createdUser }} </td>
</ng-container>
<ng-container matColumnDef="createdDate">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Created On </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Created On" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.createdDate }} </td>
</ng-container>
<ng-container matColumnDef="journalEntry">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Journal Entry Created </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Journal Entry Created" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry">
<mat-checkbox [disabled]="true" [checked]="provisioningEntry.journalEntry"></mat-checkbox>
</td>
</ng-container>
<ng-container matColumnDef="viewReport">
<th mat-header-cell *matHeaderCellDef> View Report </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.View Report" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry">
<button mat-button color="primary" [routerLink]="['view', provisioningEntry.id]">
<fa-icon icon="eye" class="m-r-10"></fa-icon>View
<fa-icon icon="eye" class="m-r-10"></fa-icon>{{"labels.buttons.View" |translate}}
</button>
</td>
</ng-container>
<ng-container matColumnDef="recreateProvisioning">
<th mat-header-cell *matHeaderCellDef> Recreate Provisioning </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Recreate Provisioning" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry">
<button mat-button (click)="recreateProvisioning($event, provisioningEntry.id)" [disabled]="provisioningEntry.journalEntry" color="primary">
<fa-icon icon="edit" class="m-r-10"></fa-icon>Recreate
<fa-icon icon="edit" class="m-r-10"></fa-icon>{{"labels.buttons.Recreate" |translate}}
</button>
</td>
</ng-container>
<ng-container matColumnDef="viewJournalEntry">
<th mat-header-cell *matHeaderCellDef> View Journal Entry </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.View Journal Entry" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry">
<button mat-button (click)="viewJournalEntry($event, provisioningEntry.id)" [disabled]="!provisioningEntry.journalEntry" color="primary">
<fa-icon icon="eye" class="m-r-10"></fa-icon>View
<fa-icon icon="eye" class="m-r-10"></fa-icon>{{"labels.buttons.View" |translate}}
</button>
</td>
</ng-container>
@@ -3,7 +3,7 @@
<div class="m-b-20" fxLayout="row" fxLayoutAlign="end" fxLayoutGap="20px">
<button mat-raised-button color="primary" (click)="createProvisioningJournalEntries()" [disabled]="provisioningEntry.journalEntry" *mifosxHasPermission="'CREATE_JOURNAL_ENTRY'">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Create Journal Entries
{{"labels.buttons.Create Journal Entries" |translate}}
</button>
</div>
@@ -14,7 +14,7 @@
<div fxLayout="row wrap" class="content" fxLayout.lt-md="column">
<div fxFlex="16%" class="header">
Created By
{{"labels.inputs.Created By" |translate}}
</div>
<div fxFlex="16%">
@@ -22,7 +22,7 @@
</div>
<div fxFlex="16%" class="header">
Created On
{{"labels.inputs.Created On" |translate}}
</div>
<div fxFlex="16%">
@@ -30,7 +30,7 @@
</div>
<div fxFlex="18%" class="header">
Amount to be Reserved
{{"labels.inputs.Amount to be Reserved" |translate}}
</div>
<div fxFlex="18%">
@@ -49,17 +49,17 @@
<div class="container m-t-20" fxLayout="row wrap" fxLayoutGap="2%" fxLayout.lt-md="column">
<mat-form-field fxFlex="31%">
<mat-label>Office Name</mat-label>
<mat-label>{{"labels.inputs.Office Name" |translate}}</mat-label>
<input matInput [formControl]="officeName" [matAutocomplete]="officeNameAutocomplete">
</mat-form-field>
<mat-form-field fxFlex="31%">
<mat-label>Loan Product</mat-label>
<mat-label>{{"labels.inputs.Loan Product" |translate}}</mat-label>
<input matInput [formControl]="loanProduct" [matAutocomplete]="loanProductAutocomplete">
</mat-form-field>
<mat-form-field fxFlex="31%">
<mat-label>Provisioning Category</mat-label>
<mat-label>{{"labels.inputs.Provisioning Category" |translate}}</mat-label>
<input matInput [formControl]="provisioningCategory" [matAutocomplete]="provisioningCategoryAutocomplete">
</mat-form-field>
@@ -91,37 +91,37 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="officeName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Office Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Office Name" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.officeName }} </td>
</ng-container>
<ng-container matColumnDef="productName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Product Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Product Name" |translate}}</th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.productName }} </td>
</ng-container>
<ng-container matColumnDef="currencyCode">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Currency Code </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Currency Code" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.currencyCode }} </td>
</ng-container>
<ng-container matColumnDef="categoryName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Category Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Category Name" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.categoryName }} </td>
</ng-container>
<ng-container matColumnDef="amountreserved">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Provisioning Amount </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Provisioning Amount" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.amountreserved }} </td>
</ng-container>
<ng-container matColumnDef="liabilityAccountName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Liability Account (CR) </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Liability Account (CR)" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.liabilityAccountName }} </td>
</ng-container>
<ng-container matColumnDef="expenseAccountName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Expense Account (DR) </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Expense Account (DR)" |translate}} </th>
<td mat-cell *matCellDef="let provisioningEntry"> {{ provisioningEntry.expenseAccountName }} </td>
</ng-container>
@@ -12,52 +12,52 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="id">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Entry ID </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Entry ID" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.id }} </td>
</ng-container>
<ng-container matColumnDef="officeName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Office </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Office" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.officeName }} </td>
</ng-container>
<ng-container matColumnDef="transactionDate">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Transaction Date </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Transaction Date" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.transactionDate }} </td>
</ng-container>
<ng-container matColumnDef="transactionId">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Transaction ID </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Transaction ID" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.transactionId }} </td>
</ng-container>
<ng-container matColumnDef="glAccountType">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Type </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Type" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.glAccountType.value }} </td>
</ng-container>
<ng-container matColumnDef="createdByUserName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Type </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Type" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.createdByUserName }} </td>
</ng-container>
<ng-container matColumnDef="glAccountCode">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Account Code </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Account Code" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.glAccountCode }} </td>
</ng-container>
<ng-container matColumnDef="glAccountName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Account Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Account Name" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"> {{ provisioningJournalEntry.glAccountName }} </td>
</ng-container>
<ng-container matColumnDef="debit">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Debit </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Debit" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"><span *ngIf="provisioningJournalEntry.entryType.value === 'DEBIT'"> {{ (provisioningJournalEntry.currency.displaySymbol || provisioningJournalEntry.currency.code) + ' ' + provisioningJournalEntry.amount }} </span></td>
</ng-container>
<ng-container matColumnDef="credit">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Credit </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Credit" |translate}} </th>
<td mat-cell *matCellDef="let provisioningJournalEntry"><span *ngIf="provisioningJournalEntry.entryType.value === 'CREDIT'"> {{ (provisioningJournalEntry.currency.displaySymbol || provisioningJournalEntry.currency.code) + ' ' + provisioningJournalEntry.amount }} </span></td>
</ng-container>