@rero/ng-core
Version:
RERO angular core library.
36 lines (35 loc) • 1.51 kB
TypeScript
import { FormlyFieldConfig } from '@ngx-formly/core';
import { TranslateService } from '@ngx-translate/core';
import { ApiService } from '../../../api/api.service';
import { RecordService } from '../../record.service';
import { JSONSchema7 } from '../editor.component';
import * as i0 from "@angular/core";
export declare class JSONSchemaService {
protected translateService: TranslateService;
protected recordService: RecordService;
protected apiService: ApiService;
private customValidators;
processField(field: FormlyFieldConfig, jsonSchema: JSONSchema7): FormlyFieldConfig<import("@ngx-formly/core").FormlyFieldProps & {
[additionalProperties: string]: any;
}>;
/**
* Populate a select options with a remote API call.
* @param field formly field config
* @param formOptions JSONSchema object
*/
protected setRemoteSelectOptions(field: FormlyFieldConfig, formOptions: any): void;
/**
*
* @param field formly field config
* @param formOptions JSONSchema object
*/
protected setValidation(field: FormlyFieldConfig, formOptions: any): void;
/**
* Convert JSONSchema form options to formly field options.
* @param field formly field config
* @param formOptions JSONSchema object
*/
protected setSimpleOptions(field: FormlyFieldConfig, formOptions: any): void;
static ɵfac: i0.ɵɵFactoryDeclaration<JSONSchemaService, never>;
static ɵprov: i0.ɵɵInjectableDeclaration<JSONSchemaService>;
}