biz9-logic 10.0.60 → 10.0.76

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. package/biz9_config +1 -1
  2. package/index.js +1197 -97
  3. package/package.json +1 -1
  4. package/test.js +38 -58
package/index.js CHANGED
@@ -75,9 +75,16 @@ class Type {
75
75
  static DATA_VIDEO='video_biz';
76
76
  //field
77
77
  static FIELD_AUTHOR = 'author';
78
+ static FIELD_CART_NUMBER = 'cart_number';
79
+ static FIELD_CART_ID = 'cart_id';
80
+ static FIELD_CART_ITEM_ID = 'cart_item_id';
81
+ static FIELD_ORDER_NUMBER = 'order_number';
82
+ static FIELD_ORDER_ID = 'order_id';
83
+ static FIELD_ORDER_ITEM_ID = 'order_item_id';
78
84
  static FIELD_CATEGORY = 'category';
79
85
  static FIELD_CATEGORY_TYPE = 'category_type';
80
- static FIELD_COST = 'cost';
86
+ static FIELD_COST = 'cost';
87
+ static FIELD_GRAND_TOTAL = 'grand_total';
81
88
  static FIELD_DATA_TYPE='data_type';
82
89
  static FIELD_DATE_CREATE='date_create';
83
90
  static FIELD_DATE_SAVE='date_save';
@@ -143,7 +150,7 @@ class Type {
143
150
  static TITLE_DATA_PAGE = 'Page';
144
151
  static TITLE_DATA_PRODUCT = 'Product';
145
152
  static TITLE_DATA_SERVICE = 'Service';
146
- //
153
+ //
147
154
  static TITLE_APP_ENV_TEST='Test';
148
155
  static TITLE_APP_ENV_STAGE='Stage';
149
156
  static TITLE_APP_ENV_PROD='Production';
@@ -167,8 +174,8 @@ class Type {
167
174
  static TITLE_ORDER_SUB_ITEMS='order Sub Items';
168
175
  static TITLE_PARENT_ITEM='Parent Item';
169
176
  static TITLE_USER='User';
170
- static TITLE_SORT_BY_ASC='ASC';
171
- static TITLE_SORT_BY_DESC='DESC';
177
+ static TITLE_SORT_BY_ASC='asc';
178
+ static TITLE_SORT_BY_DESC='desc';
172
179
  static TITLE_STAT_ITEMS='Stat Items';
173
180
  static TITLE_STAT_SUB_ITEMS='Stat Sub Items';
174
181
  static TITLE_ORDER_STATUS_NEW="New";
@@ -285,6 +292,12 @@ class Type {
285
292
  static IMAGE_RESIZE_NORMAL="normal";
286
293
  static IMAGE_RESIZE_SQUARE="squre";
287
294
  static IMAGE_RESIZE_NONE="none";
295
+ //
296
+ static CART_SUB_TYPE_STANDARD = 'standard';
297
+ static CART_SUB_TYPE_SHIPPING = 'shipping';
298
+ static CART_SUB_TYPE_COUPON = 'coupon';
299
+ static CART_SUB_TYPE_GIFT_CARD = 'gift_card';
300
+
288
301
  //order
289
302
  static ORDER_STATUS_NEW="new";
290
303
  static ORDER_STATUS_OPEN="open";
@@ -363,10 +376,10 @@ class Stat_Logic {
363
376
  }
364
377
  class Order_Logic {
365
378
  static get = (cart,option) => {
366
- option = option?option:{get_payment_plan:false,payment_plan:Title.ORDER_PAYMENT_PLAN_1};
379
+ option = option?option:{};
380
+ let order_code = option.order_code ? option.order_code+"-" : "";
367
381
  let order = Data_Logic.get_new(Type.DATA_ORDER,0,{data:{
368
- order_number:Title.ORDER_NUMBER + Num.get_id(99999),
369
- parent_data_type:cart.parent_data_type,
382
+ order_number:order_code + Num.get_id(99999),
370
383
  user_id:cart.user_id,
371
384
  cart_number:cart.cart_number,
372
385
  grand_total:cart.grand_total,
@@ -374,20 +387,14 @@ class Order_Logic {
374
387
  order_items:[]
375
388
  }});
376
389
  for(const key in cart) {
377
- if(!Str.check_is_null(cart[key])
378
- && key != Type.FIELD_ID && key != Type.FIELD_DATA_TYPE
379
- && key != Type.TITLE_PARENT_ITEM && key != Type.TITLE_USER
380
- && key != Type.TITLE_CART_ITEMS && key != Type.TITLE_CART_SUB_ITEMS
381
- && key != Type.TITLE_ORDER_ITEMS && key != Type.TITLE_ORDER_SUB_ITEMS
382
- && key != Type.FIELD_SOURCE && key != Type.FIELD_SOURCE_ID
383
- && key != Type.FIELD_DATE_CREATE && key != Type.FIELD_DATE_SAVE){
390
+ if(!Obj.check_is_array(cart[key]) && Obj.check_is_object(cart[key])
391
+ && key != Type.FIELD_ID && key != Type.FIELD_DATA_TYPE
392
+ && key != Type.FIELD_SOURCE && key != Type.FIELD_SOURCE_ID
393
+ && key != Type.FIELD_DATE_CREATE && key != Type.FIELD_DATE_SAVE)
394
+ {
384
395
  order[key] = cart[key];
385
396
  }
386
397
  }
387
- if(option.get_payment_plan){
388
- order.payment_plan = option.payment_plan;
389
- }
390
- /*
391
398
  cart.cart_items.forEach(cart_item => {
392
399
  let order_item = Data_Logic.get_new(Type.DATA_ORDER_ITEM,0,{data:{
393
400
  order_number:order.order_number,
@@ -398,38 +405,34 @@ class Order_Logic {
398
405
  cost:cart_item.cost?cart_item.cost:0,
399
406
  order_sub_items:[]
400
407
  }});
401
- });
402
- for(const key in cart_item){
403
- if(!Str.check_is_null(cart_item[key]){
404
- && key != Type.FIELD_ID && key != Type.FIELD_DATA_TYPE
405
- && key != Type.TITLE_PARENT_ITEM && key != Type.TITLE_USER
406
- && key != Type.TITLE_CART_ITEMS && key != Type.TITLE_CART_SUB_ITEMS
407
- && key != Type.TITLE_ORDER_ITEMS && key != Type.TITLE_ORDER_SUB_ITEMS
408
+ for(const key in cart_item){
409
+ if(!Obj.check_is_array(cart_item[key]) && Obj.check_is_object(cart_item[key])
410
+ && key != Type.FIELD_ID && key != Type.FIELD_DATA_TYPE
408
411
  && key != Type.FIELD_SOURCE && key != Type.FIELD_SOURCE_ID
409
- && key != Type.FIELD_DATE_CREATE && key != Type.FIELD_DATE_SAVE
412
+ && key != Type.FIELD_DATE_CREATE && key != Type.FIELD_DATE_SAVE){
410
413
  order_item[key] = cart_item[key]
411
414
  }
412
415
  }
413
- cart_item.cart_sub_items.forEach(cart_sub_item => {
414
- let order_sub_item = Data_Logic.get_new(Type.DATA_ORDER_SUB_ITEM,0,
415
- {data:{order_number:order.order_number,parent_data_type:cart_sub_item.parent_data_type,parent_id:cart_sub_item.parent_id,user_id:order.user_id,quanity:cart_sub_item.quanity?cart_sub_item.quanity:0,cost:cart_sub_item.cost?cart_sub_item.cost:0}};
416
- for(const key in cart_sub_item){
417
- if(!Str.check_is_null(cart_sub_item[key])){
418
- && key != Type.FIELD_ID && key != Type.DATA_TYPE
419
- && key != Type.TITLE_PARENT_ITEM && key != Type.TITLE_USER
420
- && key != Type.TITLE_CART_ITEMS && key != Type.TITLE_CART_SUB_ITEMS
421
- && key != Type.TITLE_ORDER_ITEMS && key != Type.TITLE_ORDER_SUB_ITEMS
422
- && key != Type.FIELD_SOURCE && key != Type.FIELD_SOURCE_ID
423
- && key != Type.FIELD_DATE_CREATE && key != Type.FIELD_DATE_SAVE{
424
- order_sub_item[key] = cart_sub_item[key]{
425
- }
426
- }
427
- order_item.order_sub_items.push(order_sub_item);
428
- });
429
- order.order_items.push(order_item);
416
+ cart_item.cart_sub_items.forEach(cart_sub_item => {
417
+ let order_sub_item = Data_Logic.get_new(Type.DATA_ORDER_SUB_ITEM,0,{data:{
418
+ type:cart_sub_item.type,
419
+ cart_item_id:cart_sub_item.cart_item_id,
420
+ quanity:cart_sub_item.quanity,
421
+ cost:cart_sub_item.cost
422
+ }});
423
+ for(const key in cart_sub_item){
424
+ if(!Obj.check_is_array(order_sub_item[key]) && Obj.check_is_object(order_sub_item[key])
425
+ && key != Type.FIELD_ID && key != Type.FIELD_DATA_TYPE
426
+ && key != Type.FIELD_SOURCE && key != Type.FIELD_SOURCE_ID
427
+ && key != Type.FIELD_DATE_CREATE && key != Type.FIELD_DATE_SAVE){
428
+ order_sub_item[key] = cart_sub_item[key]
429
+ }
430
+ }
431
+ order_item.order_sub_items.push(order_sub_item);
432
+ });
433
+ order.order_items.push(order_item);
430
434
  });
431
435
  return order;
432
- */
433
436
  };
434
437
  static get_order_statuses(){
435
438
  return [
@@ -441,17 +444,6 @@ class Order_Logic {
441
444
  {value:Type.ORDER_STATUS_CANCELLED,label:Type.TITLE_ORDER_STATUS_CANCELLED,title:Type.TITLE_ORDER_STATUS_CANCELLED},
442
445
  ];
443
446
  };
444
-
445
- /*
446
- static get_order_payment = (order_number,payment_method_type,payment_amount) => {
447
- return Data_Logic.get_new(Type.DATA_ORDER_PAYMENT,0,{data:
448
- {
449
- order_number:order_number,
450
- payment_method_type:payment_method_type,
451
- payment_amount:payment_amount,
452
- transaction_id:Title.ORDER_TRANSACTION_ID + Num.get_id(99999)
453
- }});
454
- };
455
447
  static get_total = (order) => {
456
448
  let grand_total = 0;
457
449
  order.order_items.forEach(order_item => {
@@ -471,18 +463,37 @@ class Order_Logic {
471
463
  order.grand_total = grand_total;
472
464
  return order;
473
465
  };
474
- */
466
+
467
+ static get_order_payment = (order_number,payment_method_type,payment_amount) => {
468
+ return Data_Logic.get_new(Type.DATA_ORDER_PAYMENT,0,{data:
469
+ {
470
+ order_number:order_number,
471
+ payment_method_type:payment_method_type,
472
+ payment_amount:payment_amount,
473
+ transaction_id:Title.ORDER_TRANSACTION_ID + Num.get_id(99999)
474
+ }});
475
+ };
475
476
  }
476
477
  class Cart_Logic {
477
- static get = (parent_data_type,user_id) => {
478
- return Data_Logic.get_new(Type.DATA_CART,0,{data:{user_id:user_id,cart_number:Title.CART_NUMBER + Num.get_id(99999),parent_data_type:parent_data_type,grand_total:0,cart_items:[]}});
478
+ static get = (user_id,option) => {
479
+ option = option ? option : {};
480
+ let cart_code = option.cart_code ? option.cart_code+"-" : "";
481
+ return Data_Logic.get_new(Type.DATA_CART,0,{data:{user_id:user_id,cart_number:cart_code + Num.get_id(99999),grand_total:0,cart_items:[]}});
479
482
  };
480
- static get_cart_item = (parent_data_type,parent_id,cart_number,quanity,cost) =>{
481
- return Data_Logic.get_new(Type.DATA_CART_ITEM,0,{data:{parent_data_type:parent_data_type,parent_id:parent_id,cart_number:cart_number,quanity:quanity?quanity:0,cost:cost?cost:0,cart_sub_items:[]}});
483
+ static get_cart_item = (parent_data_type,parent_id,quanity,cost) =>{
484
+ return Data_Logic.get_new(Type.DATA_CART_ITEM,0,{data:{parent_data_type:parent_data_type,parent_id:parent_id,quanity:quanity?quanity:0,cost:cost?cost:0,cart_sub_items:[]}});
482
485
  };
483
- static get_cart_sub_item = (parent_data_type,parent_id,cart_number,quanity,cost) =>{
484
- return Data_Logic.get_new(Type.DATA_CART_SUB_ITEM,0,{data:{parent_data_type:parent_data_type,parent_id:parent_id,cart_number:cart_number,quanity:quanity?quanity:0,cost:cost?cost:0}});
486
+ static get_cart_sub_item = (cart_item_id,type,quanity,cost) =>{
487
+ return Data_Logic.get_new(Type.DATA_CART_SUB_ITEM,0,{data:{type:type,cart_item_id:cart_item_id,quanity:quanity,cost:cost}});
485
488
  };
489
+ static get_cart_sub_items = () =>{
490
+ return [
491
+ {title:Str.get_title(Type.CART_SUB_TYPE_STANDARD),label:Str.get_title(Type.CART_SUB_TYPE_STANDARD),type:Type.CART_SUB_TYPE_STANDARD},
492
+ {title:Str.get_title(Type.CART_SUB_TYPE_SHIPPING),label:Str.get_title(Type.CART_SUB_TYPE_SHIPPING),type:Type.CART_SUB_TYPE_SHIPPING},
493
+ {title:Str.get_title(Type.CART_SUB_TYPE_COUPON),label:Str.get_title(Type.CART_SUB_TYPE_COUPON),type:Type.CART_SUB_TYPE_COUPON},
494
+ {title:Str.get_title(Type.CART_SUB_TYPE_GIFT_CARD),label:Str.get_title(Type.CART_SUB_TYPE_GIFT_CARD),type:Type.CART_SUB_TYPE_GIFT_CARD}
495
+ ];
496
+ };
486
497
  static get_total = (cart) => {
487
498
  let grand_total = 0;
488
499
  cart.cart_items.forEach(cart_item => {
@@ -534,8 +545,8 @@ class Product_Logic {
534
545
  break;
535
546
  }
536
547
  };
537
- static get_test = (option) =>{
538
- let data = {};
548
+ static get_test = () =>{
549
+ let data = Data_Logic.get(Type.DATA_PRODUCT,0);
539
550
  data.cost = Field_Logic.get_test_cost();
540
551
  data.old_cost = Field_Logic.get_test_cost();
541
552
  data.category = "Category "+String(Num.get_id());
@@ -581,33 +592,43 @@ class Service_Logic {
581
592
  return data;
582
593
  };
583
594
  }
595
+ class Content_Logic {
596
+ static get_test = () =>{
597
+ let data = Data_Logic.get(Type.DATA_CONTENT,0);
598
+ data.field_1="Field 1 "+ Num.get_id();
599
+ data.field_2="Field 2 "+ Num.get_id();
600
+ return data;
601
+ };
602
+ };
603
+
584
604
  class Blank_Logic {
585
- static get_test = (option) =>{
586
- let data = {};
605
+ static get_test = () =>{
606
+ let data = Data_Logic.get(Type.DATA_BLANK,0);
587
607
  data.field_1="Field 1 "+ Num.get_id();
588
608
  data.field_2="Field 2 "+ Num.get_id();
589
609
  return data;
590
610
  };
591
611
  };
592
612
  class Blog_Post_Logic {
593
- static get_test = (option) =>{
594
- let data = {};
595
- data.author="First Name "+ Num.get_id();
613
+ static get_test = () =>{
614
+ let data = Data_Logic.get(Type.DATA_BLOG_POST,0);
615
+ data.author="Full Name "+ Num.get_id();
596
616
  data.tag = "Tag "+ Num.get_id() + ", Tag "+Num.get_id() + ", Tag "+ Num.get_id(), " Tag "+ Num.get_id() + ", Tag "+Num.get_id() + ", Tag "+ Num.get_id();
597
617
  data.category = "Category "+String(Num.get_id());
598
618
  data.type = "Type "+String(Num.get_id());
599
619
  data.sub_type = "Sub Type "+String(Num.get_id());
600
-
620
+ data.description = "Description "+String(Num.get_id());
621
+ data.note = Field_Logic.get_test_note();
601
622
  return data;
602
623
  };
603
624
  }
604
625
  class Gallery_Logic {
605
626
  static get_test = () =>{
606
- let data = {};
607
- data.date = String(String(Num.get_id(2030)) + "-" + String(Num.get_id(13)) + "-" + String(Num.get_id(30))).trim();
608
- data.time = String(Num.get_id(24)) + ":" + String(Num.get_id(59));
609
- data.website = "Website "+String(Num.get_id());
610
- return data;
627
+ let data = Data_Logic.get(Type.DATA_GALLERY,0);
628
+ data.date = String(String(Num.get_id(2030)) + "-" + String(Num.get_id(13)) + "-" + String(Num.get_id(30))).trim();
629
+ data.time = String(Num.get_id(24)) + ":" + String(Num.get_id(59));
630
+ data.website = "Website "+String(Num.get_id());
631
+ return data;
611
632
  };
612
633
  };
613
634
  class Event_Logic {
@@ -639,8 +660,8 @@ class Event_Logic {
639
660
  }
640
661
  };
641
662
  static get_test = () =>{
642
- let data = {};
643
- data.cost = Field_Logic.get_test_cost();
663
+ let data = Data_Logic.get(Type.DATA_EVENT,0);
664
+ data.cost = Field_Logic.get_test_cost();
644
665
  data.old_cost = Field_Logic.get_test_cost();
645
666
  data.date = String(String(Num.get_id(2030)) + "-" + String(Num.get_id(13)) + "-" + String(Num.get_id(30))).trim();
646
667
  data.time = String(Num.get_id(24)) + ":" + String(Num.get_id(59));
@@ -659,10 +680,6 @@ class Field_Logic {
659
680
  data[Type.FIELD_TITLE] = option.title;
660
681
  data[Type.FIELD_TITLE_URL] = Str.get_title_url(option.title);
661
682
  }
662
- if(option.title){
663
- data[Type.FIELD_TITLE] = Data_Logic.get_data_type_by_type(data.data_type);
664
- data[Type.FIELD_TITLE_URL] = Str.get_title_url(data[Type.FIELD_TITLE]);
665
- }
666
683
  if(option.generate_title || option.test){
667
684
  data[Type.FIELD_TITLE] = Data_Logic.get_data_type_by_type(data.data_type) + " " +Num.get_id(999);
668
685
  data[Type.FIELD_TITLE_URL] = Str.get_title_url(data[Type.FIELD_TITLE]);
@@ -909,11 +926,11 @@ class Review_Logic {
909
926
  ] };
910
927
  }
911
928
  static get_test = () =>{
912
- let data = {};
913
- data.item_data_type = item_data_type;
914
- data.item_id = item_id;
929
+ let data = Data_Logic.get(Type.DATA_REVIEW,0);
930
+ data.user_id = 1;
931
+ data.parent_data_type = Type.DATA_BLANK;;
932
+ data.parent_id = 1;
915
933
  data.rating = Num.get_id(6);
916
- data.user_id = user_id;
917
934
  data.comment = "My comment "+ Field_Logic.get_test_note();
918
935
  return data;
919
936
  };
@@ -926,6 +943,12 @@ class Category_Logic {
926
943
  }
927
944
  return categorys;
928
945
  };
946
+ static get_test = () =>{
947
+ let data = Data_Logic.get(Type.DATA_CATEGORY,0);
948
+ data.field_1="Field 1 "+ Num.get_id();
949
+ data.field_2="Field 2 "+ Num.get_id();
950
+ return data;
951
+ };
929
952
  };
930
953
  class Storage {
931
954
  static get = (window,key) => {
@@ -983,7 +1006,6 @@ static get_pages(){
983
1006
  {value:Type.PAGE_SERVICE_HOME,title:Type.TITLE_PAGE_SERVICE_HOME,label:Type.TITLE_PAGE_SERVICE_HOME,url:Url.PAGE_SERVICE_HOME},
984
1007
  ];
985
1008
  };
986
-
987
1009
  }
988
1010
  class User_Logic {
989
1011
  static get_user_roles(){
@@ -1049,23 +1071,1085 @@ class User_Logic {
1049
1071
  delete req.session.user;
1050
1072
  }
1051
1073
  static get_test = () =>{
1052
- let data = {};
1053
- data.first_name="First Name "+ Num.get_id();
1074
+ let data = Data_Logic.get(Type.DATA_USER,0);
1075
+ data.first_name="First Name "+ Num.get_id();
1054
1076
  data.last_name="First Name "+ Num.get_id();
1055
1077
  data.email="email"+ Num.get_id() + "@email.com";
1056
- data.city="City"+ Num.get_id();
1057
- data.state="State"+ Num.get_id();
1078
+ data.city="City "+ Num.get_id();
1079
+ data.state= User_Logic.get_states()[Num.get_id(User_Logic.get_states().length)].label;
1080
+ data.country= User_Logic.get_countries()[Num.get_id(User_Logic.get_countries().length)].label;
1058
1081
  data.password="1234567";
1059
- data.country="United States";
1060
1082
  return data;
1061
1083
  };
1084
+ static get_countries = () =>{
1085
+ return [
1086
+ {label: 'United States', value: 'United States'},
1087
+ {
1088
+ value: 'Afghanistan',
1089
+ label: 'Afghanistan'
1090
+ },
1091
+ {
1092
+ value: 'Albania',
1093
+ label: 'Albania'
1094
+ },
1095
+ {
1096
+ value: 'Algeria',
1097
+ label: 'Algeria'
1098
+ },
1099
+ {
1100
+ value: 'American Samoa',
1101
+ label: 'American Samoa'
1102
+ },
1103
+ {
1104
+ value: 'Andorra',
1105
+ label: 'Andorra'
1106
+ },
1107
+ {
1108
+ value: 'Angola',
1109
+ label: 'Angola'
1110
+ },
1111
+ {
1112
+ value: 'Anguilla',
1113
+ label: 'Anguilla'
1114
+ },
1115
+ {
1116
+ value: 'Antarctica',
1117
+ label: 'Antarctica'
1118
+ },
1119
+ {
1120
+ value: 'Antigua and Barbuda',
1121
+ label: 'Antigua and Barbuda'
1122
+ },
1123
+ {
1124
+ value: 'Argentina',
1125
+ label: 'Argentina'
1126
+ },
1127
+ {
1128
+ value: 'Armenia',
1129
+ label: 'Armenia'
1130
+ },
1131
+ {
1132
+ value: 'Aruba',
1133
+ label: 'Aruba'
1134
+ },
1135
+ {
1136
+ value: 'Australia',
1137
+ label: 'Australia'
1138
+ },
1139
+ {
1140
+ value: 'Austria',
1141
+ label: 'Austria'
1142
+ },
1143
+ {
1144
+ value: 'Azerbaijan',
1145
+ label: 'Azerbaijan'
1146
+ },
1147
+ {
1148
+ value: 'Bahamas',
1149
+ label: 'Bahamas'
1150
+ },
1151
+ {
1152
+ value: 'Bahrain',
1153
+ label: 'Bahrain'
1154
+ },
1155
+ {
1156
+ value: 'Bangladesh',
1157
+ label: 'Bangladesh'
1158
+ },
1159
+ {
1160
+ value: 'Barbados',
1161
+ label: 'Barbados'
1162
+ },
1163
+ {
1164
+ value: 'Belarus',
1165
+ label: 'Belarus'
1166
+ },
1167
+ {
1168
+ value: 'Belgium',
1169
+ label: 'Belgium'
1170
+ },
1171
+ {
1172
+ value: 'Belize',
1173
+ label: 'Belize'
1174
+ },
1175
+ {
1176
+ value: 'Benin',
1177
+ label: 'Benin'
1178
+ },
1179
+ {
1180
+ value: 'Bermuda',
1181
+ label: 'Bermuda'
1182
+ },
1183
+ {
1184
+ value: 'Bhutan',
1185
+ label: 'Bhutan'
1186
+ },
1187
+ {
1188
+ value: 'Bolivia (Plurinational State of)',
1189
+ label: 'Bolivia (Plurinational State of)'
1190
+ },
1191
+ {
1192
+ value: 'Bonaire, Sint Eustatius and Saba',
1193
+ label: 'Bonaire, Sint Eustatius and Saba'
1194
+ },
1195
+ {
1196
+ value: 'Bosnia and Herzegovina',
1197
+ label: 'Bosnia and Herzegovina'
1198
+ },
1199
+ {
1200
+ value: 'Botswana',
1201
+ label: 'Botswana'
1202
+ },
1203
+ {
1204
+ value: 'Bouvet Island',
1205
+ label: 'Bouvet Island'
1206
+ },
1207
+ {
1208
+ value: 'Brazil',
1209
+ label: 'Brazil'
1210
+ },
1211
+ {
1212
+ value: 'British Indian Ocean Territory',
1213
+ label: 'British Indian Ocean Territory'
1214
+ },
1215
+ {
1216
+ value: 'Brunei Darussalam',
1217
+ label: 'Brunei Darussalam'
1218
+ },
1219
+ {
1220
+ value: 'Bulgaria',
1221
+ label: 'Bulgaria'
1222
+ },
1223
+ {
1224
+ value: 'Burkina Faso',
1225
+ label: 'Burkina Faso'
1226
+ },
1227
+ {
1228
+ value: 'Burundi',
1229
+ label: 'Burundi'
1230
+ },
1231
+ {
1232
+ value: 'Cabo Verde',
1233
+ label: 'Cabo Verde'
1234
+ },
1235
+ {
1236
+ value: 'Cambodia',
1237
+ label: 'Cambodia'
1238
+ },
1239
+ {
1240
+ value: 'Cameroon',
1241
+ label: 'Cameroon'
1242
+ },
1243
+ {
1244
+ value: 'Canada',
1245
+ label: 'Canada'
1246
+ },
1247
+ {
1248
+ value: 'Cayman Islands',
1249
+ label: 'Cayman Islands'
1250
+ },
1251
+ {
1252
+ value: 'Central African Republic',
1253
+ label: 'Central African Republic'
1254
+ },
1255
+ {
1256
+ value: 'Chad',
1257
+ label: 'Chad'
1258
+ },
1259
+ {
1260
+ value: 'Chile',
1261
+ label: 'Chile'
1262
+ },
1263
+ {
1264
+ value: 'China',
1265
+ label: 'China'
1266
+ },
1267
+ {
1268
+ value: 'Christmas Island',
1269
+ label: 'Christmas Island'
1270
+ },
1271
+ {
1272
+ value: 'Cocos (Keeling) Islands',
1273
+ label: 'Cocos (Keeling) Islands'
1274
+ },
1275
+ {
1276
+ value: 'Colombia',
1277
+ label: 'Colombia'
1278
+ },
1279
+ {
1280
+ value: 'Comoros',
1281
+ label: 'Comoros'
1282
+ },
1283
+ {
1284
+ value: 'Congo',
1285
+ label: 'Congo'
1286
+ },
1287
+ {
1288
+ value: 'Congo (Democratic Republic of the)',
1289
+ label: 'Congo (Democratic Republic of the)'
1290
+ },
1291
+ {
1292
+ value: 'Cook Islands',
1293
+ label: 'Cook Islands'
1294
+ },
1295
+ {
1296
+ value: 'Costa Rica',
1297
+ label: 'Costa Rica'
1298
+ },
1299
+ {
1300
+ value: 'Croatia',
1301
+ label: 'Croatia'
1302
+ },
1303
+ {
1304
+ value: 'Cuba',
1305
+ label: 'Cuba'
1306
+ },
1307
+ {
1308
+ value: 'Curaçao',
1309
+ label: 'Curaçao'
1310
+ },
1311
+ {
1312
+ value: 'Cyprus',
1313
+ label: 'Cyprus'
1314
+ },
1315
+ {
1316
+ value: 'Czechia',
1317
+ label: 'Czechia'
1318
+ },
1319
+ {
1320
+ value: "Côte d'Ivoire",
1321
+ label: "Côte d'Ivoire"
1322
+ },
1323
+ {
1324
+ value: 'Denmark',
1325
+ label: 'Denmark'
1326
+ },
1327
+ {
1328
+ value: 'Djibouti',
1329
+ label: 'Djibouti'
1330
+ },
1331
+ {
1332
+ value: 'Dominica',
1333
+ label: 'Dominica'
1334
+ },
1335
+ {
1336
+ value: 'Dominican Republic',
1337
+ label: 'Dominican Republic'
1338
+ },
1339
+ {
1340
+ value: 'Ecuador',
1341
+ label: 'Ecuador'
1342
+ },
1343
+ {
1344
+ value: 'Egypt',
1345
+ label: 'Egypt'
1346
+ },
1347
+ {
1348
+ value: 'El Salvador',
1349
+ label: 'El Salvador'
1350
+ },
1351
+ {
1352
+ value: 'Equatorial Guinea',
1353
+ label: 'Equatorial Guinea'
1354
+ },
1355
+ {
1356
+ value: 'Eritrea',
1357
+ label: 'Eritrea'
1358
+ },
1359
+ {
1360
+ value: 'Estonia',
1361
+ label: 'Estonia'
1362
+ },
1363
+ {
1364
+ value: 'Ethiopia',
1365
+ label: 'Ethiopia'
1366
+ },
1367
+ {
1368
+ value: 'Falkland Islands (Malvinas)',
1369
+ label: 'Falkland Islands (Malvinas)'
1370
+ },
1371
+ {
1372
+ value: 'Faroe Islands',
1373
+ label: 'Faroe Islands'
1374
+ },
1375
+ {
1376
+ value: 'Fiji',
1377
+ label: 'Fiji'
1378
+ },
1379
+ {
1380
+ value: 'Finland',
1381
+ label: 'Finland'
1382
+ },
1383
+ {
1384
+ value: 'France',
1385
+ label: 'France'
1386
+ },
1387
+ {
1388
+ value: 'French Guiana',
1389
+ label: 'French Guiana'
1390
+ },
1391
+ {
1392
+ value: 'French Polynesia',
1393
+ label: 'French Polynesia'
1394
+ },
1395
+ {
1396
+ value: 'French Southern Territories',
1397
+ label: 'French Southern Territories'
1398
+ },
1399
+ {
1400
+ value: 'Gabon',
1401
+ label: 'Gabon'
1402
+ },
1403
+ {
1404
+ value: 'Gambia',
1405
+ label: 'Gambia'
1406
+ },
1407
+ {
1408
+ value: 'Georgia',
1409
+ label: 'Georgia'
1410
+ },
1411
+ {
1412
+ value: 'Germany',
1413
+ label: 'Germany'
1414
+ },
1415
+ {
1416
+ value: 'Ghana',
1417
+ label: 'Ghana'
1418
+ },
1419
+ {
1420
+ value: 'Gibraltar',
1421
+ label: 'Gibraltar'
1422
+ },
1423
+ {
1424
+ value: 'Greece',
1425
+ label: 'Greece'
1426
+ },
1427
+ {
1428
+ value: 'Greenland',
1429
+ label: 'Greenland'
1430
+ },
1431
+ {
1432
+ value: 'Grenada',
1433
+ label: 'Grenada'
1434
+ },
1435
+ {
1436
+ value: 'Guadeloupe',
1437
+ label: 'Guadeloupe'
1438
+ },
1439
+ {
1440
+ value: 'Guam',
1441
+ label: 'Guam'
1442
+ },
1443
+ {
1444
+ value: 'Guatemala',
1445
+ label: 'Guatemala'
1446
+ },
1447
+ {
1448
+ value: 'Guernsey',
1449
+ label: 'Guernsey'
1450
+ },
1451
+ {
1452
+ value: 'Guinea',
1453
+ label: 'Guinea'
1454
+ },
1455
+ {
1456
+ value: 'Guinea-Bissau',
1457
+ label: 'Guinea-Bissau'
1458
+ },
1459
+ {
1460
+ value: 'Guyana',
1461
+ label: 'Guyana'
1462
+ },
1463
+ {
1464
+ value: 'Haiti',
1465
+ label: 'Haiti'
1466
+ },
1467
+ {
1468
+ value: 'Heard Island and McDonald Islands',
1469
+ label: 'Heard Island and McDonald Islands'
1470
+ },
1471
+ {
1472
+ value: 'Holy See',
1473
+ label: 'Holy See'
1474
+ },
1475
+ {
1476
+ value: 'Honduras',
1477
+ label: 'Honduras'
1478
+ },
1479
+ {
1480
+ value: 'Hong Kong',
1481
+ label: 'Hong Kong'
1482
+ },
1483
+ {
1484
+ value: 'Hungary',
1485
+ label: 'Hungary'
1486
+ },
1487
+ {
1488
+ value: 'Iceland',
1489
+ label: 'Iceland'
1490
+ },
1491
+ {
1492
+ value: 'India',
1493
+ label: 'India'
1494
+ },
1495
+ {
1496
+ value: 'Indonesia',
1497
+ label: 'Indonesia'
1498
+ },
1499
+ {
1500
+ value: 'Iran (Islamic Republic of)',
1501
+ label: 'Iran (Islamic Republic of)'
1502
+ },
1503
+ {
1504
+ value: 'Iraq',
1505
+ label: 'Iraq'
1506
+ },
1507
+ {
1508
+ value: 'Ireland',
1509
+ label: 'Ireland'
1510
+ },
1511
+ {
1512
+ value: 'Isle of Man',
1513
+ label: 'Isle of Man'
1514
+ },
1515
+ {
1516
+ value: 'Israel',
1517
+ label: 'Israel'
1518
+ },
1519
+ {
1520
+ value: 'Italy',
1521
+ label: 'Italy'
1522
+ },
1523
+ {
1524
+ value: 'Jamaica',
1525
+ label: 'Jamaica'
1526
+ },
1527
+ {
1528
+ value: 'Japan',
1529
+ label: 'Japan'
1530
+ },
1531
+ {
1532
+ value: 'Jersey',
1533
+ label: 'Jersey'
1534
+ },
1535
+ {
1536
+ value: 'Jordan',
1537
+ label: 'Jordan'
1538
+ },
1539
+ {
1540
+ value: 'Kazakhstan',
1541
+ label: 'Kazakhstan'
1542
+ },
1543
+ {
1544
+ value: 'Kenya',
1545
+ label: 'Kenya'
1546
+ },
1547
+ {
1548
+ value: 'Kiribati',
1549
+ label: 'Kiribati'
1550
+ },
1551
+ {
1552
+ value: "Korea (Democratic People's Republic of)",
1553
+ label: "Korea (Democratic People's Republic of)"
1554
+ },
1555
+ {
1556
+ value: 'Korea (Republic of)',
1557
+ label: 'Korea (Republic of)'
1558
+ },
1559
+ {
1560
+ value: 'Kuwait',
1561
+ label: 'Kuwait'
1562
+ },
1563
+ {
1564
+ value: 'Kyrgyzstan',
1565
+ label: 'Kyrgyzstan'
1566
+ },
1567
+ {
1568
+ value: "Lao People's Democratic Republic",
1569
+ label: "Lao People's Democratic Republic"
1570
+ },
1571
+ {
1572
+ value: 'Latvia',
1573
+ label: 'Latvia'
1574
+ },
1575
+ {
1576
+ value: 'Lebanon',
1577
+ label: 'Lebanon'
1578
+ },
1579
+ {
1580
+ value: 'Lesotho',
1581
+ label: 'Lesotho'
1582
+ },
1583
+ {
1584
+ value: 'Liberia',
1585
+ label: 'Liberia'
1586
+ },
1587
+ {
1588
+ value: 'Libya',
1589
+ label: 'Libya'
1590
+ },
1591
+ {
1592
+ value: 'Liechtenstein',
1593
+ label: 'Liechtenstein'
1594
+ },
1595
+ {
1596
+ value: 'Lithuania',
1597
+ label: 'Lithuania'
1598
+ },
1599
+ {
1600
+ value: 'Luxembourg',
1601
+ label: 'Luxembourg'
1602
+ },
1603
+ {
1604
+ value: 'Macao',
1605
+ label: 'Macao'
1606
+ },
1607
+ {
1608
+ value: 'Macedonia (the former Yugoslav Republic of)',
1609
+ label: 'Macedonia (the former Yugoslav Republic of)'
1610
+ },
1611
+ {
1612
+ value: 'Madagascar',
1613
+ label: 'Madagascar'
1614
+ },
1615
+ {
1616
+ value: 'Malawi',
1617
+ label: 'Malawi'
1618
+ },
1619
+ {
1620
+ value: 'Malaysia',
1621
+ label: 'Malaysia'
1622
+ },
1623
+ {
1624
+ value: 'Maldives',
1625
+ label: 'Maldives'
1626
+ },
1627
+ {
1628
+ value: 'Mali',
1629
+ label: 'Mali'
1630
+ },
1631
+ {
1632
+ value: 'Malta',
1633
+ label: 'Malta'
1634
+ },
1635
+ {
1636
+ value: 'Marshall Islands',
1637
+ label: 'Marshall Islands'
1638
+ },
1639
+ {
1640
+ value: 'Martinique',
1641
+ label: 'Martinique'
1642
+ },
1643
+ {
1644
+ value: 'Mauritania',
1645
+ label: 'Mauritania'
1646
+ },
1647
+ {
1648
+ value: 'Mauritius',
1649
+ label: 'Mauritius'
1650
+ },
1651
+ {
1652
+ value: 'Mayotte',
1653
+ label: 'Mayotte'
1654
+ },
1655
+ {
1656
+ value: 'Mexico',
1657
+ label: 'Mexico'
1658
+ },
1659
+ {
1660
+ value: 'Micronesia (Federated States of)',
1661
+ label: 'Micronesia (Federated States of)'
1662
+ },
1663
+ {
1664
+ value: 'Moldova (Republic of)',
1665
+ label: 'Moldova (Republic of)'
1666
+ },
1667
+ {
1668
+ value: 'Monaco',
1669
+ label: 'Monaco'
1670
+ },
1671
+ {
1672
+ value: 'Mongolia',
1673
+ label: 'Mongolia'
1674
+ },
1675
+ {
1676
+ value: 'Montenegro',
1677
+ label: 'Montenegro'
1678
+ },
1679
+ {
1680
+ value: 'Montserrat',
1681
+ label: 'Montserrat'
1682
+ },
1683
+ {
1684
+ value: 'Morocco',
1685
+ label: 'Morocco'
1686
+ },
1687
+ {
1688
+ value: 'Mozambique',
1689
+ label: 'Mozambique'
1690
+ },
1691
+ {
1692
+ value: 'Myanmar',
1693
+ label: 'Myanmar'
1694
+ },
1695
+ {
1696
+ value: 'Namibia',
1697
+ label: 'Namibia'
1698
+ },
1699
+ {
1700
+ value: 'Nauru',
1701
+ label: 'Nauru'
1702
+ },
1703
+ {
1704
+ value: 'Nepal',
1705
+ label: 'Nepal'
1706
+ },
1707
+ {
1708
+ value: 'Netherlands',
1709
+ label: 'Netherlands'
1710
+ },
1711
+ {
1712
+ value: 'New Caledonia',
1713
+ label: 'New Caledonia'
1714
+ },
1715
+ {
1716
+ value: 'New Zealand',
1717
+ label: 'New Zealand'
1718
+ },
1719
+ {
1720
+ value: 'Nicaragua',
1721
+ label: 'Nicaragua'
1722
+ },
1723
+ {
1724
+ value: 'Niger',
1725
+ label: 'Niger'
1726
+ },
1727
+ {
1728
+ value: 'Nigeria',
1729
+ label: 'Nigeria'
1730
+ },
1731
+ {
1732
+ value: 'Niue',
1733
+ label: 'Niue'
1734
+ },
1735
+ {
1736
+ value: 'Norfolk Island',
1737
+ label: 'Norfolk Island'
1738
+ },
1739
+ {
1740
+ value: 'Northern Mariana Islands',
1741
+ label: 'Northern Mariana Islands'
1742
+ },
1743
+ {
1744
+ value: 'Norway',
1745
+ label: 'Norway'
1746
+ },
1747
+ {
1748
+ value: 'Oman',
1749
+ label: 'Oman'
1750
+ },
1751
+ {
1752
+ value: 'Pakistan',
1753
+ label: 'Pakistan'
1754
+ },
1755
+ {
1756
+ value: 'Palau',
1757
+ label: 'Palau'
1758
+ },
1759
+ {
1760
+ value: 'Palestine, State of',
1761
+ label: 'Palestine, State of'
1762
+ },
1763
+ {
1764
+ value: 'Panama',
1765
+ label: 'Panama'
1766
+ },
1767
+ {
1768
+ value: 'Papua New Guinea',
1769
+ label: 'Papua New Guinea'
1770
+ },
1771
+ {
1772
+ value: 'Paraguay',
1773
+ label: 'Paraguay'
1774
+ },
1775
+ {
1776
+ value: 'Peru',
1777
+ label: 'Peru'
1778
+ },
1779
+ {
1780
+ value: 'Philippines',
1781
+ label: 'Philippines'
1782
+ },
1783
+ {
1784
+ value: 'Pitcairn',
1785
+ label: 'Pitcairn'
1786
+ },
1787
+ {
1788
+ value: 'Poland',
1789
+ label: 'Poland'
1790
+ },
1791
+ {
1792
+ value: 'Portugal',
1793
+ label: 'Portugal'
1794
+ },
1795
+ {
1796
+ value: 'Puerto Rico',
1797
+ label: 'Puerto Rico'
1798
+ },
1799
+ {
1800
+ value: 'Qatar',
1801
+ label: 'Qatar'
1802
+ },
1803
+ {
1804
+ value: 'Romania',
1805
+ label: 'Romania'
1806
+ },
1807
+ {
1808
+ value: 'Russian Federation',
1809
+ label: 'Russian Federation'
1810
+ },
1811
+ {
1812
+ value: 'Rwanda',
1813
+ label: 'Rwanda'
1814
+ },
1815
+ {
1816
+ value: 'Réunion',
1817
+ label: 'Réunion'
1818
+ },
1819
+ {
1820
+ value: 'Saint Barthélemy',
1821
+ label: 'Saint Barthélemy'
1822
+ },
1823
+ {
1824
+ value: 'Saint Helena, Ascension and Tristan da Cunha',
1825
+ label: 'Saint Helena, Ascension and Tristan da Cunha'
1826
+ },
1827
+ {
1828
+ value: 'Saint Kitts and Nevis',
1829
+ label: 'Saint Kitts and Nevis'
1830
+ },
1831
+ {
1832
+ value: 'Saint Lucia',
1833
+ label: 'Saint Lucia'
1834
+ },
1835
+ {
1836
+ value: 'Saint Martin (French part)',
1837
+ label: 'Saint Martin (French part)'
1838
+ },
1839
+ {
1840
+ value: 'Saint Pierre and Miquelon',
1841
+ label: 'Saint Pierre and Miquelon'
1842
+ },
1843
+ {
1844
+ value: 'Saint Vincent and the Grenadines',
1845
+ label: 'Saint Vincent and the Grenadines'
1846
+ },
1847
+ {
1848
+ value: 'Samoa',
1849
+ label: 'Samoa'
1850
+ },
1851
+ {
1852
+ value: 'San Marino',
1853
+ label: 'San Marino'
1854
+ },
1855
+ {
1856
+ value: 'Sao Tome and Principe',
1857
+ label: 'Sao Tome and Principe'
1858
+ },
1859
+ {
1860
+ value: 'Saudi Arabia',
1861
+ label: 'Saudi Arabia'
1862
+ },
1863
+ {
1864
+ value: 'Senegal',
1865
+ label: 'Senegal'
1866
+ },
1867
+ {
1868
+ value: 'Serbia',
1869
+ label: 'Serbia'
1870
+ },
1871
+ {
1872
+ value: 'Seychelles',
1873
+ label: 'Seychelles'
1874
+ },
1875
+ {
1876
+ value: 'Sierra Leone',
1877
+ label: 'Sierra Leone'
1878
+ },
1879
+ {
1880
+ value: 'Singapore',
1881
+ label: 'Singapore'
1882
+ },
1883
+ {
1884
+ value: 'Sint Maarten (Dutch part)',
1885
+ label: 'Sint Maarten (Dutch part)'
1886
+ },
1887
+ {
1888
+ value: 'Slovakia',
1889
+ label: 'Slovakia'
1890
+ },
1891
+ {
1892
+ value: 'Slovenia',
1893
+ label: 'Slovenia'
1894
+ },
1895
+ {
1896
+ value: 'Solomon Islands',
1897
+ label: 'Solomon Islands'
1898
+ },
1899
+ {
1900
+ value: 'Somalia',
1901
+ label: 'Somalia'
1902
+ },
1903
+ {
1904
+ value: 'South Africa',
1905
+ label: 'South Africa'
1906
+ },
1907
+ {
1908
+ value: 'South Georgia and the South Sandwich Islands',
1909
+ label: 'South Georgia and the South Sandwich Islands'
1910
+ },
1911
+ {
1912
+ value: 'South Sudan',
1913
+ label: 'South Sudan'
1914
+ },
1915
+ {
1916
+ value: 'Spain',
1917
+ label: 'Spain'
1918
+ },
1919
+ {
1920
+ value: 'Sri Lanka',
1921
+ label: 'Sri Lanka'
1922
+ },
1923
+ {
1924
+ value: 'Sudan',
1925
+ label: 'Sudan'
1926
+ },
1927
+ {
1928
+ value: 'Suriname',
1929
+ label: 'Suriname'
1930
+ },
1931
+ {
1932
+ value: 'Svalbard and Jan Mayen',
1933
+ label: 'Svalbard and Jan Mayen'
1934
+ },
1935
+ {
1936
+ value: 'Swaziland',
1937
+ label: 'Swaziland'
1938
+ },
1939
+ {
1940
+ value: 'Sweden',
1941
+ label: 'Sweden'
1942
+ },
1943
+ {
1944
+ value: 'Switzerland',
1945
+ label: 'Switzerland'
1946
+ },
1947
+ {
1948
+ value: 'Syrian Arab Republic',
1949
+ label: 'Syrian Arab Republic'
1950
+ },
1951
+ {
1952
+ value: 'Taiwan Republic of China',
1953
+ label: 'Taiwan Republic of China'
1954
+ },
1955
+ {
1956
+ value: 'Tajikistan',
1957
+ label: 'Tajikistan'
1958
+ },
1959
+ {
1960
+ value: 'Tanzania, United Republic of',
1961
+ label: 'Tanzania, United Republic of'
1962
+ },
1963
+ {
1964
+ value: 'Thailand',
1965
+ label: 'Thailand'
1966
+ },
1967
+ {
1968
+ value: 'Timor-Leste',
1969
+ label: 'Timor-Leste'
1970
+ },
1971
+ {
1972
+ value: 'Togo',
1973
+ label: 'Togo'
1974
+ },
1975
+ {
1976
+ value: 'Tokelau',
1977
+ label: 'Tokelau'
1978
+ },
1979
+ {
1980
+ value: 'Tonga',
1981
+ label: 'Tonga'
1982
+ },
1983
+ {
1984
+ value: 'Trinidad and Tobago',
1985
+ label: 'Trinidad and Tobago'
1986
+ },
1987
+ {
1988
+ value: 'Tunisia',
1989
+ label: 'Tunisia'
1990
+ },
1991
+ {
1992
+ value: 'Turkey',
1993
+ label: 'Turkey'
1994
+ },
1995
+ {
1996
+ value: 'Turkmenistan',
1997
+ label: 'Turkmenistan'
1998
+ },
1999
+ {
2000
+ value: 'Turks and Caicos Islands',
2001
+ label: 'Turks and Caicos Islands'
2002
+ },
2003
+ {
2004
+ value: 'Tuvalu',
2005
+ label: 'Tuvalu'
2006
+ },
2007
+ {
2008
+ value: 'Uganda',
2009
+ label: 'Uganda'
2010
+ },
2011
+ {
2012
+ value: 'Ukraine',
2013
+ label: 'Ukraine'
2014
+ },
2015
+ {
2016
+ value: 'United Arab Emirates',
2017
+ label: 'United Arab Emirates'
2018
+ },
2019
+ {
2020
+ value: 'United Kingdom of Great Britain and Northern Ireland',
2021
+ label: 'United Kingdom of Great Britain and Northern Ireland'
2022
+ },
2023
+ {
2024
+ value: 'United States Minor Outlying Islands',
2025
+ label: 'United States Minor Outlying Islands'
2026
+ },
2027
+ {
2028
+ value: 'United States of America',
2029
+ label: 'United States of America'
2030
+ },
2031
+ {
2032
+ value: 'Uruguay',
2033
+ label: 'Uruguay'
2034
+ },
2035
+ {
2036
+ value: 'Uzbekistan',
2037
+ label: 'Uzbekistan'
2038
+ },
2039
+ {
2040
+ value: 'Vanuatu',
2041
+ label: 'Vanuatu'
2042
+ },
2043
+ {
2044
+ value: 'Venezuela (Bolivarian Republic of)',
2045
+ label: 'Venezuela (Bolivarian Republic of)'
2046
+ },
2047
+ {
2048
+ value: 'Vietnam',
2049
+ label: 'Vietnam'
2050
+ },
2051
+ {
2052
+ value: 'Virgin Islands (British)',
2053
+ label: 'Virgin Islands (British)'
2054
+ },
2055
+ {
2056
+ value: 'Virgin Islands (U.S.)',
2057
+ label: 'Virgin Islands (U.S.)'
2058
+ },
2059
+ {
2060
+ value: 'Wallis and Futuna',
2061
+ label: 'Wallis and Futuna'
2062
+ },
2063
+ {
2064
+ value: 'Western Sahara',
2065
+ label: 'Western Sahara'
2066
+ },
2067
+ {
2068
+ value: 'Yemen',
2069
+ label: 'Yemen'
2070
+ },
2071
+ {
2072
+ value: 'Zambia',
2073
+ label: 'Zambia'
2074
+ },
2075
+ {
2076
+ value: 'Zimbabwe',
2077
+ label: 'Zimbabwe'
2078
+ },
2079
+ {
2080
+ value: 'Åland Islands',
2081
+ label: 'Åland Islands'
2082
+ }
2083
+ ];
2084
+
2085
+ };
2086
+ static get_states = () =>{
2087
+ return [
2088
+ {
2089
+ label: "Other",
2090
+ value: "Other"
2091
+ },
2092
+ { label: "Alaska", value: "Alaska" },
2093
+ { label: "Alabama", value: "Alabama" },
2094
+ { label: "Arkansas", value: "Arkansas" },
2095
+ { label: "Arizona", value: "Arizona" },
2096
+ { label: "California", value: "California" },
2097
+ { label: "Colorado", value: "Colorado" },
2098
+ { label: "Connecticut", value: "Connecticut" },
2099
+ { label: "District of Columbia", value: "District of Columbia" },
2100
+ { label: "Delaware", value: "Delaware" },
2101
+ { label: "Florida", value: "Florida" },
2102
+ { label: "Georgia", value: "Georgia" },
2103
+ { label: "Hawaii", value: "Hawaii" },
2104
+ { label: "Iowa", value: "Iowa" },
2105
+ { label: "Idaho", value: "Idaho" },
2106
+ { label: "IL", value: "Illinois" },
2107
+ { label: "Illinois", value: "Indiana" },
2108
+ { label: "Kansas", value: "Kansas" },
2109
+ { label: "Kentucky", value: "Kentucky" },
2110
+ { label: "Louisiana", value: "Louisiana" },
2111
+ { label: "Massachusetts", value: "Massachusetts" },
2112
+ { label: "Maryland", value: "Maryland" },
2113
+ { label: "Maine", value: "Maine" },
2114
+ { label: "Michigan", value: "Michigan" },
2115
+ { label: "Minnesota", value: "Minnesota" },
2116
+ { label: "Missouri", value: "Missouri" },
2117
+ { label: "Mississippi", value: "Mississippi" },
2118
+ { label: "Montana", value: "Montana" },
2119
+ { label: "North Carolina", value: "North Carolina" },
2120
+ { label: "North Dakota", value: "North Dakota" },
2121
+ { label: "Nebraska", value: "Nebraska" },
2122
+ { label: "New Hampshire", value: "New Hampshire" },
2123
+ { label: "New Jersey", value: "New Jersey" },
2124
+ { label: "New Mexico", value: "New Mexico" },
2125
+ { label: "Nevada", value: "Nevada" },
2126
+ { label: "New York", value: "NewYork" },
2127
+ { label: "Ohio", value: "Ohio" },
2128
+ { label: "Oklahoma", value: "Oklahoma" },
2129
+ { label: "Oregon", value: "Oregon" },
2130
+ { label: "Pennsylvania", value: "Pennsylvania" },
2131
+ { label: "Rhode Island", value: "Rhode Island" },
2132
+ { label: "South Carolina", value: "South Carolina" },
2133
+ { label: "South Dakota", value: "South Dakota" },
2134
+ { label: "Tennessee", value: "Tennessee" },
2135
+ { label: "Texas", value: "Texas" },
2136
+ { label: "Utah", value: "Utah" },
2137
+ { label: "Virginia", value: "Virginia" },
2138
+ { label: "Vermont", value: "Vermont" },
2139
+ { label: "Washington", value: "Washington" },
2140
+ { label: "Wisconsin", value: "Wisconsin" },
2141
+ { label: "West Virginia", value: "West Virginia" },
2142
+ { label: "Wyoming", value: "Wyoming" },
2143
+ ];
2144
+ }
1062
2145
  }
1063
2146
  class Data_Logic {
1064
2147
  static get_new = (data_type,id,option) => {
1065
2148
  return Data_Logic.get(data_type,id,option);
1066
2149
  };
1067
- // --> options / test / test_blank / title / generate_title / count
2150
+ // --> option = / test / blank / title / generate_title / count / data
1068
2151
  static get = (data_type,id,option) => {
2152
+ option = option ? option : {};
1069
2153
  function get_test_data(data_type){
1070
2154
  switch(data_type)
1071
2155
  {
@@ -1081,11 +2165,14 @@ class Data_Logic {
1081
2165
  case Type.DATA_PRODUCT:
1082
2166
  return Product_Logic.get_test();
1083
2167
  break;
2168
+ case Type.DATA_REVIEW:
2169
+ return Review_Logic.get_test();
2170
+ break;
1084
2171
  case Type.DATA_CONTENT:
1085
2172
  case Type.DATA_CATEGORY:
1086
2173
  case Type.DATA_BLANK:
1087
2174
  return Blank_Logic.get_test();
1088
- break;
2175
+ break;
1089
2176
  case Type.DATA_USER:
1090
2177
  return User_Logic.get_test();
1091
2178
  break;
@@ -1094,13 +2181,22 @@ class Data_Logic {
1094
2181
  break;
1095
2182
  }
1096
2183
  }
1097
- let data = {data_type:data_type,id:id};
2184
+ let data = null;
2185
+ if(option.count>1){
2186
+ data = [];
2187
+ }else{
2188
+ data = {data_type:data_type,id:id};
2189
+ }
1098
2190
  option = option ? option : {count:0};
1099
2191
  data = Field_Logic.get_base_option(data,option);
1100
2192
  if(option.test){
1101
2193
  data = Obj.merge(get_test_data(data_type),data);
1102
2194
  }
1103
- if(option.test_blank){
2195
+ if(option.title){
2196
+ data[Type.FIELD_TITLE] = option.title;
2197
+ data[Type.FIELD_TITLE_URL] = Str.get_title_url(option.title);
2198
+ }
2199
+ if(option.blank){
1104
2200
  for(const field in data){
1105
2201
  if(field != Type.FIELD_ID && field != Type.FIELD_DATA_TYPE){
1106
2202
  data[field] = '';
@@ -1114,6 +2210,9 @@ class Data_Logic {
1114
2210
  let test_data = Obj.merge(data,get_test_data(data.data_type));
1115
2211
  test_data[Type.FIELD_TITLE] = my_title;
1116
2212
  test_data[Type.FIELD_TITLE_URL] = Str.get_title_url(my_title);
2213
+ if(option.data){
2214
+ test_data = Obj.merge(test_data,option.data);
2215
+ }
1117
2216
  items.push(test_data);
1118
2217
  }
1119
2218
  data = items;
@@ -1204,7 +2303,7 @@ class Data_Logic {
1204
2303
  foreign_data_type = foreign_data_type ? foreign_data_type : Str.get_title_url(Data_Logic.get_data_type_by_type(foreign_data_type,{plural:true}));
1205
2304
  foreign_field = foreign_field ? foreign_field : Type.FIELD_PARENT_ID;
1206
2305
  parent_field = parent_field ? parent_field : parent_field;
1207
- let field = option.field ? option.field : {};
2306
+ let field = option.field ? option.field : null;
1208
2307
  let title = option.title ? option.title : Str.get_title_url(Data_Logic.get_data_type_by_type(foreign_data_type,{plural:true}));
1209
2308
  let page_current = option.page_current ? option.page_current : 1;
1210
2309
  let page_size = option.page_size ? option.page_size : 0;
@@ -1450,7 +2549,6 @@ class Url {
1450
2549
  static GET="main/crud/get";
1451
2550
  static LOGIN="user/login";
1452
2551
  static LOGOUT="user/logout";
1453
- static REGISTER="user/register";
1454
2552
  static PARENT_TOP="main/crud/parent_top";
1455
2553
  static PING_GET="ping_get";
1456
2554
  static PING_POST="ping_post";
@@ -1494,6 +2592,7 @@ class Url {
1494
2592
  static PAGE_PRODUCT="page/product";
1495
2593
  static PAGE_PRODUCT_HOME="page/product_home";
1496
2594
  static PAGE_PRODUCT_SEARCH="page/product_search";
2595
+ static PAGE_REGISTER="user/register";
1497
2596
  static PAGE_SERVICE="page/service";
1498
2597
  static PAGE_SERVICE_HOME="page/service_home";
1499
2598
  static PAGE_SERVICE_SEARCH="page/service_search";
@@ -1517,6 +2616,7 @@ module.exports = {
1517
2616
  Blog_Post_Logic,
1518
2617
  Cart_Logic,
1519
2618
  Category_Logic,
2619
+ Content_Logic,
1520
2620
  Data_Logic,
1521
2621
  Event_Logic,
1522
2622
  File_Logic,