jdlxnl/jdlx 问题修复 & 功能扩展

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

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

jdlxnl/jdlx

Composer 安装命令:

composer require jdlxnl/jdlx

包简介

Foundation for rest APIs in Laravel

README 文档

README

This packages offers a set of tools to support a REST API. It is very biased and does not offer much in the way of configuration.

It can:

Installation

Add the package by loading it through composer.

composer require jdlxnl/jdlx

Run the following commands to setup the database

php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"
php artisan vendor:publish --provider="Spatie\Permission\PermissionServiceProvider"
php artisan vendor:publish --provider="Jdlx\JdlxServiceProvider"

## By default files won't be overwritten. This is good for existing intallations
## For new installation use force to overwrite the following:
##  - router/api.php
##  - app/Models/User.php
##  - app/Exception/Handler.php
##
php artisan vendor:publish --provider="Jdlx\JdlxServiceProvider" --force

php artisan migrate

Generate the User scaffold

php artisan api:scaffold User

Add to config/app.php to enable formatted responses

    /*
     * Package Service Providers...
     */
     Jdlx\Providers\ResponseServiceProvider::class,

Update to config/permission.php to allow wildcards

    'enable_wildcard_permission' => true,

Add to .env

SANCTUM_STATEFUL_DOMAINS=*.local.me,localhost,localhost:8000,localhost:3000,127.0.0.1,127.0.0.1:8000,::1
SESSION_SECURE_COOKIE=false
Tips and tricks
  • In JetBreans mark the publish folder as excluded to prevent clashes

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2021-12-23

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固