You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by br...@apache.org on 2014/05/28 00:00:00 UTC
[3/8] git commit: [#7372] ticket:583 Factor up menu for account
related pages
[#7372] ticket:583 Factor up menu for account related pages
Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/c4bc6059
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/c4bc6059
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/c4bc6059
Branch: refs/heads/master
Commit: c4bc60599a8e35f4970ad73c5d9df960221f77eb
Parents: bab493a
Author: Igor Bondarenko <je...@gmail.com>
Authored: Wed May 14 11:23:40 2014 +0300
Committer: Dave Brondsema <db...@slashdotmedia.com>
Committed: Fri May 23 18:02:37 2014 +0000
----------------------------------------------------------------------
Allura/allura/templates/oauth_applications.html | 14 ++-------
Allura/allura/templates/user_account_base.html | 33 ++++++++++++++++++++
Allura/allura/templates/user_availability.html | 14 ++-------
Allura/allura/templates/user_contacts.html | 14 ++-------
.../allura/templates/user_disable_account.html | 18 +++--------
Allura/allura/templates/user_info.html | 14 ++-------
Allura/allura/templates/user_prefs.html | 14 ++-------
Allura/allura/templates/user_skills.html | 14 ++-------
Allura/allura/templates/user_subs.html | 14 ++-------
9 files changed, 52 insertions(+), 97 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/oauth_applications.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/oauth_applications.html b/Allura/allura/templates/oauth_applications.html
index 3742662..7506975 100644
--- a/Allura/allura/templates/oauth_applications.html
+++ b/Allura/allura/templates/oauth_applications.html
@@ -17,7 +17,7 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Applications {% endblock %}
@@ -69,17 +69,7 @@
{% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
+ {{ super() }}
<h2>Authorized Applications</h2>
<p>
These are applications you have authorized to act on your behalf.
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_account_base.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_account_base.html b/Allura/allura/templates/user_account_base.html
new file mode 100644
index 0000000..eb68667
--- /dev/null
+++ b/Allura/allura/templates/user_account_base.html
@@ -0,0 +1,33 @@
+{#-
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-#}
+{% set hide_left_bar = True %}
+{% extends g.theme.master %}
+
+{% block content %}
+ <ul id="account-nav-menu" class="b-hornav droppy">
+ {% for item in menu -%}
+ <li id="{{ item.tabid }}">
+ <a href="{{ item.target }}">
+ {{ item.title }}
+ <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
+ </a>
+ </li>
+ {%- endfor %}
+ </ul>
+{% endblock %}
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_availability.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_availability.html b/Allura/allura/templates/user_availability.html
index c10cdee..aa6b90b 100644
--- a/Allura/allura/templates/user_availability.html
+++ b/Allura/allura/templates/user_availability.html
@@ -17,24 +17,14 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Availability{% endblock %}
{% block header %}Availability timeslots of {{c.user.username}} {% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
+ {{ super() }}
<div class="grid-20">
<h2>Availability</h2>
<div class="grid-18">
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_contacts.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_contacts.html b/Allura/allura/templates/user_contacts.html
index 7495508..399a5c6 100644
--- a/Allura/allura/templates/user_contacts.html
+++ b/Allura/allura/templates/user_contacts.html
@@ -17,24 +17,14 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Contacts{% endblock %}
{% block header %}Contacts of {{c.user.username}} {% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
+ {{ super() }}
<div class="grid-20">
<h2>Personal Contacts</h2>
<h3>Skype account</h3>
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_disable_account.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_disable_account.html b/Allura/allura/templates/user_disable_account.html
index 631b7ef..6542902 100644
--- a/Allura/allura/templates/user_disable_account.html
+++ b/Allura/allura/templates/user_disable_account.html
@@ -17,23 +17,15 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Disable account{% endblock %}
{% block header %}Disable account for {{c.user.username}}{% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
- <h2>Disable account</h2>
+ {{ super() }}
+ <div class='grid-20'>
+ <h2>Disable account</h2>
+ </div>
{% endblock %}
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_info.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_info.html b/Allura/allura/templates/user_info.html
index 7e49658..7d08900 100644
--- a/Allura/allura/templates/user_info.html
+++ b/Allura/allura/templates/user_info.html
@@ -17,24 +17,14 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Preferences{% endblock %}
{% block header %}User Preferences for {{c.user.username}}{% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
+ {{ super() }}
<div style="clear:both" class="grid-20">
<h2>Personal Information</h2>
{{g.theme.personal_data_form.display(action="/auth/user_info/change_personal_data", user=c.user)}}
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_prefs.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_prefs.html b/Allura/allura/templates/user_prefs.html
index 900c9f0..36a7463 100644
--- a/Allura/allura/templates/user_prefs.html
+++ b/Allura/allura/templates/user_prefs.html
@@ -17,24 +17,14 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Preferences{% endblock %}
{% block header %}User Preferences for {{c.user.username}}{% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
+ {{ super() }}
<div class="grid-23">
<h2>Preferences</h2>
<form action="update" method="post">
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_skills.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_skills.html b/Allura/allura/templates/user_skills.html
index cc5d02b..780916c 100644
--- a/Allura/allura/templates/user_skills.html
+++ b/Allura/allura/templates/user_skills.html
@@ -17,24 +17,14 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Skills{% endblock %}
{% block header %}Skills manager for {{c.user.username}} {% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
+ {{ super() }}
<div class="grid-20">
{% if c.user.get_skills()|length > 0 %}
<h2>Your current skills list:</h2>
http://git-wip-us.apache.org/repos/asf/allura/blob/c4bc6059/Allura/allura/templates/user_subs.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/user_subs.html b/Allura/allura/templates/user_subs.html
index 7e90a17..15f3a7c 100644
--- a/Allura/allura/templates/user_subs.html
+++ b/Allura/allura/templates/user_subs.html
@@ -17,24 +17,14 @@
under the License.
-#}
{% set hide_left_bar = True %}
-{% extends g.theme.master %}
+{% extends "allura:templates/user_account_base.html" %}
{% block title %}{{c.user.username}} / Preferences{% endblock %}
{% block header %}User Preferences for {{c.user.username}}{% endblock %}
{% block content %}
- <ul id="account-nav-menu" class="b-hornav droppy">
- {% for item in menu -%}
- <li id="{{ item.tabid }}">
- <a href="{{ item.target }}">
- {{ item.title }}
- <div class="marker{% if item.target.rstrip('/') == request.path.rstrip('/') %} current{% endif %}"></div>
- </a>
- </li>
- {%- endfor %}
- </ul>
-
+ {{ super() }}
<h2>Subscriptions</h2>
{% if subscriptions %}
<p><em>Mark tools that you want to subscribe to. Unmark tools that you want to unsubscribe from. Press 'Save' button.</em></p>