41 parent::__construct(
'AutoblockList' );
51 $out->setPageTitleMsg( $this->
msg(
'autoblocklist' ) );
53 $out->addModuleStyles( [
'mediawiki.special' ] );
55 # setup BlockListPager here to get the actual default Limit
58 # Just show the block list
61 'type' =>
'limitselect',
62 'label-message' =>
'table_pager_limit_label',
63 'options' => $pager->getLimitSelectList(),
65 'default' => $pager->getLimit(),
69 $form = HTMLForm::factory(
'ooui', $fields, $this->
getContext() );
70 $form->setMethod(
'get' )
72 ->setFormIdentifier(
'blocklist' )
73 ->setWrapperLegendMsg(
'autoblocklist-legend' )
74 ->setSubmitTextMsg(
'autoblocklist-submit' )
75 ->setId(
'mw-autoblock-list-form' )
77 ->displayForm(
false );
88 $this->dbProvider->getReplicaDatabase()->expr(
'bl_parent_block_id',
'!=',
null ),
90 # Is the user allowed to see hidden blocks?
92 $conds[
'bl_deleted'] = 0;
97 $this->blockActionInfo,
98 $this->blockRestrictionStore,
99 $this->blockTargetFactory,
100 $this->hideUserUtils,
102 $this->linkBatchFactory,
105 $this->rowCommentFormatter,
118 # Check for other blocks, i.e. global/tor blocks
119 $otherAutoblockLink = [];
120 $this->
getHookRunner()->onOtherAutoblockLogLink( $otherAutoblockLink );
122 # Show additional header for the local block only when other blocks exists.
123 # Not necessary in a standard installation without such extensions enabled
124 if ( count( $otherAutoblockLink ) ) {
126 Html::rawElement(
'h2', [], $this->
msg(
'autoblocklist-localblocks',
133 $out->addParserOutputContent(
135 ParserOptions::newFromContext( $this->getContext() )
138 $out->addWikiMsg(
'autoblocklist-empty' );
141 if ( count( $otherAutoblockLink ) ) {
146 $this->
msg(
'autoblocklist-otherblocks', count( $otherAutoblockLink ) )->parse()
150 foreach ( $otherAutoblockLink as $link ) {
151 $list .= Html::rawElement(
'li', [], $link ) .
"\n";
156 [
'class' =>
'mw-autoblocklist-otherblocks' ],
174class_alias( SpecialAutoblockList::class,
'SpecialAutoblockList' );
Factory for LinkBatch objects to batch query page metadata.
Parent class for all special pages.
setHeaders()
Sets headers - this should be called from the execute() method of all derived classes!
getPageTitle( $subpage=false)
Get a self-referential title object.
getContext()
Gets the context this SpecialPage is executed in.
msg( $key,... $params)
Wrapper around wfMessage that sets the current context.
getOutput()
Get the OutputPage being used for this instance.
getAuthority()
Shortcut to get the Authority executing this instance.
outputHeader( $summaryMessageKey='')
Outputs a summary message on top of special pages By default the message key is the canonical name of...
addHelpLink( $to, $overrideBaseUrl=false)
Adds help link with an icon via page indicators.