30 changed files with 2600 additions and 1631 deletions
Unified View
Diff Options
-
BINassets/images/vip_buy_tag.png
-
BINassets/images/vip_chat.png
-
BINassets/images/vip_gift.png
-
BINassets/images/vip_message.png
-
BINassets/images/vip_special.png
-
BINassets/images/vip_visitor.png
-
BINassets/images/vip_voice.png
-
151lib/controller/discover/visitor_controller.dart
-
25lib/controller/mine/auth_controller.dart
-
37lib/controller/mine/edit_info_controller.dart
-
17lib/controller/mine/mine_controller.dart
-
25lib/controller/mine/rose_controller.dart
-
71lib/generated/assets.dart
-
75lib/model/discover/visitor_model.dart
-
21lib/model/mine/submit_order_data.dart
-
3lib/network/api_urls.dart
-
6lib/network/user_api.dart
-
39lib/network/user_api.g.dart
-
258lib/pages/discover/visitor_list_page.dart
-
993lib/pages/home/user_information_page.dart
-
14lib/pages/mine/auth_center_page.dart
-
1164lib/pages/mine/edit_info_page.dart
-
299lib/pages/mine/mine_page.dart
-
81lib/pages/mine/pay_fail_page.dart
-
8lib/pages/mine/real_name_page.dart
-
75lib/pages/mine/renew_manage_page.dart
-
5lib/pages/mine/rose_page.dart
-
54lib/pages/mine/vip_manage_page.dart
-
390lib/pages/mine/vip_page.dart
-
420pubspec.lock
@ -0,0 +1,151 @@ |
|||||
|
// controllers/visitor_controller.dart |
||||
|
import 'package:get/get.dart'; |
||||
|
import 'package:pull_to_refresh/pull_to_refresh.dart'; |
||||
|
import '../../model/discover/visitor_model.dart'; |
||||
|
|
||||
|
class VisitorController extends GetxController { |
||||
|
// 访客列表 |
||||
|
var visitors = <VisitorModel>[].obs; |
||||
|
|
||||
|
// Refresh controllers |
||||
|
final RefreshController refreshController = RefreshController(); |
||||
|
final RefreshController loadMoreController = RefreshController(); |
||||
|
|
||||
|
// 分页参数 |
||||
|
var currentPage = 1.obs; |
||||
|
final int pageSize = 15; |
||||
|
var hasMore = true.obs; |
||||
|
var isLoading = false.obs; |
||||
|
|
||||
|
@override |
||||
|
void onInit() { |
||||
|
super.onInit(); |
||||
|
_loadInitialData(); |
||||
|
} |
||||
|
|
||||
|
// 加载初始数据 |
||||
|
void _loadInitialData() async { |
||||
|
isLoading.value = true; |
||||
|
await Future.delayed(Duration(milliseconds: 800)); // 模拟网络延迟 |
||||
|
|
||||
|
final initialVisitors = _generateMockData(1, pageSize); |
||||
|
visitors.assignAll(initialVisitors); |
||||
|
|
||||
|
isLoading.value = false; |
||||
|
hasMore.value = initialVisitors.length == pageSize; |
||||
|
} |
||||
|
|
||||
|
// 下拉刷新 |
||||
|
void onRefresh() async { |
||||
|
currentPage.value = 1; |
||||
|
hasMore.value = true; |
||||
|
|
||||
|
await Future.delayed(Duration(milliseconds: 1000)); // 模拟网络延迟 |
||||
|
|
||||
|
final newVisitors = _generateMockData(1, pageSize); |
||||
|
visitors.assignAll(newVisitors); |
||||
|
|
||||
|
refreshController.refreshCompleted(); |
||||
|
hasMore.value = newVisitors.length == pageSize; |
||||
|
|
||||
|
if (newVisitors.isEmpty) { |
||||
|
refreshController.loadNoData(); |
||||
|
} else { |
||||
|
refreshController.loadComplete(); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 上拉加载更多 |
||||
|
void onLoadMore() async { |
||||
|
if (!hasMore.value) { |
||||
|
loadMoreController.loadNoData(); |
||||
|
return; |
||||
|
} |
||||
|
|
||||
|
currentPage.value++; |
||||
|
|
||||
|
await Future.delayed(Duration(milliseconds: 800)); // 模拟网络延迟 |
||||
|
|
||||
|
final newVisitors = _generateMockData(currentPage.value, pageSize); |
||||
|
|
||||
|
if (newVisitors.isEmpty) { |
||||
|
hasMore.value = false; |
||||
|
loadMoreController.loadNoData(); |
||||
|
} else { |
||||
|
visitors.addAll(newVisitors); |
||||
|
loadMoreController.loadComplete(); |
||||
|
hasMore.value = false; |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// 删除访客 |
||||
|
void deleteVisitor(String visitorId) { |
||||
|
// visitors.removeWhere((visitor) => visitor.id == visitorId); |
||||
|
Get.snackbar('成功', '已删除访客记录'); |
||||
|
} |
||||
|
|
||||
|
// 清空所有访客记录 |
||||
|
void clearAllVisitors() { |
||||
|
visitors.clear(); |
||||
|
Get.snackbar('成功', '已清空所有访客记录'); |
||||
|
} |
||||
|
|
||||
|
// 获取今日访客数量 |
||||
|
int get todayVisitorsCount { |
||||
|
return visitors.length; |
||||
|
} |
||||
|
|
||||
|
// 获取在线访客数量 |
||||
|
int get onlineVisitorsCount { |
||||
|
return visitors.length; |
||||
|
} |
||||
|
|
||||
|
// 模拟数据生成 |
||||
|
List<VisitorModel> _generateMockData(int page, int size) { |
||||
|
if (page > 3) return []; // 模拟只有3页数据 |
||||
|
|
||||
|
final names = [ |
||||
|
'张三', '李四', '王五', '赵六', '钱七', '孙八', '周九', '吴十', |
||||
|
'小明', '小红', '小刚', '小花', '大山', '小云', '星辰', '大海' |
||||
|
]; |
||||
|
|
||||
|
final avatars = [ |
||||
|
'https://randomuser.me/api/portraits/men/1.jpg', |
||||
|
'https://randomuser.me/api/portraits/women/1.jpg', |
||||
|
'https://randomuser.me/api/portraits/men/2.jpg', |
||||
|
'https://randomuser.me/api/portraits/women/2.jpg', |
||||
|
'https://randomuser.me/api/portraits/men/3.jpg', |
||||
|
'https://randomuser.me/api/portraits/women/3.jpg', |
||||
|
'https://randomuser.me/api/portraits/men/4.jpg', |
||||
|
'https://randomuser.me/api/portraits/women/4.jpg', |
||||
|
]; |
||||
|
|
||||
|
final pages = [ |
||||
|
'首页', '产品页', '关于我们', '博客', '联系方式', '服务页', '价格页', '案例页' |
||||
|
]; |
||||
|
|
||||
|
final startIndex = (page - 1) * size; |
||||
|
final endIndex = startIndex + size; |
||||
|
|
||||
|
return List.generate(size, (index) { |
||||
|
final globalIndex = startIndex + index; |
||||
|
final isOnline = globalIndex % 3 == 0; // 每3个有一个在线 |
||||
|
|
||||
|
return VisitorModel( |
||||
|
miId: 'visitor_${globalIndex + 1}', |
||||
|
nickName: names[globalIndex % names.length], |
||||
|
profilePhoto: avatars[globalIndex % avatars.length], |
||||
|
visitTime: '2025-11-14 10:42:42', |
||||
|
onlineStatus: 2, |
||||
|
describeInfo: '阿萨德垃圾袋杰克伦敦撒娇克拉斯的健康拉屎的 金坷垃四大皆空拉屎的距离考试啊' |
||||
|
); |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
@override |
||||
|
void onClose() { |
||||
|
refreshController.dispose(); |
||||
|
loadMoreController.dispose(); |
||||
|
super.onClose(); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,37 @@ |
|||||
|
import 'package:dating_touchme_app/controller/global.dart'; |
||||
|
import 'package:dating_touchme_app/generated/assets.dart'; |
||||
|
import 'package:dating_touchme_app/model/mine/user_data.dart'; |
||||
|
import 'package:dating_touchme_app/pages/mine/auth_center_page.dart'; |
||||
|
import 'package:dating_touchme_app/pages/mine/my_wallet_page.dart'; |
||||
|
import 'package:dating_touchme_app/pages/mine/rose_page.dart'; |
||||
|
import 'package:get/get.dart'; |
||||
|
import 'package:flutter_smart_dialog/flutter_smart_dialog.dart'; |
||||
|
|
||||
|
class EditInfoController extends GetxController { |
||||
|
|
||||
|
|
||||
|
final menuActive = 1.obs; |
||||
|
|
||||
|
|
||||
|
List<String> imgList = [ |
||||
|
"https://fastly.picsum.photos/id/64/800/800.jpg?hmac=NBZ4_-vqzD6p25oCeaW0H5vH-ql9zzei-SqJNeUo1QU", |
||||
|
"https://fastly.picsum.photos/id/985/800/800.jpg?hmac=DfRt99HFbMJ96DlN-poOhruWYRsexESE94ilLC3g1rU", |
||||
|
"https://fastly.picsum.photos/id/703/800/800.jpg?hmac=-bRTkPxnsiQ5kCo2tfXj6tFrXMD7YnVx7bQ0STno3Tg" |
||||
|
]; |
||||
|
|
||||
|
final nowSelect = 0.obs; |
||||
|
|
||||
|
List<String> tagList = [ |
||||
|
"北京", "160cm", "想要甜甜的恋爱", "本科", "朋友圈摄影师", "英雄联盟", "流放之路", |
||||
|
"CF", "DNA", "堡垒之夜", "SCP" |
||||
|
]; |
||||
|
|
||||
|
final userData = GlobalData().userData.obs; |
||||
|
|
||||
|
@override |
||||
|
void onInit() { |
||||
|
super.onInit(); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,75 @@ |
|||||
|
class VisitorModel { |
||||
|
final String? miId; |
||||
|
final String? profilePhoto; |
||||
|
final String? nickName; |
||||
|
final int? height; |
||||
|
final String? visitTime; |
||||
|
final String? education; |
||||
|
final int? age; |
||||
|
final int? minimumIncome; |
||||
|
final int? maximumIncome; |
||||
|
final String? income; |
||||
|
final String? describeInfo; |
||||
|
final int? vip; |
||||
|
final int? miSessionType; |
||||
|
final int? genderCode; |
||||
|
final int? onlineStatus; |
||||
|
|
||||
|
VisitorModel({ |
||||
|
this.miId, |
||||
|
this.profilePhoto, |
||||
|
this.nickName, |
||||
|
this.height, |
||||
|
this.visitTime, |
||||
|
this.education, |
||||
|
this.age, |
||||
|
this.minimumIncome, |
||||
|
this.maximumIncome, |
||||
|
this.income, |
||||
|
this.describeInfo, |
||||
|
this.vip, |
||||
|
this.miSessionType, |
||||
|
this.genderCode, |
||||
|
this.onlineStatus, |
||||
|
}); |
||||
|
|
||||
|
factory VisitorModel.fromJson(Map<String, dynamic> json) { |
||||
|
return VisitorModel( |
||||
|
miId: json['miId'] as String?, |
||||
|
profilePhoto: json['profilePhoto'] as String?, |
||||
|
nickName: json['nickName'] as String?, |
||||
|
height: json['height'] as int?, |
||||
|
visitTime: json['visitTime'] as String?, |
||||
|
education: json['education'] as String?, |
||||
|
age: json['age'] as int?, |
||||
|
minimumIncome: json['minimumIncome'] as int?, |
||||
|
maximumIncome: json['maximumIncome'] as int?, |
||||
|
income: json['income'] as String?, |
||||
|
describeInfo: json['describeInfo'] as String?, |
||||
|
vip: json['vip'] as int?, |
||||
|
miSessionType: json['miSessionType'] as int?, |
||||
|
genderCode: json['genderCode'] as int?, |
||||
|
onlineStatus: json['onlineStatus'] as int?, |
||||
|
); |
||||
|
} |
||||
|
|
||||
|
Map<String, dynamic> toJson() { |
||||
|
return { |
||||
|
'miId': miId, |
||||
|
'profilePhoto': profilePhoto, |
||||
|
'nickName': nickName, |
||||
|
'height': height, |
||||
|
'visitTime': visitTime, |
||||
|
'education': education, |
||||
|
'age': age, |
||||
|
'minimumIncome': minimumIncome, |
||||
|
'maximumIncome': maximumIncome, |
||||
|
'income': income, |
||||
|
'describeInfo': describeInfo, |
||||
|
'vip': vip, |
||||
|
'miSessionType': miSessionType, |
||||
|
'genderCode': genderCode, |
||||
|
'onlineStatus': onlineStatus, |
||||
|
}; |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,21 @@ |
|||||
|
class SubmitOrderData { |
||||
|
String? orderId; |
||||
|
String? paymentOrderId; |
||||
|
bool? freeSettlement; |
||||
|
|
||||
|
SubmitOrderData({this.orderId, this.paymentOrderId, this.freeSettlement}); |
||||
|
|
||||
|
SubmitOrderData.fromJson(Map<String, dynamic> json) { |
||||
|
orderId = json['orderId']; |
||||
|
paymentOrderId = json['paymentOrderId']; |
||||
|
freeSettlement = json['freeSettlement']; |
||||
|
} |
||||
|
|
||||
|
Map<String, dynamic> toJson() { |
||||
|
final Map<String, dynamic> data = new Map<String, dynamic>(); |
||||
|
data['orderId'] = this.orderId; |
||||
|
data['paymentOrderId'] = this.paymentOrderId; |
||||
|
data['freeSettlement'] = this.freeSettlement; |
||||
|
return data; |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,258 @@ |
|||||
|
// pages/visitor_list_page.dart |
||||
|
import 'package:cached_network_image/cached_network_image.dart'; |
||||
|
import 'package:dating_touchme_app/extension/ex_widget.dart'; |
||||
|
import 'package:flutter/material.dart'; |
||||
|
import 'package:get/get.dart'; |
||||
|
import 'package:pull_to_refresh/pull_to_refresh.dart'; |
||||
|
|
||||
|
import '../../controller/discover/visitor_controller.dart'; |
||||
|
import '../../model/discover/visitor_model.dart'; |
||||
|
|
||||
|
class VisitorListPage extends StatelessWidget { |
||||
|
final VisitorController visitorController = Get.put(VisitorController()); |
||||
|
|
||||
|
VisitorListPage({Key? key}) : super(key: key); |
||||
|
|
||||
|
@override |
||||
|
Widget build(BuildContext context) { |
||||
|
return Scaffold( |
||||
|
backgroundColor: Color(0xffF5F5F5), |
||||
|
appBar: AppBar( |
||||
|
title: Obx(() => Text( |
||||
|
'最近访客 (${visitorController.todayVisitorsCount})', |
||||
|
style: TextStyle(fontSize: 16, fontWeight: FontWeight.bold), |
||||
|
)), |
||||
|
centerTitle: true, |
||||
|
backgroundColor: Colors.white, |
||||
|
actions: [ |
||||
|
// 更多操作 |
||||
|
PopupMenuButton<String>( |
||||
|
onSelected: (value) { |
||||
|
if (value == 'clear') { |
||||
|
_showClearDialog(); |
||||
|
} else if (value == 'sort') { |
||||
|
_showSortDialog(); |
||||
|
} |
||||
|
}, |
||||
|
itemBuilder: (BuildContext context) => [ |
||||
|
PopupMenuItem(value: 'sort', child: Text('排序方式')), |
||||
|
PopupMenuItem(value: 'clear', child: Text('清空记录')), |
||||
|
], |
||||
|
), |
||||
|
], |
||||
|
), |
||||
|
body: Obx(() { |
||||
|
if (visitorController.isLoading.value && visitorController.visitors.isEmpty) { |
||||
|
return Center( |
||||
|
child: Column( |
||||
|
mainAxisAlignment: MainAxisAlignment.center, |
||||
|
children: [ |
||||
|
CircularProgressIndicator(), |
||||
|
SizedBox(height: 16), |
||||
|
Text('加载访客数据中...'), |
||||
|
], |
||||
|
), |
||||
|
); |
||||
|
} |
||||
|
|
||||
|
if (visitorController.visitors.isEmpty) { |
||||
|
return Center( |
||||
|
child: Column( |
||||
|
mainAxisAlignment: MainAxisAlignment.center, |
||||
|
children: [ |
||||
|
Icon(Icons.people_outline, size: 80, color: Colors.grey[300]), |
||||
|
SizedBox(height: 16), |
||||
|
Text( |
||||
|
'暂无访客记录', |
||||
|
style: TextStyle(fontSize: 18, color: Colors.grey), |
||||
|
), |
||||
|
SizedBox(height: 8), |
||||
|
Text( |
||||
|
'下拉刷新获取数据', |
||||
|
style: TextStyle(color: Colors.grey), |
||||
|
), |
||||
|
], |
||||
|
), |
||||
|
); |
||||
|
} |
||||
|
|
||||
|
return SmartRefresher( |
||||
|
controller: visitorController.refreshController, |
||||
|
enablePullDown: true, |
||||
|
enablePullUp: visitorController.hasMore.value, |
||||
|
onRefresh: visitorController.onRefresh, |
||||
|
onLoading: visitorController.onLoadMore, |
||||
|
header: ClassicHeader( |
||||
|
idleText: '下拉刷新', |
||||
|
releaseText: '松开刷新', |
||||
|
refreshingText: '刷新中...', |
||||
|
completeText: '刷新完成', |
||||
|
failedText: '刷新失败', |
||||
|
height: 60, |
||||
|
), |
||||
|
footer: CustomFooter( |
||||
|
builder: (BuildContext context, LoadStatus? mode) { |
||||
|
Widget body; |
||||
|
if (mode == LoadStatus.idle) { |
||||
|
body = Text("上拉加载更多"); |
||||
|
} else if (mode == LoadStatus.loading) { |
||||
|
body = CircularProgressIndicator(); |
||||
|
} else if (mode == LoadStatus.failed) { |
||||
|
body = Text("加载失败,点击重试"); |
||||
|
} else if (mode == LoadStatus.canLoading) { |
||||
|
body = Text("松开加载更多"); |
||||
|
} else { |
||||
|
body = Text("没有更多数据了"); |
||||
|
} |
||||
|
return SizedBox( |
||||
|
height: 36, |
||||
|
child: Center(child: body), |
||||
|
); |
||||
|
}, |
||||
|
), |
||||
|
child: ListView.builder( |
||||
|
padding: const EdgeInsets.only(top: 8, right: 10, left: 10), |
||||
|
itemCount: visitorController.visitors.length, |
||||
|
itemBuilder: (context, index) { |
||||
|
final visitor = visitorController.visitors[index]; |
||||
|
return VisitorListItem(visitor: visitor); |
||||
|
}, |
||||
|
), |
||||
|
); |
||||
|
}), |
||||
|
); |
||||
|
} |
||||
|
|
||||
|
void _showClearDialog() { |
||||
|
Get.dialog( |
||||
|
AlertDialog( |
||||
|
title: Text('确认清空'), |
||||
|
content: Text('确定要清空所有访客记录吗?此操作不可恢复。'), |
||||
|
actions: [ |
||||
|
TextButton( |
||||
|
onPressed: () => Get.back(), |
||||
|
child: Text('取消'), |
||||
|
), |
||||
|
TextButton( |
||||
|
onPressed: () { |
||||
|
visitorController.clearAllVisitors(); |
||||
|
Get.back(); |
||||
|
}, |
||||
|
child: Text('确定', style: TextStyle(color: Colors.red)), |
||||
|
), |
||||
|
], |
||||
|
), |
||||
|
); |
||||
|
} |
||||
|
|
||||
|
void _showSortDialog() { |
||||
|
Get.dialog( |
||||
|
AlertDialog( |
||||
|
title: Text('排序方式'), |
||||
|
content: Column( |
||||
|
mainAxisSize: MainAxisSize.min, |
||||
|
children: [ |
||||
|
ListTile( |
||||
|
title: Text('按访问时间'), |
||||
|
onTap: () { |
||||
|
// 实现排序逻辑 |
||||
|
Get.back(); |
||||
|
}, |
||||
|
), |
||||
|
ListTile( |
||||
|
title: Text('按访问时长'), |
||||
|
onTap: () { |
||||
|
// 实现排序逻辑 |
||||
|
Get.back(); |
||||
|
}, |
||||
|
), |
||||
|
ListTile( |
||||
|
title: Text('按访问次数'), |
||||
|
onTap: () { |
||||
|
// 实现排序逻辑 |
||||
|
Get.back(); |
||||
|
}, |
||||
|
), |
||||
|
], |
||||
|
), |
||||
|
), |
||||
|
); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
class VisitorListItem extends StatelessWidget { |
||||
|
final VisitorModel visitor; |
||||
|
|
||||
|
const VisitorListItem({Key? key, required this.visitor}) : super(key: key); |
||||
|
|
||||
|
@override |
||||
|
Widget build(BuildContext context) { |
||||
|
return Container( |
||||
|
decoration: BoxDecoration( |
||||
|
color: Colors.white, |
||||
|
borderRadius: BorderRadius.circular(12), |
||||
|
), |
||||
|
padding: const EdgeInsets.all(12), |
||||
|
margin: EdgeInsets.only(bottom: 8), |
||||
|
child: Row( |
||||
|
crossAxisAlignment: CrossAxisAlignment.center, |
||||
|
children: [ |
||||
|
// 左侧图片 |
||||
|
Container( |
||||
|
width: 50, |
||||
|
height: 50, |
||||
|
decoration: BoxDecoration( |
||||
|
borderRadius: BorderRadius.circular(8), |
||||
|
color: Colors.blue[100], |
||||
|
image: DecorationImage( |
||||
|
image: NetworkImage(visitor.profilePhoto!), |
||||
|
fit: BoxFit.cover, |
||||
|
), |
||||
|
), |
||||
|
), |
||||
|
SizedBox(width: 12), |
||||
|
Expanded( |
||||
|
child: Column( |
||||
|
children: [ |
||||
|
Row( |
||||
|
children: [ |
||||
|
Text( |
||||
|
visitor.nickName!, |
||||
|
style: TextStyle( |
||||
|
fontSize: 14, |
||||
|
), |
||||
|
), |
||||
|
Spacer(), |
||||
|
Text( |
||||
|
visitor.visitTime!, |
||||
|
style: TextStyle( |
||||
|
color: Colors.grey[500], |
||||
|
fontSize: 13, |
||||
|
), |
||||
|
), |
||||
|
], |
||||
|
), |
||||
|
SizedBox(height: 4), |
||||
|
SizedBox( |
||||
|
// height: 20, // 固定高度20 |
||||
|
child: Text( |
||||
|
visitor.describeInfo!, |
||||
|
style: TextStyle( |
||||
|
fontSize: 13, |
||||
|
color: Color.fromRGBO(51, 51, 51, 0.6), |
||||
|
), |
||||
|
overflow: TextOverflow.ellipsis, // 文本超出显示... |
||||
|
maxLines: 1, // 限制为单行 |
||||
|
), |
||||
|
), |
||||
|
], |
||||
|
) |
||||
|
) |
||||
|
], |
||||
|
), |
||||
|
).onTap((){ |
||||
|
// _showVisitorDetail(visitor); |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
} |
||||
993
lib/pages/home/user_information_page.dart
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
1164
lib/pages/mine/edit_info_page.dart
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -0,0 +1,81 @@ |
|||||
|
import 'package:dating_touchme_app/components/page_appbar.dart'; |
||||
|
import 'package:flutter/material.dart'; |
||||
|
import 'package:flutter_screenutil/flutter_screenutil.dart'; |
||||
|
|
||||
|
class PayFailPage extends StatefulWidget { |
||||
|
const PayFailPage({super.key}); |
||||
|
|
||||
|
@override |
||||
|
State<PayFailPage> createState() => _PayFailPageState(); |
||||
|
} |
||||
|
|
||||
|
class _PayFailPageState extends State<PayFailPage> { |
||||
|
@override |
||||
|
Widget build(BuildContext context) { |
||||
|
return Scaffold( |
||||
|
appBar: PageAppbar(title: "支付结果"), |
||||
|
body: SingleChildScrollView( |
||||
|
child: Container( |
||||
|
width: 375.w, |
||||
|
padding: EdgeInsets.symmetric( |
||||
|
vertical: 60.w |
||||
|
), |
||||
|
child: Column( |
||||
|
children: [ |
||||
|
Container( |
||||
|
width: 70.w, |
||||
|
height: 70.w, |
||||
|
margin: EdgeInsets.only(bottom: 16.w), |
||||
|
decoration: BoxDecoration( |
||||
|
borderRadius: BorderRadius.all(Radius.circular(70.w)), |
||||
|
color: const Color.fromRGBO(248, 85, 66, 1) |
||||
|
), |
||||
|
child: Center( |
||||
|
child: Icon( |
||||
|
Icons.close, |
||||
|
size: 50.w, |
||||
|
color: Colors.white, |
||||
|
), |
||||
|
), |
||||
|
), |
||||
|
Text( |
||||
|
"交易失败", |
||||
|
style: TextStyle( |
||||
|
fontSize: 13.w, |
||||
|
fontWeight: FontWeight.w500 |
||||
|
), |
||||
|
), |
||||
|
SizedBox(height: 292.w,), |
||||
|
Container( |
||||
|
width: 150.w, |
||||
|
height: 30.w, |
||||
|
decoration: BoxDecoration( |
||||
|
borderRadius: BorderRadius.all(Radius.circular(30.w)), |
||||
|
color: const Color.fromRGBO(245, 245, 245, 1) |
||||
|
), |
||||
|
child: Center( |
||||
|
child: Text( |
||||
|
"联系客服", |
||||
|
style: TextStyle( |
||||
|
fontSize: 13.w, |
||||
|
fontWeight: FontWeight.w500 |
||||
|
), |
||||
|
), |
||||
|
), |
||||
|
), |
||||
|
SizedBox(height: 18.w,), |
||||
|
Text( |
||||
|
"返回", |
||||
|
style: TextStyle( |
||||
|
fontSize: 13.w, |
||||
|
color: const Color.fromRGBO(144, 144, 144, 1), |
||||
|
fontWeight: FontWeight.w500 |
||||
|
), |
||||
|
) |
||||
|
], |
||||
|
), |
||||
|
), |
||||
|
), |
||||
|
); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,75 @@ |
|||||
|
import 'package:dating_touchme_app/components/page_appbar.dart'; |
||||
|
import 'package:flutter/material.dart'; |
||||
|
import 'package:flutter_screenutil/flutter_screenutil.dart'; |
||||
|
import 'package:tdesign_flutter/tdesign_flutter.dart'; |
||||
|
|
||||
|
class RenewManagePage extends StatefulWidget { |
||||
|
const RenewManagePage({super.key}); |
||||
|
|
||||
|
@override |
||||
|
State<RenewManagePage> createState() => _RenewManagePageState(); |
||||
|
} |
||||
|
|
||||
|
class _RenewManagePageState extends State<RenewManagePage> { |
||||
|
|
||||
|
bool blockUser = false; |
||||
|
|
||||
|
@override |
||||
|
Widget build(BuildContext context) { |
||||
|
return Scaffold( |
||||
|
appBar: PageAppbar(title: "自动续费管理"), |
||||
|
body: SingleChildScrollView( |
||||
|
child: Column( |
||||
|
children: [ |
||||
|
Container( |
||||
|
padding: EdgeInsets.symmetric( |
||||
|
vertical: 20.w, |
||||
|
horizontal: 14.w |
||||
|
), |
||||
|
margin: EdgeInsets.only( |
||||
|
bottom: 12.w |
||||
|
), |
||||
|
child: Row( |
||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween, |
||||
|
children: [ |
||||
|
Text( |
||||
|
"自动续费管理", |
||||
|
style: TextStyle( |
||||
|
fontSize: 13.w, |
||||
|
fontWeight: FontWeight.w500 |
||||
|
), |
||||
|
), |
||||
|
TDSwitch( |
||||
|
isOn: blockUser, |
||||
|
trackOnColor: const Color.fromRGBO(117, 98, 249, 1), |
||||
|
onChanged: (bool e){ |
||||
|
print(e); |
||||
|
blockUser = e; |
||||
|
setState(() { |
||||
|
|
||||
|
}); |
||||
|
return e; |
||||
|
}, |
||||
|
), |
||||
|
], |
||||
|
), |
||||
|
), |
||||
|
Padding( |
||||
|
padding: EdgeInsets.symmetric( |
||||
|
horizontal: 14.w |
||||
|
), |
||||
|
child: Text( |
||||
|
"关闭“会员自动续费”即可解除连续包月协议,次月将不再扣除会员服务费,也可以前往支付宝和微信进行解约。", |
||||
|
style: TextStyle( |
||||
|
fontSize: 11.w, |
||||
|
color: const Color.fromRGBO(144, 144, 144, 1) |
||||
|
), |
||||
|
), |
||||
|
) |
||||
|
|
||||
|
], |
||||
|
), |
||||
|
), |
||||
|
); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,54 @@ |
|||||
|
import 'package:dating_touchme_app/components/page_appbar.dart'; |
||||
|
import 'package:dating_touchme_app/extension/ex_widget.dart'; |
||||
|
import 'package:dating_touchme_app/pages/mine/renew_manage_page.dart'; |
||||
|
import 'package:flutter/material.dart'; |
||||
|
import 'package:flutter_screenutil/flutter_screenutil.dart'; |
||||
|
import 'package:get/get.dart'; |
||||
|
import 'package:get/get_core/src/get_main.dart'; |
||||
|
|
||||
|
class VipManagePage extends StatefulWidget { |
||||
|
const VipManagePage({super.key}); |
||||
|
|
||||
|
@override |
||||
|
State<VipManagePage> createState() => _VipManagePageState(); |
||||
|
} |
||||
|
|
||||
|
class _VipManagePageState extends State<VipManagePage> { |
||||
|
@override |
||||
|
Widget build(BuildContext context) { |
||||
|
return Scaffold( |
||||
|
appBar: PageAppbar(title: "会员特权管理"), |
||||
|
body: SingleChildScrollView( |
||||
|
child: Column( |
||||
|
children: [ |
||||
|
Container( |
||||
|
padding: EdgeInsets.symmetric( |
||||
|
vertical: 20.w, |
||||
|
horizontal: 14.w |
||||
|
), |
||||
|
child: Row( |
||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween, |
||||
|
children: [ |
||||
|
Text( |
||||
|
"自动续费管理", |
||||
|
style: TextStyle( |
||||
|
fontSize: 13.w, |
||||
|
fontWeight: FontWeight.w500 |
||||
|
), |
||||
|
), |
||||
|
Icon( |
||||
|
Icons.keyboard_arrow_right, |
||||
|
size: 20.w, |
||||
|
color: const Color.fromRGBO(191, 191, 191, 1), |
||||
|
) |
||||
|
], |
||||
|
), |
||||
|
).onTap((){ |
||||
|
Get.to(() => RenewManagePage()); |
||||
|
}) |
||||
|
], |
||||
|
), |
||||
|
), |
||||
|
); |
||||
|
} |
||||
|
} |
||||
420
pubspec.lock
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
Write
Preview
Loading…
Cancel
Save