Download the PHP package aryehraber/statamic-uuid without Composer
On this page you can find all versions of the php package aryehraber/statamic-uuid. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download aryehraber/statamic-uuid
More information about aryehraber/statamic-uuid
Files in aryehraber/statamic-uuid
Package statamic-uuid
Short Description One of its kind; unlike anything else
License MIT
Homepage https://github.com/aryehraber/statamic-uuid
Informations about the package statamic-uuid
Uuid (Statamic 3)
One of its kind; unlike anything else
This fieldtype auto-generates UUIDs for empty fields. This can be useful if you need unique, persistent IDs for each row in a Replicator, for example.
Installation
Install the addon via composer:
Publish the fieldtype assets:
Usage
Inside your blueprint, simply use type: uuid
and a UUID will be generated for that field if it's blank. Already occupied fields (including previously generated UUIDs) will not be overwritten.
Settings
Name | Default | Description |
---|---|---|
hidden |
false |
Hide the field from the CP while still generating a UUID. |
read_only |
false |
Set the input to read-only, stopping the user from editing the field. |
id_prefix |
'' |
Add a prefix to the ID. |
id_type |
uuid |
Set the underlying ID generator, options: uuid & nanoid . |
alphabet |
null |
Set a custom alphabet when using nanoid . |
size |
null |
Set the max character limit when using nanoid . |
Example:
Blueprint
Output
Credits
Originally built at Series Eight, now maintained by Aryeh Raber.