henriquemattia/moeda-br
最新稳定版本:3.3.0
Composer 安装命令:
composer require henriquemattia/moeda-br
包简介
A Laravel Nova custom mask field for the brazilian currency.
README 文档
README
Mask field for brazilian currency
Install
Run this command into your nova project:
composer require henriquemattia/moeda-br
Add it to your Nova Resource:
use Henriquemattia\MoedaBr\MoedaBr; MoedaBr::make('Valor', 'value'),
Optional Methods
You can customize the behavior of the field using the following methods:
-
Multiply the value by a factor:
Use the
multiplyValueBymethod to multiply the input value by a specific integer. For example, to multiply the value by 100:MoedaBr::make('Valor', 'value')->multiplyValueBy(100),
-
Display the value divided by a factor:
Use the
displayValueDividedBymethod to divide the displayed value by a specific integer. This is useful when you want to format or scale the value for display purposes. For example, if you want to display the value divided by 100:MoedaBr::make('Valor', 'value')->displayValueDividedBy(100),
Demo
统计信息
- 总下载量: 9.37k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-04-08
