07-28-2015 06:33 AM
How can I limit the search results to only elements contained in the current folder. What I'm using now returns all the "accuse de reception" stored in DB.
<contentView name="parent_accuse_de_reception_content">
      <title>label.contentview.accuse_de_receptions_content</title>
      <translateTitle>true</translateTitle>
      <showTitle>false</showTitle>
      <coreQueryPageProvider>
        <property name="coreSession">#{documentManager}</property>
        <property name="maxResults">DEFAULT_NAVIGATION_RESULTS</property>
        <whereClause docType="accuse_de_reception_search">
          <predicate parameter="adr:num_facture" operator="=">
            <field schema="accuse_de_reception_search" name="num_facture" />
          </predicate>
          <predicate parameter="bc_base:num_bc" operator="=">
            <field schema="accuse_de_reception_search" name="num_bc" />
          </predicate>
		  <predicate parameter="adr:ville" operator="=">
            <field schema="accuse_de_reception_search" name="ville" />
          </predicate>
		  <predicate parameter="adr:montant" operator="=">
            <field schema="accuse_de_reception_search" name="montant" />
          </predicate>
          <fixedPart>
                ecm:isCheckedInVersion = 0 AND
				ecm:mixinType != 'HiddenInNavigation' AND 
				ecm:currentLifeCycleState != 'deleted' AND
				ecm:primaryType = 'accuse_de_reception' 
          </fixedPart>
			<sort column="dc:title" ascending="true" />
        <pageSize>20</pageSize>		  
        </whereClause>
      </coreQueryPageProvider>
      <showPageSizeSelector>true</showPageSizeSelector>
      <useGlobalPageSize>true</useGlobalPageSize>
      <refresh>
        <event>documentChanged</event>
        <event>documentChildrenChanged</event>
      </refresh>
      <cacheKey>#{currentDocument.repositoryName}_#{currentDocument.id}</cacheKey>
      <cacheSize>10</cacheSize>
      <searchLayout name="accuse_de_reception_filter" filterDisplayType="quick" />
      <showFilterForm>true</showFilterForm>
      <resultLayouts>
        <layout name="accuse_de_reception_listing_ajax" title="document_listing"
          translateTitle="true" iconPath="/icons/document_listing_icon.png"
          showCSVExport="true" showPDFExport="false"
          showSyndicationLinks="true" />
      </resultLayouts>
      <selectionList>CURRENT_SELECTION</selectionList>
      <actions category="CURRENT_SELECTION_LIST" />
    </contentView>
07-28-2015 09:36 AM
Hi,
In the <fixedPart> you need to add
AND ecm:parentId = ?
and then after the </whereClause> you need to add
<parameter>#{currentDocument.id}</parameter>
You can have a look at the document_content content view, which uses this mechanism.
07-28-2015 09:36 AM
Hi,
In the <fixedPart> you need to add
AND ecm:parentId = ?
and then after the </whereClause> you need to add
<parameter>#{currentDocument.id}</parameter>
You can have a look at the document_content content view, which uses this mechanism.
07-28-2015 11:16 AM
That's exactly what I was looking for. Thanks [Manon Lumeau](https
 
					
				
				
			
		
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.