Commit 8c7389ed authored by 林生雨's avatar 林生雨

co

parent ae142f80
......@@ -51,6 +51,7 @@ class DiscussLowPriceModel extends BaseModel {
.givePhoneAuth(DioUtil.getInstance().getDio(), leadPhoneRequestId)
.listen((event) {
if (event.error == 0) {
NativeToast.showNativeToast("提交成功,请留意机构来电~");
} else {
NativeToast.showNativeToast(event.message);
}
......
......@@ -119,12 +119,10 @@ class PlanCompareDetailPageState extends BaseState<PlanCompareDetailPage> {
Groups group = data.data.second[newIndex];
Widget widget;
if (group.groupType == 'hot') {
widget = Container(
child: planPopularityView(group),
widget = planPopularityView(group);
// height: 100,
// alignment: Alignment.center,
// child: baseText("第一个", 15, Colors.black),
);
} else if (group.groupType == 'normal_attrs') {
widget = Container(
child: planNormalEffectiveAttrsView(group),
......
import 'package:cached_network_image/cached_network_image.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_common/commonModel/toast/NativeToast.dart';
import 'package:gm_flutter/ClueModel/server/entity/PlansCompareFeed.dart';
import 'package:gm_flutter/commonModel/base/BaseComponent.dart';
import 'package:gm_flutter/commonModel/base/BaseState.dart';
import 'package:gm_flutter/commonModel/util/DartUtil.dart';
import 'CallBackCompareItem.dart';
......@@ -49,31 +51,26 @@ class _PlansCompareFeedItemViewState
width: double.maxFinite,
height: 90,
alignment: Alignment.centerLeft,
padding: EdgeInsets.only(top: 20, bottom: 20),
padding: EdgeInsets.only(top: 15, bottom: 15),
child: Row(
children: <Widget>[
GestureDetector(
behavior: HitTestBehavior.opaque,
onTap: () => onClickCheckBox(_icon),
child: Container(
alignment: Alignment.center,
child: ClipRRect(
child: Image.asset(
_icon,
width: 17,
height: 17,
fit: BoxFit.fill,
)),
)),
Container(
alignment: Alignment.center,
child: Image.asset(
_icon,
width: 17,
height: 17,
),
),
Container(
margin: EdgeInsets.only(left: 15, right: 15),
child: ClipRRect(
borderRadius: BorderRadius.circular(4.0),
child: Image.network(
widget.plan.projectImage,
child: CachedNetworkImage(
imageUrl: widget.plan.projectImage,
width: 50,
height: 50,
fit: BoxFit.fill,
fit: BoxFit.cover,
),
),
),
......@@ -94,10 +91,17 @@ class _PlansCompareFeedItemViewState
style: TextStyle(
fontSize: 11, color: Color(0xFF282828))),
TextSpan(
text: widget.plan.positiveRate,
text:
"${(widget.plan.positiveRate.contains(".") ? widget.plan.positiveRate.split(".")[0] : widget.plan.positiveRate).replaceAll("%", "")}",
style: TextStyle(
fontSize: 14,
color: Color(0xFFFF5963),
fontWeight: FontWeight.w500)),
TextSpan(
text: "%",
style: TextStyle(
fontSize: 11,
color: Color(0xFFFF5963),
fontWeight: FontWeight.w500))
])),
],
......@@ -117,7 +121,9 @@ class _PlansCompareFeedItemViewState
)
],
),
);
).gestureDetector(() {
onClickCheckBox(_icon);
});
}
getSecondLevelItem() {
......@@ -133,13 +139,11 @@ class _PlansCompareFeedItemViewState
onTap: () => onClickCheckBox(_icon),
child: Container(
alignment: Alignment.center,
child: ClipRRect(
child: Image.asset(
child: Image.asset(
_icon,
width: 17,
height: 17,
fit: BoxFit.fill,
)),
),
)),
),
Expanded(
......
......@@ -175,8 +175,8 @@ class LevelOneState extends BaseState<LevelOnePage>
},
child: newHome(),
)),
baseSliverTitle(
"${widget.title}", MediaQuery.of(context).size.width, _model.textLive),
baseSliverTitle("${widget.title}", MediaQuery.of(context).size.width,
_model.textLive),
baseSliverBack(() {
if (RouterCenterImpl().findMainRouter().isWithNative()) {
FlutterBoost.singleton.closeCurrent();
......@@ -280,8 +280,11 @@ class LevelOneState extends BaseState<LevelOnePage>
Positioned(
bottom: 8,
left: 15,
child: baseText(
_model.planoverItem.planDescription, 12, Color(0xff999999)),
child: Container(
width: MediaQuery.of(context).size.width - 30 - 100,
child: baseText("${_model.planoverItem.planDescription}", 12,
Color(0xff999999)),
),
),
Positioned(
right: 0,
......@@ -307,11 +310,11 @@ class LevelOneState extends BaseState<LevelOnePage>
Container(
margin: EdgeInsets.only(left: 4),
child: baseText(
"${_model.planoverItem.positiveRate.contains(".") ? _model.planoverItem.positiveRate.split(".")[0] : _model.planoverItem.positiveRate}",
"${(_model.planoverItem.positiveRate.contains(".") ? _model.planoverItem.positiveRate.split(".")[0] : _model.planoverItem.positiveRate).replaceAll("%", "")}",
20,
Color(0xffFF5963)),
),
// baseText("%", 11, Color(0xffFF5963)),
baseText("%", 11, Color(0xffFF5963)),
],
),
),
......@@ -345,7 +348,7 @@ class LevelOneState extends BaseState<LevelOnePage>
Container(
margin: EdgeInsets.only(left: 2, right: 2),
child: Text(
element.attrName,
element.attrValue,
textScaleFactor: 1.0,
maxLines: 1,
overflow: TextOverflow.ellipsis,
......@@ -360,7 +363,7 @@ class LevelOneState extends BaseState<LevelOnePage>
Container(
margin: EdgeInsets.only(left: 2, right: 2),
child: Text(
element.attrValue,
element.attrName,
textScaleFactor: 1.0,
maxLines: 1,
overflow: TextOverflow.ellipsis,
......
......@@ -32,6 +32,7 @@ class PlanItem extends StatelessWidget {
if (rate != null && rate.contains(".")) {
rate = rate.split(".")[0];
}
rate = rate.replaceAll("%", "");
return Container(
margin: EdgeInsets.only(top: 10, left: 10, right: 10),
child: Container(
......@@ -88,7 +89,8 @@ class PlanItem extends StatelessWidget {
Container(
width: 4,
),
baseText("${rate}%", 14, Color(0xffFF5963))
baseText("${rate}", 14, Color(0xffFF5963)),
baseText("%", 11, Color(0xffFF5963)),
],
),
),
......
......@@ -62,7 +62,7 @@ class TestState extends BaseState<TestPage> {
context,
RouterCenterImpl()
.findClueRouter()
.getPlansCompareFeed({"planId": 1, "planType": 1}));
.getPlansCompareFeed({"planId": 1, "planType": 2}));
}));
list.add(listItem("榜单", () {
JumpUtil.jumpToPageRight(context,
......
......@@ -159,10 +159,11 @@ class NestedScrollViewRefreshIndicatorState
Animation<Color> _valueColor;
Future<void> _pendingRefreshFuture;
bool _isIndicatorAtTop=false;
double _dragOffset=0.0;
_RefreshIndicatorMode _mode=_RefreshIndicatorMode.drag;
bool _isIndicatorAtTop;
double _dragOffset;
_RefreshIndicatorMode _mode;
static final Animatable<double> _threeQuarterTween =
Tween<double>(begin: 0.0, end: 0.75);
......@@ -177,6 +178,9 @@ class NestedScrollViewRefreshIndicatorState
func = (str) {
if (str == "refresh") {
if (mounted) {
_isIndicatorAtTop = false;
_dragOffset = 0.0;
_mode = _RefreshIndicatorMode.drag;
_show();
}
}
......@@ -451,8 +455,7 @@ class NestedScrollViewRefreshIndicatorState
final bool showIndeterminateIndicator =
_mode == _RefreshIndicatorMode.refresh ||
_mode == _RefreshIndicatorMode.done;
return
Column(
return Column(
children: <Widget>[
Container(
color: Color(0xffF7F6FA),
......
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