承接 asahasrabuddhe/laravel-api 相关项目开发

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

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

asahasrabuddhe/laravel-api

Composer 安装命令:

composer require asahasrabuddhe/laravel-api

包简介

A package that makes developing APIs in Laravel (Lumen too) very very easy

README 文档

README

A powerful package designed to make developing APIs very easy. This package takes care of all the boiler-plate code to provide support for routes, controller methods and associated logic out of the box.

Please note, this package is still in development and the documentation below is subject to change in ways which can make it incompatible with previous versions. Please DO NOT use in production until 1.0 release.

Installation

The package is currently under development and hence is not available on composer. Please use the following method to install and help build this package.

Clone the repository inside your Laravel installation as follows:

git clone https://github.com/asahasrabuddhe/laravel-api packages/asahasrabuddhe/laravelapi

Add the following lines in your composer.json file to help install the package

"repositories": [
        {
            "type": "path",
            "url": "packages/asahasrabuddhe/laravel-api",
            "options": {
                "symlink": true
            }
        }
    ],

Then, add the following lines in the require section of your composer file and run composer update.

"asahasrabuddhe/laravel-api": "dev-master"

You are now ready to use the package.

Basic Usage

  1. To enable using this package, replace the following:

a. Models: Replace all instances of use Illuminate\Database\Eloquent\Model; with use Asahasrabuddhe\LaravelAPI\BaseModel;. For the Laravel default user model, replace use Illuminate\Foundation\Auth\User as Authenticatable; with use Asahasrabuddhe\LaravelAPI\BaseUser as Authenticatable;

b. Controllers: Add the following line to the top of your controller: use Asahasrabuddhe\LaravelAPI\BaseController as Controller

2.Routing: Please define the routes as following in routes/api.php file:

ApiRoute::group([
    'middleware' => ['api'],
    'namespace' => 'App\Http\Controllers'], function () {
        ApiRoute::resource('user', 'UserController');
        ApiRoute::resource(<route>, <controller>);
    }
);

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: Unknown
  • 更新时间: 2018-04-24

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固