|
...
|
...
|
@@ -69,7 +69,8 @@ class NoteBookPageState extends State<NoteBookPage> { |
|
|
|
//初始化时间
|
|
|
|
_initTime() {
|
|
|
|
dateTime = DateTime.now();
|
|
|
|
dateText = "${dateTime.year}年 "+Utils.addZeroNumber(dateTime.month) +
|
|
|
|
dateText = "${dateTime.year}年 " +
|
|
|
|
Utils.addZeroNumber(dateTime.month) +
|
|
|
|
"月" +
|
|
|
|
Utils.addZeroNumber(dateTime.day) +
|
|
|
|
"日" +
|
|
...
|
...
|
@@ -142,8 +143,8 @@ class NoteBookPageState extends State<NoteBookPage> { |
|
|
|
"keywords": "",
|
|
|
|
"sort": "1"
|
|
|
|
};
|
|
|
|
if(tabIndex==1){
|
|
|
|
params["account"]=userModel.user.account;
|
|
|
|
if (tabIndex == 1) {
|
|
|
|
params["account"] = userModel.user.account;
|
|
|
|
}
|
|
|
|
model.getReserveList(context, params);
|
|
|
|
}
|
|
...
|
...
|
@@ -184,8 +185,8 @@ class NoteBookPageState extends State<NoteBookPage> { |
|
|
|
? "0" + dateTime.day.toString()
|
|
|
|
: dateTime.day.toString())
|
|
|
|
};
|
|
|
|
if(tabIndex==1){
|
|
|
|
params["account"]=userModel.user.account;
|
|
|
|
if (tabIndex == 1) {
|
|
|
|
params["account"] = userModel.user.account;
|
|
|
|
}
|
|
|
|
model.getReserveCountDay(context, params);
|
|
|
|
}
|
|
...
|
...
|
@@ -263,7 +264,8 @@ class NoteBookPageState extends State<NoteBookPage> { |
|
|
|
if (Utils.isOneDay(day, dateTime)) return; //日期没变
|
|
|
|
setState(() {
|
|
|
|
DateTime dateNow = DateTime.now();
|
|
|
|
dateText = "${day.year}年 "+Utils.addZeroNumber(day.month) +
|
|
|
|
dateText = "${day.year}年 " +
|
|
|
|
Utils.addZeroNumber(day.month) +
|
|
|
|
"月" +
|
|
|
|
Utils.addZeroNumber(day.day) +
|
|
|
|
"日";
|
|
...
|
...
|
@@ -286,15 +288,17 @@ class NoteBookPageState extends State<NoteBookPage> { |
|
|
|
Container container = Container(
|
|
|
|
color: MyColours.color_ffffff,
|
|
|
|
width: double.infinity,
|
|
|
|
padding: EdgeInsets.only(left: ScreenUtil().setWidth(20),top: ScreenUtil().setWidth(20)),
|
|
|
|
padding: EdgeInsets.only(
|
|
|
|
left: ScreenUtil().setWidth(20), top: ScreenUtil().setWidth(20)),
|
|
|
|
child: Row(
|
|
|
|
mainAxisSize: MainAxisSize.min,
|
|
|
|
children: <Widget>[
|
|
|
|
Container(
|
|
|
|
padding: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(20)),
|
|
|
|
padding:
|
|
|
|
EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(20)),
|
|
|
|
child: GestureDetector(
|
|
|
|
onTap: () {
|
|
|
|
if(tabIndex==0)return;
|
|
|
|
if (tabIndex == 0) return;
|
|
|
|
setState(() {
|
|
|
|
tabIndex = 0;
|
|
|
|
_getReserveList();
|
|
...
|
...
|
@@ -322,30 +326,27 @@ class NoteBookPageState extends State<NoteBookPage> { |
|
|
|
child: Container(
|
|
|
|
height: ScreenUtil().setWidth(6),
|
|
|
|
width: ScreenUtil().setWidth(60),
|
|
|
|
margin:
|
|
|
|
EdgeInsets.only(top: ScreenUtil().setWidth(8)),
|
|
|
|
margin: EdgeInsets.only(top: ScreenUtil().setWidth(8)),
|
|
|
|
decoration: tabIndex == 0
|
|
|
|
? BoxDecoration(color: MyColours.color_199095,borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil()
|
|
|
|
.setWidth(
|
|
|
|
6)))
|
|
|
|
? BoxDecoration(
|
|
|
|
color: MyColours.color_199095,
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil().setWidth(6)))
|
|
|
|
: BoxDecoration(
|
|
|
|
color: MyColours.color_ffffff,
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil()
|
|
|
|
.setWidth(
|
|
|
|
6))
|
|
|
|
),
|
|
|
|
color: MyColours.color_ffffff,
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil().setWidth(6))),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
)),
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
padding: EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(20)),
|
|
|
|
padding:
|
|
|
|
EdgeInsets.symmetric(horizontal: ScreenUtil().setWidth(20)),
|
|
|
|
child: GestureDetector(
|
|
|
|
onTap: () {
|
|
|
|
if(tabIndex==1)return;
|
|
|
|
if (tabIndex == 1) return;
|
|
|
|
setState(() {
|
|
|
|
tabIndex = 1;
|
|
|
|
_getReserveList();
|
|
...
|
...
|
@@ -373,20 +374,16 @@ class NoteBookPageState extends State<NoteBookPage> { |
|
|
|
child: Container(
|
|
|
|
height: ScreenUtil().setWidth(6),
|
|
|
|
width: ScreenUtil().setWidth(60),
|
|
|
|
margin:
|
|
|
|
EdgeInsets.only(top: ScreenUtil().setWidth(8)),
|
|
|
|
margin: EdgeInsets.only(top: ScreenUtil().setWidth(8)),
|
|
|
|
decoration: tabIndex == 1
|
|
|
|
? BoxDecoration(color: MyColours.color_199095,borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil()
|
|
|
|
.setWidth(
|
|
|
|
6)))
|
|
|
|
? BoxDecoration(
|
|
|
|
color: MyColours.color_199095,
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil().setWidth(6)))
|
|
|
|
: BoxDecoration(
|
|
|
|
color: MyColours.color_ffffff,
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil()
|
|
|
|
.setWidth(
|
|
|
|
6))
|
|
|
|
),
|
|
|
|
color: MyColours.color_ffffff,
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
ScreenUtil().setWidth(6))),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
...
|
...
|
|