Deliver superior customer experiences with an AI-driven platform for creating and deploying cognitive chatbots
Deliver Awesome UI with the most complete toolboxes for .NET, Web and Mobile development
Automate UI, load and performance testing for web, desktop and mobile
A complete cloud platform for an app or your entire digital business
Detect and predict anomalies by automating machine learning to achieve higher asset uptime and maximized yield
Automate decision processes with a no-code business rules engine
Optimize data integration with high-performance connectivity
Connect to any cloud or on-premises data source using a standard interface
Build engaging multi-channel web and digital experiences with intuitive web content management
Personalize and optimize the customer experience across digital touchpoints
Build, protect and deploy apps across any platform and mobile device
Rapidly develop, manage and deploy business apps, delivered as SaaS in the cloud
The content you're reading is getting on in years
This post is on the older side and its content may be out of date.
Be sure to visit our blogs homepage for our latest news, updates and information.
When working with the content modules in Sitefinity, we can either directly publish items that we create, or save them as drafts. Those operations create some different versions of the same content behind the scenes, and use a concept that we call content lifecycle. In this blog post we are going to use the API to perform these operations and compare it with doing the same through the user interface.
Content lifecycle governs whether an item is visible in the frontend, and whether it is being edited. There are three lifecycle states of an item – master, temp and live. When persisting items in the database, Sitefinity creates one row for each state. You can think of lifecycle states as separate versions of an item. An important characteristic of lifecycle is that an item can be in more than one state at a time (can have several versions). The meaning of each state (item version) is defined in the following table:
The diagram shows how an item moves between the different lifecycle states. The circles represent states, and the arrows represent operations on the item. Each operation triggered by the user interface or API moves an item between states. As we mentioned, those states are actually different versions of an item. To illustrate this, let’s take a look at the state of the database and user interface after each operation. We will use the News module as an example
We’ve gone through the above steps by explicitly saving the item as draft to illustrate the lifecycle. We can also directly publish the item through the UI, and Sitefinity will perform the two operations together in the same order. There will be no difference in the state transitions between those two cases.
Understanding the concept of content lifecycle is important when working with items through the API. All the code samples in the Developers Guide take it into account. We also have a section which explains how to work with different item versions. Some item operations, however (like scheduling) cannot be performed through the lifecycle alone. They fall into the realm of workflow, which we’ll take a look at in another blog post.
View all posts from The Progress Team on the Progress blog. Connect with us about all things application development and deployment, data integration and digital business.
Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.
Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.