<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; class UpdateAreaChinaData extends Migration { public function up() { goto jtmYE; qUc5j: \ModStart\Core\Dao\ModelUtil::insertAll('area_china', $Jpf30); goto NSUAR; IwLfK: \ModStart\Core\Dao\ModelUtil::insertAll('area_china', $eTfUS); goto qUc5j; ualUP: $Jpf30 = array_map(function ($dRTD0) { return array('id' => $dRTD0['code'], 'pid' => $dRTD0['provinceCode'], 'sort' => $dRTD0['code'], 'title' => $dRTD0['name']); }, $Jpf30); goto cLaiW; pTfGw: $Jpf30 = @json_decode(file_get_contents(__DIR__ . '/../Data/cities.json'), true); goto QHEc8; jtmYE: $eTfUS = @json_decode(file_get_contents(__DIR__ . '/../Data/provinces.json'), true); goto pTfGw; EUsc7: $eTfUS = array_map(function ($dRTD0) { return array('id' => $dRTD0['code'], 'pid' => 0, 'sort' => $dRTD0['code'], 'title' => $dRTD0['name']); }, $eTfUS); goto ualUP; kb9Py: \ModStart\Core\Dao\ModelManageUtil::truncate('area_china'); goto IwLfK; QHEc8: $pAMAA = @json_decode(file_get_contents(__DIR__ . '/../Data/areas.json'), true); goto EUsc7; cLaiW: $pAMAA = array_map(function ($dRTD0) { return array('id' => $dRTD0['code'], 'pid' => $dRTD0['cityCode'], 'sort' => $dRTD0['code'], 'title' => $dRTD0['name']); }, $pAMAA); goto kb9Py; NSUAR: \ModStart\Core\Dao\ModelUtil::insertAll('area_china', $pAMAA); goto VzNl5; VzNl5: } public function down() { } }