Forum Stats

  • 3,876,204 Users
  • 2,267,082 Discussions
  • 7,912,467 Comments

Discussions

File explorer - Content presenter template.

User_QUFP4
User_QUFP4 Member Posts: 176 Red Ribbon
edited May 18, 2018 12:55PM in WebCenter Portal

Hello,

One of my requirements is to get file explorer view in the WebCenter portal page.

I was able to get the file explorer view by creating a page parameter datasource : #{facesContext.externalContext.requestParameterMap['datasource']} and defined the parameter of the content presenter as {#bindings.datasource} and passed the value of Folder GUID in the URL and got the folder contents.

The issue is I have 3 content presenters in my portal page. As all the three content presenter is bound to  a single parameter-  datasource, when I click on the folder link in one content presenter, I'm getting the folder contents in all the three content presenters view in my portal page.

Please advise..

Thanks as always!

Best Answer

Answers

  • Dinil Mithra
    Dinil Mithra Member Posts: 351 Bronze Badge
    edited Apr 27, 2018 12:39AM Answer ✓

    Can you try with 3 different page parameters instead of single parameter?

    Kind Regards,

    DM

  • User_QUFP4
    User_QUFP4 Member Posts: 176 Red Ribbon
    edited Apr 27, 2018 10:08AM

    Thanks a  lot for your rpely!

    Yes, I am working on that

    little changes in my content presenter template code to accomodate all the parameters.. Will give an update once I get this

  • User_QUFP4
    User_QUFP4 Member Posts: 176 Red Ribbon
    edited Apr 27, 2018 1:18PM

    I defined 3 different page paramters and set the parameters of the content presenter - #{bindings.datasource1 2 and 3...

    the direct URL - <Server_name>/portal/page_name?datsource2=WebCenterpotralcontent%dCollectionId:<GUID> is working fine.

    I do not know how to mention this in the content presenter template code - I meant change from datasource1 to datasource2 when this folder structure is clicked..

    Is there a way to refer the parameter value of that content presenter... ? Thanks as always.

  • Dinil Mithra
    Dinil Mithra Member Posts: 351 Bronze Badge
    edited Apr 28, 2018 4:19AM

    Please try with setPropertyListener to set value from your page binding.

          <af:link text="Folder 1" id="l1">

            <af:setPropertyListener from="#{YourValue}" to="#{bindings.datasource1}" type="action"/>

          </af:link>

    Kind Regards,

    DM

    User_QUFP4
  • User_QUFP4
    User_QUFP4 Member Posts: 176 Red Ribbon
    edited Apr 30, 2018 3:43PM

    I am not sure if I am using this Property Listener right in my code.

    <af:link id="l1" test="Folder1">

    <af:setPropertyListener from="datasource_Value" to="#{bindings.datasource1}" type="action"/>

    </af:link>

    Could you please let me know what is #{YourValue}.. Is it the value of the datasource parameter.. I tried assigning the datasource value like in the URL

    <af:setPropertyListener from="?datasource=WebCenterportalcontent%dCollectionId:<GUID>" to="#{bindings.datasource1}" type="action"/>

    It is not working.

    Tried to give the destination <Whole URL> along with parameters.. not working.

    Could you please advise.

    Thanks as always!

  • User_QUFP4
    User_QUFP4 Member Posts: 176 Red Ribbon
    edited May 15, 2018 5:29PM

    Was able to  achieve this using component.clientId.

    thanks for all your help

This discussion has been closed.