Selaa lähdekoodia

设备列表页

yangyang 2 vuotta sitten
vanhempi
commit
ed1ded211f

+ 25 - 28
lib/common/style/TitleBar.dart

@@ -1,4 +1,3 @@
-import 'package:deus_app/common/style/gsy_style.dart';
 import 'package:flutter/material.dart';
 
 /**
@@ -12,7 +11,6 @@ import 'package:flutter/material.dart';
  */
 
 class TitleBar {
-
   /**
    * 仅含 左侧返回按钮 及中间标题
    * appBar: TitleBar().backAppbar(context, '个人资料'),
@@ -20,17 +18,17 @@ class TitleBar {
    */
   backAppbar(BuildContext context, String title) {
     return AppBar(
-          title: Text(
-            title,
-            style: TextStyle(color: Colors.white, fontSize: 16),
-          ),
-          centerTitle: true,
-          leading: BackButton(),
-          brightness: Brightness.light,
-          backgroundColor: Color(0xFF4875EC),
-          elevation: 0,
-          iconTheme: IconThemeData(color: Colors.white),
-        );
+      title: Text(
+        title,
+        style: TextStyle(color: Colors.white, fontSize: 16),
+      ),
+      centerTitle: true,
+      leading: BackButton(),
+      brightness: Brightness.light,
+      backgroundColor: Color(0xFF4875EC),
+      elevation: 0,
+      iconTheme: IconThemeData(color: Colors.white),
+    );
   }
 
   /**
@@ -66,37 +64,36 @@ class TitleBar {
     );
   }
 
-
-  homeAppBar(String title, VoidCallback rightButtonClick) {
+  drawAppBar(String title, VoidCallback rightButtonClick) {
     return AppBar(
       centerTitle: true,
       titleSpacing: 0,
       elevation: 0,
       backgroundColor: Color(0xFF4875EC),
+      leading: BackButton(),
       // 返回按钮
       title: Text(
         title,
-        style: TextStyle(fontSize: 17),
+        style: TextStyle(fontSize: 16),
       ),
       automaticallyImplyLeading: false,
       // 标题
-        actions: <Widget>[
-          new IconButton( // action button
-            padding: EdgeInsets.only(right: 20),
-            icon: new Icon(Icons.settings),
-            onPressed: rightButtonClick,
-          ),
-        ],
+      actions: <Widget>[
+
+        new IconButton(
+          // action button
+          padding: EdgeInsets.only(right: 20),
+          icon: new Icon(Icons.drive_file_rename_outline),
+          onPressed: rightButtonClick,
+        ),
+      ],
     );
   }
 
-
-
   /**
    * 关闭页面
    */
-  _popThis(BuildContext context){
+  _popThis(BuildContext context) {
     Navigator.of(context).pop();
   }
-
-}
+}

+ 7 - 1
lib/common/style/gsy_style.dart

