Commit f757be88 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

implement login feature by using a link to login_form in global navigations not by login widget.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@27039 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent edf5f8cf
......@@ -9,6 +9,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Cacheable__manager_id</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
......@@ -41,28 +47,29 @@
<tal:block replace="nothing">\n
<!--\n
This widget displays the login form.\n
This widget displays the breadcrumbs of the current context.\n
\n
TODO:\n
- implement \'Password forgottn?\' feature.\n
- why \'new-line\' between checkbox and \'Remember me\'?\n
- make sure translation is possible or working\n
-->\n
</tal:block>\n
\n
<div class="loginform">\n
<p><input type="hidden" name="rememberme" value="0" /></p>\n
<fieldset>\n
<p><label for="name" class="top" i18n:translate="" i18n:domain="ui">User:</label><br />\n
<input type="text" name="__ac_name" id="name" class="field" value=""\n
tal:attributes="value python: request.get(\'__ac_name\') or \'\'" /></p>\n
<p><label for="password" class="top" i18n:translate="" i18n:domain="ui">Password:</label><br />\n
<input type="password" name="__ac_password" id="password" class="field" value="" /></p>\n
<p><input type="checkbox" name="__ac_persistent" id="checkbox" class="cb_remember" value="1" checked="checked" /><label for="cb_remember" class="right" i18n:translate="" i18n:domain="ui">Remember me</label></p>\n
<p><input type="submit" name="WebSite_login:method" class="button" value="LOGIN" i18n:attributes="value" i18n:domain="ui" /></p>\n
<!-- <p><a href="#" id="forgotpsswd">Password forgotten?</a></p> -->\n
</fieldset>\n
<tal:block tal:define="current_web_section python:request.get(\'current_web_section\', here);\n
web_site_url python:current_web_section.getWebSiteValue().absolute_url();">\n
<div class="navglobal">\n
<ul>\n
<tal:block tal:condition="here/portal_membership/isAnonymousUser">\n
<li><a href="#" i18n:translate="" i18n:domain="ui"\n
tal:attributes="href python:\'%s/login_form\' % web_site_url">Login</a></li>\n
</tal:block>\n
<tal:block tal:condition="not:here/portal_membership/isAnonymousUser">\n
<li><a tal:attributes="href python:\'%s/logout\' % web_site_url">\n
<tal:block i18n:translate="" i18n:domain="ui">Logout</tal:block>\n
(<tal:block tal:replace="python:here.portal_membership.getAuthenticatedMember().getUserName()" />)</a></li>\n
</tal:block>\n
</ul>\n
</div>\n
</tal:block>
]]></string> </value>
</item>
......@@ -76,7 +83,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>WebSection_viewLoginWidget</string> </value>
<value> <string>WebSection_viewGlobalNavigationWidget</string> </value>
</item>
<item>
<key> <string>title</string> </key>
......
......@@ -15,7 +15,6 @@
<list>
<string>default</string>
<string>editable</string>
<string>enabled</string>
<string>title</string>
</list>
</value>
......@@ -58,6 +57,16 @@
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>default</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
......@@ -70,6 +79,10 @@
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
......@@ -96,10 +109,6 @@
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_editor_field</string> </value>
......@@ -122,4 +131,20 @@
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>here/WebSection_viewGlobalNavigationWidget</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -59,9 +59,11 @@
<dictionary>
<item>
<key> <string>default</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>field_id</string> </key>
......@@ -88,7 +90,26 @@
<dictionary>
<item>
<key> <string>default</string> </key>
<value> <string></string> </value>
<value> <string encoding="cdata"><![CDATA[
<div class="loginform">\n
<form method="post" action="index.html">\n
<p><input type="hidden" name="rememberme" value="0" /></p>\n
<fieldset>\n
<p><label for="username_1" class="top">User:</label><br />\n
<input type="text" name="username_1" id="username_1" tabindex="1" class="field" value="" /></p>\n
\n
<p><label for="password_1" class="top">Password:</label><br />\n
<input type="password" name="password_1" id="password_1" tabindex="2" class="field" value="" /></p>\n
<p><input type="checkbox" name="checkbox_1" id="checkbox_1" class="checkbox" tabindex="3" size="1" value="" /><label for="checkbox_1" class="right">Remember me</label></p>\n
<p><input type="submit" name="cmdweblogin" class="button" value="LOGIN" /></p>\n
<p><a href="#" id="forgotpsswd_1">Password forgotten?</a></p>\n
</fieldset>\n
</form>\n
\n
</div>
]]></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
......@@ -116,20 +137,4 @@
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>here/WebSection_viewLoginWidget</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
90
\ No newline at end of file
91
\ No newline at end of file
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