|
...
|
...
|
@@ -3,12 +3,19 @@ import 'package:flutter/material.dart'; |
|
|
|
import 'package:flutter_picker_plus/picker.dart';
|
|
|
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
|
|
|
import 'package:one_key/widgets/system_app_bar.dart';
|
|
|
|
import 'package:provider/provider.dart';
|
|
|
|
|
|
|
|
import '../../../constant/state.dart';
|
|
|
|
import '../../../models/discount_order_model.dart';
|
|
|
|
import '../../../provider/finance_provider.dart';
|
|
|
|
import '../../../provider/user_model.dart';
|
|
|
|
import '../../../res/colors.dart';
|
|
|
|
import '../../../route/navigator_util.dart';
|
|
|
|
import '../../../utils/dialog_util.dart';
|
|
|
|
import '../../../utils/screen_util.dart';
|
|
|
|
import '../../../utils/utils.dart';
|
|
|
|
import '../../../widgets/h_empty_view.dart';
|
|
|
|
import '../../../widgets/page_exception.dart';
|
|
|
|
import '../../../widgets/round_button.dart';
|
|
|
|
import '../../../widgets/v_empty_view.dart';
|
|
|
|
|
|
...
|
...
|
@@ -30,6 +37,44 @@ class _TransactionRecordSearchPageState |
|
|
|
String fromDate = '选择日期';
|
|
|
|
String endDate = '选择日期';
|
|
|
|
ScrollController controller = ScrollController();
|
|
|
|
FinanceProvider? financeProvider;
|
|
|
|
|
|
|
|
@override
|
|
|
|
void initState() {
|
|
|
|
super.initState();
|
|
|
|
|
|
|
|
WidgetsBinding.instance.addPostFrameCallback((_) {
|
|
|
|
// _getDiscountOrderList();
|
|
|
|
// _getCountCommentLabel(isShowLoading: false);
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
_getDiscountOrderList({bool isShowLoading = false}) async {
|
|
|
|
List<String> start = fromDate.split('-');
|
|
|
|
|
|
|
|
String from = '${start[0]}' +
|
|
|
|
'-' +
|
|
|
|
Utils.addZeroNumber(int.parse(start[1])) +
|
|
|
|
'-' +
|
|
|
|
Utils.addZeroNumber(int.parse(start[2])) +
|
|
|
|
' 00:00:00';
|
|
|
|
List<String> endList = endDate.split('-');
|
|
|
|
String end = '${endList[0]}' +
|
|
|
|
'-' +
|
|
|
|
Utils.addZeroNumber(int.parse(endList[1])) +
|
|
|
|
'-' +
|
|
|
|
Utils.addZeroNumber(int.parse(endList[2])) +
|
|
|
|
' 23:59:59';
|
|
|
|
|
|
|
|
Map<String, String?> params = {
|
|
|
|
'sellerid': Provider.of<UserModel>(context, listen: false).user!.sellerid,
|
|
|
|
'stime': '${(DateUtil.getDateMsByTimeStr(from)! / 1000).floor()}',
|
|
|
|
'etime': '${(DateUtil.getDateMsByTimeStr(end)! / 1000).floor()}',
|
|
|
|
};
|
|
|
|
|
|
|
|
await financeProvider!.getDiscountOrderList(context, params,
|
|
|
|
from: 'search', isShowLoading: isShowLoading);
|
|
|
|
}
|
|
|
|
|
|
|
|
///时间选择
|
|
|
|
Widget _select(String title, String hintText, GestureTapCallback onTap) {
|
|
...
|
...
|
@@ -74,166 +119,328 @@ class _TransactionRecordSearchPageState |
|
|
|
|
|
|
|
@override
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
financeProvider = Provider.of<FinanceProvider>(context, listen: true);
|
|
|
|
return Scaffold(
|
|
|
|
appBar: SystemAppBar('自定义查询'),
|
|
|
|
key: scaffoldKey,
|
|
|
|
body: Column(
|
|
|
|
children: [
|
|
|
|
Expanded(
|
|
|
|
child: SingleChildScrollView(
|
|
|
|
controller: controller,
|
|
|
|
child: Column(children: [
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
height: w(33),
|
|
|
|
alignment: Alignment.centerLeft,
|
|
|
|
color: MyColours.color_4DDBDBDB,
|
|
|
|
padding: EdgeInsets.only(left: w(16)),
|
|
|
|
child: Text(
|
|
|
|
'查询时间跨度不超过31天',
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_999999, fontSize: font(12)),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
_select('开始日期', fromDate, () {
|
|
|
|
FocusScope.of(context).requestFocus(FocusNode()); //点击空白处隐藏键盘
|
|
|
|
//弹出时间选择器
|
|
|
|
// showPickerDateTime(context);
|
|
|
|
// showDateSelWidget = true;
|
|
|
|
DialogUtil.showPickerDateTime24(
|
|
|
|
context,
|
|
|
|
scaffoldKey,
|
|
|
|
(value) {
|
|
|
|
// {'text': picker.adapter.text, 'select': selecteds}
|
|
|
|
if (value != null) {
|
|
|
|
setState(() {
|
|
|
|
print(value);
|
|
|
|
fromDate = DateUtil.formatDateStr(value,
|
|
|
|
format: DateFormats.y_mo_d);
|
|
|
|
});
|
|
|
|
}
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
},
|
|
|
|
dateTime: fromDate == '选择日期'
|
|
|
|
? null
|
|
|
|
: DateUtil.getDateTime(fromDate),
|
|
|
|
pickerDateTimeType: PickerDateTimeType.kYMD,
|
|
|
|
onCancel: () {
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
// Container(
|
|
|
|
// width: double.infinity,
|
|
|
|
// height: w(33),
|
|
|
|
// alignment: Alignment.centerLeft,
|
|
|
|
// color: MyColours.color_4DDBDBDB,
|
|
|
|
// padding: EdgeInsets.only(left: w(16)),
|
|
|
|
// child: Text(
|
|
|
|
// '查询时间跨度不超过31天',
|
|
|
|
// style: TextStyle(
|
|
|
|
// color: MyColours.color_999999, fontSize: font(12)),
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
_select('开始日期', fromDate, () {
|
|
|
|
FocusScope.of(context).requestFocus(FocusNode()); //点击空白处隐藏键盘
|
|
|
|
//弹出时间选择器
|
|
|
|
// showPickerDateTime(context);
|
|
|
|
// showDateSelWidget = true;
|
|
|
|
DialogUtil.showPickerDateTime24(
|
|
|
|
context,
|
|
|
|
scaffoldKey,
|
|
|
|
(value) {
|
|
|
|
// {'text': picker.adapter.text, 'select': selecteds}
|
|
|
|
if (value != null) {
|
|
|
|
setState(() {
|
|
|
|
print(value);
|
|
|
|
fromDate = DateUtil.formatDateStr(value,
|
|
|
|
format: DateFormats.y_mo_d);
|
|
|
|
});
|
|
|
|
}),
|
|
|
|
Container(
|
|
|
|
height: ScreenUtil().setWidth(1),
|
|
|
|
color: MyColours.color_E7E7E7,
|
|
|
|
),
|
|
|
|
VEmptyView(24),
|
|
|
|
_select('结束日期', endDate, () {
|
|
|
|
FocusScope.of(context).requestFocus(FocusNode()); //点击空白处隐藏键盘
|
|
|
|
//弹出时间选择器
|
|
|
|
// showPickerDateTime(context);
|
|
|
|
// showDateSelWidget = true;
|
|
|
|
DialogUtil.showPickerDateTime24(
|
|
|
|
context,
|
|
|
|
scaffoldKey,
|
|
|
|
(value) {
|
|
|
|
// {'text': picker.adapter.text, 'select': selecteds}
|
|
|
|
if (value != null) {
|
|
|
|
setState(() {
|
|
|
|
print(value);
|
|
|
|
endDate = DateUtil.formatDateStr(value,
|
|
|
|
format: DateFormats.y_mo_d);
|
|
|
|
});
|
|
|
|
}
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
},
|
|
|
|
dateTime: endDate == '选择日期'
|
|
|
|
? null
|
|
|
|
: DateUtil.getDateTime(endDate),
|
|
|
|
pickerDateTimeType: PickerDateTimeType.kYMD,
|
|
|
|
onCancel: () {
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
}
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
},
|
|
|
|
minValue: DateTime(1987, 1, 1),
|
|
|
|
dateTime:
|
|
|
|
fromDate == '选择日期' ? null : DateUtil.getDateTime(fromDate),
|
|
|
|
pickerDateTimeType: PickerDateTimeType.kYMD,
|
|
|
|
onCancel: () {
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
});
|
|
|
|
}),
|
|
|
|
Container(
|
|
|
|
height: ScreenUtil().setWidth(1),
|
|
|
|
color: MyColours.color_E7E7E7,
|
|
|
|
),
|
|
|
|
VEmptyView(24),
|
|
|
|
_select('结束日期', endDate, () {
|
|
|
|
FocusScope.of(context).requestFocus(FocusNode()); //点击空白处隐藏键盘
|
|
|
|
//弹出时间选择器
|
|
|
|
// showPickerDateTime(context);
|
|
|
|
// showDateSelWidget = true;
|
|
|
|
DialogUtil.showPickerDateTime24(
|
|
|
|
context,
|
|
|
|
scaffoldKey,
|
|
|
|
(value) {
|
|
|
|
// {'text': picker.adapter.text, 'select': selecteds}
|
|
|
|
if (value != null) {
|
|
|
|
setState(() {
|
|
|
|
print(value);
|
|
|
|
endDate = DateUtil.formatDateStr(value,
|
|
|
|
format: DateFormats.y_mo_d);
|
|
|
|
});
|
|
|
|
}),
|
|
|
|
Container(
|
|
|
|
height: ScreenUtil().setWidth(1),
|
|
|
|
color: MyColours.color_E7E7E7,
|
|
|
|
),
|
|
|
|
// VEmptyView(48),
|
|
|
|
//结果展示
|
|
|
|
Column(
|
|
|
|
children: [
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
height: w(40),
|
|
|
|
alignment: Alignment.center,
|
|
|
|
color: MyColours.color_4DDBDBDB,
|
|
|
|
child: Text(
|
|
|
|
'收入580.00,支出290.00',
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_999999, fontSize: font(12)),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
ListView.builder(
|
|
|
|
itemCount: 25,
|
|
|
|
}
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
},
|
|
|
|
minValue: DateTime(1987, 1, 1),
|
|
|
|
dateTime:
|
|
|
|
endDate == '选择日期' ? null : DateUtil.getDateTime(endDate),
|
|
|
|
pickerDateTimeType: PickerDateTimeType.kYMD,
|
|
|
|
onCancel: () {
|
|
|
|
// showDateSelWidget = false;
|
|
|
|
});
|
|
|
|
}),
|
|
|
|
Container(
|
|
|
|
height: ScreenUtil().setWidth(1),
|
|
|
|
color: MyColours.color_E7E7E7,
|
|
|
|
),
|
|
|
|
Consumer<FinanceProvider>(builder: (context, model, _) {
|
|
|
|
if (model.pageStateRecordSearch != PageState.Success) {
|
|
|
|
if (model.pageStateRecordSearch == PageState.Loading) {
|
|
|
|
return Spacer();
|
|
|
|
}
|
|
|
|
return Expanded(
|
|
|
|
child: ExceptionPage(
|
|
|
|
pageState: model.pageStateRecordSearch,
|
|
|
|
callback: () async {
|
|
|
|
_getDiscountOrderList(isShowLoading: true);
|
|
|
|
},
|
|
|
|
emptyMsg: "没有交易记录信息哦",
|
|
|
|
emptyImg: "empty_search",
|
|
|
|
showMsg: "加载中,请稍候...",
|
|
|
|
));
|
|
|
|
} else {
|
|
|
|
return Expanded(
|
|
|
|
child: ListView.builder(
|
|
|
|
itemCount: financeProvider!.discountOrderList.length,
|
|
|
|
shrinkWrap: true,
|
|
|
|
controller: controller,
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
DiscountOrderListModelData? listData =
|
|
|
|
financeProvider!.discountOrderList[index];
|
|
|
|
return Container(
|
|
|
|
height: w(37),
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
border: Border(
|
|
|
|
bottom: BorderSide(
|
|
|
|
color: MyColours.color_E7E7E7,
|
|
|
|
width: w(0.5)))),
|
|
|
|
margin: EdgeInsets.only(
|
|
|
|
left: w(20), bottom: w(10), right: w(20)),
|
|
|
|
padding: EdgeInsets.only(top: w(5)),
|
|
|
|
child: Row(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
child: Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
children: [
|
|
|
|
Text(
|
|
|
|
'收入',
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_515151,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontSize: font(12)),
|
|
|
|
),
|
|
|
|
HEmptyView(8),
|
|
|
|
Text(
|
|
|
|
'扫码支付',
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_515151,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontSize: font(12)),
|
|
|
|
),
|
|
|
|
HEmptyView(70),
|
|
|
|
Text(
|
|
|
|
'2022-05-01 18:00',
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_515151,
|
|
|
|
fontSize: font(10)),
|
|
|
|
),
|
|
|
|
HEmptyView(8),
|
|
|
|
Expanded(
|
|
|
|
child: Text(
|
|
|
|
'+290.00',
|
|
|
|
textAlign: TextAlign.right,
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_515151,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontSize: font(18)),
|
|
|
|
)),
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
alignment: Alignment.center,
|
|
|
|
|
|
|
|
// height: w(40),
|
|
|
|
color: MyColours.color_4DDBDBDB,
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
top: index == 0 ? w(10) : w(22),
|
|
|
|
bottom: w(10)),
|
|
|
|
child: Wrap(
|
|
|
|
runSpacing: w(5),
|
|
|
|
crossAxisAlignment:
|
|
|
|
WrapCrossAlignment.center,
|
|
|
|
children: [
|
|
|
|
Text(
|
|
|
|
listData!.date ?? '',
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_515151,
|
|
|
|
fontSize: font(14)),
|
|
|
|
),
|
|
|
|
HEmptyView(16),
|
|
|
|
Padding(
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
right: index == 0 ? w(33) : 0),
|
|
|
|
child: Text(
|
|
|
|
'收入${listData.total},支出${listData.refundTotal}',
|
|
|
|
maxLines: 3,
|
|
|
|
overflow: TextOverflow.ellipsis,
|
|
|
|
style: TextStyle(
|
|
|
|
color: MyColours.color_999999,
|
|
|
|
fontSize: font(12)),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
)),
|
|
|
|
ListView.builder(
|
|
|
|
itemCount: listData.list?.length,
|
|
|
|
shrinkWrap: true,
|
|
|
|
controller: controller,
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
DiscountOrderListModelDataList? subdata =
|
|
|
|
listData.list?[index];
|
|
|
|
return InkWell(
|
|
|
|
onTap: () {
|
|
|
|
NavigatorUtil
|
|
|
|
.goTransactionRecordDetailPage(
|
|
|
|
context,
|
|
|
|
subdata.status,
|
|
|
|
subdata.status == '00'
|
|
|
|
? subdata.refundId
|
|
|
|
: subdata.transactionId);
|
|
|
|
},
|
|
|
|
child: Container(
|
|
|
|
height: w(37),
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
border: Border(
|
|
|
|
bottom: BorderSide(
|
|
|
|
color: MyColours
|
|
|
|
.color_E7E7E7,
|
|
|
|
width: w(0.5)))),
|
|
|
|
margin: EdgeInsets.only(
|
|
|
|
left: w(20),
|
|
|
|
bottom: w(10),
|
|
|
|
right: w(20)),
|
|
|
|
padding: EdgeInsets.only(top: w(5)),
|
|
|
|
child: Row(
|
|
|
|
mainAxisAlignment:
|
|
|
|
MainAxisAlignment.spaceBetween,
|
|
|
|
children: [
|
|
|
|
Text(
|
|
|
|
subdata!.status != '00'
|
|
|
|
? '收入'
|
|
|
|
: '支出',
|
|
|
|
style: TextStyle(
|
|
|
|
color:
|
|
|
|
MyColours.color_515151,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontSize: font(12)),
|
|
|
|
),
|
|
|
|
HEmptyView(8),
|
|
|
|
Text(
|
|
|
|
subdata.status != '00'
|
|
|
|
? '扫码支付'
|
|
|
|
: '用户退款',
|
|
|
|
style: TextStyle(
|
|
|
|
color:
|
|
|
|
MyColours.color_515151,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontSize: font(12)),
|
|
|
|
),
|
|
|
|
HEmptyView(70),
|
|
|
|
Text(
|
|
|
|
subdata.status != '00'
|
|
|
|
? DateUtil.formatDate(
|
|
|
|
DateTime.fromMillisecondsSinceEpoch(
|
|
|
|
int.parse(subdata.cdate.toString()) *
|
|
|
|
1000),
|
|
|
|
format: DateFormats
|
|
|
|
.y_mo_d_h_m)
|
|
|
|
: subdata.refundCdate ==
|
|
|
|
null
|
|
|
|
? ''
|
|
|
|
: DateUtil.formatDate(
|
|
|
|
DateTime.fromMillisecondsSinceEpoch(
|
|
|
|
int.parse(subdata
|
|
|
|
.refundCdate
|
|
|
|
.toString()) *
|
|
|
|
1000),
|
|
|
|
format: DateFormats
|
|
|
|
.y_mo_d_h_m),
|
|
|
|
style: TextStyle(
|
|
|
|
color:
|
|
|
|
MyColours.color_515151,
|
|
|
|
fontSize: font(10)),
|
|
|
|
),
|
|
|
|
HEmptyView(8),
|
|
|
|
Expanded(
|
|
|
|
child: Text(
|
|
|
|
subdata.status != '00'
|
|
|
|
? '+${subdata.price}'
|
|
|
|
: '-${subdata.price}',
|
|
|
|
textAlign: TextAlign.right,
|
|
|
|
style: TextStyle(
|
|
|
|
color:
|
|
|
|
MyColours.color_515151,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontSize: font(18)),
|
|
|
|
)),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
));
|
|
|
|
})
|
|
|
|
],
|
|
|
|
),
|
|
|
|
);
|
|
|
|
})
|
|
|
|
],
|
|
|
|
)
|
|
|
|
]),
|
|
|
|
)),
|
|
|
|
}));
|
|
|
|
}
|
|
|
|
}),
|
|
|
|
// VEmptyView(48),
|
|
|
|
//结果展示
|
|
|
|
// Column(
|
|
|
|
// children: [
|
|
|
|
// Container(
|
|
|
|
// width: double.infinity,
|
|
|
|
// height: w(40),
|
|
|
|
// alignment: Alignment.center,
|
|
|
|
// color: MyColours.color_4DDBDBDB,
|
|
|
|
// child: Text(
|
|
|
|
// '收入580.00,支出290.00',
|
|
|
|
// style: TextStyle(
|
|
|
|
// color: MyColours.color_999999, fontSize: font(12)),
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ListView.builder(
|
|
|
|
// itemCount: 25,
|
|
|
|
// shrinkWrap: true,
|
|
|
|
// controller: controller,
|
|
|
|
// itemBuilder: (context, index) {
|
|
|
|
// return Container(
|
|
|
|
// height: w(37),
|
|
|
|
// decoration: BoxDecoration(
|
|
|
|
// border: Border(
|
|
|
|
// bottom: BorderSide(
|
|
|
|
// color: MyColours.color_E7E7E7,
|
|
|
|
// width: w(0.5)))),
|
|
|
|
// margin: EdgeInsets.only(
|
|
|
|
// left: w(20), bottom: w(10), right: w(20)),
|
|
|
|
// padding: EdgeInsets.only(top: w(5)),
|
|
|
|
// child: Row(
|
|
|
|
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
// children: [
|
|
|
|
// Text(
|
|
|
|
// '收入',
|
|
|
|
// style: TextStyle(
|
|
|
|
// color: MyColours.color_515151,
|
|
|
|
// fontWeight: FontWeight.bold,
|
|
|
|
// fontSize: font(12)),
|
|
|
|
// ),
|
|
|
|
// HEmptyView(8),
|
|
|
|
// Text(
|
|
|
|
// '扫码支付',
|
|
|
|
// style: TextStyle(
|
|
|
|
// color: MyColours.color_515151,
|
|
|
|
// fontWeight: FontWeight.bold,
|
|
|
|
// fontSize: font(12)),
|
|
|
|
// ),
|
|
|
|
// HEmptyView(70),
|
|
|
|
// Text(
|
|
|
|
// '2022-05-01 18:00',
|
|
|
|
// style: TextStyle(
|
|
|
|
// color: MyColours.color_515151,
|
|
|
|
// fontSize: font(10)),
|
|
|
|
// ),
|
|
|
|
// HEmptyView(8),
|
|
|
|
// Expanded(
|
|
|
|
// child: Text(
|
|
|
|
// '+290.00',
|
|
|
|
// textAlign: TextAlign.right,
|
|
|
|
// style: TextStyle(
|
|
|
|
// color: MyColours.color_515151,
|
|
|
|
// fontWeight: FontWeight.bold,
|
|
|
|
// fontSize: font(18)),
|
|
|
|
// )),
|
|
|
|
// ],
|
|
|
|
// ),
|
|
|
|
// );
|
|
|
|
// })
|
|
|
|
// ],
|
|
|
|
// )
|
|
|
|
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
padding: EdgeInsets.symmetric(vertical: w(13), horizontal: w(79)),
|
|
|
|
padding: EdgeInsets.symmetric(vertical: w(13), horizontal: w(20)),
|
|
|
|
child: Row(
|
|
|
|
children: [
|
|
|
|
RoundButton(
|
|
...
|
...
|
@@ -251,6 +458,7 @@ class _TransactionRecordSearchPageState |
|
|
|
//导出数据
|
|
|
|
},
|
|
|
|
),
|
|
|
|
HEmptyView(30),
|
|
|
|
Expanded(
|
|
|
|
child: RoundButton(
|
|
|
|
text: '查询交易记录',
|
|
...
|
...
|
@@ -264,6 +472,21 @@ class _TransactionRecordSearchPageState |
|
|
|
fontSize: 32,
|
|
|
|
onPressed: () {
|
|
|
|
// 查询交易记录
|
|
|
|
if (fromDate == '选择日期') {
|
|
|
|
Utils.showToast('请选择开始日期');
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
if (endDate == '选择日期') {
|
|
|
|
Utils.showToast('请选择结束日期');
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
if (DateUtil.getDateTime(endDate)
|
|
|
|
.compareTo(DateUtil.getDateTime(fromDate)) <
|
|
|
|
0) {
|
|
|
|
Utils.showToast('结束日期不能早于开始日期');
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
_getDiscountOrderList(isShowLoading: true);
|
|
|
|
},
|
|
|
|
)),
|
|
|
|
],
|
...
|
...
|
|