Author API Methods
editItem()
Navigates to the Item editor and loads the specified Item.
You would want to use this method so that you can build a custom Item edit button in your own application, for example.
Examples
authorApp.editItem('My Item reference to edit');
Arguments
-
itemReference string
The Item reference used to identify the Item.
Maximum length is 150 characters.
-
create boolean
Controls the behavior when the specified
itemReferenceis not found in the Item bank.This argument is not supported in the Activity editor view.
Default:
falsePossible values
-
trueA new Item will be created with the passed
itemReferenceas its reference. -
falseThe operation will fail with an error indicating that the
itemReferencecould not be found.
-
Return value
None (undefined).
Caveats
In cases where the author has access to multiple Item banks, the specified Item to be edited must belong to the current API Consumer that initialized Author API. See Security and Authentication for more information.
Related articles
- The
createItem()method, which navigates to a new Item editor view, ready for an author to create a new Item.