44 return 'deleterevision';
53 return $rev ?
$rev->getTitle() : $target;
61 $ids = array_map(
'intval', $this->ids );
63 'tables' => [
'revision',
'user' ],
66 'rev_page' => $this->
title->getArticleID(),
69 'options' => [
'ORDER BY' =>
'rev_id DESC' ],
79 $queryInfo[
'join_conds'],
80 $queryInfo[
'options'],
89 $queryInfo[
'options'],
90 $queryInfo[
'join_conds']
92 if ( $live->numRows() >= count(
$ids ) ) {
98 'tables' => [
'archive' ],
103 'options' => [
'ORDER BY' =>
'ar_rev_id DESC' ],
108 $archiveQueryInfo[
'tables'],
109 $archiveQueryInfo[
'fields'],
110 $archiveQueryInfo[
'conds'],
111 $archiveQueryInfo[
'join_conds'],
112 $archiveQueryInfo[
'options'],
117 $archived = $db->select(
118 $archiveQueryInfo[
'tables'],
119 $archiveQueryInfo[
'fields'],
120 $archiveQueryInfo[
'conds'],
122 $archiveQueryInfo[
'options'],
123 $archiveQueryInfo[
'join_conds']
126 if ( $archived->numRows() == 0 ) {
128 } elseif ( $live->numRows() == 0 ) {
133 foreach ( $live
as $row ) {
134 $rows[$row->rev_id] = $row;
136 foreach ( $archived
as $row ) {
137 $rows[$row->ar_rev_id] = $row;
145 if ( isset( $row->rev_id ) ) {
147 } elseif ( isset( $row->ar_rev_id ) ) {
151 throw new MWException(
'Invalid row type in RevDelRevisionList' );
156 if ( is_null( $this->currentRevId ) ) {
158 $this->currentRevId = $dbw->selectField(
159 'page',
'page_latest', $this->
title->pageCond(), __METHOD__ );
169 $this->
title->invalidateCache();
174 $this->
title->purgeSquid();
176 Hooks::run(
'ArticleRevisionVisibilitySet', [ $this->
title, $this->ids, $visibilityChangeMap ] );
Abstract base class for a list of deletable items.
wfGetDB($db, $groups=[], $wiki=false)
Get a Database object.
the array() calling protocol came about after MediaWiki 1.4rc1.
static getRevdelConstant()
static suggestTarget($target, array $ids)
static selectArchiveFields()
Return the list of revision fields that should be selected to create a new revision from an archive r...
List for revision table items.
Item class for a archive table row by ar_rev_id – actually used via RevDelRevisionList.
static selectFields()
Return the list of revision fields that should be selected to create a new revision.
static run($event, array $args=[], $deprecatedVersion=null)
Call hook functions defined in Hooks::register and $wgHooks.
presenting them properly to the user as errors is done by the caller return true use this to change the list i e etc $rev
This document is intended to provide useful advice for parties seeking to redistribute MediaWiki to end users It s targeted particularly at maintainers for Linux since it s been observed that distribution packages of MediaWiki often break We ve consistently had to recommend that users seeking support use official tarballs instead of their distribution s and this often solves whatever problem the user is having It would be nice if this could such as
static newFromId($id, $flags=0)
Load a page revision from a given revision ID number.
static pageJoinCond()
Return the value of a select() page conds array for the page table.
injection txt This is an overview of how MediaWiki makes use of dependency injection The design described here grew from the discussion of RFC T384 The term dependency this means that anything an object needs to operate should be injected from the the object itself should only know narrow no concrete implementation of the logic it relies on The requirement to inject everything typically results in an architecture that based on two main types of and essentially stateless service objects that use other service objects to operate on the value objects As of the beginning MediaWiki is only starting to use the DI approach Much of the code still relies on global state or direct resulting in a highly cyclical dependency which acts as the top level factory for services in MediaWiki which can be used to gain access to default instances of various services MediaWikiServices however also allows new services to be defined and default services to be redefined Services are defined or redefined by providing a callback the instantiator that will return a new instance of the service When it will create an instance of MediaWikiServices and populate it with the services defined in the files listed by thereby bootstrapping the DI framework Per $wgServiceWiringFiles lists includes ServiceWiring php
Item class for a live revision table row.
Overloads the relevant methods of the real ResultsWrapper so it doesn't go anywhere near an actual da...
doPostCommitUpdates(array $visibilityChangeMap)
to move a page</td >< td > &*You are moving the page across *A non empty talk page already exists under the new or *You uncheck the box below In those you will have to move or merge the page manually if desired</td >< td > be sure to &You are responsible for making sure that links continue to point where they are supposed to go Note that the page will &a page at the new title
static userJoinCond()
Return the value of a select() JOIN conds array for the user table.
static selectUserFields()
Return the list of user fields that should be selected from user table.
static newGood($value=null)
Factory function for good results.