You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
HMG_Patient_App/lib/models/mobile_number.dart

72 lines
1.7 KiB
Dart

// final List<Countries> countries = [
// new Countries(
// name: "Saudi Arabia", name_ar: "المملكة العربية السعودية", code: '966'),
// new Countries(
// name: "United Arab Emirates",
// name_ar: "الإمارات العربية المتحدة",
// code: '971'),
// ];
// class Countries {
// final String name;
// final String name_ar;
// final String code;
// Countries({this.name, this.name_ar, this.code});
// }
class Countries {
String? name;
String? nameAr;
String? code;
String? countryCode;
Countries({this.name, this.nameAr, this.code, this.countryCode});
Countries.fromJson(Map<String, dynamic> json) {
name = json['name'];
nameAr = json['name_ar'];
code = json['code'];
countryCode = json['countryCode'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['name'] = this.name;
data['name_ar'] = this.nameAr;
data['code'] = this.code;
data['countryCode'] = this.countryCode;
return data;
}
}
List<Map<String, dynamic>> countriesData = [
{
"name": "Saudi Arabia",
"name_ar": "المملكة العربية السعودية",
"code": "966",
"countryCode": "SA",
"pattern": "5xxxxxxxx",
"maxLength": 9
},
{
"name": "United Arab Emirates",
"name_ar": "الإمارات العربية المتحدة",
"code": "971",
"countryCode": "AE",
"pattern": "5xxxxxxxx",
"maxLength": 9
},
{
"name": "Others",
"name_ar": "أخرى",
"code": "0",
"countryCode": "OT",
"pattern": "",
"maxLength": 20
},
];
// });
// List<Countries> countryList =[];