承接 raiolanetworks/atlas 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

raiolanetworks/atlas

最新稳定版本:1.0.7

Composer 安装命令:

composer require raiolanetworks/atlas

包简介

Get the data from the most recondite place with 'Atlas'

README 文档

README

With 'Atlas' you will be able to create new tables in the database and fill them with information about countries, states, cities, timezones and more.

Get to know us

Installation

You can install the package via composer:

composer require raiolanetworks/atlas

You can publish the migrations with:

php artisan vendor:publish --tag="atlas-migrations"

Also, you can publish the config file with:

php artisan vendor:publish --tag="atlas-config"

Finally, you can publish the data jsons file with:

php artisan vendor:publish --tag="atlas-jsons"

For run the migrations and fill the tables you should run:

php artisan atlas:install

This will migrate the database tables previously allowed in the configuration file in the entities section. (By default, all are allowed)

When the command is executed, it will give the option to select which seeders to run.

The process may take a few minutes as the number of cities is very large.

Usage

Internally, the package works with Laravel models, which allows you to work with this model as if they were models of your own project.

For example, if you want to get all the countries in Africa:

use Raiolanetworks\Atlas\Models\Country;

class MyClass
{
	public function getAllAfricaCountries(): Collection
	{
		Country::whereRegion('Africa')
			->orderBy('name')
			->get();
		}
}

Changelog

Please see CHANGELOG for more information on what has changed recently.

Credits

License

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

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-03-19