import { OnDestroy } from '@angular/core'; import { CoreBaseFormService } from '../../providers/services/base-form.service'; import { CoreSessionService } from '../../providers/services/session.service'; import { Router } from '@angular/router'; import { FormBuilder, FormGroup } from '@angular/forms'; import { CoreCommonService } from '../../providers/services/common.service'; import { ApiSchema } from '../../models/interfaces'; import { CoreDataShareService } from '../../providers/services/data-share.service'; import { CoreHttpService } from '../../utilities/services/http.service'; import { CoreUtilityService } from '../../utilities/services/utility.service'; import { CoreNetworkAwarePreloadStrategy } from '../../utilities/network-aware-preload-strategy.service'; import { SubSink } from 'subsink'; export declare class CoreComponent implements OnDestroy { environment: any; fields: Array; protected coreBaseService: CoreBaseFormService; coreSessionService: CoreSessionService; protected router: Router; protected formBuilder: FormBuilder; currentFormGroup: FormGroup; protected currentModuleName: string; currentModule: object; protected coreCommonService: CoreCommonService; coreUtilityService: CoreUtilityService; protected coreDataShareService: CoreDataShareService; protected coreHttpService: CoreHttpService; imagePath: string; eventSubscriptionsList$: SubSink; currentModuleButtons: object; apiEndPoint: ApiSchema; coreConnectionService: CoreNetworkAwarePreloadStrategy; primaryApplicantDetails: any; constructor(environment: any); /** * This method will check screte key is matching or not */ private verifySecretKey; /** * This method will initialize the base form * @param moduleName - module name */ protected initBaseForm(moduleName: string): Promise; /** * This method will initialize all the required dependency injections */ private coreInitDependencyInjection; /** * This method will initialize the constant values */ private initConstants; /** * This method will get the schema based on module * @param moduleName - current module name */ private handleFormLoad; /** * This method will assign schema received from the server * @param currentModuleSchema - current module schema */ private assignSchema; /** * this method will get page schema from the server * @param moduleName - module name */ private getPageSchema; /** * This method will set the current module schema to session object * @param moduleObject - module object */ private setCurrentModuleToSession; /** * This method will provide the next module name as per status flow */ protected getNextModuleName(): any; /** * This method will call the save api to save the data * @param url - save api url */ saveApplicantModule(url: string, params?: object): Promise; /** * This method will get the api associated with that module schema * @param apiName - api name * @param schema - schema data */ /** * This method will be called post page load and populate the form * @param form - form data * @param checkForSavedData - flag to check the page is loaded properly or not */ postPageLoadActivities(form: FormGroup, checkForSavedData?: boolean): void; /** * This method will populate the form * @param form - form */ checkAndPopulateForm(form: FormGroup): Promise; /** * This method will mark the fields of form as touched/dirty * @param formGroup - form */ protected touchAllFields(formGroup: FormGroup): boolean; /** * This method will fetch the current module name shown on screen */ protected getAllModules(): Array; /** * This method will get data base on api name * @param currentModule - current module name * @param apiName - api name */ getDataFromApiName(currentModule: object, apiName: string): Promise; /** * This method will set the form group * @param form - form */ setFormGroup(form: FormGroup): boolean; /** * This method will filter the schema based on accessibility * @param actualSchema - original schema */ private filterControlsOnDomain; /** * This method will check for the form value changes */ formValueChanges(): void; /** * This method will hide/show add applicant button based on curr app displayed */ showPrimarySelection(): boolean; /** * This method will hide/show copy primary appc data checkbox based on config * @param moduleName - name of service */ getProductConfigFlags(moduleName: any): boolean; /** * Save Response data to session */ saveRespToSession(params: any, responseValue: any): boolean; /** * Scroll user to invalid form fields * @param form current form */ scrollToInvalidForm(form: any): void; /** * The trackBy function takes the index and the current item as arguments * and needs to return the unique identifier for this item * @param index - item index */ trackByFn(index: number, item: any): number; /** * Unsubscribe Observables and detach event handlers to avoid memory leaks */ ngOnDestroy(): void; }