1
0
Fork 0

Compare commits

..

No commits in common. "15ed5a1a77316c752e417791a49479e885c4b0a2" and "16aae8cfa2e3e53c89b9e35315e329729431bb55" have entirely different histories.

6 changed files with 17 additions and 21 deletions

View File

@ -1,6 +1,6 @@
- `cp .env.example .env`
- `php artisan key:generate`
- `php artisan storage:link`
- 创建数据库
- 修改 .env 文件中的配置
- `php artisan migrate --seed`
php artisan k:g
php artisan storage:link
php artsian admin:publish
php artisan admin:install
php artisan db:seed AdminMenuSeeder

View File

@ -9,7 +9,6 @@ use Slowlyo\OwlAdmin\Renderers\TextControl;
use Slowlyo\OwlAdmin\Controllers\AdminController;
use App\Services\Admin\AdminNoticeService;
use App\Admin\Components;
use Slowlyo\OwlAdmin\OwlAdmin;
class AdminNoticeController extends AdminController
{
@ -19,16 +18,12 @@ class AdminNoticeController extends AdminController
public function list(): Page
{
$options = [];
$user = OwlAdmin::user();
// 添加权限
if ($user->can('admin_notice.create')) {
array_push($options, $this->createButton(true, 'lg'));
}
$options = array_merge($options, $this->baseHeaderToolBar(),);
$crud = $this->baseCRUD()
->filterTogglable(false)
->headerToolbar($options)
->headerToolbar([
$this->createButton(true, 'lg'),
...$this->baseHeaderToolBar(),
])
->columns([
TableColumn::make()->name('id')->label('ID')->sortable(true),
TableColumn::make()->name('title')->label('标题'),

View File

@ -32,8 +32,6 @@ class SettingController extends AdminController
->redirect('')
->api($this->getStorePath())
->data(settings()->all())
->panelClassName('')
->title('')
->body(
Tabs::make()->tabs([
Tab::make()->title('基本设置')->body([

View File

@ -73,7 +73,6 @@ class AdminMenuSeeder extends Seeder
['title' => '权限管理', 'icon' => 'icon-park:key-one', 'url' => '/system/admin_permissions', 'order'=>3],
['title' => '菜单管理', 'icon' => 'icon-park:menu-fold-one', 'url' => '/system/admin_menus', 'order'=>4],
['title' => '字典管理', 'icon' => 'icon-park:arrow-keys', 'url' => '/keywords', 'order'=>5],
['title' => '配置管理', 'icon' => 'icon-park:setting-two', 'url' => '/system/settings', 'order'=>6],
],
],
];

View File

@ -14,7 +14,11 @@ class DatabaseSeeder extends Seeder
*/
public function run()
{
$this->call(AdminMenuSeeder::class);
$this->call(AdminSeeder::class);
// \App\Models\User::factory(10)->create();
// \App\Models\User::factory()->create([
// 'name' => 'Test User',
// 'email' => 'test@example.com',
// ]);
}
}

View File

@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="zh-CN">
<html lang="zh">
<head>
<meta charset="UTF-8"/>
<link rel="icon" href="/admin/logo.png"/>