Wednesday, August 21, 2019

Hide the 'Add Fields' button in query panel Advance mode

This below blog we will see how to hide the ‘Add Fields’ button in the advanced mode. This below window is the query panel.


                               

Now we need to click ‘Advance’ button. The below window is the advance mode of query panel.

                                 
Now we will see how to hide ‘Add Fields’ button in advance mode query panel using ADF skin.First we need to create an ADF skin in source folder. For this, add a new ADF skin and follow the below configuration.

 



Open the source tab in the skin file. Now we need to add the below custom class for hiding the ‘Add Fields’ button.

/**ADFFaces_Skin_File / DO NOT REMOVE**/
@namespace af "http://xmlns.oracle.com/adf/faces/rich";
@namespace dvt "http://xmlns.oracle.com/dss/adf/faces";
.AFQueryHideAddFields af|query::footer-facet-content-style
{
  display: none;
}

Now we need to add the custom class “AFQueryHideAddFields” in af:query component. The code is below

<af:query id="qryId1" headerText="Search" disclosed="true" 
      value="#{bindings.EmployeesVOCriteriaQuery.queryDescriptor}"
      model="#{bindings.EmployeesVOCriteriaQuery.queryModel}"                                      queryListener="#{bindings.EmployeesVOCriteriaQuery.processQuery}"                    queryOperationListener="#{bindings.EmployeesVOCriteriaQuery.processQueryOperation}"
resultComponentId="::resId1"         binding="#{backingBeanScope.backing_QueryPanel.qryId1}"
        styleClass="AFQueryHideAddFields"/>

<af:query id="qryId1" headerText=" " disclosed="true"
                  value="#{bindings.PoRequisitionHeadersAllEOVOCriteriaQuery.queryDescriptor}"
                  model="#{bindings.PoRequisitionHeadersAllEOVOCriteriaQuery.queryModel}"
                  queryListener="#{bindings.PoRequisitionHeadersAllEOVOCriteriaQuery.processQuery}"
                  queryOperationListener="#{bindings.PoRequisitionHeadersAllEOVOCriteriaQuery.processQueryOperation}"

                  saveQueryMode="hidden" rows="3" maxColumns="2" modeChangeVisible="false"/>

Now you run your page and check the ‘Add Fields’ button will not display in advance mode of query panel.

Thanks...

No comments:

Post a Comment