Fórum

Best Practices

Becas Vasilis, modificado 11 Anos atrás.

Best Practices

Junior Member Postagens: 28 Data de Entrada: 30/08/12 Postagens Recentes
Hey Liferayers

I will use a simple example to describe my problem so you can guide me to the best practice.

The main purpose of the site is to list products. Products can be categorized by region or category. For each region we have a layout (all the region layouts have the same look n feel) where we have a portlet for listing the products of that region, a portlet where we have the relevant articles for that region (asset publisher with filter), a portlet where we have the relevant news for that region (asset publisher with filter) and a portlet where we have some info for that region.

Shall i create a new entity "Regions" with service builder, then create a webform so the user/admin can input a new region with all the data we need, and after the submission of the form, programmaticaly create a new layout and place and configure programmatically the portlets i need in it. Or shall i create a layout template with the portlets i need in it, and then have a vocabulary with all the regions i need and filter all the portlets by that vocabulary in the template?

I want the layout to have 4 portlets in it:
- one asset publisher for the articles of that region
- one asset publisher for the news of that region
- one asset publisher or webcontent (with the info for that region)
- one custom portlet or an asset publisher (with custom view) for listing the products.

So what is the best practice for that? Shall i create different layout(page) for each region, or having one template and filter the content in it somehow?And if i use the template solution how i will create links to that template in the main navigation?


I hope i made my self clear

With Regards,
Vasilis
thumbnail
Juan Gonzalez P, modificado 11 Anos atrás.

RE: Best Practices

Liferay Legend Postagens: 3089 Data de Entrada: 28/10/08 Postagens Recentes
Mmm and what if Regions are Sites/Organizations each one, so it's easier to isolate all data from each one?

You can categorize sites with tags/categories too.

And after that you can have Site templates so region creation should be easy.