diff --git a/app/appfront/modules/Customer/block/newsletter/Index.php b/app/appfront/modules/Customer/block/newsletter/Index.php index 34ae80368d785c5849b6f581de50a1839f09ac7a..c5d452d27d5dff8aaf0d9b979e42be03896a5657 100644 --- a/app/appfront/modules/Customer/block/newsletter/Index.php +++ b/app/appfront/modules/Customer/block/newsletter/Index.php @@ -29,6 +29,8 @@ class Index $message = Yii::$service->page->translate->__('Your subscribed email was successful, You can {urlB} click Here to Home Page {urlE}, Thank You.', $arr); $param['email'] = $email; Yii::$service->email->customer->sendNewsletterSubscribeEmail($param); + } else if (is_array($message)) { + $message = implode(',', $message); } return [ diff --git a/app/appfront/modules/Customer/controllers/TestController.php b/app/appfront/modules/Customer/controllers/TestController.php index 8da70908bc251fcab182faa90365b236962477f4..9a641971146bdaf3f422b043c039df401742d83b 100644 --- a/app/appfront/modules/Customer/controllers/TestController.php +++ b/app/appfront/modules/Customer/controllers/TestController.php @@ -11,6 +11,7 @@ namespace fecshop\app\appfront\modules\Customer\controllers; use fecshop\app\appfront\modules\AppfrontController; use Yii; +use fecshop\queue\job\SendEmailJob; /** * @author Terry Zhao <2358269014@qq.com> @@ -23,21 +24,11 @@ class TestController extends AppfrontController public $enableCsrfValidation = false; /** - * Н╦╗Долл─. + * */ public function actionIndex() { - echo json_encode([ - 'data' => - [ - ['terry','1','2','3'], - ['water','11','22','33'], - ['xxx','111','222','333'], - ] - ]); - - exit; } } diff --git a/composer.json b/composer.json index bce95b788f3858852446decedce53cc312f51774..49716561ee972ac01f398e81c75a4c01ea45fa65 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ ], "minimum-stability": "stable", "require": { - "php": ">=5.4.0", + "php": ">=7.0", "yiisoft/yii2-swiftmailer": "2.0.7", "yiisoft/yii2": ">=2.0.12" , "fancyecommerce/fec":">=1.1.3.4", diff --git a/services/Service.php b/services/Service.php index 7f482a59a05dd81314fc71aca4ae1001bf89e20a..f23a7cc4268bcfc8f00bf450bfe7d7eeb698d415 100644 --- a/services/Service.php +++ b/services/Service.php @@ -224,7 +224,7 @@ class Service extends BaseObject return false; } if ($object->storagePath) { - $storagePath = '\\'.trim($object->storagePath.'\\').'\\'; + $storagePath = '\\'.trim($object->storagePath, '\\').'\\'; } else { $storagePath = '\\'.strtolower($className).'\\'; } diff --git a/services/cms/Article.php b/services/cms/Article.php index 283b59e29341c0e1d45052864d10dfe46877c1d3..1a6223b3e76a3f1fbb3b6bedea9c29a432fd4846 100644 --- a/services/cms/Article.php +++ b/services/cms/Article.php @@ -38,7 +38,9 @@ class Article extends Service { parent::init(); $currentService = $this->getStorageService($this); + $this->_article = new $currentService(); + /* if ($this->storage == 'mongodb') { $this->_article = new ArticleMongodb(); @@ -47,6 +49,8 @@ class Article extends Service } */ } + + /** * Get Url by article's url key.