• Share
    • Twitter
    • LinkedIn
    • Facebook
    • Email
  • Feedback
  • Improve this Doc

Interface IWorkflowManager

This class is responsible to manage the workflows of the portal. It provides CRUD operation methods and methods to know the usage of the workflow.

Namespace: DotNetNuke.Entities.Content.Workflow
Assembly: DotNetNuke.dll
Syntax
public interface IWorkflowManager

Methods

| Improve this Doc View Source

AddWorkflow(Workflow)

This method adds a new workflow. It automatically add two system states: "Draft" and "Published".

Declaration
void AddWorkflow(Workflow workflow)
Parameters
Type Name Description
Workflow workflow

Workflow Entity.

Exceptions
Type Condition
WorkflowNameAlreadyExistsException

Thrown when a workflow with the same name already exist for the portal.

| Improve this Doc View Source

DeleteWorkflow(Workflow)

This method hard deletes a workflow.

Declaration
void DeleteWorkflow(Workflow workflow)
Parameters
Type Name Description
Workflow workflow

Workflow Entity.

Exceptions
Type Condition
WorkflowInvalidOperationException

Thrown when a workflow is in use or is a system workflow.

| Improve this Doc View Source

GetWorkflow(ContentItem)

This method returns a workflow entity by Content Item Id. It returns null if the Content Item is not under workflow.

Declaration
Workflow GetWorkflow(ContentItem contentItem)
Parameters
Type Name Description
ContentItem contentItem

Content Item.

Returns
Type Description
Workflow

Workflow Entity.

| Improve this Doc View Source

GetWorkflow(Int32)

This method returns a workflow entity by Id.

Declaration
Workflow GetWorkflow(int workflowId)
Parameters
Type Name Description
System.Int32 workflowId

Workflow Id.

Returns
Type Description
Workflow

Workflow Entity.

| Improve this Doc View Source

GetWorkflows(Int32)

This method return the list of the Workflows defined for the portal.

Declaration
IEnumerable<Workflow> GetWorkflows(int portalId)
Parameters
Type Name Description
System.Int32 portalId

Portal Id.

Returns
Type Description
IEnumerable<Workflow>

List of the Workflows for the portal.

| Improve this Doc View Source

GetWorkflowUsage(Int32, Int32, Int32)

This method returns the paginated list of Items that are associated with a workflow.

Declaration
IEnumerable<WorkflowUsageItem> GetWorkflowUsage(int workflowId, int pageIndex, int pageSize)
Parameters
Type Name Description
System.Int32 workflowId

Workflow Id.

System.Int32 pageIndex

Page index (where 1 is the index of the first page).

System.Int32 pageSize

Page size.

Returns
Type Description
IEnumerable<WorkflowUsageItem>

List of Usage Items.

| Improve this Doc View Source

GetWorkflowUsageCount(Int32)

This method returns the total number of Content Items that are associated with any State of a workflow (even the Published state).

Declaration
int GetWorkflowUsageCount(int workflowId)
Parameters
Type Name Description
System.Int32 workflowId

Workflow Id.

Returns
Type Description
System.Int32

Total count of Content Items that are using the specified workflow.

| Improve this Doc View Source

UpdateWorkflow(Workflow)

this method update a existing workflow.

Declaration
void UpdateWorkflow(Workflow workflow)
Parameters
Type Name Description
Workflow workflow

Workflow Entity.

Exceptions
Type Condition
WorkflowNameAlreadyExistsException

Thrown when a workflow with the same name already exist for the portal.

Extension Methods

JsonExtensionsWeb.ToJson(Object)
  • View Source
Back to top by the community, for the community... #DNNCMS