定制 kematjaya/price-bundle 二次开发

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

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

kematjaya/price-bundle

最新稳定版本:7.2

Composer 安装命令:

composer require kematjaya/price-bundle

包简介

README 文档

README

Price Type Extension for Symfony 4

  1. installation

    composer require kematjaya/price-bundle
    
  2. add to bundles.php

    Kematjaya\PriceBundle\PriceBundle::class => ["all" => true]
    
  3. add in twig.yaml

    twig:
    form_themes: 
        ....
        - '@Price/bootstrap_5_price_layout.html.twig' ## for bootstrap 5
        - '@Price/bootstrap_4_price_layout.html.twig' ## for bootstrap 4
        - '@Price/bootstrap_3_price_layout.html.twig' ## for bootstrap 3
        ....
    
  4. Usage 3.1. Form

    ...
    use Kematjaya\PriceBundle\Type\PriceType;
    ...
    
    $builder->add("price", PriceType::class);
    ...
    

    3.2. Twig

    • terbilang
    {{ terbilang(1000) }} // seribu
    {{ terbilang(40000) }} // empat puluh ribu
    
    • price format
    {{ price(1000) }} // IDR 1,000
    {{ price(1000.22) }} // IDR 1,000.22
    {{ price(4500) }} // IDR 4,500
    

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-04-06