@@ -51,7 +51,7 @@ class GSYConstant {
       "https://github.com/CarGuo/gsy_github_app_flutter";
 
   static const lagerTextSize = 30.0;
-  static const bigTextSize = 23.0;
+  static const bigTextSize = 20.0;
   static const normalTextSize = 18.0;
   static const middleTextWhiteSize = 16.0;
   static const smallTextSize = 14.0;
@@ -174,6 +174,12 @@ class GSYConstant {
     fontSize: normalTextSize,
   );
 
+  static const normalTextBigWhiteBold = TextStyle(
+    color: GSYColors.actionBlue,
+    fontSize: bigTextSize,
+    fontWeight: FontWeight.bold,
+  );
+
   static const largeText = TextStyle(
     color: GSYColors.mainTextColor,
     fontSize: bigTextSize,

+ 2 - 0
lib/common/utils/ConstantString.dart

@@ -16,4 +16,6 @@ class ConstantString {
   static const String mainText = "首页";
 
   static const String loginNull = "请输入用户名和密码";
+
+  static const String deviceNum="设备总数:";
 }

+ 43 - 1
lib/generated/json/base/json_convert_content.dart

@@ -3,8 +3,10 @@
 // ignore_for_file: prefer_single_quotes
 
 import 'package:deus_app/generated/json/login_response_entity_helper.dart';
+import 'package:deus_app/generated/json/patrol_job_detail_response_entity_helper.dart';
 import 'package:deus_app/generated/json/user_response_entity_helper.dart';
 import 'package:deus_app/model/login_response_entity.dart';
+import 'package:deus_app/model/patrol_job_detail_response_entity.dart';
 // This file is automatically generated. DO NOT EDIT, all your changes would be lost.
 import 'package:deus_app/model/user_response_entity.dart';
 
@@ -32,7 +34,15 @@ class JsonConvert<T> {
 			case LoginResponseData:
 				return loginResponseDataFromJson(data as LoginResponseData, json) as T;
 			case LoginResponseDataUser:
-				return loginResponseDataUserFromJson(data as LoginResponseDataUser, json) as T;    }
+				return loginResponseDataUserFromJson(data as LoginResponseDataUser, json) as T;
+			case PatrolJobDetailResponseEntity:
+				return patrolJobDetailResponseEntityFromJson(data as PatrolJobDetailResponseEntity, json) as T;
+			case PatrolJobDetailResponseData:
+				return patrolJobDetailResponseDataFromJson(data as PatrolJobDetailResponseData, json) as T;
+			case PatrolJobDetailResponseDataList:
+				return patrolJobDetailResponseDataListFromJson(data as PatrolJobDetailResponseDataList, json) as T;
+			case PatrolJobDetailResponseDataListDeviceList:
+				return patrolJobDetailResponseDataListDeviceListFromJson(data as PatrolJobDetailResponseDataListDeviceList, json) as T;    }
 		return data as T;
 	}
 
@@ -52,6 +62,14 @@ class JsonConvert<T> {
 				return loginResponseDataToJson(data as LoginResponseData);
 			case LoginResponseDataUser:
 				return loginResponseDataUserToJson(data as LoginResponseDataUser);
+			case PatrolJobDetailResponseEntity:
+				return patrolJobDetailResponseEntityToJson(data as PatrolJobDetailResponseEntity);
+			case PatrolJobDetailResponseData:
+				return patrolJobDetailResponseDataToJson(data as PatrolJobDetailResponseData);
+			case PatrolJobDetailResponseDataList:
+				return patrolJobDetailResponseDataListToJson(data as PatrolJobDetailResponseDataList);
+			case PatrolJobDetailResponseDataListDeviceList:
+				return patrolJobDetailResponseDataListDeviceListToJson(data as PatrolJobDetailResponseDataListDeviceList);
 			}
 			return data as T;
 		}
@@ -79,6 +97,18 @@ class JsonConvert<T> {
 		if(type == (LoginResponseDataUser).toString()){
 			return LoginResponseDataUser().fromJson(json);
 		}
+		if(type == (PatrolJobDetailResponseEntity).toString()){
+			return PatrolJobDetailResponseEntity().fromJson(json);
+		}
+		if(type == (PatrolJobDetailResponseData).toString()){
+			return PatrolJobDetailResponseData().fromJson(json);
+		}
+		if(type == (PatrolJobDetailResponseDataList).toString()){
+			return PatrolJobDetailResponseDataList().fromJson(json);
+		}
+		if(type == (PatrolJobDetailResponseDataListDeviceList).toString()){
+			return PatrolJobDetailResponseDataListDeviceList().fromJson(json);
+		}
 
 		return null;
 	}
@@ -106,6 +136,18 @@ class JsonConvert<T> {
 		if(<LoginResponseDataUser>[] is M){
 			return data.map<LoginResponseDataUser>((e) => LoginResponseDataUser().fromJson(e)).toList() as M;
 		}
+		if(<PatrolJobDetailResponseEntity>[] is M){
+			return data.map<PatrolJobDetailResponseEntity>((e) => PatrolJobDetailResponseEntity().fromJson(e)).toList() as M;
+		}
+		if(<PatrolJobDetailResponseData>[] is M){
+			return data.map<PatrolJobDetailResponseData>((e) => PatrolJobDetailResponseData().fromJson(e)).toList() as M;
+		}
+		if(<PatrolJobDetailResponseDataList>[] is M){
+			return data.map<PatrolJobDetailResponseDataList>((e) => PatrolJobDetailResponseDataList().fromJson(e)).toList() as M;
+		}
+		if(<PatrolJobDetailResponseDataListDeviceList>[] is M){
+			return data.map<PatrolJobDetailResponseDataListDeviceList>((e) => PatrolJobDetailResponseDataListDeviceList().fromJson(e)).toList() as M;
+		}
 
 		throw Exception("not found");
 	}

