Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

如何在一个表单页面,实现表单提交后,页面刷新,而不是跳转 #76

Open
flanliulf opened this issue Aug 7, 2014 · 2 comments

Comments

@flanliulf
Copy link

如何在一个表单页面,实现表单提交后,页面刷新,而不是跳转。
比方说我现在有个页面 xxx-start.jsp,该页面 form 表单的 action 为 xxx-saveResult,controller 中分别对应 start 和 saveResult 方法,这两个方法的 return 分别为buildDefaultHttpHeaders("start");和buildDefaultHttpHeaders();在 start.jsp 页面点击保存后,页面还是会跳转到/prototype/test/xxx!saveResult,地址栏就会显示.../prototype/test/xxx!saveResult,如何让当前的表单页面停留呢?,或者跳转到另一个页签 tab,或者跳转到指定的页面比如/prototype/layout#/PCSTGL

@xautlx
Copy link
Owner

xautlx commented Aug 8, 2014

prototype里面的“销售单创建”好像就是这个效果吧

@flanliulf
Copy link
Author

额,"销售单创建"的确是保存后刷新了页面,但是我仔细看了一下 jsp 和 controller 的代码,发现配置和我上面说的差不多啊,但是我上面的做法还是会跳转到 form 表单设置的 action 方法对应的页面去,难道是 edit->doSave 可以, method1->method2就不行?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants