|
...
|
...
|
@@ -199,7 +199,7 @@ class DialogUtil { |
|
|
|
TableCalendar(
|
|
|
|
calendarController: _calendarController,
|
|
|
|
initialSelectedDay: selectDateTime,
|
|
|
|
onDaySelected: (day, events,holidays) {
|
|
|
|
onDaySelected: (day, events) {
|
|
|
|
Navigator.of(dialogContext).pop(day);
|
|
|
|
},
|
|
|
|
availableGestures: AvailableGestures.none,
|
|
...
|
...
|
@@ -527,7 +527,8 @@ class DialogUtil { |
|
|
|
}
|
|
|
|
|
|
|
|
//显示桌位管理弹框
|
|
|
|
static Future<int> showTableManagerDialog(BuildContext context,t.Table table) {
|
|
|
|
static Future<int> showTableManagerDialog(
|
|
|
|
BuildContext context, t.Table table) {
|
|
|
|
return showModalBottomSheet(
|
|
|
|
context: context,
|
|
|
|
builder: (context) {
|
|
...
|
...
|
@@ -540,43 +541,60 @@ class DialogUtil { |
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
padding: EdgeInsets.symmetric(vertical: ScreenUtil().setWidth(20)),
|
|
|
|
child: Text("${table.name}",style: TextStyle(fontSize: ScreenUtil().setSp(30),color: MyColours.color_999999),),
|
|
|
|
padding:
|
|
|
|
EdgeInsets.symmetric(vertical: ScreenUtil().setWidth(20)),
|
|
|
|
child: Text(
|
|
|
|
"${table.name}",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: ScreenUtil().setSp(30),
|
|
|
|
color: MyColours.color_999999),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Offstage(
|
|
|
|
offstage: table.enable=="0",
|
|
|
|
offstage: table.enable == "0",
|
|
|
|
child: Column(
|
|
|
|
mainAxisSize: MainAxisSize.min,
|
|
|
|
children: [
|
|
|
|
Offstage(
|
|
|
|
offstage: !(table.signStr=="已预订"||table.signStr=="用餐中"),
|
|
|
|
child: GestureDetector(
|
|
|
|
behavior: HitTestBehavior.opaque,
|
|
|
|
onTap: (){
|
|
|
|
Navigator.of(context).pop(1);
|
|
|
|
},
|
|
|
|
child: Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
padding: EdgeInsets.symmetric(vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text("查看详情",style: TextStyle(fontSize: ScreenUtil().setSp(34),color: MyColours.color_353535),),
|
|
|
|
),
|
|
|
|
)
|
|
|
|
),
|
|
|
|
offstage: !(table.signStr == "已预订" ||
|
|
|
|
table.signStr == "用餐中"),
|
|
|
|
child: GestureDetector(
|
|
|
|
behavior: HitTestBehavior.opaque,
|
|
|
|
onTap: () {
|
|
|
|
Navigator.of(context).pop(1);
|
|
|
|
},
|
|
|
|
child: Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
padding: EdgeInsets.symmetric(
|
|
|
|
vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text(
|
|
|
|
"查看详情",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: ScreenUtil().setSp(34),
|
|
|
|
color: MyColours.color_353535),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
)),
|
|
|
|
Offstage(
|
|
|
|
offstage: table.signStr!="",
|
|
|
|
offstage: table.signStr != "",
|
|
|
|
child: GestureDetector(
|
|
|
|
behavior: HitTestBehavior.opaque,
|
|
|
|
onTap: (){
|
|
|
|
Navigator.of(context).pop(2);
|
|
|
|
},
|
|
|
|
child: Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
padding: EdgeInsets.symmetric(vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text("订座",style: TextStyle(fontSize: ScreenUtil().setSp(34),color: MyColours.color_353535),),
|
|
|
|
)
|
|
|
|
),
|
|
|
|
behavior: HitTestBehavior.opaque,
|
|
|
|
onTap: () {
|
|
|
|
Navigator.of(context).pop(2);
|
|
|
|
},
|
|
|
|
child: Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
padding: EdgeInsets.symmetric(
|
|
|
|
vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text(
|
|
|
|
"订座",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: ScreenUtil().setSp(34),
|
|
|
|
color: MyColours.color_353535),
|
|
|
|
),
|
|
|
|
)),
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
...
|
...
|
@@ -588,16 +606,21 @@ class DialogUtil { |
|
|
|
),
|
|
|
|
GestureDetector(
|
|
|
|
behavior: HitTestBehavior.opaque,
|
|
|
|
onTap: (){
|
|
|
|
onTap: () {
|
|
|
|
Navigator.of(context).pop(3);
|
|
|
|
},
|
|
|
|
child: Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
padding: EdgeInsets.symmetric(vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text("${table.enable=='1'?'停用桌位':'启用桌位'}",style: TextStyle(fontSize: ScreenUtil().setSp(34),color: MyColours.color_353535),),
|
|
|
|
)
|
|
|
|
),
|
|
|
|
padding: EdgeInsets.symmetric(
|
|
|
|
vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text(
|
|
|
|
"${table.enable == '1' ? '停用桌位' : '启用桌位'}",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: ScreenUtil().setSp(34),
|
|
|
|
color: MyColours.color_353535),
|
|
|
|
),
|
|
|
|
)),
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
height: ScreenUtil().setWidth(10),
|
|
...
|
...
|
@@ -605,16 +628,21 @@ class DialogUtil { |
|
|
|
),
|
|
|
|
GestureDetector(
|
|
|
|
behavior: HitTestBehavior.opaque,
|
|
|
|
onTap: (){
|
|
|
|
onTap: () {
|
|
|
|
Navigator.of(context).pop();
|
|
|
|
},
|
|
|
|
child: Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
padding: EdgeInsets.symmetric(vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text("取消",style: TextStyle(fontSize: ScreenUtil().setSp(34),color: MyColours.color_353535),),
|
|
|
|
)
|
|
|
|
),
|
|
|
|
padding: EdgeInsets.symmetric(
|
|
|
|
vertical: ScreenUtil().setWidth(40)),
|
|
|
|
child: Text(
|
|
|
|
"取消",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: ScreenUtil().setSp(34),
|
|
|
|
color: MyColours.color_353535),
|
|
|
|
),
|
|
|
|
)),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
);
|
...
|
...
|
|