import 'package:cpt_facility/modules/facility/active/facility_active_screen.dart'; import 'package:cs_resources/generated/l10n.dart'; import 'package:cs_resources/theme/app_colors_theme.dart'; import 'package:flutter/material.dart'; import 'package:widgets/ext/ex_widget.dart'; import 'package:widgets/my_text_view.dart'; /// 设施的Active的Item class FacilityActiveItem extends StatelessWidget { final int index; final String item; const FacilityActiveItem({ required this.index, required this.item, }); @override Widget build(BuildContext context) { return Container( width: double.infinity, margin: const EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5), padding: const EdgeInsets.only(left: 20, right: 15, top: 18, bottom: 23), decoration: BoxDecoration( color: context.appColors.whiteBG, borderRadius: BorderRadius.circular(6.0), // 圆角 ), child: Row( mainAxisSize: MainAxisSize.max, crossAxisAlignment: CrossAxisAlignment.start, children: [ Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ //设施 MyTextView( "Kids party room", fontSize: 16, maxLines: 3, textColor: context.appColors.textBlack, isFontMedium: true, ), //分类 MyTextView( "Blue room", fontSize: 14, marginTop: 3, textColor: context.appColors.textBlack, isFontRegular: true, ), //预订人 MyTextView( S.current.booked_by_someone("Wu Bing Bing"), fontSize: 14, marginTop: 3, textColor: context.appColors.textBlack, isFontRegular: true, ), //日期 MyTextView( "Tue,24 Oct 2023", fontSize: 14, marginTop: 16, textColor: context.appColors.textBlack, isFontRegular: true, ), //时间 MyTextView( "05:00 PM-10:00 PM", fontSize: 14, marginBottom: 7, marginTop: 3, textColor: context.appColors.textBlack, isFontRegular: true, ), //标签 Row( children: [ MyTextView( "Fee Paid", textColor: context.appColors.textPrimary, fontSize: 13, isFontRegular: true, backgroundColor: context.appColors.lightPurpleBg, cornerRadius: 3, paddingLeft: 7, marginRight: 6, paddingRight: 7, paddingTop: 3, paddingBottom: 3, ), MyTextView( "Deposit", textColor: context.appColors.textPrimary, fontSize: 13, isFontRegular: true, backgroundColor: context.appColors.lightPurpleBg, cornerRadius: 3, paddingLeft: 7, marginRight: 6, paddingRight: 7, paddingTop: 3, paddingBottom: 3, ) ], ) ], ).expanded(), Column( mainAxisSize: MainAxisSize.min, mainAxisAlignment:MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, children: [ //查看按钮 MyTextView( S.current.view, textColor: Colors.white, backgroundColor: context.appColors.btnBgDefault, cornerRadius: 7, paddingTop: 9, paddingBottom: 9, textAlign: TextAlign.center, boxWidth: 60, ) ], ) ], ), ); } }