sujan-sht/admin-master 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

sujan-sht/admin-master

最新稳定版本:v1.0.0

Composer 安装命令:

composer require sujan-sht/admin-master

包简介

Laravel Admin Panel

README 文档

README

Latest Version on Packagist Total Downloads GitHub Actions

Installation

You can install the package via composer:

composer require sujan-sht/admin-master

Usage

To use the admin panel, you must publish the required assets and configuration files. Run the following commands:

php artisan vendor:publish --tag=admin-master-config
php artisan vendor:publish --tag=media-library-modules
php artisan vendor:publish --provider="Rappasoft\LaravelLivewireTables\LaravelLivewireTablesServiceProvider" --tag=livewire-tables-config
php artisan vendor:publish --tag=admin-master-seeders

These will publish:

  • Public assets (CSS, JS)

  • Configuration file (config/admin-master.php)

  • Media library module scaffolding (app/Modules)

After publishing, In config/livewire-tables.php file

'theme' => 'bootstrap-4',

Add AdminMasterUser Trait in Your User Model

use SujanSht\AdminMaster\Traits\AdminMasterUser;

class User extends Authenticatable
{
    use AdminMasterUser;
}

To migrate tables

php artisan migrate

Seed the database to create superadmin,dummy roles and permissions

php artisan db:seed RoleSeeder
php artisan db:seed UserSeeder
php artisan db:seed PermissionSeeder

You can now login superadmin user using this credentials

email: admin@admin.com
password: admin123

In config/app.php add this line.

'providers' => ServiceProvider::defaultProviders()->merge([
        ......
        App\Providers\AdminServiceProvider::class
    ])->toArray(),

In routes/web.php add this line

Route::admin();

You can simply generate CRUD using command/by creating menu from admin panel that will generate all the files in repository pattern.

php artisan make:crud Test

Install Media Library

Include Package Path In composer.json .

    "repositories": {
        "spatie/laravel-medialibrary-pro": {
            "type": "path",
            "url": "app/Modules",
            "options": {
                "symlink": true
            }
        }
    }

After adding it in composer.json, run the command

composer require spatie/laravel-medialibrary-pro:dev-main

Optional

To customize configuration, views, migrations, and seeders, you may also publish:

php artisan vendor:publish --tag=admin-master-assets
php artisan vendor:publish --tag=admin-master-views
php artisan vendor:publish --tag=admin-master-migrations

These allow you to:

  • Override package blade views

  • Modify database migrations and seeders as needed

Contributing

Please see CONTRIBUTING for details.

Security

If you discover any security related issues, please email sujanstha016@gmail.com instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

Laravel Package Boilerplate

This package was generated using the Laravel Package Boilerplate.

统计信息

  • 总下载量: 14
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: Blade

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-07-18