• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Portlet modes

 
Dorothy Taylor
Ranch Hand
Posts: 104
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Suppose I have a portlet that shows me some info about a person from the database. I have to provide a way by which the info can be edited as well by the logged in user.

So what is the best way to do it. Should an edit link be provided in the portlet or should this be done in the edit portlet mode, or in the configure mode?

I am using Struts 1.1., JSR-168 portlets on RAD 6.0

Thanks..
 
Saravanan Mahalingam
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I suggest that your first option is best one. You can add Edit link/button to do this functionality in View mode itself. Most commonly edit mode can be used for setting up the user preferences. For e.g., if you want to restrict number of user records to be displayed in the view mode, you can provide a text box in Edit mode in which user can give number of records to be displayed.
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Let's turn this into a philisophical argument.

What is the purpose of the edit mode? I'd say that the purpose of the edit mode it to change how the portlet itself renders, displays, or behaves. The edit mode is really designed to edit the portlet, and portlet properties, not necessarily the data displayed in the portlet.

So, if I have a person details portlet, to me, the edit mode might do things like add a new field to display about the user, or the edit mode might be used to remove the 'middle-name' textfield on the portlet. But can you see how, philisophically, the edit button is being used to change the behavior of the PORTLET, and not change the behavior or the state of the data in which the portlet resides.

The data being displayed about a user in a portlet is NOT a property of the portlet. My name is NOT a portlet preference. If I want to change my last name, I shouldn't have to the edit mode of the portlet, because my name has nothing to do with the portlet. If I want to edit my name, there should be a button on the view mode of the portlet that allows me to update my personal information.

Is what I'm saying making sense?

To me, the edit mode is designed to edit the portlet, and how the portlet does certain things.

-Cameron McKenzie
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Dorothy",
Please check your private messages.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic