Index: trunk/phase3/includes/SpecialUserrights.php |
— | — | @@ -154,6 +154,7 @@ |
155 | 155 | } |
156 | 156 | |
157 | 157 | $this->showEditUserGroupsForm( $username, $user->getGroups() ); |
| 158 | + $this->showLogFragment( $user, $wgOut ); |
158 | 159 | } |
159 | 160 | |
160 | 161 | /** |
— | — | @@ -376,5 +377,26 @@ |
377 | 378 | } |
378 | 379 | return $groups; |
379 | 380 | } |
380 | | -} // end class UserrightsForm |
381 | | - |
| 381 | + |
| 382 | + /** |
| 383 | + * Show a rights log fragment for the specified user |
| 384 | + * |
| 385 | + * @param User $user User to show log for |
| 386 | + * @param OutputPage $output OutputPage to use |
| 387 | + */ |
| 388 | + protected function showLogFragment( $user, $output ) { |
| 389 | + $viewer = new LogViewer( |
| 390 | + new LogReader( |
| 391 | + new FauxRequest( |
| 392 | + array( |
| 393 | + 'type' => 'rights', |
| 394 | + 'page' => $user->getUserPage()->getPrefixedUrl(), |
| 395 | + ) |
| 396 | + ) |
| 397 | + ) |
| 398 | + ); |
| 399 | + $output->addHtml( "<h2>" . htmlspecialchars( LogPage::logName( 'rights' ) ) . "</h2>\n" ); |
| 400 | + $viewer->showList( $output ); |
| 401 | + } |
| 402 | + |
| 403 | +} |
\ No newline at end of file |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -113,6 +113,7 @@ |
114 | 114 | * (bug 10387) Detect and handle '.php5' extension environments at install time |
115 | 115 | Patch by Edward Z. Yang. |
116 | 116 | * Introduce 'ShowRawCssJs' hook; see docs/hooks.txt for more information |
| 117 | +* (bug 10404) Show rights log fragment for the selected user in Special:Userrights |
117 | 118 | |
118 | 119 | == Bugfixes since 1.10 == |
119 | 120 | |