1081 lines
64 KiB
Dart
1081 lines
64 KiB
Dart
import '/components/appbar_widget.dart';
|
|
import '/components/nav_bar1_widget.dart';
|
|
import '/flutterlib/flutter_drop_down.dart';
|
|
import '/flutterlib/flutter_icon_button.dart';
|
|
import '/flutterlib/flutter_theme.dart';
|
|
import '/flutterlib/flutter_util.dart';
|
|
import '/flutterlib/flutter_widgets.dart';
|
|
import '/flutterlib/form_field_controller.dart';
|
|
import 'package:flutter/foundation.dart';
|
|
import 'package:flutter/material.dart';
|
|
import 'package:flutter/services.dart';
|
|
import 'package:google_fonts/google_fonts.dart';
|
|
import 'package:provider/provider.dart';
|
|
import 'search_page_model.dart';
|
|
export 'search_page_model.dart';
|
|
|
|
class SearchPageWidget extends StatefulWidget {
|
|
const SearchPageWidget({Key? key}) : super(key: key);
|
|
|
|
@override
|
|
_SearchPageWidgetState createState() => _SearchPageWidgetState();
|
|
}
|
|
|
|
class _SearchPageWidgetState extends State<SearchPageWidget> {
|
|
late SearchPageModel _model;
|
|
|
|
final scaffoldKey = GlobalKey<ScaffoldState>();
|
|
|
|
@override
|
|
void initState() {
|
|
super.initState();
|
|
_model = createModel(context, () => SearchPageModel());
|
|
|
|
_model.textController1 ??= TextEditingController();
|
|
_model.textFieldFocusNode ??= FocusNode();
|
|
|
|
_model.search122Controller ??= TextEditingController();
|
|
_model.search122FocusNode ??= FocusNode();
|
|
|
|
_model.afterdateController ??= TextEditingController();
|
|
_model.afterdateFocusNode ??= FocusNode();
|
|
|
|
_model.beforedateController ??= TextEditingController();
|
|
_model.beforedateFocusNode ??= FocusNode();
|
|
}
|
|
|
|
@override
|
|
void dispose() {
|
|
_model.dispose();
|
|
|
|
super.dispose();
|
|
}
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
if (isiOS) {
|
|
SystemChrome.setSystemUIOverlayStyle(
|
|
SystemUiOverlayStyle(
|
|
statusBarBrightness: Theme.of(context).brightness,
|
|
systemStatusBarContrastEnforced: true,
|
|
),
|
|
);
|
|
}
|
|
|
|
context.watch<FFAppState>();
|
|
|
|
return GestureDetector(
|
|
onTap: () => _model.unfocusNode.canRequestFocus
|
|
? FocusScope.of(context).requestFocus(_model.unfocusNode)
|
|
: FocusScope.of(context).unfocus(),
|
|
child: Scaffold(
|
|
key: scaffoldKey,
|
|
backgroundColor: FlutterTheme.of(context).primaryBackground,
|
|
appBar: PreferredSize(
|
|
preferredSize: Size.fromHeight(0.0),
|
|
child: AppBar(
|
|
backgroundColor: Color(0xFFE7E36B),
|
|
automaticallyImplyLeading: false,
|
|
actions: [],
|
|
centerTitle: false,
|
|
elevation: 0.0,
|
|
),
|
|
),
|
|
body: SafeArea(
|
|
top: true,
|
|
child: Stack(
|
|
children: [
|
|
Align(
|
|
alignment: AlignmentDirectional(0.0, 0.0),
|
|
child: Column(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Expanded(
|
|
child: Align(
|
|
alignment: AlignmentDirectional(0.0, 0.0),
|
|
child: Container(
|
|
width: 358.0,
|
|
height: 620.0,
|
|
decoration: BoxDecoration(
|
|
color: Colors.white,
|
|
borderRadius: BorderRadius.circular(8.0),
|
|
),
|
|
child: Column(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 20.0, 0.0, 0.0),
|
|
child: Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Text(
|
|
FFLocalizations.of(context).getText(
|
|
'bf6yun7r' /* Search */,
|
|
),
|
|
style: FlutterTheme.of(context)
|
|
.bodyMedium
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Color(0xFF364257),
|
|
fontSize: 24.0,
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 20.0, 0.0, 0.0),
|
|
child: Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Column(
|
|
mainAxisSize: MainAxisSize.max,
|
|
crossAxisAlignment:
|
|
CrossAxisAlignment.start,
|
|
children: [
|
|
Padding(
|
|
padding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 0.0, 12.0),
|
|
child: Text(
|
|
FFLocalizations.of(context).getText(
|
|
'8vzwn8zw' /* Document category */,
|
|
),
|
|
style: FlutterTheme.of(context)
|
|
.bodyMedium
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Color(0xFF364257),
|
|
fontSize: 16.0,
|
|
),
|
|
),
|
|
),
|
|
FlutterDropDown<String>(
|
|
controller: _model
|
|
.categoryId122ValueController ??=
|
|
FormFieldController<String>(
|
|
_model.categoryId122Value ??= 'all',
|
|
),
|
|
options: List<String>.from(
|
|
['all', '1', '2', '3', '4', '5']),
|
|
optionLabels: [
|
|
FFLocalizations.of(context).getText(
|
|
'loltnxzb' /* Any */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'l4cuzcrp' /* Bank statement */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'krq0fxvi' /* Income */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'cr9ztadr' /* Expense */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'cqanobsq' /* Others */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'dmez3h80' /* Income Tax statement */,
|
|
)
|
|
],
|
|
onChanged: (val) => setState(() =>
|
|
_model.categoryId122Value = val),
|
|
width: 326.0,
|
|
height: 40.0,
|
|
textStyle:
|
|
FlutterTheme.of(context)
|
|
.bodyMedium,
|
|
hintText: FFLocalizations.of(context)
|
|
.getText(
|
|
'p4vxy3jr' /* Any */,
|
|
),
|
|
icon: Icon(
|
|
Icons.keyboard_arrow_down_rounded,
|
|
color: FlutterTheme.of(context)
|
|
.secondaryText,
|
|
size: 24.0,
|
|
),
|
|
fillColor: Color(0xFFEBEBE4),
|
|
elevation: 2.0,
|
|
borderColor:
|
|
FlutterTheme.of(context)
|
|
.alternate,
|
|
borderWidth: 2.0,
|
|
borderRadius: 40.0,
|
|
margin:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 4.0, 16.0, 4.0),
|
|
hidesUnderline: true,
|
|
isSearchable: false,
|
|
isMultiSelect: false,
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 20.0, 0.0, 0.0),
|
|
child: Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Column(
|
|
mainAxisSize: MainAxisSize.max,
|
|
crossAxisAlignment:
|
|
CrossAxisAlignment.start,
|
|
children: [
|
|
Padding(
|
|
padding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 0.0, 12.0),
|
|
child: Text(
|
|
FFLocalizations.of(context).getText(
|
|
'zpqqtv2w' /* Status */,
|
|
),
|
|
style: FlutterTheme.of(context)
|
|
.bodyMedium
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Color(0xFF364257),
|
|
fontSize: 16.0,
|
|
),
|
|
),
|
|
),
|
|
FlutterDropDown<String>(
|
|
controller: _model
|
|
.status122ValueController ??=
|
|
FormFieldController<String>(
|
|
_model.status122Value ??= 'all',
|
|
),
|
|
options:
|
|
List<String>.from(['all', '1']),
|
|
optionLabels: [
|
|
FFLocalizations.of(context).getText(
|
|
'0nj03gij' /* All */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'hizuxchp' /* ORC Completed */,
|
|
)
|
|
],
|
|
onChanged: (val) => setState(() =>
|
|
_model.status122Value = val),
|
|
width: 326.0,
|
|
height: 40.0,
|
|
textStyle:
|
|
FlutterTheme.of(context)
|
|
.bodyMedium,
|
|
hintText: FFLocalizations.of(context)
|
|
.getText(
|
|
'3m4xqh30' /* All */,
|
|
),
|
|
icon: Icon(
|
|
Icons.keyboard_arrow_down_rounded,
|
|
color: FlutterTheme.of(context)
|
|
.secondaryText,
|
|
size: 24.0,
|
|
),
|
|
fillColor: Color(0xFFEBEBE4),
|
|
elevation: 2.0,
|
|
borderColor:
|
|
FlutterTheme.of(context)
|
|
.alternate,
|
|
borderWidth: 2.0,
|
|
borderRadius: 40.0,
|
|
margin:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 4.0, 16.0, 4.0),
|
|
hidesUnderline: true,
|
|
isSearchable: false,
|
|
isMultiSelect: false,
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 20.0, 0.0, 0.0),
|
|
child: Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Column(
|
|
mainAxisSize: MainAxisSize.max,
|
|
crossAxisAlignment:
|
|
CrossAxisAlignment.start,
|
|
children: [
|
|
Padding(
|
|
padding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 0.0, 12.0),
|
|
child: Text(
|
|
FFLocalizations.of(context).getText(
|
|
'tekr9cjf' /* Keyword */,
|
|
),
|
|
style: FlutterTheme.of(context)
|
|
.bodyMedium
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Color(0xFF364257),
|
|
fontSize: 16.0,
|
|
),
|
|
),
|
|
),
|
|
Container(
|
|
width: 326.0,
|
|
child: TextFormField(
|
|
controller:
|
|
_model.search122Controller,
|
|
focusNode:
|
|
_model.search122FocusNode,
|
|
autofocus: true,
|
|
obscureText: false,
|
|
decoration: InputDecoration(
|
|
labelStyle:
|
|
FlutterTheme.of(context)
|
|
.labelMedium,
|
|
hintStyle:
|
|
FlutterTheme.of(context)
|
|
.labelMedium,
|
|
enabledBorder: OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme.of(
|
|
context)
|
|
.alternate,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius.circular(40.0),
|
|
),
|
|
focusedBorder: OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme.of(
|
|
context)
|
|
.primary,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius.circular(40.0),
|
|
),
|
|
errorBorder: OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme.of(
|
|
context)
|
|
.error,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius.circular(40.0),
|
|
),
|
|
focusedErrorBorder:
|
|
OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme.of(
|
|
context)
|
|
.error,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius.circular(40.0),
|
|
),
|
|
),
|
|
style: FlutterTheme.of(context)
|
|
.bodyMedium,
|
|
validator: _model
|
|
.search122ControllerValidator
|
|
.asValidator(context),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 20.0, 0.0, 0.0),
|
|
child: Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Column(
|
|
mainAxisSize: MainAxisSize.max,
|
|
crossAxisAlignment:
|
|
CrossAxisAlignment.start,
|
|
children: [
|
|
Padding(
|
|
padding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 0.0, 12.0),
|
|
child: Text(
|
|
FFLocalizations.of(context).getText(
|
|
'f5xgbwel' /* Date uploaded */,
|
|
),
|
|
style: FlutterTheme.of(context)
|
|
.bodyMedium
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Color(0xFF364257),
|
|
fontSize: 16.0,
|
|
),
|
|
),
|
|
),
|
|
FlutterDropDown<String>(
|
|
controller: _model
|
|
.fixDate122ValueController ??=
|
|
FormFieldController<String>(
|
|
_model.fixDate122Value ??= 'all',
|
|
),
|
|
options: List<String>.from([
|
|
'all',
|
|
'1',
|
|
'2',
|
|
'3',
|
|
'4',
|
|
'5',
|
|
'6'
|
|
]),
|
|
optionLabels: [
|
|
FFLocalizations.of(context).getText(
|
|
'eiauo6r1' /* Any time */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'7sujfeqs' /* Today */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'poz7aar9' /* Yesterday */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
't1kmzx9g' /* Last 7 days */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'xdwaftzj' /* Last 30 days */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'7ic68bjh' /* Last 90 days */,
|
|
),
|
|
FFLocalizations.of(context).getText(
|
|
'y57bgre2' /* Custom... */,
|
|
)
|
|
],
|
|
onChanged: (val) => setState(() =>
|
|
_model.fixDate122Value = val),
|
|
width: 326.0,
|
|
height: 40.0,
|
|
textStyle:
|
|
FlutterTheme.of(context)
|
|
.bodyMedium,
|
|
hintText: FFLocalizations.of(context)
|
|
.getText(
|
|
'v12qiant' /* Any time */,
|
|
),
|
|
icon: Icon(
|
|
Icons.keyboard_arrow_down_rounded,
|
|
color: FlutterTheme.of(context)
|
|
.secondaryText,
|
|
size: 24.0,
|
|
),
|
|
fillColor: Color(0xFFEBEBE4),
|
|
elevation: 2.0,
|
|
borderColor:
|
|
FlutterTheme.of(context)
|
|
.alternate,
|
|
borderWidth: 2.0,
|
|
borderRadius: 40.0,
|
|
margin:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 4.0, 16.0, 4.0),
|
|
hidesUnderline: true,
|
|
isSearchable: false,
|
|
isMultiSelect: false,
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
if (_model.fixDate122Value == '6')
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
16.0, 20.0, 0.0, 0.0),
|
|
child: Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
Column(
|
|
mainAxisSize: MainAxisSize.max,
|
|
crossAxisAlignment:
|
|
CrossAxisAlignment.start,
|
|
children: [
|
|
Padding(
|
|
padding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 0.0, 12.0),
|
|
child: Text(
|
|
FFLocalizations.of(context)
|
|
.getText(
|
|
'8hkxol4z' /* Between */,
|
|
),
|
|
style: FlutterTheme.of(
|
|
context)
|
|
.bodyMedium
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Color(0xFF364257),
|
|
fontSize: 16.0,
|
|
),
|
|
),
|
|
),
|
|
Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
children: [
|
|
FlutterIconButton(
|
|
borderColor: Color(0xFFD6DEE9),
|
|
borderRadius: 20.0,
|
|
borderWidth: 1.0,
|
|
buttonSize: 40.0,
|
|
fillColor: Colors.white,
|
|
icon: Icon(
|
|
Icons.calendar_month,
|
|
color: FlutterTheme.of(
|
|
context)
|
|
.primaryText,
|
|
size: 24.0,
|
|
),
|
|
onPressed: () async {
|
|
final _datePicked1Date =
|
|
await showDatePicker(
|
|
context: context,
|
|
initialDate:
|
|
(_model.datePicked1 ??
|
|
DateTime.now()),
|
|
firstDate: DateTime(1900),
|
|
lastDate: DateTime(2050),
|
|
builder: (context, child) {
|
|
return wrapInMaterialDatePickerTheme(
|
|
context,
|
|
child!,
|
|
headerBackgroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.primary,
|
|
headerForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.info,
|
|
headerTextStyle:
|
|
FlutterTheme.of(
|
|
context)
|
|
.headlineLarge
|
|
.override(
|
|
fontFamily:
|
|
'Outfit',
|
|
fontSize:
|
|
32.0,
|
|
fontWeight:
|
|
FontWeight
|
|
.w600,
|
|
),
|
|
pickerBackgroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.secondaryBackground,
|
|
pickerForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.primaryText,
|
|
selectedDateTimeBackgroundColor:
|
|
Color(0xFFE7E36B),
|
|
selectedDateTimeForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.info,
|
|
actionButtonForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.primaryText,
|
|
iconSize: 24.0,
|
|
);
|
|
},
|
|
);
|
|
|
|
if (_datePicked1Date !=
|
|
null) {
|
|
safeSetState(() {
|
|
_model.datePicked1 =
|
|
DateTime(
|
|
_datePicked1Date.year,
|
|
_datePicked1Date.month,
|
|
_datePicked1Date.day,
|
|
);
|
|
});
|
|
}
|
|
},
|
|
),
|
|
Align(
|
|
alignment: AlignmentDirectional(
|
|
-1.0, 0.0),
|
|
child: Padding(
|
|
padding: EdgeInsetsDirectional
|
|
.fromSTEB(
|
|
5.0, 0.0, 0.0, 0.0),
|
|
child: Container(
|
|
width: 120.0,
|
|
child: TextFormField(
|
|
controller: _model
|
|
.afterdateController,
|
|
focusNode: _model
|
|
.afterdateFocusNode,
|
|
autofocus: true,
|
|
obscureText: false,
|
|
decoration:
|
|
InputDecoration(
|
|
labelText:
|
|
dateTimeFormat(
|
|
'y-M-d',
|
|
_model.datePicked1,
|
|
locale:
|
|
FFLocalizations.of(
|
|
context)
|
|
.languageCode,
|
|
),
|
|
labelStyle:
|
|
FlutterTheme.of(
|
|
context)
|
|
.labelMedium,
|
|
hintText:
|
|
FFLocalizations.of(
|
|
context)
|
|
.getText(
|
|
'1g4otzq0' /* After */,
|
|
),
|
|
hintStyle:
|
|
FlutterTheme.of(
|
|
context)
|
|
.labelMedium
|
|
.override(
|
|
fontFamily:
|
|
'Readex Pro',
|
|
color: Color(
|
|
0xFFD6DEE9),
|
|
fontSize:
|
|
16.0,
|
|
),
|
|
enabledBorder:
|
|
OutlineInputBorder(
|
|
borderSide:
|
|
BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.alternate,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(
|
|
40.0),
|
|
),
|
|
focusedBorder:
|
|
OutlineInputBorder(
|
|
borderSide:
|
|
BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.primary,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(
|
|
40.0),
|
|
),
|
|
errorBorder:
|
|
OutlineInputBorder(
|
|
borderSide:
|
|
BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.error,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(
|
|
40.0),
|
|
),
|
|
focusedErrorBorder:
|
|
OutlineInputBorder(
|
|
borderSide:
|
|
BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.error,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(
|
|
40.0),
|
|
),
|
|
),
|
|
style:
|
|
FlutterTheme.of(
|
|
context)
|
|
.bodyMedium,
|
|
validator: _model
|
|
.afterdateControllerValidator
|
|
.asValidator(context),
|
|
),
|
|
),
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional
|
|
.fromSTEB(
|
|
10.0, 0.0, 0.0, 0.0),
|
|
child: FlutterIconButton(
|
|
borderColor:
|
|
Color(0xFFD6DEE9),
|
|
borderRadius: 20.0,
|
|
borderWidth: 1.0,
|
|
buttonSize: 40.0,
|
|
fillColor: Colors.white,
|
|
icon: Icon(
|
|
Icons.calendar_month,
|
|
color: FlutterTheme.of(
|
|
context)
|
|
.primaryText,
|
|
size: 24.0,
|
|
),
|
|
onPressed: () async {
|
|
final _datePicked2Date =
|
|
await showDatePicker(
|
|
context: context,
|
|
initialDate:
|
|
(_model.datePicked2 ??
|
|
DateTime.now()),
|
|
firstDate: DateTime(1900),
|
|
lastDate: DateTime(2050),
|
|
builder:
|
|
(context, child) {
|
|
return wrapInMaterialDatePickerTheme(
|
|
context,
|
|
child!,
|
|
headerBackgroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.primary,
|
|
headerForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.info,
|
|
headerTextStyle:
|
|
FlutterTheme.of(
|
|
context)
|
|
.headlineLarge
|
|
.override(
|
|
fontFamily:
|
|
'Outfit',
|
|
fontSize:
|
|
32.0,
|
|
fontWeight:
|
|
FontWeight
|
|
.w600,
|
|
),
|
|
pickerBackgroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.secondaryBackground,
|
|
pickerForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.primaryText,
|
|
selectedDateTimeBackgroundColor:
|
|
Color(0xFFE7E36B),
|
|
selectedDateTimeForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.info,
|
|
actionButtonForegroundColor:
|
|
FlutterTheme.of(
|
|
context)
|
|
.primaryText,
|
|
iconSize: 24.0,
|
|
);
|
|
},
|
|
);
|
|
|
|
if (_datePicked2Date !=
|
|
null) {
|
|
safeSetState(() {
|
|
_model.datePicked2 =
|
|
DateTime(
|
|
_datePicked2Date.year,
|
|
_datePicked2Date
|
|
.month,
|
|
_datePicked2Date.day,
|
|
);
|
|
});
|
|
}
|
|
},
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional
|
|
.fromSTEB(
|
|
5.0, 0.0, 0.0, 0.0),
|
|
child: Container(
|
|
width: 120.0,
|
|
child: TextFormField(
|
|
controller: _model
|
|
.beforedateController,
|
|
focusNode: _model
|
|
.beforedateFocusNode,
|
|
autofocus: true,
|
|
obscureText: false,
|
|
decoration: InputDecoration(
|
|
labelText: dateTimeFormat(
|
|
'y-M-d',
|
|
_model.datePicked2,
|
|
locale:
|
|
FFLocalizations.of(
|
|
context)
|
|
.languageCode,
|
|
),
|
|
labelStyle:
|
|
FlutterTheme.of(
|
|
context)
|
|
.labelMedium,
|
|
hintText:
|
|
FFLocalizations.of(
|
|
context)
|
|
.getText(
|
|
'b46v0stq' /* Before */,
|
|
),
|
|
hintStyle:
|
|
FlutterTheme.of(
|
|
context)
|
|
.labelMedium
|
|
.override(
|
|
fontFamily:
|
|
'Readex Pro',
|
|
color: Color(
|
|
0xFFD6DEE9),
|
|
fontSize: 16.0,
|
|
),
|
|
enabledBorder:
|
|
OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.alternate,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(40.0),
|
|
),
|
|
focusedBorder:
|
|
OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.primary,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(40.0),
|
|
),
|
|
errorBorder:
|
|
OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.error,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(40.0),
|
|
),
|
|
focusedErrorBorder:
|
|
OutlineInputBorder(
|
|
borderSide: BorderSide(
|
|
color: FlutterTheme
|
|
.of(context)
|
|
.error,
|
|
width: 2.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius
|
|
.circular(40.0),
|
|
),
|
|
),
|
|
style: FlutterTheme.of(
|
|
context)
|
|
.bodyMedium,
|
|
validator: _model
|
|
.beforedateControllerValidator
|
|
.asValidator(context),
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 24.0, 0.0, 0.0),
|
|
child: Row(
|
|
mainAxisSize: MainAxisSize.max,
|
|
mainAxisAlignment:
|
|
MainAxisAlignment.spaceEvenly,
|
|
children: [
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
10.0, 0.0, 0.0, 0.0),
|
|
child: FFButtonWidget(
|
|
onPressed: () async {
|
|
context.pushNamed(
|
|
'search1',
|
|
queryParameters: {
|
|
'search': serializeParam(
|
|
_model.search122Controller.text,
|
|
ParamType.String,
|
|
),
|
|
'status': serializeParam(
|
|
_model.status122Value,
|
|
ParamType.String,
|
|
),
|
|
'category': serializeParam(
|
|
_model.categoryId122Value,
|
|
ParamType.String,
|
|
),
|
|
'fixDate': serializeParam(
|
|
_model.fixDate122Value,
|
|
ParamType.String,
|
|
),
|
|
'dateFrom': serializeParam(
|
|
_model.afterdateController.text,
|
|
ParamType.String,
|
|
),
|
|
'dateTo': serializeParam(
|
|
_model
|
|
.beforedateController.text,
|
|
ParamType.String,
|
|
),
|
|
}.withoutNulls,
|
|
);
|
|
},
|
|
text:
|
|
FFLocalizations.of(context).getText(
|
|
'sr3myfu8' /* Search */,
|
|
),
|
|
options: FFButtonOptions(
|
|
width: 159.0,
|
|
height: 50.0,
|
|
padding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
24.0, 0.0, 24.0, 0.0),
|
|
iconPadding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 0.0, 0.0),
|
|
color: Color(0xFF009B9A),
|
|
textStyle:
|
|
FlutterTheme.of(context)
|
|
.titleSmall
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Colors.white,
|
|
fontSize: 20.0,
|
|
),
|
|
elevation: 3.0,
|
|
borderSide: BorderSide(
|
|
color: Colors.transparent,
|
|
width: 1.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius.circular(40.0),
|
|
),
|
|
),
|
|
),
|
|
Padding(
|
|
padding: EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 10.0, 0.0),
|
|
child: FFButtonWidget(
|
|
onPressed: () async {
|
|
context.safePop();
|
|
},
|
|
text:
|
|
FFLocalizations.of(context).getText(
|
|
'mqiey7ls' /* Cancel */,
|
|
),
|
|
options: FFButtonOptions(
|
|
width: 159.0,
|
|
height: 50.0,
|
|
padding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
24.0, 0.0, 24.0, 0.0),
|
|
iconPadding:
|
|
EdgeInsetsDirectional.fromSTEB(
|
|
0.0, 0.0, 0.0, 0.0),
|
|
color: Color(0xFF9B0025),
|
|
textStyle:
|
|
FlutterTheme.of(context)
|
|
.titleSmall
|
|
.override(
|
|
fontFamily: 'Readex Pro',
|
|
color: Colors.white,
|
|
fontSize: 20.0,
|
|
),
|
|
elevation: 3.0,
|
|
borderSide: BorderSide(
|
|
color: Colors.transparent,
|
|
width: 1.0,
|
|
),
|
|
borderRadius:
|
|
BorderRadius.circular(40.0),
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
Align(
|
|
alignment: AlignmentDirectional(0.0, 1.0),
|
|
child: wrapWithModel(
|
|
model: _model.navBar1Model,
|
|
updateCallback: () => setState(() {}),
|
|
child: NavBar1Widget(),
|
|
),
|
|
),
|
|
Align(
|
|
alignment: AlignmentDirectional(0.0, -1.0),
|
|
child: wrapWithModel(
|
|
model: _model.appbarModel,
|
|
updateCallback: () => setState(() {}),
|
|
child: AppbarWidget(),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|