with plain jsp i don't know, but using a little trick inside the portlet do view you
could.
the problem is from the processAction / doView method. doView keep renderParam (set in
processAction), therefore, render 'old' data when switching back using the tab
button. Unfortunately ActionRequest doesn't allow us to remove a renderParam - That
would solve the problem - I tried using Attributes, properties but none seem to work.
The 'trick' I'm using in a similar problems is to pass param from
processAction to doView using... session ! yes, it's quite dirty. Sample :
| public void processAction(ActionRequest request, ActionResponse response) throws
PortletException, IOException {
|
| PortletSession session = request.getPortletSession(true);
| if (session != null) {
| String todo = request.getParameter("articleedit_todo");
| session.setAttribute("todo", todo);
| }
| //......
| }
|
| public void doView(RenderRequest request, RenderResponse response) throws
PortletException, IOException {
| //.......
| PortletSession session = request.getPortletSession(true);
| Object todo = session.getAttribute("todo");
| session.setAttribute("todo", null);
| if ((todo == null ? "" : todo.toString()).compareTo("goedit") ==
0) {
|
getPortletContext().getRequestDispatcher("/WEB-INF/jsp/articles/ACAdminArticleEditPortlet_view.jsp").include(request,
response);
| } else {
|
getPortletContext().getRequestDispatcher("/WEB-INF/jsp/articles/ACAdminArticlePortlet_view.jsp").include(request,
response);
| }
| }
| }
A+
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4152587#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...