mirror of
https://github.com/symbiote/silverstripe-gridfieldextensions.git
synced 2024-10-22 17:05:39 +02:00
Declare visibility
This commit is contained in:
parent
0c157d77c8
commit
bc7be3f136
@ -29,7 +29,7 @@ class GridFieldAddNewInlineButton extends AbstractGridFieldComponent implements
|
||||
/**
|
||||
* @skipUpgrade
|
||||
*/
|
||||
const POST_KEY = 'GridFieldAddNewInlineButton';
|
||||
private const POST_KEY = 'GridFieldAddNewInlineButton';
|
||||
|
||||
private string $fragment;
|
||||
private string $title;
|
||||
|
@ -31,7 +31,7 @@ class GridFieldAddNewMultiClass extends AbstractGridFieldComponent implements
|
||||
/**
|
||||
* @skipUpgrade
|
||||
*/
|
||||
const POST_KEY = 'GridFieldAddNewMultiClass';
|
||||
private const POST_KEY = 'GridFieldAddNewMultiClass';
|
||||
|
||||
private static $allowed_actions = array(
|
||||
'handleAdd'
|
||||
|
@ -28,7 +28,7 @@ class GridFieldConfigurablePaginator extends GridFieldPaginator
|
||||
* @config
|
||||
* @var int
|
||||
*/
|
||||
private static $default_page_sizes = array(15, 30, 60);
|
||||
private static $default_page_sizes = [15, 30, 60];
|
||||
|
||||
/**
|
||||
* @var GridField
|
||||
|
@ -43,7 +43,7 @@ class GridFieldEditableColumns extends GridFieldDataColumns implements
|
||||
/**
|
||||
* @skipUpgrade
|
||||
*/
|
||||
const POST_KEY = 'GridFieldEditableColumns';
|
||||
private const POST_KEY = 'GridFieldEditableColumns';
|
||||
|
||||
private static $allowed_actions = array(
|
||||
'handleForm'
|
||||
|
@ -28,27 +28,12 @@ abstract class GridFieldRequestHandler extends RequestHandler
|
||||
'Form'
|
||||
);
|
||||
|
||||
/**
|
||||
* @var GridField
|
||||
*/
|
||||
protected $grid;
|
||||
protected GridField $grid;
|
||||
protected GridFieldComponent $component;
|
||||
protected string $name;
|
||||
protected string $template = __CLASS__;
|
||||
|
||||
/**
|
||||
* @var GridFieldComponent
|
||||
*/
|
||||
protected $component;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
protected $name;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
protected $template = __CLASS__;
|
||||
|
||||
public function __construct(GridField $grid, GridFieldComponent $component, $name)
|
||||
public function __construct(GridField $grid, GridFieldComponent $component, string $name)
|
||||
{
|
||||
$this->grid = $grid;
|
||||
$this->component = $component;
|
||||
@ -112,7 +97,7 @@ abstract class GridFieldRequestHandler extends RequestHandler
|
||||
/**
|
||||
* @param string $template
|
||||
*/
|
||||
public function setTemplate($template)
|
||||
public function setTemplate(string $template)
|
||||
{
|
||||
$this->template = $template;
|
||||
}
|
||||
@ -120,7 +105,7 @@ abstract class GridFieldRequestHandler extends RequestHandler
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getTemplate()
|
||||
public function getTemplate(): string
|
||||
{
|
||||
return $this->template;
|
||||
}
|
||||
@ -128,7 +113,7 @@ abstract class GridFieldRequestHandler extends RequestHandler
|
||||
/**
|
||||
* @return ArrayList
|
||||
*/
|
||||
public function getBreadcrumbs()
|
||||
public function getBreadcrumbs(): ArrayList
|
||||
{
|
||||
$controller = $this->getController();
|
||||
|
||||
@ -142,7 +127,7 @@ abstract class GridFieldRequestHandler extends RequestHandler
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
protected function getBackLink()
|
||||
protected function getBackLink(): string
|
||||
{
|
||||
$controller = $this->getTopLevelController();
|
||||
|
||||
|
@ -12,7 +12,7 @@ use SilverStripe\View\ArrayData;
|
||||
*/
|
||||
class GridFieldTitleHeader extends AbstractGridFieldComponent implements GridField_HTMLProvider
|
||||
{
|
||||
public function getHTMLFragments($grid)
|
||||
public function getHTMLFragments($grid): array
|
||||
{
|
||||
$cols = ArrayList::create();
|
||||
|
||||
@ -25,8 +25,8 @@ class GridFieldTitleHeader extends AbstractGridFieldComponent implements GridFie
|
||||
)));
|
||||
}
|
||||
|
||||
return array(
|
||||
return [
|
||||
'header' => $cols->renderWith(__CLASS__)
|
||||
);
|
||||
];
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user