Commit cbad2c8a authored by Jean-Paul Smets's avatar Jean-Paul Smets

Better support for erp5_web login

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@12662 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 103e5d97
...@@ -61,12 +61,12 @@ ...@@ -61,12 +61,12 @@
isAnon mtool/isAnonymousUser|nothing;">\n isAnon mtool/isAnonymousUser|nothing;">\n
<tal:block tal:condition="isAnon">\n <tal:block tal:condition="isAnon">\n
<tal:block tal:define="dummy python: response.expireCookie(\'__ac\', path=\'/\');\n <tal:block tal:define="dummy python: response.expireCookie(\'__ac\', path=\'/\');\n
url python: \'%s/login_form?portal_status_message=%s\' % (here.portal_url(), here.getPortalObject().Localizer.translate(\'ui\', \'Login+and/or+password+is+incorrect.\'));\n url python: \'%s/login_form?portal_status_message=%s\' % (here.absolute_url(), here.getPortalObject().Localizer.translate(\'ui\', \'Login+and/or+password+is+incorrect.\'));\n
url python: request.get(\'came_from\') and \'%s&came_from=%s\' % (url, request[\'came_from\']) or url;\n url python: request.get(\'came_from\') and \'%s&came_from=%s\' % (url, request[\'came_from\']) or url;\n
dummy python: response.redirect(url);"/>\n dummy python: response.redirect(url);"/>\n
</tal:block>\n </tal:block>\n
<tal:block tal:condition="not: isAnon">\n <tal:block tal:condition="not: isAnon">\n
<tal:block tal:define="came_from python: request.get(\'came_from\') or here.portal_url() + \'/view\';\n <tal:block tal:define="came_from python: request.get(\'came_from\') or here.absolute_url() + \'/view\';\n
dummy python: response.redirect(came_from);" />\n dummy python: response.redirect(came_from);" />\n
</tal:block>\n </tal:block>\n
</tal:block> </tal:block>
......
...@@ -85,6 +85,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n ...@@ -85,6 +85,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n
-->\n -->\n
</tal:block>\n </tal:block>\n
<tal:block tal:define="form_action string:logged_in;\n <tal:block tal:define="form_action string:logged_in;\n
global form_id string:login_form;\n
js_list python: [\'%s/login_form.js\' % (here.portal_url.getPortalPath(), )]">\n js_list python: [\'%s/login_form.js\' % (here.portal_url.getPortalPath(), )]">\n
<tal:block metal:use-macro="here/main_template/macros/master">\n <tal:block metal:use-macro="here/main_template/macros/master">\n
<tal:block metal:fill-slot="main">\n <tal:block metal:fill-slot="main">\n
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment