summaryrefslogtreecommitdiffstats
path: root/extensions/BMO/web
diff options
context:
space:
mode:
authorByron Jones <bjones@mozilla.com>2013-08-01 08:15:20 +0200
committerByron Jones <bjones@mozilla.com>2013-08-01 08:15:20 +0200
commit612dd017fd0901d653fb8145385079a578b74caa (patch)
tree8060c14e6544f2e3981281513f56be4b1fa9e887 /extensions/BMO/web
parente985249f971bdeebb498e6f8ba6cc5ff4d160d97 (diff)
downloadbugzilla-612dd017fd0901d653fb8145385079a578b74caa.tar.gz
bugzilla-612dd017fd0901d653fb8145385079a578b74caa.tar.xz
Bug 859550: Create a user profile page for bugzilla users
Diffstat (limited to 'extensions/BMO/web')
-rw-r--r--extensions/BMO/web/js/edituser_menu.js14
1 files changed, 7 insertions, 7 deletions
diff --git a/extensions/BMO/web/js/edituser_menu.js b/extensions/BMO/web/js/edituser_menu.js
index 4f6d6ec69..383418430 100644
--- a/extensions/BMO/web/js/edituser_menu.js
+++ b/extensions/BMO/web/js/edituser_menu.js
@@ -3,6 +3,7 @@ var usermenu_widget;
YAHOO.util.Event.onDOMReady(function() {
usermenu_widget = new YAHOO.widget.Menu('usermenu_widget', { position : 'dynamic' });
usermenu_widget.addItems([
+ { text: 'Profile', url: '#', target: '_blank' },
{ text: 'Activity', url: '#', target: '_blank' },
{ text: 'Mail', url: '#', target: '_blank' },
{ text: 'Edit', url: '#', target: '_blank' }
@@ -16,15 +17,14 @@ function show_usermenu(event, id, email, show_edit) {
if (event.ctrlKey || event.shiftKey || event.altKey || event.metaKey)
return true;
usermenu_widget.getItem(0).cfg.setProperty('url',
- 'page.cgi?id=user_activity.html&action=run' +
- '&from=' + YAHOO.util.Date.format(new Date(new Date() - (1000 * 60 * 60 * 24 * 14)), {format: '%Y-%m-%d'}) +
- '&to=' + YAHOO.util.Date.format(new Date(), {format: '%Y-%m-%d'}) +
- '&who=' + encodeURIComponent(email));
- usermenu_widget.getItem(1).cfg.setProperty('url', 'mailto:' + encodeURIComponent(email));
+ 'user_profile?login=' + encodeURIComponent(email));
+ usermenu_widget.getItem(1).cfg.setProperty('url',
+ 'page.cgi?id=user_activity.html&action=run&from=-14d&who=' + encodeURIComponent(email));
+ usermenu_widget.getItem(2).cfg.setProperty('url', 'mailto:' + encodeURIComponent(email));
if (show_edit) {
- usermenu_widget.getItem(2).cfg.setProperty('url', 'editusers.cgi?action=edit&userid=' + id);
+ usermenu_widget.getItem(3).cfg.setProperty('url', 'editusers.cgi?action=edit&userid=' + id);
} else {
- usermenu_widget.removeItem(2);
+ usermenu_widget.removeItem(3);
}
usermenu_widget.cfg.setProperty('xy', YAHOO.util.Event.getXY(event));
usermenu_widget.show();