|
|
@ -24,7 +24,7 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
onPressed: () => Get.back(), |
|
|
onPressed: () => Get.back(), |
|
|
), |
|
|
), |
|
|
title: Text( |
|
|
title: Text( |
|
|
'购买', |
|
|
'purchase'.tr, |
|
|
style: TextStyle( |
|
|
style: TextStyle( |
|
|
fontSize: 18.sp, |
|
|
fontSize: 18.sp, |
|
|
fontWeight: FontWeight.w600, |
|
|
fontWeight: FontWeight.w600, |
|
|
@ -261,7 +261,7 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
UsageType.AI: 'aiFunction'.tr, |
|
|
UsageType.AI: 'aiFunction'.tr, |
|
|
UsageType.Meet: 'conferenceAssistant'.tr, |
|
|
UsageType.Meet: 'conferenceAssistant'.tr, |
|
|
UsageType.Translation: 'simultaneousTranslation'.tr, |
|
|
UsageType.Translation: 'simultaneousTranslation'.tr, |
|
|
UsageType.Vip: 'premiumMember'.tr, |
|
|
UsageType.Vip: 'memberService'.tr, |
|
|
}; |
|
|
}; |
|
|
final iconAndColor = _iconColorForType(type, isDarkMode); |
|
|
final iconAndColor = _iconColorForType(type, isDarkMode); |
|
|
final subColor = isDarkMode ? Colors.white70 : Colors.grey[700]; |
|
|
final subColor = isDarkMode ? Colors.white70 : Colors.grey[700]; |
|
|
@ -281,8 +281,8 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
? DateTime.fromMillisecondsSinceEpoch(vipexptime) |
|
|
? DateTime.fromMillisecondsSinceEpoch(vipexptime) |
|
|
: DateTime.fromMillisecondsSinceEpoch(vipexptime * 1000); |
|
|
: DateTime.fromMillisecondsSinceEpoch(vipexptime * 1000); |
|
|
} |
|
|
} |
|
|
titleStr = 'Vip $viplv'; |
|
|
// titleStr = 'Vip $viplv'; |
|
|
vipSubtitle = expiry != null ? _fmtDate(expiry) : '未开启'; |
|
|
vipSubtitle = expiry != null ? _fmtDate(expiry) : '未激活'; |
|
|
} |
|
|
} |
|
|
return Container( |
|
|
return Container( |
|
|
padding: EdgeInsets.all(16.w), |
|
|
padding: EdgeInsets.all(16.w), |
|
|
@ -346,7 +346,7 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
crossAxisAlignment: CrossAxisAlignment.start, |
|
|
crossAxisAlignment: CrossAxisAlignment.start, |
|
|
children: [ |
|
|
children: [ |
|
|
_buildTypeHeader(type, isDarkMode), |
|
|
_buildTypeHeader(type, isDarkMode), |
|
|
SizedBox(height: 12.h), |
|
|
SizedBox(height: 8.h), |
|
|
_buildGoodsGrid(list, type, isDarkMode), |
|
|
_buildGoodsGrid(list, type, isDarkMode), |
|
|
], |
|
|
], |
|
|
); |
|
|
); |
|
|
@ -504,7 +504,7 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
Column( |
|
|
Column( |
|
|
crossAxisAlignment: CrossAxisAlignment.end, |
|
|
crossAxisAlignment: CrossAxisAlignment.end, |
|
|
children: [ |
|
|
children: [ |
|
|
Text('¥${item.priceYuan.toStringAsFixed(2)}', |
|
|
Text(goodsDisplayPrice(item), |
|
|
style: TextStyle( |
|
|
style: TextStyle( |
|
|
fontSize: 16.sp, |
|
|
fontSize: 16.sp, |
|
|
fontWeight: FontWeight.w600, |
|
|
fontWeight: FontWeight.w600, |
|
|
@ -718,9 +718,9 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
physics: const NeverScrollableScrollPhysics(), |
|
|
physics: const NeverScrollableScrollPhysics(), |
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( |
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( |
|
|
crossAxisCount: 2, |
|
|
crossAxisCount: 2, |
|
|
mainAxisSpacing: 12.h, |
|
|
mainAxisSpacing: 8.h, |
|
|
crossAxisSpacing: 12.w, |
|
|
crossAxisSpacing: 12.w, |
|
|
childAspectRatio: 1.15, |
|
|
childAspectRatio: 1.3, |
|
|
), |
|
|
), |
|
|
itemCount: list.length, |
|
|
itemCount: list.length, |
|
|
itemBuilder: (_, i) => _buildGridItemCard(list[i], type, isDarkMode), |
|
|
itemBuilder: (_, i) => _buildGridItemCard(list[i], type, isDarkMode), |
|
|
@ -751,7 +751,7 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
children: [ |
|
|
children: [ |
|
|
Container( |
|
|
Container( |
|
|
width: 34.w, |
|
|
width: 34.w, |
|
|
height: 34.w, |
|
|
height: 20.w, |
|
|
decoration: BoxDecoration( |
|
|
decoration: BoxDecoration( |
|
|
color: iconColors.background, |
|
|
color: iconColors.background, |
|
|
borderRadius: BorderRadius.circular(17.r), |
|
|
borderRadius: BorderRadius.circular(17.r), |
|
|
@ -761,11 +761,11 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
SizedBox(width: 8.w), |
|
|
SizedBox(width: 8.w), |
|
|
Expanded( |
|
|
Expanded( |
|
|
child: Text( |
|
|
child: Text( |
|
|
localizedGoodsName(item), |
|
|
goodsDisplayPrice(item), |
|
|
maxLines: 1, |
|
|
maxLines: 1, |
|
|
overflow: TextOverflow.ellipsis, |
|
|
overflow: TextOverflow.ellipsis, |
|
|
style: TextStyle( |
|
|
style: TextStyle( |
|
|
fontSize: 14.sp, |
|
|
fontSize: 21.sp, |
|
|
fontWeight: FontWeight.w600, |
|
|
fontWeight: FontWeight.w600, |
|
|
color: isDarkMode ? Colors.white : Colors.black, |
|
|
color: isDarkMode ? Colors.white : Colors.black, |
|
|
), |
|
|
), |
|
|
@ -776,27 +776,19 @@ class GoodsvipView extends GetView<GoodsvipController> { |
|
|
SizedBox(height: 6.h), |
|
|
SizedBox(height: 6.h), |
|
|
Expanded( |
|
|
Expanded( |
|
|
child: Text( |
|
|
child: Text( |
|
|
localizedGoodsDesc(item), |
|
|
localizedGoodsName(item), |
|
|
maxLines: 3, |
|
|
maxLines: 3, |
|
|
overflow: TextOverflow.ellipsis, |
|
|
overflow: TextOverflow.ellipsis, |
|
|
style: TextStyle( |
|
|
style: TextStyle( |
|
|
fontSize: 12.sp, |
|
|
fontSize: 15.sp, |
|
|
color: isDarkMode ? Colors.white70 : Colors.grey[700], |
|
|
color: isDarkMode ? Colors.white70 : Colors.grey[700], |
|
|
), |
|
|
), |
|
|
), |
|
|
), |
|
|
), |
|
|
), |
|
|
SizedBox(height: 6.h), |
|
|
// SizedBox(height: 6.h), |
|
|
Row( |
|
|
Row( |
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween, |
|
|
mainAxisAlignment: MainAxisAlignment.end, |
|
|
children: [ |
|
|
children: [ |
|
|
Text( |
|
|
|
|
|
'¥${item.priceYuan.toStringAsFixed(2)}', |
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
fontSize: 14.sp, |
|
|
|
|
|
fontWeight: FontWeight.w600, |
|
|
|
|
|
color: isDarkMode ? Colors.white : Colors.black, |
|
|
|
|
|
), |
|
|
|
|
|
), |
|
|
|
|
|
GestureDetector( |
|
|
GestureDetector( |
|
|
onTap: () => controller.purchase(item), |
|
|
onTap: () => controller.purchase(item), |
|
|
child: Container( |
|
|
child: Container( |
|
|
|