28 parent::__construct(
'Wantedpages' );
43 $this->limit = (int)$par;
46 $this->shownavigation = !$inc;
47 parent::execute( $par );
54 [ $blNamespace, $blTitle ] = $this->linksMigration->getTitleFields(
'pagelinks' );
55 $queryInfo = $this->linksMigration->getQueryInfo(
'pagelinks',
'pagelinks' );
57 'tables' => array_merge( $queryInfo[
'tables'], [
62 'namespace' => $blNamespace,
67 'pg1.page_namespace' =>
null,
73 'COUNT(*) > ' . $dbr->addQuotes( $count ),
74 'COUNT(*) > SUM(pg2.page_is_redirect)'
76 'GROUP BY' => [ $blNamespace, $blTitle ]
78 'join_conds' => array_merge( [
81 'pg1.page_namespace = ' . $blNamespace,
82 'pg1.page_title = ' . $blTitle
85 'pg2' => [
'LEFT JOIN',
'pg2.page_id = pl_from' ]
86 ], $queryInfo[
'joins'] )
89 $this->
getHookRunner()->onWantedPages__getQueryInfo( $this, $query );
97 PageLinksTable::VIRTUAL_DOMAIN,
104 return 'maintenance';
112class_alias( SpecialWantedPages::class,
'WantedPagesPage' );
A class containing constants representing the names of configuration variables.
const WantedPagesThreshold
Name constant for the WantedPagesThreshold setting, for use with Config::get()
Factory for LinkBatch objects to batch query page metadata.
setDatabaseProvider(IConnectionProvider $databaseProvider)
setLinkBatchFactory(LinkBatchFactory $linkBatchFactory)
getConfig()
Shortcut to get main config object.
including( $x=null)
Whether the special page is being evaluated via transclusion.
Base class for a "wanted" query page like WantedPages, WantedTemplates, etc.
List of the most-linked pages that do not exist.
getGroupName()
Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-gro...
__construct(IConnectionProvider $dbProvider, LinkBatchFactory $linkBatchFactory, private readonly LinksMigration $linksMigration)
isIncludable()
Whether it's allowed to transclude the special page via {{Special:Foo/params}}.to override bool
getQueryInfo()
Subclasses return an SQL query here, formatted as an array with the following keys: tables => Table(s...
getRecacheDB()
Get a DB connection to be used for slow recache queries.to override IReadableDatabase
execute( $par)
This is the actual workhorse.It does everything needed to make a real, honest-to-gosh query page....