hakhant/convert-mm 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

hakhant/convert-mm

最新稳定版本:v1.0.1

Composer 安装命令:

composer require hakhant/convert-mm

包简介

Myanmar date and nrc number converter

README 文档

README

Testing

Installation

You can install the package via composer:

composer require hakhant/convert-mm

Publish the configuration:

php artisan vendor:publish --tag=convert

Usage

Convert number to myanmar format

$number = '1234567';

$convert = Convert::mm($number);

return $convert;

// output 
'၁၂၃၄၅၆၇'

Convert date to myanmar format

$today = '2023-08-07';

$convert = Convert::mmDate($today);

return $convert;

// output 
'၂၀၂၃ ခုနှစ်၊သြဂုတ်လ၊ ၀၇ ရက်'

Date Avaliable lists

$mmDateNumber = Convert::mmDateNumber('2023-08-07') 
// output '၂၀၂၃-၀၈-၀၇'

$year = Convert::year('2023') 
// output '၂၀၂၃'

$month = Convert::month('08') 
// output 'သြဂုတ်'

$day = Convert::day('8') 
// output '၈'

NRC Avaliable Lists

$regions = Convert::regions(); 
// return array of regions english format 

$mmRegions = Convert::mmRegions(); 
// return array of regions myanmar format

$citizens = Convert::citizens(); 
// return array of citizens 

$mmCitizens = Convert::mmCitizens(); 
// return array of citizens myanmar format

$townships = Convert::townships(); 
// return array of townships 

$mmTownships = Convert::mmTownships(); 
// return array of townships 

$number = Convert::nrcNumber('215556'); 
// return string '215556'

$mmNumber = Convert::mmNrcNumber('215556') 
// return string '၂၁၅၅၅၆'

$fullNrc = Convert::fullNrc('12/', 'YaKaNa', '(N)', 123456); 
// Or 
$fullNrc = Convert::fullNrc('12', 'YaKaNa', 'N', 123456);
// Example out  '12/YaKaNa(N)215556'

$mmFullNrc = Convert::mmFullNrc('၁၂/', 'ရကန', '(နိင်)', 123456); 
// Or
$mmFullNrc = Convert::mmFullNrc('၁၂', 'ရကန', 'နိင်', 123456); 
// example output '၁၂/ရကန(နိုင်)၂၁၅၅၅၆'

Testing

composer test

Changelog

Please see CHANGELOG for more information what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security

If you discover any security related issues, please email info@hakhant.tech instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 48
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-05-20