update document manifests
This commit is contained in:
@@ -1,18 +1,13 @@
|
||||
import { UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS } from '../repository/index.js';
|
||||
import { UMB_DOCUMENT_ENTITY_TYPE, UMB_DOCUMENT_ROOT_ENTITY_TYPE } from '../entity.js';
|
||||
import { UMB_DOCUMENT_ENTITY_TYPE } from '../entity.js';
|
||||
import { UmbPublishDocumentEntityAction } from './publish.action.js';
|
||||
import { UmbCreateDocumentBlueprintEntityAction } from './create-blueprint.action.js';
|
||||
import { UmbUnpublishDocumentEntityAction } from './unpublish.action.js';
|
||||
import { UmbRollbackDocumentEntityAction } from './rollback.action.js';
|
||||
import { manifests as createManifests } from './create/manifests.js';
|
||||
import { manifests as publicAccessManifests } from './public-access/manifests.js';
|
||||
import { manifests as cultureAndHostnamesManifests } from './culture-and-hostnames/manifests.js';
|
||||
import {
|
||||
UmbDuplicateEntityAction,
|
||||
UmbMoveEntityAction,
|
||||
UmbSortChildrenOfEntityAction,
|
||||
} from '@umbraco-cms/backoffice/entity-action';
|
||||
import type { ManifestTypes } from '@umbraco-cms/backoffice/extension-registry';
|
||||
import { UMB_DOCUMENT_PICKER_MODAL } from '@umbraco-cms/backoffice/modal';
|
||||
|
||||
const entityActions: Array<ManifestTypes> = [
|
||||
...createManifests,
|
||||
@@ -24,49 +19,35 @@ const entityActions: Array<ManifestTypes> = [
|
||||
name: 'Create Document Blueprint Entity Action',
|
||||
weight: 800,
|
||||
api: UmbCreateDocumentBlueprintEntityAction,
|
||||
kind: 'default',
|
||||
meta: {
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
icon: 'icon-blueprint',
|
||||
label: 'Create Document Blueprint (TBD)',
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
},
|
||||
},
|
||||
{
|
||||
type: 'entityAction',
|
||||
alias: 'Umb.EntityAction.Document.Move',
|
||||
name: 'Move Document Entity Action ',
|
||||
weight: 700,
|
||||
api: UmbMoveEntityAction,
|
||||
kind: 'move',
|
||||
meta: {
|
||||
icon: 'icon-enter',
|
||||
label: 'Move (TBD)',
|
||||
repositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
moveRepositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
itemRepositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
pickerModelAlias: UMB_DOCUMENT_PICKER_MODAL.toString(),
|
||||
},
|
||||
},
|
||||
{
|
||||
type: 'entityAction',
|
||||
alias: 'Umb.EntityAction.Document.Copy',
|
||||
name: 'Copy Document Entity Action',
|
||||
weight: 600,
|
||||
api: UmbDuplicateEntityAction,
|
||||
name: 'Duplicate Document Entity Action',
|
||||
kind: 'duplicate',
|
||||
meta: {
|
||||
icon: 'icon-documents',
|
||||
label: 'Copy (TBD)',
|
||||
repositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
},
|
||||
},
|
||||
{
|
||||
type: 'entityAction',
|
||||
alias: 'Umb.EntityAction.Document.Sort',
|
||||
name: 'Sort Document Entity Action',
|
||||
weight: 500,
|
||||
api: UmbSortChildrenOfEntityAction,
|
||||
meta: {
|
||||
icon: 'icon-navigation-vertical',
|
||||
label: 'Sort (TBD)',
|
||||
repositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
entityTypes: [UMB_DOCUMENT_ROOT_ENTITY_TYPE, UMB_DOCUMENT_ENTITY_TYPE],
|
||||
duplicateRepositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
itemRepositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
pickerModalAlias: UMB_DOCUMENT_PICKER_MODAL.toString(),
|
||||
},
|
||||
},
|
||||
{
|
||||
@@ -74,11 +55,11 @@ const entityActions: Array<ManifestTypes> = [
|
||||
alias: 'Umb.EntityAction.Document.Publish',
|
||||
name: 'Publish Document Entity Action',
|
||||
api: UmbPublishDocumentEntityAction,
|
||||
kind: 'default',
|
||||
meta: {
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
icon: 'icon-globe',
|
||||
label: 'Publish',
|
||||
repositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
},
|
||||
},
|
||||
{
|
||||
@@ -86,22 +67,11 @@ const entityActions: Array<ManifestTypes> = [
|
||||
alias: 'Umb.EntityAction.Document.Unpublish',
|
||||
name: 'Unpublish Document Entity Action',
|
||||
api: UmbUnpublishDocumentEntityAction,
|
||||
kind: 'default',
|
||||
meta: {
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
icon: 'icon-globe',
|
||||
label: 'Unpublish',
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
},
|
||||
},
|
||||
{
|
||||
type: 'entityAction',
|
||||
alias: 'Umb.EntityAction.Document.Rollback',
|
||||
name: 'Rollback Document Entity Action',
|
||||
api: UmbRollbackDocumentEntityAction,
|
||||
meta: {
|
||||
icon: 'icon-undo',
|
||||
label: 'Rollback (TBD)',
|
||||
repositoryAlias: UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS,
|
||||
entityTypes: [UMB_DOCUMENT_ENTITY_TYPE],
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
import type { UmbEntityActionArgs } from '@umbraco-cms/backoffice/entity-action';
|
||||
import { UmbEntityActionBase } from '@umbraco-cms/backoffice/entity-action';
|
||||
import type { UmbControllerHost } from '@umbraco-cms/backoffice/controller-api';
|
||||
|
||||
export class UmbRollbackDocumentEntityAction extends UmbEntityActionBase<never> {
|
||||
constructor(host: UmbControllerHost, args: UmbEntityActionArgs<never>) {
|
||||
super(host, args);
|
||||
}
|
||||
|
||||
async execute() {
|
||||
console.log(`execute for: ${this.args.unique}`);
|
||||
//await this.repository?.rollback();
|
||||
}
|
||||
|
||||
destroy(): void {}
|
||||
}
|
||||
Reference in New Issue
Block a user