mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-09-17 14:21:29 +00:00
refactor content
This commit is contained in:
@@ -35,18 +35,19 @@ import { map, catchError } from 'rxjs/operators';
|
||||
})
|
||||
export class ActivitiContentService {
|
||||
|
||||
get integrationAlfrescoOnPremiseApi(): IntegrationAlfrescoOnPremiseApi {
|
||||
return new IntegrationAlfrescoOnPremiseApi(this.apiService.getInstance());
|
||||
}
|
||||
get contentApi(): ActivitiContentApi {
|
||||
return new ActivitiContentApi(this.apiService.getInstance());
|
||||
}
|
||||
|
||||
static UNKNOWN_ERROR_MESSAGE: string = 'Unknown error';
|
||||
static GENERIC_ERROR_MESSAGE: string = 'Server error';
|
||||
|
||||
integrationAlfrescoOnPremiseApi: IntegrationAlfrescoOnPremiseApi;
|
||||
contentApi: ActivitiContentApi;
|
||||
|
||||
constructor(private apiService: AlfrescoApiService,
|
||||
private logService: LogService,
|
||||
private sitesService: SitesService) {
|
||||
|
||||
this.integrationAlfrescoOnPremiseApi = new IntegrationAlfrescoOnPremiseApi(this.apiService.getInstance());
|
||||
this.contentApi = new ActivitiContentApi(this.apiService.getInstance());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -30,20 +30,22 @@ import {
|
||||
import { TaskProcessVariableModel } from '../models/task-process-variable.model';
|
||||
import { WidgetVisibilityModel, WidgetTypeEnum } from '../models/widget-visibility.model';
|
||||
import { map, catchError } from 'rxjs/operators';
|
||||
import { TaskFormsApi } from '@alfresco/js-api';
|
||||
import { RuntimeAppDefinitionsApi, TaskFormsApi } from '@alfresco/js-api';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class WidgetVisibilityService {
|
||||
|
||||
private taskFormsApi: TaskFormsApi;
|
||||
get taskFormsApi(): TaskFormsApi {
|
||||
return new TaskFormsApi(this.apiService.getInstance());
|
||||
}
|
||||
|
||||
private processVarList: TaskProcessVariableModel[];
|
||||
private form: FormModel;
|
||||
|
||||
constructor(private apiService: AlfrescoApiService,
|
||||
private logService: LogService) {
|
||||
this.taskFormsApi = new TaskFormsApi(this.apiService.getInstance());
|
||||
}
|
||||
|
||||
public refreshVisibility(form: FormModel, processVarList?: TaskProcessVariableModel[]) {
|
||||
|
Reference in New Issue
Block a user