Guest User

Untitled

a guest
Sep 16th, 2018
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Dart 100.30 KB | None | 0 0
  1. import 'package:flutter/material.dart';
  2. import 'package:image_picker/image_picker.dart';
  3. import 'dart:io';
  4. import 'dart:typed_data';
  5. import 'dart:async';
  6. import 'package:flutter/services.dart' show rootBundle;
  7. import 'package:firebase_storage/firebase_storage.dart';
  8. import 'package:cloud_firestore/cloud_firestore.dart';
  9. import 'package:doctorradar/pages/doctorslogin.dart';
  10. import 'package:doctorradar/pages/home_screen.dart';
  11. import 'package:flutter/services.dart';
  12. import 'package:location/location.dart';
  13.  
  14. final Controller = TextEditingController();
  15. final Controller1 = TextEditingController();
  16. final Controller2 = TextEditingController();
  17. final Controller3 = TextEditingController();
  18. final Controller4 = TextEditingController();
  19. final Controller5 = TextEditingController();
  20. final Controller6 = TextEditingController();
  21. String docname = Controller.text;
  22. String docfield='General Surgery';
  23. String docspecialty = Controller1.text;
  24. String docoverview = Controller2.text;
  25. String docclinicnum = Controller3.text;
  26. String doccontracted = Controller4.text;
  27. String doclocation2 = Controller5.text;
  28. String docstatus = Controller6.text;
  29. String pathfile;
  30. bool uploaded = false;
  31. String photo = 'Choose Image';
  32. double latitude;
  33. double longitude;
  34. var googlemaps;
  35.  
  36. class Submit extends StatefulWidget {
  37.   @override
  38.   SubmitState createState() {
  39.     return new SubmitState();
  40.   }
  41. }
  42.  
  43. class SubmitState extends State<Submit> {
  44.   File image;
  45.   String _path;
  46.   final CollectionReference collectionReference =
  47.       Firestore.instance.collection("");
  48.   final _formKey1 = GlobalKey<FormState>();
  49.   // location content starts here
  50.   Map<String, double> _startLocation;
  51.   Map<String, double> geolocation;
  52.  
  53.   Location _location = new Location();
  54.   bool _permission = false;
  55.   String error;
  56.  
  57.   bool currentWidget = true;
  58.  
  59.   Image image1;
  60. //location content ends here
  61.  
  62.   Future<Null> uploadFile(String filepath) async {
  63.     setState(() {
  64.       docname = Controller.text;
  65.     });
  66.  
  67.     final ByteData bytes = await rootBundle.load(filepath);
  68.     final Directory tempDir = Directory.systemTemp;
  69.     final String fileName = "$docid";
  70.     final File file = File('${tempDir.path}/$fileName');
  71.     file.writeAsBytes(bytes.buffer.asInt8List(), mode: FileMode.write);
  72.  
  73.     final StorageReference ref = FirebaseStorage.instance.ref().child(fileName);
  74.     final StorageUploadTask task = ref.putFile(file);
  75.     final Uri downloadUrl = (await task.future).downloadUrl;
  76.     setState(() {
  77.       _path = downloadUrl.toString();
  78.       uploaded = true;
  79.     });
  80.   }
  81.  
  82.   picker() async {
  83.     File img = await ImagePicker.pickImage(
  84.       source: ImageSource.gallery,
  85.     );
  86. //    File img = await ImagePicker.pickImage(source: ImageSource.gallery);
  87.     if (img != null) {
  88.       image = img;
  89.       pathfile = img.path;
  90.       uploadFile(pathfile);
  91.       setState(() {});
  92.       setState(() {
  93.         photo = "Remove Image";
  94.       });
  95.     }
  96.   }
  97.  
  98.   String _selected = "General Surgery";
  99.   void onChanged(String value) {
  100.     setState(() {
  101.       _selected = value;
  102.       docfield = value;
  103.     });
  104.   }
  105.  
  106.   bool freeappointment = false;
  107.   void changefree(bool values) {
  108.     setState(() {
  109.       freeappointment = values;
  110.     });
  111.   }
  112.  
  113.   Widget picture() {
  114.     if (image == null) {
  115.       return Icon(
  116.         Icons.account_box,
  117.         color: Colors.blue,
  118.         size: 100.0,
  119.       );
  120.     } else
  121.       return Padding(
  122.         padding: const EdgeInsets.all(8.0),
  123.         child: Image.file(image),
  124.       );
  125.   }
  126.  
  127.   void _add() {
  128.     Map<String, String> data = <String, String>{
  129.       "ID": "$docid",
  130.       "Name": "$docname",
  131.       "Field": "$docfield",
  132.       "Specialty": "$docspecialty",
  133.       "Contracted": "$doccontracted",
  134.       "Status": "$docstatus",
  135.       "Description": "$docoverview",
  136.       "Number": "$docclinicnum",
  137.       "Location": "$googlemaps",
  138.       "Location2": "$doclocation2",
  139.       "Picture": "$_path",
  140.       "Rate": "0.0",
  141.       "Rate_Number": '0.0',
  142.       "Free_Appointment": "$freeappointment"
  143.     };
  144.     collectionReference.document("Doctors/$docid").setData(data);
  145.   }
  146.  
  147.   bool hasData1 = false;
  148.   Future<bool> hasInternetConnectivity() async {
  149.     try {
  150.       final result = await InternetAddress.lookup('google.com');
  151.       if (result.isNotEmpty && result[0].rawAddress.isNotEmpty) {
  152.        
  153.         return hasData1 = true;
  154.       }
  155.     } on SocketException catch (_) {
  156.      
  157.       return hasData1 = false;
  158.     }
  159.    
  160.     return hasData1 = false;
  161.   }
  162.  
  163.   Timer time;
  164.  
  165.   @override
  166.   void initState() {
  167.     super.initState();
  168.     setState(() {
  169.       photo = 'Choose Image';
  170.     });
  171.     const oneSec = const Duration(milliseconds: 100);
  172.     time = new Timer.periodic(
  173.         oneSec,
  174.         (Timer t) => hasInternetConnectivity().whenComplete(() {
  175.               return hasData1;
  176.             }));
  177.     initPlatformState();
  178.   }
  179.  
  180.   // for location
  181.   initPlatformState() async {
  182.     // Platform messages may fail, so we use a try/catch PlatformException.
  183.  
  184.     try {
  185.       _permission = await _location.hasPermission();
  186.       geolocation = await _location.getLocation();
  187.  
  188.       error = null;
  189.     } on PlatformException catch (e) {
  190.       if (e.code == 'PERMISSION_DENIED') {
  191.         error = 'Permission denied';
  192.       } else if (e.code == 'PERMISSION_DENIED_NEVER_ASK') {
  193.         error =
  194.             'Permission denied - please ask the user to enable it from the app settings';
  195.       }
  196.       geolocation = null;
  197.     }
  198.  
  199.     // If the widget was removed from the tree while the asynchronous platform
  200.     // message was in flight, we want to discard the reply rather than calling
  201.     // setState to update our non-existent appearance.
  202.     //if (!mounted) return;
  203.   }
  204.  
  205.   @override
  206.   void dispose() {
  207.     time.cancel();
  208.     super.dispose();
  209.   }
  210.  
  211.   @override
  212.   Widget build(BuildContext context) {
  213.     final Screensize = MediaQuery.of(context).size;
  214.     return Scaffold(
  215.       floatingActionButton: new FloatingActionButton(
  216.         child: new Icon(Icons.check),
  217.         onPressed: () {
  218.           print("This is docid  $docid");
  219.           if (_formKey1.currentState.validate()) {
  220.             setState(() {
  221.               docname = Controller.text;
  222.               docspecialty = Controller1.text;
  223.               docoverview = Controller2.text;
  224.               docclinicnum = Controller3.text;
  225.               doccontracted = Controller4.text;
  226.               doclocation2 = Controller5.text;
  227.               docstatus = Controller6.text;
  228.             });
  229.             hasInternetConnectivity().whenComplete(() {
  230.               return hasData1;
  231.             });
  232.  
  233.             if (hasData1 == false) {
  234.               showModalBottomSheet<void>(
  235.                   context: context,
  236.                   builder: (BuildContext context) {
  237.                     return new Container(
  238.                         child: new Padding(
  239.                       padding: const EdgeInsets.all(32.0),
  240.                       child: new Text(
  241.                         "Please Connect to the Internet ",
  242.                         textAlign: TextAlign.center,
  243.                         style: TextStyle(
  244.                           color: Colors.red,
  245.                           fontSize: 20.0,
  246.                         ),
  247.                       ),
  248.                     ));
  249.                   });
  250.             } else if (hasData1 == true && uploaded == true) {
  251.               if (_startLocation != null) {
  252.                 _add();
  253.                 showDialog(
  254.                   context: context,
  255.                   builder: (context) => AlertDialog(
  256.                         title: new ListTile(
  257.                           title: new Text("Form Completed"),
  258.                           subtitle: new Text(
  259.                               "You are Now Registered in Doctor Radar Lists and Your Profile Will be Displayed Across All Devices.You Will Now be Navigated To the Users Page"),
  260.                         ),
  261.                         actions: <Widget>[
  262.                           FlatButton(
  263.                               onPressed: () {
  264.                                 Navigator.pop(context);
  265.                                 Navigator.push(
  266.                                   context,
  267.                                   MaterialPageRoute(
  268.                                       builder: (context) => HomeScreen()),
  269.                                 );
  270.                               },
  271.                               child: new Text("Okay"))
  272.                         ],
  273.                       ),
  274.                 );
  275.               } else if (_startLocation == null) {
  276.                 showModalBottomSheet<void>(
  277.                     context: context,
  278.                     builder: (BuildContext context) {
  279.                       return new Container(
  280.                           child: new Padding(
  281.                               padding: const EdgeInsets.all(16.0),
  282.                               child: new ListView(
  283.                                 shrinkWrap: true,
  284.                                 children: <Widget>[
  285.                                   new Text(
  286.                                     "Please press the Get Location button to automatically grab the location of your clinic, otherwise you will not be"
  287.                                         " able to complete the form and register in Doctor Radar.If you are pressing the location button and nothing is happening,"
  288.                                         ' this means that you have disabled the location permissions for Doctor Radar, press the info button to see how to enable it.',
  289.                                     textAlign: TextAlign.center,
  290.                                     style: TextStyle(
  291.                                       color: Colors.red,
  292.                                       fontSize: 16.0,
  293.                                     ),
  294.                                   ),
  295.                                   new IconButton(
  296.                                     icon: Icon(
  297.                                       Icons.info,
  298.                                       color: Colors.blue,
  299.                                     ),
  300.                                     onPressed: () {
  301.                                       Navigator.pop(context);
  302.                                       showDialog(
  303.                                         context: context,
  304.                                         builder: (context) => AlertDialog(
  305.                                               title: new ListTile(
  306.                                                 title: new Text(
  307.                                                     "Enable Permissions"),
  308.                                                 subtitle: new Text(
  309.                                                     "Go to settings >> Apps >> Doctor Radar >> Permissions >> Enable Location"),
  310.                                               ),
  311.                                               actions: <Widget>[
  312.                                                 FlatButton(
  313.                                                     onPressed: () {
  314.                                                       Navigator.pop(context);
  315.                                                     },
  316.                                                     child: new Text("Okay"))
  317.                                               ],
  318.                                             ),
  319.                                       );
  320.                                     },
  321.                                   )
  322.                                 ],
  323.                               )));
  324.                     });
  325.               }
  326.             } else if (hasData1 == true && uploaded == false) {
  327.               showModalBottomSheet<void>(
  328.                   context: context,
  329.                   builder: (BuildContext context) {
  330.                     return new Container(
  331.                         child: new Padding(
  332.                       padding: const EdgeInsets.all(32.0),
  333.                       child: new Text(
  334.                         "You Did Not Upload an Image Yet ",
  335.                         textAlign: TextAlign.center,
  336.                         style: TextStyle(
  337.                           color: Colors.red,
  338.                           fontSize: 20.0,
  339.                         ),
  340.                       ),
  341.                     ));
  342.                   });
  343.             }
  344.           } else {
  345.             showModalBottomSheet<void>(
  346.                 context: context,
  347.                 builder: (BuildContext context) {
  348.                   return new Container(
  349.                       child: new Padding(
  350.                     padding: const EdgeInsets.all(32.0),
  351.                     child: new Text(
  352.                       "Please Check Your Form Again",
  353.                       textAlign: TextAlign.center,
  354.                       style: TextStyle(
  355.                         color: Colors.red,
  356.                         fontSize: 20.0,
  357.                       ),
  358.                     ),
  359.                   ));
  360.                 });
  361.           }
  362.         },
  363.       ),
  364.       appBar: new AppBar(
  365.         title: new Text("Submit Your Credentials"),
  366.       ),
  367.       body: new Container(
  368.         child: Form(
  369.           key: _formKey1,
  370.           child: ListView(
  371.             scrollDirection: Axis.vertical,
  372.             children: <Widget>[
  373.               Center(
  374.                 child: Container(
  375.                   child: Card(
  376.                     child: Column(
  377.                       crossAxisAlignment: CrossAxisAlignment.center,
  378.                       mainAxisAlignment: MainAxisAlignment.center,
  379.                       children: <Widget>[
  380.                         picture(),
  381.                         Padding(
  382.                           padding: const EdgeInsets.all(12.0),
  383.                           child: Text("Enter Your Full Name:",
  384.                               style: TextStyle(
  385.                                   fontSize: 20.0, color: Colors.blue)),
  386.                         ),
  387.                         Padding(
  388.                           padding: const EdgeInsets.all(12.0),
  389.                           child: TextFormField(
  390.                             validator: (value) {
  391.                               if (value.startsWith(' ')) {
  392.                                 return 'Do not start Your Name with spaces';
  393.                               } else if (value.isEmpty) {
  394.                                 return 'Please Enter Your Name';
  395.                               }
  396.                             },
  397.                             keyboardType: TextInputType.multiline,
  398.                             maxLines: null,
  399.                             autofocus: false,
  400.                             decoration: InputDecoration(
  401.                               hintText: 'Full Name',
  402.                               contentPadding:
  403.                                   EdgeInsets.fromLTRB(20.0, 10.0, 20.0, 10.0),
  404.                               border: OutlineInputBorder(
  405.                                   borderRadius: BorderRadius.circular(32.0)),
  406.                             ),
  407.                             controller: Controller,
  408.                           ),
  409.                         ),
  410.                         Column(
  411.                           children: <Widget>[
  412.                             Padding(
  413.                               padding: const EdgeInsets.all(8.0),
  414.                               child: Text(
  415.                                 "Upload Profile Picture",
  416.                                 style: TextStyle(
  417.                                     fontSize: 20.0, color: Colors.blue),
  418.                               ),
  419.                             ),
  420.                             ButtonBar(
  421.                               mainAxisSize: MainAxisSize.min,
  422.                               children: <Widget>[
  423.                                 new RaisedButton(
  424.                                   color: Colors.blue,
  425.                                   child: Text(
  426.                                     "$photo",
  427.                                     style: TextStyle(color: Colors.white),
  428.                                   ),
  429.                                   onPressed: () {
  430.                                     if (photo == 'Choose Image') {
  431.                                       picker();
  432.                                     } else if (photo == "Remove Image") {
  433.                                       setState(() {
  434.                                         image = null;
  435.                                         uploaded = false;
  436.                                         photo = 'Choose Image';
  437.                                         print(docname);
  438.                                       });
  439.                                     }
  440.                                   },
  441.                                 ),
  442.                               ],
  443.                             ),
  444.                           ],
  445.                         ),
  446.                       ],
  447.                     ),
  448.                   ),
  449.                   margin: EdgeInsets.only(left: 10.0, right: 5.0, top: 10.0),
  450.                 ),
  451.               ),
  452.               Stack(
  453.                 children: <Widget>[
  454.                   new Container(),
  455.                   Center(
  456.                     child: Container(
  457.                       child: Card(
  458.                         child: Column(
  459.                           crossAxisAlignment: CrossAxisAlignment.center,
  460.                           mainAxisAlignment: MainAxisAlignment.center,
  461.                           children: <Widget>[
  462.                             new Icon(
  463.                               Icons.assignment,
  464.                               color: Colors.blue,
  465.                               size: 80.0,
  466.                             ),
  467.                             Padding(
  468.                               padding: const EdgeInsets.all(12.0),
  469.                               child: Text("Choose Your Major Among The List:",
  470.                                   textAlign: TextAlign.center,
  471.                                   style: TextStyle(
  472.                                       fontSize: 20.0, color: Colors.blue)),
  473.                             ),
  474.                             Container(
  475.                               height: Screensize.height / 3,
  476.                               child: SingleChildScrollView(
  477.                                 scrollDirection: Axis.vertical,
  478.                                 child: Stack(
  479.                                   children: <Widget>[
  480.                                     Container(),
  481.                                     new Column(
  482.                                       children: <Widget>[
  483.                                         new ListTile(
  484.                                             leading: new Text(
  485.                                           "surgery majors",
  486.                                           textAlign: TextAlign.start,
  487.                                           style: TextStyle(
  488.                                             fontSize: 25.0,
  489.                                             color: Colors.red,
  490.                                           ),
  491.                                         )),
  492.                                         new RadioListTile(
  493.                                             title: new Text(
  494.                                               "General Surgery",
  495.                                               style: TextStyle(
  496.                                                   fontWeight: FontWeight.bold),
  497.                                             ),
  498.                                             value: 'General Surgery',
  499.                                             groupValue: _selected,
  500.                                             onChanged: (String value) {
  501.                                               onChanged(value);
  502.                                             }),
  503.                                         new RadioListTile(
  504.                                             title: new Text(
  505.                                               "Head & Neck Surgery",
  506.                                               style: TextStyle(
  507.                                                   fontWeight: FontWeight.bold),
  508.                                             ),
  509.                                             value: 'Head & Neck Surgery',
  510.                                             groupValue: _selected,
  511.                                             onChanged: (String value) {
  512.                                               onChanged(value);
  513.                                             }),
  514.                                         new RadioListTile(
  515.                                             title: new Text(
  516.                                               "Plastic & Reconstructive Surgery",
  517.                                               style: TextStyle(
  518.                                                   fontWeight: FontWeight.bold),
  519.                                             ),
  520.                                             value:
  521.                                                 'Plastic & Reconstructive Surgery',
  522.                                             groupValue: _selected,
  523.                                             onChanged: (String value) {
  524.                                               onChanged(value);
  525.                                             }),
  526.                                         new RadioListTile(
  527.                                             title: new Text(
  528.                                               "Plastic & Maxillofacial Surgery",
  529.                                               style: TextStyle(
  530.                                                   fontWeight: FontWeight.bold),
  531.                                             ),
  532.                                             value:
  533.                                                 'Plastic & Maxillofacial Surgery',
  534.                                             groupValue: _selected,
  535.                                             onChanged: (String value) {
  536.                                               onChanged(value);
  537.                                             }),
  538.                                         new RadioListTile(
  539.                                             title: new Text(
  540.                                               "Pediatric Surgery",
  541.                                               style: TextStyle(
  542.                                                   fontWeight: FontWeight.bold),
  543.                                             ),
  544.                                             value: 'Pediatric Surgery',
  545.                                             groupValue: _selected,
  546.                                             onChanged: (String value) {
  547.                                               onChanged(value);
  548.                                             }),
  549.                                         new RadioListTile(
  550.                                             title: new Text(
  551.                                               "Vascular Surgery",
  552.                                               style: TextStyle(
  553.                                                   fontWeight: FontWeight.bold),
  554.                                             ),
  555.                                             value: 'Vascular Surgery',
  556.                                             groupValue: _selected,
  557.                                             onChanged: (String value) {
  558.                                               onChanged(value);
  559.                                             }),
  560.                                         new RadioListTile(
  561.                                             title: new Text(
  562.                                               "Orthopedic Surgery",
  563.                                               style: TextStyle(
  564.                                                   fontWeight: FontWeight.bold),
  565.                                             ),
  566.                                             value: 'Orthopedic Surgery',
  567.                                             groupValue: _selected,
  568.                                             onChanged: (String value) {
  569.                                               onChanged(value);
  570.                                             }),
  571.                                         new RadioListTile(
  572.                                             title: new Text(
  573.                                               "Urology",
  574.                                               style: TextStyle(
  575.                                                   fontWeight: FontWeight.bold),
  576.                                             ),
  577.                                             value: 'Urology',
  578.                                             groupValue: _selected,
  579.                                             onChanged: (String value) {
  580.                                               onChanged(value);
  581.                                             }),
  582.                                         new RadioListTile(
  583.                                             title: new Text(
  584.                                               "Neurosurgery",
  585.                                               style: TextStyle(
  586.                                                   fontWeight: FontWeight.bold),
  587.                                             ),
  588.                                             value: 'Neurosurgery',
  589.                                             groupValue: _selected,
  590.                                             onChanged: (String value) {
  591.                                               onChanged(value);
  592.                                             }),
  593.                                         new RadioListTile(
  594.                                             title: new Text(
  595.                                               "Thoracic & Cardiovascular Surgery",
  596.                                               style: TextStyle(
  597.                                                   fontWeight: FontWeight.bold),
  598.                                             ),
  599.                                             value:
  600.                                                 'Thoracic & Cardiovascular Surgery',
  601.                                             groupValue: _selected,
  602.                                             onChanged: (String value) {
  603.                                               onChanged(value);
  604.                                             }),
  605.                                         new RadioListTile(
  606.                                             title: new Text(
  607.                                               "Obstetrics & Gynecology",
  608.                                               style: TextStyle(
  609.                                                   fontWeight: FontWeight.bold),
  610.                                             ),
  611.                                             value: 'Obstetrics & Gynecology',
  612.                                             groupValue: _selected,
  613.                                             onChanged: (String value) {
  614.                                               onChanged(value);
  615.                                             }),
  616.                                         new RadioListTile(
  617.                                             title: new Text(
  618.                                               "OtoRhinolaryngology",
  619.                                               style: TextStyle(
  620.                                                   fontWeight: FontWeight.bold),
  621.                                             ),
  622.                                             value: 'OtoRhinolaryngology',
  623.                                             groupValue: _selected,
  624.                                             onChanged: (String value) {
  625.                                               onChanged(value);
  626.                                             }),
  627.                                         new RadioListTile(
  628.                                             title: new Text(
  629.                                               "Opthalmology",
  630.                                               style: TextStyle(
  631.                                                   fontWeight: FontWeight.bold),
  632.                                             ),
  633.                                             value: 'Opthalmology',
  634.                                             groupValue: _selected,
  635.                                             onChanged: (String value) {
  636.                                               onChanged(value);
  637.                                             }),
  638.                                         new RadioListTile(
  639.                                             title: new Text(
  640.                                               "Thoracic Surgery",
  641.                                               style: TextStyle(
  642.                                                   fontWeight: FontWeight.bold),
  643.                                             ),
  644.                                             value: 'Thoracic Surgery',
  645.                                             groupValue: _selected,
  646.                                             onChanged: (String value) {
  647.                                               onChanged(value);
  648.                                             }),
  649.                                         new RadioListTile(
  650.                                             title: new Text(
  651.                                               "Oncologic Surgery",
  652.                                               style: TextStyle(
  653.                                                   fontWeight: FontWeight.bold),
  654.                                             ),
  655.                                             value: 'Oncologic Surgery',
  656.                                             groupValue: _selected,
  657.                                             onChanged: (String value) {
  658.                                               onChanged(value);
  659.                                             }),
  660.                                         new RadioListTile(
  661.                                             title: new Text(
  662.                                               "Surgery & Reconstruction of Maxillofacial",
  663.                                               style: TextStyle(
  664.                                                   fontWeight: FontWeight.bold),
  665.                                             ),
  666.                                             value:
  667.                                                 'Surgery & Reconstruction of Maxillofacial',
  668.                                             groupValue: _selected,
  669.                                             onChanged: (String value) {
  670.                                               onChanged(value);
  671.                                             }),
  672.                                         new ListTile(
  673.                                             leading: new Text(
  674.                                           "internal diseases majors",
  675.                                           textAlign: TextAlign.start,
  676.                                           style: TextStyle(
  677.                                             fontSize: 25.0,
  678.                                             color: Colors.red,
  679.                                           ),
  680.                                         )),
  681.                                         new RadioListTile(
  682.                                             title: new Text(
  683.                                               "Internal Medicine",
  684.                                               style: TextStyle(
  685.                                                   fontWeight: FontWeight.bold),
  686.                                             ),
  687.                                             value: 'Internal Medicine',
  688.                                             groupValue: _selected,
  689.                                             onChanged: (String value) {
  690.                                               onChanged(value);
  691.                                             }),
  692.                                         new RadioListTile(
  693.                                             title: new Text(
  694.                                               "Cardiology",
  695.                                               style: TextStyle(
  696.                                                   fontWeight: FontWeight.bold),
  697.                                             ),
  698.                                             value: 'Cardiology',
  699.                                             groupValue: _selected,
  700.                                             onChanged: (String value) {
  701.                                               onChanged(value);
  702.                                             }),
  703.                                         new RadioListTile(
  704.                                             title: new Text(
  705.                                               "Endocrinology & Metabolism",
  706.                                               style: TextStyle(
  707.                                                   fontWeight: FontWeight.bold),
  708.                                             ),
  709.                                             value: 'Endocrinology & Metabolism',
  710.                                             groupValue: _selected,
  711.                                             onChanged: (String value) {
  712.                                               onChanged(value);
  713.                                             }),
  714.                                         new RadioListTile(
  715.                                             title: new Text(
  716.                                               "Pulmonary Diseases",
  717.                                               style: TextStyle(
  718.                                                   fontWeight: FontWeight.bold),
  719.                                             ),
  720.                                             value: 'Pulmonary Diseases',
  721.                                             groupValue: _selected,
  722.                                             onChanged: (String value) {
  723.                                               onChanged(value);
  724.                                             }),
  725.                                         new RadioListTile(
  726.                                             title: new Text(
  727.                                               "Gastroenterology",
  728.                                               style: TextStyle(
  729.                                                   fontWeight: FontWeight.bold),
  730.                                             ),
  731.                                             value: 'Gastroenterology',
  732.                                             groupValue: _selected,
  733.                                             onChanged: (String value) {
  734.                                               onChanged(value);
  735.                                             }),
  736.                                         new RadioListTile(
  737.                                             title: new Text(
  738.                                               "Nephrology",
  739.                                               style: TextStyle(
  740.                                                   fontWeight: FontWeight.bold),
  741.                                             ),
  742.                                             value: 'Nephrology',
  743.                                             groupValue: _selected,
  744.                                             onChanged: (String value) {
  745.                                               onChanged(value);
  746.                                             }),
  747.                                         new RadioListTile(
  748.                                             title: new Text(
  749.                                               "Infectious Diseases",
  750.                                               style: TextStyle(
  751.                                                   fontWeight: FontWeight.bold),
  752.                                             ),
  753.                                             value: 'Infectious Diseases',
  754.                                             groupValue: _selected,
  755.                                             onChanged: (String value) {
  756.                                               onChanged(value);
  757.                                             }),
  758.                                         new RadioListTile(
  759.                                             title: new Text(
  760.                                               "Allergy & Immunology",
  761.                                               style: TextStyle(
  762.                                                   fontWeight: FontWeight.bold),
  763.                                             ),
  764.                                             value: 'Allergy & Immunology',
  765.                                             groupValue: _selected,
  766.                                             onChanged: (String value) {
  767.                                               onChanged(value);
  768.                                             }),
  769.                                         new RadioListTile(
  770.                                             title: new Text(
  771.                                               "Genetic Diseases",
  772.                                               style: TextStyle(
  773.                                                   fontWeight: FontWeight.bold),
  774.                                             ),
  775.                                             value: 'Genetic Diseases',
  776.                                             groupValue: _selected,
  777.                                             onChanged: (String value) {
  778.                                               onChanged(value);
  779.                                             }),
  780.                                         new RadioListTile(
  781.                                             title: new Text(
  782.                                               "Gerontology",
  783.                                               style: TextStyle(
  784.                                                   fontWeight: FontWeight.bold),
  785.                                             ),
  786.                                             value: 'Gerontology',
  787.                                             groupValue: _selected,
  788.                                             onChanged: (String value) {
  789.                                               onChanged(value);
  790.                                             }),
  791.                                         new RadioListTile(
  792.                                             title: new Text(
  793.                                               "Rheumatology",
  794.                                               style: TextStyle(
  795.                                                   fontWeight: FontWeight.bold),
  796.                                             ),
  797.                                             value: 'Rheumatology',
  798.                                             groupValue: _selected,
  799.                                             onChanged: (String value) {
  800.                                               onChanged(value);
  801.                                             }),
  802.                                         new RadioListTile(
  803.                                             title: new Text(
  804.                                               "Dermatology",
  805.                                               style: TextStyle(
  806.                                                   fontWeight: FontWeight.bold),
  807.                                             ),
  808.                                             value: 'Dermatology',
  809.                                             groupValue: _selected,
  810.                                             onChanged: (String value) {
  811.                                               onChanged(value);
  812.                                             }),
  813.                                         new RadioListTile(
  814.                                             title: new Text(
  815.                                               "Neurology",
  816.                                               style: TextStyle(
  817.                                                   fontWeight: FontWeight.bold),
  818.                                             ),
  819.                                             value: 'Neurology',
  820.                                             groupValue: _selected,
  821.                                             onChanged: (String value) {
  822.                                               onChanged(value);
  823.                                             }),
  824.                                         new RadioListTile(
  825.                                             title: new Text(
  826.                                               "Psychiatry",
  827.                                               style: TextStyle(
  828.                                                   fontWeight: FontWeight.bold),
  829.                                             ),
  830.                                             value: 'Psychiatry',
  831.                                             groupValue: _selected,
  832.                                             onChanged: (String value) {
  833.                                               onChanged(value);
  834.                                             }),
  835.                                         new RadioListTile(
  836.                                             title: new Text(
  837.                                               "Hematology",
  838.                                               style: TextStyle(
  839.                                                   fontWeight: FontWeight.bold),
  840.                                             ),
  841.                                             value: 'Hematology',
  842.                                             groupValue: _selected,
  843.                                             onChanged: (String value) {
  844.                                               onChanged(value);
  845.                                             }),
  846.                                         new RadioListTile(
  847.                                             title: new Text(
  848.                                               "Medical Oncology",
  849.                                               style: TextStyle(
  850.                                                   fontWeight: FontWeight.bold),
  851.                                             ),
  852.                                             value: 'Medical Oncology',
  853.                                             groupValue: _selected,
  854.                                             onChanged: (String value) {
  855.                                               onChanged(value);
  856.                                             }),
  857.                                         new RadioListTile(
  858.                                             title: new Text(
  859.                                               "Medical Hematology &  Oncology",
  860.                                               style: TextStyle(
  861.                                                   fontWeight: FontWeight.bold),
  862.                                             ),
  863.                                             value:
  864.                                                 'Medical Hematology  Oncology',
  865.                                             groupValue: _selected,
  866.                                             onChanged: (String value) {
  867.                                               onChanged(value);
  868.                                             }),
  869.                                         new RadioListTile(
  870.                                             title: new Text(
  871.                                               "Emergency Medicine",
  872.                                               style: TextStyle(
  873.                                                   fontWeight: FontWeight.bold),
  874.                                             ),
  875.                                             value: 'Emergency Medicine',
  876.                                             groupValue: _selected,
  877.                                             onChanged: (String value) {
  878.                                               onChanged(value);
  879.                                             }),
  880.                                         new RadioListTile(
  881.                                             title: new Text(
  882.                                               "Intensive Care Medicine",
  883.                                               style: TextStyle(
  884.                                                   fontWeight: FontWeight.bold),
  885.                                             ),
  886.                                             value: 'Intensive Care Medicine',
  887.                                             groupValue: _selected,
  888.                                             onChanged: (String value) {
  889.                                               onChanged(value);
  890.                                             }),
  891.                                         new RadioListTile(
  892.                                             title: new Text(
  893.                                               "Infections Diseases",
  894.                                               style: TextStyle(
  895.                                                   fontWeight: FontWeight.bold),
  896.                                             ),
  897.                                             value: 'Infections Diseases',
  898.                                             groupValue: _selected,
  899.                                             onChanged: (String value) {
  900.                                               onChanged(value);
  901.                                             }),
  902.                                         new ListTile(
  903.                                             leading: new Text(
  904.                                           "children medicine majors",
  905.                                           textAlign: TextAlign.start,
  906.                                           style: TextStyle(
  907.                                             fontSize: 25.0,
  908.                                             color: Colors.red,
  909.                                           ),
  910.                                         )),
  911.                                         new RadioListTile(
  912.                                             title: new Text(
  913.                                               "Pediatrics",
  914.                                               style: TextStyle(
  915.                                                   fontWeight: FontWeight.bold),
  916.                                             ),
  917.                                             value: 'Pediatrics',
  918.                                             groupValue: _selected,
  919.                                             onChanged: (String value) {
  920.                                               onChanged(value);
  921.                                             }),
  922.                                         new RadioListTile(
  923.                                             title: new Text(
  924.                                               "Pediatric Cardiology",
  925.                                               style: TextStyle(
  926.                                                   fontWeight: FontWeight.bold),
  927.                                             ),
  928.                                             value: 'Pediatric Cardiology',
  929.                                             groupValue: _selected,
  930.                                             onChanged: (String value) {
  931.                                               onChanged(value);
  932.                                             }),
  933.                                         new RadioListTile(
  934.                                             title: new Text(
  935.                                               "Pediatric Nephrology",
  936.                                               style: TextStyle(
  937.                                                   fontWeight: FontWeight.bold),
  938.                                             ),
  939.                                             value: 'Pediatric Nephrology',
  940.                                             groupValue: _selected,
  941.                                             onChanged: (String value) {
  942.                                               onChanged(value);
  943.                                             }),
  944.                                         new RadioListTile(
  945.                                             title: new Text(
  946.                                               "Pediatric Neurology",
  947.                                               style: TextStyle(
  948.                                                   fontWeight: FontWeight.bold),
  949.                                             ),
  950.                                             value: 'Pediatric Neurology',
  951.                                             groupValue: _selected,
  952.                                             onChanged: (String value) {
  953.                                               onChanged(value);
  954.                                             }),
  955.                                         new RadioListTile(
  956.                                             title: new Text(
  957.                                               "Pediatric Psychiatry",
  958.                                               style: TextStyle(
  959.                                                   fontWeight: FontWeight.bold),
  960.                                             ),
  961.                                             value: 'Pediatric Psychiatry',
  962.                                             groupValue: _selected,
  963.                                             onChanged: (String value) {
  964.                                               onChanged(value);
  965.                                             }),
  966.                                         new RadioListTile(
  967.                                             title: new Text(
  968.                                               "Pediatric Endocrinology",
  969.                                               style: TextStyle(
  970.                                                   fontWeight: FontWeight.bold),
  971.                                             ),
  972.                                             value: 'Pediatric Endocrinology',
  973.                                             groupValue: _selected,
  974.                                             onChanged: (String value) {
  975.                                               onChanged(value);
  976.                                             }),
  977.                                         new RadioListTile(
  978.                                             title: new Text(
  979.                                               "Pediatric Pulmonology",
  980.                                               style: TextStyle(
  981.                                                   fontWeight: FontWeight.bold),
  982.                                             ),
  983.                                             value: 'Pediatric Pulmonology',
  984.                                             groupValue: _selected,
  985.                                             onChanged: (String value) {
  986.                                               onChanged(value);
  987.                                             }),
  988.                                         new RadioListTile(
  989.                                             title: new Text(
  990.                                               "Pediatric Gastroenterology",
  991.                                               style: TextStyle(
  992.                                                   fontWeight: FontWeight.bold),
  993.                                             ),
  994.                                             value: 'Pediatric Gastroenterology',
  995.                                             groupValue: _selected,
  996.                                             onChanged: (String value) {
  997.                                               onChanged(value);
  998.                                             }),
  999.                                         new RadioListTile(
  1000.                                             title: new Text(
  1001.                                               "Pediatric Infectious Diseases",
  1002.                                               style: TextStyle(
  1003.                                                   fontWeight: FontWeight.bold),
  1004.                                             ),
  1005.                                             value:
  1006.                                                 'Pediatric Infectious Diseases',
  1007.                                             groupValue: _selected,
  1008.                                             onChanged: (String value) {
  1009.                                               onChanged(value);
  1010.                                             }),
  1011.                                         new RadioListTile(
  1012.                                             title: new Text(
  1013.                                               "Pediatric Genetics",
  1014.                                               style: TextStyle(
  1015.                                                   fontWeight: FontWeight.bold),
  1016.                                             ),
  1017.                                             value: 'Pediatric Genetics',
  1018.                                             groupValue: _selected,
  1019.                                             onChanged: (String value) {
  1020.                                               onChanged(value);
  1021.                                             }),
  1022.                                         new RadioListTile(
  1023.                                             title: new Text(
  1024.                                               "Pediatric Allergy & Immunology",
  1025.                                               style: TextStyle(
  1026.                                                   fontWeight: FontWeight.bold),
  1027.                                             ),
  1028.                                             value:
  1029.                                                 'Pediatric Allergy & Immunology',
  1030.                                             groupValue: _selected,
  1031.                                             onChanged: (String value) {
  1032.                                               onChanged(value);
  1033.                                             }),
  1034.                                         new RadioListTile(
  1035.                                             title: new Text(
  1036.                                               "Neonatology",
  1037.                                               style: TextStyle(
  1038.                                                   fontWeight: FontWeight.bold),
  1039.                                             ),
  1040.                                             value: 'Neonatology',
  1041.                                             groupValue: _selected,
  1042.                                             onChanged: (String value) {
  1043.                                               onChanged(value);
  1044.                                             }),
  1045.                                         new RadioListTile(
  1046.                                             title: new Text(
  1047.                                               "Pediatric Hematology",
  1048.                                               style: TextStyle(
  1049.                                                   fontWeight: FontWeight.bold),
  1050.                                             ),
  1051.                                             value: 'Pediatric Hematology',
  1052.                                             groupValue: _selected,
  1053.                                             onChanged: (String value) {
  1054.                                               onChanged(value);
  1055.                                             }),
  1056.                                         new RadioListTile(
  1057.                                             title: new Text(
  1058.                                               "Pediatric oncology",
  1059.                                               style: TextStyle(
  1060.                                                   fontWeight: FontWeight.bold),
  1061.                                             ),
  1062.                                             value: 'Pediatric oncology',
  1063.                                             groupValue: _selected,
  1064.                                             onChanged: (String value) {
  1065.                                               onChanged(value);
  1066.                                             }),
  1067.                                         new RadioListTile(
  1068.                                             title: new Text(
  1069.                                               "Pediatric Hematology & Oncology",
  1070.                                               style: TextStyle(
  1071.                                                   fontWeight: FontWeight.bold),
  1072.                                             ),
  1073.                                             value:
  1074.                                                 'Pediatric Hematology & Oncology',
  1075.                                             groupValue: _selected,
  1076.                                             onChanged: (String value) {
  1077.                                               onChanged(value);
  1078.                                             }),
  1079.                                         new RadioListTile(
  1080.                                             title: new Text(
  1081.                                               "Pediatric Intensive Care",
  1082.                                               style: TextStyle(
  1083.                                                   fontWeight: FontWeight.bold),
  1084.                                             ),
  1085.                                             value: 'Pediatric Intensive Care',
  1086.                                             groupValue: _selected,
  1087.                                             onChanged: (String value) {
  1088.                                               onChanged(value);
  1089.                                             }),
  1090.                                         new ListTile(
  1091.                                             leading: new Text(
  1092.                                           "other majors",
  1093.                                           textAlign: TextAlign.start,
  1094.                                           style: TextStyle(
  1095.                                             fontSize: 25.0,
  1096.                                             color: Colors.red,
  1097.                                           ),
  1098.                                         )),
  1099.                                         new RadioListTile(
  1100.                                             title: new Text(
  1101.                                               "Family Medicine",
  1102.                                               style: TextStyle(
  1103.                                                   fontWeight: FontWeight.bold),
  1104.                                             ),
  1105.                                             value: 'Family Medicine',
  1106.                                             groupValue: _selected,
  1107.                                             onChanged: (String value) {
  1108.                                               onChanged(value);
  1109.                                             }),
  1110.                                         new RadioListTile(
  1111.                                             title: new Text(
  1112.                                               "General Medicine",
  1113.                                               style: TextStyle(
  1114.                                                   fontWeight: FontWeight.bold),
  1115.                                             ),
  1116.                                             value: 'General Medicine',
  1117.                                             groupValue: _selected,
  1118.                                             onChanged: (String value) {
  1119.                                               onChanged(value);
  1120.                                             }),
  1121.                                         new RadioListTile(
  1122.                                             title: new Text(
  1123.                                               "Anesthesiology",
  1124.                                               style: TextStyle(
  1125.                                                   fontWeight: FontWeight.bold),
  1126.                                             ),
  1127.                                             value: 'Anesthesiology',
  1128.                                             groupValue: _selected,
  1129.                                             onChanged: (String value) {
  1130.                                               onChanged(value);
  1131.                                             }),
  1132.                                         new RadioListTile(
  1133.                                             title: new Text(
  1134.                                               "Diagnostic Radiology",
  1135.                                               style: TextStyle(
  1136.                                                   fontWeight: FontWeight.bold),
  1137.                                             ),
  1138.                                             value: 'Diagnostic Radiology',
  1139.                                             groupValue: _selected,
  1140.                                             onChanged: (String value) {
  1141.                                               onChanged(value);
  1142.                                             }),
  1143.                                         new RadioListTile(
  1144.                                             title: new Text(
  1145.                                               "Oncologic Radiotherapy Medicine",
  1146.                                               style: TextStyle(
  1147.                                                   fontWeight: FontWeight.bold),
  1148.                                             ),
  1149.                                             value:
  1150.                                                 'Oncologic Radiotherapy Medicine',
  1151.                                             groupValue: _selected,
  1152.                                             onChanged: (String value) {
  1153.                                               onChanged(value);
  1154.                                             }),
  1155.                                         new RadioListTile(
  1156.                                             title: new Text(
  1157.                                               "Nuclear Medicine",
  1158.                                               style: TextStyle(
  1159.                                                   fontWeight: FontWeight.bold),
  1160.                                             ),
  1161.                                             value: 'Nuclear Medicine',
  1162.                                             groupValue: _selected,
  1163.                                             onChanged: (String value) {
  1164.                                               onChanged(value);
  1165.                                             }),
  1166.                                         new RadioListTile(
  1167.                                             title: new Text(
  1168.                                               "Anatomical Pathology",
  1169.                                               style: TextStyle(
  1170.                                                   fontWeight: FontWeight.bold),
  1171.                                             ),
  1172.                                             value: 'Anatomical Pathology',
  1173.                                             groupValue: _selected,
  1174.                                             onChanged: (String value) {
  1175.                                               onChanged(value);
  1176.                                             }),
  1177.                                         new RadioListTile(
  1178.                                             title: new Text(
  1179.                                               "Laboratory Medicine",
  1180.                                               style: TextStyle(
  1181.                                                   fontWeight: FontWeight.bold),
  1182.                                             ),
  1183.                                             value: 'Laboratory Medicine',
  1184.                                             groupValue: _selected,
  1185.                                             onChanged: (String value) {
  1186.                                               onChanged(value);
  1187.                                             }),
  1188.                                         new RadioListTile(
  1189.                                             title: new Text(
  1190.                                               "Legal Medicine",
  1191.                                               style: TextStyle(
  1192.                                                   fontWeight: FontWeight.bold),
  1193.                                             ),
  1194.                                             value: 'Legal Medicine',
  1195.                                             groupValue: _selected,
  1196.                                             onChanged: (String value) {
  1197.                                               onChanged(value);
  1198.                                             }),
  1199.                                         new RadioListTile(
  1200.                                             title: new Text(
  1201.                                               "Industrial Medicine",
  1202.                                               style: TextStyle(
  1203.                                                   fontWeight: FontWeight.bold),
  1204.                                             ),
  1205.                                             value: 'Industrial Medicine',
  1206.                                             groupValue: _selected,
  1207.                                             onChanged: (String value) {
  1208.                                               onChanged(value);
  1209.                                             }),
  1210.                                         new RadioListTile(
  1211.                                             title: new Text(
  1212.                                               "Preventive Medicine",
  1213.                                               style: TextStyle(
  1214.                                                   fontWeight: FontWeight.bold),
  1215.                                             ),
  1216.                                             value: 'Preventive Medicine',
  1217.                                             groupValue: _selected,
  1218.                                             onChanged: (String value) {
  1219.                                               onChanged(value);
  1220.                                             }),
  1221.                                         new RadioListTile(
  1222.                                             title: new Text(
  1223.                                               "Physical Medicine & Rehabilitation",
  1224.                                               style: TextStyle(
  1225.                                                   fontWeight: FontWeight.bold),
  1226.                                             ),
  1227.                                             value:
  1228.                                                 'Physical Medicine & Rehabilitation',
  1229.                                             groupValue: _selected,
  1230.                                             onChanged: (String value) {
  1231.                                               onChanged(value);
  1232.                                             }),
  1233.                                         new RadioListTile(
  1234.                                             title: new Text(
  1235.                                               "Public Health",
  1236.                                               style: TextStyle(
  1237.                                                   fontWeight: FontWeight.bold),
  1238.                                             ),
  1239.                                             value: 'Public Health',
  1240.                                             groupValue: _selected,
  1241.                                             onChanged: (String value) {
  1242.                                               onChanged(value);
  1243.                                             }),
  1244.                                         new RadioListTile(
  1245.                                             title: new Text(
  1246.                                               "Angiology",
  1247.                                               style: TextStyle(
  1248.                                                   fontWeight: FontWeight.bold),
  1249.                                             ),
  1250.                                             value: 'Angiology',
  1251.                                             groupValue: _selected,
  1252.                                             onChanged: (String value) {
  1253.                                               onChanged(value);
  1254.                                             }),
  1255.                                         new RadioListTile(
  1256.                                             title: new Text(
  1257.                                               "Aerospatial Medicine",
  1258.                                               style: TextStyle(
  1259.                                                   fontWeight: FontWeight.bold),
  1260.                                             ),
  1261.                                             value: 'Aerospatial Medicine',
  1262.                                             groupValue: _selected,
  1263.                                             onChanged: (String value) {
  1264.                                               onChanged(value);
  1265.                                             }),
  1266.                                         new RadioListTile(
  1267.                                             title: new Text(
  1268.                                               "Sports Medicine",
  1269.                                               style: TextStyle(
  1270.                                                   fontWeight: FontWeight.bold),
  1271.                                             ),
  1272.                                             value: 'Sports Medicine',
  1273.                                             groupValue: _selected,
  1274.                                             onChanged: (String value) {
  1275.                                               onChanged(value);
  1276.                                             }),
  1277.                                         new RadioListTile(
  1278.                                             title: new Text(
  1279.                                               "Penitentiary Medicine",
  1280.                                               style: TextStyle(
  1281.                                                   fontWeight: FontWeight.bold),
  1282.                                             ),
  1283.                                             value: 'Penitentiary Medicine',
  1284.                                             groupValue: _selected,
  1285.                                             onChanged: (String value) {
  1286.                                               onChanged(value);
  1287.                                             }),
  1288.                                         new RadioListTile(
  1289.                                             title: new Text(
  1290.                                               "Pain Medicine",
  1291.                                               style: TextStyle(
  1292.                                                   fontWeight: FontWeight.bold),
  1293.                                             ),
  1294.                                             value: 'Pain Medicine',
  1295.                                             groupValue: _selected,
  1296.                                             onChanged: (String value) {
  1297.                                               onChanged(value);
  1298.                                             }),
  1299.                                         new ListTile(
  1300.                                             leading: new Text(
  1301.                                           "dental majors",
  1302.                                           textAlign: TextAlign.start,
  1303.                                           style: TextStyle(
  1304.                                             fontSize: 25.0,
  1305.                                             color: Colors.red,
  1306.                                           ),
  1307.                                         )),
  1308.                                         new RadioListTile(
  1309.                                             title: new Text(
  1310.                                               "Orthodontics",
  1311.                                               style: TextStyle(
  1312.                                                   fontWeight: FontWeight.bold),
  1313.                                             ),
  1314.                                             value: 'Orthodontics',
  1315.                                             groupValue: _selected,
  1316.                                             onChanged: (String value) {
  1317.                                               onChanged(value);
  1318.                                             }),
  1319.                                         new RadioListTile(
  1320.                                             title: new Text(
  1321.                                               "Restorative & Esthetic Dentistry",
  1322.                                               style: TextStyle(
  1323.                                                   fontWeight: FontWeight.bold),
  1324.                                             ),
  1325.                                             value:
  1326.                                                 'Restorative & Esthetic Dentistry',
  1327.                                             groupValue: _selected,
  1328.                                             onChanged: (String value) {
  1329.                                               onChanged(value);
  1330.                                             }),
  1331.                                         new RadioListTile(
  1332.                                             title: new Text(
  1333.                                               "Periodontology",
  1334.                                               style: TextStyle(
  1335.                                                   fontWeight: FontWeight.bold),
  1336.                                             ),
  1337.                                             value: 'Periodontology',
  1338.                                             groupValue: _selected,
  1339.                                             onChanged: (String value) {
  1340.                                               onChanged(value);
  1341.                                             }),
  1342.                                         new RadioListTile(
  1343.                                             title: new Text(
  1344.                                               "Oral Surgery",
  1345.                                               style: TextStyle(
  1346.                                                   fontWeight: FontWeight.bold),
  1347.                                             ),
  1348.                                             value: 'Oral Surgery',
  1349.                                             groupValue: _selected,
  1350.                                             onChanged: (String value) {
  1351.                                               onChanged(value);
  1352.                                             }),
  1353.                                         new RadioListTile(
  1354.                                             title: new Text(
  1355.                                               "Oral & Maxillofacial Surgery",
  1356.                                               style: TextStyle(
  1357.                                                   fontWeight: FontWeight.bold),
  1358.                                             ),
  1359.                                             value:
  1360.                                                 'Oral & Maxillofacial Surgery',
  1361.                                             groupValue: _selected,
  1362.                                             onChanged: (String value) {
  1363.                                               onChanged(value);
  1364.                                             }),
  1365.                                         new RadioListTile(
  1366.                                             title: new Text(
  1367.                                               "Maxillofacial Prosthodontics",
  1368.                                               style: TextStyle(
  1369.                                                   fontWeight: FontWeight.bold),
  1370.                                             ),
  1371.                                             value:
  1372.                                                 'Maxillofacial Prosthodontics',
  1373.                                             groupValue: _selected,
  1374.                                             onChanged: (String value) {
  1375.                                               onChanged(value);
  1376.                                             }),
  1377.                                         new RadioListTile(
  1378.                                             title: new Text(
  1379.                                               "Fixed Prosthodontics",
  1380.                                               style: TextStyle(
  1381.                                                   fontWeight: FontWeight.bold),
  1382.                                             ),
  1383.                                             value: 'Fixed Prosthodontics',
  1384.                                             groupValue: _selected,
  1385.                                             onChanged: (String value) {
  1386.                                               onChanged(value);
  1387.                                             }),
  1388.                                         new RadioListTile(
  1389.                                             title: new Text(
  1390.                                               "Removable Prosthodontics",
  1391.                                               style: TextStyle(
  1392.                                                   fontWeight: FontWeight.bold),
  1393.                                             ),
  1394.                                             value: 'Removable Prosthodontics',
  1395.                                             groupValue: _selected,
  1396.                                             onChanged: (String value) {
  1397.                                               onChanged(value);
  1398.                                             }),
  1399.                                         new RadioListTile(
  1400.                                             title: new Text(
  1401.                                               "Fixed & Removable Prosthodontics",
  1402.                                               style: TextStyle(
  1403.                                                   fontWeight: FontWeight.bold),
  1404.                                             ),
  1405.                                             value:
  1406.                                                 'Fixed & Removable Prosthodontics',
  1407.                                             groupValue: _selected,
  1408.                                             onChanged: (String value) {
  1409.                                               onChanged(value);
  1410.                                             }),
  1411.                                         new RadioListTile(
  1412.                                             title: new Text(
  1413.                                               "Prosthetic & Esthetic Dentistry",
  1414.                                               style: TextStyle(
  1415.                                                   fontWeight: FontWeight.bold),
  1416.                                             ),
  1417.                                             value:
  1418.                                                 'Prosthetic & Esthetic Dentistry',
  1419.                                             groupValue: _selected,
  1420.                                             onChanged: (String value) {
  1421.                                               onChanged(value);
  1422.                                             }),
  1423.                                         new RadioListTile(
  1424.                                             title: new Text(
  1425.                                               "Implant Prosthodontics",
  1426.                                               style: TextStyle(
  1427.                                                   fontWeight: FontWeight.bold),
  1428.                                             ),
  1429.                                             value: 'Implant Prosthodontics',
  1430.                                             groupValue: _selected,
  1431.                                             onChanged: (String value) {
  1432.                                               onChanged(value);
  1433.                                             }),
  1434.                                         new RadioListTile(
  1435.                                             title: new Text(
  1436.                                               "Pediatric Dentistry",
  1437.                                               style: TextStyle(
  1438.                                                   fontWeight: FontWeight.bold),
  1439.                                             ),
  1440.                                             value: 'Pediatric Dentistry',
  1441.                                             groupValue: _selected,
  1442.                                             onChanged: (String value) {
  1443.                                               onChanged(value);
  1444.                                             }),
  1445.                                         new RadioListTile(
  1446.                                             title: new Text(
  1447.                                               "Oral & Maxillofacial Radiology",
  1448.                                               style: TextStyle(
  1449.                                                   fontWeight: FontWeight.bold),
  1450.                                             ),
  1451.                                             value:
  1452.                                                 'Oral & Maxillofacial Radiology',
  1453.                                             groupValue: _selected,
  1454.                                             onChanged: (String value) {
  1455.                                               onChanged(value);
  1456.                                             }),
  1457.                                         new RadioListTile(
  1458.                                             title: new Text(
  1459.                                               "Implantology",
  1460.                                               style: TextStyle(
  1461.                                                   fontWeight: FontWeight.bold),
  1462.                                             ),
  1463.                                             value: 'Implantology',
  1464.                                             groupValue: _selected,
  1465.                                             onChanged: (String value) {
  1466.                                               onChanged(value);
  1467.                                             }),
  1468.                                         new RadioListTile(
  1469.                                             title: new Text(
  1470.                                               "Oral Pathology",
  1471.                                               style: TextStyle(
  1472.                                                   fontWeight: FontWeight.bold),
  1473.                                             ),
  1474.                                             value: 'Oral Pathology',
  1475.                                             groupValue: _selected,
  1476.                                             onChanged: (String value) {
  1477.                                               onChanged(value);
  1478.                                             }),
  1479.                                         new RadioListTile(
  1480.                                             title: new Text(
  1481.                                               "Endodontics",
  1482.                                               style: TextStyle(
  1483.                                                   fontWeight: FontWeight.bold),
  1484.                                             ),
  1485.                                             value: 'Endodontics',
  1486.                                             groupValue: _selected,
  1487.                                             onChanged: (String value) {
  1488.                                               onChanged(value);
  1489.                                             }),
  1490.                                         new RadioListTile(
  1491.                                             title: new Text(
  1492.                                               "Occlusion",
  1493.                                               style: TextStyle(
  1494.                                                   fontWeight: FontWeight.bold),
  1495.                                             ),
  1496.                                             value: 'Occlusion',
  1497.                                             groupValue: _selected,
  1498.                                             onChanged: (String value) {
  1499.                                               onChanged(value);
  1500.                                             }),
  1501.                                         new RadioListTile(
  1502.                                             title: new Text(
  1503.                                               "Dental Public Health",
  1504.                                               style: TextStyle(
  1505.                                                   fontWeight: FontWeight.bold),
  1506.                                             ),
  1507.                                             value: 'Dental Public Health',
  1508.                                             groupValue: _selected,
  1509.                                             onChanged: (String value) {
  1510.                                               onChanged(value);
  1511.                                             }),
  1512.                                         new RadioListTile(
  1513.                                             title: new Text(
  1514.                                               "Forensic Dentistry",
  1515.                                               style: TextStyle(
  1516.                                                   fontWeight: FontWeight.bold),
  1517.                                             ),
  1518.                                             value: 'Forensic Dentistry',
  1519.                                             groupValue: _selected,
  1520.                                             onChanged: (String value) {
  1521.                                               onChanged(value);
  1522.                                             }),
  1523.                                         new RadioListTile(
  1524.                                             title: new Text(
  1525.                                               "General Dentistry",
  1526.                                               style: TextStyle(
  1527.                                                   fontWeight: FontWeight.bold),
  1528.                                             ),
  1529.                                             value: 'General Dentistry',
  1530.                                             groupValue: _selected,
  1531.                                             onChanged: (String value) {
  1532.                                               onChanged(value);
  1533.                                             }),
  1534.                                         new RadioListTile(
  1535.                                             title: new Text(
  1536.                                               "Laser Therapy In Dental Medicine",
  1537.                                               style: TextStyle(
  1538.                                                   fontWeight: FontWeight.bold),
  1539.                                             ),
  1540.                                             value:
  1541.                                                 'Laser Therapy In Dental Medicine',
  1542.                                             groupValue: _selected,
  1543.                                             onChanged: (String value) {
  1544.                                               onChanged(value);
  1545.                                             }),
  1546.                                       ],
  1547.                                     ),
  1548.                                   ],
  1549.                                 ),
  1550.                               ),
  1551.                             ),
  1552.                           ],
  1553.                         ),
  1554.                       ),
  1555.                       height: Screensize.height / 1.5,
  1556.                       width: Screensize.width / 1.2,
  1557.                       margin:
  1558.                           EdgeInsets.only(left: 10.0, right: 5.0, top: 10.0),
  1559.                     ),
  1560.                   ),
  1561.                 ],
  1562.               ),
  1563.               Center(
  1564.                 child: Container(
  1565.                   child: Card(
  1566.                     child: Column(
  1567.                       crossAxisAlignment: CrossAxisAlignment.center,
  1568.                       mainAxisAlignment: MainAxisAlignment.center,
  1569.                       children: <Widget>[
  1570.                         new Icon(
  1571.                           Icons.folder_special,
  1572.                           color: Colors.blue,
  1573.                           size: 80.0,
  1574.                         ),
  1575.                         Padding(
  1576.                           padding: const EdgeInsets.all(12.0),
  1577.                           child: Text("Specialty:",
  1578.                               style: TextStyle(
  1579.                                   fontSize: 20.0, color: Colors.blue)),
  1580.                         ),
  1581.                         Padding(
  1582.                           padding: const EdgeInsets.all(12.0),
  1583.                           child: TextFormField(
  1584.                             maxLength: 50,
  1585.                             validator: (value) {
  1586.                               if (value.startsWith(' ')) {
  1587.                                 return 'Do not start Your Specialty with spaces';
  1588.                               } else if (value.isEmpty) {
  1589.                                 return 'Please Enter Your Specialty';
  1590.                               }
  1591.                             },
  1592.                             keyboardType: TextInputType.multiline,
  1593.                             maxLines: null,
  1594.                             autofocus: false,
  1595.                             decoration: InputDecoration(
  1596.                               hintText: 'Example: Fertility',
  1597.                               contentPadding:
  1598.                                   EdgeInsets.fromLTRB(20.0, 10.0, 20.0, 10.0),
  1599.                               border: OutlineInputBorder(
  1600.                                   borderRadius: BorderRadius.circular(32.0)),
  1601.                             ),
  1602.                             controller: Controller1,
  1603.                           ),
  1604.                         ),
  1605.                         new Text(
  1606.                           "Part of Your Major That You are Mostly Skilled in",
  1607.                           textAlign: TextAlign.center,
  1608.                           style: TextStyle(fontSize: 20.0),
  1609.                         )
  1610.                       ],
  1611.                     ),
  1612.                   ),
  1613.                   height: Screensize.height / 2,
  1614.                   width: Screensize.width / 1.2,
  1615.                   margin: EdgeInsets.only(left: 10.0, right: 5.0, top: 10.0),
  1616.                 ),
  1617.               ),
  1618.               Center(
  1619.                 child: Container(
  1620.                   child: Card(
  1621.                     child: Column(
  1622.                       crossAxisAlignment: CrossAxisAlignment.center,
  1623.                       mainAxisAlignment: MainAxisAlignment.center,
  1624.                       children: <Widget>[
  1625.                         new Image.asset(
  1626.                           "lib/images/OverView.png",
  1627.                           color: Colors.blue,
  1628.                           height: 60.0,
  1629.                           width: 60.0,
  1630.                         ),
  1631.                         Padding(
  1632.                           padding: const EdgeInsets.all(12.0),
  1633.                           child: Text("Overview:",
  1634.                               style: TextStyle(
  1635.                                   fontSize: 20.0, color: Colors.blue)),
  1636.                         ),
  1637.                         Padding(
  1638.                           padding: const EdgeInsets.all(12.0),
  1639.                           child: TextFormField(
  1640.                             validator: (value) {
  1641.                               if (value.startsWith(' ')) {
  1642.                                 return 'Do not start Your Overview with spaces';
  1643.                               } else if (value.isEmpty) {
  1644.                                 return 'Please Enter Your Overview';
  1645.                               }
  1646.                             },
  1647.                             keyboardType: TextInputType.multiline,
  1648.                             maxLines: null,
  1649.                             autofocus: false,
  1650.                             decoration: InputDecoration(
  1651.                               hintText: 'degree,experience,accomplishments... ',
  1652.                               contentPadding:
  1653.                                   EdgeInsets.fromLTRB(20.0, 10.0, 20.0, 10.0),
  1654.                               border: OutlineInputBorder(
  1655.                                   borderRadius: BorderRadius.circular(32.0)),
  1656.                             ),
  1657.                             controller: Controller2,
  1658.                           ),
  1659.                         ),
  1660.                         new Text(
  1661.                           "Brief Summary About Your Achievements & Degrees",
  1662.                           textAlign: TextAlign.center,
  1663.                           style: TextStyle(fontSize: 20.0),
  1664.                         )
  1665.                       ],
  1666.                     ),
  1667.                   ),
  1668.                   height: Screensize.height / 2,
  1669.                   width: Screensize.width / 1.2,
  1670.                   margin: EdgeInsets.only(left: 10.0, right: 5.0, top: 10.0),
  1671.                 ),
  1672.               ),
  1673.               Center(
  1674.                 child: Container(
  1675.                   child: Card(
  1676.                     child: Column(
  1677.                       crossAxisAlignment: CrossAxisAlignment.center,
  1678.                       mainAxisAlignment: MainAxisAlignment.center,
  1679.                       children: <Widget>[
  1680.                         Container(
  1681.                           padding: EdgeInsets.symmetric(
  1682.                               vertical: 16.0, horizontal: 30.0),
  1683.                           child: TextFormField(
  1684.                             maxLength: 25,
  1685.                             validator: (value) {
  1686.                               if (value.startsWith(' ')) {
  1687.                                 return 'Do not start the Number of Your Clinic With Spaces';
  1688.                               } else if (value.isEmpty) {
  1689.                                 return 'Please Enter the Number of Your Clinic';
  1690.                               }
  1691.                             },
  1692.                             controller: Controller3,
  1693.                             keyboardType: TextInputType.phone,
  1694.                             decoration: InputDecoration(
  1695.                               hintText: "+961...",
  1696.                               labelText: "Phone Number of the Clinic",
  1697.                             ),
  1698.                           ),
  1699.                         ),
  1700.                         Container(
  1701.                           padding: EdgeInsets.symmetric(
  1702.                               vertical: 16.0, horizontal: 30.0),
  1703.                           child: TextFormField(
  1704.                             validator: (value) {
  1705.                               if (value.startsWith(' ')) {
  1706.                                 return 'Do not start the Name of the Hospital with spaces';
  1707.                               } else if (value.isEmpty) {
  1708.                                 return 'Please Enter a Valid Hospital';
  1709.                               }
  1710.                             },
  1711.                             controller: Controller4,
  1712.                             keyboardType: TextInputType.multiline,
  1713.                             maxLines: null,
  1714.                             decoration: InputDecoration(
  1715.                               hintText:
  1716.                                   "American University Hospital\nAl Shifaa Hospital\nGreat Prophet Hospital",
  1717.                               labelText: "Contracted With",
  1718.                             ),
  1719.                           ),
  1720.                         ),
  1721.                         Container(
  1722.                           padding: EdgeInsets.symmetric(
  1723.                               vertical: 16.0, horizontal: 30.0),
  1724.                           child: TextFormField(
  1725.                             maxLength: 100,
  1726.                             validator: (value) {
  1727.                               if (value.startsWith(' ')) {
  1728.                                 return 'Do not start the Address of Your Clinic with spaces';
  1729.                               } else if (value.isEmpty) {
  1730.                                 return 'Please Enter the Address of Your Clinic';
  1731.                               }
  1732.                             },
  1733.                             controller: Controller5,
  1734.                             keyboardType: TextInputType.multiline,
  1735.                             maxLines: null,
  1736.                             decoration: InputDecoration(
  1737.                               hintText:
  1738.                                   "Tripoli, Azmi Street\nCrystal Building, Floor 6",
  1739.                               labelText: "Address",
  1740.                             ),
  1741.                           ),
  1742.                         ),
  1743.                         Container(
  1744.                           padding: EdgeInsets.symmetric(
  1745.                               vertical: 16.0, horizontal: 30.0),
  1746.                           child: TextFormField(
  1747.                             maxLength: 14,
  1748.                             validator: (value) {
  1749.                               if (value.startsWith(' ')) {
  1750.                                 return 'Do not start Your Status with spaces';
  1751.                               } else if (value.isEmpty) {
  1752.                                 return 'Please Enter Your Status';
  1753.                               }
  1754.                             },
  1755.                             controller: Controller6,
  1756.                             keyboardType: TextInputType.multiline,
  1757.                             maxLines: null,
  1758.                             decoration: InputDecoration(
  1759.                               hintText: "Available, Vacation, Abroad...",
  1760.                               labelText: "Status",
  1761.                             ),
  1762.                           ),
  1763.                         ),
  1764.                       ],
  1765.                     ),
  1766.                   ),
  1767.                   width: Screensize.width / 1.2,
  1768.                   margin: EdgeInsets.only(left: 10.0, right: 5.0, top: 10.0),
  1769.                 ),
  1770.               ),
  1771.               Center(
  1772.                 child: Container(
  1773.                   width: Screensize.width / 1.2,
  1774.                   margin: EdgeInsets.only(left: 10.0, right: 5.0, top: 10.0),
  1775.                   child: new Card(
  1776.                     child: new Column(
  1777.                       crossAxisAlignment: CrossAxisAlignment.center,
  1778.                       children: <Widget>[
  1779.                         new Padding(
  1780.                           padding: EdgeInsets.all(8.0),
  1781.                           child: new Text(
  1782.                             'Pay attention that before pressing the Get Location button, you must be mainly in your clinic, since'
  1783.                                 ' this location will be directly taken in accordance with the palce your are in now,in another meaning, you cannot select locations on the google map'
  1784.                                 ' and set them as the location of your clinic. This location will allow all Doctor Radar users to reach you through google maps.',
  1785.                             textAlign: TextAlign.center,
  1786.                           ),
  1787.                         ),
  1788.                         new RaisedButton(
  1789.                           highlightColor: Colors.amber,
  1790.                           child: new Text(
  1791.                             'Get Location',
  1792.                             style: TextStyle(color: Colors.white),
  1793.                           ),
  1794.                           color: Colors.blue,
  1795.                           onPressed: () async {
  1796.                             geolocation = await _location.getLocation();
  1797.                             setState(() {
  1798.                               _startLocation = geolocation;
  1799.                               latitude = geolocation['latitude'];
  1800.                               longitude = geolocation['longitude'];
  1801.                               googlemaps =
  1802.                                   "http://maps.google.com/maps?q=${latitude.toString()},${longitude.toString()}";
  1803.                               print(googlemaps);
  1804.                             });
  1805.                             showModalBottomSheet<void>(
  1806.                                 context: context,
  1807.                                 builder: (BuildContext context) {
  1808.                                   return new Container(
  1809.                                       child: new Padding(
  1810.                                     padding: const EdgeInsets.all(32.0),
  1811.                                     child: new Text(
  1812.                                       "Your Location has been recorded",
  1813.                                       textAlign: TextAlign.center,
  1814.                                       style: TextStyle(
  1815.                                         color: Theme.of(context).accentColor,
  1816.                                         fontSize: 20.0,
  1817.                                       ),
  1818.                                     ),
  1819.                                   ));
  1820.                                 });
  1821.                           },
  1822.                         )
  1823.                       ],
  1824.                     ),
  1825.                   ),
  1826.                 ),
  1827.               ),
  1828.               Padding(
  1829.                 padding: const EdgeInsets.all(8.0),
  1830.                 child: new CheckboxListTile(
  1831.                   title: Text(
  1832.                     'Join the Free Appointment Program ?',
  1833.                     style: TextStyle(color: Colors.red),
  1834.                   ),
  1835.                   value: freeappointment,
  1836.                   onChanged: (bool values) {
  1837.                     changefree(values);
  1838.                   },
  1839.                   activeColor: Colors.red,
  1840.                   subtitle: new Text(
  1841.                       "By checking the box, you agree to offer to our project, a single monthly renewable free appointment to our users as a matter of spreading your services and increasing your patients' number. It is highly recommended by Doctor Radar Team to join the service as it benefits the user's expectations and respectively the app download rate. In any case we thank you for choosing our app in order to enhance your business, wish you best regards, Doctor Radar Team."),
  1842.                 ),
  1843.               ),
  1844.               new SizedBox(
  1845.                 height: 60.0,
  1846.               )
  1847.             ],
  1848.           ),
  1849.         ),
  1850.       ),
  1851.     );
  1852.   }
  1853. }
Add Comment
Please, Sign In to add comment