sohami commented on issue #1787: DRILL-7203: Back button not working 
URL: https://github.com/apache/drill/pull/1787#issuecomment-494487972
 
 
   @kkhatua : I am not sure if this is the right way to fix this issue. The 
issue as you mentioned is because we are loading the response from server in 
same page. I guess the reason for that is because any error in query on server 
side is also send as a HTTP success response. So we just chose to update the 
/query page with either actual result or exception from server side. Please 
consider below 2 options:
   
   1) Create a single `queryResult.ftl` page or repurpose `result.ftl` page, 
now on server side based on success or failure we populate it with either 
result.ftl or errorMessage.ftl template. In this way the form on /query page 
can always be directed to load /queryResult.ftl page (I guess using the 
`action` property)
   2) Somehow in success handler of ajax post request get the response page URL 
and load that url with the response data. Or may be use redirection mechanism 
to load the result page. Something like here: 
https://stackoverflow.com/questions/199099/how-to-manage-a-redirect-request-after-a-jquery-ajax-call

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to