Skip to content

Commit

Permalink
Reorder items on user edit page (bug 674018)
Browse files Browse the repository at this point in the history
  • Loading branch information
gkoberger committed Jul 25, 2011
1 parent 51f449a commit b0dc61b
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 28 deletions.
60 changes: 32 additions & 28 deletions apps/users/templates/users/edit_impala.html
Expand Up @@ -58,6 +58,11 @@ <h4>{{ _('Delete Account') }}</h4>
</label>
{{ form.emailhidden.errors }}
</li>
<li>
<label>&nbsp;</label>
<a href="#acct-password" id="change-acct-password">
{{ _('Change Password') }}</a>
</li>
</ul>
</fieldset>

Expand Down Expand Up @@ -85,27 +90,6 @@ <h4>{{ _('Delete Account') }}</h4>
</li>
</ol>
</fieldset>

<fieldset id="acct-notify">
<legend>{{ _('Notifications') }}</legend>
<p>
{% trans %}
From time to time, Mozilla may send you email about upcoming
releases and add-on events. Please select the topics you are
interested in below:
{% endtrans %}
</p>
{{ form.notifications }}

<p class="note">
{% trans %}
Mozilla reserves the right to contact you individually about
specific concerns with your hosted add-ons.
{% endtrans %}
</p>
</fieldset>
</div>{# /#user-account #}
<div id="user-profile" class="tab-panel">
<fieldset id="profile-personal">
<legend>{{ _('Profile information') }}</legend>
<ol>
Expand Down Expand Up @@ -157,24 +141,44 @@ <h4>{{ _('Delete Account') }}</h4>
{{ some_html_tip() }}
{{ form.bio.errors }}
</fieldset> {# /.profile-detail #}

<ul>
<li>
<fieldset id="profile-detail" class="clearboth">
<legend>{{ _('Miscellaneous') }}</legend>
<ul>
<li>
<label for="id_display_collections" class="check">
{{ form.display_collections }}
{{ _('Display the collections I have created') }}
</label>
{{ form.display_collections.errors }}
</li>
<li>
</li>
<li>
<label for="id_display_collections_fav" class="check">
{{ form.display_collections_fav }}
{{ _("Display collections I'm following") }}
</label>
{{ form.display_collections_fav.errors }}
</li>
</ul>
</li>
</ul>
</fieldset>

<fieldset id="acct-notify">
<legend>{{ _('Notifications') }}</legend>
<p>
{% trans %}
From time to time, Mozilla may send you email about upcoming
releases and add-on events. Please select the topics you are
interested in below:
{% endtrans %}
</p>
{{ form.notifications }}

<p class="note">
{% trans %}
Mozilla reserves the right to contact you individually about
specific concerns with your hosted add-ons.
{% endtrans %}
</p>
</fieldset>
</div>{# /#user-profile #}
<div class="listing-footer">
<button type="submit" class="button prominent">{{ _('Update') }}</button>
Expand Down
8 changes: 8 additions & 0 deletions media/js/impala/users.js
Expand Up @@ -5,4 +5,12 @@ $(function() {
$this.closest('li').find('input:not([disabled]').attr('checked', $this.hasClass('more-all'));
}));
}

// Hide change password box
$('#acct-password').hide();
$('#change-acct-password').click(_pd(function() {
$('#acct-password').show();
$('#id_oldpassword').focus();
$(this).closest('li').hide();
}));
});

0 comments on commit b0dc61b

Please sign in to comment.