Download the PHP package stryksta/referencenumber without Composer
On this page you can find all versions of the php package stryksta/referencenumber. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download stryksta/referencenumber
More information about stryksta/referencenumber
Files in stryksta/referencenumber
Download stryksta/referencenumber
More information about stryksta/referencenumber
Files in stryksta/referencenumber
Vendor stryksta
Package referencenumber
Short Description Generate a Reference Number when saving Eloquent models
License MIT
Homepage https://github.com/strykstaguy/referencenumber
Package referencenumber
Short Description Generate a Reference Number when saving Eloquent models
License MIT
Homepage https://github.com/strykstaguy/referencenumber
Please rate this library. Is it a good library?
Informations about the package referencenumber
Laravel Reference Number Trait
Generate a reference number for Invoices, Payment Transactions, Form Submissions, etc
Installation
You can install the package via composer:
Options
Option | Type | Default | Description |
---|---|---|---|
field |
string | reference_number |
This is used to identify the field the generated reference number will be saved to. |
start |
integer | 0 |
This is where incrementing will start. When generating a reference number this will always increment by 1. So if you start at 0, your first reference will be 1. |
prefix |
string | '' |
This is a string you want added in front of every reference number |
suffix |
string | '' |
This is a string you want added to the end of every reference number |
padding |
integer | '' |
This will pad the reference number to a specified length. For example, setting padding to 3 will generate 001, 002, 003 and so on. |
Usage
- Your model should use the
Stryksta\ReferenceNumber\GenerateReferenceNumber
trait - You should have a field to save the generated reference number to.
Here's an example of how to implement the trait:
Changelog
1.0.0 - 2020-01-03
- Initial release
Testing
Contributing
Suggestions, Improvements, and any other comments are welcome!
License
The MIT License (MIT). Please see License File for more information.
All versions of referencenumber with dependencies
PHP Build Version
Package Version
The package stryksta/referencenumber contains the following files
Loading the files please wait ....