+ 213 - 0
lib/generated/json/patrol_job_detail_response_entity_helper.dart

@@ -0,0 +1,213 @@
+import 'package:deus_app/model/patrol_job_detail_response_entity.dart';
+
+patrolJobDetailResponseEntityFromJson(PatrolJobDetailResponseEntity data, Map<String, dynamic> json) {
+	if (json['code'] != null) {
+		data.code = json['code'] is String
+				? int.tryParse(json['code'])
+				: json['code'].toInt();
+	}
+	if (json['data'] != null) {
+		data.data = PatrolJobDetailResponseData().fromJson(json['data']);
+	}
+	if (json['msg'] != null) {
+		data.msg = json['msg'].toString();
+	}
+	return data;
+}
+
+Map<String, dynamic> patrolJobDetailResponseEntityToJson(PatrolJobDetailResponseEntity entity) {
+	final Map<String, dynamic> data = new Map<String, dynamic>();
+	data['code'] = entity.code;
+	data['data'] = entity.data.toJson();
+	data['msg'] = entity.msg;
+	return data;
+}
+
+patrolJobDetailResponseDataFromJson(PatrolJobDetailResponseData data, Map<String, dynamic> json) {
+	if (json['id'] != null) {
+		data.id = json['id'] is String
+				? int.tryParse(json['id'])
+				: json['id'].toInt();
+	}
+	if (json['name'] != null) {
+		data.name = json['name'].toString();
+	}
+	if (json['number'] != null) {
+		data.number = json['number'].toString();
+	}
+	if (json['planName'] != null) {
+		data.planName = json['planName'].toString();
+	}
+	if (json['planNumber'] != null) {
+		data.planNumber = json['planNumber'].toString();
+	}
+	if (json['termType'] != null) {
+		data.termType = json['termType'] is String
+				? int.tryParse(json['termType'])
+				: json['termType'].toInt();
+	}
+	if (json['personnelId'] != null) {
+		data.personnelId = json['personnelId'] is String
+				? int.tryParse(json['personnelId'])
+				: json['personnelId'].toInt();
+	}
+	if (json['personnel'] != null) {
+		data.personnel = json['personnel'].toString();
+	}
+	if (json['remarks'] != null) {
+		data.remarks = json['remarks'].toString();
+	}
+	if (json['finishTime'] != null) {
+		data.finishTime = json['finishTime'].toString();
+	}
+	if (json['fileUrls'] != null) {
+		data.fileUrls = (json['fileUrls'] as List).map((v) => v).toList().cast<dynamic>();
+	}
+	if (json['startDate'] != null) {
+		data.startDate = json['startDate'].toString();
+	}
+	if (json['endDate'] != null) {
+		data.endDate = json['endDate'].toString();
+	}
+	if (json['status'] != null) {
+		data.status = json['status'] is String
+				? int.tryParse(json['status'])
+				: json['status'].toInt();
+	}
+	if (json['closeReason'] != null) {
+		data.closeReason = json['closeReason'];
+	}
+	if (json['customerName'] != null) {
+		data.customerName = json['customerName'];
+	}
+	if (json['channelName'] != null) {
+		data.channelName = json['channelName'];
+	}
+	if (json['closeUser'] != null) {
+		data.closeUser = json['closeUser'];
+	}
+	if (json['closeUserName'] != null) {
+		data.closeUserName = json['closeUserName'];
+	}
+	if (json['closeTime'] != null) {
+		data.closeTime = json['closeTime'];
+	}
+	if (json['createTime'] != null) {
+		data.createTime = json['createTime'].toString();
+	}
+	if (json['creator'] != null) {
+		data.creator = json['creator'] is String
+				? int.tryParse(json['creator'])
+				: json['creator'].toInt();
+	}
+	if (json['creatorName'] != null) {
+		data.creatorName = json['creatorName'].toString();
+	}
+	if (json['list'] != null) {
+		data.xList = (json['list'] as List).map((v) => PatrolJobDetailResponseDataList().fromJson(v)).toList();
+	}
+	return data;
+}
+
+Map<String, dynamic> patrolJobDetailResponseDataToJson(PatrolJobDetailResponseData entity) {
+	final Map<String, dynamic> data = new Map<String, dynamic>();
+	data['id'] = entity.id;
+	data['name'] = entity.name;
+	data['number'] = entity.number;
+	data['planName'] = entity.planName;
+	data['planNumber'] = entity.planNumber;
+	data['termType'] = entity.termType;
+	data['personnelId'] = entity.personnelId;
+	data['personnel'] = entity.personnel;
+	data['remarks'] = entity.remarks;
+	data['finishTime'] = entity.finishTime;
+	data['fileUrls'] = entity.fileUrls;
+	data['startDate'] = entity.startDate;
+	data['endDate'] = entity.endDate;
+	data['status'] = entity.status;
+	data['closeReason'] = entity.closeReason;
+	data['customerName'] = entity.customerName;
+	data['channelName'] = entity.channelName;
+	data['closeUser'] = entity.closeUser;
+	data['closeUserName'] = entity.closeUserName;
+	data['closeTime'] = entity.closeTime;
+	data['createTime'] = entity.createTime;
+	data['creator'] = entity.creator;
+	data['creatorName'] = entity.creatorName;
+	data['list'] =  entity.xList.map((v) => v.toJson()).toList();
+	return data;
+}
+
+patrolJobDetailResponseDataListFromJson(PatrolJobDetailResponseDataList data, Map<String, dynamic> json) {
+	if (json['productName'] != null) {
+		data.productName = json['productName'].toString();
+	}
+	if (json['deviceList'] != null) {
+		data.deviceList = (json['deviceList'] as List).map((v) => PatrolJobDetailResponseDataListDeviceList().fromJson(v)).toList();
+	}
+	return data;
+}
+
+Map<String, dynamic> patrolJobDetailResponseDataListToJson(PatrolJobDetailResponseDataList entity) {
+	final Map<String, dynamic> data = new Map<String, dynamic>();
+	data['productName'] = entity.productName;
+	data['deviceList'] =  entity.deviceList.map((v) => v.toJson()).toList();
+	return data;
+}
+
+patrolJobDetailResponseDataListDeviceListFromJson(PatrolJobDetailResponseDataListDeviceList data, Map<String, dynamic> json) {
+	if (json['id'] != null) {
+		data.id = json['id'] is String
+				? int.tryParse(json['id'])
+				: json['id'].toInt();
+	}
+	if (json['equipmentId'] != null) {
+		data.equipmentId = json['equipmentId'] is String
+				? int.tryParse(json['equipmentId'])
+				: json['equipmentId'].toInt();
+	}
+	if (json['name'] != null) {
+		data.name = json['name'].toString();
+	}
+	if (json['showName'] != null) {
+		data.showName = json['showName'].toString();
+	}
+	if (json['deviceKey'] != null) {
+		data.deviceKey = json['deviceKey'].toString();
+	}
+	if (json['productName'] != null) {
+		data.productName = json['productName'].toString();
+	}
+	if (json['itemCompleteTime'] != null) {
+		data.itemCompleteTime = json['itemCompleteTime'].toString();
+	}
+	if (json['itemPerson'] != null) {
+		data.itemPerson = json['itemPerson'].toString();
+	}
+	if (json['patrolJobId'] != null) {
+		data.patrolJobId = json['patrolJobId'] is String
+				? int.tryParse(json['patrolJobId'])
+				: json['patrolJobId'].toInt();
+	}
+	if (json['isComplete'] != null) {
+		data.isComplete = json['isComplete'] is String
+				? int.tryParse(json['isComplete'])
+				: json['isComplete'].toInt();
+	}
+	return data;
+}
+
+Map<String, dynamic> patrolJobDetailResponseDataListDeviceListToJson(PatrolJobDetailResponseDataListDeviceList entity) {
+	final Map<String, dynamic> data = new Map<String, dynamic>();
+	data['id'] = entity.id;
+	data['equipmentId'] = entity.equipmentId;
+	data['name'] = entity.name;
+	data['showName'] = entity.showName;
+	data['deviceKey'] = entity.deviceKey;
+	data['productName'] = entity.productName;
+	data['itemCompleteTime'] = entity.itemCompleteTime;
+	data['itemPerson'] = entity.itemPerson;
+	data['patrolJobId'] = entity.patrolJobId;
+	data['isComplete'] = entity.isComplete;
+	return data;
+}

