zifan/laravel-addressparser

laravel中文收货地址智能识别

v1.0.4 2023-05-22 03:03 UTC

This package is auto-updated.

Last update: 2024-04-22 05:29:56 UTC


README

Latest Version on Packagist Total Downloads Build Status StyleCI

Take a look at contributing.md to see a to do list.

Requirements

  • PHP >= 7.1.0
  • Mbstring PHP Extension
  • Laravel >= 5.5.0

Installation

Via Composer

$ composer require zifan/laravel-addressparser

Then run these commands to publish config:

$ php artisan vendor:publish --tag="addressparser.config"

After run command you can find config file in config/addressparser.php, in this file you can change the settings.

Configuration

  • dataProvider array Default setting: [ 'driver' => 'database', 'model' => 'Zifan\LaravelAddressParser\Models\Area' ]

If you use the plug-in's default data provider, follow these instructions:

$ php artisan address-parser:table
$ php artisan migrate --step
  • Omit others

Usage

\AddressParser::smart('浙江省杭州市滨江区西兴街道滨康路228号万福中心A座21楼');

Change log

Please see the changelog for more information on what has changed recently.

Contributing

Please see contributing.md for details and a todolist.

Security

If you discover any security related issues, please email s443939412@163.com instead of using the issue tracker.

Credits

License

MIT. Please see the license file for more information.