add contact
This commit is contained in:
29
lib/fcs/common/domain/entities/faq.dart
Normal file
29
lib/fcs/common/domain/entities/faq.dart
Normal file
@@ -0,0 +1,29 @@
|
||||
class FAQ {
|
||||
String id;
|
||||
String questionEng;
|
||||
String questionMm;
|
||||
String answerEng;
|
||||
String answerMm;
|
||||
|
||||
String question(bool isEng) => isEng?questionEng:questionMm;
|
||||
String answer(bool isEng) => isEng?answerEng:answerMm;
|
||||
|
||||
Map<String, String> images;
|
||||
FAQ({this.id,this.questionEng,this.questionMm,this.answerEng,this.answerMm,this.images});
|
||||
|
||||
|
||||
Map<String, dynamic> toMap() {
|
||||
return {
|
||||
'question_eng': questionEng,
|
||||
'answer_eng': answerEng,
|
||||
'question_mm': questionMm,
|
||||
'answer_mm': answerMm,
|
||||
'images': images,
|
||||
};
|
||||
}
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'FAQ{id: $id, questionEng: $questionEng,questionMm:$questionMm}';
|
||||
}
|
||||
}
|
||||
45
lib/fcs/common/domain/vo/contact.dart
Normal file
45
lib/fcs/common/domain/vo/contact.dart
Normal file
@@ -0,0 +1,45 @@
|
||||
import 'package:fcs/fcs/common/domain/entities/setting.dart';
|
||||
|
||||
class Contact {
|
||||
String usaAddress;
|
||||
String mmAddress;
|
||||
String usaContactNumber;
|
||||
String mmContactNumber;
|
||||
String emailAddress;
|
||||
String facebookLink;
|
||||
|
||||
Contact({
|
||||
this.usaAddress,
|
||||
this.mmAddress,
|
||||
this.usaContactNumber,
|
||||
this.mmContactNumber,
|
||||
this.emailAddress,
|
||||
this.facebookLink,
|
||||
});
|
||||
|
||||
factory Contact.fromSetting(Setting setting) {
|
||||
return Contact(
|
||||
usaContactNumber: setting.usaContactNumber,
|
||||
mmContactNumber: setting.mmContactNumber,
|
||||
usaAddress: setting.usaAddress,
|
||||
mmAddress: setting.mmAddress,
|
||||
emailAddress: setting.emailAddress,
|
||||
facebookLink: setting.facebookLink);
|
||||
}
|
||||
|
||||
Map<String, dynamic> toMap() {
|
||||
return {
|
||||
'usa_address': usaAddress,
|
||||
'mm_address': mmAddress,
|
||||
'usa_contact_number': usaContactNumber,
|
||||
'mm_contact_number': mmContactNumber,
|
||||
'email_address': emailAddress,
|
||||
'facebook_link': facebookLink,
|
||||
};
|
||||
}
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'Contact{usa_address:$usaAddress,mm_address:$mmAddress}';
|
||||
}
|
||||
}
|
||||
25
lib/fcs/common/domain/vo/term.dart
Normal file
25
lib/fcs/common/domain/vo/term.dart
Normal file
@@ -0,0 +1,25 @@
|
||||
import 'package:fcs/fcs/common/domain/entities/setting.dart';
|
||||
|
||||
class Term {
|
||||
String term;
|
||||
|
||||
Term({
|
||||
this.term,
|
||||
});
|
||||
|
||||
factory Term.fromSetting(Setting setting) {
|
||||
return Term(
|
||||
term: setting.terms,);
|
||||
}
|
||||
|
||||
Map<String, dynamic> toMap() {
|
||||
return {
|
||||
'terms': term,
|
||||
};
|
||||
}
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'Contact{terms:$term}';
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user