52 parent::__construct(
'Wantedfiles' );
53 $this->repoGroup = $repoGroup;
59 # Specifically setting to use "Wanted Files" (NS_MAIN) as title, so as to get what
60 # category would be used on main namespace pages, for those tricky wikipedia
61 # admins who like to do {{#ifeq:{{NAMESPACE}}|foo|bar|....}}.
62 $catMessage = $this->
msg(
'broken-file-category' )
63 ->page( PageReferenceValue::localReference(
NS_MAIN,
"Wanted Files" ) )
64 ->inContentLanguage();
66 if ( !$catMessage->isDisabled() ) {
67 $category = Title::makeTitleSafe(
NS_CATEGORY, $catMessage->text() );
76 $noForeign =
'-noforeign';
81 ->msg(
'wantedfiletext-cat' . $noForeign )
82 ->params( $category->getFullText() )
86 ->msg(
'wantedfiletext-nocat' . $noForeign )
100 return $this->repoGroup->hasForeignRepos();
127 return (
bool)$this->repoGroup->findFile( $title );
142 'value' =>
'COUNT(*)'
145 'img1.img_name' =>
null,
147 'img2.img_name' =>
null,
149 'options' => [
'GROUP BY' =>
'il_to' ],
151 'img1' => [
'LEFT JOIN',
152 'il_to = img1.img_name'
154 'page' => [
'LEFT JOIN', [
155 'il_to = page_title',
158 'redirect' => [
'LEFT JOIN', [
163 'img2' => [
'LEFT JOIN',
164 'rd_title = img2.img_name'
171 return 'maintenance';
179class_alias( SpecialWantedFiles::class,
'WantedFilesPage' );
setDatabaseProvider(IConnectionProvider $databaseProvider)
setLinkBatchFactory(LinkBatchFactory $linkBatchFactory)
msg( $key,... $params)
Wrapper around wfMessage that sets the current context.
Base class for a "wanted" query page like WantedPages, WantedTemplates, etc.
Prioritized list of file repositories.