deesoft/yii2-rest 问题修复 & 功能扩展

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

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

deesoft/yii2-rest

Composer 安装命令:

composer require deesoft/yii2-rest

包简介

Yii2 rest extension

关键字:

README 文档

README

Yii2 rest extension

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require deesoft/yii2-rest "~1.0"

or add

"deesoft/yii2-rest": "~1.0"

to the require section of your composer.json file.

Usage

In controller

public function actions()
{
    return [
        'index' => [
            'class' => 'dee\rest\RestAction',
        ],
    ];
}

To use url rule. Set in config

        'urlManager' => [
            'enablePrettyUrl' => true,
            'showScriptName' => false,
            'rules' => [
                [
                    'class' => 'dee\rest\UrlRule',
                    'actions' => [
                        'post' => 'post/index',
                        
                    ],
                ],
            ],
        ],

统计信息

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

GitHub 信息

  • Stars: 4
  • Watchers: 3
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2015-04-21