recommend_exit.dart 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377
  1. import 'package:flutter/material.dart';
  2. import 'package:liftmanager/res/gaps.dart';
  3. import 'package:liftmanager/net/api_service.dart';
  4. import 'package:liftmanager/utils/toast.dart';
  5. import 'package:liftmanager/widgets/app_bar.dart';
  6. import 'package:liftmanager/internal/search/search_router.dart';
  7. import 'package:liftmanager/widgets/app_search_bar.dart';
  8. import 'package:liftmanager/res/resources.dart';
  9. import 'package:liftmanager/routers/fluro_navigator.dart';
  10. import 'package:liftmanager/widgets/load_image.dart';
  11. import 'package:liftmanager/widgets/selected_image.dart';
  12. import 'package:image_picker/image_picker.dart';
  13. import 'dart:io';
  14. import 'package:flutter_screenutil/flutter_screenutil.dart';
  15. import 'package:liftmanager/internal/bbs/bbs_router.dart';
  16. class RecommendExit extends StatefulWidget {
  17. RecommendExit(this.id);
  18. final String id;
  19. @override
  20. State<StatefulWidget> createState() {
  21. return RecommendExitState();
  22. }
  23. }
  24. class RecommendExitState extends State<RecommendExit> {
  25. // NewsDetailItem item = NewsDetailItem();
  26. ScrollController _scrollController = new ScrollController();
  27. @override
  28. Widget build(BuildContext context) {
  29. double width = MediaQuery.of(context).size.width;
  30. return Scaffold(
  31. resizeToAvoidBottomPadding: false,//不让键盘弹上去
  32. appBar: MyAppBar(
  33. centerTitle: "出诊推荐",
  34. ),
  35. body:Stack(
  36. children:<Widget>[
  37. Container(
  38. padding: EdgeInsets.only(bottom:ScreenUtil().setWidth(70)),
  39. child: ListView(
  40. children: <Widget>[
  41. Column(
  42. crossAxisAlignment: CrossAxisAlignment.start,
  43. children: <Widget>[
  44. Container(
  45. padding: EdgeInsets.only(left:ScreenUtil().setWidth(15),right:ScreenUtil().setWidth(15),top:ScreenUtil().setWidth(10),bottom:ScreenUtil().setWidth(10)),
  46. decoration: BoxDecoration(
  47. border: Border(
  48. bottom: BorderSide(width: 0.5, color: Colours.line),
  49. ),
  50. ),
  51. child: Row(
  52. mainAxisAlignment: MainAxisAlignment.spaceBetween,
  53. children:<Widget>[
  54. Text(
  55. "提问人",
  56. style: TextStyle(
  57. color:Color(0xff333333),
  58. fontSize:ScreenUtil().setSp(17)
  59. ),
  60. textAlign:TextAlign.start,
  61. ),
  62. Row(
  63. children: <Widget>[
  64. Text(
  65. "小小维修工",
  66. style: TextStyle(
  67. color:Color(0xff666666),
  68. fontSize:ScreenUtil().setSp(15)
  69. ),
  70. textAlign:TextAlign.start,
  71. ),
  72. Container(
  73. margin: EdgeInsets.only(left:ScreenUtil().setWidth(10),right:ScreenUtil().setWidth(10),top:ScreenUtil().setWidth(5)),
  74. decoration: BoxDecoration(
  75. borderRadius: BorderRadius.circular(ScreenUtil().setWidth(25)),
  76. ),
  77. child: LoadAssetImage(
  78. // image: AssetImage(i['img']),
  79. "temporary/avator1",
  80. width: ScreenUtil().setWidth(37),
  81. height:ScreenUtil().setWidth(37),
  82. // alignment: Alignment.centerLeft,
  83. ),
  84. ),
  85. ],
  86. )
  87. ]
  88. ),
  89. ),
  90. Container(
  91. padding: EdgeInsets.only(left:ScreenUtil().setWidth(15),right:ScreenUtil().setWidth(15),top:ScreenUtil().setWidth(10),bottom:ScreenUtil().setWidth(10)),
  92. decoration: BoxDecoration(
  93. border: Border(
  94. bottom: BorderSide(width: 0.5, color: Colours.line),
  95. ),
  96. ),
  97. child: Row(
  98. mainAxisAlignment: MainAxisAlignment.spaceBetween,
  99. children:<Widget>[
  100. Text(
  101. "电梯品牌",
  102. style: TextStyle(
  103. color:Color(0xff333333),
  104. fontSize:ScreenUtil().setSp(17)
  105. ),
  106. textAlign:TextAlign.start,
  107. ),
  108. Text(
  109. "奥的斯",
  110. style: TextStyle(
  111. color:Color(0xff666666),
  112. fontSize:ScreenUtil().setSp(15)
  113. ),
  114. textAlign:TextAlign.start,
  115. ),
  116. ]
  117. ),
  118. ),
  119. Container(
  120. padding: EdgeInsets.only(left:ScreenUtil().setWidth(15),right:ScreenUtil().setWidth(15),top:ScreenUtil().setWidth(10),bottom:ScreenUtil().setWidth(10)),
  121. decoration: BoxDecoration(
  122. border: Border(
  123. bottom: BorderSide(width: 0.5, color: Colours.line),
  124. ),
  125. ),
  126. child: Row(
  127. mainAxisAlignment: MainAxisAlignment.spaceBetween,
  128. children:<Widget>[
  129. Text(
  130. "出诊时间",
  131. style: TextStyle(
  132. color:Color(0xff333333),
  133. fontSize:ScreenUtil().setSp(17)
  134. ),
  135. textAlign:TextAlign.start,
  136. ),
  137. Text(
  138. "2020-02-20 12:30",
  139. style: TextStyle(
  140. color:Color(0xff666666),
  141. fontSize:ScreenUtil().setSp(15)
  142. ),
  143. textAlign:TextAlign.start,
  144. ),
  145. ]
  146. ),
  147. ),
  148. Container(
  149. padding: EdgeInsets.only(left:ScreenUtil().setWidth(15),right:ScreenUtil().setWidth(15),top:ScreenUtil().setWidth(10),bottom:ScreenUtil().setWidth(10)),
  150. decoration: BoxDecoration(
  151. border: Border(
  152. bottom: BorderSide(width: 0.5, color: Colours.line),
  153. ),
  154. ),
  155. child: Row(
  156. mainAxisAlignment: MainAxisAlignment.spaceBetween,
  157. children:<Widget>[
  158. Text(
  159. "出诊地点",
  160. style: TextStyle(
  161. color:Color(0xff333333),
  162. fontSize:ScreenUtil().setSp(17)
  163. ),
  164. textAlign:TextAlign.start,
  165. ),
  166. Text(
  167. "创业大厦E座",
  168. style: TextStyle(
  169. color:Color(0xff666666),
  170. fontSize:ScreenUtil().setSp(15)
  171. ),
  172. textAlign:TextAlign.start,
  173. ),
  174. ]
  175. ),
  176. ),
  177. Column(
  178. crossAxisAlignment: CrossAxisAlignment.start,
  179. mainAxisAlignment: MainAxisAlignment.start,
  180. children: <Widget>[
  181. Container(
  182. padding:EdgeInsets.only(left:ScreenUtil().setWidth(15),top:ScreenUtil().setWidth(10),bottom:ScreenUtil().setWidth(5)),
  183. child: Text(
  184. "问题描述",
  185. style: TextStyle(
  186. color:Color(0xff333333),
  187. fontSize:ScreenUtil().setSp(17),
  188. ),
  189. textAlign:TextAlign.left,
  190. ),
  191. ),
  192. Container(
  193. padding: EdgeInsets.only(left:ScreenUtil().setWidth(15),right:ScreenUtil().setWidth(15),bottom:ScreenUtil().setWidth(50)),
  194. child: Text(
  195. "重启闸门,还是没有解决",
  196. style: TextStyle(
  197. color:Color(0xff666666),
  198. fontSize:ScreenUtil().setSp(15),
  199. ),
  200. textAlign:TextAlign.left,
  201. ),
  202. ),
  203. ],
  204. ),
  205. SizedBox(
  206. height:6,
  207. child: Container(
  208. color:Color(0xFFF8F8F8)
  209. ),
  210. ),
  211. Column(
  212. crossAxisAlignment: CrossAxisAlignment.start,
  213. mainAxisAlignment: MainAxisAlignment.start,
  214. children: <Widget>[
  215. Container(
  216. padding:EdgeInsets.only(left:ScreenUtil().setWidth(15),top:ScreenUtil().setWidth(10),bottom:ScreenUtil().setWidth(5)),
  217. child: Text(
  218. "已尝试方法",
  219. style: TextStyle(
  220. color:Color(0xff333333),
  221. fontSize:ScreenUtil().setSp(17),
  222. ),
  223. textAlign:TextAlign.left,
  224. ),
  225. ),
  226. Container(
  227. padding: EdgeInsets.only(left:ScreenUtil().setWidth(15),right:ScreenUtil().setWidth(15),bottom:ScreenUtil().setWidth(50)),
  228. child: Text(
  229. "重启闸门,还是没有解决",
  230. style: TextStyle(
  231. color:Color(0xff666666),
  232. fontSize:ScreenUtil().setSp(15),
  233. ),
  234. textAlign:TextAlign.left,
  235. ),
  236. ),
  237. ],
  238. ),
  239. SizedBox(
  240. height:6,
  241. child: Container(
  242. color:Color(0xFFF8F8F8)
  243. ),
  244. ),
  245. Container(
  246. padding: EdgeInsets.all(15),
  247. color: Colors.white,
  248. child: Wrap(
  249. spacing: 15,
  250. runSpacing : 15,
  251. children:<Widget>[
  252. LoadAssetImage(
  253. "temporary/product1",
  254. width: ScreenUtil().setWidth(70),
  255. height:ScreenUtil().setWidth(70),
  256. // alignment: Alignment.centerLeft,
  257. ),
  258. LoadAssetImage(
  259. "temporary/product1",
  260. width: ScreenUtil().setWidth(70),
  261. height:ScreenUtil().setWidth(70),
  262. // alignment: Alignment.centerLeft,
  263. ),
  264. LoadAssetImage(
  265. "temporary/product1",
  266. width: ScreenUtil().setWidth(70),
  267. height:ScreenUtil().setWidth(70),
  268. // alignment: Alignment.centerLeft,
  269. ),
  270. LoadAssetImage(
  271. "temporary/product1",
  272. width: ScreenUtil().setWidth(70),
  273. height:ScreenUtil().setWidth(70),
  274. // alignment: Alignment.centerLeft,
  275. ),
  276. LoadAssetImage(
  277. "temporary/product1",
  278. width: ScreenUtil().setWidth(70),
  279. height:ScreenUtil().setWidth(70),
  280. // alignment: Alignment.centerLeft,
  281. ),
  282. LoadAssetImage(
  283. "temporary/product1",
  284. width: ScreenUtil().setWidth(70),
  285. height:ScreenUtil().setWidth(70),
  286. // alignment: Alignment.centerLeft,
  287. ),
  288. LoadAssetImage(
  289. "temporary/product1",
  290. width: ScreenUtil().setWidth(70),
  291. height:ScreenUtil().setWidth(70),
  292. // alignment: Alignment.centerLeft,
  293. ),
  294. LoadAssetImage(
  295. "temporary/product1",
  296. width: ScreenUtil().setWidth(70),
  297. height:ScreenUtil().setWidth(70),
  298. // alignment: Alignment.centerLeft,
  299. ),
  300. ]
  301. )
  302. ),
  303. ],
  304. ),
  305. ]
  306. )
  307. ),
  308. Positioned(
  309. bottom:0,
  310. left:0,
  311. child:Container(
  312. width: width,
  313. child: Row(
  314. children:<Widget>[
  315. Container(
  316. height:ScreenUtil().setWidth(70),
  317. width:width/2,
  318. color: Colors.white,
  319. child: FlatButton(
  320. // padding: EdgeInsets.all(15.0),
  321. child: Text("拒绝",style: TextStyle(fontSize:ScreenUtil().setSp(16)),),
  322. textColor: Color(0xff222222),
  323. onPressed: () {
  324. // NavigatorUtils.push(context, BbsRouter.questionPay);
  325. },
  326. ),
  327. ),
  328. Container(
  329. height:ScreenUtil().setWidth(70),
  330. width:width/2,
  331. color: Color(0xff0388FD),
  332. child: FlatButton(
  333. // padding: EdgeInsets.all(15.0),
  334. child: Text("接单",style: TextStyle(fontSize:ScreenUtil().setSp(16)),),
  335. textColor: Colors.white,
  336. onPressed: () {
  337. // NavigatorUtils.push(context, BbsRouter.questionPay);
  338. },
  339. ),
  340. ),
  341. ]
  342. )
  343. )
  344. )
  345. ]
  346. )
  347. );
  348. }
  349. }