cancel
Showing results for 
Search instead for 
Did you mean: 

Adding an aspect on multiple documents AND/OR adding an aspect on upload

ipirat
Champ in-the-making
Champ in-the-making
Hi,

I'm working with Alfresco Share (/share) and uploaded quite some documents. Now I realised that to assign Categories to them, I need to add a sertain aspect to the documents forst (Classification aspect).
So now my questions:

<ol>
<li>Is there a way to add an aspect to ALL Documents (or all documents in a doc library of a certain site or at least to all documents of a folder)?
<li>Is there a way to preselect a bunch of aspects that are automatically added to newly uploaded documents?
<ul>
<li>I need that for future documents
<li>If the answer to the question 1 is "no", I could reupload all documents (as there isn't THAT much done with them yet)
</ul>
</ol>

disclaimer: I'm quite new to alfresco and very new to the forum. please move the discussion to a (more) appropriate subforum, if necessary.
6 REPLIES 6

ipirat
Champ in-the-making
Champ in-the-making
Found the solution to Question 2 here: http://wiki.alfresco.com/wiki/Versioning_Behaviour

<blockquote>For example, using the Alfresco Explorer (JSF client UI) you can select "View Details" on a space, and then add an inbound content rule for all items, which applies the Versionable aspect. </blockquote>

romschn
Star Collaborator
Star Collaborator
You can setup a business rule for all the incoming documents on the folder to have specified aspects applied on them when a content is uploaded to that folder.
Below are the high-level steps to add a new business rule on a folder.
1. When you view the folder, There is link on right side - Manage Rules. Click on it.
2. It will open a new page. Select - Create Rules.
3. Give name to the rule - for example add aspects to incoming items
4. For When condition under Define rule section, select - Items are created or entered this folder
5. Select the criteria. In your scenario - you must be interested to set it for all items. However you can check and select criteria as required.
6. Now, under Perform Action section, select - Add Aspect from dropdown. It will display list of available aspects out-of-the-box. You can define as many number of aspects you want to apply by clicking on + icon.
7. Check the checkboxes at bottom and select appropriately as per your requirement.
8. Now, click on Create Rule.

Any new items uploaded will now have the mentioned aspects applied on them.
As you mentioned, you currently have smaller amount of contents uploaded and it is okay for you to upload them again then i would suggest to upload them after creating the rule.

Hope this helps.

Mark the comment as useful if it was helpful to you.


ipirat
Champ in-the-making
Champ in-the-making
Thanks, I had already found this solution in the Alfresco Explorer (see my post above) – Now I also know how to find the rules in the Alfresco Share.

I see one difference: In the Explorer, I can define the rules on sites as well as on folders. In the Share I only found a way to modify the rules on folders (including the "root" folder documentLibrary). Which isnt a big deal for me at the moment, just trying to understand the system. – Is there a way to access site rules in the Alfresco Share?

romschn
Star Collaborator
Star Collaborator
You can access various sites created under site folders from alfresco share through repository view.

ipirat
Champ in-the-making
Champ in-the-making
Cool, Thanks!

ipirat
Champ in-the-making
Champ in-the-making
In the meantime, I have a (positive) answer to Question 1 as well:

1. Create a business Rule on a Folder as described in other replies
2. Go to Busiess-Rules-Edit Screen of that Folder (in /share)
3. Select "Run Rules" Button at the top right => this will immediately run your rules, and so manually apply the change