cancel
Showing results for 
Search instead for 
Did you mean: 

Per folder view setting

fnduy
Champ in-the-making
Champ in-the-making
Hello,

I am using Alfresco Community 2.1 .
I have modified browse.jsp to create a special view (let's say "MoreDetails"), which is basically the same as the view "Details" with more metadata displayed. I want the view "details" to be the default view for most of the folders, so I made this setting in web-client-config-custom.xml.

<config evaluator="string-compare" condition="Views">
  <views>
    <view-defaults>
      <browse>
        <view>details</view>
      </browse>
   </view-defaults>
</views>
</config>

This works fine, but this setting applies to all the folders. Now, I want "MoreDetails" to be the default view for only a special folder and all its subfolders.
Ideally, if a user modifies the view for a folder (for instance, changes the sort column or the sort order), I would like Alfresco to memorize these changes for that folder as well.
Is there a simple way to do it ?

Thanks in advance for your help
1 REPLY 1

fogo
Champ in-the-making
Champ in-the-making
The only way I found to do this was to

- Assign a custom aspect to the spaces you want this view applied to
- override BrowseBean and the spaceChanged method
- in this method check the currentNode for your custom aspect and set the browseView accordingly