mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-12 17:04:57 +00:00
20 lines
626 B
TypeScript
20 lines
626 B
TypeScript
import { PluginInterface } from './plugin-model';
|
|
import { GovernanceHealth } from './governance-health';
|
|
|
|
export class GovernanceCheckPlugin {
|
|
governanceHealth: GovernanceHealth;
|
|
constructor(
|
|
private pluginInfo: PluginInterface,
|
|
private alfrescoJsApi: any
|
|
) {
|
|
this.governanceHealth = new GovernanceHealth(this.pluginInfo, this.alfrescoJsApi);
|
|
}
|
|
|
|
async checkRecordManagement() {
|
|
const isAvailable = await this.governanceHealth.isRecordManagementAvailable();
|
|
if (!isAvailable) {
|
|
await this.governanceHealth.createRecordManagementSite();
|
|
}
|
|
}
|
|
}
|