Add 'specific' properties

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-19-2008 05:05 AM
Hello!
I 'd like to add some properties but there are some difficulties…
If you add a file and then you click details, it appears a page that includes properties (such as name, content type, encoding,author, size etc) . I found that the file which is responsible for the properties is here:
tomcat\webapps\alfresco\WEB-INF\classes\alfresco\model\contentModel.xml
I want to add some more properties but I want them to be depended on the kind of the file that is added.
For example if it is a pdf file, the user should be able to add a summary of the pdf, or
if it is a jpg file the user should be able to add resolution (something that will not have any point in the case of a pdf file).
I couldn t find how alfresco is recognize the kind of the file.. and if/how properties of a file can be changed/added.
Have you got any idea of how this can be done???
I 'd like to add some properties but there are some difficulties…
If you add a file and then you click details, it appears a page that includes properties (such as name, content type, encoding,author, size etc) . I found that the file which is responsible for the properties is here:
tomcat\webapps\alfresco\WEB-INF\classes\alfresco\model\contentModel.xml
I want to add some more properties but I want them to be depended on the kind of the file that is added.
For example if it is a pdf file, the user should be able to add a summary of the pdf, or
if it is a jpg file the user should be able to add resolution (something that will not have any point in the case of a pdf file).
I couldn t find how alfresco is recognize the kind of the file.. and if/how properties of a file can be changed/added.
Have you got any idea of how this can be done???
Labels:
- Labels:
-
Archive
5 REPLIES 5
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-19-2008 05:21 AM
First have a look at http://wiki.alfresco.com/wiki/Data_Dictionary_Guide
There you will find explanation of how to add new content types and aspects.
And have a look at http://ecmarchitect.com/ there are some nice tutorials there.
Then when you have created your new aspects, add them to specific content types using rules.
In your rule, you can specify that it only applies for a certain mime type.
Peter Löfgren
There you will find explanation of how to add new content types and aspects.
And have a look at http://ecmarchitect.com/ there are some nice tutorials there.
Then when you have created your new aspects, add them to specific content types using rules.
In your rule, you can specify that it only applies for a certain mime type.
Peter Löfgren

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-21-2008 07:32 AM
I tried to add new content types and aspects but it didn't work. I followed the instructions at this article
http://ecmarchitect.com/images/articles/alfresco-content/content-article.pdf
Could you give me an example of how the code should be in order to add some more properties which will be depended on the kind of the file that is added?
Thank you in advance!
http://ecmarchitect.com/images/articles/alfresco-content/content-article.pdf
Could you give me an example of how the code should be in order to add some more properties which will be depended on the kind of the file that is added?
Thank you in advance!
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-21-2008 07:44 AM
What do you mean by it didn't work?
Do you have errors when starting Alfresco, or do they not show up?
Rules is added using the client. Using rules you can base them on certain mime types as said, then you either choose to ad an aspect using your rule, our you choose specialise type of item. But in order for your custom types and aspects to show up in the rule wizard, you have to make sure you have configured web-client-config-custom.xml correctly. This should be in the tutorial you have been working through or in the link to data dictionary.
Peter
Do you have errors when starting Alfresco, or do they not show up?
Rules is added using the client. Using rules you can base them on certain mime types as said, then you either choose to ad an aspect using your rule, our you choose specialise type of item. But in order for your custom types and aspects to show up in the rule wizard, you have to make sure you have configured web-client-config-custom.xml correctly. This should be in the tutorial you have been working through or in the link to data dictionary.
Peter

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-21-2008 04:28 PM
They don t show up…
I also tried the exampleModel.xml and example-model-context.xml (according to the tutorial) but i didn t show the results.
Also i tried to drop the database and re-built it but it hadn t any result..
Have you got any idea about what may be the problem???
Thank you!
I also tried the exampleModel.xml and example-model-context.xml (according to the tutorial) but i didn t show the results.
Also i tried to drop the database and re-built it but it hadn t any result..
Have you got any idea about what may be the problem???
Thank you!
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-08-2008 11:04 AM
I had the same problem, but it was my mistake.
I forgot to uncomment the lines that shows the elements in the Content Wizards, Action Wizards, etc in the web-client-config-custom.xml; they all come commented by default and I didn't realize that because I was using a non-colored editor… I lost about 8hours in that.. jajaja so bad!
I forgot to uncomment the lines that shows the elements in the Content Wizards, Action Wizards, etc in the web-client-config-custom.xml; they all come commented by default and I didn't realize that because I was using a non-colored editor… I lost about 8hours in that.. jajaja so bad!
