mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-4529] Enable form configuration from e2e tests (#4738)
* [ADF-4529] Enable form configuration from e2e tests * Improve linting * Move form methods to new file
This commit is contained in:
committed by
Eugenio Romano
parent
36faed0fab
commit
f2f08a5bf8
@@ -20,11 +20,14 @@ import { AppConfigService } from '../app-config/app-config.service';
|
||||
import { AlfrescoApiService } from '../services/alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { UserPreferencesService } from './user-preferences.service';
|
||||
import { DemoForms } from '../mock/form/demo-form.mock';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class CoreAutomationService {
|
||||
forms = new DemoForms();
|
||||
|
||||
constructor(private appConfigService: AppConfigService,
|
||||
private alfrescoApiService: AlfrescoApiService,
|
||||
private userPreferencesService: UserPreferencesService,
|
||||
@@ -46,6 +49,14 @@ export class CoreAutomationService {
|
||||
this.userPreferencesService.set(key, data);
|
||||
};
|
||||
|
||||
adfProxy.setFormInEditor = (json: string) => {
|
||||
this.forms.formDefinition = JSON.parse(json);
|
||||
};
|
||||
|
||||
adfProxy.setCloudFormInEditor = (json: string) => {
|
||||
this.forms.cloudFormDefinition = JSON.parse(json);
|
||||
};
|
||||
|
||||
adfProxy.clearStorage = () => {
|
||||
this.storageService.clear();
|
||||
};
|
||||
|
Reference in New Issue
Block a user