From 4c8d02fcf21d87ffa8b94d1e51fcf481ebb76c7f Mon Sep 17 00:00:00 2001 From: xiaochong0302 Date: Fri, 4 Sep 2020 14:25:58 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0readme?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 24 +++++++++++++++--------- app/Providers/Annotation.php | 22 +++++++++++++--------- app/Providers/ProviderInterface.php | 2 +- 3 files changed, 29 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index d6505ef9..2a55c157 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,8 @@ 都有些什么功能?我也不想写一大堆,自己体验吧! +PS:**系统后台已禁止提交并隐藏私人配置** + - [前台演示](https://ctc.koogua.com) - [后台演示](https://ctc.koogua.com/admin) - [系统截图](https://gitee.com/koogua/course-tencent-cloud/wikis/系统截图) @@ -29,15 +31,14 @@ #### 会推出商业服务吗? -如果不符合您对“开源”的认知,请移步其它同类产品,毕竟同类“免费”产品也很多。 - -如果“开源”版本不能满足您的需求,或者您更希望有更好的支持,商业服务是不错的选择。 +- 如果不符合您对“开源”的认知,请移步其它同类产品,毕竟同类“免费”产品也很多。 +- 如果“开源”版本不能满足您的需求,或者您更希望有更好的支持,商业服务是不错的选择。 我们目前提供的服务: -1. 安装服务 -2. 会员服务 -3. 定制服务 +- 安装服务 +- 会员服务 +- 定制服务 #### 会有阿里云版吗? @@ -61,10 +62,15 @@ - 移动端:待启动 - 小程序:待启动 +#### 意见反馈 + +- [在线反馈](https://gitee.com/koogua/course-tencent-cloud/issues) +- QQ邮箱: 76632555@qq.com +- QQ群组: 787363898 + #### 加入我们 这是我的创业项目,个人能力和精力有限,要兼顾产品规划以及开发,还要处理除报税记账之外的所有琐碎事情。 +目前在南山科技园某个众创空间,希望有能独挡一面的**深圳前端同学**加入我们。 -目前在南山科技园这边,希望有能独挡一面的**深圳前端同学**加入我们。 - -联系邮箱:xiaochong0302@qq.com +联系邮箱:76632555@qq.com diff --git a/app/Providers/Annotation.php b/app/Providers/Annotation.php index 9f06bdd1..3e524fcf 100644 --- a/app/Providers/Annotation.php +++ b/app/Providers/Annotation.php @@ -4,6 +4,7 @@ namespace App\Providers; use Phalcon\Annotations\Adapter\Memory as MemoryAnnotations; use Phalcon\Annotations\Adapter\Redis as RedisAnnotations; +use Phalcon\Config; class Annotation extends Provider { @@ -12,20 +13,23 @@ class Annotation extends Provider public function register() { - $this->di->setShared($this->serviceName, function () { + /** + * @var Config $config + */ + $config = $this->di->getShared('config'); - $config = $this->getShared('config'); + $this->di->setShared($this->serviceName, function () use ($config) { - if ($config->env == ENV_DEV) { + if ($config->get('env') == ENV_DEV) { $annotations = new MemoryAnnotations(); } else { $annotations = new RedisAnnotations([ - 'host' => $config->redis->host, - 'port' => $config->redis->port, - 'auth' => $config->redis->auth, - 'index' => $config->annotation->db, - 'lifetime' => $config->annotation->lifetime, - 'statsKey' => $config->annotation->statsKey, + 'host' => $config->path('redis.host'), + 'port' => $config->path('redis.port'), + 'auth' => $config->path('redis.auth'), + 'index' => $config->path('annotation.db'), + 'lifetime' => $config->path('annotation.lifetime'), + 'statsKey' => $config->path('annotation.statsKey'), ]); } diff --git a/app/Providers/ProviderInterface.php b/app/Providers/ProviderInterface.php index 8baab3db..d87b6eff 100644 --- a/app/Providers/ProviderInterface.php +++ b/app/Providers/ProviderInterface.php @@ -8,7 +8,7 @@ interface ProviderInterface extends InjectionAwareInterface { /** - * RegisterByPhone application service. + * Register application service. * * @return mixed */