2017 © Pedro Peláez
 

laravel-library postal-pt

Postal-PT is a bundle for Laravel with all Portuguese postal codes.

image

luismarcelino/postal-pt

Postal-PT is a bundle for Laravel with all Portuguese postal codes.

  • Tuesday, August 18, 2015
  • by luismarcelino
  • Repository
  • 1 Watchers
  • 0 Stars
  • 3 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Freguesias

Postal-PT is a Laravel 5 package that provides all post codes in Portugal., (*1)

Instalation

Add luismarcelino/postal-pt to composer.json., (*2)

"luismarcelino/postal-pt": "dev-master"

Run composer update to pull down the latest version of Postal Codes List., (*3)

Edit config/app.php and add the provider and filter, (*4)

'providers' => [
    Luismarcelino\PostalPt\CodigosPostaisServiceProvider::class,
]

Now add the alias., (*5)

'aliases' => [
    'PostalPt' => Luismarcelino\PostalPt\CodigosPostaisFacade::class,
]

Publishing

Optionaly you can publishing the configuration if you want to change the default table name post_codes_pt:, (*6)

$ php artisan vendor:publish

To generate the migration file use:, (*7)

$ php artisan postalpt:migration

This will generate the <timestamp>_setup_post_codes_pt_table.php migration file. To run the migration, run as usual:, (*8)

php artisan migrate

As the amount of the data to be inserted in the 'post_code_pt' table is large, you must use the follow artisan command (there is no 'db:seed' file):, (*9)

php artisan postalpt:seed

The Versions

18/08 2015

dev-master

9999999-dev https://github.com/luismarcelino/postal-pt

Postal-PT is a bundle for Laravel with all Portuguese postal codes.

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

laravel portugal administrative region postal codes