Add public keyword to methods
[MAILPOET-2413]
This commit is contained in:
@ -4,7 +4,7 @@ namespace MailPoet\Form\Block;
|
||||
|
||||
class Checkbox extends Base {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
|
||||
$field_name = 'data[' . static::getFieldName($block) . ']';
|
||||
|
@ -7,7 +7,7 @@ use MailPoetVendor\Carbon\Carbon;
|
||||
|
||||
class Date extends Base {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
$html .= '<p class="mailpoet_paragraph">';
|
||||
$html .= static::renderLabel($block);
|
||||
@ -103,7 +103,7 @@ class Date extends Base {
|
||||
return $html;
|
||||
}
|
||||
|
||||
static function getDateTypes() {
|
||||
public static function getDateTypes() {
|
||||
return [
|
||||
'year_month_day' => WPFunctions::get()->__('Year, month, day', 'mailpoet'),
|
||||
'year_month' => WPFunctions::get()->__('Year, month', 'mailpoet'),
|
||||
@ -112,7 +112,7 @@ class Date extends Base {
|
||||
];
|
||||
}
|
||||
|
||||
static function getDateFormats() {
|
||||
public static function getDateFormats() {
|
||||
return [
|
||||
'year_month_day' => ['MM/DD/YYYY', 'DD/MM/YYYY', 'YYYY/MM/DD'],
|
||||
'year_month' => ['MM/YYYY', 'YYYY/MM'],
|
||||
@ -120,14 +120,14 @@ class Date extends Base {
|
||||
'month' => ['MM'],
|
||||
];
|
||||
}
|
||||
static function getMonthNames() {
|
||||
public static function getMonthNames() {
|
||||
return [__('January', 'mailpoet'), WPFunctions::get()->__('February', 'mailpoet'), WPFunctions::get()->__('March', 'mailpoet'), WPFunctions::get()->__('April', 'mailpoet'),
|
||||
WPFunctions::get()->__('May', 'mailpoet'), WPFunctions::get()->__('June', 'mailpoet'), WPFunctions::get()->__('July', 'mailpoet'), WPFunctions::get()->__('August', 'mailpoet'), WPFunctions::get()->__('September', 'mailpoet'),
|
||||
WPFunctions::get()->__('October', 'mailpoet'), WPFunctions::get()->__('November', 'mailpoet'), WPFunctions::get()->__('December', 'mailpoet'),
|
||||
];
|
||||
}
|
||||
|
||||
static function getMonths($block = []) {
|
||||
public static function getMonths($block = []) {
|
||||
$defaults = [
|
||||
'selected' => null,
|
||||
];
|
||||
@ -152,7 +152,7 @@ class Date extends Base {
|
||||
return $html;
|
||||
}
|
||||
|
||||
static function getYears($block = []) {
|
||||
public static function getYears($block = []) {
|
||||
$defaults = [
|
||||
'selected' => null,
|
||||
'from' => (int)strftime('%Y') - 100,
|
||||
@ -181,7 +181,7 @@ class Date extends Base {
|
||||
return $html;
|
||||
}
|
||||
|
||||
static function getDays($block = []) {
|
||||
public static function getDays($block = []) {
|
||||
$defaults = [
|
||||
'selected' => null,
|
||||
];
|
||||
@ -207,7 +207,7 @@ class Date extends Base {
|
||||
return $html;
|
||||
}
|
||||
|
||||
static function convertDateToDatetime($date, $date_format) {
|
||||
public static function convertDateToDatetime($date, $date_format) {
|
||||
$datetime = false;
|
||||
if ($date_format === 'datetime') {
|
||||
$datetime = $date;
|
||||
|
@ -4,7 +4,7 @@ namespace MailPoet\Form\Block;
|
||||
|
||||
class Divider {
|
||||
|
||||
static function render() {
|
||||
public static function render() {
|
||||
return '<hr class="mailpoet_divider" />';
|
||||
}
|
||||
}
|
@ -4,7 +4,7 @@ namespace MailPoet\Form\Block;
|
||||
|
||||
class Html {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
$text = '';
|
||||
|
||||
|
@ -4,7 +4,7 @@ namespace MailPoet\Form\Block;
|
||||
|
||||
class Radio extends Base {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
|
||||
$field_name = 'data[' . static::getFieldName($block) . ']';
|
||||
|
@ -4,7 +4,7 @@ namespace MailPoet\Form\Block;
|
||||
|
||||
class Segment extends Base {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
|
||||
$field_name = 'data[' . static::getFieldName($block) . ']';
|
||||
|
@ -6,7 +6,7 @@ use MailPoet\WP\Functions as WPFunctions;
|
||||
|
||||
class Select extends Base {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
|
||||
$field_name = 'data[' . static::getFieldName($block) . ']';
|
||||
|
@ -4,7 +4,7 @@ namespace MailPoet\Form\Block;
|
||||
|
||||
class Submit extends Base {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
|
||||
$html .= '<p class="mailpoet_paragraph"><input type="submit" class="mailpoet_submit" ';
|
||||
|
@ -4,7 +4,7 @@ namespace MailPoet\Form\Block;
|
||||
|
||||
class Text extends Base {
|
||||
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$type = 'text';
|
||||
$automation_id = ' ';
|
||||
if ($block['id'] === 'email') {
|
||||
|
@ -3,7 +3,7 @@
|
||||
namespace MailPoet\Form\Block;
|
||||
|
||||
class Textarea extends Base {
|
||||
static function render($block) {
|
||||
public static function render($block) {
|
||||
$html = '';
|
||||
|
||||
$html .= '<p class="mailpoet_paragraph">';
|
||||
|
Reference in New Issue
Block a user