converted text domain to string instead of constant
This commit is contained in:
@@ -11,10 +11,10 @@ class CustomField extends Model {
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
$this->addValidations('name', array(
|
||||
'required' => __('Please specify a name', MAILPOET)
|
||||
'required' => __('Please specify a name', 'mailpoet')
|
||||
));
|
||||
$this->addValidations('type', array(
|
||||
'required' => __('Please specify a type', MAILPOET)
|
||||
'required' => __('Please specify a type', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
|
@@ -10,7 +10,7 @@ class Form extends Model {
|
||||
parent::__construct();
|
||||
|
||||
$this->addValidations('name', array(
|
||||
'required' => __('Please specify a name', MAILPOET)
|
||||
'required' => __('Please specify a name', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
@@ -47,12 +47,12 @@ class Form extends Model {
|
||||
return array(
|
||||
array(
|
||||
'name' => 'all',
|
||||
'label' => __('All', MAILPOET),
|
||||
'label' => __('All', 'mailpoet'),
|
||||
'count' => Form::getPublished()->count()
|
||||
),
|
||||
array(
|
||||
'name' => 'trash',
|
||||
'label' => __('Trash', MAILPOET),
|
||||
'label' => __('Trash', 'mailpoet'),
|
||||
'count' => Form::getTrashed()->count()
|
||||
)
|
||||
);
|
||||
|
@@ -50,7 +50,7 @@ class Model extends \Sudzy\ValidModel {
|
||||
$column = $matches[1];
|
||||
$this->setError(
|
||||
sprintf(
|
||||
__('Another record already exists. Please specify a different "%1$s".', MAILPOET),
|
||||
__('Another record already exists. Please specify a different "%1$s".', 'mailpoet'),
|
||||
$column
|
||||
)
|
||||
);
|
||||
|
@@ -23,7 +23,7 @@ class Newsletter extends Model {
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
$this->addValidations('type', array(
|
||||
'required' => __('Please specify a type', MAILPOET)
|
||||
'required' => __('Please specify a type', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
@@ -309,7 +309,7 @@ class Newsletter extends Model {
|
||||
$segments = Segment::orderByAsc('name')->findMany();
|
||||
$segment_list = array();
|
||||
$segment_list[] = array(
|
||||
'label' => __('All Lists', MAILPOET),
|
||||
'label' => __('All Lists', 'mailpoet'),
|
||||
'value' => ''
|
||||
);
|
||||
|
||||
@@ -408,7 +408,7 @@ class Newsletter extends Model {
|
||||
$groups = array(
|
||||
array(
|
||||
'name' => 'all',
|
||||
'label' => __('All', MAILPOET),
|
||||
'label' => __('All', 'mailpoet'),
|
||||
'count' => Newsletter::getPublished()
|
||||
->filter('filterType', $type)
|
||||
->count()
|
||||
@@ -420,7 +420,7 @@ class Newsletter extends Model {
|
||||
$groups = array_merge($groups, array(
|
||||
array(
|
||||
'name' => self::STATUS_DRAFT,
|
||||
'label' => __('Draft', MAILPOET),
|
||||
'label' => __('Draft', 'mailpoet'),
|
||||
'count' => Newsletter::getPublished()
|
||||
->filter('filterType', $type)
|
||||
->filter('filterStatus', self::STATUS_DRAFT)
|
||||
@@ -428,7 +428,7 @@ class Newsletter extends Model {
|
||||
),
|
||||
array(
|
||||
'name' => self::STATUS_SCHEDULED,
|
||||
'label' => __('Scheduled', MAILPOET),
|
||||
'label' => __('Scheduled', 'mailpoet'),
|
||||
'count' => Newsletter::getPublished()
|
||||
->filter('filterType', $type)
|
||||
->filter('filterStatus', self::STATUS_SCHEDULED)
|
||||
@@ -436,7 +436,7 @@ class Newsletter extends Model {
|
||||
),
|
||||
array(
|
||||
'name' => self::STATUS_SENDING,
|
||||
'label' => __('Sending', MAILPOET),
|
||||
'label' => __('Sending', 'mailpoet'),
|
||||
'count' => Newsletter::getPublished()
|
||||
->filter('filterType', $type)
|
||||
->filter('filterStatus', self::STATUS_SENDING)
|
||||
@@ -444,7 +444,7 @@ class Newsletter extends Model {
|
||||
),
|
||||
array(
|
||||
'name' => self::STATUS_SENT,
|
||||
'label' => __('Sent', MAILPOET),
|
||||
'label' => __('Sent', 'mailpoet'),
|
||||
'count' => Newsletter::getPublished()
|
||||
->filter('filterType', $type)
|
||||
->filter('filterStatus', self::STATUS_SENT)
|
||||
@@ -458,7 +458,7 @@ class Newsletter extends Model {
|
||||
$groups = array_merge($groups, array(
|
||||
array(
|
||||
'name' => self::STATUS_ACTIVE,
|
||||
'label' => __('Active', MAILPOET),
|
||||
'label' => __('Active', 'mailpoet'),
|
||||
'count' => Newsletter::getPublished()
|
||||
->filter('filterType', $type)
|
||||
->filter('filterStatus', self::STATUS_ACTIVE)
|
||||
@@ -466,7 +466,7 @@ class Newsletter extends Model {
|
||||
),
|
||||
array(
|
||||
'name' => self::STATUS_DRAFT,
|
||||
'label' => __('Not active', MAILPOET),
|
||||
'label' => __('Not active', 'mailpoet'),
|
||||
'count' => Newsletter::getPublished()
|
||||
->filter('filterType', $type)
|
||||
->filter('filterStatus', self::STATUS_DRAFT)
|
||||
@@ -478,7 +478,7 @@ class Newsletter extends Model {
|
||||
|
||||
$groups[] = array(
|
||||
'name' => 'trash',
|
||||
'label' => __('Trash', MAILPOET),
|
||||
'label' => __('Trash', 'mailpoet'),
|
||||
'count' => Newsletter::getTrashed()
|
||||
->filter('filterType', $type)
|
||||
->count()
|
||||
|
@@ -9,10 +9,10 @@ class NewsletterOptionField extends Model {
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
$this->addValidations('name', array(
|
||||
'required' => __('Please specify a name', MAILPOET)
|
||||
'required' => __('Please specify a name', 'mailpoet')
|
||||
));
|
||||
$this->addValidations('newsletter_type', array(
|
||||
'required' => __('Please specify a newsletter type', MAILPOET)
|
||||
'required' => __('Please specify a newsletter type', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
|
@@ -10,10 +10,10 @@ class NewsletterTemplate extends Model {
|
||||
parent::__construct();
|
||||
|
||||
$this->addValidations('name', array(
|
||||
'required' => __('Please specify a name', MAILPOET)
|
||||
'required' => __('Please specify a name', 'mailpoet')
|
||||
));
|
||||
$this->addValidations('body', array(
|
||||
'required' => __('The template body cannot be empty', MAILPOET)
|
||||
'required' => __('The template body cannot be empty', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
|
@@ -10,7 +10,7 @@ class Segment extends Model {
|
||||
parent::__construct();
|
||||
|
||||
$this->addValidations('name', array(
|
||||
'required' => __('Please specify a name', MAILPOET)
|
||||
'required' => __('Please specify a name', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
@@ -100,9 +100,9 @@ class Segment extends Model {
|
||||
// create the wp users segment
|
||||
$wp_segment = Segment::create();
|
||||
$wp_segment->hydrate(array(
|
||||
'name' => __('WordPress Users', MAILPOET),
|
||||
'name' => __('WordPress Users', 'mailpoet'),
|
||||
'description' =>
|
||||
__('This lists containts all of your WordPress users', MAILPOET),
|
||||
__('This lists containts all of your WordPress users', 'mailpoet'),
|
||||
'type' => 'wp_users'
|
||||
));
|
||||
$wp_segment->save();
|
||||
@@ -119,12 +119,12 @@ class Segment extends Model {
|
||||
return array(
|
||||
array(
|
||||
'name' => 'all',
|
||||
'label' => __('All', MAILPOET),
|
||||
'label' => __('All', 'mailpoet'),
|
||||
'count' => Segment::getPublished()->count()
|
||||
),
|
||||
array(
|
||||
'name' => 'trash',
|
||||
'label' => __('Trash', MAILPOET),
|
||||
'label' => __('Trash', 'mailpoet'),
|
||||
'count' => Segment::getTrashed()->count()
|
||||
)
|
||||
);
|
||||
@@ -176,7 +176,7 @@ class Segment extends Model {
|
||||
'AND relation.status = "' . Subscriber::STATUS_SUBSCRIBED . '" ' .
|
||||
'GROUP BY segments.id) ' .
|
||||
'UNION ALL ' .
|
||||
'(SELECT 0 as id, "' . __('Not in a List', MAILPOET) . '" as name, COUNT(*) as subscribers ' .
|
||||
'(SELECT 0 as id, "' . __('Not in a List', 'mailpoet') . '" as name, COUNT(*) as subscribers ' .
|
||||
'FROM ' . MP_SUBSCRIBERS_TABLE . ' subscribers ' .
|
||||
'LEFT JOIN ' . MP_SUBSCRIBER_SEGMENT_TABLE . ' relation on relation.subscriber_id = subscribers.id ' .
|
||||
(($withConfirmedSubscribers) ?
|
||||
|
@@ -19,7 +19,7 @@ class Setting extends Model {
|
||||
parent::__construct();
|
||||
|
||||
$this->addValidations('name', array(
|
||||
'required' => __('Please specify a name', MAILPOET)
|
||||
'required' => __('Please specify a name', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
@@ -45,8 +45,8 @@ class Setting extends Model {
|
||||
),
|
||||
'signup_confirmation' => array(
|
||||
'enabled' => true,
|
||||
'subject' => sprintf(__('Confirm your subscription to %1$s', MAILPOET), get_option('blogname')),
|
||||
'body' => __("Hello!\n\nHurray! You've subscribed to our site.\n\nPlease confirm your subscription to the list(s): [lists_to_confirm] by clicking the link below: \n\n[activation_link]Click here to confirm your subscription.[/activation_link]\n\nThank you,\n\nThe Team", MAILPOET)
|
||||
'subject' => sprintf(__('Confirm your subscription to %1$s', 'mailpoet'), get_option('blogname')),
|
||||
'body' => __("Hello!\n\nHurray! You've subscribed to our site.\n\nPlease confirm your subscription to the list(s): [lists_to_confirm] by clicking the link below: \n\n[activation_link]Click here to confirm your subscription.[/activation_link]\n\nThank you,\n\nThe Team", 'mailpoet')
|
||||
),
|
||||
'tracking' => array(
|
||||
'enabled' => true
|
||||
|
@@ -18,8 +18,8 @@ class Subscriber extends Model {
|
||||
parent::__construct();
|
||||
|
||||
$this->addValidations('email', array(
|
||||
'required' => __('Please enter your email address', MAILPOET),
|
||||
'isEmail' => __('Your email address is invalid!', MAILPOET)
|
||||
'required' => __('Please enter your email address', 'mailpoet'),
|
||||
'isEmail' => __('Your email address is invalid!', 'mailpoet')
|
||||
));
|
||||
}
|
||||
|
||||
@@ -214,13 +214,13 @@ class Subscriber extends Model {
|
||||
$segments = Segment::orderByAsc('name')->findMany();
|
||||
$segment_list = array();
|
||||
$segment_list[] = array(
|
||||
'label' => __('All Lists', MAILPOET),
|
||||
'label' => __('All Lists', 'mailpoet'),
|
||||
'value' => ''
|
||||
);
|
||||
|
||||
$subscribers_without_segment = self::filter('withoutSegments')->count();
|
||||
$subscribers_without_segment_label = sprintf(
|
||||
__('Subscribers without a list (%s)', MAILPOET),
|
||||
__('Subscribers without a list (%s)', 'mailpoet'),
|
||||
number_format($subscribers_without_segment)
|
||||
);
|
||||
|
||||
@@ -276,27 +276,27 @@ class Subscriber extends Model {
|
||||
return array(
|
||||
array(
|
||||
'name' => 'all',
|
||||
'label' => __('All', MAILPOET),
|
||||
'label' => __('All', 'mailpoet'),
|
||||
'count' => self::getPublished()->count()
|
||||
),
|
||||
array(
|
||||
'name' => self::STATUS_SUBSCRIBED,
|
||||
'label' => __('Subscribed', MAILPOET),
|
||||
'label' => __('Subscribed', 'mailpoet'),
|
||||
'count' => self::filter(self::STATUS_SUBSCRIBED)->count()
|
||||
),
|
||||
array(
|
||||
'name' => self::STATUS_UNCONFIRMED,
|
||||
'label' => __('Unconfirmed', MAILPOET),
|
||||
'label' => __('Unconfirmed', 'mailpoet'),
|
||||
'count' => self::filter(self::STATUS_UNCONFIRMED)->count()
|
||||
),
|
||||
array(
|
||||
'name' => self::STATUS_UNSUBSCRIBED,
|
||||
'label' => __('Unsubscribed', MAILPOET),
|
||||
'label' => __('Unsubscribed', 'mailpoet'),
|
||||
'count' => self::filter(self::STATUS_UNSUBSCRIBED)->count()
|
||||
),
|
||||
array(
|
||||
'name' => 'trash',
|
||||
'label' => __('Trash', MAILPOET),
|
||||
'label' => __('Trash', 'mailpoet'),
|
||||
'count' => self::getTrashed()->count()
|
||||
)
|
||||
);
|
||||
|
Reference in New Issue
Block a user