Commit 9d52fc12 authored by 何碧荣's avatar 何碧荣

update

parent f9e8e9f5
......@@ -35,9 +35,9 @@ buildDir = new File(rootProject.projectDir, "../build/host")
dependencies {
implementation project(':flutter')
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support.constraint:constraint-layout:1.1.2'
implementation 'com.android.support:design:27.1.1'
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'com.android.support:design:28.0.0'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
testImplementation 'junit:junit:4.12'
......
sdk.dir=/Users/apple/Library/Android/sdk
flutter.sdk=/Users/apple/Applications/flutter
flutter.buildMode=debug
flutter.versionName=1.0.0
flutter.versionCode=1
\ No newline at end of file
......@@ -555,9 +555,9 @@ class DioUtil {
// options.contentType = ContentType.parse('application/x-www-form-urlencoded');
options.contentType = ContentType.json;
options.responseType = ResponseType.plain;
// options.baseUrl = 'https://earth.iyanzhi.com/';
options.baseUrl = 'https://earth.iyanzhi.com/';
// options.baseUrl = 'http://earth.gmapp.env/';
options.baseUrl = "https://www.wanandroid.com/";
// options.baseUrl = "https://www.wanandroid.com/";
Map<String, dynamic> headers = Map<String, dynamic>();
headers['Accept'] = 'application/json';
headers['version'] = '1.0.0';
......
......@@ -68,7 +68,8 @@ class _MyAppState extends State<MyApp> {
if (findQuestionRouter == null) {
return null;
}
return findQuestionRouter.getQuestionPage();
findQuestionRouter.getAskPage("1");
return findQuestionRouter.getQuestionPage("1");
// var findUserRouter = RouterCenterImpl().findUserRouter();
// if(findUserRouter==null){
// return null;
......
......@@ -11,5 +11,8 @@ import 'package:gmalpha_flutter/questionModel/QuestionRouterImpl.dart';
@Router("questionModel",QuestionRouterImpl)
abstract class QuestionRouter implements RouterBaser{
Widget getQuestionPage();
Widget getQuestionPage(String id);
Widget getAskPage(String id );
}
\ No newline at end of file
......@@ -2,13 +2,19 @@
* @author lsy
* @date 2019-09-03
**/
import 'package:flutter/src/widgets/framework.dart';
import 'package:flutter/widgets.dart';
import 'package:gmalpha_flutter/questionModel/QuestionRouter.dart';
import 'package:gmalpha_flutter/questionModel/page/question/QuestionPage.dart';
import 'package:gmalpha_flutter/questionModel/page/questionPage/QuestionPage.dart';
class QuestionRouterImpl implements QuestionRouter {
@override
Widget getQuestionPage() {
return QuestionWidget();
Widget getQuestionPage(String id) {
return QuestionPage(id);
}
@override
Widget getAskPage(String id) {
return null;
}
}
/*
* @author hbr
* @date 2019-09-18
**/
import 'package:flutter/material.dart';
import 'package:gmalpha_flutter/questionModel/page/QuestionPageModel.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEntity.dart';
class QuestionPage extends StatefulWidget {
@override
State<StatefulWidget> createState() => QuestionState();
}
class QuestionState extends State<QuestionPage> {
QuestionPageModel _model;
@override
void initState() {
super.initState();
_model = new QuestionPageModel();
}
@override
void dispose() {
super.dispose();
_model.dispose();
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text(
"User",
style: TextStyle(fontSize: 16),
),
centerTitle: true,
),
body: Column(
children: <Widget>[
Container(
margin: EdgeInsets.fromLTRB(16, 10, 16, 20),
child: TextField(
cursorColor: Colors.black,
decoration: InputDecoration(
contentPadding: EdgeInsets.all(10.0),
icon: Icon(Icons.text_fields, color: Colors.black),
labelText: 'name1',
labelStyle: TextStyle(color: Colors.black)),
autofocus: false,
),
),
Container(
margin: EdgeInsets.fromLTRB(16, 0, 16, 20),
child: TextField(
cursorColor: Colors.black,
decoration: InputDecoration(
contentPadding: EdgeInsets.all(10.0),
icon: Icon(
Icons.text_fields,
color: Colors.black,
),
labelText: 'word2',
labelStyle: TextStyle(color: Colors.black)),
autofocus: false,
),
),
Container(
width: double.maxFinite,
margin: EdgeInsets.fromLTRB(16, 0, 16, 0),
child: OutlineButton(
onPressed: () => _model.logout(context),
child: Text("退出"),
shape: BeveledRectangleBorder(
borderRadius: BorderRadius.circular(3),
),
)),
],
),
);
}
}
/*
* @author lsy
* @date 2019-09-04
**/
import 'package:flutter/material.dart';
import 'package:gmalpha_flutter/commonModel/live/BaseModel.dart';
import 'package:gmalpha_flutter/commonModel/live/LiveData.dart';
import 'package:gmalpha_flutter/commonModel/toast/toast.dart';
import 'package:gmalpha_flutter/questionModel/service/QuestionRepository.dart';
import 'package:gmalpha_flutter/QuestionModel/service/remote/entity/QuestionEntity.dart';
class QuestionPageModel extends BaseModel {
LiveData<QuestionEntity> resignLive = new LiveData();
// LiveData<String> userTokenLive = new LiveData();
QuestionPageModel() {}
void logout(BuildContext context) {
QuestionRepository.getInstance().logout().listen((data) {
logoutLive.notifyView(data);
}).onError((error) {
Toast.show(context, "error ${error}");
print(error);
});
}
void resignUser(BuildContext context, String name, String word) {
QuestionRepository.getInstance().resignUser(name, word, word).listen((data) {
print("data !! :${data}");
resignLive.notifyView(data);
}).onError((error) {
Toast.show(context, "error :${error}");
print(error);
});
}
@override
void dispose() {
logoutLive.dispost();
resignLive.dispost();
}
}
//
import 'package:flutter/material.dart';
import 'package:gmalpha_flutter/questionModel/page/questionPage/QuestionPageModel.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEntity.dart';
///*
// * @author hbr
// * @date 2019-09-18
// **/
//
class QuestionPage extends StatefulWidget{
QuestionPageModel _model;
QuestionPage(String id){
_model=QuestionPageModel(id);
}
@override
State<StatefulWidget> createState() {
// TODO: implement createState
return QuestionPageState(_model);
}
}
class QuestionPageState extends State<QuestionPage>{
QuestionPageModel _model;
QuestionPageState(this._model);
@override
Widget build(BuildContext context) {
return Scaffold(
body: Container(
child: StreamBuilder<QuestionEntity>(
stream: _model.live.stream,
initialData: _model.live.data,
builder: (content,data){
print(data.data);
return Container(
child: Text("${data.data}"),
);
}),
),
);
}
@override
void initState() {
super.initState();
_model.init(context);
}
@override
void dispose() {
super.dispose();
_model.dispose();
}
}
//import 'package:flutter/material.dart';
//import 'package:gmalpha_flutter/questionModel/page/questionPage/QuestionPageModel.dart';
//
//class QuestionPage extends StatefulWidget {
// QuestionPageModel _model;
//
// QuestionPage(String id){
// _model=QuestionPageModel(id);
// }
//
// _QuestionPageState createState() => _QuestionPageState(_model);
//}
//
//class _QuestionPageState extends State<QuestionPage> {
// QuestionPageModel _model;
//
// _QuestionPageState(this._model);
//
// @override
// void initState() {
// super.initState();
// _model.init(context);
// }
//
// @override
// void dispose() {
// super.dispose();
// _model.dispose();
// }
// @override
// Widget build(BuildContext context) {
// return Scaffold(
// appBar: AppBar(
// title: Text(
// "User",
// style: TextStyle(fontSize: 16),
// ),
// centerTitle: true,
// ),
// body: Column(
// children: <Widget>[
//
// Container(
// margin: EdgeInsets.fromLTRB(16, 10, 16, 20),
// child: TextField(
// cursorColor: Colors.black,
// decoration: InputDecoration(
// contentPadding: EdgeInsets.all(10.0),
// icon: Icon(Icons.text_fields, color: Colors.black),
// labelText: 'name1',
// labelStyle: TextStyle(color: Colors.black)),
// autofocus: false,
// ),
// ),
// Container(
// margin: EdgeInsets.fromLTRB(16, 0, 16, 20),
// child: TextField(
// cursorColor: Colors.black,
// decoration: InputDecoration(
// contentPadding: EdgeInsets.all(10.0),
// icon: Icon(
// Icons.text_fields,
// color: Colors.black,
// ),
// labelText: 'word2',
// labelStyle: TextStyle(color: Colors.black)),
// autofocus: false,
// ),
// ),
//
// Container(
// width: double.maxFinite,
// margin: EdgeInsets.fromLTRB(16, 0, 16, 0),
// child: OutlineButton(
// onPressed: () => {},
// child: Text("退出"),
// shape: BeveledRectangleBorder(
// borderRadius: BorderRadius.circular(3),
// ),
// )),
//
// ],
// ),
// );
// }
//}
import 'package:flutter/src/widgets/framework.dart';
import 'package:gmalpha_flutter/commonModel/live/BaseModel.dart';
import 'package:gmalpha_flutter/commonModel/live/LiveData.dart';
import 'package:gmalpha_flutter/questionModel/service/QuestionRepository.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEntity.dart';
///*
// * @author lsy
// * @date 2019-09-04
// **/
//
//import 'package:flutter/material.dart';
//import 'package:gmalpha_flutter/commonModel/live/BaseModel.dart';
//import 'package:gmalpha_flutter/commonModel/live/LiveData.dart';
//import 'package:gmalpha_flutter/commonModel/toast/toast.dart';
//import 'package:gmalpha_flutter/questionModel/service/QuestionRepository.dart';
//import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEntity.dart';
//
class QuestionPageModel extends BaseModel {
LiveData<QuestionEntity> live = LiveData();
final String id;
QuestionPageModel(this.id);
@override
void dispose() {
live.dispost();
}
void init(BuildContext context) {
QuestionRepository.getInstance().getQuestion(id).listen((value) {
live.notifyView(value);
}).onError((error) {
print(error);
});
}
}
//
//class QuestionPageModel extends BaseModel {
// LiveData<QuestionEntity> questionLive = new LiveData();
//
// final String id;
// QuestionPageModel(this.id);
//
// init(BuildContext context) {
// QuestionRepository.getInstance()
// .getQuestion(id)
// .listen((value) {
// if (value != null) {
// questionLive.notifyView(value);
// }
// }).onError((error) {
// Toast.show(context, "${error.toString()}");
// print(error);
// });
// }
//
//
// @override
// void dispose() {
// questionLive.dispost();
// }
//}
/*
* @author lsy
* @date 2019-09-04
**/
import 'package:gmalpha_flutter/commonModel/net/Responce/SimpleResponce.dart';
import 'package:gmalpha_flutter/userModel/service/local/UserLocal.dart';
import 'package:gmalpha_flutter/userModel/service/remote/UserRemote.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/TestQuestionEntity.dart';
import 'package:gmalpha_flutter/questionModel/service/local/QuestionLocal.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/QuestionRemote.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/api/QuestionApi.serv.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEntity.dart';
import 'package:rxdart/rxdart.dart';
class QuestionRepository {
UserRemote _remote;
UserLocal _local;
static QuestionRepository _instance;
static QuestionRepository _questionRepository;
QuestionRemote _remote;
QuestionLocal _local;
QuestionRepository._() {
_remote = UserRemote.getInstance();
_local = UserLocal.getInstance();
_remote = QuestionRemote.getInstance();
_local = QuestionLocal.getInstance();
}
static QuestionRepository getInstance() {
if (_questionRepository == null) {
_questionRepository = QuestionRepository._();
if (_instance == null) {
_instance = QuestionRepository._();
}
return _questionRepository;
return _instance;
}
Observable<QuestionEntity> getUserInfo(String token) {
_remote.getUserInfo(token).map((value) {
if (value != null) {
_local.saveUserInfo(value);
}
return value;
});
}
Map<int,List<String>> restore={};
Observable<TestQuestionEntity> resignUser(
String name, String word, String reword) {
return _remote.resignUser(name, word, reword).map((value) {
Observable<QuestionEntity> getQuestion(String id) {
return _remote.getQuestion(id).map((value) {
if (value != null) {
_local.saveUser(value);
}
return value;
});
}
_local.saveQuestionResult(value);
Observable<SimpleResponce> logout() {
return _remote.logout().map((value) {
if (value != null) {
_local.logout();
}
return value;
});
......
/*
* @author lsy
* @date 2019-09-04
**/
import 'package:gmalpha_flutter/questionModel/service/remote/entity/TestQuestionEntity.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEntity.dart';
import 'package:rxdart/rxdart.dart';
class UserLocal {
static UserLocal _userRemote;
class QuestionLocal {
UserLocal._() {}
static QuestionLocal _instance;
static UserLocal getInstance() {
if (_userRemote == null) {
_userRemote = new UserLocal._();
}
return _userRemote;
}
QuestionLocal._(){
void saveUserInfo(QuestionEntity value) {
//TODO
}
void saveUser(TestQuestionEntity value) {
//TODO
static QuestionLocal getInstance(){
if(_instance==null){
_instance=QuestionLocal._();
}
return _instance;
}
void logout() {
//TODO
void saveQuestionResult(QuestionEntity entity){
}
}
\ No newline at end of file
/*
* @author lsy
* @date 2019-09-04
**/
import 'package:gmalpha_flutter/commonModel/net/Responce/SimpleResponce.dart';
import 'package:gmalpha_flutter/userModel/service/remote/api/UserLoginApi.serv.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/TestQuestionEntity.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEntity.dart';
import 'package:gmalpha_flutter/questionModel/service/remote/api/QuestionApi.serv.dart';
import 'package:rxdart/rxdart.dart';
import 'entity/QuestionEntity.dart';
class QuestionRemote {
static QuestionRemote _userRemote;
QuestionRemote._() {}
static QuestionRemote _instance;
static QuestionRemote getInstance() {
if (_userRemote == null) {
_userRemote = new QuestionRemote._();
}
return _userRemote;
}
Observable<QuestionEntity> getUserInfo(String token) {
// return UserLoginApiImpl().getUserInfo(token);
QuestionRemote._(){
}
Observable<TestQuestionEntity> resignUser(
String name, String word, String reWord) {
// return UserLoginApiImpl().resign(name, word, reWord);
static QuestionRemote getInstance(){
if(_instance==null){
_instance=new QuestionRemote._();
}
return _instance;
}
Observable<SimpleResponce> logout() {
return UserLoginApiImpl().logout();
Observable<QuestionEntity> getQuestion(String id){
return QuestionApiImpl().getQuestion(int.parse(id));
}
}
\ No newline at end of file
/*
* @author lsy
* @date 2019-09-04
**/
import 'package:gmalpha_flutter/Annotations/anno/Get.dart';
import 'package:gmalpha_flutter/Annotations/anno/Query.dart';
import 'package:gmalpha_flutter/Annotations/anno/ServiceCenter.dart';
......@@ -9,8 +5,6 @@ import 'package:gmalpha_flutter/questionModel/service/remote/entity/QuestionEnti
@ServiceCenter()
abstract class QuestionApi {
@Get("api/v1/survey_question/get")
QuestionEntity getUserInfo(@Query("templateId") String templateId);
@Get('api/v1/survey_question/get')
QuestionEntity getQuestion(@Query("id") int id);
}
......@@ -28,9 +28,10 @@ class QuestionApiImpl {
return _instance;
}
Observable<QuestionEntity> getUserInfo(String templateId) {
return Observable.fromFuture(DioUtil().get('api/v1/survey_question/get',
data: {'templateId': templateId})).map((value) {
Observable<QuestionEntity> getQuestion(int id) {
return Observable.fromFuture(
DioUtil().get('api/v1/survey_question/get', data: {'id': id}))
.map((value) {
if (value.statusCode == 200) {
Map map = json.decode(value.toString());
return QuestionEntity.fromJson(map);
......
import 'package:gmalpha_flutter/Annotations/anno/User.dart';
import 'package:gmalpha_flutter/Annotations/anno/UserCenter.dart';
import 'package:json_annotation/json_annotation.dart';
const String USER_ID = "user_uid";
const String NICKNAME = "username";
const String PORTRAIT = "potrait";
const String GENDER = "gender";
const String PERSONAL_QA = "personal_qa";
const String HAS_SCAN_FACE = "has_scan_face";
const String CURRENT_CITY_ID = "current_city_id";
const String QUESTION_URL = "question_url";
const String DETAIL_SETTED = "detail_setted";
const String BIRTHDAY = "birthday";
const String COUNTRY_ID = "country_id";
const String USER_BIND_MOBILE = "user_bind_mobile";
const String COUNTRY_LANGUAGE = "country_language";
const String COUNTRY_NAME = "country_name";
@UserCenter()
class QuestionEntity {
/**
* 用户id
*/
@User(USER_ID, "")
String userId;
/**
* 用户昵称
*/
@User(NICKNAME, "")
String nickName;
/**
* 用户头像
*/
@User(PORTRAIT,"")
String profilePic;
/**
* 是否需要答题
*/
@User(PERSONAL_QA,true)
bool hasAnswered = true;
/**
* 是否扫过脸
*/
@User(HAS_SCAN_FACE,true)
bool hasScanFace = false;
String id;
@User(GENDER,"")
String gender;
@User(CURRENT_CITY_ID,"")
String cityId;
@User(BIRTHDAY,0)
int birth;
@User(COUNTRY_ID,"")
String countryId;
bool logined;
// 用户是否设置过个人信息
@User(DETAIL_SETTED,true)
bool detailSetted = true;
//用户是否选择了标签
bool tagSetted = false;
//注册流程中断后返回之前的登录页面
@User(QUESTION_URL,"")
String questionUrl;
@User(USER_BIND_MOBILE,true)
bool isBind;
@User(COUNTRY_NAME,"")
String countryInfoName;
@User(COUNTRY_ID,"")
String countryInfoId;
@User(COUNTRY_LANGUAGE,"")
String countryInfoLanguage;
String insBindId;
String registerTime;
QuestionEntity(
{this.userId,
this.nickName,
this.profilePic,
this.hasAnswered,
this.hasScanFace,
this.id,
this.gender,
this.cityId,
this.birth,
this.countryId,
this.logined,
this.detailSetted,
this.tagSetted,
this.questionUrl,
this.isBind,
this.countryInfoName,
this.countryInfoId,
this.countryInfoLanguage,
this.insBindId,
this.registerTime});
int error;
String message;
Null extra;
Data data;
QuestionEntity({this.error, this.message, this.extra, this.data});
QuestionEntity.fromJson(Map<String, dynamic> json) {
userId = json['user_id'];
nickName = json['nick_name'];
profilePic = json['profile_pic'];
hasAnswered = json['has_answered'];
hasScanFace = json['has_scan_face'];
error = json['error'];
message = json['message'];
extra = json['extra'];
data = json['data'] != null ? new Data.fromJson(json['data']) : null;
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['error'] = this.error;
data['message'] = this.message;
data['extra'] = this.extra;
if (this.data != null) {
data['data'] = this.data.toJson();
}
return data;
}
}
class Data {
int id;
String name;
List<Questions> questions;
Data({this.id, this.name, this.questions});
Data.fromJson(Map<String, dynamic> json) {
id = json['id'];
name = json['name'];
if (json['questions'] != null) {
questions = new List<Questions>();
json['questions'].forEach((v) {
questions.add(new Questions.fromJson(v));
});
}
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['name'] = this.name;
if (this.questions != null) {
data['questions'] = this.questions.map((v) => v.toJson()).toList();
}
return data;
}
}
class Questions {
int id;
String content;
String image;
String questionType;
int relatedId1;
List<Answers> answers;
Questions(
{this.id,
this.content,
this.image,
this.questionType,
this.relatedId1,
this.answers});
Questions.fromJson(Map<String, dynamic> json) {
id = json['id'];
content = json['content'];
image = json['image'];
questionType = json['question_type'];
relatedId1 = json['related_id_1'];
if (json['answers'] != null) {
answers = new List<Answers>();
json['answers'].forEach((v) {
answers.add(new Answers.fromJson(v));
});
}
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['content'] = this.content;
data['image'] = this.image;
data['question_type'] = this.questionType;
data['related_id_1'] = this.relatedId1;
if (this.answers != null) {
data['answers'] = this.answers.map((v) => v.toJson()).toList();
}
return data;
}
}
class Answers {
int id;
String content;
String image;
List<HotTags> hotTags;
List<ExpertTags> expertTags;
int experience;
int relatedId1;
int relatedId2;
Answers(
{this.id,
this.content,
this.image,
this.hotTags,
this.expertTags,
this.experience,
this.relatedId1,
this.relatedId2});
Answers.fromJson(Map<String, dynamic> json) {
id = json['id'];
content = json['content'];
image = json['image'];
if (json['hot_tags'] != null) {
hotTags = new List<HotTags>();
json['hot_tags'].forEach((v) {
hotTags.add(new HotTags.fromJson(v));
});
}
if (json['expert_tags'] != null) {
expertTags = new List<ExpertTags>();
json['expert_tags'].forEach((v) {
expertTags.add(new ExpertTags.fromJson(v));
});
}
experience = json['experience'];
relatedId1 = json['related_id_1'];
relatedId2 = json['related_id_2'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['content'] = this.content;
data['image'] = this.image;
if (this.hotTags != null) {
data['hot_tags'] = this.hotTags.map((v) => v.toJson()).toList();
}
if (this.expertTags != null) {
data['expert_tags'] = this.expertTags.map((v) => v.toJson()).toList();
}
data['experience'] = this.experience;
data['related_id_1'] = this.relatedId1;
data['related_id_2'] = this.relatedId2;
return data;
}
}
class HotTags {
int id;
String name;
HotTags({this.id, this.name});
HotTags.fromJson(Map<String, dynamic> json) {
id = json['id'];
gender = json['gender'];
cityId = json['city_id'];
birth = json['birth'];
countryId = json['country_id'];
logined = json['logined'];
detailSetted = json['detail_setted'];
tagSetted = json['tag_setted'];
questionUrl = json['question_url'];
isBind = json['is_bind'];
countryInfoName = json['country_info_name'];
countryInfoId = json['country_info_id'];
countryInfoLanguage = json['country_info_language'];
insBindId = json['ins_bind_id'];
registerTime = json['register_time'];
name = json['name'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['user_id'] = this.userId;
data['nick_name'] = this.nickName;
data['profile_pic'] = this.profilePic;
data['has_answered'] = this.hasAnswered;
data['has_scan_face'] = this.hasScanFace;
data['id'] = this.id;
data['gender'] = this.gender;
data['city_id'] = this.cityId;
data['birth'] = this.birth;
data['country_id'] = this.countryId;
data['logined'] = this.logined;
data['detail_setted'] = this.detailSetted;
data['tag_setted'] = this.tagSetted;
data['question_url'] = this.questionUrl;
data['is_bind'] = this.isBind;
data['country_info_name'] = this.countryInfoName;
data['country_info_id'] = this.countryInfoId;
data['country_info_language'] = this.countryInfoLanguage;
data['ins_bind_id'] = this.insBindId;
data['register_time'] = this.registerTime;
data['name'] = this.name;
return data;
}
}
class ExpertTags {
int id;
String name;
ExpertTags({this.id, this.name});
ExpertTags.fromJson(Map<String, dynamic> json) {
id = json['id'];
name = json['name'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['name'] = this.name;
return data;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment