YSCouponCardView.dart 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691
  1. import 'dart:async';
  2. import 'package:dotted_border/dotted_border.dart';
  3. import 'package:flutter/material.dart';
  4. import 'package:qr_flutter/qr_flutter.dart';
  5. import 'package:wakelock/wakelock.dart';
  6. import '../../base/YSNetWorking.dart';
  7. import '../../base/YSTools.dart';
  8. class YSCouponCardView extends StatefulWidget {
  9. final Map item;
  10. final List array;
  11. final bool isShow;
  12. const YSCouponCardView({Key key, @required this.item, this.isShow = false, @required this.array}) : super(key: key);
  13. @override
  14. _YSCouponCardViewState createState() => _YSCouponCardViewState();
  15. }
  16. class _YSCouponCardViewState extends State<YSCouponCardView> {
  17. @override
  18. Widget build(BuildContext context) {
  19. return Container(
  20. height: 267,
  21. width: ysWidth(context),
  22. decoration: BoxDecoration(
  23. color: Color(widget.item['color']),
  24. borderRadius: BorderRadius.all(Radius.circular(9)),
  25. boxShadow: [
  26. BoxShadow(color: Colors.black38,blurRadius: 10)
  27. ]
  28. ),
  29. margin: EdgeInsets.only(top: widget.item['index']*44*1.0),
  30. child: LayoutBuilder(
  31. builder: (context, constraints) {
  32. return widget.isShow?Stack(
  33. children: [
  34. Container(
  35. height: 50,
  36. padding: EdgeInsets.only(left: 40,right: 40),
  37. alignment: Alignment.centerLeft,
  38. child: Row(
  39. children: [
  40. Container(
  41. width: constraints.maxWidth-130,
  42. child: Text(widget.item['name'],style: TextStyle(fontSize: 18,color: Colors.white),maxLines: 1,),
  43. ),
  44. Container(
  45. width: 50,
  46. height: 18,
  47. decoration: BoxDecoration(
  48. color: Colors.white,
  49. borderRadius: BorderRadius.all(Radius.circular(50))
  50. ),
  51. child: Text('共${widget.item['count']}张',style: TextStyle(fontSize: 10,color: Color(widget.item['color'])),),
  52. alignment: Alignment.center,
  53. )
  54. ],
  55. ),
  56. ),
  57. Container(
  58. decoration: BoxDecoration(
  59. image: DecorationImage(image: AssetImage('lib/images/编组 12_fy.png'))
  60. ),
  61. margin: EdgeInsets.only(top: 50),
  62. width: ysWidth(context)-20,
  63. height: 158,
  64. padding: EdgeInsets.only(left: 70,right: 30,top: 30,bottom: 38),
  65. child: Container(
  66. height: 90,
  67. child: Column(
  68. children: [
  69. Container(
  70. alignment: Alignment.centerLeft,
  71. height: 30,
  72. child: Text('编号:${widget.item['no']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),),
  73. ),
  74. Container(
  75. alignment: Alignment.centerLeft,
  76. height: 30,
  77. child: Text('时间:${widget.item['month']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),),
  78. ),
  79. Container(
  80. alignment: Alignment.centerLeft,
  81. height: 30,
  82. child: Text('失效日期:${widget.item['date']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),),
  83. )
  84. ],
  85. ),
  86. ),
  87. ),
  88. Positioned(
  89. left: 0,
  90. bottom: 0,
  91. width: ysWidth(context),
  92. height: 108,
  93. child: Stack(
  94. children: [
  95. Image.asset('lib/images/矩形备份 17_fy.png',color: Color(widget.item['color']),),
  96. Padding(
  97. padding: EdgeInsets.only(left: ysWidth(context)/2-67,top: 55),
  98. child: Image.asset('lib/images/编组 9_fy.png',height: 40,width: 134,),
  99. ),
  100. GestureDetector(
  101. onTap: (){
  102. ysShowBottomAlertView(context, YSCodeAlertView(array: widget.array,item: widget.item,callback: (){
  103. CustomerNotification().dispatch(context);
  104. },),isBarr: true);
  105. },
  106. behavior: HitTestBehavior.opaque,
  107. child: Container(
  108. height: 40,
  109. width: 134,
  110. margin: EdgeInsets.only(left: ysWidth(context)/2-67,top: 55),
  111. alignment: Alignment.center,
  112. child: Text('核销码',style: TextStyle(fontSize: 16,color: Colors.white),),
  113. ),
  114. )
  115. ],
  116. )
  117. )
  118. ],
  119. ):Column(
  120. children: [
  121. Container(
  122. height: 50,
  123. padding: EdgeInsets.only(left: 40,right: 40),
  124. alignment: Alignment.centerLeft,
  125. child: Row(
  126. children: [
  127. Container(
  128. width: constraints.maxWidth-130,
  129. child: Text(widget.item['name'],style: TextStyle(fontSize: 18,color: Colors.white),maxLines: 1,),
  130. ),
  131. Container(
  132. width: 50,
  133. height: 20,
  134. child: Text('共${widget.item['count']}张',style: TextStyle(fontSize: 14,color: Colors.white),),
  135. alignment: Alignment.center,
  136. )
  137. ],
  138. ),
  139. ),
  140. Container(
  141. margin: EdgeInsets.only(top: 167),
  142. height: 50,
  143. padding: EdgeInsets.only(left: 40,right: 40),
  144. alignment: Alignment.centerLeft,
  145. child: Row(
  146. children: [
  147. Container(
  148. width: constraints.maxWidth-130,
  149. child: Text(widget.item['name'],style: TextStyle(fontSize: 18,color: Colors.white),maxLines: 1,),
  150. ),
  151. Container(
  152. width: 50,
  153. height: 20,
  154. child: Text('共${widget.item['count']}张',style: TextStyle(fontSize: 14,color: Colors.white),),
  155. alignment: Alignment.center,
  156. ),
  157. ],
  158. ),
  159. )
  160. ],
  161. );
  162. },
  163. ),
  164. );
  165. }
  166. }
  167. class YSWriteOffView extends StatefulWidget {
  168. final VoidCallback voidCallback;
  169. const YSWriteOffView({Key key, @required this.voidCallback}) : super(key: key);
  170. @override
  171. _YSWriteOffViewState createState() => _YSWriteOffViewState();
  172. }
  173. class _YSWriteOffViewState extends State<YSWriteOffView> {
  174. @override
  175. void initState() {
  176. Future.delayed(Duration(seconds: 1)).then((value) {
  177. Navigator.pop(context);
  178. widget.voidCallback();
  179. });
  180. super.initState();
  181. }
  182. @override
  183. Widget build(BuildContext context) {
  184. return Center(
  185. child: Container(
  186. height: 150,
  187. width: 150,
  188. decoration: BoxDecoration(
  189. color: Colors.pinkAccent,
  190. borderRadius: BorderRadius.all(Radius.circular(10))
  191. ),
  192. alignment: Alignment.center,
  193. child: Column(
  194. mainAxisSize: MainAxisSize.min,
  195. children: [
  196. Icon(Icons.check_circle,size: 50,color: Colors.white,),
  197. Padding(
  198. padding: EdgeInsets.only(top: 10),
  199. child: Text('已核销',style: TextStyle(fontSize: 15,color: Colors.white,decoration: TextDecoration.none),)
  200. )
  201. ],
  202. ),
  203. )
  204. );
  205. }
  206. }
  207. class YSCodeAlertView extends StatefulWidget {
  208. final List array;
  209. final Map item;
  210. final VoidCallback callback;
  211. const YSCodeAlertView({Key key, this.array, this.item, @required this.callback}) : super(key: key);
  212. @override
  213. _YSCodeAlertViewState createState() => _YSCodeAlertViewState();
  214. }
  215. class _YSCodeAlertViewState extends State<YSCodeAlertView> with SingleTickerProviderStateMixin{
  216. TabController _tabController;
  217. Timer _timer;
  218. @override
  219. void initState() {
  220. _tabController = TabController(
  221. vsync: this,
  222. length: widget.array.length,
  223. initialIndex: widget.array.indexOf(widget.item)
  224. );
  225. getTimer();
  226. super.initState();
  227. }
  228. @override
  229. void dispose() {
  230. if(_timer!=null){
  231. _timer.cancel();
  232. }
  233. super.dispose();
  234. }
  235. getTimer() {
  236. _timer =Timer.periodic(Duration(seconds: 3), (timer) async{
  237. Map dict = await ysRequestHttpNoLoading(context, requestType.post, 'transfer/coupon/checkTicketInformation', {'idcard':User().idCard,'couponId':widget.item['couponId']});
  238. if(dict!=null){
  239. bool isCheck = dict['data']??false;
  240. if(isCheck){
  241. ysShowCenterAlertView(context, YSWriteOffView(voidCallback: (){
  242. widget.callback();
  243. Navigator.pop(context);
  244. },),isTrans: true);
  245. // ysFlutterToast(context, '已核销');
  246. }
  247. }
  248. });
  249. }
  250. @override
  251. Widget build(BuildContext context) {
  252. return ClipRRect(
  253. borderRadius: BorderRadius.only(topRight: Radius.circular(20),topLeft: Radius.circular(20)),
  254. child: Container(
  255. height: 570,
  256. decoration: BoxDecoration(
  257. color: Color(0xFFF5F5F5),
  258. ),
  259. child: DefaultTabController(
  260. length: widget.array.length,
  261. child: false?Column(
  262. children: [
  263. Container(
  264. color: Color(0xFFFF6D96),
  265. height: 50,
  266. width: MediaQuery.of(context).size.width,
  267. child: Row(
  268. children: [
  269. Container(
  270. width: ysWidth(context)-40,
  271. padding: EdgeInsets.only(left: 20,right: 20),
  272. child: TabBar(
  273. controller: _tabController,
  274. indicatorColor: Color(0xFFFF6D96),
  275. isScrollable: true,
  276. labelColor: Colors.white,
  277. indicatorWeight: 3,
  278. indicatorSize: TabBarIndicatorSize.label,
  279. labelStyle: TextStyle(fontSize: 14),
  280. unselectedLabelColor: Colors.white60,
  281. tabs: widget.array.map((f) {//text: '· ${f['title']}'
  282. return Tab(
  283. child: Row(
  284. mainAxisSize: MainAxisSize.min,
  285. children: [
  286. Text(f['couponName'])
  287. ],
  288. ),
  289. );
  290. }).toList(),
  291. ),
  292. ),
  293. GestureDetector(
  294. onTap: (){Navigator.pop(context);},
  295. child: Image.asset('lib/images/clear_fy.png',height: 20,width: 20,),
  296. )
  297. ],
  298. ),
  299. ),
  300. SizedBox(
  301. height: 520,
  302. width: MediaQuery.of(context).size.width,
  303. child: TabBarView(
  304. controller: _tabController,
  305. children: widget.array.map((f) {
  306. return YSCodeAlertInfoView(item: f,);
  307. }).toList(),
  308. ),
  309. )
  310. ],
  311. ):Column(
  312. children: [
  313. Container(
  314. color: Color(0xFFFF6D96),
  315. height: 50,
  316. width: MediaQuery.of(context).size.width,
  317. child: Row(
  318. children: [
  319. Container(
  320. width: ysWidth(context)-40,
  321. padding: EdgeInsets.only(left: 20,right: 20),
  322. child: Text(widget.item['couponName'],style: TextStyle(fontSize: 14,color: Colors.white),),
  323. alignment: Alignment.center,
  324. ),
  325. GestureDetector(
  326. onTap: (){Navigator.pop(context);},
  327. child: Image.asset('lib/images/clear_fy.png',height: 20,width: 20,),
  328. )
  329. ],
  330. ),
  331. ),
  332. SizedBox(
  333. height: 520,
  334. width: MediaQuery.of(context).size.width,
  335. child: YSCodeAlertInfoView(item: widget.item,),
  336. )
  337. ],
  338. ),
  339. ),
  340. ),
  341. );
  342. }
  343. }
  344. class YSCodeAlertInfoView extends StatefulWidget {
  345. final Map item;
  346. const YSCodeAlertInfoView({Key key, this.item}) : super(key: key);
  347. @override
  348. _YSCodeAlertInfoViewState createState() => _YSCodeAlertInfoViewState();
  349. }
  350. class _YSCodeAlertInfoViewState extends State<YSCodeAlertInfoView> {
  351. String _codeStr = '';
  352. @override
  353. void initState() {
  354. Wakelock.enable();
  355. YSScreenChange().change(255);
  356. Future.delayed(Duration(seconds: 0)).then((value) {
  357. _getCodeData();
  358. });
  359. super.initState();
  360. }
  361. _getCodeData() async{
  362. Map dict = await ysRequestHttpNoLoading(context, requestType.post, 'transfer/coupon/getTicketCode', {'idcard':User().idCard,'couponId':widget.item['couponId']});
  363. if(dict!=null){
  364. _codeStr = dict['message'];
  365. setState(() {});
  366. }
  367. }
  368. @override
  369. void dispose() {
  370. YSScreenChange().change(100);
  371. Wakelock.disable();
  372. super.dispose();
  373. }
  374. @override
  375. Widget build(BuildContext context) {
  376. return Column(
  377. children: [
  378. GestureDetector(
  379. onTap: (){
  380. _getCodeData();
  381. },
  382. behavior: HitTestBehavior.opaque,
  383. child: Container(
  384. height: 200,
  385. width: 200,
  386. color: Colors.white,
  387. margin: EdgeInsets.only(top: 20),
  388. child: _codeStr.isNotEmpty?QrImage(data: _codeStr):SizedBox(),
  389. ),
  390. ),
  391. Container(
  392. height: 40,
  393. child: Text('$_codeStr',style: TextStyle(fontSize: 16,color: Colors.grey),),
  394. alignment: Alignment.center,
  395. ),
  396. ClipRRect(
  397. child: Container(
  398. height: 260,
  399. color: Colors.white,
  400. width: ysWidth(context),
  401. child: Stack(
  402. children: [
  403. // Transform.rotate(
  404. // angle: 2,
  405. // child: Container(
  406. // color: Colors.red,
  407. // ),
  408. // ),
  409. Column(
  410. children: List.generate(
  411. 4,(index) => Expanded(
  412. child: Row(
  413. children: List.generate(
  414. 4,(index) => Expanded(
  415. child: Center(
  416. child: Transform.rotate(
  417. angle: -0.8,
  418. child: Text(
  419. '${widget.item['hospitalName']}',
  420. style: TextStyle(
  421. color: Color(0xFFC8C9CC).withOpacity(0.5),
  422. fontSize: 14,
  423. decoration: TextDecoration.none,
  424. ),
  425. ),
  426. ),
  427. ),
  428. ),
  429. ),
  430. ),
  431. ),
  432. ),
  433. ),
  434. Container(
  435. alignment: Alignment.center,
  436. padding: EdgeInsets.only(left: 20,right: 20),
  437. child: Column(
  438. mainAxisSize: MainAxisSize.min,
  439. children: [
  440. Container(
  441. height: 35,
  442. child: Text(widget.item['couponName'],style: TextStyle(fontSize: 18,color: Color(0xFF444444)),maxLines: 1,),
  443. alignment: Alignment.center,
  444. ),
  445. Container(
  446. height: 30,
  447. child: Text('编号:${widget.item['couponCode']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  448. alignment: Alignment.center,
  449. ),
  450. Container(
  451. height: 30,
  452. child: Text('母亲姓名:${widget.item['pregnantWomanName']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  453. alignment: Alignment.center,
  454. ),
  455. Container(
  456. height: 30,
  457. child: Text('时间:${widget.item['applicableRange']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  458. alignment: Alignment.center,
  459. ),
  460. Container(
  461. height: 30,
  462. child: Text('发券机构:${widget.item['hospitalName']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  463. alignment: Alignment.center,
  464. ),
  465. Container(
  466. height: 30,
  467. child: Text('失效日期:${widget.item['applicableEntTime']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  468. alignment: Alignment.center,
  469. ),
  470. ],
  471. ),
  472. )
  473. ],
  474. ),
  475. ),
  476. )
  477. ],
  478. );
  479. }
  480. }
  481. // DottedBorder(
  482. // color: Color(0xFFFF6D96),
  483. // borderType: BorderType.RRect,
  484. // radius: Radius.circular(9),
  485. // strokeWidth: 1,
  486. // child: Container(
  487. // height: 185,
  488. // width: ysWidth(context)-40,
  489. // child: Column(
  490. // children: [
  491. // Container(
  492. // height: 35,
  493. // child: Text(widget.item['couponName'],style: TextStyle(fontSize: 18,color: Color(0xFF444444)),maxLines: 1,),
  494. // alignment: Alignment.centerLeft,
  495. // ),
  496. // Container(
  497. // height: 30,
  498. // child: Text('编号:${widget.item['couponCode']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  499. // alignment: Alignment.centerLeft,
  500. // ),
  501. // Container(
  502. // height: 30,
  503. // child: Text('母亲姓名:${widget.item['pregnantWomanName']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  504. // alignment: Alignment.centerLeft,
  505. // ),
  506. // Container(
  507. // height: 30,
  508. // child: Text('时间:${widget.item['applicableRange']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  509. // alignment: Alignment.centerLeft,
  510. // ),
  511. // Container(
  512. // height: 30,
  513. // child: Text('发券机构:${widget.item['hospitalName']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  514. // alignment: Alignment.centerLeft,
  515. // ),
  516. // Container(
  517. // height: 30,
  518. // child: Text('失效日期:${widget.item['applicableEntTime']}',style: TextStyle(fontSize: 14,color: Color(0xFF444444)),maxLines: 1,),
  519. // alignment: Alignment.centerLeft,
  520. // ),
  521. // ],
  522. // ),
  523. // padding: EdgeInsets.only(left: 50,right: 50),
  524. // ),
  525. // )
  526. class YSCouponCardNewView extends StatefulWidget {
  527. final Map item;
  528. final List array;
  529. const YSCouponCardNewView({Key key, @required this.item, this.array}) : super(key: key);
  530. @override
  531. _YSCouponCardNewViewState createState() => _YSCouponCardNewViewState();
  532. }
  533. class _YSCouponCardNewViewState extends State<YSCouponCardNewView> {
  534. int _type = 1;
  535. @override
  536. void initState() {
  537. _type = int.parse(widget.item['type']??'1');
  538. super.initState();
  539. }
  540. @override
  541. Widget build(BuildContext context) {
  542. return GestureDetector(
  543. onTap: (){
  544. // CustomerValueNotification({'item':widget.item,'array':widget.array}).dispatch(context);
  545. ysShowBottomAlertView(context, YSCodeAlertView(array: widget.array,item: widget.item,callback: (){
  546. CustomerNotification().dispatch(context);
  547. }),isBarr: true);
  548. },
  549. behavior: HitTestBehavior.opaque,
  550. child: Container(
  551. color: Colors.white,
  552. height: 150,
  553. child: LayoutBuilder(
  554. builder: (context,conSize){
  555. int typeId = widget.item['typeId']??1;
  556. return Stack(
  557. children: [
  558. Padding(
  559. padding: EdgeInsets.only(left: 80,top: 2),
  560. child: DottedBorder(
  561. color: _type==1?Color(0xFFFF6D96):Color(0xFF6EA0EF),
  562. borderType: BorderType.RRect,
  563. radius: Radius.circular(10),
  564. strokeWidth: 1,
  565. child: Container(
  566. width: conSize.maxWidth-80,
  567. height: 142,
  568. padding: EdgeInsets.only(left: 14),
  569. child: Container(
  570. child: Column(
  571. children: [
  572. Container(
  573. height: 41.5,
  574. padding: EdgeInsets.only(left: 5,right: 5),
  575. alignment: Alignment.center,
  576. child: Text(widget.item['couponName'],style: TextStyle(fontSize: 18,color: _type==1?Color(0xFFFF6D96):Color(0xFF6EA0EF)),maxLines: 1,),
  577. ),
  578. Padding(
  579. child: DashLine(color: Color(0xFF979797),height: 0.5,),
  580. padding: EdgeInsets.only(left: 13,right: 13)
  581. ),
  582. Container(
  583. height: 100,
  584. alignment: Alignment.center,
  585. padding: EdgeInsets.only(left: 50,right: 20),
  586. child: Column(
  587. mainAxisSize: MainAxisSize.min,
  588. children: [
  589. Container(
  590. height: 20,
  591. alignment: Alignment.centerLeft,
  592. child: Text('编号:${widget.item['couponCode']}',style: TextStyle(fontSize: 12,color: Color(0xFF444444)),maxLines: 1,),
  593. ),
  594. Container(
  595. margin: EdgeInsets.only(top: 5,bottom: 5),
  596. height: 20,
  597. alignment: Alignment.centerLeft,
  598. child: Text('时间:${widget.item['applicableRange']}',style: TextStyle(fontSize: 12,color: Color(0xFF444444)),maxLines: 1),
  599. ),
  600. Container(
  601. height: 20,
  602. alignment: Alignment.centerLeft,
  603. child: Text('失效日期:${widget.item['applicableEntTime']}',style: TextStyle(fontSize: 12,color: Color(0xFF444444)),maxLines: 1),
  604. )
  605. ],
  606. ),
  607. )
  608. ],
  609. ),
  610. ),
  611. ),
  612. ),
  613. ),
  614. Container(
  615. width: 94,
  616. decoration: BoxDecoration(
  617. image: DecorationImage(image: AssetImage('lib/images/${
  618. typeId==1?'编组 8备份m':typeId==2?'编组 8备份m(1)':typeId==3?'编组 8备份m(2)':typeId==4?'fy_coipon_2':typeId==5?'编组 8备份 2':'fy_coupon_1'
  619. }.png'))
  620. ),
  621. alignment: Alignment.center,
  622. child: Column(
  623. mainAxisSize: MainAxisSize.min,
  624. children: [
  625. // RichText(text: TextSpan(
  626. // text: '共',
  627. // style: TextStyle(fontSize: 14,color: Colors.white,fontWeight: FontWeight.bold),
  628. // children: [
  629. // TextSpan(
  630. // text: ' ${widget.item['count']} ',
  631. // style: TextStyle(fontSize: 24)
  632. // ),
  633. // TextSpan(
  634. // text: '张'
  635. // )
  636. // ]
  637. // )),
  638. Padding(
  639. padding: EdgeInsets.only(top: 10,bottom: 20),
  640. child: Image.asset('lib/images/${_type==1?'fy_mom':'fy_child'}.png',height: 25,width: 25,),
  641. ),
  642. Stack(
  643. children: [
  644. Image.asset('lib/images/${
  645. typeId==1?'编组 9m':typeId==2?'编组 9m(1)':typeId==3?'编组 9m(2)':typeId==4?'fy_hx_2':typeId==5?'编组 9备份':'fy_hx_1'
  646. }.png',height: 20,width: 56,),
  647. Container(
  648. padding: EdgeInsets.only(left: 15),
  649. height: 20,
  650. width: 56,
  651. child: Text('核销码',style: TextStyle(fontSize: 7,color: Colors.white),),
  652. alignment: Alignment.centerLeft,
  653. )
  654. ],
  655. )
  656. ],
  657. ),
  658. ),
  659. ],
  660. );
  661. },
  662. ),
  663. ),
  664. );
  665. }
  666. }