Browse Source

优化样式,补充备注

master
王子贤 2 months ago
parent
commit
0a0d8f9e77
5 changed files with 71 additions and 76 deletions
  1. 5
      lib/model/mine/rose_history_data.dart
  2. 4
      lib/model/mine/wallet_account_record_data.dart
  3. 2
      lib/pages/home/content_card.dart
  4. 39
      lib/pages/mine/my_wallet_page.dart
  5. 97
      lib/pages/mine/rose_history_page.dart

5
lib/model/mine/rose_history_data.dart

@ -38,13 +38,15 @@ class Records {
int? tradeType;
int? tradeBalance;
String? createTime;
String? remark;
Records({this.tradeType, this.tradeBalance, this.createTime});
Records({this.tradeType, this.tradeBalance, this.createTime, this.remark});
Records.fromJson(Map<String, dynamic> json) {
tradeType = json['tradeType'];
tradeBalance = json['tradeBalance'];
createTime = json['createTime'];
remark = json['remark'];
}
Map<String, dynamic> toJson() {
@ -52,6 +54,7 @@ class Records {
data['tradeType'] = this.tradeType;
data['tradeBalance'] = this.tradeBalance;
data['createTime'] = this.createTime;
data['remark'] = this.remark;
return data;
}
}

4
lib/model/mine/wallet_account_record_data.dart

@ -38,6 +38,7 @@ class Records {
String? id;
String? walletAccountId;
String? createTime;
String? remark;
int? tradeType;
double? tradeAmount;
bool? isIncome;
@ -46,6 +47,7 @@ class Records {
{this.id,
this.walletAccountId,
this.createTime,
this.remark,
this.tradeType,
this.tradeAmount,
this.isIncome});
@ -54,6 +56,7 @@ class Records {
id = json['id'];
walletAccountId = json['walletAccountId'];
createTime = json['createTime'];
remark = json['remark'];
tradeType = json['tradeType'];
tradeAmount = json['tradeAmount'];
isIncome = json['isIncome'];
@ -64,6 +67,7 @@ class Records {
data['id'] = this.id;
data['walletAccountId'] = this.walletAccountId;
data['createTime'] = this.createTime;
data['remark'] = this.remark;
data['tradeType'] = this.tradeType;
data['tradeAmount'] = this.tradeAmount;
data['isIncome'] = this.isIncome;

2
lib/pages/home/content_card.dart

@ -214,7 +214,7 @@ class _CardHeader extends StatelessWidget {
SizedBox(
height: 16,
child: Text(
'${item.age ?? 0}岁 · ${item.cityName ?? ''}${item.districtName != null ? item.districtName : ''}',
'${item.age ?? 0}${(item.cityName ?? '') != "" ? "· " : ""}${item.cityName ?? ''}${item.districtName != null ? item.districtName : ''}',
style: TextStyle(
fontSize: 12,
color: Color.fromRGBO(51, 51, 51, 1),

39
lib/pages/mine/my_wallet_page.dart

@ -384,37 +384,14 @@ class _InfoItemState extends State<InfoItem> {
)
],
),
// SizedBox(height: 8.w,),
// Row(
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
// children: [
// Text(
// "服务嘉宾:张三",
// style: TextStyle(
// fontSize: 12.w,
// ),
// ),
// RichText(
// text: TextSpan(
// style: TextStyle(
// fontSize: 12.w,
// fontWeight: FontWeight.w500
// ),
// children: [
// TextSpan(
// text: "营收:",
// ),
// TextSpan(
// text: "680.00",
// style: TextStyle(
// color: const Color.fromRGBO(117, 98, 249, 1)
// )
// ),
// ]
// ),
// )
// ],
// ),
if(widget.item.remark != null && widget.item.remark != "")SizedBox(height: 8.w,),
if(widget.item.remark != null && widget.item.remark != "")Text(
"${widget.item.remark ?? ""}",
style: TextStyle(
fontSize: 12.w,
color: const Color.fromRGBO(153, 153, 153, 1)
),
),
SizedBox(height: 8.w,),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,

97
lib/pages/mine/rose_history_page.dart

@ -144,7 +144,7 @@ class _SendItemState extends State<SendItem> {
@override
Widget build(BuildContext context) {
return Container(
height: 70.w,
padding: EdgeInsets.symmetric(vertical: 10.w),
decoration: BoxDecoration(
border: Border(
bottom: BorderSide(
@ -156,51 +156,62 @@ class _SendItemState extends State<SendItem> {
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Row(
children: [
Container(
width: 40.w,
height: 40.w,
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(40.w)),
color: const Color.fromRGBO(237, 237, 237, 1)
),
child: Center(
child: Image.asset(
Assets.imagesRoseGift,
width: 27.w,
height: 27.w,
Expanded(
child: Row(
children: [
Container(
width: 40.w,
height: 40.w,
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(40.w)),
color: const Color.fromRGBO(237, 237, 237, 1)
),
),
),
SizedBox(width: 22.w,),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text(
widget.item.tradeType == 201 ? "聊天花费" :
widget.item.tradeType == 202 ? "赠送礼物" :
widget.item.tradeType == 203 ? "连麦" :
widget.item.tradeType == 204 ? "1V1语音" :
widget.item.tradeType == 205 ? "1V1视频" :
widget.item.tradeType == 101 ? "充值" : "",
style: TextStyle(
fontSize: 13.w,
color: const Color.fromRGBO(51, 51, 51, 1),
fontWeight: FontWeight.w500
child: Center(
child: Image.asset(
Assets.imagesRoseGift,
width: 27.w,
height: 27.w,
),
),
Text(
"${widget.item.createTime}",
style: TextStyle(
fontSize: 11.w,
color: const Color.fromRGBO(144, 144, 144, 1),
),
)
],
)
],
),
SizedBox(width: 22.w,),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text(
widget.item.tradeType == 201 ? "聊天花费" :
widget.item.tradeType == 202 ? "赠送礼物" :
widget.item.tradeType == 203 ? "连麦" :
widget.item.tradeType == 204 ? "1V1语音" :
widget.item.tradeType == 205 ? "1V1视频" :
widget.item.tradeType == 101 ? "充值" : "",
style: TextStyle(
fontSize: 13.w,
color: const Color.fromRGBO(51, 51, 51, 1),
fontWeight: FontWeight.w500
),
),
if(widget.item.remark != null && widget.item.remark != "")Text(
"${widget.item.remark ?? ""}",
style: TextStyle(
fontSize: 11.w,
color: const Color.fromRGBO(144, 144, 144, 1),
),
),
Text(
"${widget.item.createTime}",
style: TextStyle(
fontSize: 11.w,
color: const Color.fromRGBO(144, 144, 144, 1),
),
)
],
),
)
],
),
),
Text(
"${widget.item.tradeBalance}",

Loading…
Cancel
Save