Update dashboard table reports (#1653)
Co-authored-by: Jose Alberto Hernandez <alberto@MacBook-Pro.local>
This commit is contained in:
co-authored by
Jose Alberto Hernandez
parent
e61f4f92e3
commit
9ed38f0f7b
@@ -5,6 +5,7 @@ import { HttpClient, HttpParams } from '@angular/common/http';
|
||||
/** rxjs Imports */
|
||||
import { Observable } from 'rxjs';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
import { SettingsService } from 'app/settings/settings.service';
|
||||
|
||||
/**
|
||||
* Loans service.
|
||||
@@ -14,6 +15,7 @@ import { Dates } from 'app/core/utils/dates';
|
||||
})
|
||||
export class LoansService {
|
||||
constructor(private http: HttpClient,
|
||||
private settingsService: SettingsService,
|
||||
private dateUtils: Dates) { }
|
||||
/**
|
||||
* @param {string} loanId loanId of the loan.
|
||||
@@ -28,6 +30,15 @@ export class LoansService {
|
||||
return this.http.get(`/loans/${loanId}/transactions/template`, { params: httpParams });
|
||||
}
|
||||
|
||||
getLoanForeclosureActionTemplate(loanId: string): Observable<any> {
|
||||
const httpParams = new HttpParams()
|
||||
.set('command', 'foreclosure')
|
||||
.set('locale', this.settingsService.language.code)
|
||||
.set('dateFormat', this.settingsService.dateFormat)
|
||||
.set('transactionDate', this.dateUtils.formatDate(this.settingsService.businessDate, this.settingsService.dateFormat))
|
||||
return this.http.get(`/loans/${loanId}/transactions/template`, { params: httpParams });
|
||||
}
|
||||
|
||||
getLoanAccountResource(loanId: string, associations: string): Observable<any> {
|
||||
const httpParams = new HttpParams().set('associations', associations);
|
||||
return this.http.get(`/loans/${loanId}`, { params: httpParams });
|
||||
|
||||
Reference in New Issue
Block a user