leave_message.dart 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. import 'package:flutter/material.dart';
  2. import 'package:jmrh/constant/styles.dart';
  3. class LeaveMessage extends StatefulWidget {
  4. LeaveMessage({Key key}) : super(key: key);
  5. @override
  6. _LeaveMessageState createState() => _LeaveMessageState();
  7. }
  8. class _LeaveMessageState extends State<LeaveMessage> {
  9. @override
  10. Widget build(BuildContext context) {
  11. return Scaffold(
  12. appBar: appBarLight('对接留言'),
  13. body: GestureDetector(
  14. child: SingleChildScrollView(
  15. child: Column(
  16. crossAxisAlignment: CrossAxisAlignment.stretch,
  17. children: [
  18. Container(
  19. height: 68,
  20. padding: EdgeInsets.symmetric(horizontal: 16),
  21. child: Row(
  22. children: [
  23. Text('单位名称'),
  24. Expanded(
  25. child: Text(
  26. '走马信息技术有限公司',
  27. textAlign: TextAlign.end,
  28. ),
  29. )
  30. ],
  31. ),
  32. ),
  33. Divider(height: 1, indent: 16, endIndent: 16, color: COLOR_BORDER),
  34. Container(
  35. height: 68,
  36. padding: EdgeInsets.symmetric(horizontal: 16),
  37. child: Row(
  38. children: [
  39. Text('单位名称'),
  40. Expanded(
  41. child: TextField(
  42. textAlign: TextAlign.end,
  43. style: TextStyle(fontSize: 14),
  44. decoration: InputDecoration.collapsed(hintText: '请输入您的姓名'),
  45. ),
  46. )
  47. ],
  48. ),
  49. ),
  50. Divider(height: 1, indent: 16, endIndent: 16, color: COLOR_BORDER),
  51. Container(
  52. height: 68,
  53. padding: EdgeInsets.symmetric(horizontal: 16),
  54. child: Row(
  55. children: [
  56. Text('联系方式'),
  57. Expanded(
  58. child: TextField(
  59. textAlign: TextAlign.end,
  60. style: TextStyle(fontSize: 14),
  61. decoration: InputDecoration.collapsed(hintText: '请输入您的联系方式'),
  62. ),
  63. )
  64. ],
  65. ),
  66. ),
  67. Divider(height: 1, indent: 16, endIndent: 16, color: COLOR_BORDER),
  68. Container(
  69. height: 68,
  70. padding: EdgeInsets.symmetric(horizontal: 16),
  71. alignment: AlignmentDirectional.centerStart,
  72. child: Text('对接描述'),
  73. ),
  74. Container(
  75. height: 130,
  76. margin: EdgeInsets.symmetric(horizontal: 16),
  77. padding: EdgeInsets.all(16),
  78. decoration: BoxDecoration(color: COLOR_BORDER),
  79. child: TextField(
  80. style: TextStyle(fontSize: 14),
  81. keyboardType: TextInputType.multiline,
  82. maxLines: null,
  83. decoration: InputDecoration.collapsed(hintText: '请填写对接描述,不超过200字'),
  84. maxLength: 300,
  85. ),
  86. ),
  87. Container(
  88. height: 44,
  89. margin: EdgeInsets.symmetric(horizontal: 16, vertical: 30),
  90. child: FlatButton(
  91. textColor: Colors.white,
  92. shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(0.0)),
  93. color: COLOR_PRIMARY,
  94. child: Text(
  95. '保存',
  96. style: TextStyle(fontSize: 16, fontWeight: FontWeight.bold),
  97. ),
  98. onPressed: () {},
  99. ),
  100. ),
  101. ],
  102. ),
  103. ),
  104. onTap: () {
  105. FocusScope.of(context).requestFocus(FocusNode());
  106. },
  107. ));
  108. }
  109. }