cancel
Showing results for 
Search instead for 
Did you mean: 

Custom attributes in table view

asv
Champ in-the-making
Champ in-the-making
Hello

I have created my custom model. I works fine. I have added type from my model to  <config evaluator="string-compare" condition="Content Wizards">

I need to display some custom properties in a table view (in Content Items or as Custom View).

There is Template mechanism that allow me to change design. But I don't know how to add custom properties to template or to browse.jsp (This  JSP uses in Content Items table).

Could you help me how to customize Alfresco in order to show custom properties in a table.
7 REPLIES 7

asv
Champ in-the-making
Champ in-the-making
I am struggling with  <hSmiley SurprisedutputText and #{r} variable. I have tried #{r.properties['myProp']} and  #{r.myProp} it dosn't work

zg0571
Champ in-the-making
Champ in-the-making
I have the same problem that I want to display the properties in browse.jsp .
Could anyone help?

kevinr
Star Contributor
Star Contributor
For properties that are not part of the standard Alfresco content model you need to specify the shortform of the model namespace for your property, so something like this:

#{r.properties['custom:myProp']}

Hope this helps,

Kevin

darko_narandzic
Champ in-the-making
Champ in-the-making
I followed your suggestion, but fields remain blank although content items have this particular property filled in.


<%– Description column for all view modes –%>
<a:column id="col13" style="text-align:left">
<f:facet name="header">
<a:sortLink id="col13-sort" label="My Label" value="myProp" styleClass="header"/>
</f:facet>
<h:outputText id="col13-txt" value="#{r.properties['custom:myProp']}" />
</a:column>

Can you help? It's sort of urgent…Smiley Happy

kevinr
Star Contributor
Star Contributor
Are you using 'custom' as the short uri for your model namespace? Or something else?

rock_tu
Champ on-the-rise
Champ on-the-rise
Hello kevinr,if I want to some property align right,How I do that can achivee it,Do you have a good idea?thank you very much!

darko_narandzic
Champ in-the-making
Champ in-the-making
If anyone is interested, this works in my case:

value="#{r['myType:myProp']}"