no message

parent 094947c9
PODS:
- Flutter (1.0.0)
- path_provider_linux (0.0.1):
- Flutter
- shared_preferences (0.0.1):
- Flutter
- shared_preferences_linux (0.0.1):
- Flutter
- shared_preferences_macos (0.0.1):
- Flutter
- shared_preferences_web (0.0.1):
- Flutter
DEPENDENCIES:
- Flutter (from `Flutter`)
- path_provider_linux (from `.symlinks/plugins/path_provider_linux/ios`)
- shared_preferences (from `.symlinks/plugins/shared_preferences/ios`)
- shared_preferences_linux (from `.symlinks/plugins/shared_preferences_linux/ios`)
- shared_preferences_macos (from `.symlinks/plugins/shared_preferences_macos/ios`)
- shared_preferences_web (from `.symlinks/plugins/shared_preferences_web/ios`)
EXTERNAL SOURCES:
Flutter:
:path: Flutter
path_provider_linux:
:path: ".symlinks/plugins/path_provider_linux/ios"
shared_preferences:
:path: ".symlinks/plugins/shared_preferences/ios"
shared_preferences_linux:
:path: ".symlinks/plugins/shared_preferences_linux/ios"
shared_preferences_macos:
:path: ".symlinks/plugins/shared_preferences_macos/ios"
shared_preferences_web:
:path: ".symlinks/plugins/shared_preferences_web/ios"
SPEC CHECKSUMS:
Flutter: 0e3d915762c693b495b44d77113d4970485de6ec
path_provider_linux: 4d630dc393e1f20364f3e3b4a2ff41d9674a84e4
shared_preferences: af6bfa751691cdc24be3045c43ec037377ada40d
shared_preferences_linux: afefbfe8d921e207f01ede8b60373d9e3b566b78
shared_preferences_macos: f3f29b71ccbb56bf40c9dd6396c9acf15e214087
shared_preferences_web: 141cce0c3ed1a1c5bf2a0e44f52d31eeb66e5ea9
PODFILE CHECKSUM: 1b66dae606f75376c5f2135a8290850eeb09ae83
COCOAPODS: 1.9.1
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; }; 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; };
3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
3B8F2F30495DF54C475260F0 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 87BA19A8D364DD0686A7FEE2 /* Pods_Runner.framework */; };
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; }; 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; };
9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
...@@ -37,11 +38,14 @@ ...@@ -37,11 +38,14 @@
/* Begin PBXFileReference section */ /* Begin PBXFileReference section */
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; }; 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; };
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; }; 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; };
33024327C221F515472E9F1F /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; }; 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; };
3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = "<group>"; }; 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = "<group>"; };
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; }; 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; };
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; }; 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
79C89B9F733C7608F23FFD16 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; }; 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
87BA19A8D364DD0686A7FEE2 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; }; 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; };
9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; }; 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; };
9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = "<group>"; }; 9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = "<group>"; };
...@@ -50,6 +54,7 @@ ...@@ -50,6 +54,7 @@
97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; }; 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; }; 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
B9D8AD6C5731486189955743 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };
/* End PBXFileReference section */ /* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */ /* Begin PBXFrameworksBuildPhase section */
...@@ -59,12 +64,32 @@ ...@@ -59,12 +64,32 @@
files = ( files = (
9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */, 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */,
3B80C3941E831B6300D905FE /* App.framework in Frameworks */, 3B80C3941E831B6300D905FE /* App.framework in Frameworks */,
3B8F2F30495DF54C475260F0 /* Pods_Runner.framework in Frameworks */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
}; };
/* End PBXFrameworksBuildPhase section */ /* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */ /* Begin PBXGroup section */
4C22BE78BAD0C8381E524F68 /* Frameworks */ = {
isa = PBXGroup;
children = (
87BA19A8D364DD0686A7FEE2 /* Pods_Runner.framework */,
);
name = Frameworks;
sourceTree = "<group>";
};
714F2D453FFE3E51D15C603E /* Pods */ = {
isa = PBXGroup;
children = (
B9D8AD6C5731486189955743 /* Pods-Runner.debug.xcconfig */,
33024327C221F515472E9F1F /* Pods-Runner.release.xcconfig */,
79C89B9F733C7608F23FFD16 /* Pods-Runner.profile.xcconfig */,
);
name = Pods;
path = Pods;
sourceTree = "<group>";
};
9740EEB11CF90186004384FC /* Flutter */ = { 9740EEB11CF90186004384FC /* Flutter */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
...@@ -84,6 +109,8 @@ ...@@ -84,6 +109,8 @@
9740EEB11CF90186004384FC /* Flutter */, 9740EEB11CF90186004384FC /* Flutter */,
97C146F01CF9000F007C117D /* Runner */, 97C146F01CF9000F007C117D /* Runner */,
97C146EF1CF9000F007C117D /* Products */, 97C146EF1CF9000F007C117D /* Products */,
714F2D453FFE3E51D15C603E /* Pods */,
4C22BE78BAD0C8381E524F68 /* Frameworks */,
); );
sourceTree = "<group>"; sourceTree = "<group>";
}; };
...@@ -125,12 +152,14 @@ ...@@ -125,12 +152,14 @@
isa = PBXNativeTarget; isa = PBXNativeTarget;
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
buildPhases = ( buildPhases = (
F2D33FFAE85B58D994792568 /* [CP] Check Pods Manifest.lock */,
9740EEB61CF901F6004384FC /* Run Script */, 9740EEB61CF901F6004384FC /* Run Script */,
97C146EA1CF9000F007C117D /* Sources */, 97C146EA1CF9000F007C117D /* Sources */,
97C146EB1CF9000F007C117D /* Frameworks */, 97C146EB1CF9000F007C117D /* Frameworks */,
97C146EC1CF9000F007C117D /* Resources */, 97C146EC1CF9000F007C117D /* Resources */,
9705A1C41CF9048500538489 /* Embed Frameworks */, 9705A1C41CF9048500538489 /* Embed Frameworks */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */, 3B06AD1E1E4923F5004D2608 /* Thin Binary */,
FA4EFC6F822E3113A21F3DE1 /* [CP] Embed Pods Frameworks */,
); );
buildRules = ( buildRules = (
); );
...@@ -217,6 +246,43 @@ ...@@ -217,6 +246,43 @@
shellPath = /bin/sh; shellPath = /bin/sh;
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
}; };
F2D33FFAE85B58D994792568 /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputFileListPaths = (
);
inputPaths = (
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
"${PODS_ROOT}/Manifest.lock",
);
name = "[CP] Check Pods Manifest.lock";
outputFileListPaths = (
);
outputPaths = (
"$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
showEnvVarsInLog = 0;
};
FA4EFC6F822E3113A21F3DE1 /* [CP] Embed Pods Frameworks */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "[CP] Embed Pods Frameworks";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */ /* End PBXShellScriptBuildPhase section */
/* Begin PBXSourcesBuildPhase section */ /* Begin PBXSourcesBuildPhase section */
......
...@@ -4,4 +4,7 @@ ...@@ -4,4 +4,7 @@
<FileRef <FileRef
location = "group:Runner.xcodeproj"> location = "group:Runner.xcodeproj">
</FileRef> </FileRef>
<FileRef
location = "group:Pods/Pods.xcodeproj">
</FileRef>
</Workspace> </Workspace>
...@@ -9,6 +9,8 @@ import 'package:feelverapp/ui/splashscreen/splash_screen_page.dart'; ...@@ -9,6 +9,8 @@ import 'package:feelverapp/ui/splashscreen/splash_screen_page.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'ui/edit_profile/edit_profile.dart';
void main() => runApp(MyApp()); void main() => runApp(MyApp());
...@@ -23,7 +25,7 @@ class MyApp extends StatelessWidget { ...@@ -23,7 +25,7 @@ class MyApp extends StatelessWidget {
), ),
// home: SplashScreenPage(), // home: SplashScreenPage(),
home: HomePage(), home: EditProfile(),
); );
} }
......
class GetprofileModel {
List<Result> result;
List<Reward> reward;
GetprofileModel({this.result, this.reward});
GetprofileModel.fromJson(Map<String, dynamic> json) {
if (json['result'] != null) {
result = new List<Result>();
json['result'].forEach((v) {
result.add(new Result.fromJson(v));
});
}
if (json['reward'] != null) {
reward = new List<Reward>();
json['reward'].forEach((v) {
reward.add(new Reward.fromJson(v));
});
}
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
if (this.result != null) {
data['result'] = this.result.map((v) => v.toJson()).toList();
}
if (this.reward != null) {
data['reward'] = this.reward.map((v) => v.toJson()).toList();
}
return data;
}
}
class Result {
int id;
String prefix;
String name;
String lastname;
String displayName;
dynamic image;
String email;
int age;
String sex;
String phone;
String address;
String socialRegister;
dynamic socialType;
String status;
String approved;
dynamic createdAt;
dynamic updatedAt;
int userId;
User user;
Result(
{this.id,
this.prefix,
this.name,
this.lastname,
this.displayName,
this.image,
this.email,
this.age,
this.sex,
this.phone,
this.address,
this.socialRegister,
this.socialType,
this.status,
this.approved,
this.createdAt,
this.updatedAt,
this.userId,
this.user});
Result.fromJson(Map<String, dynamic> json) {
id = json['id'];
prefix = json['prefix'];
name = json['name'];
lastname = json['lastname'];
displayName = json['display_name'];
image = json['image'];
email = json['email'];
age = json['age'];
sex = json['sex'];
phone = json['phone'];
address = json['address'];
socialRegister = json['social_register'];
socialType = json['social_type'];
status = json['status'];
approved = json['approved'];
createdAt = json['created_at'];
updatedAt = json['updated_at'];
userId = json['user_id'];
user = json['user'] != null ? new User.fromJson(json['user']) : null;
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['prefix'] = this.prefix;
data['name'] = this.name;
data['lastname'] = this.lastname;
data['display_name'] = this.displayName;
data['image'] = this.image;
data['email'] = this.email;
data['age'] = this.age;
data['sex'] = this.sex;
data['phone'] = this.phone;
data['address'] = this.address;
data['social_register'] = this.socialRegister;
data['social_type'] = this.socialType;
data['status'] = this.status;
data['approved'] = this.approved;
data['created_at'] = this.createdAt;
data['updated_at'] = this.updatedAt;
data['user_id'] = this.userId;
if (this.user != null) {
data['user'] = this.user.toJson();
}
return data;
}
}
class User {
int id;
Null roleId;
String name;
String email;
String avatar;
Null emailVerifiedAt;
int status;
int fvRoleId;
Null settings;
Null createdAt;
String updatedAt;
User(
{this.id,
this.roleId,
this.name,
this.email,
this.avatar,
this.emailVerifiedAt,
this.status,
this.fvRoleId,
this.settings,
this.createdAt,
this.updatedAt});
User.fromJson(Map<String, dynamic> json) {
id = json['id'];
roleId = json['role_id'];
name = json['name'];
email = json['email'];
avatar = json['avatar'];
emailVerifiedAt = json['email_verified_at'];
status = json['status'];
fvRoleId = json['fv_role_id'];
settings = json['settings'];
createdAt = json['created_at'];
updatedAt = json['updated_at'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['role_id'] = this.roleId;
data['name'] = this.name;
data['email'] = this.email;
data['avatar'] = this.avatar;
data['email_verified_at'] = this.emailVerifiedAt;
data['status'] = this.status;
data['fv_role_id'] = this.fvRoleId;
data['settings'] = this.settings;
data['created_at'] = this.createdAt;
data['updated_at'] = this.updatedAt;
return data;
}
}
class Reward {
int id;
Null type;
int userId;
int allPoints;
Null pendingPoints;
Null usedPoint;
int remainPoint;
Null remarkPoint;
String status;
int storeId;
int vendorId;
String createdDate;
int createdBy;
String updatedDate;
int updatedBy;
Null createdAt;
String updatedAt;
List<History> history;
Reward(
{this.id,
this.type,
this.userId,
this.allPoints,
this.pendingPoints,
this.usedPoint,
this.remainPoint,
this.remarkPoint,
this.status,
this.storeId,
this.vendorId,
this.createdDate,
this.createdBy,
this.updatedDate,
this.updatedBy,
this.createdAt,
this.updatedAt,
this.history});
Reward.fromJson(Map<String, dynamic> json) {
id = json['id'];
type = json['type'];
userId = json['user_id'];
allPoints = json['all_points'];
pendingPoints = json['pending_points'];
usedPoint = json['used_point'];
remainPoint = json['remain_point'];
remarkPoint = json['remark_point'];
status = json['status'];
storeId = json['store_id'];
vendorId = json['vendor_id'];
createdDate = json['created_date'];
createdBy = json['created_by'];
updatedDate = json['updated_date'];
updatedBy = json['updated_by'];
createdAt = json['created_at'];
updatedAt = json['updated_at'];
if (json['history'] != null) {
history = new List<History>();
json['history'].forEach((v) {
history.add(new History.fromJson(v));
});
}
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['type'] = this.type;
data['user_id'] = this.userId;
data['all_points'] = this.allPoints;
data['pending_points'] = this.pendingPoints;
data['used_point'] = this.usedPoint;
data['remain_point'] = this.remainPoint;
data['remark_point'] = this.remarkPoint;
data['status'] = this.status;
data['store_id'] = this.storeId;
data['vendor_id'] = this.vendorId;
data['created_date'] = this.createdDate;
data['created_by'] = this.createdBy;
data['updated_date'] = this.updatedDate;
data['updated_by'] = this.updatedBy;
data['created_at'] = this.createdAt;
data['updated_at'] = this.updatedAt;
if (this.history != null) {
data['history'] = this.history.map((v) => v.toJson()).toList();
}
return data;
}
}
class History {
int id;
int rewardId;
String remarkLog;
String actionType;
String actionDate;
int pointAction;
String ip;
String createdDate;
int createdBy;
Null updatedDate;
Null updatedBy;
String createdAt;
String updatedAt;
History(
{this.id,
this.rewardId,
this.remarkLog,
this.actionType,
this.actionDate,
this.pointAction,
this.ip,
this.createdDate,
this.createdBy,
this.updatedDate,
this.updatedBy,
this.createdAt,
this.updatedAt});
History.fromJson(Map<String, dynamic> json) {
id = json['id'];
rewardId = json['reward_id'];
remarkLog = json['remark_log'];
actionType = json['action_type'];
actionDate = json['action_date'];
pointAction = json['point_action'];
ip = json['ip'];
createdDate = json['created_date'];
createdBy = json['created_by'];
updatedDate = json['updated_date'];
updatedBy = json['updated_by'];
createdAt = json['created_at'];
updatedAt = json['updated_at'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['reward_id'] = this.rewardId;
data['remark_log'] = this.remarkLog;
data['action_type'] = this.actionType;
data['action_date'] = this.actionDate;
data['point_action'] = this.pointAction;
data['ip'] = this.ip;
data['created_date'] = this.createdDate;
data['created_by'] = this.createdBy;
data['updated_date'] = this.updatedDate;
data['updated_by'] = this.updatedBy;
data['created_at'] = this.createdAt;
data['updated_at'] = this.updatedAt;
return data;
}
}
\ No newline at end of file
...@@ -3,6 +3,8 @@ import 'dart:convert'; ...@@ -3,6 +3,8 @@ import 'dart:convert';
import 'package:feelverapp/model/Login/login_model.dart'; import 'package:feelverapp/model/Login/login_model.dart';
import 'package:feelverapp/model/base/base.dart'; import 'package:feelverapp/model/base/base.dart';
import 'package:feelverapp/model/editprofile/getprofilemodel.dart';
import 'package:feelverapp/model/forgetpassword/forgetpassModel.dart'; import 'package:feelverapp/model/forgetpassword/forgetpassModel.dart';
import 'package:feelverapp/model/home/home_model.dart'; import 'package:feelverapp/model/home/home_model.dart';
...@@ -19,6 +21,25 @@ class Api<T> { ...@@ -19,6 +21,25 @@ class Api<T> {
"Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczpcL1wvYmFja2VuZC11YXQuZmVlbHZlci5jb21cL2FwaVwvbG9naW4iLCJpYXQiOjE1OTQ5NzIzMjYsImV4cCI6MTYwMjE3MjMyNiwibmJmIjoxNTk0OTcyMzI2LCJqdGkiOiJsM1BldUJVcTdDNldSbzVGIiwic3ViIjo1LCJwcnYiOiI4N2UwYWYxZWY5ZmQxNTgxMmZkZWM5NzE1M2ExNGUwYjA0NzU0NmFhIn0.fwFqcbzG2T_ZHtIcGF13Ek7nIxxwbnaE9ZXGomo-nzY", "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczpcL1wvYmFja2VuZC11YXQuZmVlbHZlci5jb21cL2FwaVwvbG9naW4iLCJpYXQiOjE1OTQ5NzIzMjYsImV4cCI6MTYwMjE3MjMyNiwibmJmIjoxNTk0OTcyMzI2LCJqdGkiOiJsM1BldUJVcTdDNldSbzVGIiwic3ViIjo1LCJwcnYiOiI4N2UwYWYxZWY5ZmQxNTgxMmZkZWM5NzE1M2ExNGUwYjA0NzU0NmFhIn0.fwFqcbzG2T_ZHtIcGF13Ek7nIxxwbnaE9ZXGomo-nzY",
}; };
Future<Response<T>> getprofile(Object body) async {
var _model;
var _fail;
var result;
// (body as Map)['lang'] = allTranslations.currentLanguage;
await _httpConnection(
"${this._baseApi}/customer/info", this._headerApi, body)
.then((response) {
print("ผลลัพ เท่ากับบบบ " + "${response.body}");
if (response.statusCode == 200) {
_model = GetprofileModel.fromJson(json.decode(response.body));
} else {
_fail = FailModel.fromJson(json.decode(response.body));
}
result = new Response<T>(_model, _fail);
});
return result;
}
Future<Response<T>> forgetPassword(Object body) async { Future<Response<T>> forgetPassword(Object body) async {
var _model; var _model;
var _fail; var _fail;
......
...@@ -19,18 +19,12 @@ class _ForgetPasswordState extends State<ForgetPassword> with TickerProviderStat ...@@ -19,18 +19,12 @@ class _ForgetPasswordState extends State<ForgetPassword> with TickerProviderStat
ForgetPasswordPresenter presenter; ForgetPasswordPresenter presenter;
@override @override
void initState() { void initState() {
// TODO: implement initState
super.initState(); super.initState();
presenter = ForgetPasswordPresenter(this); presenter = ForgetPasswordPresenter(this);
// presenter.letSignIn();
// _tabController = TabController(length: 2, vsync: this);
// _tabController.addListener(_handleTabSelection);
// registerBloc = RegisterBloc(this);
// loginBloc = LoginBloc(this);
}
void _handleTabSelection() {
setState(() {});
} }
@override @override
void dispose() { void dispose() {
super.dispose(); super.dispose();
......
import 'package:feelverapp/ui/edit_profile/editprofile_presenter.dart';
import 'package:feelverapp/util/SizeConfig.dart'; import 'package:feelverapp/util/SizeConfig.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import '../../util/SizeConfig.dart';
class EditProfile extends StatefulWidget { class EditProfile extends StatefulWidget {
@override @override
_EditProfileState createState() => _EditProfileState(); _EditProfileState createState() => _EditProfileState();
} }
class _EditProfileState extends State<EditProfile> { class _EditProfileState extends State<EditProfile> {
EditprofilePresenter presenter;
@override
void initState() {
super.initState();
presenter = EditprofilePresenter(this);
presenter.getprofile();
}
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
SizeConfig(context);
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
backgroundColor: Color.fromRGBO(106, 179, 170, 1), backgroundColor: Color.fromRGBO(106, 179, 170, 1),
...@@ -24,7 +42,16 @@ class _EditProfileState extends State<EditProfile> { ...@@ -24,7 +42,16 @@ class _EditProfileState extends State<EditProfile> {
fontWeight: FontWeight.w500), fontWeight: FontWeight.w500),
), ),
), ),
body: SingleChildScrollView( body:presenter.getmodel == null
? Container(
child: Center(
child: CircularProgressIndicator(
valueColor:
new AlwaysStoppedAnimation<Color>(Color.fromRGBO(106, 179, 170, 1),),
)
)):
SingleChildScrollView(
child: Column( child: Column(
children: <Widget>[ children: <Widget>[
Stack( Stack(
...@@ -54,7 +81,7 @@ class _EditProfileState extends State<EditProfile> { ...@@ -54,7 +81,7 @@ class _EditProfileState extends State<EditProfile> {
width: SizeConfig.getWidth(34), width: SizeConfig.getWidth(34),
height: SizeConfig.getWidth(34), height: SizeConfig.getWidth(34),
), ),
), )
], ],
), ),
Container( Container(
...@@ -63,7 +90,7 @@ class _EditProfileState extends State<EditProfile> { ...@@ -63,7 +90,7 @@ class _EditProfileState extends State<EditProfile> {
top: SizeConfig.getPadding(10), top: SizeConfig.getPadding(10),
), ),
child: Text( child: Text(
'Rattaya Pratumkan', "${presenter.getmodel.result[0].name} ${presenter.getmodel.result[0].lastname}",
style: TextStyle( style: TextStyle(
color: Color.fromRGBO(238, 175, 183, 1), color: Color.fromRGBO(238, 175, 183, 1),
fontSize: SizeConfig.getFontSize(24), fontSize: SizeConfig.getFontSize(24),
...@@ -79,11 +106,14 @@ class _EditProfileState extends State<EditProfile> { ...@@ -79,11 +106,14 @@ class _EditProfileState extends State<EditProfile> {
top: SizeConfig.getPadding(0), top: SizeConfig.getPadding(0),
), ),
child: TextFormField( child: TextFormField(
decoration: InputDecoration( decoration: InputDecoration(
focusedBorder: UnderlineInputBorder( focusedBorder: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.black45), borderSide: BorderSide(color: Colors.black45),
) , ) ,
labelText: 'ชื่อผู้ใช้งาน', labelText: 'ชื่อผู้ใช้งาน',
hintText: "${presenter.getmodel.result[0].name} ${presenter.getmodel.result[0].lastname}",
hintStyle: TextStyle(fontSize: 15.0, color: Colors.black),
labelStyle: TextStyle( labelStyle: TextStyle(
color: Colors.black87, color: Colors.black87,
fontSize: SizeConfig.getFontSize(16), fontSize: SizeConfig.getFontSize(16),
...@@ -223,7 +253,29 @@ class _EditProfileState extends State<EditProfile> { ...@@ -223,7 +253,29 @@ class _EditProfileState extends State<EditProfile> {
focusColor: Colors.red, focusColor: Colors.red,
), ),
), ),
),
SizedBox(height: 10,),
SizedBox(
width: 70.0,
height: 35.0,
child: FlatButton(
color: Color.fromRGBO(106, 179, 170, 1),
textColor: Colors.white,
disabledColor: Colors.grey,
disabledTextColor: Colors.black,
padding: EdgeInsets.all(0.0),
splashColor: Colors.blueAccent,
onPressed: () {
presenter.getprofile();
},
shape: new RoundedRectangleBorder(
borderRadius: new BorderRadius.circular(20.0)),
child: Text(
"ยืนยัน",
style: TextStyle(fontSize: 12.0),
), ),
))
], ],
), ),
), ),
......
import 'dart:async';
import 'dart:developer';
import 'package:feelverapp/model/Login/login_model.dart';
import 'package:feelverapp/model/editprofile/getprofilemodel.dart';
import 'package:feelverapp/model/forgetpassword/forgetpassModel.dart';
import 'package:feelverapp/service/Loading.dart';
import 'package:feelverapp/service/api.dart';
import 'package:feelverapp/service/base_presenter.dart';
import 'package:feelverapp/ui/ForgetPassword/forgetpassword.dart';
import 'package:feelverapp/ui/home/home.dart';
import 'package:feelverapp/ui/login/login.dart';
import 'package:feelverapp/util/Accout_util.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:rflutter_alert/rflutter_alert.dart';
import 'edit_profile.dart';
class EditprofilePresenter extends BasePresenter<EditProfile> {
Api _api;
final formKey = GlobalKey<FormState>();
TextEditingController emailCtrl = TextEditingController();
GetprofileModel getmodel;
EditprofilePresenter(State<EditProfile> state) : super(state);
letCheckData() async {
try {
if (emailCtrl.text.isEmpty ) throw ('กรุณากรอก\nอีเมล์');
Pattern pattern =
r"^[a-zA-Z0-9.a-zA-Z0-9.!#$%&'*+-/=?^_`{|}~]+@[a-zA-Z0-9]+\.[a-zA-Z]+";
RegExp regex = new RegExp(pattern);
if (!regex.hasMatch(emailCtrl.text))
throw ('รูปแบบอีเมล์\nไม่ถูกต้อง');
else {
await getprofile();
}
} catch (e) {
Alert(
style: AlertStyle(
animationType: AnimationType.fromTop,
isCloseButton: false,
),
context: state.context,
title: '$e',
content: Icon(Icons.warning,color: Colors.orange,size: 80,),
buttons: [
DialogButton(
color: Color.fromRGBO(106, 179, 170, 1),
onPressed: () => Navigator.pop(state.context),
child: Text(
"ตกลง",
style: TextStyle(color: Colors.white, fontSize: 20),
),
)
]).show();
}
}
getprofile() async {
_api = Api<GetprofileModel>();
var res = await _api.getprofile({
"id":"16"
});
if (res.fail == null) {
setState((){
getmodel = res.success;
});
} else {
Alert(
style: AlertStyle(
animationType: AnimationType.fromTop,
isCloseButton: false,
),
context: state.context,
title: "ไม่สามารถติดต่อ\nเซิร์ฟเวอร์ได้",
content: Icon(Icons.warning,color: Colors.orange,size: 80,),
buttons: [
DialogButton(
color: Color.fromRGBO(106, 179, 170, 1),
onPressed: () => Navigator.pop(state.context),
child: Text(
"ลองอีกครั้ง",
style: TextStyle(color: Colors.white, fontSize: 20),
),
)
]).show();
}
}
}
...@@ -7,42 +7,42 @@ packages: ...@@ -7,42 +7,42 @@ packages:
name: archive name: archive
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "2.0.13" version: "2.0.11"
args: args:
dependency: transitive dependency: transitive
description: description:
name: args name: args
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "1.6.0" version: "1.5.2"
async: async:
dependency: transitive dependency: transitive
description: description:
name: async name: async
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "2.4.1" version: "2.4.0"
boolean_selector: boolean_selector:
dependency: transitive dependency: transitive
description: description:
name: boolean_selector name: boolean_selector
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "2.0.0" version: "1.0.5"
charcode: charcode:
dependency: transitive dependency: transitive
description: description:
name: charcode name: charcode
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "1.1.3" version: "1.1.2"
collection: collection:
dependency: transitive dependency: transitive
description: description:
name: collection name: collection
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "1.14.12" version: "1.14.11"
convert: convert:
dependency: transitive dependency: transitive
description: description:
...@@ -56,7 +56,7 @@ packages: ...@@ -56,7 +56,7 @@ packages:
name: crypto name: crypto
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "2.1.4" version: "2.1.3"
cupertino_icons: cupertino_icons:
dependency: "direct main" dependency: "direct main"
description: description:
...@@ -113,7 +113,7 @@ packages: ...@@ -113,7 +113,7 @@ packages:
name: image name: image
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "2.1.12" version: "2.1.4"
intl: intl:
dependency: transitive dependency: transitive
description: description:
...@@ -204,7 +204,7 @@ packages: ...@@ -204,7 +204,7 @@ packages:
name: quiver name: quiver
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "2.1.3" version: "2.0.5"
rflutter_alert: rflutter_alert:
dependency: "direct main" dependency: "direct main"
description: description:
...@@ -258,7 +258,7 @@ packages: ...@@ -258,7 +258,7 @@ packages:
name: source_span name: source_span
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "1.7.0" version: "1.5.5"
stack_trace: stack_trace:
dependency: transitive dependency: transitive
description: description:
...@@ -293,7 +293,7 @@ packages: ...@@ -293,7 +293,7 @@ packages:
name: test_api name: test_api
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "0.2.15" version: "0.2.11"
typed_data: typed_data:
dependency: transitive dependency: transitive
description: description:
...@@ -321,7 +321,7 @@ packages: ...@@ -321,7 +321,7 @@ packages:
name: xml name: xml
url: "https://pub.dartlang.org" url: "https://pub.dartlang.org"
source: hosted source: hosted
version: "3.6.1" version: "3.5.0"
sdks: sdks:
dart: ">=2.6.0 <3.0.0" dart: ">=2.6.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5 <2.0.0" flutter: ">=1.12.13+hotfix.5 <2.0.0"
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