提交 fed1da31 编写于 作者: S server

develop

上级 6a9e3dd8
<?php
namespace Module\Cms\Traits;
use ModStart\Admin\Layout\AdminPage;
use ModStart\Admin\Widget\SecurityTooltipBox;
use ModStart\Layout\Row;
use Module\AdminManager\Widget\ServerInfoWidget;
use Module\Cms\Widget\CmsInfoWidget;
use Module\Vendor\Admin\Config\AdminWidgetDashboard;
trait AdminDashboardTrait
{
public function dashboard()
{
$page = app(AdminPage::class);
$page->pageTitle(L('Dashboard'))
->row(new SecurityTooltipBox())
->append(new Row(function (Row $row) {
AdminWidgetDashboard::callIcon($row);
}));
AdminWidgetDashboard::call($page);
$page->append(new CmsInfoWidget());
$page->append(new ServerInfoWidget());
return $page;
}
}
......@@ -85,9 +85,11 @@
@foreach($channelTree as $channelGroup)
<a class="group-title" href="{{modstart_web_url('channel/'.$channelGroup['alias'])}}">{{$channelGroup['title']}}</a>
<div class="group-list">
@foreach($channelGroup['_child'] as $channel)
<a class="item" href="{{modstart_web_url('channel/'.$channel['alias'])}}">{{$channel['title']}}</a>
@endforeach
@if(!empty($channelGroup['_child']))
@foreach($channelGroup['_child'] as $channel)
<a class="item" href="{{modstart_web_url('channel/'.$channel['alias'])}}">{{$channel['title']}}</a>
@endforeach
@endif
</div>
@endforeach
</div>
......
......@@ -70,6 +70,7 @@ class ModuleStoreController extends Controller
$version = $dataInput->getTrimString('version');
BizException::throwsIfEmpty('module为空', $module);
BizException::throwsIfEmpty('version为空', $version);
BizException::throwsIf('当前环境禁止操作模块管理相关功能', config('env.MS_MODULE_STORE_DISABLE', false));
switch ($step) {
default:
$ret = ModuleManager::disable($module);
......@@ -90,6 +91,8 @@ class ModuleStoreController extends Controller
$version = $dataInput->getTrimString('version');
BizException::throwsIfEmpty('module为空', $module);
BizException::throwsIfEmpty('version为空', $version);
BizException::throwsIf('当前环境禁止操作模块管理相关功能', config('env.MS_MODULE_STORE_DISABLE', false));
switch ($step) {
default:
$ret = ModuleManager::enable($module);
......@@ -112,6 +115,8 @@ class ModuleStoreController extends Controller
BizException::throwsIfEmpty('module为空', $module);
BizException::throwsIfEmpty('version为空', $version);
BizException::throwsIf('系统模块不能动态配置', ModuleManager::isSystemModule($module));
BizException::throwsIf('当前环境禁止操作模块管理相关功能', config('env.MS_MODULE_STORE_DISABLE', false));
if ($isLocal) {
switch ($step) {
default:
......@@ -152,7 +157,9 @@ class ModuleStoreController extends Controller
$version = $dataInput->getTrimString('version');
BizException::throwsIfEmpty('module为空', $module);
BizException::throwsIfEmpty('version为空', $version);
switch ($step) {
BizException::throwsIf('当前环境禁止操作模块管理相关功能', config('env.MS_MODULE_STORE_DISABLE', false));
switch ($step) {
case 'installModule':
$ret = ModuleManager::install($module, true);
BizException::throwsIfResponseError($ret);
......@@ -204,6 +211,8 @@ class ModuleStoreController extends Controller
BizException::throwsIfEmpty('module为空', $module);
BizException::throwsIfEmpty('version为空', $version);
BizException::throwsIf('系统模块不能动态配置', ModuleManager::isSystemModule($module));
BizException::throwsIf('当前环境禁止操作模块管理相关功能', config('env.MS_MODULE_STORE_DISABLE', false));
if ($isLocal) {
switch ($step) {
case 'installModule':
......@@ -287,6 +296,7 @@ class ModuleStoreController extends Controller
}
}
return $builder->perform(RepositoryUtil::itemFromArray($moduleInfo['config']), function (Form $form) use ($module) {
BizException::throwsIf('当前环境禁止操作模块管理相关功能', config('env.MS_MODULE_STORE_DISABLE', false));
ModuleManager::saveUserInstalledModuleConfig($module, $form->dataForming());
return Response::generate(0, '保存成功', null, CRUDUtil::jsDialogClose());
});
......
提供网站模块管理工作,通过模块市场,可以安装模块市场的所有模块,方便满足您对系统的不同需求。
const gulp = require('gulp');
const gulpfile = require('./../../../../vendor/modstart/modstart/resources/asset/src/mod/gulpfile.js');
gulpfile(gulp, __dirname)
此差异已折叠。
......@@ -34,7 +34,7 @@ return [
'asset' => [
'driver' => \ModStart\Core\Assets\Driver\LocalAssetsPath::class,
'cdn' => '/',
'cdn' => env('CDN_URL', '/'),
'image_none' => '',
],
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册