projects
/
GitHub
/
WoltLab
/
WCF.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2987375
)
Updating badge on user panel loaded
author
Alexander Ebert
<ebert@woltlab.com>
Sun, 28 Apr 2013 12:54:59 +0000
(14:54 +0200)
committer
Alexander Ebert
<ebert@woltlab.com>
Sun, 28 Apr 2013 12:54:59 +0000
(14:54 +0200)
wcfsetup/install/files/js/WCF.js
patch
|
blob
|
blame
|
history
diff --git
a/wcfsetup/install/files/js/WCF.js
b/wcfsetup/install/files/js/WCF.js
index f7502b077f7aad804035f1d3477bfa046b14e702..37b37f30e9b7a7a5117d1fd319fb28f2e113fba0 100755
(executable)
--- a/
wcfsetup/install/files/js/WCF.js
+++ b/
wcfsetup/install/files/js/WCF.js
@@
-7723,6
+7723,14
@@
WCF.UserPanel = Class.extend({
if (data.returnValues && data.returnValues.template) {
$('' + data.returnValues.template).prependTo($dropdownMenu);
+
+ // update badge
+ var $badge = this._container.find('.badge');
+ if (!$badge.length) {
+ $badge = $('<span class="badge badgeInverse" />').appendTo(this._container.children('.dropdownToggle'));
+ }
+ $badge.html(data.returnValues.totalCount);
+
this._after($dropdownMenu);
}
else {