承接 afaanbilal/laravel-has-uuid 相关项目开发

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

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

afaanbilal/laravel-has-uuid

最新稳定版本:0.1.3

Composer 安装命令:

composer require afaanbilal/laravel-has-uuid

包简介

Autogenerate UUIDs for your Models on insert and set the route-model-binding key to uuid.

README 文档

README

Author: Afaan Bilal

Introduction

Laravel HasUUID is a package for Laravel to autogenerate UUIDs for your Models on insert and set the route-model-binding key to uuid. Also adds a fromUUID method to your Model which accepts a uuid and returns a model instance if found, or null otherwise.

Please make sure that you have column in your table called uuid which is a unique index.

Example (in migration):

$table->string('uuid')->unique();

Installation

composer require afaanbilal/laravel-has-uuid

Usage

// In any model:

use AfaanBilal\LaravelHasUUID\HasUUID;
// ...

class Post extends Model
{
    use HasUUID;
    // ...
}

Contributing

All contributions are welcome. Please create an issue first for any feature request or bug. Then fork the repository, create a branch and make any changes to fix the bug or add the feature and create a pull request. That's it! Thanks!

License

Laravel HasUUID is released under the MIT License. Check out the full license here.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-06-23