Class CreateWebPage
Page for creating a new web page.
[UIEvaluatePermission("View")]
[UINavigation(false)]
public sealed class CreateWebPage : CreateWebPageBase<CreateWebPageCreateCommandResult, ContentTypeSelectionModel>, IPage
- Inheritance
-
objectCreateWebPage
- Implements
- Inherited Members
- Extension Methods
Constructors
CreateWebPage(IFormComponentCommandInvoker, IAuthenticatedUserAccessor, IWebPageManagerFactory, IPageLinkGenerator, IContentItemDisplayNameValidator, IContentItemCommonDataInfoRetriever, IContentItemReferenceManagerCore, IInfoProvider<WebPageItemInfo>, IServiceProvider)
Initializes an instance of the CreateWebPage class.
public CreateWebPage(IFormComponentCommandInvoker formComponentCommandInvoker, IAuthenticatedUserAccessor authenticatedUserAccessor, IWebPageManagerFactory webPageManagerFactory, IPageLinkGenerator pageLinkGenerator, IContentItemDisplayNameValidator contentItemDisplayNameValidator, IContentItemCommonDataInfoRetriever contentItemCommonDataInfoRetriever, IContentItemReferenceManagerCore contentItemReferenceManagerCore, IInfoProvider<WebPageItemInfo> webPageItemInfoProvider, IServiceProvider serviceProvider)
Parameters
formComponentCommandInvoker
IFormComponentCommandInvokerauthenticatedUserAccessor
IAuthenticatedUserAccessorwebPageManagerFactory
IWebPageManagerFactorypageLinkGenerator
IPageLinkGeneratorcontentItemDisplayNameValidator
IContentItemDisplayNameValidatorcontentItemCommonDataInfoRetriever
IContentItemCommonDataInfoRetrievercontentItemReferenceManagerCore
IContentItemReferenceManagerCorewebPageItemInfoProvider
IInfoProvider<WebPageItemInfo>serviceProvider
IServiceProvider
Methods
CascadePublish(CreateWebPageCreateCommandArguments, CancellationToken)
Creates new web page and redirects to the publish page.
[Obsolete("Use Publish command instead.")]
[ObsoleteSince(29, 1)]
public override Task<ICommandResponse> CascadePublish(CreateWebPageCreateCommandArguments args, CancellationToken cancellationToken = default)
Parameters
args
CreateWebPageCreateCommandArgumentsCreate web page command arguments.
cancellationToken
CancellationTokenCancellation instruction.
Returns
- Task<ICommandResponse>
Change(CreateWebPageCreateCommandArguments, CancellationToken)
Handles the form change command. The command is invoked whenever visibility conditions or form component configurators of the form need to be reevaluated to re-render the form.
public override Task<ICommandResponse<FormChangeResult>> Change(CreateWebPageCreateCommandArguments args, CancellationToken cancellationToken = default)
Parameters
args
CreateWebPageCreateCommandArgumentsForm change arguments.
cancellationToken
CancellationTokenCancellation instruction.
Returns
- Task<ICommandResponse<FormChangeResult>>
ChangeWorkflowStep(CreateWebPageCreateCommandArguments, CancellationToken)
Create a new web page language variant as the initial draft and redirects to the change workflow step UI.
public override Task<ICommandResponse> ChangeWorkflowStep(CreateWebPageCreateCommandArguments args, CancellationToken cancellationToken = default)
Parameters
args
CreateWebPageCreateCommandArgumentsCreate web page command arguments.
cancellationToken
CancellationTokenCancellation instruction.
Returns
- Task<ICommandResponse>
ConfigurePage()
Allows configure and share page specific values prior invocation of the ConfigureTemplateProperties(TClientProperties) or command method.
public override Task ConfigurePage()
Returns
- Task
ConfigureTemplateProperties(CreateWebPageClientProperties)
Gets the object representing client side template properties.
public override Task<CreateWebPageClientProperties> ConfigureTemplateProperties(CreateWebPageClientProperties properties)
Parameters
properties
CreateWebPageClientPropertiesInitialized properties object.
Returns
Create(CreateWebPageCreateCommandArguments, CancellationToken)
Creates the web page language variant.
public override Task<ICommandResponse<CreateWebPageCreateCommandResult>> Create(CreateWebPageCreateCommandArguments args, CancellationToken cancellationToken = default)
Parameters
args
CreateWebPageCreateCommandArgumentsCreate web page command arguments.
cancellationToken
CancellationTokenCancellation instruction.
Returns
CreateInternal(CreateWebPageCreateCommandArguments, List<IFormComponent>, bool, CancellationToken)
Creates the web page and returns response.
protected override Task<ICommandResponse<CreateWebPageCreateCommandResult>> CreateInternal(CreateWebPageCreateCommandArguments args, List<IFormComponent> formComponents, bool publish, CancellationToken cancellationToken = default)
Parameters
args
CreateWebPageCreateCommandArgumentsForm submission arguments.
formComponents
List<IFormComponent>Form components.
publish
boolIndicates whether the web page should also be immediately published.
cancellationToken
CancellationTokenCancellation instruction.
Returns
Discard()
Discards the unsaved draft of web page and redirects back to the parent page.
public Task<INavigateResponse> Discard()
Returns
- Task<INavigateResponse>
GetChangeWorkflowStepPageUrl(int)
Returns change workflow step page URL for given webPageId
.
protected override string GetChangeWorkflowStepPageUrl(int webPageId)
Parameters
webPageId
intWeb page identifier.
Returns
- string
GetPublishPageUrl(int)
Returns publish page URL for given webPageId
.
protected override string GetPublishPageUrl(int webPageId)
Parameters
webPageId
intWeb page identifier.
Returns
- string
GetUrlComponents(CreateWebPageCreateCommandArguments, bool)
Gets URL slug edit components.
protected override Task<ICollection<IFormItem>> GetUrlComponents(CreateWebPageCreateCommandArguments args, bool useExistingValue)
Parameters
args
CreateWebPageCreateCommandArgumentsCreate web page command arguments.
useExistingValue
boolIndicates if the URL slug component should be pre-filled with existing value.
Returns
- Task<ICollection<IFormItem>>
Publish(CreateWebPageCreateCommandArguments, CancellationToken)
Creates new web page and redirects to the publish page.
public override Task<ICommandResponse<CreateWebPageCreateCommandResult>> Publish(CreateWebPageCreateCommandArguments args, CancellationToken cancellationToken = default)
Parameters
args
CreateWebPageCreateCommandArgumentsCreate web page command arguments.
cancellationToken
CancellationTokenCancellation instruction.
Returns
SubmitFirstStep(FormSubmissionCommandArguments, CancellationToken)
Confirms the selection of web page parameters.
public override Task<ICommandResponse<ICreateWebPageStepCommandResult>> SubmitFirstStep(FormSubmissionCommandArguments args, CancellationToken cancellationToken = default)
Parameters
args
FormSubmissionCommandArgumentsConfirm selection form command arguments.
cancellationToken
CancellationTokenCancellation instruction.
Returns
SubmitSecondStep(CreateWebPageCreateCommandArguments, CancellationToken)
Confirms the selection of web page parameters.
public override Task<ICommandResponse<ICreateWebPageStepCommandResult>> SubmitSecondStep(CreateWebPageCreateCommandArguments args, CancellationToken cancellationToken = default)
Parameters
args
CreateWebPageCreateCommandArgumentsSelected data form command arguments.
cancellationToken
CancellationTokenCancellation instruction.
Returns
ValidateDisplayName(RenameCommandArguments)
Validates the content item display name.
public override Task<ICommandResponse<RenameCommandResult>> ValidateDisplayName(RenameCommandArguments args)
Parameters
args
RenameCommandArgumentsRename command arguments.