Association customization in Share
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2012 01:00 PM
Hi
I created a new custom model called mymodel1in alfresco with some properties and an association to mymodel2.
When I render it in Share I can click on create–>newmodel1 and I can associate the newmodel1 object to an existing newmodel2 object.
what I can't do is to click on create –>newmodel1 and to get a button in the form to create newomodel2 instead of the button "select"
Is it possible to customize share/document-library to do that?
I created a new custom model called mymodel1in alfresco with some properties and an association to mymodel2.
When I render it in Share I can click on create–>newmodel1 and I can associate the newmodel1 object to an existing newmodel2 object.
what I can't do is to click on create –>newmodel1 and to get a button in the form to create newomodel2 instead of the button "select"
Is it possible to customize share/document-library to do that?
Labels:
- Labels:
-
Archive
3 REPLIES 3
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-17-2012 06:31 AM
Yes Possible,
You need to create a custom Controller, that would show the upload dialogue and uploads the file and add as association.
You need to create a custom Controller, that would show the upload dialogue and uploads the file and add as association.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-17-2012 09:42 AM
that's great.
It not 100% clear what you mean with Controller, a webscript?
Could you please be more specific?
actually my target type is not cm:content it is a custom model it self so I don't have a simple file to upload but a new obj to create. Do you have any idea about how I can implement that in share?
thanks a lot
It not 100% clear what you mean with Controller, a webscript?
Could you please be more specific?
actually my target type is not cm:content it is a custom model it self so I don't have a simple file to upload but a new obj to create. Do you have any idea about how I can implement that in share?
thanks a lot
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-18-2012 04:36 AM
Hi,
In share every form filed is rendered by a Controller.
You can find the OOB controllers in tomcat\webapps\share\WEB-INF\classes\alfresco\site-webscripts\org\alfresco\components\form\controls.
Now you need to implement a Custom Controller, that wolud have a button, onclick it would open create content Dialouge, onSuccess you wil get the created nodeRef, you assign this node ref to association field.
You can take a look into the association.ftl, how it is working.
In share every form filed is rendered by a Controller.
You can find the OOB controllers in tomcat\webapps\share\WEB-INF\classes\alfresco\site-webscripts\org\alfresco\components\form\controls.
Now you need to implement a Custom Controller, that wolud have a button, onclick it would open create content Dialouge, onSuccess you wil get the created nodeRef, you assign this node ref to association field.
You can take a look into the association.ftl, how it is working.
