FINERACT-1724: Server-side pagination support for clients screen
This commit is contained in:
committed by
Arnold Gálovics
parent
517584280f
commit
aa438ed4b2
@@ -381,4 +381,26 @@ export class ClientsService {
|
||||
getCollateralTemplate(clientId: any) {
|
||||
return this.http.get(`/clients/${clientId}/collaterals/template`);
|
||||
}
|
||||
|
||||
searchByText(text: string, page: number, pageSize: number, sortAttribute: string = '', sortDirection: string = '') {
|
||||
let request: any = {
|
||||
request: {
|
||||
text
|
||||
},
|
||||
page,
|
||||
size: pageSize
|
||||
}
|
||||
if (sortAttribute !== '' && sortDirection !== '') {
|
||||
request = {
|
||||
...request,
|
||||
sorts: [
|
||||
{
|
||||
direction: sortDirection,
|
||||
property: sortAttribute
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
return this.http.post(`/v2/clients/search`, request);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user