Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
RE: Custom Attributes - Where to apply them OOT
10527, modificat fa 17 anys.
Liferay Legend
Apunts: 1197
Data d'incorporació: 08/02/05
Publicacions recents
Hey All,
I'm trying to decide where we should provide access to the new feature "Custom Attributes".
First off, this feature allows adhoc creation of attributes associated with a given entity type at runtime, via a UI. Woohoo!
For example, "User"; I want to add a custom attribute to store their favorite color.
- Visit the "Custom Attributes" section associated with User
- click "Add Custom Attribute"
- select name = "color"
- type = "String"
- optionally specify a defaultValue = "Enter your favorite color here before we cancel your account!"
- Set the permissions
- optionally set some properties on the attribute
Now we also have some new tags designed to display these values as well as provide them as editable fields based on permissions.
So, I'll blog about all this once its all finalized and committed (within the week or so).
My question is, on which entities should such a feature be provided OOTB?
This is a general framework with an API available on any entity created by ServiceBuilder. BUT we obviously can only provide OOTB support for a handful of objects, where it makes sense.
I'm thinking the following, but can anyone think of others I'm obviously missing?
- User
- Org
- Role
- Document Library FileEntry
Thanks all!
PS: Yes these fields should be indexed per type and instance (just haven't worked out all the details for that yet).
I'm trying to decide where we should provide access to the new feature "Custom Attributes".
First off, this feature allows adhoc creation of attributes associated with a given entity type at runtime, via a UI. Woohoo!
For example, "User"; I want to add a custom attribute to store their favorite color.
- Visit the "Custom Attributes" section associated with User
- click "Add Custom Attribute"
- select name = "color"
- type = "String"
- optionally specify a defaultValue = "Enter your favorite color here before we cancel your account!"
- Set the permissions
- optionally set some properties on the attribute
Now we also have some new tags designed to display these values as well as provide them as editable fields based on permissions.
So, I'll blog about all this once its all finalized and committed (within the week or so).
My question is, on which entities should such a feature be provided OOTB?
This is a general framework with an API available on any entity created by ServiceBuilder. BUT we obviously can only provide OOTB support for a handful of objects, where it makes sense.
I'm thinking the following, but can anyone think of others I'm obviously missing?
- User
- Org
- Role
- Document Library FileEntry
Thanks all!
PS: Yes these fields should be indexed per type and instance (just haven't worked out all the details for that yet).
10437, modificat fa 17 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
Hi Ray,
This is very cool, since it will allow any entity to quickly be able to store associated meta-information. Of the ones you mention I think all of them make a lot of sense (maybe with the exception of role). Some other places where it could make sense:
This is very cool, since it will allow any entity to quickly be able to store associated meta-information. Of the ones you mention I think all of them make a lot of sense (maybe with the exception of role). Some other places where it could make sense:
- Image Gallery Image
- Bookmarks Entry
- Polls Question
- Calendar Event
- Wiki article
- Blogs Entry
10527, modificat fa 17 anys.
Liferay Legend
Apunts: 1197
Data d'incorporació: 08/02/05
Publicacions recents
Role is already the second place Armin and I have ended up using it. So,
I think it is logical.
I think it is logical.
31926, modificat fa 17 anys.
Liferay Master
Apunts: 582
Data d'incorporació: 16/05/07
Publicacions recents
Hi Ray,
I think it would be nice if the UI controlled expandos, especially those for the files and directories in DL, worked like aspects.
Say you store instruction videos in the DL and that you extract some basic technical meta-data like playing time when the file is uploaded. In addition, you want to store some meta-data that describes the instructional content of the video. Further, you have some additional instruction material that is not video based and some marketing videos.
For each aspect I would like some expando attributes and in the hypothetical case above the aspects could be:
Training material
Marketing material
Movie
Thoughts?
I think it would be nice if the UI controlled expandos, especially those for the files and directories in DL, worked like aspects.
Say you store instruction videos in the DL and that you extract some basic technical meta-data like playing time when the file is uploaded. In addition, you want to store some meta-data that describes the instructional content of the video. Further, you have some additional instruction material that is not video based and some marketing videos.
For each aspect I would like some expando attributes and in the hypothetical case above the aspects could be:
Training material
Marketing material
Movie
Thoughts?
10437, modificat fa 17 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
Wow, that's a pretty cool idea. So basically there would be 'groups' of attributes that would be applied as aspects, right?
What Ray has currently implemented is simpler, since once you define a custom attribute for a user (for example) it will be shown in the form for all users (unless some JSP customization is made). For users that might be enough, but I think what you say makes a lot of sense for other entities, specially for contents.
For example, I can imagine a predefined group of custom attributes to implement dublin core.
I'm not sure how to implement it, or if we are asking for too much for a first version of this feature, but it's certainly a good idea that should be implemented sooner or later.
What Ray has currently implemented is simpler, since once you define a custom attribute for a user (for example) it will be shown in the form for all users (unless some JSP customization is made). For users that might be enough, but I think what you say makes a lot of sense for other entities, specially for contents.
For example, I can imagine a predefined group of custom attributes to implement dublin core.
I'm not sure how to implement it, or if we are asking for too much for a first version of this feature, but it's certainly a good idea that should be implemented sooner or later.
31926, modificat fa 17 anys.
Liferay Master
Apunts: 582
Data d'incorporació: 16/05/07
Publicacions recents
Jorge Ferrer:
Wow, that's a pretty cool idea. So basically there would be 'groups' of attributes that would be applied as aspects, right?
Yes, that's the main idea. Also, the aspects can be used when defining rules for content routing.
24726, modificat fa 17 anys.
Regular Member
Apunts: 192
Data d'incorporació: 18/11/06
Publicacions recents
Other entities OOTB:
Company
Community
LayoutSet -- Let's one set additional settings for a site. For
example one could tell an intelligent theme that the navmenu should
have a max of 5 items per row or horizontal vs vertical layout for the
nav menu
Layout -- Allows adding custom properties for a page. For example,
could tell the theme if the header or footer portions of the them
should be rendered.
On Oct 6, 2008, at 10:55 PM, Ray Augé at Liferay's Community Forums
wrote:
> Hey All,
>
> I'm trying to decide where we should provide access to the new
> feature "Custom Attributes".
>
> First off, this feature allows adhoc creation of attributes
> associated with a given entity type at runtime, via a UI. Woohoo!
>
> For example, "User"; I want to add a custom attribute to store their
> favorite color.
>
> - Visit the "Custom Attributes" section associated with User
> - click "Add Custom Attribute"
> - select name = "color"
> - type = "String"
> - optionally specify a defaultValue = "Enter your favorite color
> here before we cancel your account!"
> - Set the permissions
> - optionally set some properties on the attribute
>
> Now we also have some new tags designed to display these values as
> well as provide them as editable fields based on permissions.
>
> So, I'll blog about all this once its all finalized and committed
> (within the week or so).
>
> My question is, on which entities should such a feature be provided
> OOTB?
>
> This is a general framework with an API available on any entity
> created by ServiceBuilder. BUT we obviously can only provide OOTB
> support for a handful of objects, where it makes sense.
>
> I'm thinking the following, but can anyone think of others I'm
> obviously missing?
>
> - User
> - Org
> - Role
> - Document Library FileEntry
>
>
> Thanks all!
>
> PS: Yes these fields should be indexed per type and instance (just
> haven't worked out all the details for that yet).
> --
> Liferay Community Forum
> mb.308691.1390484@events.liferay.com
> http://www.liferay.com/web/guest/community/forums/-/message_boards/message/1390484
Company
Community
LayoutSet -- Let's one set additional settings for a site. For
example one could tell an intelligent theme that the navmenu should
have a max of 5 items per row or horizontal vs vertical layout for the
nav menu
Layout -- Allows adding custom properties for a page. For example,
could tell the theme if the header or footer portions of the them
should be rendered.
On Oct 6, 2008, at 10:55 PM, Ray Augé at Liferay's Community Forums
wrote:
> Hey All,
>
> I'm trying to decide where we should provide access to the new
> feature "Custom Attributes".
>
> First off, this feature allows adhoc creation of attributes
> associated with a given entity type at runtime, via a UI. Woohoo!
>
> For example, "User"; I want to add a custom attribute to store their
> favorite color.
>
> - Visit the "Custom Attributes" section associated with User
> - click "Add Custom Attribute"
> - select name = "color"
> - type = "String"
> - optionally specify a defaultValue = "Enter your favorite color
> here before we cancel your account!"
> - Set the permissions
> - optionally set some properties on the attribute
>
> Now we also have some new tags designed to display these values as
> well as provide them as editable fields based on permissions.
>
> So, I'll blog about all this once its all finalized and committed
> (within the week or so).
>
> My question is, on which entities should such a feature be provided
> OOTB?
>
> This is a general framework with an API available on any entity
> created by ServiceBuilder. BUT we obviously can only provide OOTB
> support for a handful of objects, where it makes sense.
>
> I'm thinking the following, but can anyone think of others I'm
> obviously missing?
>
> - User
> - Org
> - Role
> - Document Library FileEntry
>
>
> Thanks all!
>
> PS: Yes these fields should be indexed per type and instance (just
> haven't worked out all the details for that yet).
> --
> Liferay Community Forum
> mb.308691.1390484@events.liferay.com
> http://www.liferay.com/web/guest/community/forums/-/message_boards/message/1390484
11303, modificat fa 17 anys.
Junior Member
Apunts: 71
Data d'incorporació: 24/03/05
Publicacions recents
This is a little OT, but it deals with where we should place this feature.
I'd like to keep the out of the box GUI as simple as possible and only include the functionality that is used most on a daily basis. I believe that this is one of the main things that will help us to gain mainstream adoption.
We should include a Settings link next to each portlet title that would control any settings - permissions, preferences or otherwise. The fact that it is located next to the portlet title will clue users into the fact that these are portlet settings. It should not be a small icon at the upper right since most new users would never click that. They might however, click the Settings link.
Given that this isn't a common usage scenario, I would suggest placing the Custom Attributes under Settings or the existing Configuration icon.
I'd like to keep the out of the box GUI as simple as possible and only include the functionality that is used most on a daily basis. I believe that this is one of the main things that will help us to gain mainstream adoption.
We should include a Settings link next to each portlet title that would control any settings - permissions, preferences or otherwise. The fact that it is located next to the portlet title will clue users into the fact that these are portlet settings. It should not be a small icon at the upper right since most new users would never click that. They might however, click the Settings link.
Given that this isn't a common usage scenario, I would suggest placing the Custom Attributes under Settings or the existing Configuration icon.
Fitxers adjunts:
10437, modificat fa 17 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
Hi Ed,
The access to managing custom attributes will be in the toolbar of the user management portlet. For cases like this I think we should be careful to keep the links out of the portlet box (which is managed by the portal).
I think it's important to keep out of the portlet window anything that's not related to that specific portlet window. Note that preferences and configuration are specific to the window, not the the Journal portlet (or any other portlet) in general.
Anything that is related to the "contents" of the portlet should be handled by the portlet itself and not by the portal in any way. That keeps the proper separation of concerns which ends up helping usability and also provides more flexibility to the developers.
The access to managing custom attributes will be in the toolbar of the user management portlet. For cases like this I think we should be careful to keep the links out of the portlet box (which is managed by the portal).
I think it's important to keep out of the portlet window anything that's not related to that specific portlet window. Note that preferences and configuration are specific to the window, not the the Journal portlet (or any other portlet) in general.
Anything that is related to the "contents" of the portlet should be handled by the portlet itself and not by the portal in any way. That keeps the proper separation of concerns which ends up helping usability and also provides more flexibility to the developers.
11303, modificat fa 17 anys.
Junior Member
Apunts: 71
Data d'incorporació: 24/03/05
Publicacions recents
Makes sense. I assumed that we were going to include it as another tab. Thanks Jorge.
1503461, modificat fa 17 anys.
New Member
Apunts: 3
Data d'incorporació: 28/10/08
Publicacions recents
Hello,
Has this feature "custom attributes" been released?
If it has, how can i access it, if not when is it likely to be released.
Thanks in Advance
Yinka
Has this feature "custom attributes" been released?
If it has, how can i access it, if not when is it likely to be released.
Thanks in Advance
Yinka
10437, modificat fa 17 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
Hi Yanke,
You can have access to this feature by checking out the code from trunk. It'll also be included in the next release (5.2), although it doesn't have a date yet.
You can have access to this feature by checking out the code from trunk. It'll also be included in the next release (5.2), although it doesn't have a date yet.
31576, modificat fa 16 anys.
Liferay Master
Apunts: 993
Data d'incorporació: 27/04/07
Publicacions recents
Hi Ray,
It is really nice feature - Custom Attributes. Thank you, Ray.
It was noticed that only basic types (Booleans, String, etc) are supported in custom attributes like:
Is it good to support Liferay default types like DLFileEntry, IGImage, JournalArticle? Hope that it CAN.
Why do we need these types?
Use custom attributes to represent references (associations) of documents, images and JournalArticle;
Use custom attributes to build dynamic content model;
and more ...
Make sense?
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
It is really nice feature - Custom Attributes. Thank you, Ray.
It was noticed that only basic types (Booleans, String, etc) are supported in custom attributes like:
public class ExpandoColumnConstants {
public static final int BOOLEAN = 1;
public static final int BOOLEAN_ARRAY = 2;
public static final String BOOLEAN_ARRAY_LABEL = "boolean[]";
public static final String BOOLEAN_LABEL = "boolean";
public static final int DATE = 3;
public static final int DATE_ARRAY = 4;
...
public static final int STRING = 15;
public static final int STRING_ARRAY = 16;
public static final String STRING_ARRAY_LABEL = "java.lang.String[]";
public static final String STRING_LABEL = "java.lang.String";
Is it good to support Liferay default types like DLFileEntry, IGImage, JournalArticle? Hope that it CAN.
Why do we need these types?
Use custom attributes to represent references (associations) of documents, images and JournalArticle;
Use custom attributes to build dynamic content model;
and more ...
Make sense?
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
10437, modificat fa 16 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
Hi Jonas,
I like the idea of allowing linking contents, but I would prefer to create specific tables for that and do it at the asset level. Using specific tables and services would allow for more specialized code to work with the relationships.
I'm thinking of this feature for the version after 5.3. Suggestions and contributions are welcome.
I like the idea of allowing linking contents, but I would prefer to create specific tables for that and do it at the asset level. Using specific tables and services would allow for more specialized code to work with the relationships.
I'm thinking of this feature for the version after 5.3. Suggestions and contributions are welcome.
31576, modificat fa 16 anys.
Liferay Master
Apunts: 993
Data d'incorporació: 27/04/07
Publicacions recents
Hi Jorge,
Thank you so much. It would be very nice to know your detailed plan on this.
The specific tables are used for metadata of Images and Documents. I think that these specific tables should have following capabilities:
1) association to any objects, including Images and Documents - for long term usage;
2) dynamic types (basic types) generation, like the custom attributes (Expando tables);
3) custom types generation, like DLFileEntry, IGImage, JournalArticle, etc - object reference and association.
4) handling persistent "lock / unlock" functions;
5) handling workflow (jBPM) status;
Any thing else?
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
Thank you so much. It would be very nice to know your detailed plan on this.
The specific tables are used for metadata of Images and Documents. I think that these specific tables should have following capabilities:
1) association to any objects, including Images and Documents - for long term usage;
2) dynamic types (basic types) generation, like the custom attributes (Expando tables);
3) custom types generation, like DLFileEntry, IGImage, JournalArticle, etc - object reference and association.
4) handling persistent "lock / unlock" functions;
5) handling workflow (jBPM) status;
Any thing else?
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
31576, modificat fa 16 anys.
Liferay Master
Apunts: 993
Data d'incorporació: 27/04/07
Publicacions recents
Hi Jorge,
It would be nice to know your plan on implementation of this feature. Please let me know what I can contribute on this feature.
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
It would be nice to know your plan on implementation of this feature. Please let me know what I can contribute on this feature.
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
34366, modificat fa 16 anys.
Junior Member
Apunts: 32
Data d'incorporació: 02/08/07
Publicacions recents
Hello
That's a great feature. Few thoughts:
Custom attributes UI that is available for users should be available as well for layout, documents, images and articles.
An advanced option of the search portlet could offer a select box in order to search contents by custom attributes.
A generic Expando portlet could offer a way to create an entity on the fly with custom attributes.
Administrators would design entities, columns, types...
Contributors would fill in tables with data (with an excel import functionnality mapped with expando columns)
And guests would see a table displayed on their web site with data (pagination, search engine, sorting with display tag) and could export in Excel
That would match a generic data list management need without much efforts thanks to the expdando system.
If we complete this portlet by adding an option "extends a Liferay entity" when you create a new entity that would let people create multiple extensions of a page, a user, a web article...
Everything seems to be in place in the service layer and we just need to work on UIs actually don't you think?
That's a great feature. Few thoughts:
Custom attributes UI that is available for users should be available as well for layout, documents, images and articles.
An advanced option of the search portlet could offer a select box in order to search contents by custom attributes.
A generic Expando portlet could offer a way to create an entity on the fly with custom attributes.
Administrators would design entities, columns, types...
Contributors would fill in tables with data (with an excel import functionnality mapped with expando columns)
And guests would see a table displayed on their web site with data (pagination, search engine, sorting with display tag) and could export in Excel
That would match a generic data list management need without much efforts thanks to the expdando system.
If we complete this portlet by adding an option "extends a Liferay entity" when you create a new entity that would let people create multiple extensions of a page, a user, a web article...
Everything seems to be in place in the service layer and we just need to work on UIs actually don't you think?
10437, modificat fa 16 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
@Jonas We are working on it. Keep a look at the commits in the next few days
@Amine The idea for a custom portlet to store data based on expandos sounds great. Do you have the time and knowledge to do a quick prototype?
@Amine The idea for a custom portlet to store data based on expandos sounds great. Do you have the time and knowledge to do a quick prototype?
34366, modificat fa 16 anys.
Junior Member
Apunts: 32
Data d'incorporació: 02/08/07
Publicacions recents
Hello Jorge
I have the knowledge but I'm very busy right now. I'll give you a prototype as soon as I can.
I was thinking about two portlets in the EXT environment.
- The first portlet would be an Expando Entity Designer. In a way I think it's going to be close to the ui for designing a web structure.
- The second portlet would be an Expando Entity Display. With the layout tag support we could paginate it and offer sorting functionnalities. With some higher permissions we would give a nice CRUD to fill in data thanks to jQuery.
And in edit mode we could select the entity to deal with and hide or make visible the "export into excel" icon or design the search engine in a "display settings" section.
I have a question about custom attributes and expando :
Entities have typed attributes composed by a key and a value.
Is there a way to store multi-lingual key names and multi-lingual values ?
I have the knowledge but I'm very busy right now. I'll give you a prototype as soon as I can.
I was thinking about two portlets in the EXT environment.
- The first portlet would be an Expando Entity Designer. In a way I think it's going to be close to the ui for designing a web structure.
- The second portlet would be an Expando Entity Display. With the layout tag support we could paginate it and offer sorting functionnalities. With some higher permissions we would give a nice CRUD to fill in data thanks to jQuery.
And in edit mode we could select the entity to deal with and hide or make visible the "export into excel" icon or design the search engine in a "display settings" section.
I have a question about custom attributes and expando :
Entities have typed attributes composed by a key and a value.
Is there a way to store multi-lingual key names and multi-lingual values ?
34366, modificat fa 16 anys.
Junior Member
Apunts: 32
Data d'incorporació: 02/08/07
Publicacions recents
I'm thinking about the design of such a UI for managing Expando tables and rows with Excel import/export capabilities.
I thought that the Expando service layer was suitable for storing user tables like that.
Moreover it can give the ability to extends existing Liferay entities.
But then I realized that localization aspect is missing in Expando.
So I tried to design a patch to Expando that would be able to consider multi-languages aspects.
Then a graphical ui that could define columns (name, type, order...).
And eventually I found that I was much too close to Web structures management in Liferay.
I surely don't want to code something that already exists.
If we put the Web Structure concept in a higher level, I think we would be close to a system that could manage expando, web structures, generic lists manager, custom attributes, and Library documents meta, altogether.
Advantages :
- We already have a good UI for designing web structures (ie for designing entities)
- An XML format that can be re-used for designing entities in general, not only for web contents but for docs as well and so on
- A rich editor
- Inheritance
- Localization capabilities (excepting for fields names but we could use messages)
- We can export/import this structure in LAR
- it's indexable
- It's been tested for a long time
- ...
What's missing? :
- Web Structure should be called "Entity Structure"
- Few Expando types should be added into the web structure types list
- A "classNameId" column should be added in EntityStructure table like in ExpandoTable
- The web structure UI should be moved into an "Entity Design" new link in the control panel and it should give the capability to choose a classNameId in a select list. (Web content, document, user, none...)
So that :
- A Web Structure would be just an "Entity Structure" that would have a classNameId = JournalArticle
- Custom attributes would be just an "Entity Structure" that would have a classNameId = User
- User Entities (for displaying generic tables with Excel export/import and pagination) would be "Entity Structure" that would have a classNameId to null
- An Alfresco-like aspect would be an "Entity Structure" that would have multiple values in "classNameId"
- ...
Do you think I should keep going further with this design? Or side effects of placing web structure in a higher level would be much too huge?
I thought that the Expando service layer was suitable for storing user tables like that.
Moreover it can give the ability to extends existing Liferay entities.
But then I realized that localization aspect is missing in Expando.
So I tried to design a patch to Expando that would be able to consider multi-languages aspects.
Then a graphical ui that could define columns (name, type, order...).
And eventually I found that I was much too close to Web structures management in Liferay.
I surely don't want to code something that already exists.
If we put the Web Structure concept in a higher level, I think we would be close to a system that could manage expando, web structures, generic lists manager, custom attributes, and Library documents meta, altogether.
Advantages :
- We already have a good UI for designing web structures (ie for designing entities)
- An XML format that can be re-used for designing entities in general, not only for web contents but for docs as well and so on
- A rich editor
- Inheritance
- Localization capabilities (excepting for fields names but we could use messages)
- We can export/import this structure in LAR
- it's indexable
- It's been tested for a long time
- ...
What's missing? :
- Web Structure should be called "Entity Structure"
- Few Expando types should be added into the web structure types list
- A "classNameId" column should be added in EntityStructure table like in ExpandoTable
- The web structure UI should be moved into an "Entity Design" new link in the control panel and it should give the capability to choose a classNameId in a select list. (Web content, document, user, none...)
So that :
- A Web Structure would be just an "Entity Structure" that would have a classNameId = JournalArticle
- Custom attributes would be just an "Entity Structure" that would have a classNameId = User
- User Entities (for displaying generic tables with Excel export/import and pagination) would be "Entity Structure" that would have a classNameId to null
- An Alfresco-like aspect would be an "Entity Structure" that would have multiple values in "classNameId"
- ...
Do you think I should keep going further with this design? Or side effects of placing web structure in a higher level would be much too huge?
31576, modificat fa 16 anys.
Liferay Master
Apunts: 993
Data d'incorporació: 27/04/07
Publicacions recents
Hi Amine, thank you. You do have good points on web content (Journal Article, Structure, Template).
Now the Expando (Custom Attributes ) is available for a set of objects: User, Organization, Wiki, Blogs, Bookmarks, Document, Image, etc. (See below screenshot)
Similar features would be useful for Document Library documents - CMS (DM and RM) of Alfresco.
Hi Jorge, thank you. It is very good that the Expando (Custom Attributes ) is available for any ServiceBuilder generated entities, especially for Document Library Document. Through custom attributes, documents can have many columns (metadata). That's cool.
I guess that there are a few limitations for Document Library plus Custom Attributes:
1) Custom attributes can only have basic data type. Custom data types like Document and Image are not supported yet.
2) Content Types can not be specified easily through custom attributes.
For example, there are two content types:
GAME - metadata: name, description, thumbnail, mini_game, keywords, etc.
VIDEO - metadata: name, description, title, thumbnail, large_thumbnail, medium_thumbnail, small_thumbnail, preview_video, etc.
How to implement above custom content types in Document Library plus Custom Attributes?
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2 Systems Development
Liferay Portal Enterprise Intranets
Now the Expando (Custom Attributes ) is available for a set of objects: User, Organization, Wiki, Blogs, Bookmarks, Document, Image, etc. (See below screenshot)
Similar features would be useful for Document Library documents - CMS (DM and RM) of Alfresco.
Hi Jorge, thank you. It is very good that the Expando (Custom Attributes ) is available for any ServiceBuilder generated entities, especially for Document Library Document. Through custom attributes, documents can have many columns (metadata). That's cool.
I guess that there are a few limitations for Document Library plus Custom Attributes:
1) Custom attributes can only have basic data type. Custom data types like Document and Image are not supported yet.
2) Content Types can not be specified easily through custom attributes.
For example, there are two content types:
GAME - metadata: name, description, thumbnail, mini_game, keywords, etc.
VIDEO - metadata: name, description, title, thumbnail, large_thumbnail, medium_thumbnail, small_thumbnail, preview_video, etc.
How to implement above custom content types in Document Library plus Custom Attributes?
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2 Systems Development
Liferay Portal Enterprise Intranets
1317658, modificat fa 16 anys.
Expert
Apunts: 462
Data d'incorporació: 17/09/08
Publicacions recents
I know this is an older post but I'm trying to implement custom attributes for bookmarks,document library,and images.. My users want a publish date and an small image url (similar to the Web Content)... We're using 5.2 Sp3 and I can't seem to an easy way to do it...
This post talks about what we want something were we don't have to change the backend for every new attribute (just controlling it on the frontend) but I don't see where this is actually done...
I think I'm going to have to use expandos and on the frontend(JSP) reference that Expandos value and then change the backend(Action) to save that value in the expando table is that correct?
Thanks
Whitt
This post talks about what we want something were we don't have to change the backend for every new attribute (just controlling it on the frontend) but I don't see where this is actually done...
I think I'm going to have to use expandos and on the frontend(JSP) reference that Expandos value and then change the backend(Action) to save that value in the expando table is that correct?
Thanks
Whitt
1373755, modificat fa 16 anys.
Liferay Legend
Apunts: 1261
Data d'incorporació: 02/10/08
Publicacions recents
4682465, modificat fa 15 anys.
Regular Member
Apunts: 221
Data d'incorporació: 05/03/10
Publicacions recents
hi..
i am using liferay 6.
In control panel there is a tab called custom fields,where we can add new meta data for portlet.
I created a new field for webcontent called webid.when i create a new web content this field is visible under abstract tab. when i enter value into that field and search that field in web-content search and normal search portlet i don't get the result...
can you tell me what i need to do,so that i can search the custom fields also..
i am not able to search using any custom attributes for any portlet.
Any idea or suggestions are welcome...
thanks in advance..
i am using liferay 6.
In control panel there is a tab called custom fields,where we can add new meta data for portlet.
I created a new field for webcontent called webid.when i create a new web content this field is visible under abstract tab. when i enter value into that field and search that field in web-content search and normal search portlet i don't get the result...
can you tell me what i need to do,so that i can search the custom fields also..
i am not able to search using any custom attributes for any portlet.
Any idea or suggestions are welcome...
thanks in advance..
10437, modificat fa 16 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
Hi Chris,
For the JSPs, I would recommend looking at the new ones from v6.0 which already have expandos integrated for bookmarks,document library,and images.
For the JSPs, I would recommend looking at the new ones from v6.0 which already have expandos integrated for bookmarks,document library,and images.
10437, modificat fa 16 anys.
Liferay Legend
Apunts: 2871
Data d'incorporació: 31/08/06
Publicacions recents
Hi Amine,
It's an interesting idea, although it's hard for me to know for sure if it's the best way to go. I'll keep in mind and talk about it with other Liferay architects when I have a chance.
If you do any further work on it (be it code, wireframes, ...) let me know.
Jorge
It's an interesting idea, although it's hard for me to know for sure if it's the best way to go. I'll keep in mind and talk about it with other Liferay architects when I have a chance.
If you do any further work on it (be it code, wireframes, ...) let me know.
Jorge
3386848, modificat fa 16 anys.
Expert
Apunts: 278
Data d'incorporació: 23/06/09
Publicacions recents
I'm not sure if I understand how custom attributes work. How can I add a custom attribute into a user's profile, and they will have to choose a picture from a drop down menu?
Baris
Baris
1070977, modificat fa 16 anys.
Liferay Legend
Apunts: 1668
Data d'incorporació: 15/07/08
Publicacions recents
Hi Baris,
you first have to add that custom attribute to Users (there is a button to do that in the users administration toolbar) and it will be automatically shown in the users administration in the section "Custo Attributes".
If you want to show it in the first page of the user administration (for example), then, you should use your ext environment to overwrite the jsp file for the profile of the user (enterprise_admin/user/details.jsp).
There is more info here: How to use Custom Attributes to enhance users
Julio
you first have to add that custom attribute to Users (there is a button to do that in the users administration toolbar) and it will be automatically shown in the users administration in the section "Custo Attributes".
If you want to show it in the first page of the user administration (for example), then, you should use your ext environment to overwrite the jsp file for the profile of the user (enterprise_admin/user/details.jsp).
There is more info here: How to use Custom Attributes to enhance users
Julio
Community
Company
Feedback