ownego/laravel-shopify-currency
最新稳定版本:1.0.0
Composer 安装命令:
composer require ownego/laravel-shopify-currency
包简介
Currency converter using Shopify's currencies cdn file
README 文档
README
This package created for convert between 2 currencies by using currencies.js file provided by Shopify.
Installation
-
Install package
composer require ownego/laravel-shopify-currency -
Optional: add the service provider
'providers' => [ // ... Ownego\LaravelShopifyCurrency\LaravelShopifyCurrencyServiceProvider::class, ],
-
Optional: publish config
php artisan vendor:publish --provider=Ownego\LaravelShopifyCurrency\LaravelShopifyCurrencyServiceProvider -
Optional: add facade
'alias' => [ // ... 'ShopifyCurrency' => Ownego\LaravelShopifyCurrency\Facades\ShopifyCurrency::class, ],
Usage
- Convert
use Ownego\LaravelShopifyCurrency\Facades\ShopifyCurrency; $result = ShopifyCurrency::convert(100, 'eur', 'usd');
- Get rate
use Ownego\LaravelShopifyCurrency\Facades\ShopifyCurrency; $result = ShopifyCurrency::rate('eur', 'usd');
Command
If you want to manually update currencies from cache, then run:
php artisan shopify-currency:cache
统计信息
- 总下载量: 6.53k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2021-07-23