|
|
|
|
@ -1,3 +1,5 @@
|
|
|
|
|
import 'dart:ui';
|
|
|
|
|
|
|
|
|
|
import 'package:diplomaticquarterapp/core/model/pharmacies/Addresses.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/core/viewModels/pharmacyModule/OrderPreviewViewModel.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/pharmacies/screens/cart-page/payment_bottom_widget.dart';
|
|
|
|
|
@ -82,88 +84,96 @@ class _OrderPreviewPageState extends State<OrderPreviewPage> {
|
|
|
|
|
widget.model.paymentCheckoutData.lacumInformation != null
|
|
|
|
|
? AbsorbPointer(
|
|
|
|
|
absorbing: true,
|
|
|
|
|
child: Container(
|
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
// LakumWidget(widget.model),
|
|
|
|
|
Container(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
padding: EdgeInsets.symmetric(vertical: 12, horizontal: 12),
|
|
|
|
|
child: Row(
|
|
|
|
|
children: [
|
|
|
|
|
Row(
|
|
|
|
|
child: Stack(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
// LakumWidget(widget.model),
|
|
|
|
|
Container(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
padding: EdgeInsets.symmetric(vertical: 12, horizontal: 12),
|
|
|
|
|
child: Row(
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 24.0,
|
|
|
|
|
width: 24.0,
|
|
|
|
|
child: Checkbox(
|
|
|
|
|
activeColor: CustomColors.green,
|
|
|
|
|
value: isChecked,
|
|
|
|
|
onChanged: (bool value) {
|
|
|
|
|
setState(() {
|
|
|
|
|
isChecked = value;
|
|
|
|
|
print(isChecked);
|
|
|
|
|
if (value){
|
|
|
|
|
// isChecked;
|
|
|
|
|
PaymentBottomWidget.isChecked = true;
|
|
|
|
|
print(value);
|
|
|
|
|
}else{
|
|
|
|
|
PaymentBottomWidget.isChecked = false;
|
|
|
|
|
}
|
|
|
|
|
setState(() {
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: const EdgeInsets.only(left: 8.0, right: 8.0),
|
|
|
|
|
child: Text(
|
|
|
|
|
TranslationBase.of(context).useLakumPoints +
|
|
|
|
|
" (${widget.model.paymentCheckoutData.lacumInformation.lakumInquiryInformationObjVersion.pointsBalance.toString() + " " + TranslationBase.of(context).points})",
|
|
|
|
|
style: TextStyle(fontSize: 12.0, fontWeight: FontWeight.w600, letterSpacing: -0.56)),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
child: Container(
|
|
|
|
|
decoration: BoxDecoration(color: Color(0x99ffffff)),
|
|
|
|
|
padding: const EdgeInsets.symmetric(horizontal: 8),
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.end,
|
|
|
|
|
Row(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
decoration: BoxDecoration(color: Color(0x99ffffff)),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Texts(
|
|
|
|
|
"${TranslationBase.of(context).availableBalance}",
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
),
|
|
|
|
|
Text(
|
|
|
|
|
"${TranslationBase.of(context).sar + " " + widget.model.paymentCheckoutData.lacumInformation.lakumInquiryInformationObjVersion.pointsBalanceAmount.toString()}",
|
|
|
|
|
style: TextStyle(fontSize: 12.0, fontWeight: FontWeight.w600, letterSpacing: -0.56)
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 24.0,
|
|
|
|
|
width: 24.0,
|
|
|
|
|
child: Checkbox(
|
|
|
|
|
activeColor: CustomColors.green,
|
|
|
|
|
value: isChecked,
|
|
|
|
|
onChanged: (bool value) {
|
|
|
|
|
setState(() {
|
|
|
|
|
isChecked = value;
|
|
|
|
|
print(isChecked);
|
|
|
|
|
if (value){
|
|
|
|
|
// isChecked;
|
|
|
|
|
PaymentBottomWidget.isChecked = true;
|
|
|
|
|
print(value);
|
|
|
|
|
}else{
|
|
|
|
|
PaymentBottomWidget.isChecked = false;
|
|
|
|
|
}
|
|
|
|
|
setState(() {
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: const EdgeInsets.only(left: 8.0, right: 8.0),
|
|
|
|
|
child: Text(
|
|
|
|
|
TranslationBase.of(context).useLakumPoints +
|
|
|
|
|
" (${widget.model.paymentCheckoutData.lacumInformation.lakumInquiryInformationObjVersion.pointsBalance.toString() + " " + TranslationBase.of(context).points})",
|
|
|
|
|
style: TextStyle(fontSize: 12.0, fontWeight: FontWeight.w600, letterSpacing: -0.56)),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
child: Container(
|
|
|
|
|
decoration: BoxDecoration(color: Color(0x99ffffff)),
|
|
|
|
|
padding: const EdgeInsets.symmetric(horizontal: 8),
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.end,
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
decoration: BoxDecoration(color: Color(0x99ffffff)),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Texts(
|
|
|
|
|
"${TranslationBase.of(context).availableBalance}",
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
),
|
|
|
|
|
Text(
|
|
|
|
|
"${TranslationBase.of(context).sar + " " + widget.model.paymentCheckoutData.lacumInformation.lakumInquiryInformationObjVersion.pointsBalanceAmount.toString()}",
|
|
|
|
|
style: TextStyle(fontSize: 12.0, fontWeight: FontWeight.w600, letterSpacing: -0.56)
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 10,
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 10,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
height: MediaQuery.of(context).size.height * .10,
|
|
|
|
|
color: Colors.white.withOpacity(0.6),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container(),
|
|
|
|
|
Container(
|
|
|
|
|
|