@@ -37,7 +37,7 @@ |
||
| 37 | 37 | is_a($this->capsule->getConnection()->getPdo(), \PDO::class ); |
| 38 | 38 | } catch (\Exception $exception) |
| 39 | 39 | { |
| 40 | - dd($exception->getMessage()); |
|
| 40 | + dd($exception->getMessage()); |
|
| 41 | 41 | } |
| 42 | 42 | } |
| 43 | 43 | } |
| 44 | 44 | \ No newline at end of file |
@@ -15,8 +15,8 @@ |
||
| 15 | 15 | foreach ($this->migrations as $migration) |
| 16 | 16 | { |
| 17 | 17 | $migration->check(function ($object){ |
| 18 | - $object->execute(); |
|
| 19 | - }); |
|
| 18 | + $object->execute(); |
|
| 19 | + }); |
|
| 20 | 20 | } |
| 21 | 21 | } |
| 22 | 22 | } |
| 23 | 23 | \ No newline at end of file |
@@ -18,9 +18,9 @@ |
||
| 18 | 18 | ]; |
| 19 | 19 | |
| 20 | 20 | protected $listFilesSeeder = [ |
| 21 | - 'CountryTableSeeder' => 'CountryTableSeeder.php', |
|
| 22 | - 'RegionsTableSeeder' => 'RegionsTableSeeder.php', |
|
| 23 | - 'CitiesTableSeeder' => 'CitiesTableSeeder.php' |
|
| 21 | + 'CountryTableSeeder' => 'CountryTableSeeder.php', |
|
| 22 | + 'RegionsTableSeeder' => 'RegionsTableSeeder.php', |
|
| 23 | + 'CitiesTableSeeder' => 'CitiesTableSeeder.php' |
|
| 24 | 24 | ]; |
| 25 | 25 | |
| 26 | 26 | protected $formatterStyle; |
@@ -90,8 +90,8 @@ |
||
| 90 | 90 | $this->settings['databasePassword'] = $helper->ask($input, $output, $question); |
| 91 | 91 | |
| 92 | 92 | |
| 93 | - $table = new Table($output); |
|
| 94 | - $table->setHeaders(array('name', 'value')) |
|
| 93 | + $table = new Table($output); |
|
| 94 | + $table->setHeaders(array('name', 'value')) |
|
| 95 | 95 | ->setRows(array( |
| 96 | 96 | array('Type database', $this->settings['databaseType']), |
| 97 | 97 | array('Host database', $this->settings['host']), |
@@ -1,25 +1,25 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | return [ |
| 4 | - // Your native language |
|
| 5 | - // 0 — Russian, |
|
| 6 | - // 1 — Ukrainian, |
|
| 7 | - // 2 — Belarusian, |
|
| 8 | - // 3 — English, |
|
| 9 | - // 4 — Spanish, |
|
| 10 | - // 5 — Finnish, |
|
| 11 | - // 6 — German, |
|
| 12 | - // 7 — Italian. |
|
| 13 | - 'locale' => 0, |
|
| 4 | + // Your native language |
|
| 5 | + // 0 — Russian, |
|
| 6 | + // 1 — Ukrainian, |
|
| 7 | + // 2 — Belarusian, |
|
| 8 | + // 3 — English, |
|
| 9 | + // 4 — Spanish, |
|
| 10 | + // 5 — Finnish, |
|
| 11 | + // 6 — German, |
|
| 12 | + // 7 — Italian. |
|
| 13 | + 'locale' => 0, |
|
| 14 | 14 | |
| 15 | - // Country you wish to migrate |
|
| 16 | - // standard 3166-1 alpha-2 |
|
| 17 | - // example RU,AU |
|
| 15 | + // Country you wish to migrate |
|
| 16 | + // standard 3166-1 alpha-2 |
|
| 17 | + // example RU,AU |
|
| 18 | 18 | 'country' => 'RU', |
| 19 | 19 | |
| 20 | - 'nameTable' => [ |
|
| 21 | - 'country' => 'country', |
|
| 22 | - 'regions' => 'regions', |
|
| 23 | - 'cities' => 'cities' |
|
| 24 | - ] |
|
| 20 | + 'nameTable' => [ |
|
| 21 | + 'country' => 'country', |
|
| 22 | + 'regions' => 'regions', |
|
| 23 | + 'cities' => 'cities' |
|
| 24 | + ] |
|
| 25 | 25 | ]; |
| 26 | 26 | \ No newline at end of file |
@@ -13,11 +13,11 @@ |
||
| 13 | 13 | */ |
| 14 | 14 | public function run() |
| 15 | 15 | { |
| 16 | - $body = file_get_contents('https://api.vk.com/method/database.getCountries?v=5.5&need_all=1&count=1000&lang='. |
|
| 17 | - config('geography.locale') . '&code=' . config('geography.country') . '&access_token=' . |
|
| 18 | - config('geography.access_token')); |
|
| 19 | - $response = json_decode($body, true); |
|
| 16 | + $body = file_get_contents('https://api.vk.com/method/database.getCountries?v=5.5&need_all=1&count=1000&lang='. |
|
| 17 | + config('geography.locale') . '&code=' . config('geography.country') . '&access_token=' . |
|
| 18 | + config('geography.access_token')); |
|
| 19 | + $response = json_decode($body, true); |
|
| 20 | 20 | |
| 21 | - Capsule::table( config('geography.nameTable.country') )->insert( $response['response']['items'] ); |
|
| 21 | + Capsule::table( config('geography.nameTable.country') )->insert( $response['response']['items'] ); |
|
| 22 | 22 | } |
| 23 | 23 | } |