Develop Custom Field Editors Using the Oracle Content Management Toolkit
Oracle Content Management Toolkit provides support for developing components of the Field Appearance type. Developers can create and manage custom field editors.
For a component of the Field Appearance type, you can do the following tasks:
- Open, copy, or delete the component
- Publish or unpublish the component
- Export or import the component
- Add or remove members on the component
- View properties
- Choose the component logo
You can filter a list of components by the Field Appearance type.
The following Content Toolkit commands are available for developing custom field editors:
cec add-field-editor <name> Adds a field editor to a field in a content type. [alias: afe]
cec remove-field-editor <name> Removes a field editor from a field in a content type. [alias: rfe]
------------------------
cec add-field-editor
------------------------
Usage: cec add-field-editor <name>
Adds a field editor to a field in a content type.
Options:
--template, -t The template the content type is from [required]
--contenttype, -c The content type [required]
--field, -f The field the field editor is for [required]
--contenttemplate, -n Flag to indicate the template is a content template
--help, -h Show help [boolean]
Examples:
cec add-field-editor editor1 -t BlogTemplate -c BlogPost -f summary Use editor1 as the appearance for field summary in content type BlogPost from local template at src/templates/BlogTemplate
cec add-field-editor editor1 -t BlogTemplateContent -n -c BlogPost -f summary Use editor1 as the appearance for field summary in content type BlogPost from local template at src/content/BlogTemplateContent
------------------------
cec remove-field-editor
------------------------
Usage: cec remove-field-editor <name>
Removes a field editor from a field in a content type.
Options:
--template, -t The template the content type is from [required]
--contenttype, -c The content type [required]
--field, -f The field the field editor is for [required]
--contenttemplate, -n Flag to indicate the template is a content template
--help, -h Show help [boolean]
Examples:
cec remove-field-editor editor1 -t BlogTemplate -c BlogPost -f summary Remove editor1 as the appearance for field summary in content type BlogPost from local template at src/templates/BlogTemplate
cec remove-field-editor editor1 -t BlogTemplateContent -n -c BlogPost -f summary Remove editor1 as the appearance for field summary in content type BlogPost from local template at src/content/BlogTemplateContent
These samples of Field Appearance components are included with Content Toolkit:
TextFieldEditor
SliderFieldEditor
MapFieldEditor
The following image shows Content Toolkit commands you can use to develop the sample Field Appearance components.

Description of the illustration develop-custom-field-editor-commands.png
You can create the out-of-the-box Field Appearance components on your local
server, test them, and then upload them to your Oracle Content Management instance. The following image shows these
components on localhost:8085
.

Description of the illustration custom-components-local-server.png
You can test each component, such as slider, on the local server. There you can select properties for the component and then save it.

Description of the illustration slider.png
For the map component, you can click around on the map to provide a location as the editor value.

Description of the illustration map1.png
You can edit the HTML file for a component to change its settings, such as background color.

Description of the illustration edit-component-html.png
You can use a Content Toolkit command to associate a field editor with a field of a content type locally:
cec add-field-editor editor1 -t SimpleContent -n -c SimpleType -f title
cec add-field-editor slider -t SimpleContent -n -c SimpleType -f value
After you finish configuring and testing the custom field editors, you can upload them to your Oracle Content Management instance, using Content Toolkit commands:
# upload editors
cec ulcp editor1,slider -p -s Latest
# upload content
cec cr Repo5 -s
cec upload-content SimpleContent -r Rpo5 -s
When you upload the custom field editors, your components are imported into your Oracle Content Management instance and can be found on the Components page of the Developer section.