+ 54 - 0
lib/model/patrol_job_detail_response_entity.dart

@@ -0,0 +1,54 @@
+import 'package:deus_app/generated/json/base/json_convert_content.dart';
+import 'package:deus_app/generated/json/base/json_field.dart';
+
+class PatrolJobDetailResponseEntity with JsonConvert<PatrolJobDetailResponseEntity> {
+	late int code;
+	late PatrolJobDetailResponseData data;
+	late String msg;
+}
+
+class PatrolJobDetailResponseData with JsonConvert<PatrolJobDetailResponseData> {
+	late int id;
+	late String name;
+	late String number;
+	late String planName;
+	late String planNumber;
+	late int termType;
+	late int personnelId;
+	late String personnel;
+	late String remarks;
+	late String finishTime;
+	late List<dynamic> fileUrls;
+	late String startDate;
+	late String endDate;
+	late int status;
+	late dynamic closeReason;
+	late dynamic customerName;
+	late dynamic channelName;
+	late dynamic closeUser;
+	late dynamic closeUserName;
+	late dynamic closeTime;
+	late String createTime;
+	late int creator;
+	late String creatorName;
+	@JSONField(name: "list")
+	late List<PatrolJobDetailResponseDataList> xList;
+}
+
+class PatrolJobDetailResponseDataList with JsonConvert<PatrolJobDetailResponseDataList> {
+	late String productName;
+	late List<PatrolJobDetailResponseDataListDeviceList> deviceList;
+}
+
+class PatrolJobDetailResponseDataListDeviceList with JsonConvert<PatrolJobDetailResponseDataListDeviceList> {
+	late int id;
+	late int equipmentId;
+	late String name;
+	late String showName;
+	late String deviceKey;
+	late String productName;
+	late String itemCompleteTime;
+	late String itemPerson;
+	late int patrolJobId;
+	late int isComplete;
+}

