You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ofbiz.apache.org by "Deepak Dixit (JIRA)" <ji...@apache.org> on 2017/07/27 11:29:00 UTC
[jira] [Comment Edited] (OFBIZ-9537) In case of reqeust redirect
context filter override the redirect parameter
[ https://issues.apache.org/jira/browse/OFBIZ-9537?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16103077#comment-16103077 ]
Deepak Dixit edited comment on OFBIZ-9537 at 7/27/17 11:28 AM:
---------------------------------------------------------------
Removed unused and dead code from RequestHandler, as _REQ_ATTR_MAP_ is removed from session in ContextFilter so it will always be null while accessing this in RequestHandler.
Thanks Jacopo
was (Author: deepak.dixit):
Removed unused and dead code from RequestHandler, as _REQ_ATTR_MAP_ is removed from session in ContextFilter so it will always be null while accessing this in RequestHandler.
> In case of reqeust redirect context filter override the redirect parameter
> --------------------------------------------------------------------------
>
> Key: OFBIZ-9537
> URL: https://issues.apache.org/jira/browse/OFBIZ-9537
> Project: OFBiz
> Issue Type: Bug
> Affects Versions: Trunk, 16.11.03
> Reporter: Deepak Dixit
> Assignee: Deepak Dixit
> Attachments: OFBIZ-9537.patch, OFBIZ-9537.patch
>
>
> In case of request redirect ContextFilter override the redirect parameter
> Like if you use following pattern
> {code}
> <request-map uri="createTask">
> <security https="true" auth="true"/>
> <event type="service" invoke="createWorkEffort"/>
> <response name="success" type="request-redirect" value="ViewWorkEffort">
> <redirect-parameter name="workEffortId" from="workEffortParentId"/>
> </response>
> <response name="error" type="request" value="ViewWorkEffort"/>
> </request-map>
> {code}
> In this case service creates new workEffort and put the newly created workEffortId in requestAttribute,
> but in response we are redirecting parentWorkEffortId as workEffortId,
> so in this case context filter override the workEffortId that passed as redirect parameter, and replace it with newly created workEffortId.
> This is due to restoring all the redirected parameter instead of default one.
> Need to restore only success/error message so redirected page can display previous request's error msg etc.
> This is handled in RequestHandler.java.
> As in case of request redirect we pass the redirect parameter name so instead of restoring all the previous redirected parameter restore only error/success message related parameter.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)