cancel
Showing results for 
Search instead for 
Did you mean: 

triggering inbound rule and reading property from aspect

chuck
Champ in-the-making
Champ in-the-making
Hi, I am currently struggling and trying to find my way around alfresco.
I have been able to add a custom aspect which is visible.

I did this by adding the aspect to my content model, then making the entry visible in web-client-config.xml.

However now I wish to use the value provided by the user in my code.

I have to admit I am a little flumoxed with all the docs and can't find the exact direction I need to take.
Particularly where I should put it based on the alfresco structure.
Would someone be so kind as to tell me how I should work within the  existing framework to do this ?
Is there a proper way to do this or can I just called (NodeRef)this.nodeService.getProperty… within any class ?

I would like it to be in the same category as aspects such as classifiable but would like to use its property value to run an action.
Does this mean I have to create my class under repo/action/executer ?

Is it possible to also access values for other aspects with my class ?

Just to clarify, I have the following:

<config evaluator="aspect-name" condition="cm:heatable">
           <property-sheet>
              <show-property name="cm:heat" display-label-id="heat" />
              <show-property name="cm:heat_temp" display-label-id="heat_temp" />
           </property-sheet>
        </config>

but I want to carry out a calculation based on the temperature value.


Thanks
1 REPLY 1

chuck
Champ in-the-making
Champ in-the-making
Ok for any pilgrim that might head this way I realised what I was trying to do where 2 entirely separate things however I had them as one in my mind.

Firstly adding my aspect was not a problem. This was the first part.

For the second part you will need to follow the
http://wiki.alfresco.com/wiki/Custom_Action_UI starting from "Implementing the action"
but being as I was not interested in setting the property I only needed to throw in nodeService.getProperty on the property I set up for my aspect within my executeImpl method.