From 7bb13483f28e7baed1de937e16c4f92d1d16de86 Mon Sep 17 00:00:00 2001 From: Sam Georges Date: Thu, 5 Jun 2014 22:05:56 +1000 Subject: [PATCH] Translate strings --- CHANGELOG.md | 3 +++ modules/system/controllers/Updates.php | 10 +++++----- .../system/controllers/updates/_disable_form.htm | 10 +++++----- .../controllers/updates/_list_manage_toolbar.htm | 6 +++--- .../controllers/updates/config_manage_list.yaml | 1 - modules/system/lang/en/lang.php | 14 ++++++++++++++ 6 files changed, 30 insertions(+), 14 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d09fa6ff5..12255c889 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +* **Build 99** (2014-06-05) + - Plugins can now be removed, refreshed and disabled via the back-end. + * **Build 96** (2014-05-29) - Plugin CLI commands are now case insensitive. - Fixes a bug where belongsTo form field relations were not being set. diff --git a/modules/system/controllers/Updates.php b/modules/system/controllers/Updates.php index 4bb82a992..ffd4940d3 100644 --- a/modules/system/controllers/Updates.php +++ b/modules/system/controllers/Updates.php @@ -57,6 +57,7 @@ class Updates extends Controller */ public function manage() { + $this->pageTitle = Lang::get('system::lang.plugins.manage'); PluginManager::instance()->clearDisabledCache(); return $this->getClassExtension('Backend.Behaviors.ListController')->index(); } @@ -407,8 +408,7 @@ class Updates extends Controller } } - Flash::success('Successfully removed those plugins from the system.'); - + Flash::success(Lang::get('system::lang.plugins.remove_success')); } return $this->listRefresh('manage'); @@ -436,7 +436,7 @@ class Updates extends Controller $manager->updatePlugin($pluginCode); } - Flash::success('Successfully refreshed those plugins in the system.'); + Flash::success(Lang::get('system::lang.plugins.refresh_success')); } return $this->listRefresh('manage'); @@ -476,9 +476,9 @@ class Updates extends Controller } if ($disable) - Flash::success('Successfully disabled those plugins.'); + Flash::success(Lang::get('system::lang.plugins.disable_success')); else - Flash::success('Successfully enabled those plugins.'); + Flash::success(Lang::get('system::lang.plugins.enable_success')); return Redirect::to(Backend::url('system/updates/manage')); } diff --git a/modules/system/controllers/updates/_disable_form.htm b/modules/system/controllers/updates/_disable_form.htm index 789854226..b186db481 100644 --- a/modules/system/controllers/updates/_disable_form.htm +++ b/modules/system/controllers/updates/_disable_form.htm @@ -1,7 +1,7 @@ 'disableForm']) ?> @@ -39,7 +39,7 @@ data-request="onDisablePlugins" data-request-confirm="Are you sure?" data-stripe-load-indicator> - Apply + \ No newline at end of file diff --git a/modules/system/controllers/updates/config_manage_list.yaml b/modules/system/controllers/updates/config_manage_list.yaml index cc4bdf775..e22b85a52 100644 --- a/modules/system/controllers/updates/config_manage_list.yaml +++ b/modules/system/controllers/updates/config_manage_list.yaml @@ -2,7 +2,6 @@ # List Behavior Config # =================================== -title: system::lang.updates.title list: @/modules/system/models/pluginversion/columns.yaml modelClass: System\Models\PluginVersion noRecordsMessage: backend::lang.list.no_records diff --git a/modules/system/lang/en/lang.php b/modules/system/lang/en/lang.php index dc2d50695..829e6f2b5 100644 --- a/modules/system/lang/en/lang.php +++ b/modules/system/lang/en/lang.php @@ -22,6 +22,20 @@ return [ 'help' => 'Name the plugin by its unique code. For example, RainLab.Blog', ], ], + 'plugins' => [ + 'manage' => 'Manage Plugins', + 'enable_or_disable' => 'Enable or disable', + 'enable_or_disable_title' => 'Enable or Disable Plugins', + 'remove' => 'Remove', + 'refresh' => 'Refresh', + 'disabled_label' => 'Disabled', + 'disabled_help' => 'Plugins that are disabled are ignored by the application.', + 'selected_amount' => 'Plugins selected: :amount', + 'remove_success' => "Successfully removed those plugins from the system.", + 'refresh_success' => "Successfully refreshed those plugins in the system.", + 'disable_success' => "Successfully disabled those plugins.", + 'enable_success' => "Successfully enabled those plugins.", + ], 'project' => [ 'name' => 'Project', 'owner_label' => 'Owner',