09-28-2016 01:54 AM
Hi,
I was able to successfully create custom document type with properties using the Model Manager provided in 5.1, but when I tried to search the document using Adv. Search I was not able to find the document type in the dropdown.
Please help me out.
Thanks
Hiten Rastogi
09-28-2016 08:23 AM
The types listed in the first drop-down (Content, Folder, etc) are hard-coded options. You would need to customize the advanced search page to add your option in.
You could craft a search query as follows in the main search page
* AND TYPE:"cm:folder"
(i.e. search for anything where the type is cm:folder).
...however if you want to have your available as an option in advanced search then you'll need to customize the page to include extra types in the drop-down menu. This is possible by configuring the forms for advanced search... in the share-config.xml you'll find a section that looks like this:
<config evaluator="string-compare" condition="AdvancedSearch">
<advanced-search>
<!-- Forms for the advanced search type list -->
<forms>
<!--
The 'form' config element contains the name of the model type
of the form to display.
The element supports the following optional attributes:
id = form id, the id of "search" will be assumed if not set
label = label text to display - defaults to model type if not set
labelId = I18N message id of label text to display
description = description text to display
descriptionId = I18N message id of description text to display
-->
<form labelId="search.form.label.cm_content" descriptionId="search.form.desc.cm_content">cm:content</form>
<form labelId="search.form.label.cm_folder" descriptionId="search.form.desc.cm_folder">cm:folder</form>
</forms>
</advanced-search>
</config>
You can add an additional "form" element for the type you want to include in the drop-down menu.
09-28-2016 08:23 AM
The types listed in the first drop-down (Content, Folder, etc) are hard-coded options. You would need to customize the advanced search page to add your option in.
You could craft a search query as follows in the main search page
* AND TYPE:"cm:folder"
(i.e. search for anything where the type is cm:folder).
...however if you want to have your available as an option in advanced search then you'll need to customize the page to include extra types in the drop-down menu. This is possible by configuring the forms for advanced search... in the share-config.xml you'll find a section that looks like this:
<config evaluator="string-compare" condition="AdvancedSearch">
<advanced-search>
<!-- Forms for the advanced search type list -->
<forms>
<!--
The 'form' config element contains the name of the model type
of the form to display.
The element supports the following optional attributes:
id = form id, the id of "search" will be assumed if not set
label = label text to display - defaults to model type if not set
labelId = I18N message id of label text to display
description = description text to display
descriptionId = I18N message id of description text to display
-->
<form labelId="search.form.label.cm_content" descriptionId="search.form.desc.cm_content">cm:content</form>
<form labelId="search.form.label.cm_folder" descriptionId="search.form.desc.cm_folder">cm:folder</form>
</forms>
</advanced-search>
</config>
You can add an additional "form" element for the type you want to include in the drop-down menu.
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.