cancel
Showing results for 
Search instead for 
Did you mean: 

Show properties in function of the user, role or group

coffman
Champ in-the-making
Champ in-the-making
Is it possible to show different custom properties in function of the user that is accesing the document ?

I mean:

A document has the following custom attributes:
* InvoiceNr
* Customer
* Total


I need that a user edits the attribute InvoiceNr (and only it)
And another user edits the attribute ( Customer and Total)

I don't know if there are some property of show-properties that allows me to show or hide in function of the user or role connected.

Regards
1 REPLY 1

gavinc
Champ in-the-making
Champ in-the-making
This is not supported I'm afraid either in permissions or the property sheet out of the box.

Permissions are to the object level not property level.

There is potentially something you could do though. When the property sheet is deciding what properties to show a lookup is performed on the "property-sheet" configuration, typically defined as:

<config evaluator="node-type" condition="content">
   <property-sheet>
      <show-property name="name" />
      …
   </property-sheet>
</config>

The configuration service decides which property sheet config to use by testing the type of the current node and the aspects it has, this is done, in part, by the "node-type" evaluator.

You could define your own evaluator that returns true depending on whether the node is the right type AND who the current user is. You could then define different property sheet configuration for different users per type.

Have a look at the Config Service wiki page (http://wiki.alfresco.com/wiki/Config_Service), and the current node-type evaluator which is implemented in org.alfresco.web.config.NodeTypeEvaluator

Hope that helps!