|
...
|
...
|
@@ -7248,6 +7248,73 @@ class DialogUtil { |
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
//显示选择可预定时段
|
|
|
|
static Future<List<int>> showSelectCusmanTimerDialog(
|
|
|
|
BuildContext context, List<dynamic> data, ValueChanged valueChanged,
|
|
|
|
{List<int> selecteds,
|
|
|
|
Color cancelTextColor = const Color.fromRGBO(0, 0, 0, 0.6),
|
|
|
|
String title = '',
|
|
|
|
VoidCallback onCancel,
|
|
|
|
String cancelText = '取消'}) {
|
|
|
|
return Picker(
|
|
|
|
selecteds: selecteds,
|
|
|
|
adapter: PickerDataAdapter<String>(pickerData: data),
|
|
|
|
height: ScreenUtil().setWidth(480),
|
|
|
|
hideHeader: false,
|
|
|
|
headerDecoration: BoxDecoration(
|
|
|
|
color: MyColours.color_ffffff,
|
|
|
|
border: Border(
|
|
|
|
bottom: BorderSide(
|
|
|
|
width: ScreenUtil().setWidth(2),
|
|
|
|
color: MyColours.color_E7E7E7),
|
|
|
|
)),
|
|
|
|
title: Text(
|
|
|
|
title,
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
color: MyColours.color_515151,
|
|
|
|
fontSize: ScreenUtil().setSp(32)),
|
|
|
|
),
|
|
|
|
cancelText: cancelText,
|
|
|
|
cancelTextStyle:
|
|
|
|
TextStyle(color: cancelTextColor, fontSize: ScreenUtil().setSp(32)),
|
|
|
|
confirmText: "确定",
|
|
|
|
itemExtent: ScreenUtil().setWidth(80),
|
|
|
|
confirmTextStyle: TextStyle(
|
|
|
|
color: MyColours.color_438E93, fontSize: ScreenUtil().setSp(32)),
|
|
|
|
selectedTextStyle: TextStyle(
|
|
|
|
color: MyColours.color_000000, fontSize: ScreenUtil().setSp(32)),
|
|
|
|
textStyle: TextStyle(
|
|
|
|
color: Color.fromRGBO(0, 0, 0, 0.26),
|
|
|
|
fontSize: ScreenUtil().setSp(32)),
|
|
|
|
selectionOverlay: Container(
|
|
|
|
height: ScreenUtil().setWidth(80),
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
border: Border(
|
|
|
|
bottom: BorderSide(
|
|
|
|
width: ScreenUtil().setWidth(2),
|
|
|
|
color: MyColours.color_E7E7E7),
|
|
|
|
top: BorderSide(
|
|
|
|
width: ScreenUtil().setWidth(2),
|
|
|
|
color: MyColours.color_E7E7E7))),
|
|
|
|
),
|
|
|
|
onCancel: onCancel,
|
|
|
|
onConfirm: (Picker picker, List value) {
|
|
|
|
Map map = data[value[0]];
|
|
|
|
List list = map.values.last;
|
|
|
|
if (list.length == 1) {
|
|
|
|
value[1] = 0;
|
|
|
|
}
|
|
|
|
print(value.toString());
|
|
|
|
if (valueChanged != null) {
|
|
|
|
valueChanged(value);
|
|
|
|
}
|
|
|
|
}).showModal<List<int>>(context).then((value) {
|
|
|
|
LogUtil.v("value:${value.toString()}");
|
|
|
|
return value;
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
//显示选择客户经理弹框
|
|
|
|
static Future<List<int>> showSelectCusmanDialog(
|
|
|
|
BuildContext context, List<dynamic> data, ValueChanged valueChanged,
|
...
|
...
|
|