How to get all selected items?

cancel
Showing results for 
Search instead for 
Did you mean: 
kamilaw_
Member II

How to get all selected items?

Jump to solution

I have a webscript which would read all selected items

Which query I should use? 

ASPECT:"cm:checkedOut"

not running.

Alfresco - How to get all checked out documents? - Stack Overflow 

1 Solution

Accepted Solutions
douglascrp
Advanced II

Re: How to get all selected items?

Jump to solution

Ok, now I understand.

When you configure a new action in that menu, the javascript action you define will receive the selected nodes automatically.

You can see how it is done by looking at the Share's source code.

The action configuration: share/share-documentlibrary-config.xml at master · Alfresco/share · GitHub 

And the javascript code executed when the user clicks on the action: share/actions.js at master · Alfresco/share · GitHub 

Follow that model and you will get what you need.

View solution in original post

3 Replies
douglascrp
Advanced II

Re: How to get all selected items?

Jump to solution

What have you tried exactly?

Can you share some code to give us an idea on what you are doing?

Without any context, it will be hard to help you.

kamilaw_
Member II

Re: How to get all selected items?

Jump to solution

I have a new action for selected items.

<action type="action-link" id="idOfJavascript" permission="Write" label="someLabel" />

And now I  need to read all selected items in this page. The question is how Alfresco read this files? 

douglascrp
Advanced II

Re: How to get all selected items?

Jump to solution

Ok, now I understand.

When you configure a new action in that menu, the javascript action you define will receive the selected nodes automatically.

You can see how it is done by looking at the Share's source code.

The action configuration: share/share-documentlibrary-config.xml at master · Alfresco/share · GitHub 

And the javascript code executed when the user clicks on the action: share/actions.js at master · Alfresco/share · GitHub 

Follow that model and you will get what you need.