detail_approved_fragment.dart 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. import 'package:cs_resources/generated/l10n.dart';
  2. import 'package:cs_resources/theme/app_colors_theme.dart';
  3. import 'package:flutter/cupertino.dart';
  4. import 'package:flutter/material.dart';
  5. import 'package:flutter/src/widgets/framework.dart';
  6. import 'package:hooks_riverpod/hooks_riverpod.dart';
  7. import 'package:widgets/ext/ex_widget.dart';
  8. import 'package:widgets/my_button.dart';
  9. import 'package:widgets/my_text_view.dart';
  10. class DetailApprovedFragment extends HookConsumerWidget {
  11. @override
  12. Widget build(BuildContext context, WidgetRef ref) {
  13. return SizedBox(
  14. width: double.infinity,
  15. height: double.infinity,
  16. child: Column(
  17. children: [
  18. SingleChildScrollView(
  19. scrollDirection: Axis.vertical,
  20. physics: const BouncingScrollPhysics(),
  21. child: Container(
  22. width: double.infinity,
  23. color: context.appColors.whiteBG,
  24. child: Column(
  25. mainAxisSize: MainAxisSize.min,
  26. crossAxisAlignment: CrossAxisAlignment.center,
  27. children: [
  28. //状态
  29. MyTextView(
  30. S.current.approved,
  31. marginTop: 17,
  32. textColor: context.appColors.textPrimary,
  33. fontSize: 24,
  34. isFontMedium: true,
  35. ),
  36. MyTextView(
  37. S.current.status,
  38. marginTop: 12,
  39. textColor: context.appColors.textBlack,
  40. fontSize: 17,
  41. isFontRegular: true,
  42. ),
  43. //Send On时间
  44. RichText(
  45. text: TextSpan(
  46. style: TextStyle(fontSize: 15, fontWeight: FontWeight.w400, color: context.appColors.textBlack),
  47. children: <TextSpan>[
  48. TextSpan(
  49. text: S.current.send_on_sometime(' '),
  50. ),
  51. TextSpan(
  52. text: "21 Nov 2024, 03:08 PM",
  53. style: TextStyle(fontSize: 15, fontWeight: FontWeight.w500, color: context.appColors.textBlack),
  54. ),
  55. ],
  56. ),
  57. ).marginOnly(top: 12),
  58. //处理时间
  59. RichText(
  60. text: TextSpan(
  61. style: TextStyle(fontSize: 15, fontWeight: FontWeight.w400, color: context.appColors.textBlack),
  62. children: <TextSpan>[
  63. TextSpan(
  64. text: S.current.approved_on_sometime(' '),
  65. ),
  66. TextSpan(
  67. text: "21 Nov 2024, 03:08 PM",
  68. style: TextStyle(fontSize: 15, fontWeight: FontWeight.w500, color: context.appColors.textBlack),
  69. ),
  70. ],
  71. ),
  72. ).marginOnly(top: 10),
  73. //分割线
  74. Container(
  75. margin: const EdgeInsets.only(top: 19, bottom: 33),
  76. width: 260,
  77. color: context.appColors.dividerDefault,
  78. height: 0.5,
  79. ),
  80. //通行卡的数据
  81. MyTextView(
  82. S.current.serial_number,
  83. marginLeft: 50,
  84. marginRight: 50,
  85. textAlign: TextAlign.center,
  86. textColor: context.appColors.textBlack,
  87. fontSize: 17,
  88. isFontRegular: true,
  89. ),
  90. MyTextView(
  91. "PL24087",
  92. marginTop: 16,
  93. marginBottom: 16,
  94. textColor: context.appColors.textPrimary,
  95. fontSize: 24,
  96. isFontMedium: true,
  97. ),
  98. //提示 Feedback 文本
  99. MyTextView(
  100. S.current.send_feedback_management,
  101. marginBottom: 33,
  102. marginLeft: 50,
  103. marginRight: 50,
  104. textAlign: TextAlign.center,
  105. textColor: context.appColors.textBlack,
  106. fontSize: 15,
  107. isFontRegular: true,
  108. ),
  109. ],
  110. ),
  111. ),
  112. ).expanded(),
  113. Row(
  114. children: [
  115. MyButton(
  116. onPressed: () {},
  117. text: S.current.send_feedback,
  118. textColor: Colors.white,
  119. fontSize: 15,
  120. fontWeight: FontWeight.w400,
  121. radius: 7,
  122. backgroundColor: context.appColors.btnBgDefault,
  123. ).expanded(),
  124. const SizedBox(width: 10),
  125. MyButton(
  126. onPressed: () {},
  127. text: S.current.view_application,
  128. textColor: Colors.white,
  129. fontSize: 15,
  130. fontWeight: FontWeight.w400,
  131. radius: 7,
  132. backgroundColor: context.appColors.greenBG,
  133. ).expanded(),
  134. ],
  135. ).marginOnly(left: 15, right: 15),
  136. MyButton(
  137. onPressed: () {},
  138. text: S.current.remove,
  139. textColor: Colors.white,
  140. fontSize: 15,
  141. fontWeight: FontWeight.w400,
  142. radius: 7,
  143. backgroundColor: context.appColors.orangeBG,
  144. ).marginOnly(top: 6, left: 15, right: 15, bottom: 17.5),
  145. ],
  146. ),
  147. );
  148. }
  149. }