定制 friskals/countries 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

friskals/countries

Composer 安装命令:

composer require friskals/countries

包简介

Nominal formatting and phone validation for Laravel Framework

README 文档

README

This package allow you

  • Set the nominal and currency format of a value based on the given country.
  • Validate and transform phone number of a particular country.

Instalation

  • Install with composer
composer require friskals/countries

For Laravel >=5.5 that's all. You don't need any configurations since it's already handled by Laravel Package Discovery but for Lumen you need a simple configuration.

Configuration

The default are set in config/country.php.

Lumen

  • Load your configuration file in bootstrap/app.php
     $app->configure('country');
  • And register your provider at bootstrap/app.php
    $app->register(Friskals\Countries\Providers\CountryServiceProvider::class);

Usage

  • Format Currency
$nominal_currency = Friskals\Countries\CountryLoader::country('ID')->format_currency(1000); 
  • Format Nominal
$nominal = Friskals\Countries\CountryLoader::country('ID')->format_nominal(1000);
  • Validate Phone
$is_validated = Friskals\Countries\CountryLoader::country('ID')->validate_phone('+6208120812081');
  • Transform Phone
$phone = Friskals\Countries\CountryLoader::country('ID')->transform_phone('+6208120812081');

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2021-11-08

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固