mirror of
https://github.com/archtechx/money.git
synced 2025-12-12 11:24:03 +00:00
Allow customization of default CurrencyManager
This commit is contained in:
parent
4474c2b115
commit
35304109e5
5 changed files with 71 additions and 1 deletions
20
README.md
20
README.md
|
|
@ -525,6 +525,26 @@ currencies()->add(cache()->remember('currencies', 3600, function () {
|
|||
|
||||
Where the DB call returns an array of array currencies following the [format mentioned above](#creating-a-currency).
|
||||
|
||||
|
||||
## Customization
|
||||
Optionally you could publish the config and replace the `CurrencyManager::class` with your own.
|
||||
|
||||
```bash
|
||||
php artisan vendor:publish --tag="money-config"
|
||||
```
|
||||
|
||||
```php
|
||||
// config/money.php
|
||||
<?php
|
||||
|
||||
return [
|
||||
//...
|
||||
'manager' => \ArchTech\Money\CurrencyManager::class, // replace with your own
|
||||
];
|
||||
|
||||
```
|
||||
|
||||
|
||||
## Development & contributing
|
||||
|
||||
Run all checks locally:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue