Hi,I suspect that this a very basic question but I'm kind of new to all of this so you're patience is appreciated.I designing a web front end to display data retrieved from a database. No big deal in that except that different users will require the data to be presented differently e.g. a status page for one user might display fields a,b,c while a status page for another user might display fields x,y,z. The majority of the site will be generic and customer independent.What I need to know is am I required to have a different template for each customer e.g. Cust1-Status.jsp, Cust2-Status.jsp etc or is there a more elegant solution to this.regardsNoel
That is not a basic question? This is a question that is tough to answer. The two solutions I ahve used in the past are:
First let me clarify customer:
A customer in this case is not like a Yahoo mail user. A customer is an organization who is using your application in a different way another group of people are using it.
1) Create a different view for each customer.
PRO: If one customer requires some wierd thing it is easy to implement when each customer has its own JSP.
Adding a new view does not reqire testing all the other views for teh given model.
CON: You have many similar JSPs to maintain.
2) Create one view that can be customized by the customer.
PRO: Smaller number of JSPs to maintain.
CON: The one view becomes very complex to meet the needs of all your clients.
The one view becomes a bear to test.
Generally I have found solution 1 to be a more maintainable solution. If using MVC this is a very easy to implement one model and one controll with one view. Then if a customer requests a change to a view you can easily add another view to the struts config or spring xml files.