Last modified: 2007-01-23 20:10:15 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 8712 - Expose user groups as JavaScript variable
Expose user groups as JavaScript variable
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
: patch-reviewed
Depends on:
Blocks: 8741
  Show dependency treegraph
 
Reported: 2007-01-20 00:45 UTC by Carl Fürstenberg
Modified: 2007-01-23 20:10 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
Patch implementing the functionallity (549 bytes, patch)
2007-01-20 16:16 UTC, Carl Fürstenberg
Details
updated patch (629 bytes, patch)
2007-01-23 16:34 UTC, Carl Fürstenberg
Details

Description Carl Fürstenberg 2007-01-20 00:45:25 UTC
Sometimes you want to have scripts funtion slightly different if you are admin
or not, and it's sometimes rather diffcult to do that. So I propose that a
variable is added, for example "wgUserGroup", that contain the usergroup(s). the
only problem is that if it only should have the "highest" group, or if it should
contain an array of all groups, for example: 

  wgUserGroups = [ 'autoconfirmed' , 'sysop' ];
Comment 1 Carl Fürstenberg 2007-01-20 16:16:51 UTC
Created attachment 3101 [details]
Patch implementing the functionallity

Have made an simple patch that will implement the wanted feature
Comment 2 Rob Church 2007-01-20 19:38:58 UTC
Applied in r19524.
Comment 3 Carl Fürstenberg 2007-01-23 16:34:28 UTC
Created attachment 3126 [details]
updated patch

seems like User::getGroups() don't reply with all we want, so I have changed it
to User::getEffectiveGroups();
Comment 4 Antoine "hashar" Musso (WMF) 2007-01-23 20:10:15 UTC
Applied as r19611

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links