Browse Source

订单详情店铺选择更改

new_revision_app
wurong 2 years ago
parent
commit
791cc21d1f
  1. 131
      lib/settlement/settlement.dart

131
lib/settlement/settlement.dart

@ -1127,7 +1127,7 @@ class _Settlement extends State<Settlement> {
date.timeZoneOffset.inHours.toString()); date.timeZoneOffset.inHours.toString());
}, onConfirm: (date) { }, onConfirm: (date) {
reservationTime = date.toString().substring(0, 16); reservationTime = date.toString().substring(0, 16);
subTime = date.toString().substring(0, 19); subTime = date.toUtc().toIso8601String().toString();
setState(() {}); setState(() {});
}, currentTime: minTime, locale: LocaleType.zh); }, currentTime: minTime, locale: LocaleType.zh);
} }
@ -1142,7 +1142,7 @@ class _Settlement extends State<Settlement> {
) { ) {
return Container( return Container(
width: double.infinity, width: double.infinity,
height: 270.h, height: 280.h,
padding: EdgeInsets.symmetric(horizontal: 14.w, vertical: 16.h), padding: EdgeInsets.symmetric(horizontal: 14.w, vertical: 16.h),
decoration: new BoxDecoration( decoration: new BoxDecoration(
color: Colors.white, color: Colors.white,
@ -1155,38 +1155,69 @@ class _Settlement extends State<Settlement> {
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Container( // Container(
padding: // padding: EdgeInsets.symmetric(vertical: 10.h, horizontal: 14.w),
EdgeInsets.symmetric(vertical: 10.h, horizontal: 14.w), // child: Row(
child: Row( // mainAxisAlignment: MainAxisAlignment.spaceBetween,
mainAxisAlignment: MainAxisAlignment.spaceBetween, // children: [
children: [ // GestureDetector(
GestureDetector( // onTap: () {
onTap: () { // Navigator.of(context).pop();
// },
// child: Text(
// S.of(context).quxiao,
// style:
// TextStyle(fontSize: 18.sp, color: Colors.black),
// ),
// ),
// GestureDetector(
// onTap: () {
// setState(() {
// subscribeStoresName =
// subscribeParam.stores[storesIndex];
// });
// Navigator.of(context).pop();
// },
// child: Text(
// S.of(context).queding,
// style: TextStyle(
// fontSize: 18.sp, color: Color(0xFF32A060)),
// ),
// ),
// ],
// ),
// ),
Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Expanded(
child: Container(
alignment: Alignment.center,
margin: EdgeInsets.symmetric(vertical:5.h),
child: Text(
"请选择预约门店",
style: TextStyle(
fontWeight: MyFontWeight.bold,
fontSize: 15.sp,
color: Color(0xFF353535),
),
),
)),
GestureDetector(
onTap: () {
setState(() {
Navigator.of(context).pop(); Navigator.of(context).pop();
}, });
child: Text( },
S.of(context).quxiao, child: Icon(
style: Icons.clear,
TextStyle(fontSize: 18.sp, color: Colors.black), color: Colors.black,
), size: 18,
), ),
GestureDetector( ),
onTap: () { // SizedBox(width:4.w),
setState(() { ],
subscribeStoresName =
subscribeParam.stores[storesIndex];
});
Navigator.of(context).pop();
},
child: Text(
S.of(context).queding,
style: TextStyle(
fontSize: 18.sp, color: Color(0xFF32A060)),
),
)
],
),
), ),
Expanded( Expanded(
child: ListView.builder( child: ListView.builder(
@ -1202,6 +1233,33 @@ class _Settlement extends State<Settlement> {
); );
}), }),
), ),
GestureDetector(
onTap: (){
setState(() {
subscribeStoresName =
subscribeParam.stores[storesIndex];
});
Navigator.of(context).pop();
},
child: Container(
width: double.infinity,
height: 40.h,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(100),
color:Color(0xFF32A060),
),
alignment: Alignment.center,
margin: EdgeInsets.only(bottom: 10.h,),
child: Text(
S.of(context).queding,
style: TextStyle(
fontWeight: MyFontWeight.bold,
fontSize: 16.sp,
color: Color(0xFFFFFFFF),
),
),
),
),
], ],
), ),
); );
@ -1214,8 +1272,17 @@ class _Settlement extends State<Settlement> {
Widget storesNameItem(index) { Widget storesNameItem(index) {
return Container( return Container(
width: double.infinity, width: double.infinity,
margin: EdgeInsets.symmetric(vertical:8.h),
padding: EdgeInsets.symmetric(vertical: 10.h), padding: EdgeInsets.symmetric(vertical: 10.h),
alignment: Alignment.center, alignment: Alignment.center,
decoration: BoxDecoration(
borderRadius:BorderRadius.circular(6),
border: Border.all(
color: storesIndex == index ? Color(0xFF32A060):Color(0xFFF7F7F7),
width: storesIndex == index ? 1 :0,
),
color: storesIndex == index ? Color(0xFFF0FAF4) :Color(0xFFF7F7F7),
),
child: Text( child: Text(
subscribeParam.stores[index], subscribeParam.stores[index],
style: TextStyle( style: TextStyle(

Loading…
Cancel
Save