cancel
Showing results for 
Search instead for 
Did you mean: 

Use the out-of-the-box move action in custom dashlet in Alfresco

mstpkha
Champ in-the-making
Champ in-the-making
I have a custom dashlet(in Alfresco Share) which displays a list of documents of a specific folder. I want to set a link on the front of each document with the name "Move this doc". Until here, all is ok. I have the following display in my custom dashlet :
Doc1 || Move this doc
Doc2 || Move this doc
Doc3 || Move this doc
My question : I want to get the out-of-the-box move action executed by clicking in "Move this doc". Actually, I'm not looking to customize the out-of-the-box move action available in Document Library. I just need to use it as it is, but in my custom dashlet. How can I do this, please ? Any suggestion could help me. I'm using Alfresco Community 5.0
2 REPLIES 2

gravitonian
Star Collaborator
Star Collaborator
Hi,

I think you can achieve this by calling a Web Script from JS. As an example, look at the onActionSimpleRepoAction JS function that is used from Document Library actions to invoke a Repo Action. You can find it in the https://github.com/Alfresco/community-edition/blob/master/projects/slingshot/source/web/components/d... file.

mstpkha
Champ in-the-making
Champ in-the-making
Thanks Mr Gravitonian,
I've made some research but I didn't get a consistance response until now.
Recently, I've found that I should use the copy-move-to.js script in my Freemarker file of my webscript that generate the list of documents(regarding to 5.0 version of Alfresco).  I think I should add the following line in the top of my ftl file :
<@script type="text/javascript" src="${page.url.context}/res/modules/documentlibrary/copy-move-to.js"></@script>
But, until now, I didn't get any example in which I could focus to understand how to use it.
Have anyone any idea to help me, please?