承接 gonzalo123/rest 相关项目开发

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

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

gonzalo123/rest

Composer 安装命令:

composer require gonzalo123/rest

包简介

Simple REST crud server.

README 文档

README

Simple REST crud server.

Build Status

model objects will share the interface:

<?php

namespace Rest;

use \Symfony\Component\HttpFoundation\Request;

interface Iface
{
    public function __construct($id, \PDO $pdo);

    public function get();

    public function delete();

    public function update(Request $request);

    public function create(Request $request);

    public static function getAll(Request $request);
}

initialize the server mapping the model to the real class names:

<?php
// index.php
use Rest\App;

$app = App::create(new \PDO('sqlite::memory:'));

$app->register('dogs', '\App\Dogs');
$app->register('cats', '\App\Cats');

$app->getResponse()->send();

The server will handle GET request to get(), DELETE to delete(), POST to update() and CREATE to create().

If we perform a GET request without id (null) then the static getAll is raised

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2012-12-27

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固