Commit 2964573c authored by 林生雨's avatar 林生雨

commit

parent 11a4f46c
......@@ -17,8 +17,10 @@ class LevelOneItem extends StatelessWidget {
VoidCallback lowPrice;
VoidCallback ask;
VoidCallback compare;
Function(int planId) gotoPlan;
LevelOneItem(this.cards, {this.lowPrice, this.ask, this.compare});
LevelOneItem(this.cards,
{this.lowPrice, this.ask, this.compare, this.gotoPlan});
@override
Widget build(BuildContext context) {
......@@ -287,7 +289,10 @@ class LevelOneItem extends StatelessWidget {
)
],
),
);
).gestureDetector(() {
RouterCenterImpl().findMainRouter().jumpPage(context,
"level_two_plan_deatil", {"planId": cards.plan.plan_id}, false);
});
}
Widget lowPriceWidget() {
......
......@@ -7,6 +7,8 @@ import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:gm_flutter/ClueModel/server/entity/PlanFeedBean.dart';
import 'package:gm_flutter/commonModel/base/BaseComponent.dart';
import 'package:gm_flutter/commonModel/util/DartUtil.dart';
import 'package:gm_flutter/main.mark.dart';
class PlanItem extends StatelessWidget {
final Plans plans;
......@@ -104,11 +106,15 @@ class PlanItem extends StatelessWidget {
Positioned(
left: 92,
top: 36,
child: baseText("${stringBuffer.toString()}", 11, Color(0xff999999)),
child:
baseText("${stringBuffer.toString()}", 11, Color(0xff999999)),
)
],
),
),
);
).gestureDetector(() {
RouterCenterImpl().findMainRouter().jumpPage(
context, "level_one_plan_detail", {"planId": plans.id}, false);
});
}
}
......@@ -48,7 +48,6 @@ class PlanState extends BaseState<PlanPage> with TickerProviderStateMixin {
TextEditingController _editingController = TextEditingController();
FocusNode focusNode = FocusNode();
RefreshController refreshController = RefreshController();
List<Widget> planList = List();
BaseMenuListener projectMenuListener = BaseMenuListener();
BaseMenuListener sortMenuListener = BaseMenuListener();
......@@ -66,9 +65,6 @@ class PlanState extends BaseState<PlanPage> with TickerProviderStateMixin {
_model.init();
planBarView =
PlanBarView(_model.managerLive, clickIndex, hideAllMenuListener);
planList.add(towPic().toActive());
planList.add(planBar().toActive());
planList.add(pages());
}
@override
......@@ -607,27 +603,4 @@ class PlanState extends BaseState<PlanPage> with TickerProviderStateMixin {
},
);
}
void _onScroll(double offset) {
var topPos = PosUtil.findPos(globalKey);
if (topPos != null) {
if (topPos.dy > topHeight) {
_model.showTab.notifyView(false);
} else {
_model.showTab.notifyView(true);
}
}
// if (topPos != null && topPos.dy < 0) {
// double dy = -topPos.dy;
// if (dy < 20) {
// dy = 0;
// }
// double alpha = dy / 112;
// if (alpha < 0) {
// alpha = 0;
// } else if (alpha > 1) {
// alpha = 1;
// }
// _model.showTab.notifyView(alpha);
}
}
......@@ -119,6 +119,7 @@ class Cards {
}
class Plan {
int plan_id;
String planName;
String minPrice;
String maxPrice;
......@@ -142,6 +143,7 @@ class Plan {
Plan.fromJson(Map<String, dynamic> json) {
planName = json['plan_name'];
plan_id = json['plan_id'];
minPrice = json['min_price'];
maxPrice = json['max_price'];
positiveRate = json['positive_rate'];
......@@ -162,6 +164,7 @@ class Plan {
data['plan_name'] = this.planName;
data['min_price'] = this.minPrice;
data['max_price'] = this.maxPrice;
data['plan_id'] = this.plan_id;
data['positive_rate'] = this.positiveRate;
data['sales_count'] = this.salesCount;
if (this.baseAttrs != null) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment