e5core-angular-ui
Version:
e5 Anywhere Angular UI
31 lines (30 loc) • 1.56 kB
TypeScript
import { IDataSource } from './data-source';
import { Observable } from 'rxjs';
import { UiSearchDefinitionService, WorkSearchFoundationService } from 'e5core-angular-services';
import { DataSourceColumn } from './data-source-column';
import { DataSourceResults } from './data-source-results';
import { SearchDataSourceOptions } from './search-data-source-options';
import { DataSourceOptions } from './data-source-options';
export declare class SearchDataSourceService implements IDataSource {
private searchDefinitionService;
private searchService;
readonly SlaExpiryColumnCode = "_SLAExpiryStatus";
readonly NextTaskColumnCode = "_NextDueTask";
searchDefinitionId: number;
searchOptions: SearchDataSourceOptions;
constructor(searchDefinitionService: UiSearchDefinitionService, searchService: WorkSearchFoundationService);
defaultOptions(): DataSourceOptions;
setDefaultOptions(options: DataSourceOptions): void;
setSearchDefinitionId(id: number): SearchDataSourceService;
columns(): Observable<DataSourceColumn[]>;
private addOptionalColumns;
read(page: number, pageSize: number, optionsIn: DataSourceOptions): Observable<DataSourceResults>;
/**
* The data that comes back from the API is a columns defintion and an array
* of array of data. We need to map this into an array of objects with the column property
* id as the object key so that it's easier to handle by the table.
* @param model
*/
private mapResults;
private mapQueryToFilterBy;
}