stayallive/laravel-eloquent-uuid 问题修复 & 功能扩展

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

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

stayallive/laravel-eloquent-uuid

最新稳定版本:v1.0.4

Composer 安装命令:

composer require stayallive/laravel-eloquent-uuid

包简介

Generate UUID for a Laravel Eloquent model attribute.

README 文档

README

Latest Version Software License Build Status Total Downloads

Generate UUID for a Laravel Eloquent model attribute.

Note This package still works great, however since Laravel 10 this package is no longer needed as Laravel now has a built-in UUID/ULID traits that work much the same as this package. Read more about UUID/ULID in the Laravel documentation.

Installation

composer require stayallive/laravel-eloquent-uuid

Usage

Adding the UsesUUID trait will ensure that the key attribute will be filled with a UUID.

<?php namespace App\Models; use Illuminate\Database\Eloquent\Model; use Stayallive\Laravel\Eloquent\UUID\UsesUUID; class SomeModel extends Model { use UsesUUID; /**  * This method is not needed but can be used to override which attribute is filled with the UUID.  */ public function getUUIDAttributeName(): string { return $this->getKeyName(); } }

Security Vulnerabilities

If you discover a security vulnerability within this package, please send an e-mail to Alex Bouma at alex+security@bouma.me. All security vulnerabilities will be swiftly addressed.

License

This package is open-sourced software licensed under the MIT license.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固