mirror of
https://gitee.com/koogua/course-tencent-cloud.git
synced 2025-07-10 18:47:09 +08:00
commit
4b88561604
@ -39,11 +39,13 @@ class IndexController extends Controller
|
||||
$todayStat = $indexService->getTodayStat();
|
||||
$appInfo = $indexService->getAppInfo();
|
||||
$serverInfo = $indexService->getServerInfo();
|
||||
$releases = $indexService->getReleases();
|
||||
|
||||
$this->view->setVar('global_stat', $globalStat);
|
||||
$this->view->setVar('today_stat', $todayStat);
|
||||
$this->view->setVar('app_info', $appInfo);
|
||||
$this->view->setVar('server_info', $serverInfo);
|
||||
$this->view->setVar('releases', $releases);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -6,6 +6,7 @@ use App\Caches\SiteGlobalStat;
|
||||
use App\Caches\SiteTodayStat;
|
||||
use App\Library\AppInfo;
|
||||
use App\Library\Utils\ServerInfo;
|
||||
use GuzzleHttp\Client;
|
||||
|
||||
class Index extends Service
|
||||
{
|
||||
@ -52,4 +53,17 @@ class Index extends Service
|
||||
return $cache->get();
|
||||
}
|
||||
|
||||
public function getReleases()
|
||||
{
|
||||
$url = 'https://koogua.com/api-releases.json';
|
||||
|
||||
$client = new Client();
|
||||
|
||||
$response = $client->get($url, ['timeout' => 3]);
|
||||
|
||||
$content = json_decode($response->getBody(), true);
|
||||
|
||||
return $content['releases'] ?? [];
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -63,7 +63,7 @@
|
||||
<iframe name="content" style="width:100%;height:100%;border:0;" src="{{ url({'for':'admin.main'}) }}"></iframe>
|
||||
</div>
|
||||
<div class="layui-copyright">
|
||||
Powered by <a href="{{ app_info.link }}" title="{{ app_info.name }}">{{ app_info.alias }} {{ app_info.version }}</a>
|
||||
Powered by <a href="{{ app_info.link }}" title="{{ app_info.name }}" target="_blank">{{ app_info.alias }} {{ app_info.version }}</a>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
|
@ -13,7 +13,7 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<td>系统框架</td>
|
||||
<td><a href="https://gitee.com/koogua/cphalcon">Phalcon 3.4.5</a></td>
|
||||
<td><a href="https://gitee.com/koogua/cphalcon/releases/v3.4.5.1" target="_blank">Phalcon 3.4.5</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>获取渠道</td>
|
||||
|
@ -1,6 +1,19 @@
|
||||
<div class="layui-card layui-text">
|
||||
<div class="layui-card-header">产品动态</div>
|
||||
<div class="layui-card-body">
|
||||
|
||||
<table class="layui-table">
|
||||
<colgroup>
|
||||
<col width="80%">
|
||||
<col>
|
||||
</colgroup>
|
||||
<tbody>
|
||||
{% for release in releases %}
|
||||
<tr>
|
||||
<td><a href="{{ release.url }}" target="_blank">{{ release.title }}</a></td>
|
||||
<td>{{ release.date }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
@ -9,7 +9,7 @@
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>版权所有</td>
|
||||
<td><a href="http://koogua.com">深圳市酷瓜软件有限公司</a></td>
|
||||
<td><a href="https://koogua.com" target="_blank">深圳市酷瓜软件有限公司</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>产品经理</td>
|
||||
|
@ -10,7 +10,7 @@ use App\Services\Pay\Wxpay as WxpayService;
|
||||
use App\Services\Storage as StorageService;
|
||||
use App\Traits\Response as ResponseTrait;
|
||||
use App\Traits\Security as SecurityTrait;
|
||||
use PHPQRCode\QRcode;
|
||||
use Endroid\QrCode\QrCode;
|
||||
|
||||
class PublicController extends \Phalcon\Mvc\Controller
|
||||
{
|
||||
@ -49,14 +49,17 @@ class PublicController extends \Phalcon\Mvc\Controller
|
||||
public function qrcodeAction()
|
||||
{
|
||||
$text = $this->request->getQuery('text', 'string');
|
||||
$level = $this->request->getQuery('level', 'int', 0);
|
||||
$size = $this->request->getQuery('size', 'int', 5);
|
||||
$size = $this->request->getQuery('size', 'int', 320);
|
||||
|
||||
$url = urldecode($text);
|
||||
$text = urldecode($text);
|
||||
|
||||
QRcode::png($url, false, $level, $size);
|
||||
$qrCode = new QrCode($text);
|
||||
|
||||
$this->response->send();
|
||||
$qrCode->setSize($size);
|
||||
|
||||
$qrCode->getContentType();
|
||||
|
||||
echo $qrCode->writeString();
|
||||
|
||||
exit;
|
||||
}
|
||||
|
@ -9,12 +9,12 @@
|
||||
{% if site_info.copyright %}
|
||||
<span>© {{ site_info.copyright }}</span>
|
||||
{% endif %}
|
||||
<a href="{{ app_info.link }}" title="{{ app_info.name }}">Powered by {{ app_info.alias }} {{ app_info.version }}</a>
|
||||
<a href="{{ app_info.link }}" title="{{ app_info.name }}" target="_blank">Powered by {{ app_info.alias }} {{ app_info.version }}</a>
|
||||
{% if site_info.icp_sn %}
|
||||
<a href="{{ site_info.icp_link }}">{{ site_info.icp_sn }}</a>
|
||||
<a href="{{ site_info.icp_link }}" target="_blank">{{ site_info.icp_sn }}</a>
|
||||
{% endif %}
|
||||
{% if site_info.police_sn %}
|
||||
<a href="{{ site_info.police_link }}">{{ site_info.police_sn }}</a>
|
||||
<a href="{{ site_info.police_link }}" target="_blank">{{ site_info.police_sn }}</a>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
@ -9,7 +9,7 @@ class AppInfo
|
||||
|
||||
protected $alias = 'CTC';
|
||||
|
||||
protected $link = 'https://gitee.com/koogua';
|
||||
protected $link = 'https://koogua.com';
|
||||
|
||||
protected $version = '1.2.4';
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
"phalcon/incubator": "^3.4",
|
||||
"guzzlehttp/guzzle": "^6.3",
|
||||
"swiftmailer/swiftmailer": "^6.0",
|
||||
"peppeocchi/php-cron-scheduler": "^2.4",
|
||||
"peppeocchi/php-cron-scheduler": "^3.0",
|
||||
"yansongda/pay": "^2.9",
|
||||
"tencentcloud/tencentcloud-sdk-php": "^3.0",
|
||||
"qcloudsms/qcloudsms_php": "^0.1",
|
||||
@ -17,12 +17,11 @@
|
||||
"workerman/gatewayclient": "^3.0",
|
||||
"whichbrowser/parser": "^2.0",
|
||||
"hightman/xunsearch": "^1.4",
|
||||
"aferrandini/phpqrcode": "1.0.1",
|
||||
"xiaochong0302/ip2region": "^1.0",
|
||||
"robmorgan/phinx": "^0.12",
|
||||
"lcobucci/jwt": "^3.3",
|
||||
"overtrue/wechat": "^4.2",
|
||||
"joyqi/hyper-down": "dev-master"
|
||||
"joyqi/hyper-down": "dev-master",
|
||||
"endroid/qr-code": "^3.9"
|
||||
},
|
||||
"require-dev": {
|
||||
"odan/phinx-migrations-generator": "^5.3",
|
||||
|
4826
composer.lock
generated
4826
composer.lock
generated
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user