Commit c375575dc81a89b8bc8fa4e6a403646c2946efcb

Authored by wdn127929
1 parent caaa04b6

桌位管理页面越界处理

... ... @@ -18,19 +18,19 @@ if (flutterRoot == null) {
def flutterVersionCode = "516"
def flutterVersionCode = "517"
if (flutterVersionCode == null) {
flutterVersionCode = '516'
flutterVersionCode = '517'
}
def flutterVersionName = "5.1.6"
def flutterVersionName = "5.1.7"
if (flutterVersionName == null) {
flutterVersionName = '5.1.6'
flutterVersionName = '5.1.7'
}
... ...
... ... @@ -379,38 +379,38 @@ class _MyMakeMarkingPageState extends State<MyMakeMarkingPage> {
},
),
VEmptyView(20),
Container(
padding: EdgeInsets.only(left: w(10), right: w(10), bottom: w(10)),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(r(5)),
border: Border.all(width: w(1), color: MyColours.color_F8F7F3)),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
height: w(34),
alignment: Alignment.centerLeft,
child: Text(
'常用模版',
style: TextStyle(
color: MyColours.color_515151,
fontSize: font(12),
),
),
),
VEmptyView(10),
Padding(
padding: EdgeInsets.only(left: w(10)),
child: Wrap(
spacing: w(10),
runSpacing: w(5),
children: _templateUI(),
),
)
],
),
),
VEmptyView(50),
// Container(
// padding: EdgeInsets.only(left: w(10), right: w(10), bottom: w(10)),
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(r(5)),
// border: Border.all(width: w(1), color: MyColours.color_F8F7F3)),
// child: Column(
// crossAxisAlignment: CrossAxisAlignment.start,
// children: [
// Container(
// height: w(34),
// alignment: Alignment.centerLeft,
// child: Text(
// '常用模版',
// style: TextStyle(
// color: MyColours.color_515151,
// fontSize: font(12),
// ),
// ),
// ),
// VEmptyView(10),
// Padding(
// padding: EdgeInsets.only(left: w(10)),
// child: Wrap(
// spacing: w(10),
// runSpacing: w(5),
// children: _templateUI(),
// ),
// )
// ],
// ),
// ),
// VEmptyView(50),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
... ... @@ -448,7 +448,7 @@ class _MyMakeMarkingPageState extends State<MyMakeMarkingPage> {
width: ScreenUtil().setWidth(44)),
HEmptyView(15),
Text(
'在当前位置插入优惠',
'营销加入优惠', //'在当前位置插入优惠',
style: TextStyle(
fontSize: ScreenUtil().setSp(32),
fontWeight: FontWeight.bold,
... ... @@ -482,25 +482,27 @@ class _MyMakeMarkingPageState extends State<MyMakeMarkingPage> {
customerMakingProvider.couponSelectIndex];
});
var cursorPos = customerMakingProvider
.controller.selection.base.offset; //获取到光标的在字符串的位置
String textAfterCursor = customerMakingProvider
.controller.text
.substring(cursorPos); //把字符串从光标的位置截取,光标后面的
String textBeforeCursor = customerMakingProvider
.controller.text
.substring(0, cursorPos); //光标前面的字符串
customerMakingProvider.controller.text =
textBeforeCursor +
"http://www.baidu.com" +
textAfterCursor; //把想要的插入的内容拼接在光标位置处
customerMakingProvider.controller.selection =
TextSelection.collapsed(
offset: customerMakingProvider
.controller.text.length);
// *************开始直接插入会报错***********还没有改
// var cursorPos = customerMakingProvider
// .controller.selection.base.offset; //获取到光标的在字符串的位置
// String textAfterCursor = customerMakingProvider
// .controller.text
// .substring(cursorPos); //把字符串从光标的位置截取,光标后面的
// String textBeforeCursor = customerMakingProvider
// .controller.text
// .substring(0, cursorPos); //光标前面的字符串
// customerMakingProvider.controller.text =
// textBeforeCursor +
// "http://www.baidu.com" +
// textAfterCursor; //把想要的插入的内容拼接在光标位置处
// customerMakingProvider.controller.selection =
// TextSelection.collapsed(
// offset: customerMakingProvider
// .controller.text.length);
}
},
selecteds: customerMakingProvider
... ...
... ... @@ -360,38 +360,38 @@ class _MakeMarkingPageState extends State<MakeMarkingPage> {
},
),
VEmptyView(20),
Container(
padding: EdgeInsets.only(left: w(10), right: w(10), bottom: w(10)),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(r(5)),
border: Border.all(width: w(1), color: MyColours.color_F8F7F3)),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
height: w(34),
alignment: Alignment.centerLeft,
child: Text(
'常用模版',
style: TextStyle(
color: MyColours.color_515151,
fontSize: font(12),
),
),
),
VEmptyView(10),
Padding(
padding: EdgeInsets.only(left: w(10)),
child: Wrap(
spacing: w(10),
runSpacing: w(5),
children: _templateUI(),
),
)
],
),
),
VEmptyView(50),
// Container(
// padding: EdgeInsets.only(left: w(10), right: w(10), bottom: w(10)),
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(r(5)),
// border: Border.all(width: w(1), color: MyColours.color_F8F7F3)),
// child: Column(
// crossAxisAlignment: CrossAxisAlignment.start,
// children: [
// Container(
// height: w(34),
// alignment: Alignment.centerLeft,
// child: Text(
// '常用模版',
// style: TextStyle(
// color: MyColours.color_515151,
// fontSize: font(12),
// ),
// ),
// ),
// VEmptyView(10),
// Padding(
// padding: EdgeInsets.only(left: w(10)),
// child: Wrap(
// spacing: w(10),
// runSpacing: w(5),
// children: _templateUI(),
// ),
// )
// ],
// ),
// ),
// VEmptyView(50),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
... ... @@ -429,7 +429,7 @@ class _MakeMarkingPageState extends State<MakeMarkingPage> {
width: ScreenUtil().setWidth(44)),
HEmptyView(15),
Text(
'在当前位置插入优惠',
'营销加入优惠', //'在当前位置插入优惠',
style: TextStyle(
fontSize: ScreenUtil().setSp(32),
fontWeight: FontWeight.bold,
... ... @@ -462,25 +462,28 @@ class _MakeMarkingPageState extends State<MakeMarkingPage> {
customerMakingProvider.youhui = couponList[
customerMakingProvider.couponSelectIndex];
});
var cursorPos = customerMakingProvider
.controller.selection.base.offset; //获取到光标的在字符串的位置
String textAfterCursor = customerMakingProvider
.controller.text
.substring(cursorPos); //把字符串从光标的位置截取,光标后面的
String textBeforeCursor = customerMakingProvider
.controller.text
.substring(0, cursorPos); //光标前面的字符串
customerMakingProvider.controller.text =
textBeforeCursor +
"http://www.baidu.com" +
textAfterCursor; //把想要的插入的内容拼接在光标位置处
customerMakingProvider.controller.selection =
TextSelection.collapsed(
offset: customerMakingProvider
.controller.text.length);
// *************开始直接插入会报错***********还没有改
// var cursorPos = customerMakingProvider
// .controller.selection.base.offset; //获取到光标的在字符串的位置
// String textAfterCursor = customerMakingProvider
// .controller.text
// .substring(cursorPos); //把字符串从光标的位置截取,光标后面的
// String textBeforeCursor = customerMakingProvider
// .controller.text
// .substring(0, cursorPos); //光标前面的字符串
// customerMakingProvider.controller.text =
// textBeforeCursor +
// "http://www.baidu.com" +
// textAfterCursor; //把想要的插入的内容拼接在光标位置处
// customerMakingProvider.controller.selection =
// TextSelection.collapsed(
// offset: customerMakingProvider
// .controller.text.length);
}
},
selecteds: customerMakingProvider
... ...
... ... @@ -126,7 +126,7 @@ class MyTableManagerHomePageState extends State<MyTableManagerHomePage> {
'id': table.id,
'name': value['name'],
'tid': tid,
'rid':value['rid']
'rid': value['rid']
};
if (value['pnumMin'] != '') {
... ... @@ -868,7 +868,6 @@ class MyTableManagerHomePageState extends State<MyTableManagerHomePage> {
ScreenUtil().setSp(32),
color:
MyColours.color_BFC4D4)),
],
)),
Align(
... ... @@ -1073,82 +1072,88 @@ class MyTableManagerHomePageState extends State<MyTableManagerHomePage> {
0
? VEmptyView(20)
: VEmptyView(60),
Expanded(
child: Column(
children: [
// Expanded(
// child:
item(tableManagerModel
.selectNumber),
if (tableManagerModel
.tableOuterList[
tableManagerModel
.selectNumber]
.list
.length ==
0)
Expanded(
child: Padding(
padding: EdgeInsets.only(
left: ScreenUtil()
.setWidth(50)),
child: Column(
crossAxisAlignment:
CrossAxisAlignment
.start,
// Expanded(
// child:
if (tableManagerModel
.tableOuterList[
tableManagerModel
.selectNumber]
.list
.length >
0)
Expanded(
child: item(tableManagerModel
.selectNumber)),
if (tableManagerModel
.tableOuterList[
tableManagerModel
.selectNumber]
.list
.length ==
0)
Expanded(
child: Padding(
padding: EdgeInsets.only(
left: ScreenUtil()
.setWidth(50)),
child: Column(
crossAxisAlignment:
CrossAxisAlignment
.start,
children: [
VEmptyView(60),
Row(
children: [
VEmptyView(60),
Row(
children: [
Text(
'1、添加区域(如:一楼、二楼、东厅等)',
style: TextStyle(
decoration:
TextDecoration
.lineThrough,
fontSize:
ScreenUtil().setSp(
32),
color: MyColours
.color_BFC4D4))
],
),
VEmptyView(40),
Text('2、选择要添加桌位的区域',
Text(
'1、添加区域(如:一楼、二楼、东厅等)',
style: TextStyle(
decoration:
TextDecoration
.lineThrough,
fontSize: ScreenUtil()
.setSp(
32),
color: MyColours
.color_BFC4D4)),
VEmptyView(40),
Text('3、点击“+”号添加桌位',
style: TextStyle(
fontSize: ScreenUtil()
.color_BFC4D4))
],
),
VEmptyView(40),
Text('2、选择要添加桌位的区域',
style: TextStyle(
fontSize:
ScreenUtil()
.setSp(
32),
color: MyColours
.color_BFC4D4)),
VEmptyView(40),
Align(
alignment:
Alignment
.center,
child:
Image.asset(
"assets/empty_search.png",
width: ScreenUtil()
color: MyColours
.color_BFC4D4)),
VEmptyView(40),
Text('3、点击“+”号添加桌位',
style: TextStyle(
fontSize:
ScreenUtil()
.setSp(
32),
color: MyColours
.color_BFC4D4)),
VEmptyView(40),
Align(
alignment: Alignment
.center,
child: Image.asset(
"assets/empty_search.png",
width:
ScreenUtil()
.setWidth(
520),
height: ScreenUtil()
height:
ScreenUtil()
.setWidth(
384),
)),
// Spacer(),
],
))),
],
))
)),
// Spacer(),
],
))),
],
))),
])),
... ...