+ 141 - 7
lib/page/device/device_manage_page.dart

@@ -1,9 +1,10 @@
 import 'package:deus_app/common/style/TitleBar.dart';
+import 'package:deus_app/common/style/gsy_style.dart';
 import 'package:deus_app/common/utils/ConstantString.dart';
+import 'package:deus_app/widget/MyDrawer.dart';
 import 'package:flutter/material.dart';
 
 class DeviceManagePage extends StatefulWidget {
-
   static var routeName = '/DeviceManagePage';
 
   const DeviceManagePage({super.key});
@@ -14,14 +15,147 @@ class DeviceManagePage extends StatefulWidget {
   }
 }
 
-
-
 class _DeviceManage extends State<DeviceManagePage> {
+  String deviceNum = "0";
+  final GlobalKey<ScaffoldState> _scaffoldKey = GlobalKey<ScaffoldState>();
+
   @override
-  Widget build(BuildContext context) {
+  Widget build(BuildContext contexts) {
     return Scaffold(
-      appBar: TitleBar().backAppbar(context, ConstantString.deviceManageText),
-
+      key: _scaffoldKey,
+      appBar: TitleBar().drawAppBar(ConstantString.deviceManageText, () {
+            _scaffoldKey.currentState?.openEndDrawer();
+      }),
+      backgroundColor: const Color(0xfff2f2f2),
+      endDrawer: MyDrawer(), //抽屉
+      body: Column(
+        children: [
+          SizedBox(
+            height: 10,
+          ),
+          Row(
+            mainAxisAlignment:MainAxisAlignment.start,
+            children: [
+              SizedBox(
+                width: 15,
+              ),
+              Text(ConstantString.deviceNum,
+                  style: GSYConstant.smallActionLightText),
+              Text(deviceNum, style: GSYConstant.normalTextBigWhiteBold),
+            ],
+          ),
+          Expanded(
+              child: Container(
+            child: ListView.builder(
+              itemCount: 20,
+              itemBuilder: (context, index) {
+                return Container(
+                    margin: EdgeInsets.only(top: 12, left: 10, right: 10),
+                    padding: EdgeInsets.only(top: 12, bottom: 10),
+                    color: Colors.white,
+                    child: ListTile(
+                      title: Column(
+                        children: [
+                          Row(
+                              mainAxisAlignment: MainAxisAlignment.spaceBetween,
+                              children: [
+                                Container(
+                                  child: Text(
+                                    '此处展示设备名称',
+                                    style: TextStyle(
+                                      color: Colors.black,
+                                      fontSize: GSYConstant.middleTextWhiteSize,
+                                      fontWeight: FontWeight.bold,
+                                    ),
+                                  ),
+                                ),
+                                Container(
+                                  padding: EdgeInsets.only(
+                                      top: 3, bottom: 3, left: 5, right: 5),
+                                  child: Text(
+                                    '运行中',
+                                    textAlign: TextAlign.right,
+                                    style: TextStyle(
+                                      color: Colors.blue,
+                                      fontSize: GSYConstant.minTextSize,
+                                    ),
+                                  ),
+                                  decoration: BoxDecoration(
+                                    border: new Border.all(
+                                      color: Colors.blue, //边框颜色
+                                      width: 1.0, //边框粗细
+                                    ),
+                                    borderRadius: const BorderRadius.all(
+                                        const Radius.circular(3.0)), //边框的弧度
+                                  ),
+                                )
+                              ]),
+                          SizedBox(
+                            height: 12,
+                          ),
+                          Row(
+                              mainAxisAlignment: MainAxisAlignment.spaceBetween,
+                              children: [
+                                Container(
+                                  child: Text(
+                                    'devicekey:',
+                                    style: TextStyle(
+                                      color: GSYColors.primaryLightValue,
+                                      fontSize: GSYConstant.middleTextWhiteSize,
+                                    ),
+                                  ),
+                                ),
+                                Container(
+                                  child: Text(
+                                    'devicekey',
+                                    textAlign: TextAlign.right,
+                                    style: TextStyle(
+                                      color: GSYColors.primaryLightValue,
+                                      fontSize: GSYConstant.middleTextWhiteSize,
+                                    ),
+                                  ),
+                                ),
+                              ]),
+                          SizedBox(
+                            height: 10,
+                          ),
+                          Row(
+                              mainAxisAlignment: MainAxisAlignment.spaceBetween,
+                              children: [
+                                Container(
+                                  child: Text(
+                                    'IMEI:',
+                                    style: TextStyle(
+                                      color: GSYColors.primaryLightValue,
+                                      fontSize: GSYConstant.middleTextWhiteSize,
+                                    ),
+                                  ),
+                                ),
+                                Container(
+                                  child: Text(
+                                    'IMEI',
+                                    textAlign: TextAlign.right,
+                                    style: TextStyle(
+                                      color: GSYColors.primaryLightValue,
+                                      fontSize: GSYConstant.middleTextWhiteSize,
+                                    ),
+                                  ),
+                                ),
+                              ]),
+                          SizedBox(
+                            height: 5,
+                          ),
+                        ],
+                      ),
+                      onTap: () {
+                        Scaffold.of(context).openEndDrawer();
+                      },
+                    ));
+              },
+            ),
+          ))
+        ],
+      ),
     );
   }
-}
+}

