Commit 73ffd048 by 杨树贤

支持供应商国家/地区

parent 0f9ae83d
......@@ -103,6 +103,7 @@ class SupplierApiController extends Controller
'sign_com_id',
'sku_optional_batch',
'nation_id',
];
public function Entrance(Request $request, $id)
......
......@@ -63,7 +63,7 @@ class SupplierReceiptApiController extends Controller
'remark',
'nation_id',
'intermediary_bank',
//'international_code'
//'nation_id'
]);
$receipt = array_map('trim', $receipt);
$receipt['account_adderss'] = empty($receipt['account_adderss']) ? ' ' : $receipt['account_adderss'];
......
......@@ -179,13 +179,13 @@ class SupplierController extends Controller
'value' => $userId,
];
}
$this->data['nationList'] = NationModel::getNationList();
$defaultPurchaseUid = $intraCodeModel->getCodeIdByUserName(config('field.DefaultPurchaseName'));
$this->data['operate'] = 'add';
$this->data['default_purchase_uid'] = $defaultPurchaseUid;
//省市区数据放到script模板
$regionService = new RegionService();
$this->data['region_data'] = $regionService->getCityRegionData();
$this->data['nationList'] = NationModel::pluck('name_cn', 'nation_id')->toArray();
$this->data['brand_init_value'] = [];
$this->data['agency_brand_init_value'] = [];
//编辑
......@@ -225,6 +225,7 @@ class SupplierController extends Controller
//省市区数据放到script模板
$regionService = new RegionService();
$this->data['region_data'] = $regionService->getCityRegionData();
$this->data['nationList'] = NationModel::getNationList();
//编辑
$this->data['title'] = '编辑供应商';
$supplierId = $request->get('supplier_id');
......
......@@ -7,7 +7,6 @@ use App\Http\Services\SupplierContactService;
use App\Http\Services\SupplierService;
use App\Http\Services\SupplierStatisticsService;
use App\Http\Services\ViewCheckService;
use App\Model\IntracodeModel;
use App\Model\NationModel;
use App\Model\SupplierChannelModel;
use App\Model\SupplierReceiptModel;
......@@ -48,6 +47,7 @@ class SupplierReceiptController extends Controller
{
$this->data['title'] = '添加供应商银行';
$this->data['nationList'] = NationModel::pluck('name_cn','nation_id')->toArray();
$this->data['internationalCodeList'] = NationModel::getNationList();
return $this->view('添加供应商银行');
}
......@@ -62,6 +62,7 @@ class SupplierReceiptController extends Controller
$this->data['nationList'] = NationModel::pluck('name_cn','nation_id')->toArray();
$this->data['title'] = '修改供应商银行';
$this->data['view'] = 'AddSupplierReceipt';
$this->data['internationalCodeList'] = NationModel::getNationList();
return $this->view('修改供应商银行');
}
......
......@@ -29,6 +29,7 @@ use App\Model\SupplierAttachmentsModel;
use App\Model\StandardBrandMappingModel;
use App\Model\Purchase\PurchaseOrderModel;
use App\Http\Transformers\SupplierTransformer;
use App\Model\NationModel;
//这个服务是处理数据的,比如导出信息,或者临时修复数据,所以代码会比较多
class DataService
......@@ -807,4 +808,67 @@ class DataService
continue;
}
}
public static function repairNationInternationalCode()
{
//读取json文件
$filePath = public_path('data') . DIRECTORY_SEPARATOR . 'countries_list.json';
$json = file_get_contents($filePath);
$data = json_decode($json, true);
$nationList = NationModel::all()->toArray();
foreach ($nationList as $item) {
$nation = array_filter($data, function ($nation) use ($item) {
return $nation['cn'] == $item['name_cn'] || $nation['en'] == $item['name_en'];
});
$nation = array_values($nation);
if (empty($nation)) {
continue;
}
$nation = $nation[0];
NationModel::where('nation_id', $item['nation_id'])->update([
'nation_id' => $nation['abb2'],
]);
}
}
public static function initSupplierNationId()
{
ini_set('memory_limit', '2048M');
$supplierList = SupplierChannelModel::where('is_type', 0)->get()->toArray();
foreach ($supplierList as $supplier) {
$supplier['nation_id'] = 0;
switch ($supplier['region']) {
case 2:
$supplier['nation_id'] = 36;
break;
case 4:
$supplier['nation_id'] = 194;
break;
case 6:
$supplier['nation_id'] = 195;
break;
}
SupplierChannelModel::where('supplier_id', $supplier['supplier_id'])->update([
'nation_id' => $supplier['nation_id'],
]);
}
}
public static function initSupplierReceiptNationId()
{
ini_set('memory_limit', '2048M');
$supplierReceiptList = SupplierReceiptModel::where('ration_id', 0)->get()->toArray();
foreach ($supplierReceiptList as $supplierReceipt) {
$supplierReceipt['nation_id'] = 0;
$receiptType = $supplierReceipt['receipt_type'];
switch ($receiptType) {
case 1:
$supplierReceipt['nation_id'] = 36;
break;
}
SupplierReceiptModel::where('receipt_id', $supplierReceipt['receipt_id'])->update([
'nation_id' => $supplierReceipt['nation_id'],
]);
}
}
}
......@@ -30,7 +30,7 @@ class ReceiptValidator
$rules["bank_adderss"] = 'required';
$rules["nation_id"] = 'required';
$rules['account_no'] = 'required|alpha_num';
//$rules["international_code"] = 'required';
//$rules["nation_id"] = 'required';
}
$messages = $this->messages();
$validator = Validator::make($receipt, $rules, $messages);
......@@ -63,8 +63,7 @@ class ReceiptValidator
'account_name.required' => '账户名称 不能为空',
'certificate.required' => '银行信息凭证 不能为空',
'account_adderss.required' => '银行地址 不能为空',
'nation_id.required' => '银行国家 不能为空',
//'international_code.required' => '国际代码 不能为空',
'nation_id.required' => '国家/地区 不能为空',
];
}
}
......@@ -3,14 +3,14 @@
namespace App\Http\Validators;
use App\Http\Services\CompanyService;
use App\Http\Services\SupplierPayTypeService;
use App\Model\SupplierAttachmentsModel;
use Carbon\Carbon;
use App\Model\SupplierChannelModel;
use App\Model\SupplierContactModel;
use App\Model\SupplierReceiptModel;
use Carbon\Carbon;
use Validator;
use App\Http\Services\CompanyService;
use App\Model\SupplierAttachmentsModel;
use Illuminate\Support\Facades\Validator;
use App\Http\Services\SupplierPayTypeService;
class SupplierValidator
{
......@@ -35,9 +35,11 @@ class SupplierValidator
//新增的时候要先去检验下一体化的数据,如果是实体黑名单用户,那么就不允许新增
$regionType = $validateData['region'] == SupplierChannelModel::REGION_CN ? 1 : 2;
//还要校验提交上来的公司是否有合法信息
$unitedCompanyInfo = (new CompanyService())->getUnitedCompanyInfo($validateData['supplier_name'],
$unitedCompanyInfo = (new CompanyService())->getUnitedCompanyInfo(
$validateData['supplier_name'],
$validateData['tax_number'],
$regionType);
$regionType
);
$unitedInfo = $unitedCompanyInfo['united_company_info'];
if ($unitedInfo && $isAdd) {
if (isset($unitedCompanyInfo['is_entity']) && $unitedCompanyInfo['is_entity'] == 1) {
......@@ -126,6 +128,7 @@ class SupplierValidator
'us_ratio' => 'min:1',
'is_business_abnormal' => 'required',
'phone' => 'required',
'nation_id' => 'required',
];
//2022年6月30日(含)之前新建的供应商,在修改供应商信息时,可跳过“注册资金”这一必填项
if (!$isAdd) {
......@@ -151,8 +154,10 @@ class SupplierValidator
if (empty($validateData['supplier_type'])) {
return '请选择供应商类型';
}
if ($validateData['supplier_type'] == SupplierChannelModel::SUPPLIER_TYPE_TEMPORARY && in_array($validateData['supplier_name'],
config('field.SkipChangeSupplierTypeNames'))) {
if ($validateData['supplier_type'] == SupplierChannelModel::SUPPLIER_TYPE_TEMPORARY && in_array(
$validateData['supplier_name'],
config('field.SkipChangeSupplierTypeNames')
)) {
$errorMessageList[] = '该供应商是代购供应商,不能修改为临时供应商';
}
......@@ -169,10 +174,11 @@ class SupplierValidator
$errorMessageList[] = '附件中代理证的有效期为必填,请检查对应代理证的附件有效期';
}
}
} else {
$attachmentFields = SupplierAttachmentsModel::where('supplier_id',
$supplierId)->get()->pluck('field_name')->toArray();
$attachmentFields = SupplierAttachmentsModel::where(
'supplier_id',
$supplierId
)->get()->pluck('field_name')->toArray();
}
if (!$attachmentFields) {
......@@ -180,8 +186,10 @@ class SupplierValidator
} else {
$attachmentFields = array_unique($attachmentFields);
//fixed.php FileNameMapping 可以知道所有对应关系
if (!in_array('business_license', $attachmentFields)
&& $validateData['region'] == SupplierChannelModel::REGION_CN) {
if (
!in_array('business_license', $attachmentFields)
&& $validateData['region'] == SupplierChannelModel::REGION_CN
) {
$errorMessageList[] = '国内供应商必须上传营业执照';
}
......@@ -191,8 +199,10 @@ class SupplierValidator
}
}
if ($validateData['supplier_type'] == SupplierChannelModel::SUPPLIER_TYPE_OFFICIAL && !in_array($validateData['supplier_group'],
[SupplierChannelModel::SUPPLIER_GROUP_ORIGINAL, SupplierChannelModel::SUPPLIER_GROUP_PROXY])) {
if ($validateData['supplier_type'] == SupplierChannelModel::SUPPLIER_TYPE_OFFICIAL && !in_array(
$validateData['supplier_group'],
[SupplierChannelModel::SUPPLIER_GROUP_ORIGINAL, SupplierChannelModel::SUPPLIER_GROUP_PROXY]
)) {
if (!in_array('quality_assurance_agreement', $attachmentFields)) {
$errorMessageList[] = '供应商为正式供应商,品质保证协议必须上传 (代理商跟原厂类型除外) ';
}
......@@ -213,7 +223,6 @@ class SupplierValidator
}
//还有代理证的有效期为必填
if (!in_array('proxy_certificate', $attachmentFields)) {
}
}
......@@ -238,7 +247,6 @@ class SupplierValidator
}
}
}
}
......@@ -272,7 +280,6 @@ class SupplierValidator
}
}
}
}
......@@ -314,8 +321,10 @@ class SupplierValidator
$companyNameCount = 0;
if (empty($supplierId)) {
$count = SupplierChannelModel::where('supplier_name', $validateData['supplier_name'])->count();
$companyNameCount = SupplierChannelModel::where('register_company_name',
$validateData['register_company_name'])->where('register_company_name', '!=', '')->count();
$companyNameCount = SupplierChannelModel::where(
'register_company_name',
$validateData['register_company_name']
)->where('register_company_name', '!=', '')->count();
} else {
//对接一体化以后,名称不能修改了,所以直接为0
$count = 0;
......@@ -393,6 +402,7 @@ class SupplierValidator
'registered_capital.numeric' => '注册资金填纯数字即可,默认单位是万',
'is_business_abnormal.required' => '是否历史经营异常必选,请补充选择',
'sign_com_id.required' => '发生跨境交易时的合同签约公司 不能为空',
'nation_id.required' => '所在国家/地区 不能为空',
];
}
......
......@@ -90,5 +90,5 @@ Route::group(['middleware' => ['external'], 'namespace' => 'Sync'], function ()
});
Route::match(['get', 'post'], '/test', function () {
DataService::repairSupplierCpTime();
DataService::repairNationInternationalCode();
});
......@@ -10,4 +10,14 @@ class NationModel extends Model
protected $table='nation';
protected $primaryKey = 'nation_id';
public $timestamps = false;
public static function getNationList()
{
$natioList = self::all()->toArray();
$data = [];
foreach ($natioList as $item) {
$data[$item['nation_id']] = $item['name_cn'] . ' | ' . $item['international_code'];
}
return $data;
}
}
......@@ -60,5 +60,6 @@ return [
'sign_com_id' => '签约公司id',
'sign_com_name' => '签约公司名称',
'sku_optional_batch_text' => 'SKU可选批次',
'nation_id' => '国家/地区',
]
];
[{"cn":"阿富汗","en":"Afghanistan","full":"the Islamic Republic of Afghanistan","abb2":"AF","abb3":"AFG","code":"004"},{"cn":"奥兰群岛","en":"Aland Islands","full":"Aland Islands","abb2":"AX","abb3":"ALA","code":"248"},{"cn":"阿尔巴尼亚","en":"Albania","full":"the Republic of Albania","abb2":"AL","abb3":"ALB","code":"008"},{"cn":"阿尔及利亚","en":"Algeria","full":"the People's Democratic Republic of Algeria","abb2":"DZ","abb3":"DZA","code":"012"},{"cn":"美属萨摩亚","en":"American Samoa","full":"American Samoa","abb2":"AS","abb3":"ASM","code":"016"},{"cn":"安道尔","en":"Andorra","full":"the Principality of Andorra","abb2":"AD","abb3":"AND","code":"020"},{"cn":"安哥拉","en":"Angola","full":"the Republic of Angola","abb2":"AO","abb3":"AGO","code":"024"},{"cn":"安圭拉","en":"Anguilla","full":"Anguilla","abb2":"AI","abb3":"AIA","code":"660"},{"cn":"南极洲","en":"Antarctica","full":"Antarctica","abb2":"AQ","abb3":"ATA","code":"010"},{"cn":"安提瓜和巴布达","en":"Antigua and Barbuda","full":"Antigua and Barbuda","abb2":"AG","abb3":"ATG","code":"028"},{"cn":"阿根廷","en":"Argentina","full":"the Argentine Republic","abb2":"AR","abb3":"ARG","code":"032"},{"cn":"亚美尼亚","en":"Armenia","full":"the Republic of Armenia","abb2":"AM","abb3":"ARM","code":"051"},{"cn":"阿鲁巴","en":"Aruba","full":"Aruba","abb2":"AW","abb3":"ABW","code":"533"},{"cn":"澳大利亚","en":"Australia","full":"Australia","abb2":"AU","abb3":"AUS","code":"036"},{"cn":"奥地利","en":"Austria","full":"the Republic of Austria","abb2":"AT","abb3":"AUT","code":"040"},{"cn":"阿塞拜疆","en":"Azerbaijan","full":"the Republic of Azerbaijan","abb2":"AZ","abb3":"AZE","code":"031"},{"cn":"巴哈马","en":"Bahamas","full":"the Commonwealth of The Bahamas","abb2":"BS","abb3":"BHS","code":"044"},{"cn":"巴林","en":"Bahrain","full":"the Kingdom of Bahrain","abb2":"BH","abb3":"BHR","code":"048"},{"cn":"孟加拉国","en":"Bangladesh","full":"the People's Republic of Bangladesh","abb2":"BD","abb3":"BGD","code":"050"},{"cn":"巴巴多斯","en":"Barbados","full":"Barbados","abb2":"BB","abb3":"BRB","code":"052"},{"cn":"白俄罗斯","en":"Belarus","full":"the Republic of Belarus","abb2":"BY","abb3":"BLR","code":"112"},{"cn":"比利时","en":"Belgium","full":"the Kingdom of Belgium","abb2":"BE","abb3":"BEL","code":"056"},{"cn":"伯利兹","en":"Belize","full":"Belize","abb2":"BZ","abb3":"BLZ","code":"084"},{"cn":"贝宁","en":"Benin","full":"the Republic of Benin","abb2":"BJ","abb3":"BEN","code":"204"},{"cn":"百慕大","en":"Bermuda","full":"Bermuda","abb2":"BM","abb3":"BMU","code":"060"},{"cn":"不丹","en":"Bhutan","full":"the Kingdom of Bhutan","abb2":"BT","abb3":"BTN","code":"064"},{"cn":"玻利维亚","en":"Bolivia","full":"the Republic of Bolivia","abb2":"BO","abb3":"BOL","code":"068"},{"cn":"波黑","en":"Bosnia and Herzegovina","full":"Bosnia and Herzegovina","abb2":"BA","abb3":"BIH","code":"070"},{"cn":"博茨瓦纳","en":"Botswana","full":"the Republic of Botswana","abb2":"BW","abb3":"BWA","code":"072"},{"cn":"布维岛","en":"Bouvet Island","full":"Bouvet Island","abb2":"BV","abb3":"BVT","code":"074"},{"cn":"巴西","en":"Brazil","full":"the Federative Republic of Brazil","abb2":"BR","abb3":"BRA","code":"076"},{"cn":"英属印度洋领地","en":"British Indian Ocean Territory","full":"British Indian Ocean Territory","abb2":"IO","abb3":"IOT","code":"086"},{"cn":"文莱","en":"Brunei Darussalam","full":"Brunei Darussalam","abb2":"BN","abb3":"BRN","code":"096"},{"cn":"保加利亚","en":"Bulgaria","full":"the Republic of Bulgaria","abb2":"BG","abb3":"BGR","code":"100"},{"cn":"布基纳法索","en":"Burkina Faso","full":"Burkina Faso","abb2":"BF","abb3":"BFA","code":"854"},{"cn":"布隆迪","en":"Burundi","full":"the Republic of Burundi","abb2":"BI","abb3":"BDI","code":"108"},{"cn":"柬埔寨","en":"Cambodia","full":"the Kingdom of Cambodia","abb2":"KH","abb3":"KHM","code":"116"},{"cn":"喀麦隆","en":"Cameroon","full":"the Republic of Cameroon","abb2":"CM","abb3":"CMR","code":"120"},{"cn":"加拿大","en":"Canada","full":"Canada","abb2":"CA","abb3":"CAN","code":"124"},{"cn":"佛得角","en":"Cape Verde","full":"the Republic of Cape Verde","abb2":"CV","abb3":"CPV","code":"132"},{"cn":"开曼群岛","en":"Cayman Islands","full":"Cayman Islands","abb2":"KY","abb3":"CYM","code":"136"},{"cn":"中非","en":"Central African Republic","full":"the Central African Republic","abb2":"CF","abb3":"CAF","code":"140"},{"cn":"乍得","en":"Chad","full":"the Republic of Chad","abb2":"TD","abb3":"TCD","code":"148"},{"cn":"智利","en":"Chile","full":"the Republic of Chile","abb2":"CL","abb3":"CHL","code":"152"},{"cn":"中国","en":"China","full":"the People's Republic of China","abb2":"CN","abb3":"CHN","code":"156"},{"cn":"圣诞岛","en":"Christmas Island","full":"Christmas Island","abb2":"CX","abb3":"CXR","code":"162"},{"cn":"科科斯(基林)群岛","en":"Cocos (Keeling) Islands","full":"Cocos (Keeling) Islands","abb2":"CC","abb3":"CCK","code":"166"},{"cn":"哥伦比亚","en":"Colombia","full":"the Republic of Colombia","abb2":"CO","abb3":"COL","code":"170"},{"cn":"科摩罗","en":"Comoros","full":"the Union of the Comoros","abb2":"KM","abb3":"COM","code":"174"},{"cn":"刚果(布)","en":"Congo","full":"the Republic of the Congo","abb2":"CG","abb3":"COG","code":"178"},{"cn":"刚果(金)","en":"Congo (the Democratic Republic of the)","full":"the Democratic Republic of the Congo","abb2":"CD","abb3":"COD","code":"180"},{"cn":"库克群岛","en":"Cook Islands","full":"Cook Islands","abb2":"CK","abb3":"COK","code":"184"},{"cn":"哥斯达黎加","en":"Costa Rica","full":"the Republic of Costa Rica","abb2":"CR","abb3":"CRI","code":"188"},{"cn":"科特迪瓦","en":"Côte d'Ivoire","full":"the Republic of Côte d'Ivoire","abb2":"CI","abb3":"CIV","code":"384"},{"cn":"克罗地亚","en":"Croatia","full":"the Republic of Croatia","abb2":"HR","abb3":"HRV","code":"191"},{"cn":"古巴","en":"Cuba","full":"the Republic of Cuba","abb2":"CU","abb3":"CUB","code":"192"},{"cn":"塞浦路斯","en":"Cyprus","full":"the Republic of Cyprus","abb2":"CY","abb3":"CYP","code":"196"},{"cn":"捷克","en":"Czech Republic","full":"the Czech Republic","abb2":"CZ","abb3":"CZE","code":"203"},{"cn":"丹麦","en":"Denmark","full":"the Kingdom of Denmark","abb2":"DK","abb3":"DNK","code":"208"},{"cn":"吉布提","en":"Djibouti","full":"the Republic of Djibouti","abb2":"DJ","abb3":"DJI","code":"262"},{"cn":"多米尼克","en":"Dominica","full":"the Commonwealth of Dominica","abb2":"DM","abb3":"DMA","code":"212"},{"cn":"多米尼加","en":"Dominican Republic","full":"the Dominican Republic","abb2":"DO","abb3":"DOM","code":"214"},{"cn":"厄瓜多尔","en":"Ecuador","full":"the Republic of Ecuador","abb2":"EC","abb3":"ECU","code":"218"},{"cn":"埃及","en":"Egypt","full":"the Arab Republic of Egypt","abb2":"EG","abb3":"EGY","code":"818"},{"cn":"萨尔瓦多","en":"El Salvador","full":"the Republic of El Salvador","abb2":"SV","abb3":"SLV","code":"222"},{"cn":"赤道几内亚","en":"Equatorial Guinea","full":"the Republic of Equatorial Guinea","abb2":"GQ","abb3":"GNQ","code":"226"},{"cn":"厄立特里亚","en":"Eritrea","full":"Eritrea","abb2":"ER","abb3":"ERI","code":"232"},{"cn":"爱沙尼亚","en":"Estonia","full":"the Republic of Estonia","abb2":"EE","abb3":"EST","code":"233"},{"cn":"埃塞俄比亚","en":"Ethiopia","full":"the Federal Democratic Republic of Ethiopia","abb2":"ET","abb3":"ETH","code":"231"},{"cn":"福克兰群岛(马尔维纳斯)","en":"Falkland Islands [Malvinas]","full":"Falkland Islands [Malvinas]","abb2":"FK","abb3":"FLK","code":"238"},{"cn":"法罗群岛","en":"Faroe Islands","full":"Faroe Islands","abb2":"FO","abb3":"FRO","code":"234"},{"cn":"斐济","en":"Fiji","full":"the Republic of the Fiji Islands","abb2":"FJ","abb3":"FJI","code":"242"},{"cn":"芬兰","en":"Finland","full":"the Republic of Finland","abb2":"FI","abb3":"FIN","code":"246"},{"cn":"法国","en":"France","full":"the French Republic","abb2":"FR","abb3":"FRA","code":"250"},{"cn":"法属圭亚那","en":"French Guiana","full":"French Guiana","abb2":"GF","abb3":"GUF","code":"254"},{"cn":"法属波利尼西亚","en":"French Polynesia","full":"French Polynesia","abb2":"PF","abb3":"PYF","code":"258"},{"cn":"法属南部领地","en":"French Southern Territories","full":"French Southern Territories","abb2":"TF","abb3":"ATF","code":"260"},{"cn":"加蓬","en":"Gabon","full":"the Gabonese Republic","abb2":"GA","abb3":"GAB","code":"266"},{"cn":"冈比亚","en":"Gambia","full":"the Republic of The Gambia","abb2":"GM","abb3":"GMB","code":"270"},{"cn":"格鲁吉亚","en":"Georgia","full":"Georgia","abb2":"GE","abb3":"GEO","code":"268"},{"cn":"德国","en":"Germany","full":"he Federal Republic of Germany","abb2":"DE","abb3":"DEU","code":"276"},{"cn":"加纳","en":"Ghana","full":"the Republic of Ghana","abb2":"GH","abb3":"GHA","code":"288"},{"cn":"直布罗陀","en":"Gibraltar","full":"Gibraltar","abb2":"GI","abb3":"GIB","code":"292"},{"cn":"希腊","en":"Greece","full":"the Hellenic Republic","abb2":"GR","abb3":"GRC","code":"300"},{"cn":"格陵兰","en":"Greenland","full":"Greenland","abb2":"GL","abb3":"GRL","code":"304"},{"cn":"格林纳达","en":"Grenada","full":"Grenada","abb2":"GD","abb3":"GRD","code":"308"},{"cn":"瓜德罗普","en":"Guadeloupe","full":"Guadeloupe","abb2":"GP","abb3":"GLP","code":"312"},{"cn":"关岛","en":"Guam","full":"Guam","abb2":"GU","abb3":"GUM","code":"316"},{"cn":"危地马拉","en":"Guatemala","full":"the Republic of Guatemala","abb2":"GT","abb3":"GTM","code":"320"},{"cn":"格恩西岛","en":"Guernsey","full":"Guernsey","abb2":"GG","abb3":"GGY","code":"831"},{"cn":"几内亚","en":"Guinea","full":"the Republic of Guinea","abb2":"GN","abb3":"GIN","code":"324"},{"cn":"几内亚比绍","en":"Guinea-Bissau","full":"the Republic of Guinea-Bissau","abb2":"GW","abb3":"GNB","code":"624"},{"cn":"圭亚那","en":"Guyana","full":"the Republic of Guyana","abb2":"GY","abb3":"GUY","code":"328"},{"cn":"海地","en":"Haiti","full":"the Republic of Haiti","abb2":"HT","abb3":"HTI","code":"332"},{"cn":"赫德岛和麦克唐纳岛","en":"Heard Island and McDonald Islands","full":"Heard Island and McDonald Islands","abb2":"HM","abb3":"HMD","code":"334"},{"cn":"梵蒂冈","en":"Holy See [Vatican City State]","full":"Holy See [Vatican City State]","abb2":"VA","abb3":"VAT","code":"336"},{"cn":"洪都拉斯","en":"Honduras","full":"the Republic of Honduras","abb2":"HN","abb3":"HND","code":"340"},{"cn":"香港 (中国)","en":"Hong Kong (China)","full":"the Hong Kong (China) Special Administrative Region of China","abb2":"HK","abb3":"HKG","code":"344"},{"cn":"匈牙利","en":"Hungary","full":"the Republic of Hungary","abb2":"HU","abb3":"HUN","code":"348"},{"cn":"冰岛","en":"Iceland","full":"the Republic of Iceland","abb2":"IS","abb3":"ISL","code":"352"},{"cn":"印度","en":"India","full":"the Republic of India","abb2":"IN","abb3":"IND","code":"356"},{"cn":"印度尼西亚","en":"Indonesia","full":"the Republic of Indonesia","abb2":"ID","abb3":"IDN","code":"360"},{"cn":"伊朗","en":"Iran (the Islamic Republic of)","full":"the Islamic Republic of Iran","abb2":"IR","abb3":"IRN","code":"364"},{"cn":"伊拉克","en":"Iraq","full":"the Republic of Iraq","abb2":"IQ","abb3":"IRQ","code":"368"},{"cn":"爱尔兰","en":"Ireland","full":"Ireland","abb2":"IE","abb3":"IRL","code":"372"},{"cn":"英国属地曼岛","en":"Isle of Man","full":"Isle of Man","abb2":"IM","abb3":"IMN","code":"833"},{"cn":"以色列","en":"Israel","full":"the State of Israel","abb2":"IL","abb3":"ISR","code":"376"},{"cn":"意大利","en":"Italy","full":"the Republic of Italy","abb2":"IT","abb3":"ITA","code":"380"},{"cn":"牙买加","en":"Jamaica","full":"Jamaica","abb2":"JM","abb3":"JAM","code":"388"},{"cn":"日本","en":"Japan","full":"Japan","abb2":"JP","abb3":"JPN","code":"392"},{"cn":"泽西岛","en":"Jersey","full":"Jersey","abb2":"JE","abb3":"JEY","code":"832"},{"cn":"约旦","en":"Jordan","full":"the Hashemite Kingdom of Jordan","abb2":"JO","abb3":"JOR","code":"400"},{"cn":"哈萨克斯坦","en":"Kazakhstan","full":"the Republic of Kazakhstan","abb2":"KZ","abb3":"KAZ","code":"398"},{"cn":"肯尼亚","en":"Kenya","full":"the Republic of Kenya","abb2":"KE","abb3":"KEN","code":"404"},{"cn":"基里巴斯","en":"Kiribati","full":"the Republic of Kiribati","abb2":"KI","abb3":"KIR","code":"296"},{"cn":"朝鲜","en":"Korea (the Democratic People's Republic of)","full":"the Democratic People's Republic of Korea","abb2":"KP","abb3":"PRK","code":"408"},{"cn":"韩国","en":"Korea (the Republic of)","full":"the Republic of Korea","abb2":"KR","abb3":"KOR","code":"410"},{"cn":"科威特","en":"Kuwait","full":"he State of Kuwait","abb2":"KW","abb3":"KWT","code":"414"},{"cn":"吉尔吉斯斯坦","en":"Kyrgyzstan","full":"the Kyrgyz Republic","abb2":"KG","abb3":"KGZ","code":"417"},{"cn":"老挝","en":"Lao People's Democratic Republic","full":"the Lao People's Democratic Republic","abb2":"LA","abb3":"LAO","code":"418"},{"cn":"拉脱维亚","en":"Latvia","full":"the Republic of Latvia","abb2":"LV","abb3":"LVA","code":"428"},{"cn":"黎巴嫩","en":"Lebanon","full":"the Lebanese Republic","abb2":"LB","abb3":"LBN","code":"422"},{"cn":"莱索托","en":"Lesotho","full":"the Kingdom of Lesotho","abb2":"LS","abb3":"LSO","code":"426"},{"cn":"利比里亚","en":"Liberia","full":"the Republic of Liberia","abb2":"LR","abb3":"LBR","code":"430"},{"cn":"利比亚","en":"Libyan Arab Jamahiriya","full":"the Socialist People's Libyan Arab Jamahiriya","abb2":"LY","abb3":"LBY","code":"434"},{"cn":"列支敦士登","en":"Liechtenstein","full":"the Principality of Liechtenstein","abb2":"LI","abb3":"LIE","code":"438"},{"cn":"立陶宛","en":"Lithuania","full":"the Republic of Lithuania","abb2":"LT","abb3":"LTU","code":"440"},{"cn":"卢森堡","en":"Luxembourg","full":"the Grand Duchy of Luxembourg","abb2":"LU","abb3":"LUX","code":"442"},{"cn":"澳门","en":"Macao","full":"Macao Special Administrative Region of China","abb2":"MO","abb3":"MAC","code":"446"},{"cn":"前南马其顿","en":"Macedonia (the former Yugoslav Republic of)","full":"the former Yugoslav Republic of Macedonia","abb2":"MK","abb3":"MKD","code":"807"},{"cn":"马达加斯加","en":"Madagascar","full":"the Republic of Madagascar","abb2":"MG","abb3":"MDG","code":"450"},{"cn":"马拉维","en":"Malawi","full":"the Republic of Malawi","abb2":"MW","abb3":"MWI","code":"454"},{"cn":"马来西亚","en":"Malaysia","full":"Malaysia","abb2":"MY","abb3":"MYS","code":"458"},{"cn":"马尔代夫","en":"Maldives","full":"the Republic of Maldives","abb2":"MV","abb3":"MDV","code":"462"},{"cn":"马里","en":"Mali","full":"the Republic of Mali","abb2":"ML","abb3":"MLI","code":"466"},{"cn":"马耳他","en":"Malta","full":"the Republic of Malta","abb2":"MT","abb3":"MLT","code":"470"},{"cn":"马绍尔群岛","en":"Marshall Islands","full":"the Republic of the Marshall Islands","abb2":"MH","abb3":"MHL","code":"584"},{"cn":"马提尼克","en":"Martinique","full":"Martinique","abb2":"MQ","abb3":"MTQ","code":"474"},{"cn":"毛利塔尼亚","en":"Mauritania","full":"the Islamic Republic of Mauritania","abb2":"MR","abb3":"MRT","code":"478"},{"cn":"毛里求斯","en":"Mauritius","full":"the Republic of Mauritius","abb2":"MU","abb3":"MUS","code":"480"},{"cn":"马约特","en":"Mayotte","full":"Mayotte","abb2":"YT","abb3":"MYT","code":"175"},{"cn":"墨西哥","en":"Mexico","full":"the United Mexican States","abb2":"MX","abb3":"MEX","code":"484"},{"cn":"密克罗尼西亚联邦","en":"Micronesia (the Federated States of)","full":"the Federated States of Micronesia","abb2":"FM","abb3":"FSM","code":"583"},{"cn":"摩尔多瓦","en":"Moldova (the Republic of)","full":"the Republic of Moldova","abb2":"MD","abb3":"MDA","code":"498"},{"cn":"摩纳哥","en":"Monaco","full":"the Principality of Monaco","abb2":"MC","abb3":"MCO","code":"492"},{"cn":"蒙古","en":"Mongolia","full":"Mongolia","abb2":"MN","abb3":"MNG","code":"496"},{"cn":"黑山","en":"Montenegro","full":"he Republic of Montenegro","abb2":"ME","abb3":"MNE","code":"499"},{"cn":"蒙特塞拉特","en":"Montserrat","full":"Montserrat","abb2":"MS","abb3":"MSR","code":"500"},{"cn":"摩洛哥","en":"Morocco","full":"the Kingdom of Morocco","abb2":"MA","abb3":"MAR","code":"504"},{"cn":"莫桑比克","en":"Mozambique","full":"the Republic of Mozambique","abb2":"MZ","abb3":"MOZ","code":"508"},{"cn":"缅甸","en":"Myanmar","full":"the Union of Myanmar","abb2":"MM","abb3":"MMR","code":"104"},{"cn":"纳米比亚","en":"Namibia","full":"the Republic of Namibia","abb2":"NA","abb3":"NAM","code":"516"},{"cn":"瑙鲁","en":"Nauru","full":"the Republic of Nauru","abb2":"NR","abb3":"NRU","code":"520"},{"cn":"尼泊尔","en":"Nepal","full":"Nepal","abb2":"NP","abb3":"NPL","code":"524"},{"cn":"荷兰","en":"Netherlands","full":"the Kingdom of the Netherlands","abb2":"NL","abb3":"NLD","code":"528"},{"cn":"荷属安的列斯","en":"Netherlands Antilles","full":"Netherlands Antilles","abb2":"AN","abb3":"ANT","code":"530"},{"cn":"新喀里多尼亚","en":"New Caledonia","full":"New Caledonia","abb2":"NC","abb3":"NCL","code":"540"},{"cn":"新西兰","en":"New Zealand","full":"New Zealand","abb2":"NZ","abb3":"NZL","code":"554"},{"cn":"尼加拉瓜","en":"Nicaragua","full":"the Republic of Nicaragua","abb2":"NI","abb3":"NIC","code":"558"},{"cn":"尼日尔","en":"Niger","full":"the Republic of the Niger","abb2":"NE","abb3":"NER","code":"562"},{"cn":"尼日利亚","en":"Nigeria","full":"the Federal Republic of Nigeria","abb2":"NG","abb3":"NGA","code":"566"},{"cn":"纽埃","en":"Niue","full":"the Republic of Niue","abb2":"NU","abb3":"NIU","code":"570"},{"cn":"诺福克岛","en":"Norfolk Island","full":"Norfolk Island","abb2":"NF","abb3":"NFK","code":"574"},{"cn":"北马里亚纳","en":"Northern Mariana Islands","full":"the Commonwealth of the Northern Mariana Islands","abb2":"MP","abb3":"MNP","code":"580"},{"cn":"挪威","en":"Norway","full":"the Kingdom of Norway","abb2":"NO","abb3":"NOR","code":"578"},{"cn":"阿曼","en":"Oman","full":"the Sultanate of Oman","abb2":"OM","abb3":"OMN","code":"512"},{"cn":"巴基斯坦","en":"Pakistan","full":"the Islamic Republic of Pakistan","abb2":"PK","abb3":"PAK","code":"586"},{"cn":"帕劳","en":"Palau","full":"the Republic of Palau","abb2":"PW","abb3":"PLW","code":"585"},{"cn":"巴勒斯坦","en":"Palestinian Territory (the Occupied)","full":"the Occupied Palestinian Territory","abb2":"PS","abb3":"PSE","code":"275"},{"cn":"巴拿马","en":"Panama","full":"the Republic of Panama","abb2":"PA","abb3":"PAN","code":"591"},{"cn":"巴布亚新几内亚","en":"Papua New Guinea","full":"Papua New Guinea","abb2":"PG","abb3":"PNG","code":"598"},{"cn":"巴拉圭","en":"Paraguay","full":"the Republic of Paraguay","abb2":"PY","abb3":"PRY","code":"600"},{"cn":"秘鲁","en":"Peru","full":"the Republic of Peru","abb2":"PE","abb3":"PER","code":"604"},{"cn":"菲律宾","en":"Philippines","full":"the Republic of the Philippines","abb2":"PH","abb3":"PHL","code":"608"},{"cn":"皮特凯恩","en":"Pitcairn","full":"Pitcairn","abb2":"PN","abb3":"PCN","code":"612"},{"cn":"波兰","en":"Poland","full":"the Republic of Poland","abb2":"PL","abb3":"POL","code":"616"},{"cn":"葡萄牙","en":"Portugal","full":"the Portuguese Republic","abb2":"PT","abb3":"PRT","code":"620"},{"cn":"波多黎各","en":"Puerto Rico","full":"Puerto Rico","abb2":"PR","abb3":"PRI","code":"630"},{"cn":"卡塔尔","en":"Qatar","full":"the State of Qatar","abb2":"QA","abb3":"QAT","code":"634"},{"cn":"留尼汪","en":"Réunion","full":"Réunion","abb2":"RE","abb3":"REU","code":"638"},{"cn":"罗马尼亚","en":"Romania","full":"Romania","abb2":"RO","abb3":"ROU","code":"642"},{"cn":"俄罗斯联邦","en":"Russian Federation","full":"the Russian Federation","abb2":"RU","abb3":"RUS","code":"643"},{"cn":"卢旺达","en":"Rwanda","full":"the Republic of Rwanda","abb2":"RW","abb3":"RWA","code":"646"},{"cn":"圣赫勒拿","en":"Saint Helena","full":"Saint Helena","abb2":"SH","abb3":"SHN","code":"654"},{"cn":"圣基茨和尼维斯","en":"Saint Kitts and Nevis","full":"Saint Kitts and Nevis","abb2":"KN","abb3":"KNA","code":"659"},{"cn":"圣卢西亚","en":"Saint Lucia","full":"Saint Lucia","abb2":"LC","abb3":"LCA","code":"662"},{"cn":"圣皮埃尔和密克隆","en":"Saint Pierre and Miquelon","full":"Saint Pierre and Miquelon","abb2":"PM","abb3":"SPM","code":"666"},{"cn":"圣文森特和格林纳丁斯","en":"Saint Vincent and the Grenadines","full":"Saint Vincent and the Grenadines","abb2":"VC","abb3":"VCT","code":"670"},{"cn":"萨摩亚","en":"Samoa","full":"the Independent State of Samoa","abb2":"WS","abb3":"WSM","code":"882"},{"cn":"圣马力诺","en":"San Marino","full":"the Republic of San Marino","abb2":"SM","abb3":"SMR","code":"674"},{"cn":"圣多美和普林西比","en":"Sao Tome and Principe","full":"the Democratic Republic of Sao Tome and Principe","abb2":"ST","abb3":"STP","code":"678"},{"cn":"沙特阿拉伯","en":"Saudi Arabia","full":"the Kingdom of Saudi Arabia","abb2":"SA","abb3":"SAU","code":"682"},{"cn":"塞内加尔","en":"Senegal","full":"the Republic of Senegal","abb2":"SN","abb3":"SEN","code":"686"},{"cn":"塞尔维亚","en":"Serbia","full":"the Republic of Serbia","abb2":"RS","abb3":"SRB","code":"688"},{"cn":"塞舌尔","en":"Seychelles","full":"the Republic of Seychelles","abb2":"SC","abb3":"SYC","code":"690"},{"cn":"塞拉利昂","en":"Sierra Leone","full":"the Republic of Sierra Leone","abb2":"SL","abb3":"SLE","code":"694"},{"cn":"新加坡","en":"Singapore","full":"the Republic of Singapore","abb2":"SG","abb3":"SGP","code":"702"},{"cn":"斯洛伐克","en":"Slovakia","full":"the Slovak Republic","abb2":"SK","abb3":"SVK","code":"703"},{"cn":"斯洛文尼亚","en":"Slovenia","full":"the Republic of Slovenia","abb2":"SI","abb3":"SVN","code":"705"},{"cn":"所罗门群岛","en":"Solomon Islands","full":"Solomon Islands","abb2":"SB","abb3":"SLB","code":"090"},{"cn":"索马里","en":"Somalia","full":"the Somali Republic","abb2":"SO","abb3":"SOM","code":"706"},{"cn":"南非","en":"South Africa","full":"the Republic of South Africa","abb2":"ZA","abb3":"ZAF","code":"710"},{"cn":"南乔治亚岛和南桑德韦奇岛","en":"South Georgia and the South Sandwich Islands","full":"South Georgia and the South Sandwich Islands","abb2":"GS","abb3":"SGS","code":"239"},{"cn":"西班牙","en":"Spain","full":"the Kingdom of Spain","abb2":"ES","abb3":"ESP","code":"724"},{"cn":"斯里兰卡","en":"Sri Lanka","full":"the Democratic Socialist Republic of Sri Lanka","abb2":"LK","abb3":"LKA","code":"144"},{"cn":"苏丹","en":"Sudan","full":"the Republic of the Sudan","abb2":"SD","abb3":"SDN","code":"736"},{"cn":"苏里南","en":"Suriname","full":"the Republic of Suriname","abb2":"SR","abb3":"SUR","code":"740"},{"cn":"斯瓦尔巴岛和扬马延岛","en":"Svalbard and Jan Mayen","full":"Svalbard and Jan Mayen","abb2":"SJ","abb3":"SJM","code":"744"},{"cn":"斯威士兰","en":"Swaziland","full":"the Kingdom of Swaziland","abb2":"SZ","abb3":"SWZ","code":"748"},{"cn":"瑞典","en":"Sweden","full":"the Kingdom of Sweden","abb2":"SE","abb3":"SWE","code":"752"},{"cn":"瑞士","en":"Switzerland","full":"the Swiss Confederation","abb2":"CH","abb3":"CHE","code":"756"},{"cn":"叙利亚","en":"Syrian Arab Republic","full":"the Syrian Arab Republic","abb2":"SY","abb3":"SYR","code":"760"},{"cn":"台湾","en":"Taiwan (Province of China)","full":"Taiwan (Province of China)","abb2":"TW","abb3":"TWN","code":"158"},{"cn":"塔吉克斯坦","en":"Tajikistan","full":"the Republic of Tajikistan","abb2":"TJ","abb3":"TJK","code":"762"},{"cn":"坦桑尼亚","en":"Tanzania,United Republic of","full":"the United Republic of Tanzania","abb2":"TZ","abb3":"TZA","code":"834"},{"cn":"泰国","en":"Thailand","full":"the Kingdom of Thailand","abb2":"TH","abb3":"THA","code":"764"},{"cn":"东帝汶","en":"Timor-Leste","full":"the Democratic Republic of Timor-Leste","abb2":"TL","abb3":"TLS","code":"626"},{"cn":"多哥","en":"Togo","full":"the Togolese Republic","abb2":"TG","abb3":"TGO","code":"768"},{"cn":"托克劳","en":"Tokelau","full":"Tokelau","abb2":"TK","abb3":"TKL","code":"772"},{"cn":"汤加","en":"Tonga","full":"the Kingdom of Tonga","abb2":"TO","abb3":"TON","code":"776"},{"cn":"特立尼达和多巴哥","en":"Trinidad and Tobago","full":"the Republic of Trinidad and Tobago","abb2":"TT","abb3":"TTO","code":"780"},{"cn":"突尼斯","en":"Tunisia","full":"the Republic of Tunisia","abb2":"TN","abb3":"TUN","code":"788"},{"cn":"土耳其","en":"Turkey","full":"the Republic of Turkey","abb2":"TR","abb3":"TUR","code":"792"},{"cn":"土库曼斯坦","en":"Turkmenistan","full":"Turkmenistan","abb2":"TM","abb3":"TKM","code":"795"},{"cn":"特克斯和凯科斯群岛","en":"Turks and Caicos Islands","full":"Turks and Caicos Islands","abb2":"TC","abb3":"TCA","code":"796"},{"cn":"图瓦卢","en":"Tuvalu","full":"Tuvalu","abb2":"TV","abb3":"TUV","code":"798"},{"cn":"乌干达","en":"Uganda","full":"the Republic of Uganda","abb2":"UG","abb3":"UGA","code":"800"},{"cn":"乌克兰","en":"Ukraine","full":"Ukraine","abb2":"UA","abb3":"UKR","code":"804"},{"cn":"阿联酋","en":"United Arab Emirates","full":"the United Arab Emirates","abb2":"AE","abb3":"ARE","code":"784"},{"cn":"英国","en":"United Kingdom","full":"the United Kingdom of Great Britain and Northern Ireland","abb2":"GB","abb3":"GBR","code":"826"},{"cn":"美国","en":"United States","full":"the United States of America","abb2":"US","abb3":"USA","code":"840"},{"cn":"美国本土外小岛屿","en":"United States Minor Outlying Islands","full":"United States Minor Outlying Islands","abb2":"UM","abb3":"UMI","code":"581"},{"cn":"乌拉圭","en":"Uruguay","full":"the Eastern Republic of Uruguay","abb2":"UY","abb3":"URY","code":"858"},{"cn":"乌兹别克斯坦","en":"Uzbekistan","full":"the Republic of Uzbekistan","abb2":"UZ","abb3":"UZB","code":"860"},{"cn":"瓦努阿图","en":"Vanuatu","full":"the Republic of Vanuatu","abb2":"VU","abb3":"VUT","code":"548"},{"cn":"委内瑞拉","en":"Venezuela","full":"the Bolivarian Republic of Venezuela","abb2":"VE","abb3":"VEN","code":"862"},{"cn":"越南","en":"Viet Nam","full":"the Socialist Republic of Viet Nam","abb2":"VN","abb3":"VNM","code":"704"},{"cn":"英属维尔京群岛","en":"Virgin Islands (British)","full":"British Virgin Islands","abb2":"VG","abb3":"VGB","code":"092"},{"cn":"美属维尔京群岛","en":"Virgin Islands (U.S.)","full":"the Virgin Islands of the United States","abb2":"VI","abb3":"VIR","code":"850"},{"cn":"瓦利斯和富图纳","en":"Wallis and Futuna","full":"Wallis and Futuna Islands","abb2":"WF","abb3":"WLF","code":"876"},{"cn":"西撒哈拉","en":"Western Sahara","full":"Western Sahara","abb2":"EH","abb3":"ESH","code":"732"},{"cn":"也门","en":"Yemen","full":"the Republic of Yemen","abb2":"YE","abb3":"YEM","code":"887"},{"cn":"赞比亚","en":"Zambia","full":"the Republic of Zambia","abb2":"ZM","abb3":"ZMB","code":"894"},{"cn":"津巴布韦","en":"Zimbabwe","full":"the Republic of Zimbabwe","abb2":"ZW","abb3":"ZWE","code":"716"}]
\ No newline at end of file
[
{
"en": "Afghanistan",
"cn": "阿富汗",
"code": "+93"
},
{
"en": "Alaska(U.S.A)",
"cn": "阿拉斯加",
"code": "+1907"
},
{
"en": "Albania",
"cn": "阿尔巴尼亚",
"code": "+355"
},
{
"en": "Algeria",
"cn": "阿尔及利亚",
"code": "+213"
},
{
"en": "American Samoa",
"cn": "美属萨摩亚",
"code": "+684"
},
{
"en": "Andorra",
"cn": "安道尔共和国",
"code": "+376"
},
{
"en": "Angola",
"cn": "安哥拉",
"code": "+244"
},
{
"en": "Anguilla",
"cn": "安圭拉岛",
"code": "+1254"
},
{
"en": "Antigua and Barbuda",
"cn": "安提瓜和巴布达",
"code": "+1268"
},
{
"en": "Argentina",
"cn": "阿根廷",
"code": "+54"
},
{
"en": "Armenia",
"cn": "亚美尼亚",
"code": "+374"
},
{
"en": "Aruba",
"cn": "阿鲁巴岛",
"code": "+297"
},
{
"en": "Ascension",
"cn": "阿森松",
"code": "+247"
},
{
"en": "Australia",
"cn": "澳大利亚",
"code": "+61"
},
{
"en": "Austria",
"cn": "奥地利",
"code": "+43"
},
{
"en": "Azerbaijan",
"cn": "阿塞拜疆",
"code": "+994"
},
{
"en": "Bahamas",
"cn": "巴哈马",
"code": "+1242"
},
{
"en": "Bahrain",
"cn": "巴林",
"code": "+973"
},
{
"en": "Bangladesh",
"cn": "孟加拉国",
"code": "+880"
},
{
"en": "Barbados",
"cn": "巴巴多斯",
"code": "+1246"
},
{
"en": "Belarus",
"cn": "白俄罗斯",
"code": "+375"
},
{
"en": "Belgium",
"cn": "比利时",
"code": "+32"
},
{
"en": "Belize",
"cn": "伯利兹",
"code": "+501"
},
{
"en": "Benin",
"cn": "贝宁",
"code": "+229"
},
{
"en": "Bermuda Is",
"cn": "百慕大群岛",
"code": "+1441"
},
{
"en": "Bhutan",
"cn": "不丹",
"code": "+975"
},
{
"en": "Bolivia",
"cn": "玻利维亚",
"code": "+591"
},
{
"en": "Bosnia And Herzegovina",
"cn": "波斯尼亚和黑塞哥维那",
"code": "+387"
},
{
"en": "Botswana",
"cn": "博茨瓦纳",
"code": "+267"
},
{
"en": "Brazil",
"cn": "巴西",
"code": "+55"
},
{
"en": "Brunei",
"cn": "文莱",
"code": "+673"
},
{
"en": "Bulgaria",
"cn": "保加利亚",
"code": "+359"
},
{
"en": "Burkina Faso",
"cn": "布基纳法索",
"code": "+226"
},
{
"en": "Burma",
"cn": "缅甸",
"code": "+95"
},
{
"en": "Burundi",
"cn": "布隆迪",
"code": "+257"
},
{
"en": "Cambodia",
"cn": "柬埔寨",
"code": "+855"
},
{
"en": "Cameroon",
"cn": "喀麦隆",
"code": "+237"
},
{
"en": "Canada",
"cn": "加拿大",
"code": "+1"
},
{
"en": "Cape Verde",
"cn": "佛得角",
"code": "+238"
},
{
"en": "Cayman Is",
"cn": "开曼群岛",
"code": "+1345"
},
{
"en": "Central African Republic",
"cn": "中非共和国",
"code": "+236"
},
{
"en": "Chad",
"cn": "乍得",
"code": "+235"
},
{
"en": "Chile",
"cn": "智利",
"code": "+56"
},
{
"en": "China",
"cn": "中国",
"code": "+86"
},
{
"en": "Colombia",
"cn": "哥伦比亚",
"code": "+57"
},
{
"en": "Congo",
"cn": "刚果",
"code": "+242"
},
{
"en": "Cook Is",
"cn": "库克群岛",
"code": "+682"
},
{
"en": "Costa Rica",
"cn": "哥斯达黎加",
"code": "+506"
},
{
"en": "Cuba",
"cn": "古巴",
"code": "+53"
},
{
"en": "Cyprus",
"cn": "塞浦路斯",
"code": "+357"
},
{
"en": "Czech Republic",
"cn": "捷克",
"code": "+420"
},
{
"en": "Denmark",
"cn": "丹麦",
"code": "+45"
},
{
"en": "Djibouti",
"cn": "吉布提",
"code": "+253"
},
{
"en": "Dominica Rep",
"cn": "多米尼加共和国",
"code": "+1809"
},
{
"en": "DR Congo",
"cn": "民主刚果",
"code": "+243"
},
{
"en": "Ecuador",
"cn": "厄瓜多尔",
"code": "+593"
},
{
"en": "Egypt",
"cn": "埃及",
"code": "+20"
},
{
"en": "El Salvador",
"cn": "萨尔瓦多",
"code": "+503"
},
{
"en": "Estonia",
"cn": "爱沙尼亚",
"code": "+372"
},
{
"en": "Ethiopia",
"cn": "埃塞俄比亚",
"code": "+251"
},
{
"en": "Falkland Islands",
"cn": "福克兰群岛",
"code": "+500"
},
{
"en": "Fiji",
"cn": "斐济",
"code": "+679"
},
{
"en": "Finland",
"cn": "芬兰",
"code": "+358"
},
{
"en": "France",
"cn": "法国",
"code": "+33"
},
{
"en": "French Guiana",
"cn": "法属圭亚那",
"code": "+594"
},
{
"en": "French Polynesia",
"cn": "法属玻利尼西亚",
"code": "+689"
},
{
"en": "Gabon",
"cn": "加蓬",
"code": "+241"
},
{
"en": "Gambia",
"cn": "冈比亚",
"code": "+220"
},
{
"en": "Georgia",
"cn": "格鲁吉亚",
"code": "+995"
},
{
"en": "Germany",
"cn": "德国",
"code": "+49"
},
{
"en": "Ghana",
"cn": "加纳",
"code": "+233"
},
{
"en": "Gibraltar",
"cn": "直布罗陀",
"code": "+350"
},
{
"en": "Greece",
"cn": "希腊",
"code": "+30"
},
{
"en": "Grenada",
"cn": "格林纳达",
"code": "+1473"
},
{
"en": "Guam",
"cn": "关岛",
"code": "+1671"
},
{
"en": "Guatemala",
"cn": "危地马拉",
"code": "+502"
},
{
"en": "Guinea",
"cn": "几内亚",
"code": "+224"
},
{
"en": "Guyana",
"cn": "圭亚那",
"code": "+592"
},
{
"en": "Haiti",
"cn": "海地",
"code": "+509"
},
{
"en": "Honduras",
"cn": "洪都拉斯",
"code": "+504"
},
{
"en": "Hongkong",
"cn": "香港",
"code": "+852"
},
{
"en": "Hungary",
"cn": "匈牙利",
"code": "+36"
},
{
"en": "Iceland",
"cn": "冰岛",
"code": "+354"
},
{
"en": "India",
"cn": "印度",
"code": "+91"
},
{
"en": "Indonesia",
"cn": "印度尼西亚",
"code": "+62"
},
{
"en": "Iran",
"cn": "伊朗",
"code": "+98"
},
{
"en": "Iraq",
"cn": "伊拉克",
"code": "+964"
},
{
"en": "Ireland",
"cn": "爱尔兰",
"code": "+353"
},
{
"en": "Israel",
"cn": "以色列",
"code": "+972"
},
{
"en": "Italy",
"cn": "意大利",
"code": "+39"
},
{
"en": "Ivory Coast",
"cn": "科特迪瓦",
"code": "+225"
},
{
"en": "Jamaica",
"cn": "牙买加",
"code": "+1876"
},
{
"en": "Japan",
"cn": "日本",
"code": "+81"
},
{
"en": "Jordan",
"cn": "约旦",
"code": "+962"
},
{
"en": "Kazakhstan",
"cn": "哈萨克斯坦",
"code": "+7"
},
{
"en": "Kenya",
"cn": "肯尼亚",
"code": "+254"
},
{
"en": "Korea",
"cn": "韩国",
"code": "+82"
},
{
"en": "Kosovo",
"cn": "科索沃",
"code": "+383"
},
{
"en": "Kuwait",
"cn": "科威特",
"code": "+965"
},
{
"en": "Kyrgyzstan",
"cn": "吉尔吉斯坦",
"code": "+996"
},
{
"en": "Laos",
"cn": "老挝",
"code": "+856"
},
{
"en": "Latvia",
"cn": "拉脱维亚",
"code": "+371"
},
{
"en": "Lebanon",
"cn": "黎巴嫩",
"code": "+961"
},
{
"en": "Lesotho",
"cn": "莱索托",
"code": "+266"
},
{
"en": "Liberia",
"cn": "利比里亚",
"code": "+231"
},
{
"en": "Libya",
"cn": "利比亚",
"code": "+218"
},
{
"en": "Liechtenstein",
"cn": "列支敦士登",
"code": "+423"
},
{
"en": "Lithuania",
"cn": "立陶宛",
"code": "+370"
},
{
"en": "Luxembourg",
"cn": "卢森堡",
"code": "+352"
},
{
"en": "Macao",
"cn": "澳门",
"code": "+853"
},
{
"en": "Madagascar",
"cn": "马达加斯加",
"code": "+261"
},
{
"en": "Malawi",
"cn": "马拉维",
"code": "+265"
},
{
"en": "Malaysia",
"cn": "马来西亚",
"code": "+60"
},
{
"en": "Maldives",
"cn": "马尔代夫",
"code": "+960"
},
{
"en": "Mali",
"cn": "马里",
"code": "+223"
},
{
"en": "Malta",
"cn": "马耳他",
"code": "+356"
},
{
"en": "Mariana Is",
"cn": "马里亚那群岛",
"code": "+1670"
},
{
"en": "Martinique",
"cn": "马提尼克",
"code": "+596"
},
{
"en": "Mauritius",
"cn": "毛里求斯",
"code": "+230"
},
{
"en": "Mexico",
"cn": "墨西哥",
"code": "+52"
},
{
"en": "Moldova",
"cn": "摩尔多瓦",
"code": "+373"
},
{
"en": "Monaco",
"cn": "摩纳哥",
"code": "+377"
},
{
"en": "Mongolia",
"cn": "蒙古",
"code": "+976"
},
{
"en": "Montenegro",
"cn": "黑山",
"code": "+382"
},
{
"en": "Montserrat Is",
"cn": "蒙特塞拉特岛",
"code": "+1664"
},
{
"en": "Morocco",
"cn": "摩洛哥",
"code": "+212"
},
{
"en": "Mozambique",
"cn": "莫桑比克",
"code": "+258"
},
{
"en": "Namibia",
"cn": "纳米比亚",
"code": "+264"
},
{
"en": "Nauru",
"cn": "瑙鲁",
"code": "+674"
},
{
"en": "Nepal",
"cn": "尼泊尔",
"code": "+977"
},
{
"en": "Netherlands",
"cn": "荷兰",
"code": "+31"
},
{
"en": "Netherlands Antilles",
"cn": "荷属安的列斯",
"code": "+599"
},
{
"en": "New Zealand",
"cn": "新西兰",
"code": "+64"
},
{
"en": "Nicaragua",
"cn": "尼加拉瓜",
"code": "+505"
},
{
"en": "Niger",
"cn": "尼日尔",
"code": "+227"
},
{
"en": "Nigeria",
"cn": "尼日利亚",
"code": "+234"
},
{
"en": "North Korea",
"cn": "朝鲜",
"code": "+850"
},
{
"en": "North Macedonia",
"cn": "北马其顿",
"code": "+389"
},
{
"en": "Norway",
"cn": "挪威",
"code": "+47"
},
{
"en": "Oman",
"cn": "阿曼",
"code": "+968"
},
{
"en": "Pakistan",
"cn": "巴基斯坦",
"code": "+92"
},
{
"en": "Palestine",
"cn": "巴勒斯坦",
"code": "+970"
},
{
"en": "Panama",
"cn": "巴拿马",
"code": "+507"
},
{
"en": "Papua New Guinea",
"cn": "巴布亚新几内亚",
"code": "+675"
},
{
"en": "Paraguay",
"cn": "巴拉圭",
"code": "+595"
},
{
"en": "Peru",
"cn": "秘鲁",
"code": "+51"
},
{
"en": "Philippines",
"cn": "菲律宾",
"code": "+63"
},
{
"en": "Poland",
"cn": "波兰",
"code": "+48"
},
{
"en": "Portugal",
"cn": "葡萄牙",
"code": "+351"
},
{
"en": "Puerto Rico",
"cn": "波多黎各",
"code": "+1787"
},
{
"en": "Qatar",
"cn": "卡塔尔",
"code": "+974"
},
{
"en": "Republic of Croatia",
"cn": "克罗地亚共和国",
"code": "+385"
},
{
"en": "Reunion",
"cn": "留尼旺",
"code": "+262"
},
{
"en": "Romania",
"cn": "罗马尼亚",
"code": "+40"
},
{
"en": "Russia",
"cn": "俄罗斯",
"code": "+7"
},
{
"en": "Saint Lucia",
"cn": "圣卢西亚",
"code": "+1758"
},
{
"en": "Saint Vincent",
"cn": "圣文森特",
"code": "+1784"
},
{
"en": "Samoa",
"cn": "萨摩亚",
"code": "+685"
},
{
"en": "San Marino",
"cn": "圣马力诺",
"code": "+378"
},
{
"en": "Sao Tome and Principe",
"cn": "圣多美和普林西比",
"code": "+239"
},
{
"en": "Saudi Arabia",
"cn": "沙特阿拉伯",
"code": "+966"
},
{
"en": "Senegal",
"cn": "塞内加尔",
"code": "+221"
},
{
"en": "Seychelles",
"cn": "塞舌尔",
"code": "+248"
},
{
"en": "Sierra Leone",
"cn": "塞拉利昂",
"code": "+232"
},
{
"en": "Singapore",
"cn": "新加坡",
"code": "+65"
},
{
"en": "Slovakia",
"cn": "斯洛伐克",
"code": "+421"
},
{
"en": "Slovenia",
"cn": "斯洛文尼亚",
"code": "+386"
},
{
"en": "Solomon Is",
"cn": "所罗门群岛",
"code": "+677"
},
{
"en": "Somali",
"cn": "索马里",
"code": "+252"
},
{
"en": "South Africa",
"cn": "南非",
"code": "+27"
},
{
"en": "South Sudan",
"cn": "南苏丹",
"code": "+211"
},
{
"en": "Spain",
"cn": "西班牙",
"code": "+34"
},
{
"en": "Sri Lanka",
"cn": "斯里兰卡",
"code": "+94"
},
{
"en": "Sudan",
"cn": "苏丹",
"code": "+249"
},
{
"en": "Suriname",
"cn": "苏里南",
"code": "+597"
},
{
"en": "Swaziland",
"cn": "斯威士兰",
"code": "+268"
},
{
"en": "Sweden",
"cn": "瑞典",
"code": "+46"
},
{
"en": "Switzerland",
"cn": "瑞士",
"code": "+41"
},
{
"en": "Syria",
"cn": "叙利亚",
"code": "+963"
},
{
"en": "Taiwan",
"cn": "台湾省",
"code": "+886"
},
{
"en": "Tajikstan",
"cn": "塔吉克斯坦",
"code": "+992"
},
{
"en": "Tanzania",
"cn": "坦桑尼亚",
"code": "+255"
},
{
"en": "Thailand",
"cn": "泰国",
"code": "+66"
},
{
"en": "Timor-Leste",
"cn": "东帝汶",
"code": "+670"
},
{
"en": "Togo",
"cn": "多哥",
"code": "+228"
},
{
"en": "Tonga",
"cn": "汤加",
"code": "+676"
},
{
"en": "Trinidad and Tobago",
"cn": "特立尼达和多巴哥",
"code": "+1868"
},
{
"en": "Tunisia",
"cn": "突尼斯",
"code": "+216"
},
{
"en": "Turkey",
"cn": "土耳其",
"code": "+90"
},
{
"en": "Turkmenistan",
"cn": "土库曼斯坦",
"code": "+993"
},
{
"en": "Uganda",
"cn": "乌干达",
"code": "+256"
},
{
"en": "Ukraine",
"cn": "乌克兰",
"code": "+380"
},
{
"en": "United Arab Emirates",
"cn": "阿拉伯联合酋长国",
"code": "+971"
},
{
"en": "United Kingdom",
"cn": "英国",
"code": "+44"
},
{
"en": "United States of America",
"cn": "美国",
"code": "+1"
},
{
"en": "Uruguay",
"cn": "乌拉圭",
"code": "+598"
},
{
"en": "Uzbekistan",
"cn": "乌兹别克斯坦",
"code": "+998"
},
{
"en": "Vatican City",
"cn": "梵蒂冈",
"code": "+379"
},
{
"en": "Venezuela",
"cn": "委内瑞拉",
"code": "+58"
},
{
"en": "Vietnam",
"cn": "越南",
"code": "+84"
},
{
"en": "Yemen",
"cn": "也门",
"code": "+967"
},
{
"en": "Zambia",
"cn": "赞比亚",
"code": "+260"
},
{
"en": "Zimbabwe",
"cn": "津巴布韦",
"code": "+263"
}
]
\ No newline at end of file
......@@ -33,6 +33,18 @@
form.on('radio(receipt_type)', function (data) {
g.receiptType = data.value;
if (data.value === '1') {
$('#bank_address_require_span').hide();
$('#nation_id').val('36');
$('#nation_id').attr('disabled', true);
$('#nation_id').addClass('layui-disabled');
form.render('select');
} else {
$('#nation_id').val('');
$('#nation_id').attr('disabled', false);
$('#nation_id').removeClass('layui-disabled');
form.render('select');
}
});
//图片上传
......
......@@ -8,19 +8,24 @@
let element = layui.element;
let xmSelect = layui.xmSelect;
form.on('radio(receipt_type)', function (data) {
form.on('radio(supplier_type)', function (data) {
if (data.value == 1) {
$('#swift_code_div').hide();
$('#nation_id_div').hide();
$('#account_name_label').text('账户名称 : ');
$('#account_name_require_span').hide();
$('#bank_address_require_span').hide();
$('#nation_id').val('36');
$('#nation_id').attr('disabled', true);
$('#nation_id').addClass('layui-disabled');
form.render('select');
} else {
$('#swift_code_div').show();
$('#nation_id_div').show();
$('#account_name_label').text('国外受益人 : ');
$('#account_name_require_span').show();
$('#bank_address_require_span').show();
$('#nation_id').attr('disabled', false);
$('#nation_id').removeClass('layui-disabled');
form.render('select');
}
});
......
......@@ -143,6 +143,16 @@
//如果选择区域为国内,那么成立时间disabled
//这里还有就是region有个对应公司id的映射关系,要自动切换对应的签约公司下拉
form.on('select(region)', function(data) {
if (data.value === '2') {
$('#nation_id').val('36');
} else if (data.value === '4') {
$('#nation_id').val('194');
} else if (data.value === '6') {
$('#nation_id').val('195');
}else{
$('#nation_id').val('');
}
form.render('select');
@if (empty($supplier))
let supplierNameObj = $('#supplier_name');
let taxNumberObj = $('#tax_number');
......
......@@ -34,7 +34,7 @@
{field: 'account_no', title: '<span class="require">* </span>银行账号', align: 'center', width: 130},
{field: 'account_name', title: '账户名称', align: 'center', width: 150},
{field: 'swift_code', title: 'Swift Code', align: 'center', width: 130},
// {field: 'international_code', title: '国际代码', align: 'center', width: 130},
// {field: 'nation_id', title: '国际代码', align: 'center', width: 130},
{
field: 'certificate',
title: '<span class="require">* </span>信息凭证',
......@@ -45,7 +45,7 @@
},
{field: 'account_adderss', title: '银行地址', align: 'center', width: 200},
{
field: 'nation_name', title: '银行国家', align: 'center', width: 100, templet: function (data) {
field: 'nation_name', title: '国家/地区', align: 'center', width: 100, templet: function (data) {
return data.nation ? data.nation.name_cn : '';
}
},
......
......@@ -38,16 +38,20 @@
<input type="hidden" name="apply_audit_reason" id="apply_audit_reason">
<div class="layui-form-item">
<div class="layui-col-md3">
<div class="layui-col-md2">
@inject('singleSelectPresenter','App\Presenters\SingleSelectPresenter')
{!! $singleSelectPresenter->render('supplier_type','供应商类别',!empty($supplier)?array_get($supplier,'supplier_type',0):'1',[1=>'正式',2=>'临时'],['require'=>true]) !!}
</div>
<div class="layui-col-md3">
<div class="layui-col-md4">
@inject('statusPresenter','App\Presenters\StatusPresenter')
{!! $statusPresenter->render('region','所在区域 : ','',
config('fixed.Region'),['required'=>true,'width'=>'150px']) !!}
config('fixed.Region'),['required'=>true,'width'=>'120px']) !!}
@inject('statusPresenter','App\Presenters\StatusPresenter')
{!! $statusPresenter->render('nation_id','所在国家/地区 : ','',
$nationList,['required'=>true,'width'=>'120px','label_width'=>'110px']) !!}
</div>
<div class="layui-col-md6">
<div class="city-div" style="display: none">
<label class="layui-form-label">选择省市 : </label>
......@@ -344,9 +348,9 @@
</div>
</div>
<div class="layui-col-md4">
<div class="layui-form-item" id="nation_id_div" style="display: none">
<div class="layui-form-item" id="nation_id_div">
@inject('statusPresenter','App\Presenters\StatusPresenter')
{!! $statusPresenter->render('nation_id','银行国家 : ',0,
{!! $statusPresenter->render('nation_id','国家/地区 : ',0,
$nationList,['required'=>true]) !!}
</div>
</div>
......@@ -368,7 +372,7 @@
value="">
</div>
</div>
<div class="layui-col-md4">
<div class="layui-col-md12">
<label class="layui-form-label">备注 : </label>
<div class="layui-input-block block-42">
<input type="text" name="remark" id="remark"
......
......@@ -69,9 +69,9 @@
value="{{$receipt['account_adderss'] or ''}}">
</div>
</div>
<div class="layui-form-item" id="nation_id_div" x-show="receiptType === '2'">
<div class="layui-form-item" id="nation_id_div">
@inject('statusPresenter','App\Presenters\StatusPresenter')
{!! $statusPresenter->render('nation_id','银行国家 : ',isset($receipt['nation_id'])?$receipt['nation_id']:0,
{!! $statusPresenter->render('nation_id','国家/地区 : ',isset($receipt['nation_id'])?$receipt['nation_id']:0,
$nationList,['required'=>true]) !!}
</div>
<div class="layui-form-item" id="swift_code_div" x-show="receiptType === '2'">
......@@ -82,6 +82,7 @@
value="{{$receipt['swift_code'] or ''}}">
</div>
</div>
<br>
<div class="layui-form-item">
<label class="layui-form-label">
<span class="require">*</span>供应商银行信息凭证:
......
......@@ -32,14 +32,16 @@
?>
<div class="layui-form-item">
<div class="layui-col-md3">
<div class="layui-col-md2">
@inject('singleSelectPresenter','App\Presenters\SingleSelectPresenter')
{!! $singleSelectPresenter->render('supplier_type','供应商类别',!empty($supplier)?array_get($supplier,'supplier_type',0):'1',$supplierType,$option) !!}
</div>
<div class="layui-col-md3">
<div class="layui-col-md4">
@inject('statusPresenter','App\Presenters\StatusPresenter')
{!! $statusPresenter->render('region','所在区域 : ',$supplier['region'],
config('fixed.Region'),['required'=>true,'width'=>'150px']) !!}
@inject('statusPresenter','App\Presenters\StatusPresenter')
{!! $statusPresenter->render('nation_id','所在国家/地区: ',!empty($supplier)?$supplier['nation_id']:'',$nationList,['required'=>true,'width'=>'110px','label_width'=>'90px']) !!}
</div>
<div class="layui-col-md6">
<div class="city-div" style="display: none">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment