|
@@ -2,7 +2,9 @@ import 'package:flutter/cupertino.dart';
|
|
|
import 'package:flutter/material.dart';
|
|
|
import 'package:flutter/widgets.dart';
|
|
|
import 'package:taskservice/Common/JXColors.dart';
|
|
|
+import 'package:taskservice/Model/JXMemberModel.dart';
|
|
|
import 'package:taskservice/Model/JXServiceModel.dart';
|
|
|
+import 'package:taskservice/database/DataBase.dart';
|
|
|
|
|
|
class CreateAccPage extends StatefulWidget {
|
|
|
@override
|
|
@@ -11,7 +13,7 @@ class CreateAccPage extends StatefulWidget {
|
|
|
|
|
|
class _CreateAccPageState extends State<CreateAccPage> {
|
|
|
List<JXServiceModel> services;
|
|
|
-
|
|
|
+ JXMemberModel member;
|
|
|
@override
|
|
|
void initState() {
|
|
|
super.initState();
|
|
@@ -90,7 +92,7 @@ class _CreateAccPageState extends State<CreateAccPage> {
|
|
|
],
|
|
|
),
|
|
|
),
|
|
|
- Container(width: MediaQuery.of(context).size.width, child: Text('保存', textAlign: TextAlign.center, style: TextStyle(fontSize: 16, color: JXColors.kFFFFFF),), padding: EdgeInsets.symmetric(vertical: 16), decoration: BoxDecoration(color: JXColors.k101E40),),
|
|
|
+ GestureDetector(onTap: onClickSave, child: Container(width: MediaQuery.of(context).size.width, child: Text('保存', textAlign: TextAlign.center, style: TextStyle(fontSize: 16, color: JXColors.kFFFFFF),), padding: EdgeInsets.symmetric(vertical: 16), decoration: BoxDecoration(color: JXColors.k101E40),)),
|
|
|
],
|
|
|
),
|
|
|
));
|
|
@@ -286,4 +288,8 @@ class _CreateAccPageState extends State<CreateAccPage> {
|
|
|
]),
|
|
|
);
|
|
|
}
|
|
|
+
|
|
|
+ void onClickSave() {
|
|
|
+ MyDataBase.getInstance().saveMember(member);
|
|
|
+ }
|
|
|
}
|