Merge branch 'development' into ZohaibIqbalKambrani
* development: re-design child vaccine and fix some funcrionalities Fix ER service first step from fix CMC fix issue on cmc return CMC HHC Nearest Er fix design solving NearestEr design problem simple fix hot fixing fix design issues # Conflicts: # lib/config/localized_values.dartmerge-requests/238/head
commit
9a5daed5c3
@ -0,0 +1,26 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="103.843" height="79.732" viewBox="0 0 103.843 79.732">
|
||||
<g id="Group_776" data-name="Group 776" transform="translate(-67.806 -333.834)">
|
||||
<g id="Group_772" data-name="Group 772" transform="translate(72.721 385.261)">
|
||||
<path id="Rectangle_494" data-name="Rectangle 494" d="M3.513,0h5.5a3.512,3.512,0,0,1,3.512,3.512V24.794a3.512,3.512,0,0,1-3.512,3.512h-5.5A3.512,3.512,0,0,1,0,24.793V3.513A3.513,3.513,0,0,1,3.513,0Z" transform="translate(81.49)" fill="#404040"/>
|
||||
<path id="Rectangle_495" data-name="Rectangle 495" d="M3.513,0h5.5a3.512,3.512,0,0,1,3.512,3.512V24.794a3.512,3.512,0,0,1-3.512,3.512h-5.5A3.512,3.512,0,0,1,0,24.793V3.513A3.513,3.513,0,0,1,3.513,0Z" transform="translate(0)" fill="#404040"/>
|
||||
</g>
|
||||
<g id="Group_774" data-name="Group 774" transform="translate(67.806 333.834)">
|
||||
<g id="Group_773" data-name="Group 773" transform="translate(0 20.106)">
|
||||
<path id="Path_964" data-name="Path 964" d="M202.791,368.713a2.117,2.117,0,0,1-1.4,1.881l.87,1.595a2.144,2.144,0,0,1,2.578-.721h.784v-2.755Z" transform="translate(-108.451 -364.552)" fill="#b2361d"/>
|
||||
<path id="Path_965" data-name="Path 965" d="M212.887,366.617c.07,1.4-1.91,2.76-3.882,3.26-2.9.735-5.653-.648-5.653-3.515,0-2.783,1.939-4.222,4.769-3.4C210.072,363.532,212.818,365.233,212.887,366.617Z" transform="translate(-109.046 -362.733)" fill="#d84c2f"/>
|
||||
<path id="Path_966" data-name="Path 966" d="M80.223,368.713a2.116,2.116,0,0,0,1.4,1.881l-.87,1.595a2.144,2.144,0,0,0-2.578-.721h-.785v-2.755Z" transform="translate(-70.722 -364.552)" fill="#b2361d"/>
|
||||
<path id="Path_967" data-name="Path 967" d="M67.808,366.617c-.07,1.4,1.909,2.76,3.882,3.26,2.9.735,5.654-.648,5.654-3.515,0-2.783-1.939-4.222-4.769-3.4C70.623,363.532,67.877,365.233,67.808,366.617Z" transform="translate(-67.806 -362.733)" fill="#d84c2f"/>
|
||||
</g>
|
||||
<path id="Path_968" data-name="Path 968" d="M168.258,369.52c-.522-3.479-3.218-7.392-4.7-10.349s-6.929-16.872-8.262-19.307a10.983,10.983,0,0,0-7.653-5.435c-3.479-.522-18.843-.594-25.511-.594s-22.032.072-25.51.594a10.981,10.981,0,0,0-7.653,5.435c-1.334,2.435-6.784,16.35-8.262,19.307s-4.174,6.871-4.7,10.349-.348,24.09.522,27.482a7.356,7.356,0,0,0,6.61,5.479h77.982a7.356,7.356,0,0,0,6.61-5.479C168.606,393.61,168.78,373,168.258,369.52Z" transform="translate(-70.214 -333.834)" fill="#d84c2f"/>
|
||||
<path id="Path_969" data-name="Path 969" d="M75.773,405.294c.09,5.924.349,11.778.779,13.45a7.356,7.356,0,0,0,6.61,5.479h77.982a7.356,7.356,0,0,0,6.61-5.479c.429-1.671.687-7.525.779-13.45Z" transform="translate(-70.23 -355.576)" fill="#d63828"/>
|
||||
<path id="Path_970" data-name="Path 970" d="M160.494,364.834s4.871,7.37,5.508,9.221.725,3.533-1.1,4.374-15.567,4.261-18.7,4.261H101.385c-3.131,0-16.872-3.42-18.7-4.261s-1.739-2.522-1.1-4.374,5.508-9.221,5.508-9.221" transform="translate(-71.873 -343.266)" fill="none" stroke="#b2361d" stroke-miterlimit="10" stroke-width="0.5"/>
|
||||
</g>
|
||||
<path id="Path_971" data-name="Path 971" d="M165.792,420.908a1.465,1.465,0,0,1-1.364,2.224H83.859a1.465,1.465,0,0,1-1.364-2.224l1.75-4.285a3.366,3.366,0,0,1,2.887-1.956h74.025a3.364,3.364,0,0,1,2.887,1.956Z" transform="translate(-4.416 -24.593)" fill="#404040"/>
|
||||
<path id="Path_972" data-name="Path 972" d="M152.824,394.283c-.522-1.565-2.783-2.783-5.044-2.783h-26.96c-2.261,0-4.522,1.218-5.044,2.783s1.826,8.009,2.7,9.179,1.826,1.46,4.609,1.46h22.438c2.783,0,3.74-.29,4.609-1.46S153.346,395.848,152.824,394.283Z" transform="translate(-14.572 -17.545)" fill="#404040"/>
|
||||
<path id="Path_973" data-name="Path 973" d="M163.631,358.436c-.435-1.508-4.609-12.147-5.827-14.669s-2.87-3.392-4.088-3.392H98c-1.218,0-2.87.87-4.088,3.392s-5.392,13.161-5.827,14.669.261,2.2,1.391,2.2h72.764C163.37,360.639,164.066,359.943,163.631,358.436Z" transform="translate(-6.13 -1.99)" fill="#404040"/>
|
||||
<g id="Group_775" data-name="Group 775" transform="translate(76.803 368.998)">
|
||||
<path id="Path_974" data-name="Path 974" d="M175.9,389.332s3.827,4.783,5.74,4.783h11.045a2.421,2.421,0,0,0,2.522-2,23,23,0,0,0,0-7.74A90.156,90.156,0,0,1,175.9,389.332Z" transform="translate(-109.692 -384.375)" fill="#fff"/>
|
||||
<path id="Path_975" data-name="Path 975" d="M100.374,389.332s-3.827,4.783-5.74,4.783H83.589a2.421,2.421,0,0,1-2.522-2,23,23,0,0,1,0-7.74A90.156,90.156,0,0,0,100.374,389.332Z" transform="translate(-80.738 -384.375)" fill="#fff"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 4.3 KiB |
@ -1,6 +1,7 @@
|
||||
class ImagesInfo {
|
||||
final String imageAr;
|
||||
final String imageEn;
|
||||
final bool isAsset;
|
||||
|
||||
ImagesInfo({this.imageAr, this.imageEn});
|
||||
ImagesInfo({this.imageAr, this.imageEn, this.isAsset = false});
|
||||
}
|
||||
|
@ -0,0 +1,148 @@
|
||||
import 'package:diplomaticquarterapp/config/config.dart';
|
||||
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||
import 'package:diplomaticquarterapp/core/viewModels/AlHabibMedicalService/add_new_address_Request_Model.dart';
|
||||
import 'package:diplomaticquarterapp/core/viewModels/AlHabibMedicalService/cmc_view_model.dart';
|
||||
import 'package:diplomaticquarterapp/core/viewModels/AlHabibMedicalService/home_health_care_view_model.dart';
|
||||
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
|
||||
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/utils.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:google_maps_flutter/google_maps_flutter.dart';
|
||||
import 'package:google_maps_place_picker/google_maps_place_picker.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
class CMCLocationPage extends StatefulWidget {
|
||||
final Function(PickResult) onPick;
|
||||
final double latitude;
|
||||
final double longitude;
|
||||
final dynamic model;
|
||||
|
||||
const CMCLocationPage({Key key, this.onPick, this.latitude, this.longitude, this.model})
|
||||
: super(key: key);
|
||||
|
||||
@override
|
||||
_CMCLocationPageState createState() =>
|
||||
_CMCLocationPageState();
|
||||
}
|
||||
|
||||
class _CMCLocationPageState
|
||||
extends State<CMCLocationPage> {
|
||||
double latitude = 0;
|
||||
double longitude = 0;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
|
||||
latitude = widget.latitude;
|
||||
longitude = widget.longitude;
|
||||
super.initState();
|
||||
}
|
||||
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
ProjectViewModel projectViewModel = Provider.of(context);
|
||||
return BaseView<CMCViewModel>(
|
||||
onModelReady: (model) {},
|
||||
builder: (_, model, widget) => AppScaffold(
|
||||
isShowDecPage: false,
|
||||
isShowAppBar: true,
|
||||
baseViewModel: model,
|
||||
body: PlacePicker(
|
||||
apiKey: GOOGLE_API_KEY,
|
||||
enableMyLocationButton: true,
|
||||
automaticallyImplyAppBarLeading: false,
|
||||
autocompleteOnTrailingWhitespace: true,
|
||||
selectInitialPosition: true,
|
||||
autocompleteLanguage: projectViewModel.currentLanguage,
|
||||
enableMapTypeButton: true,
|
||||
searchForInitialValue: false,
|
||||
onPlacePicked: (PickResult result) {
|
||||
print(result.adrAddress);
|
||||
|
||||
},
|
||||
selectedPlaceWidgetBuilder:
|
||||
(_, selectedPlace, state, isSearchBarFocused) {
|
||||
print("state: $state, isSearchBarFocused: $isSearchBarFocused");
|
||||
return isSearchBarFocused
|
||||
? Container()
|
||||
: FloatingCard(
|
||||
bottomPosition: 0.0,
|
||||
leftPosition: 0.0,
|
||||
rightPosition: 0.0,
|
||||
width: 500,
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
child: state == SearchingState.Searching
|
||||
? Center(child: CircularProgressIndicator())
|
||||
: Container(
|
||||
margin: EdgeInsets.all(12),
|
||||
child: Column(
|
||||
children: [
|
||||
SecondaryButton(
|
||||
color: Colors.grey[800],
|
||||
textColor: Colors.white,
|
||||
onTap: () async {
|
||||
print(selectedPlace);
|
||||
AddNewAddressRequestModel
|
||||
addNewAddressRequestModel =
|
||||
new AddNewAddressRequestModel(
|
||||
customer: Customer(addresses: [
|
||||
Addresses(
|
||||
address1:
|
||||
selectedPlace.formattedAddress,
|
||||
address2: selectedPlace
|
||||
.formattedAddress,
|
||||
customerAttributes: "",
|
||||
city: "",
|
||||
createdOnUtc: "",
|
||||
id: 0,
|
||||
latLong: "$latitude,$longitude",
|
||||
email: "")
|
||||
]),
|
||||
);
|
||||
|
||||
selectedPlace.addressComponents.forEach((e) {
|
||||
if (e.types.contains("country")) {
|
||||
addNewAddressRequestModel.customer
|
||||
.addresses[0].country = e.longName;
|
||||
}
|
||||
if (e.types.contains("postal_code")) {
|
||||
addNewAddressRequestModel.customer
|
||||
.addresses[0].zipPostalCode =
|
||||
e.longName;
|
||||
}
|
||||
if (e.types.contains("locality")) {
|
||||
addNewAddressRequestModel.customer
|
||||
.addresses[0].city =
|
||||
e.longName;
|
||||
}
|
||||
});
|
||||
|
||||
await model.addAddressInfo(
|
||||
addNewAddressRequestModel: addNewAddressRequestModel);
|
||||
if (model.state == ViewState.ErrorLocal) {
|
||||
Utils.showErrorToast(model.error);
|
||||
} else {
|
||||
AppToast.showSuccessToast(
|
||||
message: "Address Added Successfully");
|
||||
}
|
||||
Navigator.of(context).pop();
|
||||
},
|
||||
label: TranslationBase.of(context).addNewAddress,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
initialPosition: LatLng(latitude, longitude),
|
||||
useCurrentLocation: false,
|
||||
),
|
||||
));
|
||||
}
|
||||
}
|
@ -1,68 +0,0 @@
|
||||
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hexcolor/hexcolor.dart';
|
||||
import 'cmc_page.dart';
|
||||
|
||||
class CMCIndexPage extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return AppScaffold(
|
||||
isShowAppBar: true,
|
||||
appBarTitle: TranslationBase.of(context).serviceInformation,
|
||||
body: SingleChildScrollView(
|
||||
padding: EdgeInsets.all(12),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: <Widget>[
|
||||
Texts(
|
||||
"CMC",
|
||||
fontWeight: FontWeight.normal,
|
||||
fontSize: 25,
|
||||
color: Color(0xff60686b),
|
||||
),
|
||||
SizedBox(
|
||||
height: 12,
|
||||
),
|
||||
Texts(
|
||||
"This service is designed to help you to set drinking water goals and track the volume of water you are drinking on a daily basis. This service allows for schedule reminders and offers a basic statistical analysis of the amount of what you have consumed over the course of a day, week or month.",
|
||||
fontWeight: FontWeight.normal,
|
||||
fontSize: 17,
|
||||
),
|
||||
SizedBox(
|
||||
height: 22,
|
||||
),
|
||||
Center(
|
||||
child: Image.asset(
|
||||
'assets/images/AlHabibMedicalService/Wifi-AR.png')),
|
||||
SizedBox(
|
||||
height: 77,
|
||||
),
|
||||
],
|
||||
)),
|
||||
bottomSheet: Container(
|
||||
height: MediaQuery.of(context).size.height * 0.10,
|
||||
width: double.infinity,
|
||||
child: Column(
|
||||
children: <Widget>[
|
||||
Container(
|
||||
width: MediaQuery.of(context).size.width * 0.9,
|
||||
child: SecondaryButton(
|
||||
onTap: () => Navigator.push(
|
||||
context,
|
||||
FadePage(
|
||||
page: CMCPage(),
|
||||
),
|
||||
),
|
||||
label: "CMC",
|
||||
textColor: Theme.of(context).backgroundColor),
|
||||
),
|
||||
],
|
||||
),
|
||||
));
|
||||
}
|
||||
}
|
@ -0,0 +1,146 @@
|
||||
import 'package:diplomaticquarterapp/config/config.dart';
|
||||
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||
import 'package:diplomaticquarterapp/core/viewModels/AlHabibMedicalService/add_new_address_Request_Model.dart';
|
||||
import 'package:diplomaticquarterapp/core/viewModels/AlHabibMedicalService/home_health_care_view_model.dart';
|
||||
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
|
||||
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/utils.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:google_maps_flutter/google_maps_flutter.dart';
|
||||
import 'package:google_maps_place_picker/google_maps_place_picker.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
class LocationPage extends StatefulWidget {
|
||||
final Function(PickResult) onPick;
|
||||
final double latitude;
|
||||
final double longitude;
|
||||
final dynamic model;
|
||||
|
||||
const LocationPage({Key key, this.onPick, this.latitude, this.longitude, this.model})
|
||||
: super(key: key);
|
||||
|
||||
@override
|
||||
_LocationPageState createState() =>
|
||||
_LocationPageState();
|
||||
}
|
||||
|
||||
class _LocationPageState
|
||||
extends State<LocationPage> {
|
||||
double latitude = 0;
|
||||
double longitude = 0;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
|
||||
latitude = widget.latitude;
|
||||
longitude = widget.longitude;
|
||||
super.initState();
|
||||
}
|
||||
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
ProjectViewModel projectViewModel = Provider.of(context);
|
||||
return BaseView<HomeHealthCareViewModel>(
|
||||
onModelReady: (model) {},
|
||||
builder: (_, model, widget) => AppScaffold(
|
||||
isShowDecPage: false,
|
||||
isShowAppBar: true,
|
||||
baseViewModel: model,
|
||||
body: PlacePicker(
|
||||
apiKey: GOOGLE_API_KEY,
|
||||
enableMyLocationButton: true,
|
||||
automaticallyImplyAppBarLeading: false,
|
||||
autocompleteOnTrailingWhitespace: true,
|
||||
selectInitialPosition: true,
|
||||
autocompleteLanguage: projectViewModel.currentLanguage,
|
||||
enableMapTypeButton: true,
|
||||
searchForInitialValue: false,
|
||||
onPlacePicked: (PickResult result) {
|
||||
print(result.adrAddress);
|
||||
|
||||
},
|
||||
selectedPlaceWidgetBuilder:
|
||||
(_, selectedPlace, state, isSearchBarFocused) {
|
||||
print("state: $state, isSearchBarFocused: $isSearchBarFocused");
|
||||
return isSearchBarFocused
|
||||
? Container()
|
||||
: FloatingCard(
|
||||
bottomPosition: 0.0,
|
||||
leftPosition: 0.0,
|
||||
rightPosition: 0.0,
|
||||
width: 500,
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
child: state == SearchingState.Searching
|
||||
? Center(child: CircularProgressIndicator())
|
||||
: Container(
|
||||
margin: EdgeInsets.all(12),
|
||||
child: Column(
|
||||
children: [
|
||||
SecondaryButton(
|
||||
color: Colors.grey[800],
|
||||
textColor: Colors.white,
|
||||
onTap: () async {
|
||||
AddNewAddressRequestModel
|
||||
addNewAddressRequestModel =
|
||||
new AddNewAddressRequestModel(
|
||||
customer: Customer(addresses: [
|
||||
Addresses(
|
||||
address1:
|
||||
selectedPlace.formattedAddress,
|
||||
address2: selectedPlace
|
||||
.formattedAddress,
|
||||
customerAttributes: "",
|
||||
city: "",
|
||||
createdOnUtc: "",
|
||||
id: 0,
|
||||
latLong: "$latitude,$longitude",
|
||||
email: "")
|
||||
]),
|
||||
);
|
||||
|
||||
selectedPlace.addressComponents.forEach((e) {
|
||||
if (e.types.contains("country")) {
|
||||
addNewAddressRequestModel.customer
|
||||
.addresses[0].country = e.longName;
|
||||
}
|
||||
if (e.types.contains("postal_code")) {
|
||||
addNewAddressRequestModel.customer
|
||||
.addresses[0].zipPostalCode =
|
||||
e.longName;
|
||||
}
|
||||
if (e.types.contains("locality")) {
|
||||
addNewAddressRequestModel.customer
|
||||
.addresses[0].city =
|
||||
e.longName;
|
||||
}
|
||||
});
|
||||
|
||||
await model.addAddressInfo(
|
||||
addNewAddressRequestModel: addNewAddressRequestModel);
|
||||
if (model.state == ViewState.ErrorLocal) {
|
||||
Utils.showErrorToast(model.error);
|
||||
} else {
|
||||
AppToast.showSuccessToast(
|
||||
message: "Address Added Successfully");
|
||||
}
|
||||
Navigator.of(context).pop();
|
||||
},
|
||||
label: TranslationBase.of(context).addNewAddress,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
initialPosition: LatLng(latitude, longitude),
|
||||
useCurrentLocation: false,
|
||||
),
|
||||
));
|
||||
}
|
||||
}
|
@ -0,0 +1,139 @@
|
||||
import 'package:diplomaticquarterapp/core/service/AlHabibMedicalService/customer_addresses_service.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
// ignore: must_be_immutable
|
||||
class SelectLocationDialog extends StatefulWidget {
|
||||
final List<AddressInfo> addresses;
|
||||
final Function(AddressInfo) onValueSelected;
|
||||
AddressInfo selectedAddress;
|
||||
|
||||
SelectLocationDialog(
|
||||
{Key key, this.addresses, this.onValueSelected, this.selectedAddress});
|
||||
|
||||
@override
|
||||
_SelectLocationDialogState createState() => _SelectLocationDialogState();
|
||||
}
|
||||
|
||||
class _SelectLocationDialogState extends State<SelectLocationDialog> {
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
widget.selectedAddress = widget.selectedAddress ?? widget.addresses[0];
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return SimpleDialog(
|
||||
title: Texts(TranslationBase.of(context).selectAddress),
|
||||
children: [
|
||||
Column(
|
||||
children: [
|
||||
Container(
|
||||
height: 150,
|
||||
child: SingleChildScrollView(
|
||||
child: Column(
|
||||
children: [
|
||||
Divider(),
|
||||
...List.generate(
|
||||
widget.addresses.length,
|
||||
(index) => Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
SizedBox(
|
||||
height: 2,
|
||||
),
|
||||
Row(
|
||||
children: <Widget>[
|
||||
Expanded(
|
||||
flex: 1,
|
||||
child: InkWell(
|
||||
onTap: () {
|
||||
setState(() {
|
||||
widget.selectedAddress = widget.addresses[index];
|
||||
});
|
||||
},
|
||||
child: ListTile(
|
||||
title: Text(widget.addresses[index].address1),
|
||||
leading: Radio(
|
||||
value: widget.addresses[index],
|
||||
groupValue: widget.selectedAddress,
|
||||
activeColor: Colors.red[800],
|
||||
onChanged: (value) {
|
||||
setState(() {
|
||||
widget.selectedAddress = value;
|
||||
});
|
||||
},
|
||||
),
|
||||
),
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
SizedBox(
|
||||
height: 5.0,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 5.0,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
Row(
|
||||
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: <Widget>[
|
||||
Expanded(
|
||||
flex: 1,
|
||||
child: InkWell(
|
||||
onTap: () {
|
||||
Navigator.pop(context);
|
||||
},
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Container(
|
||||
child: Center(
|
||||
child: Texts(
|
||||
TranslationBase.of(context).cancel.toUpperCase(),
|
||||
color: Colors.red,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Container(
|
||||
width: 1,
|
||||
height: 30,
|
||||
color: Colors.grey[500],
|
||||
),
|
||||
Expanded(
|
||||
flex: 1,
|
||||
child: InkWell(
|
||||
onTap: () {
|
||||
widget.onValueSelected(widget.selectedAddress);
|
||||
Navigator.pop(context);
|
||||
},
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Center(
|
||||
child: Texts(
|
||||
TranslationBase.of(context).ok,
|
||||
fontWeight: FontWeight.w400,
|
||||
)),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
],
|
||||
)
|
||||
],
|
||||
);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue