The document browser is used to let the user search for a document to link to. The document browser is used in various locations: in the HTML editor, in the navigation editor, for link fields, in the workflow interaction screens, ...
The document browser can be customized by means of a simple configuration file to enable or disable various search features and to influence the columns shown in the search result table.
On opening of the document browser, you can add a parameter called config which specifies which configuration to use. If not found, there is a fallback on the default configuration. The configuration files are located in the conf directory of the wikidata and are named docbrowser-{config}.xml or docbrowser-default.xml for the default.
For document browsers opened from link-type fields, the config parameter will be set to the name of the field type. This makes it convenient to create document browser configurations specific to a certain link type field.
In the configuration you can specify:
<?xml version="1.0"?>
<browserconf loadImmediately="true">
<chunk size="10"/>
<filters>
<meta show="true">
<limitToSite show="false"/>
<exclude show="false"/>
<language show="true"/>
<branch show="true"/>
<version show="true"/>
</meta>
<fulltext show="true"/>
<predefined show="true"/>
<faceted show="true">
<config>documentbrowser</config>
</faceted>
</filters>
<columns>
<column name="id"/>
<column name="name"/>
<column name="lastModifierLogin"/>
<column name="lastModified"/>
</columns>
<baseCondition>
documentType = 'SimpleDocument' and InCollection('mycollection')
</baseCondition>
<predefined>
<whereclause id="1">
<name>vdab</name>
<description>documents in collection 'VDAB'</description>
<value>InCollection('vdab')</value>
</whereclause>
<whereclause id="2">
<name>simpledoc</name>
<description>all Simple Documents</description>
<value>documentType = 'SimpleDocument'</value>
</whereclause>
</predefined>
</browserconf>
To show the faceted browser filter in the document browser, you need to
You can add a basecondition to the configuration of your documentbrowser. This basecondition will allways be executed on loading of the document list. This can be useful to limit your list to a certain type of document or limit to a collection. The user cannot modify this condition in the documentbrowser GUI.
<baseCondition>
documentType = 'SimpleDocument' and InCollection('mycollection')
</baseCondition>