@@ -0,0 +1,48 @@
|
||||
/** Angular Imports */
|
||||
import { Injectable } from '@angular/core';
|
||||
import { HttpClient, HttpParams } from '@angular/common/http';
|
||||
|
||||
/** rxjs Imports */
|
||||
import { Observable } from 'rxjs';
|
||||
|
||||
/**
|
||||
* Fixed Deposits Service.
|
||||
*/
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class FixedDepositsService {
|
||||
|
||||
constructor(private http: HttpClient) {}
|
||||
|
||||
/**
|
||||
* @param accountId Account Id of group to get data for.
|
||||
* @returns {Observable<any>} Fixed Deposits data.
|
||||
*/
|
||||
getFixedDepositsAccountData(accountId: string): Observable<any> {
|
||||
const httpParams = new HttpParams().set('associations', 'all');
|
||||
return this.http.get(`/fixeddepositaccounts/${accountId}`, { params: httpParams });
|
||||
}
|
||||
|
||||
/**
|
||||
* @param clientId Client Id
|
||||
* @param clientName Client Name
|
||||
* @param fromAccountId Account Id
|
||||
* @param locale Locale
|
||||
* @param dateFormat Date Format
|
||||
* @returns {Observable<any>} Standing Instructions
|
||||
*/
|
||||
getStandingInstructions(
|
||||
clientId: string, clientName: string, fromAccountId: string,
|
||||
locale: string, dateFormat: string): Observable<any> {
|
||||
const httpParams = new HttpParams()
|
||||
.set('clientId', clientId)
|
||||
.set('clientName', clientName)
|
||||
.set('fromAccountId', fromAccountId)
|
||||
.set('fromAccountType', '2')
|
||||
.set('locale', locale)
|
||||
.set('dateFormat', dateFormat);
|
||||
return this.http.get(`/standinginstructions`, { params: httpParams });
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user