[extensions-web] auth: Make display_name editable
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [extensions-web] auth: Make display_name editable
- Date: Wed, 24 Oct 2012 15:14:32 +0000 (UTC)
commit 76b08f2b8757fb395f9270d49693bb1de08619d9
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Wed Oct 24 11:14:13 2012 -0400
auth: Make display_name editable
Whoops
.../auth/templates/registration/profile.html | 4 +---
sweettooth/static/js/main.js | 2 ++
2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/sweettooth/auth/templates/registration/profile.html b/sweettooth/auth/templates/registration/profile.html
index ca8b46a..7287e2f 100644
--- a/sweettooth/auth/templates/registration/profile.html
+++ b/sweettooth/auth/templates/registration/profile.html
@@ -5,9 +5,7 @@
{% load gravatar %}
<div class="profile">
{% if is_editable %}
- <h2 class="editable"
- id="new_display_name"
- editurl="{% url auth-ajax-edit-display-name %}">{{ display_name }}</h2>
+ <h2 class="editable" id="new_display_name">{{ display_name }}</h2>
{% else %}
<h2>{{ display_name }}</h2>
{% endif %}
diff --git a/sweettooth/static/js/main.js b/sweettooth/static/js/main.js
index 43589c5..52a3783 100644
--- a/sweettooth/static/js/main.js
+++ b/sweettooth/static/js/main.js
@@ -45,6 +45,8 @@ function($, messages, modal, hashParamUtils, templates) {
$("time").timeago();
+ $("#new_display_name").csrfEditable('/ajax/edit/display_name');
+
var $userPopupLink = $('#global_domain_bar .user');
var $userPopup = $('#global_domain_bar .user_popup');
function closeUserSettings() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]