MediaWiki
REL1_22
|
Special page allowing users with the appropriate permissions to view and hide revisions. More...
Public Member Functions | |
__construct () | |
execute ($par) | |
Default execute method Checks user permissions, calls the function given in mFunction. | |
Static Public Member Functions | |
static | extractBitfield ($bitPars, $oldfield) |
Put together a rev_deleted bitfield. | |
Public Attributes | |
$archiveName | |
Archive name, for reviewing deleted files. | |
$checks | |
Array of checkbox specs (message, name, deletion bits) | |
$ids | |
Target ID list. | |
$list | |
The RevDel_List object, storing the list of items to be deleted/undeleted. | |
$submitClicked | |
True if the submit button was clicked, and the form was posted. | |
$targetObj | |
Title object for target parameter. | |
$token | |
Edit token for securing image views against XSS. | |
$typeLabels | |
UI Labels about the current type. | |
$typeName | |
Deletion type, may be revision, archive, oldimage, filearchive, logging. | |
Static Public Attributes | |
static | $UILabels |
UI labels for each type. | |
Protected Member Functions | |
addUsageText () | |
Show some introductory text. | |
buildCheckBoxes () | |
extractBitParams () | |
Put together an array that contains -1, 0, or the *_deleted const for each bit. | |
failure ($status) | |
Report that the submit operation failed. | |
getGroupName () | |
Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'. | |
getList () | |
Get the list object for this request. | |
getLogQueryCond () | |
Get the condition used for fetching log snippets. | |
save ($bitfield, $reason, $title) | |
Do the write operations. | |
showConvenienceLinks () | |
Show some useful links in the subtitle. | |
showForm () | |
Show a list of items that we will operate on, and show a form with checkboxes which will allow the user to choose new visibility settings. | |
submit () | |
UI entry point for form submission. | |
success () | |
Report that the submit operation succeeded. | |
tryShowFile ($archiveName) | |
Show a deleted file version requested by the visitor. |
Special page allowing users with the appropriate permissions to view and hide revisions.
Log items can also be hidden.
Definition at line 30 of file SpecialRevisiondelete.php.
Definition at line 89 of file SpecialRevisiondelete.php.
SpecialRevisionDelete::addUsageText | ( | ) | [protected] |
Show some introductory text.
Definition at line 417 of file SpecialRevisiondelete.php.
References SpecialPage\getOutput(), and SpecialPage\getUser().
Referenced by showForm().
SpecialRevisionDelete::buildCheckBoxes | ( | ) | [protected] |
Definition at line 430 of file SpecialRevisiondelete.php.
References $html, $list, $name, array(), as, Xml\checkLabel(), Revision\DELETED_RESTRICTED, extractBitfield(), extractBitParams(), getList(), SpecialPage\getRequest(), list, SpecialPage\msg(), Xml\radio(), tags(), and text.
Referenced by showForm().
SpecialRevisionDelete::execute | ( | $ | subPage | ) |
Default execute method Checks user permissions, calls the function given in mFunction.
This must be overridden by subclasses; it will be made abstract in a future version
$subPage | string|null |
Reimplemented from SpecialPage.
Definition at line 93 of file SpecialRevisiondelete.php.
References $ids, $output, $user, array(), SpecialPage\checkPermissions(), SpecialPage\checkReadOnly(), Revision\DELETED_COMMENT, Revision\DELETED_RESTRICTED, Revision\DELETED_USER, RevisionDeleter\getCanonicalTypeName(), SpecialPage\getFullTitle(), getLogQueryCond(), SpecialPage\getOutput(), SpecialPage\getRequest(), RevisionDeleter\getRestriction(), RevisionDeleter\getRevdelConstant(), SpecialPage\getUser(), Title\newFromText(), SpecialPage\outputHeader(), SpecialPage\setHeaders(), showConvenienceLinks(), showForm(), LogEventsList\showLogExtract(), submit(), RevisionDeleter\suggestTarget(), token, and tryShowFile().
static SpecialRevisionDelete::extractBitfield | ( | $ | bitPars, |
$ | oldfield | ||
) | [static] |
Put together a rev_deleted bitfield.
array | $bitPars | extractBitParams() params |
int | $oldfield | current bitfield |
Definition at line 564 of file SpecialRevisiondelete.php.
Referenced by buildCheckBoxes().
SpecialRevisionDelete::extractBitParams | ( | ) | [protected] |
Put together an array that contains -1, 0, or the *_deleted const for each bit.
Definition at line 541 of file SpecialRevisiondelete.php.
References $name, array(), as, Revision\DELETED_RESTRICTED, SpecialPage\getRequest(), and list.
Referenced by buildCheckBoxes(), and submit().
SpecialRevisionDelete::failure | ( | $ | status | ) | [protected] |
Report that the submit operation failed.
Definition at line 530 of file SpecialRevisiondelete.php.
References SpecialPage\getOutput(), SpecialPage\msg(), and showForm().
Referenced by submit().
SpecialRevisionDelete::getGroupName | ( | ) | [protected] |
Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.
Reimplemented from SpecialPage.
Definition at line 581 of file SpecialRevisiondelete.php.
SpecialRevisionDelete::getList | ( | ) | [protected] |
Get the list object for this request.
Definition at line 301 of file SpecialRevisiondelete.php.
References RevisionDeleter\createList(), SpecialPage\getContext(), and list.
Referenced by buildCheckBoxes(), getLogQueryCond(), save(), and showForm().
SpecialRevisionDelete::getLogQueryCond | ( | ) | [protected] |
Get the condition used for fetching log snippets.
Definition at line 232 of file SpecialRevisiondelete.php.
References array(), getList(), and RevisionDeleter\getRelationType().
Referenced by execute().
SpecialRevisionDelete::save | ( | $ | bitfield, |
$ | reason, | ||
$ | title | ||
) | [protected] |
Do the write operations.
Simple wrapper for RevDel_*List::setVisibility().
$bitfield | |
$reason | |
$title |
Definition at line 575 of file SpecialRevisiondelete.php.
References array(), and getList().
Referenced by submit().
SpecialRevisionDelete::showConvenienceLinks | ( | ) | [protected] |
Show some useful links in the subtitle.
Definition at line 194 of file SpecialRevisiondelete.php.
References array(), SpecialPage\getLanguage(), SpecialPage\getOutput(), SpecialPage\getTitleFor(), SpecialPage\getUser(), Linker\linkKnown(), and SpecialPage\msg().
Referenced by execute().
SpecialRevisionDelete::showForm | ( | ) | [protected] |
Show a list of items that we will operate on, and show a form with checkboxes which will allow the user to choose new visibility settings.
Definition at line 314 of file SpecialRevisiondelete.php.
References $link, $list, $out, $title, addUsageText(), array(), buildCheckBoxes(), Xml\closeElement(), Xml\fieldset(), SpecialPage\getLanguage(), getList(), SpecialPage\getOutput(), SpecialPage\getRequest(), SpecialPage\getTitle(), SpecialPage\getUser(), Html\hidden(), Xml\input(), label, Linker\link(), Xml\listDropDown(), Title\makeTitle(), SpecialPage\msg(), Xml\openElement(), Xml\submitButton(), tags(), and text.
SpecialRevisionDelete::submit | ( | ) | [protected] |
UI entry point for form submission.
PermissionsError |
Definition at line 485 of file SpecialRevisiondelete.php.
References $comment, $token, Revision\DELETED_RESTRICTED, extractBitParams(), failure(), SpecialPage\getOutput(), SpecialPage\getRequest(), SpecialPage\getUser(), SpecialPage\msg(), save(), and success().
Referenced by execute().
SpecialRevisionDelete::success | ( | ) | [protected] |
Report that the submit operation succeeded.
Definition at line 520 of file SpecialRevisiondelete.php.
References SpecialPage\getOutput(), list, SpecialPage\msg(), and showForm().
Referenced by submit().
SpecialRevisionDelete::tryShowFile | ( | $ | archiveName | ) | [protected] |
Show a deleted file version requested by the visitor.
TODO Mostly copied from Special:Undelete. Refactor.
Definition at line 246 of file SpecialRevisiondelete.php.
References $archiveName, $key, $path, $user, array(), File\DELETED_FILE, File\DELETED_RESTRICTED, SpecialPage\getLanguage(), SpecialPage\getOutput(), SpecialPage\getRequest(), SpecialPage\getTitle(), SpecialPage\getUser(), SpecialPage\msg(), Xml\openElement(), RepoGroup\singleton(), Xml\submitButton(), and text.
Referenced by execute().
SpecialRevisionDelete::$archiveName |
Archive name, for reviewing deleted files.
Definition at line 38 of file SpecialRevisiondelete.php.
Referenced by tryShowFile().
SpecialRevisionDelete::$checks |
Array of checkbox specs (message, name, deletion bits)
Definition at line 50 of file SpecialRevisiondelete.php.
SpecialRevisionDelete::$ids |
SpecialRevisionDelete::$list |
The RevDel_List object, storing the list of items to be deleted/undeleted.
Definition at line 56 of file SpecialRevisiondelete.php.
Referenced by buildCheckBoxes(), and showForm().
SpecialRevisionDelete::$submitClicked |
True if the submit button was clicked, and the form was posted.
Definition at line 32 of file SpecialRevisiondelete.php.
SpecialRevisionDelete::$targetObj |
Title object for target parameter.
Definition at line 44 of file SpecialRevisiondelete.php.
SpecialRevisionDelete::$token |
Edit token for securing image views against XSS.
Definition at line 41 of file SpecialRevisiondelete.php.
Referenced by submit().
SpecialRevisionDelete::$typeLabels |
UI Labels about the current type.
Definition at line 53 of file SpecialRevisiondelete.php.
SpecialRevisionDelete::$typeName |
Deletion type, may be revision, archive, oldimage, filearchive, logging.
Definition at line 47 of file SpecialRevisiondelete.php.
SpecialRevisionDelete::$UILabels [static] |
array( 'revision' => array( 'check-label' => 'revdelete-hide-text', 'success' => 'revdelete-success', 'failure' => 'revdelete-failure', ), 'archive' => array( 'check-label' => 'revdelete-hide-text', 'success' => 'revdelete-success', 'failure' => 'revdelete-failure', ), 'oldimage' => array( 'check-label' => 'revdelete-hide-image', 'success' => 'revdelete-success', 'failure' => 'revdelete-failure', ), 'filearchive' => array( 'check-label' => 'revdelete-hide-image', 'success' => 'revdelete-success', 'failure' => 'revdelete-failure', ), 'logging' => array( 'check-label' => 'revdelete-hide-name', 'success' => 'logdelete-success', 'failure' => 'logdelete-failure', ), )
UI labels for each type.
Definition at line 61 of file SpecialRevisiondelete.php.