Commit 851a2824 authored by Jérome Perrin's avatar Jérome Perrin

web_renderjs_ui: make login pages use same DOM as dialogs

This way, the padding between fields will be applied and the visual
result would be similar as on all other ERP5JS dialogs
parent 073708c2
......@@ -27,21 +27,23 @@
<article>
<section>
<form method="post" tal:attributes="action python: context.absolute_url()">
<form method="post" tal:attributes="action python: context.absolute_url()" class="field_container">
<div>
<div>
<div class="ui-field-contain">
<label i18n:domain="ui" i18n:translate="">Username</label>
<div><input autofocus type="text" name="user_login" value="" required=""></div>
</div>
<br/>
<div class="ui-field-contain">
<label></label>
<div><input type="submit" value="Validate" i18n:attributes="value" i18n:domain="ui" tal:attributes="name python: '%s:method' % (form_action, )"/></div>
<div class="dialog_button_container">
<input type="submit" value="Validate" i18n:attributes="value" i18n:domain="ui" tal:attributes="name python: '%s:method' % (form_action, )"/>
</div>
<input type="hidden" name="url" tal:attributes="value python: context.absolute_url()" />
<input tal:condition="exists: request/came_from"
type="hidden" name="came_from"
tal:attributes="value request/came_from" />
</div>
</div>
</form>
</section>
</article>
......
......@@ -26,7 +26,9 @@
<article class="ui-content">
<section>
<form method="post" tal:attributes="action python: context.absolute_url()">
<form method="post" tal:attributes="action python: context.absolute_url()" class="field_container">
<div>
<div>
<div class="ui-field-contain">
<label data-i18n="New Password">New Password<span></span></label>
<div><input autofocus name="password" type="password" value="" required=""></div>
......@@ -35,13 +37,13 @@
<label data-i18n="New Password Confirmation">New Password Confirmation<span></span></label>
<div><input name="password_confirm" type="password" value="" required=""></div>
</div>
<div class="ui-field-contain">
<label></label>
<div><input type="submit" value="Validate" tal:attributes="name python: '%s:method' % (form_action, )"/></div>
<div class="dialog_button_container">
<input type="submit" value="Validate" tal:attributes="name python: '%s:method' % (form_action, )"/>
</div>
<input type="hidden" name="came_from" tal:attributes="value python: context.absolute_url()" />
<input type="hidden" name="password_key" tal:attributes="value python: request.get('reset_key') or ''" />
</div>
</div>
</form>
</section>
</article>
......
......@@ -39,8 +39,10 @@
</section>
<section tal:condition="portal/portal_membership/isAnonymousUser">
<form method="post" tal:attributes="action python: '%s/' % absolute_url">
<form method="post" tal:attributes="action python: '%s/' % absolute_url" class="field_container">
<div>
<div>
<div class="ui-field-contain">
<label i18n:domain="ui" i18n:translate="" >Username</label>
<div><input autofocus type="text" name="__ac_name" value="" required=""></div>
......@@ -49,15 +51,11 @@
<label i18n:domain="ui" i18n:translate="" >Password</label>
<div><input type="password" name="__ac_password" value="" required="" autocomplete="off" /></div>
</div>
<div class="ui-field-contain">
<label></label>
<div>
<div class="dialog_button_container">
<input type="submit" value="Validate" i18n:attributes="value" i18n:domain="ui" tal:attributes="name python: '%s:method' % (form_action, )"/>
<a i18n:domain="ui" i18n:translate="" tal:attributes="href python: '%s/WebSite_viewRecoverAccount?came_from=%s' % (absolute_url, absolute_url)">I forgot my password!</a>
</div>
</div><br/>
<div class="ui-field-contain">
<label></label>
<div><input type="submit" value='Login' i18n:attributes="value" i18n:domain="ui" tal:attributes="name python: '%s:method' % (form_action, )"/></div>
</div>
</div>
......
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