Chapter 8. The Blend: create, update, and delete functionality

 

This chapter covers

  • Creating folders, documents, and document versions
  • Working with primary and secondary types
  • Updating properties and content
  • Optimistic locking and change tokens
  • Copying, moving, and deleting objects

In the last chapter, you learned how to read metadata and content from a CMIS repository. In this chapter, you’ll learn about adding, updating, and removing data. You’ll enhance the web pages that you built in the previous chapter and add new web pages to your version of The Blend.

8.1. Creating folders

In the previous chapter, we started out with folder browsing; in the opening section of this chapter we’ll tie in with that. We’ll extend the browse page with the capability to create a new subfolder in the folder that’s displayed.

The operations that create objects in CMIS need at least two pieces of information: the type of the object and a name for the object. If the object should be filed (and folders are always filed), they also need a parent folder. To let the user provide these details about the new folder, you’ll have to extend the browse page starting with this HTML, which you can place wherever you want on the page:

8.2. Creating documents

8.3. Updating properties

8.4. Updating and deleting content

8.5. Versioning

8.6. Copying documents

8.7. Moving objects

8.8. Deleting objects

8.9. Summary