+ 150 - 0
lib/widget/MyDrawer.dart

@@ -0,0 +1,150 @@
+import 'package:deus_app/common/style/gsy_style.dart';
+import 'package:flutter/material.dart';
+
+class MyDrawer extends StatelessWidget {
+  // const MyDrawer({
+  //   Key? key,
+  // }) : super(key: key);
+
+  @override
+  Widget build(BuildContext context) {
+    return Drawer(
+      child: MediaQuery.removePadding(
+        context: context,
+        //移除抽屉菜单顶部默认留白
+        removeTop: true,
+        child: Column(
+          crossAxisAlignment: CrossAxisAlignment.start,
+          children: <Widget>[
+            Padding(
+              padding: const EdgeInsets.only(top: 38.0,left: 10,right: 10),
+              child: Row(children: [
+                Expanded(
+                  flex: 1,
+                  child: Text(
+                    '设备名称',
+                    style: TextStyle(
+                      color: Colors.black,
+                      fontSize: GSYConstant.minTextSize,
+                      fontWeight: FontWeight.bold,
+                    ),
+                  ),
+                ),
+                Expanded(
+                  child: Container(
+                    height: 40,
+                    child: TextField(
+                      decoration: InputDecoration(
+                        border: OutlineInputBorder(),
+                      ),style: TextStyle(fontSize: 14),
+                      onChanged: (value) {
+                        _device = value;
+                      },
+                    ),
+                  ),
+                  flex: 4,
+
+                ),
+              ]),
+            ),
+            Padding(
+              padding: const EdgeInsets.only(top: 38.0,left: 10,right: 10),
+              child: Row(children: [
+                Expanded(
+                  flex: 1,
+                  child: Text(
+                    '展示名称',
+                    style: TextStyle(
+                      color: Colors.black,
+                      fontSize: GSYConstant.minTextSize,
+                      fontWeight: FontWeight.bold,
+                    ),
+                  ),
+                ),
+                Expanded(
+                    child: Container(
+                      height: 40,
+                      child: TextField(
+                        decoration: InputDecoration(
+                            border: OutlineInputBorder()
+                        ),style: TextStyle(fontSize: 14),
+                        onChanged: (value) {
+                          _username = value;
+                        },
+                      ),
+                    ),
+                  flex: 4,
+
+                ),
+              ]),
+            ),
+            Padding(
+              padding: const EdgeInsets.only(top: 38.0,left: 10,right: 10),
+              child: Row(children: [
+                Expanded(
+                  flex: 1,
+                  child: Text(
+                    'devicekey',
+                    style: TextStyle(
+                      color: Colors.black,
+                      fontSize: GSYConstant.minTextSize,
+                      fontWeight: FontWeight.bold,
+                    ),
+                  ),
+                ),
+                Expanded(
+                  child: Container(
+                    height: 40,
+                    child: TextField(
+                      decoration: InputDecoration(
+                          border: OutlineInputBorder()
+                      ),style: TextStyle(fontSize: 14),
+                      onChanged: (value) {
+                        _deviceKey = value;
+                      },
+                    ),
+                  ),
+                  flex: 4,
+                ),
+              ]),
+            ),
+            Padding(
+              padding: const EdgeInsets.only(top: 38.0,left: 10,right: 10),
+              child: Row(children: [
+                Expanded(
+                  flex: 1,
+                  child: Text(
+                    '产品名称',
+                    style: TextStyle(
+                      color: Colors.black,
+                      fontSize: GSYConstant.minTextSize,
+                      fontWeight: FontWeight.bold,
+                    ),
+                  ),
+                ),
+                Expanded(
+                  flex: 4,
+                  child: Container(
+                    height: 40,
+                    child: TextField(
+                      decoration: InputDecoration(
+                          border: OutlineInputBorder()
+                      ),style: TextStyle(fontSize: 14),
+                      onChanged: (value) {
+                        _product = value;
+                      },
+                    ),
+                  ),
+                ),
+              ]),
+            ),
+
+          ],
+        ),
+      ),
+    );
+  }
+
+  String  _device = '',_username = '', _deviceKey = '', _product = '';
+
+}