Browse Source

更改

ff_new
w-R 3 years ago
parent
commit
f94d241e93
  1. 30
      lib/community/community_course.dart
  2. 6
      lib/community/community_details.dart
  3. 6
      lib/community/community_view/class_details.dart
  4. 12
      lib/community/community_view/course_banner.dart
  5. 30
      lib/home/home_view/home_banner.dart
  6. 2
      lib/home/home_view/shortcut_operation.dart
  7. 8
      lib/home/huixiang_view/huixiang_banner.dart
  8. 25
      lib/home/points_mall_view/points_goods_view.dart
  9. 9
      lib/home/points_mall_view/points_mall_banner.dart
  10. 2
      lib/integral/integral_page.dart
  11. 41
      lib/integral_store/integral_store_details_page.dart
  12. 2
      lib/mine/coupons_page.dart
  13. 2
      lib/mine/mine_wallet_page.dart
  14. 4
      lib/mine/user_info_page.dart
  15. 283
      lib/order/exchange_order_page.dart
  16. 6
      lib/web/web_page.dart
  17. 6
      lib/web/web_view/comment_list.dart

30
lib/community/community_course.dart

@ -10,18 +10,15 @@ import 'package:huixiang/retrofit/data/brand.dart';
import 'package:huixiang/retrofit/data/brand_data.dart';
import 'package:huixiang/retrofit/data/category_select_list.dart';
import 'package:huixiang/retrofit/data/collect_class_list.dart';
import 'package:huixiang/retrofit/data/course_details.dart';
import 'package:huixiang/retrofit/data/course_list.dart';
import 'package:huixiang/retrofit/data/page.dart';
import 'package:huixiang/retrofit/retrofit_api.dart';
import 'package:huixiang/utils/event_type.dart';
import 'package:huixiang/view_widget/classic_header.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:huixiang/view_widget/login_tips_dialog.dart';
import 'package:huixiang/view_widget/store_title_tab.dart';
import 'package:pull_to_refresh/pull_to_refresh.dart';
import 'package:shared_preferences/shared_preferences.dart';
import 'community_view/class_list_view.dart';
import 'community_view/class_title_tab.dart';
import 'community_view/course_banner.dart';
@ -40,9 +37,8 @@ class _CommunityCourse extends State<CommunityCourse>
final RefreshController refreshController = RefreshController();
ApiService apiService;
List<Brand> brands = [];
BrandData brandData;
List<GlobalKey> globaKeys = [];
List<Brand> brands = [];
List<BannerData> bannerData = [];
List<CategorySelectList> classSelectList = [];
List<CourseList> classList = [];
@ -68,15 +64,31 @@ class _CommunityCourse extends State<CommunityCourse>
///banner
queryCourseBanner() async {
BaseData<PageInfo<BannerData>> banner = await apiService.queryBanner({
if (apiService == null) {
SharedPreferences value = await SharedPreferences.getInstance();
apiService = ApiService(
Dio(),
context: context,
token: value.getString("token"),
);
}
BaseData<PageInfo<BannerData>> baseData =
await apiService.queryBanner({
"model": {"type": "COURSE_BANNER"},
}).catchError((error) {
}).catchError((onError) {
refreshController.refreshFailed();
});
if (baseData != null && baseData.isSuccess) {
bannerData.clear();
bannerData.addAll(banner.data.records);
bannerData.addAll(baseData.data.records);
refreshController.refreshCompleted();
} else {
refreshController.refreshFailed();
}
EasyLoading.dismiss();
}
///
classListAsync() async {
if (apiService == null) {
@ -242,7 +254,7 @@ class _CommunityCourse extends State<CommunityCourse>
List<Widget> classChildItem() {
var widgets = <Widget>[
///banner
CourseBanner(bannerData),
CourseBanner(bannerData,),
SizedBox(height: 28),

6
lib/community/community_details.dart

@ -138,10 +138,14 @@ class _CommunityDetails extends State<CommunityDetails> with WidgetsBindingObser
commentKey,
comunity?.likes ?? comunity?.likes.toString() ?? 0,
comunity.id,
1,
isKeyBoardShow,
_reply,
_delCommentTips,
12.sp,
requestApiFinish: (total){setState(() {
commentTotal = total;
});},
),
if (memberList == null || memberList.length == 0)
Container(
@ -186,7 +190,7 @@ class _CommunityDetails extends State<CommunityDetails> with WidgetsBindingObser
////
_queryInformationLikes() async {
BaseData baseData = await apiService.informationLikes(comunity.id);
BaseData baseData = await apiService.informationLikes(comunity.id).catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
commentKey.currentState.setState(() {});
setState(() {

6
lib/community/community_view/class_details.dart

@ -313,6 +313,7 @@ class _ClassDetails extends State<ClassDetails> with WidgetsBindingObserver{
commentKey,
course?.likes ?? course?.likes?? 0,
widget.arguments["id"],
3,
isKeyBoardShow,
_reply,
_delCommentTips,
@ -528,7 +529,7 @@ class _ClassDetails extends State<ClassDetails> with WidgetsBindingObserver{
////
_queryInformationLikes() async {
BaseData baseData = await apiService.informationLikes(widget.arguments["id"]);
BaseData baseData = await apiService.informationLikes(widget.arguments["id"]).catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
commentKey.currentState.setState(() {});
setState(() {
@ -549,13 +550,14 @@ class _ClassDetails extends State<ClassDetails> with WidgetsBindingObserver{
"content": content,
"parentId": parenId,
"relationalId":widget.arguments["id"],
"relationalType": 1
"relationalType": 3
}).catchError((error) {});
if (baseData != null && baseData.isSuccess) {
CommentListState state = commentKey.currentState;
state.queryMemberCommentList();
commentTextController.text = "";
FocusScope.of(context).unfocus();
// _toComment();
}
}

12
lib/community/community_view/course_banner.dart

@ -71,7 +71,7 @@ class _CourseBanner extends State<CourseBanner> {
);
}
/// contentType 0123
/// contentType 0123,4:,5:
bannerClick(BannerData bannerData) async {
switch (bannerData.contentType) {
case 1:
@ -101,14 +101,18 @@ class _CourseBanner extends State<CourseBanner> {
Navigator.of(context).pushNamed(router);
}
break;
case 5:
Navigator.of(context)
.pushNamed('/router/class_details', arguments: {
"id": bannerData.content,
});
break;
}
}
}
}

30
lib/home/home_view/home_banner.dart

@ -69,26 +69,24 @@ class _HomeBanner extends State<HomeBanner> {
);
}
/// contentType 0123
/// contentType 0123,4:,5:
bannerClick(BannerData bannerData) async {
switch (bannerData.contentType) {
case 1:
Navigator.of(context).pushNamed(
'/router/integral_store_page',
arguments: {"goodsId": bannerData.content},
);
Navigator.of(context).pushNamed('/router/integral_store_page',
arguments: {"goodsId": bannerData.content});
break;
case 2:
Navigator.of(context).pushNamed(
'/router/web_page',
arguments: {"activityId": bannerData.content},
);
Navigator.of(context)
.pushNamed('/router/web_page', arguments: {
"activityId": bannerData.content,
});
break;
case 3:
Navigator.of(context).pushNamed(
'/router/web_page',
arguments: {"articleId": bannerData.content},
);
Navigator.of(context)
.pushNamed('/router/web_page', arguments: {
"articleId": bannerData.content,
});
break;
case 4:
String router = bannerData.content;
@ -101,6 +99,12 @@ class _HomeBanner extends State<HomeBanner> {
Navigator.of(context).pushNamed(router);
}
break;
case 5:
Navigator.of(context)
.pushNamed('/router/class_details', arguments: {
"id": bannerData.content,
});
break;
}
}
}

2
lib/home/home_view/shortcut_operation.dart

@ -80,7 +80,7 @@ class _ShortcutOperation extends State<ShortcutOperation> {
),
GestureDetector(
onTap: (){
Navigator.of(context).pushNamed('/router/recharge_page');
},
child: Container(
width: 106,

8
lib/home/huixiang_view/huixiang_banner.dart

@ -62,7 +62,7 @@ class _HuiXiangBanner extends State<HuiXiangBanner> {
);
}
/// contentType 0123
/// contentType 0123,4:,5:
bannerClick(BannerData bannerData) async {
switch (bannerData.contentType) {
case 1:
@ -92,6 +92,12 @@ class _HuiXiangBanner extends State<HuiXiangBanner> {
Navigator.of(context).pushNamed(router);
}
break;
case 5:
Navigator.of(context)
.pushNamed('/router/class_details', arguments: {
"id": bannerData.content,
});
break;
}
}

25
lib/home/points_mall_view/points_goods_view.dart

@ -100,6 +100,7 @@ class _PointGoods extends State<PointGoods> {
Text(
goods.name,
overflow: TextOverflow.ellipsis,
maxLines: 2,
style: TextStyle(
color: Color(0xff353535),
fontWeight: MyFontWeight.medium,
@ -109,17 +110,12 @@ class _PointGoods extends State<PointGoods> {
SizedBox(
height: 5.h,
),
Container(
height: 35.h * AppUtils.textScale(context),
child: Text(
goods.description,
maxLines: 2,
overflow: TextOverflow.ellipsis,
Text(
S.of(context).jifen_(goods.price),
style: TextStyle(
color: Color(0xFF727272),
fontWeight: MyFontWeight.regular,
fontSize: 12.sp,
),
color: Color(0xFF32A060),
fontSize: 14.sp,
fontWeight: MyFontWeight.semi_bold,
),
),
SizedBox(
@ -143,11 +139,12 @@ class _PointGoods extends State<PointGoods> {
flex: 1,
),
Text(
S.of(context).jifen_(goods.price),
"库存:${goods?.stock ?? goods?.stock ??""}",
style: TextStyle(
color: Color(0xFF32A060),
fontSize: 14.sp,
fontWeight: MyFontWeight.semi_bold,
color: Color(0xFF585858),
decorationColor: Color(0xFF353535),
fontWeight: MyFontWeight.medium,
fontSize: 12.sp,
),
),
],

9
lib/home/points_mall_view/points_mall_banner.dart

@ -69,7 +69,7 @@ class _PointMallBanner extends State<PointMallBanner> {
);
}
/// contentType 0123
/// contentType 0123,4:,5:
bannerClick(BannerData bannerData) async {
switch (bannerData.contentType) {
case 1:
@ -99,10 +99,15 @@ class _PointMallBanner extends State<PointMallBanner> {
Navigator.of(context).pushNamed(router);
}
break;
case 5:
Navigator.of(context)
.pushNamed('/router/class_details', arguments: {
"id": bannerData.content,
});
break;
}
}
}

2
lib/integral/integral_page.dart

@ -152,7 +152,7 @@ class _IntegralPage extends State<IntegralPage> {
return;
}
EasyLoading.show(status: S.of(context).zhengzaijiazai);
BaseData baseData = await apiService.signIn();
BaseData baseData = await apiService.signIn().catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
setState(() {});
SmartDialog.show(

41
lib/integral_store/integral_store_details_page.dart

@ -52,7 +52,7 @@ class _IntegralStoreDetailsPage extends State {
queryGoodsById() async {
BaseData<Goods> baseData =
await apiService.creditGoodsById(arguments["goodsId"]);
await apiService.creditGoodsById(arguments["goodsId"]).catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
setState(() {
goods = baseData.data;
@ -63,13 +63,13 @@ class _IntegralStoreDetailsPage extends State {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: MyAppBar(
background: Color(0xFFFFFFFF),
leadingColor: Colors.black,
title: S.of(context).shangpinxiangqing,
titleColor: Colors.black,
titleSize: 16.sp,
),
// appBar: MyAppBar(
// background: Color(0xFFFFFFFF),
// leadingColor: Colors.black,
// title: S.of(context).shangpinxiangqing,
// titleColor: Colors.black,
// titleSize: 16.sp,
// ),
body: Container(
child: Column(
children: [
@ -213,7 +213,7 @@ class _IntegralStoreDetailsPage extends State {
width: 10.w,
),
Expanded(child: Text(
S.of(context).yuan_(goods.worth),
S.of(context).yuan_(goods?.worth??goods?.worth??""),
style: TextStyle(
color: Color(0xFF585858),
decoration: TextDecoration.lineThrough,
@ -223,7 +223,7 @@ class _IntegralStoreDetailsPage extends State {
),
),),
Text(
"库存:${goods.stock}",
"库存:${goods?.stock ?? goods?.stock ??""}",
style: TextStyle(
color: Color(0xFF585858),
decorationColor: Color(0xFF353535),
@ -268,7 +268,9 @@ class _IntegralStoreDetailsPage extends State {
return Container(
child: AspectRatio(
aspectRatio: 1.3698,
child: Swiper(
child: Stack(
children: [
Swiper(
pagination: SwiperPagination(
alignment: Alignment.bottomCenter,
builder: DotSwiperPaginationBuilder(
@ -291,6 +293,23 @@ class _IntegralStoreDetailsPage extends State {
? 1
: goods.viceImgPaths.length,
),
GestureDetector(
onTap: (){
Navigator.of(context).pop();
},
child: Container(
margin: EdgeInsets.only(left: 16,top: 52),
padding:EdgeInsets.all(5),
child:Image.asset(
"assets/image/integral_return.png",
// alignment: Alignment.center,
width: 24,
height: 24,
),
),
),
],
),
),
);
}

2
lib/mine/coupons_page.dart

@ -211,7 +211,7 @@ class _CouponsPage extends State<CouponsPage> {
}
receiveCoupon(couponId) async {
BaseData baseData = await apiService.receiveCoupon(couponId);
BaseData baseData = await apiService.receiveCoupon(couponId).catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
_onRefresh();
showAlertDialog();

2
lib/mine/mine_wallet_page.dart

@ -57,7 +57,7 @@ class _MineWalletPage extends State<MineWalletPage> {
}
queryUserBalance() async {
BaseData<UserInfo> baseData = await apiService.queryInfo();
BaseData<UserInfo> baseData = await apiService.queryInfo().catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
userInfo = baseData.data;
mBalance = double.tryParse(userInfo.money);

4
lib/mine/user_info_page.dart

@ -344,7 +344,7 @@ class _UserInfoPage extends State<UserInfoPage> {
///
modifyInfos() async {
var info = await apiService.editInfo(modifyInfo);
var info = await apiService.editInfo(modifyInfo).catchError((onError) {});
if (info.isSuccess) {
setState(() {
SmartDialog.showToast("用户信息修改成功", alignment: Alignment.center);
@ -355,7 +355,7 @@ class _UserInfoPage extends State<UserInfoPage> {
///
fileUpload() async {
if (filePath != null && filePath != "" && await File(filePath).exists()) {
BaseData<UploadResult> baseData = await apiService.upload(File(filePath), 123123123);
BaseData<UploadResult> baseData = await apiService.upload(File(filePath), 123123123).catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
UploadResult uploadResult = baseData.data;
modifyInfo["headimg"] = uploadResult.url;

283
lib/order/exchange_order_page.dart

@ -13,6 +13,7 @@ import 'package:huixiang/retrofit/retrofit_api.dart';
import 'package:huixiang/utils/font_weight.dart';
import 'package:huixiang/utils/min.dart';
import 'package:huixiang/view_widget/my_appbar.dart';
import 'package:huixiang/view_widget/round_button.dart';
import 'package:shared_preferences/shared_preferences.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
@ -226,6 +227,85 @@ class _ExchangeOrderPage extends State<ExchangeOrderPage> {
],
),
),
Container(
margin:
EdgeInsets.only(left: 16, right: 16, top: 26, bottom: 8),
padding: EdgeInsets.all(20),
decoration: BoxDecoration(
color: Colors.white,
boxShadow: [
BoxShadow(
color: Colors.black.withAlpha(12),
offset: Offset(0, 3),
blurRadius: 14,
spreadRadius: 0,
)
],
borderRadius: BorderRadius.all(Radius.circular(8)),
),
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceAround,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
Image.asset(
"assets/image/icon_order_exchange_info.png",
width: 24,
height: 24,
),
SizedBox(width: 4),
Text(
S.of(context).duihuanxinxi,
style: TextStyle(
fontWeight: FontWeight.bold,
fontSize: 16,
color: Color(0xFF353535)),
),
],
),
SizedBox(
height: 18.h,
),
Row(
children: [
Text(
S.of(context).lingqufangshi,
style: TextStyle(
fontSize: 14.sp,
color: Color(0xFF353535),
),
),
SizedBox(
width: 12.w,
),
Text(
widget.arguments["useTyped"] == 1
? S.of(context).ziti
: widget.arguments["useTyped"] == 2
? S.of(context).peisong
: S.of(context).xianshangfafang,
style: TextStyle(
fontSize: 14.sp,
color: Color(0xFF353535),
),
),
],
),
SizedBox(
height: 12.h,
),
Text(
"非实物商品兑换后领取到卡包即可使用!",
style: TextStyle(
fontSize: 14.sp,
color: Color(0xFF32A060),
fontWeight: MyFontWeight.medium
),
),
],
),
),
Container(
margin:
EdgeInsets.only(left: 16, right: 16, top: 8, bottom: 16),
@ -318,38 +398,62 @@ class _ExchangeOrderPage extends State<ExchangeOrderPage> {
SizedBox(
height: 12.h,
),
// Row(
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
// crossAxisAlignment: CrossAxisAlignment.center,
// children: [
// Text(
// "商品积分",
// style:
// TextStyle(fontSize: 14, color: Color(0xFF353535)),
// ),
// SizedBox(
// width: 12,
// ),
// Text(
// S.of(context).jifen_(widget.arguments["price"]),
// style: TextStyle(
// fontSize: 12,
// color: Colors.black,
// ),
// ),
// ],
// ),
// SizedBox(
// height: 12,
// ),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Text(
"实付积分",
"应付数额",
style:
TextStyle(fontSize: 14, color: Color(0xFF353535),fontWeight: MyFontWeight.regular),
),
SizedBox(
width: 12,
),
Text(
S.of(context).jifen_(widget.arguments["price"]),
style: TextStyle(
fontSize: 14.sp, color: Color(0xFF353535)),
fontSize: 12,
color: Colors.black,
),
),
],
),
SizedBox(
height: 12,
),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Text(
"现金抵扣积分",
style:
TextStyle(fontSize: 14, color: Color(0xFF353535),fontWeight: MyFontWeight.regular),
),
SizedBox(
width: 12,
),
Text(
S.of(context).jifen_(widget.arguments["price"]),
style: TextStyle(
fontSize: 12,
color: Colors.black,
),
),
],
),
SizedBox(
height: 12,
),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Text(
"合计",
style: TextStyle(
fontSize: 14.sp, color: Color(0xFF353535),fontWeight: MyFontWeight.regular),
),
SizedBox(
width: 12.w,
@ -432,7 +536,7 @@ class _ExchangeOrderPage extends State<ExchangeOrderPage> {
left: 16.w,
right: 16.w,
top: 12.h,
bottom:5.h,
bottom:20.h,
),
padding: EdgeInsets.only(
left: 16.w,
@ -577,29 +681,124 @@ class _ExchangeOrderPage extends State<ExchangeOrderPage> {
],
),
),
// GestureDetector(
// onTap: () {
// if (!storeIsSelected) return;
// creditOrder();
// },
// child: Container(
// padding: EdgeInsets.only(top: 16, bottom: 16),
// decoration: BoxDecoration(
// color: MaterialStateColor.resolveWith((states) =>
// storeIsSelected ? Color(0xFF32A060) : Color(0xFFD8D8D8)),
// borderRadius: BorderRadius.only(
// topLeft: Radius.circular(4),
// topRight: Radius.circular(4))),
// alignment: Alignment.center,
// child: Text(
// S.of(context).querenduihuan,
// style: TextStyle(
// fontSize: 16.sp,
// color: MaterialStateColor.resolveWith((states) =>
// storeIsSelected ? Colors.white : Color(0xFFA0A0A0)),
// fontWeight: FontWeight.bold),
// ),
// ),
// ),
Container(
height: 54.h,
color: Colors.white,
child: Row(
children: [
Spacer(),
Padding(padding: EdgeInsets.only(top: 7,right: 16),
child:Column(
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Text(
S.of(context).heji,
style: TextStyle(
fontSize: 12.sp,
fontWeight: MyFontWeight.regular,
color: Colors.black,
),
),
Text(
"¥0.0",
style: TextStyle(
fontSize: 16.sp,
fontWeight: MyFontWeight.medium,
color: Color(0xFF32A060),
),
),
],
)),
GestureDetector(
onTap: () {
},
child: RoundButton(
width: 103.w,
height: 54.h,
text: S.current.jiesuan,
textColor: Colors.white,
fontWeight: MyFontWeight.regular,
backgroup: Color(0xFF32A060),
radius: 0,
fontSize: 16.sp,
padding: EdgeInsets.symmetric(vertical: 5.h),
),
),
],
),
),
Container(
height: 54.h,
color: Colors.white,
child: Row(
children: [
Spacer(),
Padding(padding: EdgeInsets.only(top: 7,right: 16),
child:Column(
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Text(
S.of(context).heji,
style: TextStyle(
fontSize: 12.sp,
fontWeight: MyFontWeight.regular,
color: Colors.black,
),
),
Text(
S.of(context).jifen_(widget.arguments["price"]),
style: TextStyle(
fontSize: 16.sp,
fontWeight: MyFontWeight.medium,
color: Color(0xFF32A060),
),
),
],
)),
GestureDetector(
onTap: () {
if (!storeIsSelected) return;
creditOrder();
},
child: Container(
padding: EdgeInsets.only(top: 16, bottom: 16),
decoration: BoxDecoration(
color: MaterialStateColor.resolveWith((states) =>
storeIsSelected ? Color(0xFF32A060) : Color(0xFFD8D8D8)),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(4),
topRight: Radius.circular(4))),
alignment: Alignment.center,
child: Text(
S.of(context).querenduihuan,
style: TextStyle(
child: RoundButton(
width: 103.w,
height: 54.h,
text: S.current.duihuan,
textColor: Colors.white,
fontWeight: MyFontWeight.regular,
backgroup: Color(0xFF32A060),
radius: 0,
fontSize: 16.sp,
color: MaterialStateColor.resolveWith((states) =>
storeIsSelected ? Colors.white : Color(0xFFA0A0A0)),
fontWeight: FontWeight.bold),
padding: EdgeInsets.symmetric(vertical: 5.h),
),
),
],
),
),
],
),

6
lib/web/web_page.dart

@ -190,7 +190,7 @@ class _WebPage extends State<WebPage> with WidgetsBindingObserver {
///
_queryInformationLikes() async {
BaseData baseData = await apiService.informationLikes(
widget.arguments["activityId"] ?? widget.arguments["articleId"]);
widget.arguments["activityId"] ?? widget.arguments["articleId"]).catchError((onError) {});
if (baseData != null && baseData.isSuccess) {
if (article != null) {
if (article.liked) {
@ -273,10 +273,14 @@ class _WebPage extends State<WebPage> with WidgetsBindingObserver {
commentKey,
article?.likes ?? activity?.likes ?? 0,
widget.arguments["activityId"] ?? widget.arguments["articleId"],
1,
isKeyBoardShow,
_reply,
_delCommentTips,
12.sp,
requestApiFinish: (total){setState(() {
commentTotal = total;
});},
),
],
),

6
lib/web/web_view/comment_list.dart

@ -22,10 +22,11 @@ class CommentList extends StatefulWidget {
final Function delCommentTips;
final double fontSize;
final String relationalId;
final int relationalType;
final int like;
final Function requestApiFinish;
CommentList(Key key, this.like, this.relationalId,
CommentList(Key key, this.like, this.relationalId,this.relationalType,
this.isKeyBoardShow, this.reply, this.delCommentTips, this.fontSize,{this.requestApiFinish})
: super(key: key);
@ -213,10 +214,11 @@ class CommentListState extends State<CommentList> {
"pageNum": 1,
"pageSize": 100,
"relationalId": widget.relationalId,
"relationalType": 1,
"relationalType": widget.relationalType,
}).catchError((error) {});
if (baseData != null && baseData.isSuccess) {
setState(() {
memberList.clear();
commentTotal = baseData.data.size;
widget.requestApiFinish(commentTotal);
memberList.addAll(baseData.data.list);

Loading…
Cancel
Save