Showing
16 changed files
with
305 additions
and
102 deletions
| @@ -55,7 +55,7 @@ class Table { | @@ -55,7 +55,7 @@ class Table { | ||
| 55 | 55 | ||
| 56 | //获取最低消费 | 56 | //获取最低消费 |
| 57 | String get lowStr{ | 57 | String get lowStr{ |
| 58 | - return (low==null||low.isEmpty||low=="0")?"":"最低消费$low元"; | 58 | + return (low==null||low.isEmpty||low=="0")?"":"最低消费\n$low元"; |
| 59 | } | 59 | } |
| 60 | 60 | ||
| 61 | String get signStr{ | 61 | String get signStr{ |
| @@ -13,6 +13,7 @@ import 'package:one_key/utils/utils.dart'; | @@ -13,6 +13,7 @@ import 'package:one_key/utils/utils.dart'; | ||
| 13 | import 'package:one_key/widgets/MyDivider.dart'; | 13 | import 'package:one_key/widgets/MyDivider.dart'; |
| 14 | import 'package:one_key/widgets/app_bar.dart'; | 14 | import 'package:one_key/widgets/app_bar.dart'; |
| 15 | import 'package:one_key/widgets/common_button.dart'; | 15 | import 'package:one_key/widgets/common_button.dart'; |
| 16 | +import 'package:one_key/widgets/need_item.dart'; | ||
| 16 | import 'package:one_key/widgets/row_multi_text.dart'; | 17 | import 'package:one_key/widgets/row_multi_text.dart'; |
| 17 | import 'package:one_key/widgets/table_item.dart'; | 18 | import 'package:one_key/widgets/table_item.dart'; |
| 18 | import 'package:one_key/models/table.dart' as t; | 19 | import 'package:one_key/models/table.dart' as t; |
| @@ -83,19 +84,19 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -83,19 +84,19 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 83 | showDialog(context: context,builder: (context){ | 84 | showDialog(context: context,builder: (context){ |
| 84 | return AlertDialog( | 85 | return AlertDialog( |
| 85 | title: Text("确定拒绝订单吗?\n拒绝后无法联系客户"), | 86 | title: Text("确定拒绝订单吗?\n拒绝后无法联系客户"), |
| 86 | - titleTextStyle: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(26)), | 87 | + titleTextStyle: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(32)), |
| 87 | content: Text("如果包间类型订满,请及时停用"), | 88 | content: Text("如果包间类型订满,请及时停用"), |
| 88 | - contentTextStyle:TextStyle(color: MyColours.color_828282,fontSize: ScreenUtil().setSp(22)), | 89 | + contentTextStyle:TextStyle(color: MyColours.color_828282,fontSize: ScreenUtil().setSp(28)), |
| 89 | actions: <Widget>[ | 90 | actions: <Widget>[ |
| 90 | FlatButton( | 91 | FlatButton( |
| 91 | - child: Text("拒绝订单"), | 92 | + child: Text("拒绝订单",style: TextStyle(fontSize: ScreenUtil().setSp(32)),), |
| 92 | onPressed: (){ | 93 | onPressed: (){ |
| 93 | Navigator.of(context).pop(); | 94 | Navigator.of(context).pop(); |
| 94 | setReserveStatus("6"); | 95 | setReserveStatus("6"); |
| 95 | }, | 96 | }, |
| 96 | ), | 97 | ), |
| 97 | FlatButton( | 98 | FlatButton( |
| 98 | - child: Text("去安排"), | 99 | + child: Text("去安排",style: TextStyle(fontSize: ScreenUtil().setSp(32)),), |
| 99 | onPressed: () async { | 100 | onPressed: () async { |
| 100 | Navigator.of(context).pop(); | 101 | Navigator.of(context).pop(); |
| 101 | String tid=await NavigatorUtil.goSelectTablePage(context,widget.rid,DateTime.fromMillisecondsSinceEpoch(int.parse(detailEntity.ddate)*1000),detailEntity.ddate_solt); | 102 | String tid=await NavigatorUtil.goSelectTablePage(context,widget.rid,DateTime.fromMillisecondsSinceEpoch(int.parse(detailEntity.ddate)*1000),detailEntity.ddate_solt); |
| @@ -181,13 +182,13 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -181,13 +182,13 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 181 | child: Row( | 182 | child: Row( |
| 182 | mainAxisSize: MainAxisSize.min, | 183 | mainAxisSize: MainAxisSize.min, |
| 183 | children: detailEntity.demands.map((table){ | 184 | children: detailEntity.demands.map((table){ |
| 184 | - return TableItem(table); | 185 | + return NeedItem(table); |
| 185 | }).toList(), | 186 | }).toList(), |
| 186 | ), | 187 | ), |
| 187 | ), | 188 | ), |
| 188 | RowMultiText("客户姓名", detailEntity.rnameStr), | 189 | RowMultiText("客户姓名", detailEntity.rnameStr), |
| 189 | RowMultiText("客户电话", detailEntity.phone), | 190 | RowMultiText("客户电话", detailEntity.phone), |
| 190 | - MyDivider(double.infinity, ScreenUtil().setHeight(2)), | 191 | + MyDivider(double.infinity, ScreenUtil().setHeight(1)), |
| 191 | Container( | 192 | Container( |
| 192 | color: MyColours.color_ffffff, | 193 | color: MyColours.color_ffffff, |
| 193 | width: double.infinity, | 194 | width: double.infinity, |
| @@ -202,7 +203,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -202,7 +203,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 202 | "客户经理", | 203 | "客户经理", |
| 203 | style: TextStyle( | 204 | style: TextStyle( |
| 204 | color: MyColours.color_828282, | 205 | color: MyColours.color_828282, |
| 205 | - fontSize: ScreenUtil().setSp(22)), | 206 | + fontSize: ScreenUtil().setSp(30)), |
| 206 | ), | 207 | ), |
| 207 | ), | 208 | ), |
| 208 | Positioned( | 209 | Positioned( |
| @@ -224,7 +225,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -224,7 +225,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 224 | cusmanText, | 225 | cusmanText, |
| 225 | style: TextStyle( | 226 | style: TextStyle( |
| 226 | color: MyColours.color_353535, | 227 | color: MyColours.color_353535, |
| 227 | - fontSize: ScreenUtil().setSp(26), | 228 | + fontSize: ScreenUtil().setSp(30), |
| 228 | decoration: TextDecoration.underline, | 229 | decoration: TextDecoration.underline, |
| 229 | ), | 230 | ), |
| 230 | ), | 231 | ), |
| @@ -233,7 +234,6 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -233,7 +234,6 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 233 | ], | 234 | ], |
| 234 | ), | 235 | ), |
| 235 | ), | 236 | ), |
| 236 | - MyDivider(double.infinity, ScreenUtil().setHeight(2)), | ||
| 237 | Container( | 237 | Container( |
| 238 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(206)), | 238 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(206)), |
| 239 | child: Column( | 239 | child: Column( |
| @@ -242,7 +242,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -242,7 +242,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 242 | content: "安排包间", | 242 | content: "安排包间", |
| 243 | width: 669, | 243 | width: 669, |
| 244 | height: 76, | 244 | height: 76, |
| 245 | - fontSize: 26, | 245 | + fontSize: 34, |
| 246 | onPress: () async { | 246 | onPress: () async { |
| 247 | String tid=await NavigatorUtil.goSelectTablePage(context,widget.rid,DateTime.fromMillisecondsSinceEpoch(int.parse(detailEntity.ddate)*1000),detailEntity.ddate_solt); | 247 | String tid=await NavigatorUtil.goSelectTablePage(context,widget.rid,DateTime.fromMillisecondsSinceEpoch(int.parse(detailEntity.ddate)*1000),detailEntity.ddate_solt); |
| 248 | if(tid!=null){ | 248 | if(tid!=null){ |
| @@ -269,7 +269,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -269,7 +269,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 269 | "拒绝订单", | 269 | "拒绝订单", |
| 270 | style: TextStyle( | 270 | style: TextStyle( |
| 271 | color: MyColours.color_199095, | 271 | color: MyColours.color_199095, |
| 272 | - fontSize: ScreenUtil().setSp(26)), | 272 | + fontSize: ScreenUtil().setSp(34)), |
| 273 | ), | 273 | ), |
| 274 | ), | 274 | ), |
| 275 | onTap: () { | 275 | onTap: () { |
| @@ -277,7 +277,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -277,7 +277,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 277 | }, | 277 | }, |
| 278 | )), | 278 | )), |
| 279 | MyDivider( | 279 | MyDivider( |
| 280 | - ScreenUtil().setWidth(1), | 280 | + ScreenUtil().setWidth(2), |
| 281 | ScreenUtil().setHeight(52), | 281 | ScreenUtil().setHeight(52), |
| 282 | color: MyColours.color_199095, | 282 | color: MyColours.color_199095, |
| 283 | ), | 283 | ), |
| @@ -288,7 +288,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | @@ -288,7 +288,7 @@ class HandleOnlinePageState extends State<HandleOnlinePage> { | ||
| 288 | "联系顾客", | 288 | "联系顾客", |
| 289 | style: TextStyle( | 289 | style: TextStyle( |
| 290 | color: MyColours.color_199095, | 290 | color: MyColours.color_199095, |
| 291 | - fontSize: ScreenUtil().setSp(26)), | 291 | + fontSize: ScreenUtil().setSp(34)), |
| 292 | ), | 292 | ), |
| 293 | ), | 293 | ), |
| 294 | onTap: () { | 294 | onTap: () { |
| @@ -13,6 +13,7 @@ import 'package:one_key/utils/utils.dart'; | @@ -13,6 +13,7 @@ import 'package:one_key/utils/utils.dart'; | ||
| 13 | import 'package:one_key/widgets/MyDivider.dart'; | 13 | import 'package:one_key/widgets/MyDivider.dart'; |
| 14 | import 'package:one_key/widgets/app_bar.dart'; | 14 | import 'package:one_key/widgets/app_bar.dart'; |
| 15 | import 'package:one_key/widgets/common_button.dart'; | 15 | import 'package:one_key/widgets/common_button.dart'; |
| 16 | +import 'package:one_key/widgets/need_item.dart'; | ||
| 16 | import 'package:one_key/widgets/row_multi_text.dart'; | 17 | import 'package:one_key/widgets/row_multi_text.dart'; |
| 17 | import 'package:one_key/widgets/table_item.dart'; | 18 | import 'package:one_key/widgets/table_item.dart'; |
| 18 | import 'package:one_key/models/table.dart' as t; | 19 | import 'package:one_key/models/table.dart' as t; |
| @@ -120,7 +121,7 @@ class NotebookDetailPageState extends State<NotebookDetailPage> { | @@ -120,7 +121,7 @@ class NotebookDetailPageState extends State<NotebookDetailPage> { | ||
| 120 | child: Row( | 121 | child: Row( |
| 121 | mainAxisSize: MainAxisSize.min, | 122 | mainAxisSize: MainAxisSize.min, |
| 122 | children: detailEntity.demands.map((table){ | 123 | children: detailEntity.demands.map((table){ |
| 123 | - return TableItem(table,height: 160,); | 124 | + return NeedItem(table); |
| 124 | }).toList(), | 125 | }).toList(), |
| 125 | ), | 126 | ), |
| 126 | ) | 127 | ) |
| @@ -52,14 +52,14 @@ class InvicationPageState extends State<InvicationPage>{ | @@ -52,14 +52,14 @@ class InvicationPageState extends State<InvicationPage>{ | ||
| 52 | Image.asset("assets/invication_line_left.png",width: ScreenUtil().setWidth(44),height: ScreenUtil().setWidth(4),), | 52 | Image.asset("assets/invication_line_left.png",width: ScreenUtil().setWidth(44),height: ScreenUtil().setWidth(4),), |
| 53 | Container( | 53 | Container( |
| 54 | margin: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(13)), | 54 | margin: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(13)), |
| 55 | - child: Text(title,style: TextStyle(color: MyColours.color_eadab9,fontSize: ScreenUtil().setSp(22),fontWeight: FontWeight.bold)), | 55 | + child: Text(title,style: TextStyle(color: MyColours.color_eadab9,fontSize: ScreenUtil().setSp(32))), |
| 56 | ), | 56 | ), |
| 57 | Image.asset("assets/invication_line_right.png",width: ScreenUtil().setWidth(44),height: ScreenUtil().setWidth(4),) | 57 | Image.asset("assets/invication_line_right.png",width: ScreenUtil().setWidth(44),height: ScreenUtil().setWidth(4),) |
| 58 | ], | 58 | ], |
| 59 | ), | 59 | ), |
| 60 | Container( | 60 | Container( |
| 61 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(20)), | 61 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(20)), |
| 62 | - child: Text(content,style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(26)),), | 62 | + child: Text(content,style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(34)),), |
| 63 | ) | 63 | ) |
| 64 | ], | 64 | ], |
| 65 | ); | 65 | ); |
| @@ -102,7 +102,7 @@ class InvicationPageState extends State<InvicationPage>{ | @@ -102,7 +102,7 @@ class InvicationPageState extends State<InvicationPage>{ | ||
| 102 | child: Center( | 102 | child: Center( |
| 103 | child: Column( | 103 | child: Column( |
| 104 | children: <Widget>[ | 104 | children: <Widget>[ |
| 105 | - Image.asset("assets/img_ydap.png",width: ScreenUtil().setWidth(444),height: ScreenUtil().setHeight(234),), | 105 | + Image.asset("assets/img_ydap.png",width: ScreenUtil().setWidth(500),height: ScreenUtil().setHeight(300),), |
| 106 | VEmptyView(69), | 106 | VEmptyView(69), |
| 107 | Row( | 107 | Row( |
| 108 | mainAxisSize: MainAxisSize.min, | 108 | mainAxisSize: MainAxisSize.min, |
| @@ -120,7 +120,7 @@ class InvicationPageState extends State<InvicationPage>{ | @@ -120,7 +120,7 @@ class InvicationPageState extends State<InvicationPage>{ | ||
| 120 | border: Border.all(color: MyColours.color_ffffff,width: ScreenUtil().setWidth(2)), | 120 | border: Border.all(color: MyColours.color_ffffff,width: ScreenUtil().setWidth(2)), |
| 121 | borderRadius: BorderRadius.all(Radius.circular(ScreenUtil().setWidth(18))) | 121 | borderRadius: BorderRadius.all(Radius.circular(ScreenUtil().setWidth(18))) |
| 122 | ), | 122 | ), |
| 123 | - child: Text("订包间,用周到安排",style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(22),fontWeight: FontWeight.bold),), | 123 | + child: Text("订包间,用周到安排",style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(28)),), |
| 124 | ), | 124 | ), |
| 125 | Container( | 125 | Container( |
| 126 | width: ScreenUtil().setWidth(108), | 126 | width: ScreenUtil().setWidth(108), |
| @@ -141,14 +141,14 @@ class InvicationPageState extends State<InvicationPage>{ | @@ -141,14 +141,14 @@ class InvicationPageState extends State<InvicationPage>{ | ||
| 141 | Image.asset("assets/invication_map.png",width: ScreenUtil().setWidth(22),height: ScreenUtil().setWidth(28),), | 141 | Image.asset("assets/invication_map.png",width: ScreenUtil().setWidth(22),height: ScreenUtil().setWidth(28),), |
| 142 | Container( | 142 | Container( |
| 143 | margin: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(13)), | 143 | margin: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(13)), |
| 144 | - child: Text("地址导航",style: TextStyle(color: MyColours.color_eadab9,fontSize: ScreenUtil().setSp(22),fontWeight: FontWeight.bold)), | 144 | + child: Text("地址导航",style: TextStyle(color: MyColours.color_eadab9,fontSize: ScreenUtil().setSp(32))), |
| 145 | ), | 145 | ), |
| 146 | Image.asset("assets/invication_arrow_right.png",width: ScreenUtil().setWidth(14),height: ScreenUtil().setWidth(22),), | 146 | Image.asset("assets/invication_arrow_right.png",width: ScreenUtil().setWidth(14),height: ScreenUtil().setWidth(22),), |
| 147 | ], | 147 | ], |
| 148 | ), | 148 | ), |
| 149 | Container( | 149 | Container( |
| 150 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(20)), | 150 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(20)), |
| 151 | - child: Text(user.sellerAddr,style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(26)),), | 151 | + child: Text(user.sellerAddr,style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(34)),), |
| 152 | ) | 152 | ) |
| 153 | ], | 153 | ], |
| 154 | ) | 154 | ) |
| @@ -170,7 +170,7 @@ class InvicationPageState extends State<InvicationPage>{ | @@ -170,7 +170,7 @@ class InvicationPageState extends State<InvicationPage>{ | ||
| 170 | height: double.infinity, | 170 | height: double.infinity, |
| 171 | color: MyColours.color_000000, | 171 | color: MyColours.color_000000, |
| 172 | alignment: Alignment.center, | 172 | alignment: Alignment.center, |
| 173 | - child: Text("发短信",style: TextStyle(color: MyColours.color_eadab9,fontSize: ScreenUtil().setSp(30)),), | 173 | + child: Text("发短信",style: TextStyle(color: MyColours.color_eadab9,fontSize: ScreenUtil().setSp(34)),), |
| 174 | ), | 174 | ), |
| 175 | ), | 175 | ), |
| 176 | Expanded( | 176 | Expanded( |
| @@ -184,7 +184,7 @@ class InvicationPageState extends State<InvicationPage>{ | @@ -184,7 +184,7 @@ class InvicationPageState extends State<InvicationPage>{ | ||
| 184 | height: double.infinity, | 184 | height: double.infinity, |
| 185 | color: MyColours.color_e3d2ac, | 185 | color: MyColours.color_e3d2ac, |
| 186 | alignment: Alignment.center, | 186 | alignment: Alignment.center, |
| 187 | - child: Text("通知客户",style: TextStyle(color: MyColours.color_83734d,fontSize: ScreenUtil().setSp(30)),), | 187 | + child: Text("通知客户",style: TextStyle(color: MyColours.color_83734d,fontSize: ScreenUtil().setSp(34)),), |
| 188 | ), | 188 | ), |
| 189 | ), | 189 | ), |
| 190 | ) | 190 | ) |
| @@ -139,12 +139,13 @@ class LoginState extends State<LoginPage> with WidgetsBindingObserver{ | @@ -139,12 +139,13 @@ class LoginState extends State<LoginPage> with WidgetsBindingObserver{ | ||
| 139 | controller: _sellerCodeController, | 139 | controller: _sellerCodeController, |
| 140 | focusNode: _sellerCodeFocusNode, | 140 | focusNode: _sellerCodeFocusNode, |
| 141 | autofocus: _sellerCodeController.text.isEmpty, | 141 | autofocus: _sellerCodeController.text.isEmpty, |
| 142 | - style: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(28)), | 142 | + style: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(28),textBaseline: TextBaseline.alphabetic), |
| 143 | + textAlignVertical: TextAlignVertical.center, | ||
| 143 | decoration: InputDecoration( | 144 | decoration: InputDecoration( |
| 144 | hintText: "请输入6位商户编码", | 145 | hintText: "请输入6位商户编码", |
| 145 | - hintStyle: TextStyle(color: MyColours.color_c1c1c1,fontSize: ScreenUtil().setSp(28)), | 146 | + hintStyle: TextStyle(color: MyColours.color_c1c1c1,fontSize: ScreenUtil().setSp(28),), |
| 146 | border: InputBorder.none, | 147 | border: InputBorder.none, |
| 147 | - contentPadding: EdgeInsets.symmetric(vertical: ScreenUtil().setHeight(30),horizontal: ScreenUtil().setWidth(30)) | 148 | + contentPadding: EdgeInsets.symmetric(horizontal: 10,vertical: 14), |
| 148 | ), | 149 | ), |
| 149 | onChanged: (_){ | 150 | onChanged: (_){ |
| 150 | setActivate(); | 151 | setActivate(); |
| @@ -180,7 +181,7 @@ class LoginState extends State<LoginPage> with WidgetsBindingObserver{ | @@ -180,7 +181,7 @@ class LoginState extends State<LoginPage> with WidgetsBindingObserver{ | ||
| 180 | hintText: "请输入4位工号", | 181 | hintText: "请输入4位工号", |
| 181 | hintStyle: TextStyle(color: MyColours.color_c1c1c1,fontSize: ScreenUtil().setSp(28)), | 182 | hintStyle: TextStyle(color: MyColours.color_c1c1c1,fontSize: ScreenUtil().setSp(28)), |
| 182 | border: InputBorder.none, | 183 | border: InputBorder.none, |
| 183 | - contentPadding: EdgeInsets.symmetric(vertical: ScreenUtil().setHeight(30),horizontal: ScreenUtil().setWidth(30)) | 184 | + contentPadding: EdgeInsets.symmetric(horizontal: 10,vertical: 14), |
| 184 | ), | 185 | ), |
| 185 | onChanged: (_){ | 186 | onChanged: (_){ |
| 186 | setActivate(); | 187 | setActivate(); |
| @@ -217,7 +218,7 @@ class LoginState extends State<LoginPage> with WidgetsBindingObserver{ | @@ -217,7 +218,7 @@ class LoginState extends State<LoginPage> with WidgetsBindingObserver{ | ||
| 217 | hintText: "请输入密码", | 218 | hintText: "请输入密码", |
| 218 | hintStyle: TextStyle(color: MyColours.color_c1c1c1,fontSize: ScreenUtil().setSp(28)), | 219 | hintStyle: TextStyle(color: MyColours.color_c1c1c1,fontSize: ScreenUtil().setSp(28)), |
| 219 | border: InputBorder.none, | 220 | border: InputBorder.none, |
| 220 | - contentPadding: EdgeInsets.symmetric(vertical: ScreenUtil().setHeight(30),horizontal: ScreenUtil().setWidth(30)) | 221 | + contentPadding: EdgeInsets.symmetric(horizontal: 10,vertical: 14), |
| 221 | ), | 222 | ), |
| 222 | onChanged: (_){ | 223 | onChanged: (_){ |
| 223 | setActivate(); | 224 | setActivate(); |
| 1 | import 'package:flutter/material.dart'; | 1 | import 'package:flutter/material.dart'; |
| 2 | import 'package:flutter_easyrefresh/easy_refresh.dart'; | 2 | import 'package:flutter_easyrefresh/easy_refresh.dart'; |
| 3 | +import 'package:one_key/pages/message/messsage_item.dart'; | ||
| 3 | import 'package:one_key/provider/message_dialog_model.dart'; | 4 | import 'package:one_key/provider/message_dialog_model.dart'; |
| 4 | import 'package:one_key/provider/message_model.dart'; | 5 | import 'package:one_key/provider/message_model.dart'; |
| 5 | import 'package:one_key/provider/user_model.dart'; | 6 | import 'package:one_key/provider/user_model.dart'; |
| 6 | import 'package:provider/provider.dart'; | 7 | import 'package:provider/provider.dart'; |
| 7 | import 'package:one_key/utils/event_bus.dart'; | 8 | import 'package:one_key/utils/event_bus.dart'; |
| 8 | -import 'message_dialog_item.dart'; | ||
| 9 | 9 | ||
| 10 | class MessageLeftPage extends StatefulWidget { | 10 | class MessageLeftPage extends StatefulWidget { |
| 11 | @override | 11 | @override |
| @@ -61,7 +61,7 @@ class MessageLeftPageState extends State<MessageLeftPage> { | @@ -61,7 +61,7 @@ class MessageLeftPageState extends State<MessageLeftPage> { | ||
| 61 | SliverList( | 61 | SliverList( |
| 62 | delegate: | 62 | delegate: |
| 63 | SliverChildBuilderDelegate((BuildContext context, int index) { | 63 | SliverChildBuilderDelegate((BuildContext context, int index) { |
| 64 | - return MessageDialogItem(messages[index]); | 64 | + return MessageItem(messages[index]); |
| 65 | },childCount: messages.length), | 65 | },childCount: messages.length), |
| 66 | ) | 66 | ) |
| 67 | ],onRefresh: () async { | 67 | ],onRefresh: () async { |
| 1 | import 'package:flutter/material.dart'; | 1 | import 'package:flutter/material.dart'; |
| 2 | import 'package:flutter_easyrefresh/easy_refresh.dart'; | 2 | import 'package:flutter_easyrefresh/easy_refresh.dart'; |
| 3 | +import 'package:one_key/pages/message/messsage_item.dart'; | ||
| 3 | import 'package:one_key/provider/message_model.dart'; | 4 | import 'package:one_key/provider/message_model.dart'; |
| 4 | import 'package:one_key/provider/user_model.dart'; | 5 | import 'package:one_key/provider/user_model.dart'; |
| 5 | -import 'package:one_key/utils/log_util.dart'; | ||
| 6 | import 'package:provider/provider.dart'; | 6 | import 'package:provider/provider.dart'; |
| 7 | 7 | ||
| 8 | -import 'message_dialog_item.dart'; | ||
| 9 | - | ||
| 10 | class MessageRightPage extends StatefulWidget{ | 8 | class MessageRightPage extends StatefulWidget{ |
| 11 | @override | 9 | @override |
| 12 | State<StatefulWidget> createState() { | 10 | State<StatefulWidget> createState() { |
| @@ -59,7 +57,7 @@ class MessageRightPageState extends State<MessageRightPage>{ | @@ -59,7 +57,7 @@ class MessageRightPageState extends State<MessageRightPage>{ | ||
| 59 | SliverList( | 57 | SliverList( |
| 60 | delegate: | 58 | delegate: |
| 61 | SliverChildBuilderDelegate((BuildContext context, int index) { | 59 | SliverChildBuilderDelegate((BuildContext context, int index) { |
| 62 | - return MessageDialogItem(messages[index],isTreated: true,); | 60 | + return MessageItem(messages[index],isTreated: true,); |
| 63 | },childCount: messages.length), | 61 | },childCount: messages.length), |
| 64 | ) | 62 | ) |
| 65 | ],onRefresh: () async { | 63 | ],onRefresh: () async { |
lib/pages/message/messsage_item.dart
0 → 100644
| 1 | +import 'package:flutter/material.dart'; | ||
| 2 | +import 'package:flutter_screenutil/flutter_screenutil.dart'; | ||
| 3 | +import 'package:one_key/models/message.dart'; | ||
| 4 | +import 'package:one_key/provider/message_dialog_model.dart'; | ||
| 5 | +import 'package:one_key/res/colors.dart'; | ||
| 6 | +import 'package:one_key/utils/navigator_util.dart'; | ||
| 7 | +import 'package:one_key/widgets/common_button.dart'; | ||
| 8 | +import 'package:one_key/widgets/h_empty_view.dart'; | ||
| 9 | +import 'package:one_key/widgets/v_empty_view.dart'; | ||
| 10 | +import 'package:provider/provider.dart'; | ||
| 11 | + | ||
| 12 | +class MessageItem extends StatelessWidget { | ||
| 13 | + | ||
| 14 | + final Message message; | ||
| 15 | + final bool isTreated; | ||
| 16 | + final VoidCallback callback; | ||
| 17 | + MessageItem(this.message,{this.isTreated=false,this.callback}); | ||
| 18 | + | ||
| 19 | + @override | ||
| 20 | + Widget build(BuildContext context) { | ||
| 21 | + // TODO: implement build | ||
| 22 | + Color textColor=isTreated?MyColours.color_999999:MyColours.color_353535; | ||
| 23 | + MessageDialogModel messageDialogModel=Provider.of<MessageDialogModel>(context,listen: false); | ||
| 24 | + return GestureDetector( | ||
| 25 | + onTap: (){ | ||
| 26 | + if(isTreated){ | ||
| 27 | + NavigatorUtil.goNotebookDetailPage(context,message.rid.toString()); | ||
| 28 | + } | ||
| 29 | + }, | ||
| 30 | + child: Stack( | ||
| 31 | + children: <Widget>[ | ||
| 32 | + Container( | ||
| 33 | + margin: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(39),vertical: ScreenUtil().setWidth(12)), | ||
| 34 | + padding: EdgeInsets.fromLTRB( | ||
| 35 | + ScreenUtil().setWidth(12), | ||
| 36 | + ScreenUtil().setWidth(45), | ||
| 37 | + ScreenUtil().setWidth(21), | ||
| 38 | + ScreenUtil().setWidth(43)), | ||
| 39 | + decoration: BoxDecoration( | ||
| 40 | + color: MyColours.color_fefefe, | ||
| 41 | + borderRadius: | ||
| 42 | + BorderRadius.all(Radius.circular(ScreenUtil().setWidth(8)))), | ||
| 43 | + child:Column( | ||
| 44 | + mainAxisSize: MainAxisSize.min, | ||
| 45 | + crossAxisAlignment: CrossAxisAlignment.start, | ||
| 46 | + children: <Widget>[ | ||
| 47 | + Row( | ||
| 48 | + crossAxisAlignment: CrossAxisAlignment.center, | ||
| 49 | + children: <Widget>[ | ||
| 50 | + Text( | ||
| 51 | + "在线预订", | ||
| 52 | + style: TextStyle( | ||
| 53 | + color: textColor, | ||
| 54 | + fontSize: ScreenUtil().setSp(28)), | ||
| 55 | + ), | ||
| 56 | + Spacer(), | ||
| 57 | + Text( | ||
| 58 | + message.cdateStr, | ||
| 59 | + style: TextStyle( | ||
| 60 | + color: MyColours.color_999999, | ||
| 61 | + fontSize: ScreenUtil().setSp(24)), | ||
| 62 | + ), | ||
| 63 | + ], | ||
| 64 | + ), | ||
| 65 | + VEmptyView(20), | ||
| 66 | + Text( | ||
| 67 | + "包间需求:${message.room_demand}", | ||
| 68 | + style: TextStyle( | ||
| 69 | + color: textColor, | ||
| 70 | + fontSize: ScreenUtil().setSp(28)), | ||
| 71 | + ), | ||
| 72 | + VEmptyView(10), | ||
| 73 | + Text( | ||
| 74 | + "就餐时间:${message.ddateStr}", | ||
| 75 | + style: TextStyle( | ||
| 76 | + color: textColor, | ||
| 77 | + fontSize: ScreenUtil().setSp(28)), | ||
| 78 | + ), | ||
| 79 | + VEmptyView(10), | ||
| 80 | + Text( | ||
| 81 | + "预订人:${message.rnameStr}", | ||
| 82 | + style: TextStyle( | ||
| 83 | + color: textColor, | ||
| 84 | + fontSize: ScreenUtil().setSp(28)), | ||
| 85 | + ), | ||
| 86 | + ], | ||
| 87 | + ), | ||
| 88 | + ), | ||
| 89 | + Positioned( | ||
| 90 | + right: ScreenUtil().setWidth(60), | ||
| 91 | + bottom: ScreenUtil().setWidth(55), | ||
| 92 | + child:Offstage( | ||
| 93 | + offstage: isTreated?true:false, | ||
| 94 | + child: CommonButton( | ||
| 95 | + width: 160, | ||
| 96 | + height: 48, | ||
| 97 | + fontSize: 28, | ||
| 98 | + content: "立即处理", | ||
| 99 | + state: 1, | ||
| 100 | + onPress: () { | ||
| 101 | + messageDialogModel.removeMessage(message.id); | ||
| 102 | + NavigatorUtil.goHandleOnlinePage(context,message.rid.toString(),message.id); | ||
| 103 | + }, | ||
| 104 | + ), | ||
| 105 | + ), | ||
| 106 | + ) | ||
| 107 | + ], | ||
| 108 | + ) | ||
| 109 | + ); | ||
| 110 | + } | ||
| 111 | +} |
| @@ -76,7 +76,7 @@ class SmsPageState extends State<SmsPage>{ | @@ -76,7 +76,7 @@ class SmsPageState extends State<SmsPage>{ | ||
| 76 | Container( | 76 | Container( |
| 77 | alignment: Alignment.centerLeft, | 77 | alignment: Alignment.centerLeft, |
| 78 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(30),left: ScreenUtil().setWidth(38)), | 78 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(30),left: ScreenUtil().setWidth(38)), |
| 79 | - child: Text("已自动生成短信通知,可直接发送",style: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(22)),), | 79 | + child: Text("已自动生成短信通知,可直接发送",style: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(28)),), |
| 80 | ), | 80 | ), |
| 81 | Container( | 81 | Container( |
| 82 | width: ScreenUtil().setWidth(673), | 82 | width: ScreenUtil().setWidth(673), |
| @@ -86,7 +86,7 @@ class SmsPageState extends State<SmsPage>{ | @@ -86,7 +86,7 @@ class SmsPageState extends State<SmsPage>{ | ||
| 86 | border: Border.all(color: MyColours.color_dbe3e3,width: ScreenUtil().setWidth(2)), | 86 | border: Border.all(color: MyColours.color_dbe3e3,width: ScreenUtil().setWidth(2)), |
| 87 | borderRadius: BorderRadius.all(Radius.circular(ScreenUtil().setWidth(8))), | 87 | borderRadius: BorderRadius.all(Radius.circular(ScreenUtil().setWidth(8))), |
| 88 | ), | 88 | ), |
| 89 | - child: Text(smsContent,style: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(26),)) | 89 | + child: Text(smsContent,style: TextStyle(color: MyColours.color_353535,fontSize: ScreenUtil().setSp(30),)) |
| 90 | ), | 90 | ), |
| 91 | Container( | 91 | Container( |
| 92 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(143)), | 92 | margin: EdgeInsets.only(top: ScreenUtil().setHeight(143)), |
| @@ -95,7 +95,7 @@ class SmsPageState extends State<SmsPage>{ | @@ -95,7 +95,7 @@ class SmsPageState extends State<SmsPage>{ | ||
| 95 | CommonButton( | 95 | CommonButton( |
| 96 | width: 672, | 96 | width: 672, |
| 97 | height: 76, | 97 | height: 76, |
| 98 | - fontSize: 26, | 98 | + fontSize: 34, |
| 99 | content: "直接发送", | 99 | content: "直接发送", |
| 100 | state: 1, | 100 | state: 1, |
| 101 | onPress: (){ | 101 | onPress: (){ |
| @@ -106,7 +106,7 @@ class SmsPageState extends State<SmsPage>{ | @@ -106,7 +106,7 @@ class SmsPageState extends State<SmsPage>{ | ||
| 106 | CommonButton( | 106 | CommonButton( |
| 107 | width: 672, | 107 | width: 672, |
| 108 | height: 76, | 108 | height: 76, |
| 109 | - fontSize: 26, | 109 | + fontSize: 34, |
| 110 | content: "复制短信", | 110 | content: "复制短信", |
| 111 | state: 0, | 111 | state: 0, |
| 112 | onPress: () async { | 112 | onPress: () async { |
| @@ -200,7 +200,7 @@ class SelectTablePageState extends State<SelectTablePage>{ | @@ -200,7 +200,7 @@ class SelectTablePageState extends State<SelectTablePage>{ | ||
| 200 | content: "确定", | 200 | content: "确定", |
| 201 | width: 600, | 201 | width: 600, |
| 202 | height: 76, | 202 | height: 76, |
| 203 | - fontSize: 26, | 203 | + fontSize: 34, |
| 204 | state: 1, | 204 | state: 1, |
| 205 | onPress: (){ | 205 | onPress: (){ |
| 206 | if(selectTables.length>0){ | 206 | if(selectTables.length>0){ |
| @@ -28,6 +28,7 @@ class DialogUtil { | @@ -28,6 +28,7 @@ class DialogUtil { | ||
| 28 | messageModel.showMessageDialog=true; | 28 | messageModel.showMessageDialog=true; |
| 29 | await showModalBottomSheet<int>( | 29 | await showModalBottomSheet<int>( |
| 30 | context: context, | 30 | context: context, |
| 31 | + isScrollControlled: true, | ||
| 31 | builder: (BuildContext dialogContext) { | 32 | builder: (BuildContext dialogContext) { |
| 32 | Widget widget = Container( | 33 | Widget widget = Container( |
| 33 | color: MyColours.app_main, | 34 | color: MyColours.app_main, |
| @@ -70,7 +71,7 @@ class DialogUtil { | @@ -70,7 +71,7 @@ class DialogUtil { | ||
| 70 | )) | 71 | )) |
| 71 | ], | 72 | ], |
| 72 | )), | 73 | )), |
| 73 | - model.messages.length>2?Container( | 74 | + model.messages.length>3?Container( |
| 74 | margin: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(22),vertical: ScreenUtil().setWidth(11)), | 75 | margin: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(22),vertical: ScreenUtil().setWidth(11)), |
| 75 | padding: EdgeInsets.fromLTRB( | 76 | padding: EdgeInsets.fromLTRB( |
| 76 | ScreenUtil().setWidth(16), | 77 | ScreenUtil().setWidth(16), |
| @@ -26,6 +26,7 @@ class MyAppBar extends StatelessWidget { | @@ -26,6 +26,7 @@ class MyAppBar extends StatelessWidget { | ||
| 26 | onTap: () { | 26 | onTap: () { |
| 27 | Navigator.of(context).pop(); | 27 | Navigator.of(context).pop(); |
| 28 | }, | 28 | }, |
| 29 | + behavior: HitTestBehavior.opaque, | ||
| 29 | child: Padding( | 30 | child: Padding( |
| 30 | padding: EdgeInsets.symmetric( | 31 | padding: EdgeInsets.symmetric( |
| 31 | horizontal: ScreenUtil().setWidth(40), | 32 | horizontal: ScreenUtil().setWidth(40), |
| @@ -41,7 +41,7 @@ class AreaItemState extends State<AreaItem>{ | @@ -41,7 +41,7 @@ class AreaItemState extends State<AreaItem>{ | ||
| 41 | color: isSelected?MyColours.color_ffffff:MyColours.color_f1f1f1, | 41 | color: isSelected?MyColours.color_ffffff:MyColours.color_f1f1f1, |
| 42 | border: Border(bottom: BorderSide(color: MyColours.color_ffffff,width: ScreenUtil().setHeight(1))) | 42 | border: Border(bottom: BorderSide(color: MyColours.color_ffffff,width: ScreenUtil().setHeight(1))) |
| 43 | ), | 43 | ), |
| 44 | - child: Text(area.name,style: TextStyle(color: isSelected?MyColours.color_2bb5b7:MyColours.color_828282,fontSize: ScreenUtil().setSp(26),decoration: TextDecoration.none),), | 44 | + child: Text(area.name,style: TextStyle(color: isSelected?MyColours.color_2bb5b7:MyColours.color_828282,fontSize: ScreenUtil().setSp(32),decoration: TextDecoration.none,fontWeight: FontWeight.normal),), |
| 45 | ), | 45 | ), |
| 46 | Positioned( | 46 | Positioned( |
| 47 | left: 0, | 47 | left: 0, |
| @@ -54,7 +54,7 @@ class AreaItemState extends State<AreaItem>{ | @@ -54,7 +54,7 @@ class AreaItemState extends State<AreaItem>{ | ||
| 54 | color: area.count<=0?MyColours.color_999999:MyColours.color_63a6d1, | 54 | color: area.count<=0?MyColours.color_999999:MyColours.color_63a6d1, |
| 55 | borderRadius: BorderRadius.only(topRight: Radius.circular(ScreenUtil().setWidth(8)),bottomRight: Radius.circular(ScreenUtil().setWidth(8))) | 55 | borderRadius: BorderRadius.only(topRight: Radius.circular(ScreenUtil().setWidth(8)),bottomRight: Radius.circular(ScreenUtil().setWidth(8))) |
| 56 | ), | 56 | ), |
| 57 | - child: Text(area.count<=0?"满座":"余${area.count}",style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(22),decoration: TextDecoration.none)), | 57 | + child: Text(area.count<=0?"满座":"余${area.count}",style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(26),decoration: TextDecoration.none,fontWeight: FontWeight.normal)), |
| 58 | ), | 58 | ), |
| 59 | ), | 59 | ), |
| 60 | ], | 60 | ], |
| @@ -34,7 +34,7 @@ class CommonButton extends StatelessWidget { | @@ -34,7 +34,7 @@ class CommonButton extends StatelessWidget { | ||
| 34 | break; | 34 | break; |
| 35 | case 0: | 35 | case 0: |
| 36 | boxDecoration = BoxDecoration( | 36 | boxDecoration = BoxDecoration( |
| 37 | - border: Border.all(color: MyColours.color_199095), | 37 | + border: Border.all(color: MyColours.color_199095,width: ScreenUtil().setWidth(2)), |
| 38 | borderRadius: BorderRadius.circular(ScreenUtil().setWidth(5)), | 38 | borderRadius: BorderRadius.circular(ScreenUtil().setWidth(5)), |
| 39 | ); | 39 | ); |
| 40 | fontColor=MyColours.color_199095; | 40 | fontColor=MyColours.color_199095; |
lib/widgets/need_item.dart
0 → 100644
| 1 | +import 'package:flutter/material.dart'; | ||
| 2 | +import 'package:flutter_screenutil/flutter_screenutil.dart'; | ||
| 3 | +import 'package:one_key/res/colors.dart'; | ||
| 4 | + | ||
| 5 | +import 'package:one_key/models/table.dart' as t; | ||
| 6 | +import 'package:one_key/widgets/v_empty_view.dart'; | ||
| 7 | + | ||
| 8 | +class NeedItem extends StatefulWidget{ | ||
| 9 | + | ||
| 10 | + final t.Table table; | ||
| 11 | + final bool canSelected;//是否能选中 | ||
| 12 | + final ValueChanged onSelected; | ||
| 13 | + | ||
| 14 | + final int height;//高度 | ||
| 15 | + | ||
| 16 | + NeedItem(this.table,{this.onSelected,this.canSelected=false,this.height=183}); | ||
| 17 | + | ||
| 18 | + @override | ||
| 19 | + State<StatefulWidget> createState() { | ||
| 20 | + // TODO: implement createState | ||
| 21 | + return new NeedItemState(); | ||
| 22 | + } | ||
| 23 | +} | ||
| 24 | + | ||
| 25 | +class NeedItemState extends State<NeedItem>{ | ||
| 26 | + | ||
| 27 | + @override | ||
| 28 | + Widget build(BuildContext context) { | ||
| 29 | + // TODO: implement build | ||
| 30 | + | ||
| 31 | + t.Table table=widget.table; | ||
| 32 | + | ||
| 33 | + return GestureDetector( | ||
| 34 | + onTap: (){ | ||
| 35 | + if(widget.canSelected&&table.signStr.isEmpty){ | ||
| 36 | + setState(() { | ||
| 37 | + table.selected=!(table.selected??false); | ||
| 38 | + }); | ||
| 39 | + widget.onSelected(table); | ||
| 40 | + } | ||
| 41 | + }, | ||
| 42 | + child: Stack( | ||
| 43 | + children: <Widget>[ | ||
| 44 | + Container( | ||
| 45 | + width: ScreenUtil().setWidth(190), | ||
| 46 | + height: ScreenUtil().setWidth(widget.height), | ||
| 47 | + alignment: Alignment.center, | ||
| 48 | + margin:EdgeInsets.all( ScreenUtil().setWidth(9)), | ||
| 49 | + decoration: BoxDecoration( | ||
| 50 | + color: MyColours.color_a8e2e4, | ||
| 51 | + borderRadius: BorderRadius.all(Radius.circular(ScreenUtil().setWidth(8))) | ||
| 52 | + ), | ||
| 53 | + child:Column( | ||
| 54 | + mainAxisSize: MainAxisSize.min, | ||
| 55 | + crossAxisAlignment: CrossAxisAlignment.center, | ||
| 56 | + children: <Widget>[ | ||
| 57 | + Text(table.name,style: TextStyle(color: MyColours.color_131313,fontSize: ScreenUtil().setSp(30),decoration: TextDecoration.none,fontWeight: FontWeight.normal),overflow: TextOverflow.ellipsis,), | ||
| 58 | + Offstage( | ||
| 59 | + offstage: table.tableNum.isEmpty?true:false, | ||
| 60 | + child: Column( | ||
| 61 | + mainAxisSize: MainAxisSize.min, | ||
| 62 | + children: <Widget>[ | ||
| 63 | + VEmptyView(5), | ||
| 64 | + Text(table.tableNum,style: TextStyle(color: MyColours.color_777777,fontSize: ScreenUtil().setSp(26),decoration: TextDecoration.none,fontWeight: FontWeight.normal),overflow: TextOverflow.ellipsis,), | ||
| 65 | + ], | ||
| 66 | + ), | ||
| 67 | + ), | ||
| 68 | + Offstage( | ||
| 69 | + offstage: table.lowStr.isEmpty?true:false, | ||
| 70 | + child: Column( | ||
| 71 | + mainAxisSize: MainAxisSize.min, | ||
| 72 | + children: <Widget>[ | ||
| 73 | + VEmptyView(5), | ||
| 74 | + Text(table.lowStr,style: TextStyle(color: MyColours.color_2bb5b7,fontSize: ScreenUtil().setSp(24),decoration: TextDecoration.none,fontWeight: FontWeight.normal),overflow: TextOverflow.ellipsis,) | ||
| 75 | + ], | ||
| 76 | + ), | ||
| 77 | + ) | ||
| 78 | + ], | ||
| 79 | + ) | ||
| 80 | + ), | ||
| 81 | + ], | ||
| 82 | + ), | ||
| 83 | + ); | ||
| 84 | + } | ||
| 85 | +} |
| @@ -39,68 +39,73 @@ class TableItemState extends State<TableItem>{ | @@ -39,68 +39,73 @@ class TableItemState extends State<TableItem>{ | ||
| 39 | widget.onSelected(table); | 39 | widget.onSelected(table); |
| 40 | } | 40 | } |
| 41 | }, | 41 | }, |
| 42 | - child: Container( | ||
| 43 | - width: ScreenUtil().setWidth(150), | ||
| 44 | - height: ScreenUtil().setWidth(widget.height), | ||
| 45 | - margin:EdgeInsets.all( ScreenUtil().setWidth(9)), | ||
| 46 | - decoration: BoxDecoration( | ||
| 47 | - color: MyColours.color_a8e2e4, | ||
| 48 | - borderRadius: BorderRadius.all(Radius.circular(ScreenUtil().setWidth(8))) | ||
| 49 | - ), | ||
| 50 | - child: Stack( | ||
| 51 | - alignment: Alignment.center, | ||
| 52 | - children: <Widget>[ | ||
| 53 | - Positioned( | ||
| 54 | - left: 0, | ||
| 55 | - top: 0, | ||
| 56 | - child: table.tidStr==null?Container():Container( | ||
| 57 | - width: ScreenUtil().setWidth(60), | ||
| 58 | - height: ScreenUtil().setHeight(27), | ||
| 59 | - alignment: Alignment.center, | ||
| 60 | - decoration: BoxDecoration( | ||
| 61 | - color: MyColours.color_63a6d1, | ||
| 62 | - borderRadius: BorderRadius.only(topLeft: Radius.circular(ScreenUtil().setWidth(8)),topRight: Radius.circular(ScreenUtil().setWidth(8)),bottomRight: Radius.circular(ScreenUtil().setWidth(8))) | ||
| 63 | - ), | ||
| 64 | - child: Text(table.tidStr,style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(19),decoration: TextDecoration.none)), | ||
| 65 | - ), | ||
| 66 | - ), | ||
| 67 | - Container( | ||
| 68 | - alignment: Alignment.centerLeft, | ||
| 69 | - margin: EdgeInsets.only(left: ScreenUtil().setWidth(20)), | ||
| 70 | - child: Column( | ||
| 71 | - mainAxisSize: MainAxisSize.min, | ||
| 72 | - crossAxisAlignment: CrossAxisAlignment.start, | ||
| 73 | - children: <Widget>[ | ||
| 74 | - Text(table.name,style: TextStyle(color: MyColours.color_131313,fontSize: ScreenUtil().setSp(26),decoration: TextDecoration.none),), | ||
| 75 | - VEmptyView(5), | ||
| 76 | - Text((table.reserver==null||table.reserver.isEmpty)?table.tableNum:table.reserver,style: TextStyle(color: (table.reserver==null||table.reserver.isEmpty)?MyColours.color_777777:MyColours.color_2bb5b7,fontSize: ScreenUtil().setSp(22),decoration: TextDecoration.none),overflow: TextOverflow.ellipsis,), | ||
| 77 | - VEmptyView(5), | ||
| 78 | - Text(table.lowStr,style: TextStyle(color: MyColours.color_777777,fontSize: ScreenUtil().setSp(22),decoration: TextDecoration.none),overflow: TextOverflow.ellipsis,) | ||
| 79 | - ], | ||
| 80 | - ), | 42 | + child: Stack( |
| 43 | + children: <Widget>[ | ||
| 44 | + Container( | ||
| 45 | + width: ScreenUtil().setWidth(150), | ||
| 46 | + height: ScreenUtil().setWidth(widget.height), | ||
| 47 | + margin:EdgeInsets.all( ScreenUtil().setWidth(9)), | ||
| 48 | + decoration: BoxDecoration( | ||
| 49 | + color: MyColours.color_a8e2e4, | ||
| 50 | + borderRadius: BorderRadius.all(Radius.circular(ScreenUtil().setWidth(8))) | ||
| 81 | ), | 51 | ), |
| 82 | - Positioned( | ||
| 83 | - bottom: 0, | ||
| 84 | - left: 0, | ||
| 85 | - right: 0, | ||
| 86 | - child: table.signStr.isEmpty?Container():Container( | ||
| 87 | - width: ScreenUtil().setWidth(150), | ||
| 88 | - height: ScreenUtil().setHeight(46), | ||
| 89 | - alignment: Alignment.center, | ||
| 90 | - decoration: BoxDecoration( | ||
| 91 | - color:MyColours.color_89c0b7, | ||
| 92 | - borderRadius: BorderRadius.only(bottomLeft: Radius.circular(ScreenUtil().setWidth(8)),bottomRight: Radius.circular(ScreenUtil().setWidth(8))) | 52 | + child: Stack( |
| 53 | + alignment: Alignment.center, | ||
| 54 | + children: <Widget>[ | ||
| 55 | + Positioned( | ||
| 56 | + left: 0, | ||
| 57 | + top: 0, | ||
| 58 | + child: table.tidStr==null?Container():Container( | ||
| 59 | + width: ScreenUtil().setWidth(70), | ||
| 60 | + height: ScreenUtil().setHeight(32), | ||
| 61 | + alignment: Alignment.center, | ||
| 62 | + decoration: BoxDecoration( | ||
| 63 | + color: MyColours.color_63a6d1, | ||
| 64 | + borderRadius: BorderRadius.only(topLeft: Radius.circular(ScreenUtil().setWidth(8)),topRight: Radius.circular(ScreenUtil().setWidth(8)),bottomRight: Radius.circular(ScreenUtil().setWidth(8))) | ||
| 65 | + ), | ||
| 66 | + child: Text(table.tidStr,style: TextStyle(color: MyColours.color_ffffff,fontSize: ScreenUtil().setSp(24),decoration: TextDecoration.none,fontWeight: FontWeight.normal)), | ||
| 67 | + ), | ||
| 68 | + ), | ||
| 69 | + Container( | ||
| 70 | + alignment: Alignment.centerLeft, | ||
| 71 | + margin: EdgeInsets.only(left: ScreenUtil().setWidth(20)), | ||
| 72 | + child: Column( | ||
| 73 | + mainAxisSize: MainAxisSize.min, | ||
| 74 | + crossAxisAlignment: CrossAxisAlignment.start, | ||
| 75 | + children: <Widget>[ | ||
| 76 | + VEmptyView(20), | ||
| 77 | + Text(table.name,style: TextStyle(color: MyColours.color_131313,fontSize: ScreenUtil().setSp(30),decoration: TextDecoration.none,fontWeight: FontWeight.normal),overflow: TextOverflow.ellipsis,), | ||
| 78 | + VEmptyView(5), | ||
| 79 | + Text((table.reserver==null||table.reserver.isEmpty)?table.tableNum:table.reserver,style: TextStyle(color: (table.reserver==null||table.reserver.isEmpty)?MyColours.color_777777:MyColours.color_2bb5b7,fontSize: ScreenUtil().setSp(26),decoration: TextDecoration.none,fontWeight: FontWeight.normal),overflow: TextOverflow.ellipsis,), | ||
| 80 | + VEmptyView(5), | ||
| 81 | + Text(table.lowStr,style: TextStyle(color: MyColours.color_777777,fontSize: ScreenUtil().setSp(26),decoration: TextDecoration.none,fontWeight: FontWeight.normal),overflow: TextOverflow.ellipsis,) | ||
| 82 | + ], | ||
| 83 | + ), | ||
| 84 | + ), | ||
| 85 | + Positioned( | ||
| 86 | + bottom: 0, | ||
| 87 | + left: 0, | ||
| 88 | + right: 0, | ||
| 89 | + child: table.signStr.isEmpty?Container():Container( | ||
| 90 | + width: ScreenUtil().setWidth(150), | ||
| 91 | + height: ScreenUtil().setHeight(40), | ||
| 92 | + alignment: Alignment.center, | ||
| 93 | + decoration: BoxDecoration( | ||
| 94 | + color:MyColours.color_89c0b7, | ||
| 95 | + borderRadius: BorderRadius.only(bottomLeft: Radius.circular(ScreenUtil().setWidth(8)),bottomRight: Radius.circular(ScreenUtil().setWidth(8))) | ||
| 96 | + ), | ||
| 97 | + child: Text(table.signStr,style: TextStyle(color:MyColours.color_ffffff,fontSize: ScreenUtil().setSp(24),decoration: TextDecoration.none,fontWeight: FontWeight.normal),), | ||
| 98 | + ), | ||
| 93 | ), | 99 | ), |
| 94 | - child: Text(table.signStr,style: TextStyle(color:MyColours.color_ffffff,fontSize: ScreenUtil().setSp(24),decoration: TextDecoration.none),), | ||
| 95 | - ), | 100 | + ], |
| 96 | ), | 101 | ), |
| 97 | - Positioned( | ||
| 98 | - top: 0, | ||
| 99 | - right: 0, | ||
| 100 | - child: !(table.selected??false)?Container():Image.asset("assets/icon_selected.png",width: ScreenUtil().setWidth(27),height: ScreenUtil().setWidth(27),) | ||
| 101 | - ) | ||
| 102 | - ], | ||
| 103 | - ), | 102 | + ), |
| 103 | + Positioned( | ||
| 104 | + top: 3, | ||
| 105 | + right: 5, | ||
| 106 | + child: !(table.selected??false)?Container():Image.asset("assets/icon_selected.png",width: ScreenUtil().setWidth(40),height: ScreenUtil().setWidth(40),) | ||
| 107 | + ) | ||
| 108 | + ], | ||
| 104 | ), | 109 | ), |
| 105 | ); | 110 | ); |
| 106 | } | 111 | } |
-
Please register or login to post a comment