Page tree
Skip to end of metadata
Go to start of metadata

Filter Configuration Option:

We  split the filter options into 3 category

Mandatory:

Mandatory filter are bind to a existing parameter will always appear on the filter panel unless set to hidden. E.g

  • UICheckbox(MANDATORY.CHECKBOX) 
  • UIDropDownSelectList(MANDATORY.DROPDOWNSELECTLIST)

Filter that does not appear on filter panel but is still send via request:

  • UIHiddenParam(MANDATORY.HIDDEN) - Sets a parameter to a default value
  • UIHiddenResourceAttribute(MANDATORY.UIHiddenResourceAttribute) - Uses a attribute in the  csw.onlineResource such as url

 

Optional:

Filters here will appear in a dropdown. E.g provider filter

Optional.xpath:


This would be the most commonly used filter type as it binds the filter to a xpath value. Existing filter controller has to be updated to reflect the use of this due to backward dependency. If we do migrate in the future, we should  be able to configure a layer and its filter sololy via the xml file as we can easily set the style sheet as a resource and filters as parameters.

  • UIDate(OPTIONAL.DATE) 
  • UIDropDownRemote(OPTIONAL.DROPDOWNREMOTE)
  • UITextBox(OPTIONAL.TEXT)
  • UIDdropDownSelectList(OPTIONAL.DROPDOWNSELECTLIST)

Examples

 <property name ="optionalFilters">
                    <list>
                        <bean class="org.auscope.portal.core.uifilter.optional.xpath.UITextBox">
                            <constructor-arg name="label" value="Name"></constructor-arg>
                            <constructor-arg name="xpath" value="mt:name"></constructor-arg>
                            <constructor-arg name="value"><null/></constructor-arg>                            
                            <constructor-arg name="predicate">
                                <value type="org.auscope.portal.core.uifilter.Predicate">ISLIKE</value>
                            </constructor-arg>
                        </bean> 
                        <bean class="org.auscope.portal.core.uifilter.optional.xpath.UIDropDownSelectList">
                            <constructor-arg name="label" value="Tenement Type"></constructor-arg>  
                             <constructor-arg name="xpath" value="mt:tenementType"></constructor-arg>                          
                            <constructor-arg name="value"><null/></constructor-arg>
                             <constructor-arg name="predicate">
                                <value type="org.auscope.portal.core.uifilter.Predicate">ISLIKE</value>
                            </constructor-arg>                            
                            <constructor-arg name="options">
                                <list>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">ExplorationDisplay</value></constructor-arg>
                                        <constructor-arg name="right"><value  type="java.lang.String">exploration</value></constructor-arg>
                                    </bean>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">Prospecting</value></constructor-arg>
                                        <constructor-arg name="right"><value type="java.lang.String">prospecting</value></constructor-arg>
                                    </bean>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">Miscellaneous</value></constructor-arg>
                                        <constructor-arg name="right"><value type="java.lang.String">miscellaneous</value></constructor-arg>
                                    </bean>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">Mining Lease</value></constructor-arg>
                                        <constructor-arg name="right"><value type="java.lang.String">mining</value></constructor-arg>
                                    </bean>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">Licence</value></constructor-arg>
                                        <constructor-arg name="right"><value  type="java.lang.String">licence</value></constructor-arg>
                                    </bean>
                                </list>                               
                            </constructor-arg>
                        </bean> 
                         <bean class="org.auscope.portal.core.uifilter.optional.UICheckBoxGroupProvider">
                            <constructor-arg name="label" value="Provider"></constructor-arg>                            
                            <constructor-arg name="value"><null/></constructor-arg>                                                        
                        </bean>
                     	 <bean class="org.auscope.portal.core.uifilter.optional.xpath.UIDropDownRemote">
                            <constructor-arg name="label" value="Commodity"></constructor-arg>
                            <constructor-arg name="xpath" value="gsml:specification/er:MineralOccurrence/er:commodityDescription/er:Commodity/er:commodityName"></constructor-arg>
                            <constructor-arg name="value"><null/></constructor-arg>                            
                            <constructor-arg name="predicate">
                                <value type="org.auscope.portal.core.uifilter.Predicate">ISLIKE</value>
                            </constructor-arg>
                            <constructor-arg name="url" value="../getAllCommodities.do"></constructor-arg>
                        </bean>  
                    </list>
                </property> 
                <property name ="mandatoryFilters">
                    <list>
                        <bean class="org.auscope.portal.core.uifilter.mandatory.UIDropDownSelectList">
                            <constructor-arg name="label" type="java.lang.String" value="Color Code"></constructor-arg>
                            <constructor-arg name="parameter" type="java.lang.String" value="ccProperty"></constructor-arg>                         
                            <constructor-arg name="value" type="java.lang.String" value=""></constructor-arg>  
                            <constructor-arg name="options">
                                <list>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">Tenement Type</value></constructor-arg>
                                        <constructor-arg name="right"><value  type="java.lang.String">TenementType</value></constructor-arg>
                                    </bean>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">Tenement Status</value></constructor-arg>
                                        <constructor-arg name="right"><value type="java.lang.String">TenementStatus</value></constructor-arg>
                                    </bean>
                                    <bean class="org.apache.commons.lang3.tuple.ImmutablePair">
                                        <constructor-arg name="left"><value  type="java.lang.String">Default</value></constructor-arg>
                                        <constructor-arg name="right"><value type="java.lang.String"></value></constructor-arg>
                                    </bean>                                    
                                </list>                               
                            </constructor-arg>                                                      
                        </bean>
                    </list>
                </property> 

 

  • No labels