承接 derbala/routers 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

derbala/routers

Composer 安装命令:

composer require derbala/routers

包简介

this package used to fetch data from routes

README 文档

README

Fetch data from routes to permissions table and create pivot table between permissions and routes

Requirements

Laravel >=9
PHP >= 8.0
Laravel-Admin >= dev-main

Features

  • Routes Table
  • Permissions Table
  • permission_routes Table

Installation

  1. Run
    composer require derbala/routers
    
  2. Publish vendor
    php artisan vendor:publish --provider="derbala\routers\RouterServiceProvider"
    
  3. Add routes function to the permission model:
    public function routes(){
        return $this->belongsToMany(Route::class)->withTimestamps();
    }
    
  4. Run migrate:
    php artisan migrate
    
  5. Run the following command to fetch data to routes and permissions tables:
    php artisan fetch:routes {route name} {allow translate}
    
    if you want to fetch many routes so you need to put '_' between routes name. to allow translate put 1 in second arugment, otherwise, put 0. For example, if you have 3 routes called admin, metadata and dashboard and you want to fetch them you will run the follwing command:
    php artisan fetch:routes admin_metadata_dashboard 1
    
  6. Run the following command to create pivot table between permissions and routes:
    php artisan fetch:permission_routes
    

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-12-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固