Merge branch 'master' of https://gitlab.com/Cloud_Solution/diplomatic-quarter into h20_E_referral
Conflicts: lib/config/config.dart lib/locator.dart lib/pages/landing/landing_page.dart pubspec.yamlmerge-requests/226/merge
@ -1,11 +1,36 @@
|
|||||||
package com.cloud.diplomaticquarterapp
|
package com.cloud.diplomaticquarterapp
|
||||||
import androidx.annotation.NonNull;
|
import android.content.ContentResolver
|
||||||
import io.flutter.embedding.android.FlutterFragmentActivity
|
import android.content.Context
|
||||||
import io.flutter.embedding.engine.FlutterEngine
|
import android.media.RingtoneManager
|
||||||
import io.flutter.plugins.GeneratedPluginRegistrant
|
import io.flutter.embedding.android.FlutterActivity
|
||||||
|
import io.flutter.embedding.engine.FlutterEngine
|
||||||
|
import io.flutter.plugin.common.MethodCall
|
||||||
|
import io.flutter.plugin.common.MethodChannel
|
||||||
|
import io.flutter.plugins.GeneratedPluginRegistrant
|
||||||
|
|
||||||
class MainActivity: FlutterFragmentActivity() {
|
class MainActivity : FlutterActivity() {
|
||||||
override fun configureFlutterEngine(@NonNull flutterEngine: FlutterEngine) {
|
override fun configureFlutterEngine(flutterEngine: FlutterEngine) {
|
||||||
GeneratedPluginRegistrant.registerWith(flutterEngine);
|
GeneratedPluginRegistrant.registerWith(flutterEngine)
|
||||||
}
|
MethodChannel(flutterEngine.dartExecutor, "crossingthestreams.io/resourceResolver").setMethodCallHandler { call: MethodCall, result: MethodChannel.Result ->
|
||||||
|
if ("drawableToUri" == call.method) {
|
||||||
|
val resourceId = this@MainActivity.resources.getIdentifier(call.arguments as String, "drawable", this@MainActivity.packageName)
|
||||||
|
result.success(resourceToUriString(this@MainActivity.applicationContext, resourceId))
|
||||||
|
}
|
||||||
|
if ("getAlarmUri" == call.method) {
|
||||||
|
result.success(RingtoneManager.getDefaultUri(RingtoneManager.TYPE_ALARM).toString())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
companion object {
|
||||||
|
private fun resourceToUriString(context: Context, resId: Int): String {
|
||||||
|
return (ContentResolver.SCHEME_ANDROID_RESOURCE
|
||||||
|
+ "://"
|
||||||
|
+ context.resources.getResourcePackageName(resId)
|
||||||
|
+ "/"
|
||||||
|
+ context.resources.getResourceTypeName(resId)
|
||||||
|
+ "/"
|
||||||
|
+ context.resources.getResourceEntryName(resId))
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 1021 B |
|
After Width: | Height: | Size: 180 B |
|
After Width: | Height: | Size: 1.0 KiB |
@ -0,0 +1,3 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<resources xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
tools:keep="@drawable/*,@raw/slow_spring_board" />
|
||||||
|
After Width: | Height: | Size: 2.3 KiB |
|
After Width: | Height: | Size: 3.4 KiB |
|
After Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 2.4 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 2.9 KiB |
|
After Width: | Height: | Size: 3.5 KiB |
|
After Width: | Height: | Size: 2.8 KiB |
|
After Width: | Height: | Size: 1.8 KiB |
|
After Width: | Height: | Size: 1.8 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
|
After Width: | Height: | Size: 2.2 KiB |
|
After Width: | Height: | Size: 2.1 KiB |
|
After Width: | Height: | Size: 2.5 KiB |
|
After Width: | Height: | Size: 2.8 KiB |
|
After Width: | Height: | Size: 2.6 KiB |
|
After Width: | Height: | Size: 2.7 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
@ -1,618 +0,0 @@
|
|||||||
// !$*UTF8*$!
|
|
||||||
{
|
|
||||||
archiveVersion = 1;
|
|
||||||
classes = {
|
|
||||||
};
|
|
||||||
objectVersion = 46;
|
|
||||||
objects = {
|
|
||||||
|
|
||||||
/* Begin PBXBuildFile section */
|
|
||||||
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
|
|
||||||
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
|
|
||||||
5A016D0DD1095D385566337C /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AC606583E610E227F8186476 /* Pods_Runner.framework */; };
|
|
||||||
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
|
|
||||||
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
|
|
||||||
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
|
|
||||||
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
|
|
||||||
/* End PBXBuildFile section */
|
|
||||||
|
|
||||||
/* Begin PBXCopyFilesBuildPhase section */
|
|
||||||
9705A1C41CF9048500538489 /* Embed Frameworks */ = {
|
|
||||||
isa = PBXCopyFilesBuildPhase;
|
|
||||||
buildActionMask = 2147483647;
|
|
||||||
dstPath = "";
|
|
||||||
dstSubfolderSpec = 10;
|
|
||||||
files = (
|
|
||||||
);
|
|
||||||
name = "Embed Frameworks";
|
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
|
||||||
};
|
|
||||||
/* End PBXCopyFilesBuildPhase section */
|
|
||||||
|
|
||||||
/* Begin PBXFileReference section */
|
|
||||||
09DDD2020D673759BD0E86B8 /* 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>"; };
|
|
||||||
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>"; };
|
|
||||||
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; 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>"; };
|
|
||||||
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.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>"; };
|
|
||||||
97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
|
||||||
97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; 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>"; };
|
|
||||||
97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
|
|
||||||
A8949DBAE70E5B302D91F1DB /* 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>"; };
|
|
||||||
AC606583E610E227F8186476 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
|
|
||||||
E2D9C922B5D0172FE487333D /* 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>"; };
|
|
||||||
/* End PBXFileReference section */
|
|
||||||
|
|
||||||
/* Begin PBXFrameworksBuildPhase section */
|
|
||||||
97C146EB1CF9000F007C117D /* Frameworks */ = {
|
|
||||||
isa = PBXFrameworksBuildPhase;
|
|
||||||
buildActionMask = 2147483647;
|
|
||||||
files = (
|
|
||||||
5A016D0DD1095D385566337C /* Pods_Runner.framework in Frameworks */,
|
|
||||||
);
|
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
|
||||||
};
|
|
||||||
/* End PBXFrameworksBuildPhase section */
|
|
||||||
|
|
||||||
/* Begin PBXGroup section */
|
|
||||||
0A1F078D9C068A8B18DE1EDB /* Pods */ = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
A8949DBAE70E5B302D91F1DB /* Pods-Runner.debug.xcconfig */,
|
|
||||||
E2D9C922B5D0172FE487333D /* Pods-Runner.release.xcconfig */,
|
|
||||||
09DDD2020D673759BD0E86B8 /* Pods-Runner.profile.xcconfig */,
|
|
||||||
);
|
|
||||||
name = Pods;
|
|
||||||
path = Pods;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
44EDA189DE1BB86E3A41BD4A /* Frameworks */ = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
AC606583E610E227F8186476 /* Pods_Runner.framework */,
|
|
||||||
);
|
|
||||||
name = Frameworks;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
9740EEB11CF90186004384FC /* Flutter */ = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
|
|
||||||
9740EEB21CF90195004384FC /* Debug.xcconfig */,
|
|
||||||
7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
|
|
||||||
9740EEB31CF90195004384FC /* Generated.xcconfig */,
|
|
||||||
);
|
|
||||||
name = Flutter;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
97C146E51CF9000F007C117D = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
9740EEB11CF90186004384FC /* Flutter */,
|
|
||||||
97C146F01CF9000F007C117D /* Runner */,
|
|
||||||
97C146EF1CF9000F007C117D /* Products */,
|
|
||||||
0A1F078D9C068A8B18DE1EDB /* Pods */,
|
|
||||||
44EDA189DE1BB86E3A41BD4A /* Frameworks */,
|
|
||||||
);
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
97C146EF1CF9000F007C117D /* Products */ = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
97C146EE1CF9000F007C117D /* Runner.app */,
|
|
||||||
);
|
|
||||||
name = Products;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
97C146F01CF9000F007C117D /* Runner */ = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
97C146FA1CF9000F007C117D /* Main.storyboard */,
|
|
||||||
97C146FD1CF9000F007C117D /* Assets.xcassets */,
|
|
||||||
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
|
|
||||||
97C147021CF9000F007C117D /* Info.plist */,
|
|
||||||
97C146F11CF9000F007C117D /* Supporting Files */,
|
|
||||||
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */,
|
|
||||||
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */,
|
|
||||||
74858FAE1ED2DC5600515810 /* AppDelegate.swift */,
|
|
||||||
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */,
|
|
||||||
);
|
|
||||||
path = Runner;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
97C146F11CF9000F007C117D /* Supporting Files */ = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
);
|
|
||||||
name = "Supporting Files";
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
/* End PBXGroup section */
|
|
||||||
|
|
||||||
/* Begin PBXNativeTarget section */
|
|
||||||
97C146ED1CF9000F007C117D /* Runner */ = {
|
|
||||||
isa = PBXNativeTarget;
|
|
||||||
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
|
|
||||||
buildPhases = (
|
|
||||||
B4860726BBF5BF6213BBC91C /* [CP] Check Pods Manifest.lock */,
|
|
||||||
9740EEB61CF901F6004384FC /* Run Script */,
|
|
||||||
97C146EA1CF9000F007C117D /* Sources */,
|
|
||||||
97C146EB1CF9000F007C117D /* Frameworks */,
|
|
||||||
97C146EC1CF9000F007C117D /* Resources */,
|
|
||||||
9705A1C41CF9048500538489 /* Embed Frameworks */,
|
|
||||||
3B06AD1E1E4923F5004D2608 /* Thin Binary */,
|
|
||||||
72E9699567A7106FD141B9B3 /* [CP] Embed Pods Frameworks */,
|
|
||||||
);
|
|
||||||
buildRules = (
|
|
||||||
);
|
|
||||||
dependencies = (
|
|
||||||
);
|
|
||||||
name = Runner;
|
|
||||||
productName = Runner;
|
|
||||||
productReference = 97C146EE1CF9000F007C117D /* Runner.app */;
|
|
||||||
productType = "com.apple.product-type.application";
|
|
||||||
};
|
|
||||||
/* End PBXNativeTarget section */
|
|
||||||
|
|
||||||
/* Begin PBXProject section */
|
|
||||||
97C146E61CF9000F007C117D /* Project object */ = {
|
|
||||||
isa = PBXProject;
|
|
||||||
attributes = {
|
|
||||||
LastUpgradeCheck = 1020;
|
|
||||||
ORGANIZATIONNAME = "";
|
|
||||||
TargetAttributes = {
|
|
||||||
97C146ED1CF9000F007C117D = {
|
|
||||||
CreatedOnToolsVersion = 7.3.1;
|
|
||||||
LastSwiftMigration = 1100;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
|
|
||||||
compatibilityVersion = "Xcode 9.3";
|
|
||||||
developmentRegion = en;
|
|
||||||
hasScannedForEncodings = 0;
|
|
||||||
knownRegions = (
|
|
||||||
en,
|
|
||||||
Base,
|
|
||||||
);
|
|
||||||
mainGroup = 97C146E51CF9000F007C117D;
|
|
||||||
productRefGroup = 97C146EF1CF9000F007C117D /* Products */;
|
|
||||||
projectDirPath = "";
|
|
||||||
projectRoot = "";
|
|
||||||
targets = (
|
|
||||||
97C146ED1CF9000F007C117D /* Runner */,
|
|
||||||
);
|
|
||||||
};
|
|
||||||
/* End PBXProject section */
|
|
||||||
|
|
||||||
/* Begin PBXResourcesBuildPhase section */
|
|
||||||
97C146EC1CF9000F007C117D /* Resources */ = {
|
|
||||||
isa = PBXResourcesBuildPhase;
|
|
||||||
buildActionMask = 2147483647;
|
|
||||||
files = (
|
|
||||||
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
|
|
||||||
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
|
|
||||||
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
|
|
||||||
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
|
|
||||||
);
|
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
|
||||||
};
|
|
||||||
/* End PBXResourcesBuildPhase section */
|
|
||||||
|
|
||||||
/* Begin PBXShellScriptBuildPhase section */
|
|
||||||
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
|
|
||||||
isa = PBXShellScriptBuildPhase;
|
|
||||||
buildActionMask = 2147483647;
|
|
||||||
files = (
|
|
||||||
);
|
|
||||||
inputPaths = (
|
|
||||||
);
|
|
||||||
name = "Thin Binary";
|
|
||||||
outputPaths = (
|
|
||||||
);
|
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
|
||||||
shellPath = /bin/sh;
|
|
||||||
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
|
|
||||||
};
|
|
||||||
72E9699567A7106FD141B9B3 /* [CP] Embed Pods Frameworks */ = {
|
|
||||||
isa = PBXShellScriptBuildPhase;
|
|
||||||
buildActionMask = 2147483647;
|
|
||||||
files = (
|
|
||||||
);
|
|
||||||
inputPaths = (
|
|
||||||
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh",
|
|
||||||
"${PODS_ROOT}/../Flutter/Flutter.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/GoogleUtilities/GoogleUtilities.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/MTBBarcodeScanner/MTBBarcodeScanner.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/PromisesObjC/FBLPromises.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/Protobuf/protobuf.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/Reachability/Reachability.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/SwiftProtobuf/SwiftProtobuf.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/TOCropViewController/TOCropViewController.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/barcode_scan/barcode_scan.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/connectivity/connectivity.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/device_info/device_info.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/flutter_flexible_toast/flutter_flexible_toast.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/flutter_inappwebview/flutter_inappwebview.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/flutter_local_notifications/flutter_local_notifications.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/flutter_plugin_android_lifecycle/flutter_plugin_android_lifecycle.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/hexcolor/hexcolor.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/image_cropper/image_cropper.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/image_picker/image_picker.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/local_auth/local_auth.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/manage_calendar_events/manage_calendar_events.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/map_launcher/map_launcher.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/nanopb/nanopb.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/shared_preferences/shared_preferences.framework",
|
|
||||||
"${BUILT_PRODUCTS_DIR}/url_launcher/url_launcher.framework",
|
|
||||||
);
|
|
||||||
name = "[CP] Embed Pods Frameworks";
|
|
||||||
outputPaths = (
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Flutter.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/GoogleUtilities.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MTBBarcodeScanner.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/FBLPromises.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/protobuf.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Reachability.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/SwiftProtobuf.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/TOCropViewController.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/barcode_scan.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/connectivity.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/device_info.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/flutter_flexible_toast.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/flutter_inappwebview.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/flutter_local_notifications.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/flutter_plugin_android_lifecycle.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/hexcolor.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/image_cropper.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/image_picker.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/local_auth.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/manage_calendar_events.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/map_launcher.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/nanopb.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/shared_preferences.framework",
|
|
||||||
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/url_launcher.framework",
|
|
||||||
);
|
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
|
||||||
shellPath = /bin/sh;
|
|
||||||
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
|
|
||||||
showEnvVarsInLog = 0;
|
|
||||||
};
|
|
||||||
9740EEB61CF901F6004384FC /* Run Script */ = {
|
|
||||||
isa = PBXShellScriptBuildPhase;
|
|
||||||
buildActionMask = 2147483647;
|
|
||||||
files = (
|
|
||||||
);
|
|
||||||
inputPaths = (
|
|
||||||
);
|
|
||||||
name = "Run Script";
|
|
||||||
outputPaths = (
|
|
||||||
);
|
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
|
||||||
shellPath = /bin/sh;
|
|
||||||
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
|
|
||||||
};
|
|
||||||
B4860726BBF5BF6213BBC91C /* [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;
|
|
||||||
};
|
|
||||||
/* End PBXShellScriptBuildPhase section */
|
|
||||||
|
|
||||||
/* Begin PBXSourcesBuildPhase section */
|
|
||||||
97C146EA1CF9000F007C117D /* Sources */ = {
|
|
||||||
isa = PBXSourcesBuildPhase;
|
|
||||||
buildActionMask = 2147483647;
|
|
||||||
files = (
|
|
||||||
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */,
|
|
||||||
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */,
|
|
||||||
);
|
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
|
||||||
};
|
|
||||||
/* End PBXSourcesBuildPhase section */
|
|
||||||
|
|
||||||
/* Begin PBXVariantGroup section */
|
|
||||||
97C146FA1CF9000F007C117D /* Main.storyboard */ = {
|
|
||||||
isa = PBXVariantGroup;
|
|
||||||
children = (
|
|
||||||
97C146FB1CF9000F007C117D /* Base */,
|
|
||||||
);
|
|
||||||
name = Main.storyboard;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = {
|
|
||||||
isa = PBXVariantGroup;
|
|
||||||
children = (
|
|
||||||
97C147001CF9000F007C117D /* Base */,
|
|
||||||
);
|
|
||||||
name = LaunchScreen.storyboard;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
/* End PBXVariantGroup section */
|
|
||||||
|
|
||||||
/* Begin XCBuildConfiguration section */
|
|
||||||
249021D3217E4FDB00AE95B9 /* Profile */ = {
|
|
||||||
isa = XCBuildConfiguration;
|
|
||||||
buildSettings = {
|
|
||||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
||||||
CLANG_ANALYZER_NONNULL = YES;
|
|
||||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
|
||||||
CLANG_CXX_LIBRARY = "libc++";
|
|
||||||
CLANG_ENABLE_MODULES = YES;
|
|
||||||
CLANG_ENABLE_OBJC_ARC = YES;
|
|
||||||
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
|
||||||
CLANG_WARN_BOOL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_COMMA = YES;
|
|
||||||
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
|
||||||
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
|
||||||
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
|
||||||
CLANG_WARN_EMPTY_BODY = YES;
|
|
||||||
CLANG_WARN_ENUM_CONVERSION = YES;
|
|
||||||
CLANG_WARN_INFINITE_RECURSION = YES;
|
|
||||||
CLANG_WARN_INT_CONVERSION = YES;
|
|
||||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
|
||||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
|
||||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
|
||||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
|
||||||
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
|
||||||
CLANG_WARN_UNREACHABLE_CODE = YES;
|
|
||||||
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
|
||||||
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
|
||||||
COPY_PHASE_STRIP = NO;
|
|
||||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
|
||||||
ENABLE_NS_ASSERTIONS = NO;
|
|
||||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu99;
|
|
||||||
GCC_NO_COMMON_BLOCKS = YES;
|
|
||||||
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
|
|
||||||
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
|
|
||||||
GCC_WARN_UNDECLARED_SELECTOR = YES;
|
|
||||||
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
|
||||||
GCC_WARN_UNUSED_FUNCTION = YES;
|
|
||||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
|
|
||||||
MTL_ENABLE_DEBUG_INFO = NO;
|
|
||||||
SDKROOT = iphoneos;
|
|
||||||
SUPPORTED_PLATFORMS = iphoneos;
|
|
||||||
TARGETED_DEVICE_FAMILY = "1,2";
|
|
||||||
VALIDATE_PRODUCT = YES;
|
|
||||||
};
|
|
||||||
name = Profile;
|
|
||||||
};
|
|
||||||
249021D4217E4FDB00AE95B9 /* Profile */ = {
|
|
||||||
isa = XCBuildConfiguration;
|
|
||||||
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
|
|
||||||
buildSettings = {
|
|
||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
|
||||||
CLANG_ENABLE_MODULES = YES;
|
|
||||||
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
|
|
||||||
ENABLE_BITCODE = NO;
|
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
|
||||||
"$(inherited)",
|
|
||||||
"$(PROJECT_DIR)/Flutter",
|
|
||||||
);
|
|
||||||
INFOPLIST_FILE = Runner/Info.plist;
|
|
||||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
|
||||||
LIBRARY_SEARCH_PATHS = (
|
|
||||||
"$(inherited)",
|
|
||||||
"$(PROJECT_DIR)/Flutter",
|
|
||||||
);
|
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.cloud.diplomaticquarterapp;
|
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
|
||||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
|
||||||
SWIFT_VERSION = 5.0;
|
|
||||||
VERSIONING_SYSTEM = "apple-generic";
|
|
||||||
};
|
|
||||||
name = Profile;
|
|
||||||
};
|
|
||||||
97C147031CF9000F007C117D /* Debug */ = {
|
|
||||||
isa = XCBuildConfiguration;
|
|
||||||
buildSettings = {
|
|
||||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
||||||
CLANG_ANALYZER_NONNULL = YES;
|
|
||||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
|
||||||
CLANG_CXX_LIBRARY = "libc++";
|
|
||||||
CLANG_ENABLE_MODULES = YES;
|
|
||||||
CLANG_ENABLE_OBJC_ARC = YES;
|
|
||||||
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
|
||||||
CLANG_WARN_BOOL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_COMMA = YES;
|
|
||||||
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
|
||||||
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
|
||||||
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
|
||||||
CLANG_WARN_EMPTY_BODY = YES;
|
|
||||||
CLANG_WARN_ENUM_CONVERSION = YES;
|
|
||||||
CLANG_WARN_INFINITE_RECURSION = YES;
|
|
||||||
CLANG_WARN_INT_CONVERSION = YES;
|
|
||||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
|
||||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
|
||||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
|
||||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
|
||||||
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
|
||||||
CLANG_WARN_UNREACHABLE_CODE = YES;
|
|
||||||
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
|
||||||
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
|
||||||
COPY_PHASE_STRIP = NO;
|
|
||||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
|
||||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
|
||||||
ENABLE_TESTABILITY = YES;
|
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu99;
|
|
||||||
GCC_DYNAMIC_NO_PIC = NO;
|
|
||||||
GCC_NO_COMMON_BLOCKS = YES;
|
|
||||||
GCC_OPTIMIZATION_LEVEL = 0;
|
|
||||||
GCC_PREPROCESSOR_DEFINITIONS = (
|
|
||||||
"DEBUG=1",
|
|
||||||
"$(inherited)",
|
|
||||||
);
|
|
||||||
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
|
|
||||||
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
|
|
||||||
GCC_WARN_UNDECLARED_SELECTOR = YES;
|
|
||||||
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
|
||||||
GCC_WARN_UNUSED_FUNCTION = YES;
|
|
||||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
|
|
||||||
MTL_ENABLE_DEBUG_INFO = YES;
|
|
||||||
ONLY_ACTIVE_ARCH = YES;
|
|
||||||
SDKROOT = iphoneos;
|
|
||||||
TARGETED_DEVICE_FAMILY = "1,2";
|
|
||||||
};
|
|
||||||
name = Debug;
|
|
||||||
};
|
|
||||||
97C147041CF9000F007C117D /* Release */ = {
|
|
||||||
isa = XCBuildConfiguration;
|
|
||||||
buildSettings = {
|
|
||||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
||||||
CLANG_ANALYZER_NONNULL = YES;
|
|
||||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
|
||||||
CLANG_CXX_LIBRARY = "libc++";
|
|
||||||
CLANG_ENABLE_MODULES = YES;
|
|
||||||
CLANG_ENABLE_OBJC_ARC = YES;
|
|
||||||
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
|
||||||
CLANG_WARN_BOOL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_COMMA = YES;
|
|
||||||
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
|
||||||
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
|
||||||
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
|
||||||
CLANG_WARN_EMPTY_BODY = YES;
|
|
||||||
CLANG_WARN_ENUM_CONVERSION = YES;
|
|
||||||
CLANG_WARN_INFINITE_RECURSION = YES;
|
|
||||||
CLANG_WARN_INT_CONVERSION = YES;
|
|
||||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
|
||||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
|
||||||
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
|
||||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
|
||||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
|
||||||
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
|
||||||
CLANG_WARN_UNREACHABLE_CODE = YES;
|
|
||||||
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
|
||||||
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
|
||||||
COPY_PHASE_STRIP = NO;
|
|
||||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
|
||||||
ENABLE_NS_ASSERTIONS = NO;
|
|
||||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu99;
|
|
||||||
GCC_NO_COMMON_BLOCKS = YES;
|
|
||||||
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
|
|
||||||
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
|
|
||||||
GCC_WARN_UNDECLARED_SELECTOR = YES;
|
|
||||||
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
|
||||||
GCC_WARN_UNUSED_FUNCTION = YES;
|
|
||||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
|
|
||||||
MTL_ENABLE_DEBUG_INFO = NO;
|
|
||||||
SDKROOT = iphoneos;
|
|
||||||
SUPPORTED_PLATFORMS = iphoneos;
|
|
||||||
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
|
|
||||||
TARGETED_DEVICE_FAMILY = "1,2";
|
|
||||||
VALIDATE_PRODUCT = YES;
|
|
||||||
};
|
|
||||||
name = Release;
|
|
||||||
};
|
|
||||||
97C147061CF9000F007C117D /* Debug */ = {
|
|
||||||
isa = XCBuildConfiguration;
|
|
||||||
baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
|
|
||||||
buildSettings = {
|
|
||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
|
||||||
CLANG_ENABLE_MODULES = YES;
|
|
||||||
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
|
|
||||||
ENABLE_BITCODE = NO;
|
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
|
||||||
"$(inherited)",
|
|
||||||
"$(PROJECT_DIR)/Flutter",
|
|
||||||
);
|
|
||||||
INFOPLIST_FILE = Runner/Info.plist;
|
|
||||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
|
||||||
LIBRARY_SEARCH_PATHS = (
|
|
||||||
"$(inherited)",
|
|
||||||
"$(PROJECT_DIR)/Flutter",
|
|
||||||
);
|
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.cloud.diplomaticquarterapp;
|
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
|
||||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
|
||||||
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
|
|
||||||
SWIFT_VERSION = 5.0;
|
|
||||||
VERSIONING_SYSTEM = "apple-generic";
|
|
||||||
};
|
|
||||||
name = Debug;
|
|
||||||
};
|
|
||||||
97C147071CF9000F007C117D /* Release */ = {
|
|
||||||
isa = XCBuildConfiguration;
|
|
||||||
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
|
|
||||||
buildSettings = {
|
|
||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
|
||||||
CLANG_ENABLE_MODULES = YES;
|
|
||||||
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
|
|
||||||
ENABLE_BITCODE = NO;
|
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
|
||||||
"$(inherited)",
|
|
||||||
"$(PROJECT_DIR)/Flutter",
|
|
||||||
);
|
|
||||||
INFOPLIST_FILE = Runner/Info.plist;
|
|
||||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
|
||||||
LIBRARY_SEARCH_PATHS = (
|
|
||||||
"$(inherited)",
|
|
||||||
"$(PROJECT_DIR)/Flutter",
|
|
||||||
);
|
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = com.cloud.diplomaticquarterapp;
|
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
|
||||||
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
|
|
||||||
SWIFT_VERSION = 5.0;
|
|
||||||
VERSIONING_SYSTEM = "apple-generic";
|
|
||||||
};
|
|
||||||
name = Release;
|
|
||||||
};
|
|
||||||
/* End XCBuildConfiguration section */
|
|
||||||
|
|
||||||
/* Begin XCConfigurationList section */
|
|
||||||
97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = {
|
|
||||||
isa = XCConfigurationList;
|
|
||||||
buildConfigurations = (
|
|
||||||
97C147031CF9000F007C117D /* Debug */,
|
|
||||||
97C147041CF9000F007C117D /* Release */,
|
|
||||||
249021D3217E4FDB00AE95B9 /* Profile */,
|
|
||||||
);
|
|
||||||
defaultConfigurationIsVisible = 0;
|
|
||||||
defaultConfigurationName = Release;
|
|
||||||
};
|
|
||||||
97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = {
|
|
||||||
isa = XCConfigurationList;
|
|
||||||
buildConfigurations = (
|
|
||||||
97C147061CF9000F007C117D /* Debug */,
|
|
||||||
97C147071CF9000F007C117D /* Release */,
|
|
||||||
249021D4217E4FDB00AE95B9 /* Profile */,
|
|
||||||
);
|
|
||||||
defaultConfigurationIsVisible = 0;
|
|
||||||
defaultConfigurationName = Release;
|
|
||||||
};
|
|
||||||
/* End XCConfigurationList section */
|
|
||||||
};
|
|
||||||
rootObject = 97C146E61CF9000F007C117D /* Project object */;
|
|
||||||
}
|
|
||||||
@ -1,7 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<Workspace
|
|
||||||
version = "1.0">
|
|
||||||
<FileRef
|
|
||||||
location = "group:Runner.xcodeproj">
|
|
||||||
</FileRef>
|
|
||||||
</Workspace>
|
|
||||||
@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
||||||
<plist version="1.0">
|
|
||||||
<dict>
|
|
||||||
<key>IDEDidComputeMac32BitWarning</key>
|
|
||||||
<true/>
|
|
||||||
</dict>
|
|
||||||
</plist>
|
|
||||||
@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
||||||
<plist version="1.0">
|
|
||||||
<dict>
|
|
||||||
<key>PreviewsEnabled</key>
|
|
||||||
<false/>
|
|
||||||
</dict>
|
|
||||||
</plist>
|
|
||||||
@ -1,91 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<Scheme
|
|
||||||
LastUpgradeVersion = "1020"
|
|
||||||
version = "1.3">
|
|
||||||
<BuildAction
|
|
||||||
parallelizeBuildables = "YES"
|
|
||||||
buildImplicitDependencies = "YES">
|
|
||||||
<BuildActionEntries>
|
|
||||||
<BuildActionEntry
|
|
||||||
buildForTesting = "YES"
|
|
||||||
buildForRunning = "YES"
|
|
||||||
buildForProfiling = "YES"
|
|
||||||
buildForArchiving = "YES"
|
|
||||||
buildForAnalyzing = "YES">
|
|
||||||
<BuildableReference
|
|
||||||
BuildableIdentifier = "primary"
|
|
||||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
|
||||||
BuildableName = "Runner.app"
|
|
||||||
BlueprintName = "Runner"
|
|
||||||
ReferencedContainer = "container:Runner.xcodeproj">
|
|
||||||
</BuildableReference>
|
|
||||||
</BuildActionEntry>
|
|
||||||
</BuildActionEntries>
|
|
||||||
</BuildAction>
|
|
||||||
<TestAction
|
|
||||||
buildConfiguration = "Debug"
|
|
||||||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
|
|
||||||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
|
|
||||||
shouldUseLaunchSchemeArgsEnv = "YES">
|
|
||||||
<Testables>
|
|
||||||
</Testables>
|
|
||||||
<MacroExpansion>
|
|
||||||
<BuildableReference
|
|
||||||
BuildableIdentifier = "primary"
|
|
||||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
|
||||||
BuildableName = "Runner.app"
|
|
||||||
BlueprintName = "Runner"
|
|
||||||
ReferencedContainer = "container:Runner.xcodeproj">
|
|
||||||
</BuildableReference>
|
|
||||||
</MacroExpansion>
|
|
||||||
<AdditionalOptions>
|
|
||||||
</AdditionalOptions>
|
|
||||||
</TestAction>
|
|
||||||
<LaunchAction
|
|
||||||
buildConfiguration = "Debug"
|
|
||||||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
|
|
||||||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
|
|
||||||
launchStyle = "0"
|
|
||||||
useCustomWorkingDirectory = "NO"
|
|
||||||
ignoresPersistentStateOnLaunch = "NO"
|
|
||||||
debugDocumentVersioning = "YES"
|
|
||||||
debugServiceExtension = "internal"
|
|
||||||
allowLocationSimulation = "YES">
|
|
||||||
<BuildableProductRunnable
|
|
||||||
runnableDebuggingMode = "0">
|
|
||||||
<BuildableReference
|
|
||||||
BuildableIdentifier = "primary"
|
|
||||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
|
||||||
BuildableName = "Runner.app"
|
|
||||||
BlueprintName = "Runner"
|
|
||||||
ReferencedContainer = "container:Runner.xcodeproj">
|
|
||||||
</BuildableReference>
|
|
||||||
</BuildableProductRunnable>
|
|
||||||
<AdditionalOptions>
|
|
||||||
</AdditionalOptions>
|
|
||||||
</LaunchAction>
|
|
||||||
<ProfileAction
|
|
||||||
buildConfiguration = "Profile"
|
|
||||||
shouldUseLaunchSchemeArgsEnv = "YES"
|
|
||||||
savedToolIdentifier = ""
|
|
||||||
useCustomWorkingDirectory = "NO"
|
|
||||||
debugDocumentVersioning = "YES">
|
|
||||||
<BuildableProductRunnable
|
|
||||||
runnableDebuggingMode = "0">
|
|
||||||
<BuildableReference
|
|
||||||
BuildableIdentifier = "primary"
|
|
||||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
|
||||||
BuildableName = "Runner.app"
|
|
||||||
BlueprintName = "Runner"
|
|
||||||
ReferencedContainer = "container:Runner.xcodeproj">
|
|
||||||
</BuildableReference>
|
|
||||||
</BuildableProductRunnable>
|
|
||||||
</ProfileAction>
|
|
||||||
<AnalyzeAction
|
|
||||||
buildConfiguration = "Debug">
|
|
||||||
</AnalyzeAction>
|
|
||||||
<ArchiveAction
|
|
||||||
buildConfiguration = "Release"
|
|
||||||
revealArchiveInOrganizer = "YES">
|
|
||||||
</ArchiveAction>
|
|
||||||
</Scheme>
|
|
||||||
@ -1,10 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<Workspace
|
|
||||||
version = "1.0">
|
|
||||||
<FileRef
|
|
||||||
location = "group:Runner.xcodeproj">
|
|
||||||
</FileRef>
|
|
||||||
<FileRef
|
|
||||||
location = "group:Pods/Pods.xcodeproj">
|
|
||||||
</FileRef>
|
|
||||||
</Workspace>
|
|
||||||
@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
||||||
<plist version="1.0">
|
|
||||||
<dict>
|
|
||||||
<key>IDEDidComputeMac32BitWarning</key>
|
|
||||||
<true/>
|
|
||||||
</dict>
|
|
||||||
</plist>
|
|
||||||
@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
||||||
<plist version="1.0">
|
|
||||||
<dict>
|
|
||||||
<key>PreviewsEnabled</key>
|
|
||||||
<false/>
|
|
||||||
</dict>
|
|
||||||
</plist>
|
|
||||||
@ -1,13 +0,0 @@
|
|||||||
import UIKit
|
|
||||||
import Flutter
|
|
||||||
|
|
||||||
@UIApplicationMain
|
|
||||||
@objc class AppDelegate: FlutterAppDelegate {
|
|
||||||
override func application(
|
|
||||||
_ application: UIApplication,
|
|
||||||
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
|
|
||||||
) -> Bool {
|
|
||||||
GeneratedPluginRegistrant.register(with: self)
|
|
||||||
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1 +0,0 @@
|
|||||||
#import "GeneratedPluginRegistrant.h"
|
|
||||||
@ -0,0 +1,48 @@
|
|||||||
|
class Allergy {
|
||||||
|
int patientID;
|
||||||
|
int allergyDiseaseType;
|
||||||
|
int allergyDiseaseID;
|
||||||
|
String description;
|
||||||
|
dynamic descriptionN;
|
||||||
|
dynamic remarks;
|
||||||
|
dynamic avgDoctorRatingList;
|
||||||
|
dynamic doctorRatingDetailsList;
|
||||||
|
dynamic notesDoctorRatingList;
|
||||||
|
|
||||||
|
Allergy(
|
||||||
|
{this.patientID,
|
||||||
|
this.allergyDiseaseType,
|
||||||
|
this.allergyDiseaseID,
|
||||||
|
this.description,
|
||||||
|
this.descriptionN,
|
||||||
|
this.remarks,
|
||||||
|
this.avgDoctorRatingList,
|
||||||
|
this.doctorRatingDetailsList,
|
||||||
|
this.notesDoctorRatingList});
|
||||||
|
|
||||||
|
Allergy.fromJson(Map<String, dynamic> json) {
|
||||||
|
patientID = json['PatientID'];
|
||||||
|
allergyDiseaseType = json['AllergyDiseaseType'];
|
||||||
|
allergyDiseaseID = json['AllergyDiseaseID'];
|
||||||
|
description = json['Description'];
|
||||||
|
descriptionN = json['DescriptionN'];
|
||||||
|
remarks = json['Remarks'];
|
||||||
|
avgDoctorRatingList = json['AvgDoctorRatingList'];
|
||||||
|
doctorRatingDetailsList = json['DoctorRatingDetailsList'];
|
||||||
|
notesDoctorRatingList = json['NotesDoctorRatingList'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['PatientID'] = this.patientID;
|
||||||
|
data['AllergyDiseaseType'] = this.allergyDiseaseType;
|
||||||
|
data['AllergyDiseaseID'] = this.allergyDiseaseID;
|
||||||
|
data['Description'] = this.description;
|
||||||
|
data['DescriptionN'] = this.descriptionN;
|
||||||
|
data['Remarks'] = this.remarks;
|
||||||
|
data['AvgDoctorRatingList'] = this.avgDoctorRatingList;
|
||||||
|
data['DoctorRatingDetailsList'] = this.doctorRatingDetailsList;
|
||||||
|
data['NotesDoctorRatingList'] = this.notesDoctorRatingList;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,146 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class ActivePrescriptionReport {
|
||||||
|
dynamic address;
|
||||||
|
int appointmentNo;
|
||||||
|
dynamic clinic;
|
||||||
|
dynamic companyName;
|
||||||
|
int days;
|
||||||
|
dynamic doctorName;
|
||||||
|
int doseDailyQuantity;
|
||||||
|
String frequency;
|
||||||
|
int frequencyNumber;
|
||||||
|
List<int> image;
|
||||||
|
String imageExtension;
|
||||||
|
dynamic imageSRCUrl;
|
||||||
|
String imageString;
|
||||||
|
dynamic imageThumbUrl;
|
||||||
|
dynamic isCovered;
|
||||||
|
String itemDescription;
|
||||||
|
int itemID;
|
||||||
|
DateTime orderDate;
|
||||||
|
int patientID;
|
||||||
|
dynamic patientName;
|
||||||
|
dynamic phoneOffice1;
|
||||||
|
dynamic prescriptionQR;
|
||||||
|
int prescriptionTimes;
|
||||||
|
dynamic productImage;
|
||||||
|
String productImageBase64;
|
||||||
|
String productImageString;
|
||||||
|
int projectID;
|
||||||
|
dynamic projectName;
|
||||||
|
dynamic remarks;
|
||||||
|
String route;
|
||||||
|
String sKU;
|
||||||
|
int scaleOffset;
|
||||||
|
DateTime startDate;
|
||||||
|
|
||||||
|
ActivePrescriptionReport(
|
||||||
|
{this.address,
|
||||||
|
this.appointmentNo,
|
||||||
|
this.clinic,
|
||||||
|
this.companyName,
|
||||||
|
this.days,
|
||||||
|
this.doctorName,
|
||||||
|
this.doseDailyQuantity,
|
||||||
|
this.frequency,
|
||||||
|
this.frequencyNumber,
|
||||||
|
this.image,
|
||||||
|
this.imageExtension,
|
||||||
|
this.imageSRCUrl,
|
||||||
|
this.imageString,
|
||||||
|
this.imageThumbUrl,
|
||||||
|
this.isCovered,
|
||||||
|
this.itemDescription,
|
||||||
|
this.itemID,
|
||||||
|
this.orderDate,
|
||||||
|
this.patientID,
|
||||||
|
this.patientName,
|
||||||
|
this.phoneOffice1,
|
||||||
|
this.prescriptionQR,
|
||||||
|
this.prescriptionTimes,
|
||||||
|
this.productImage,
|
||||||
|
this.productImageBase64,
|
||||||
|
this.productImageString,
|
||||||
|
this.projectID,
|
||||||
|
this.projectName,
|
||||||
|
this.remarks,
|
||||||
|
this.route,
|
||||||
|
this.sKU,
|
||||||
|
this.scaleOffset,
|
||||||
|
this.startDate});
|
||||||
|
|
||||||
|
ActivePrescriptionReport.fromJson(Map<String, dynamic> json) {
|
||||||
|
address = json['Address'];
|
||||||
|
appointmentNo = json['AppointmentNo'];
|
||||||
|
clinic = json['Clinic'];
|
||||||
|
companyName = json['CompanyName'];
|
||||||
|
days = json['Days'];
|
||||||
|
doctorName = json['DoctorName'];
|
||||||
|
doseDailyQuantity = json['DoseDailyQuantity'];
|
||||||
|
frequency = json['Frequency'];
|
||||||
|
frequencyNumber = json['FrequencyNumber'];
|
||||||
|
image = json['Image'].cast<int>();
|
||||||
|
imageExtension = json['ImageExtension'];
|
||||||
|
imageSRCUrl = json['ImageSRCUrl'];
|
||||||
|
imageString = json['ImageString'];
|
||||||
|
imageThumbUrl = json['ImageThumbUrl'];
|
||||||
|
isCovered = json['IsCovered'];
|
||||||
|
itemDescription = json['ItemDescription'];
|
||||||
|
itemID = json['ItemID'];
|
||||||
|
orderDate = DateUtil.convertStringToDate(json['OrderDate']);
|
||||||
|
patientID = json['PatientID'];
|
||||||
|
patientName = json['PatientName'];
|
||||||
|
phoneOffice1 = json['PhoneOffice1'];
|
||||||
|
prescriptionQR = json['PrescriptionQR'];
|
||||||
|
prescriptionTimes = json['PrescriptionTimes'];
|
||||||
|
productImage = json['ProductImage'];
|
||||||
|
productImageBase64 = json['ProductImageBase64'];
|
||||||
|
productImageString = json['ProductImageString'];
|
||||||
|
projectID = json['ProjectID'];
|
||||||
|
projectName = json['ProjectName'];
|
||||||
|
remarks = json['Remarks'];
|
||||||
|
route = json['Route'];
|
||||||
|
sKU = json['SKU'];
|
||||||
|
scaleOffset = json['ScaleOffset'];
|
||||||
|
startDate = DateUtil.convertStringToDate(json['StartDate']);
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['Address'] = this.address;
|
||||||
|
data['AppointmentNo'] = this.appointmentNo;
|
||||||
|
data['Clinic'] = this.clinic;
|
||||||
|
data['CompanyName'] = this.companyName;
|
||||||
|
data['Days'] = this.days;
|
||||||
|
data['DoctorName'] = this.doctorName;
|
||||||
|
data['DoseDailyQuantity'] = this.doseDailyQuantity;
|
||||||
|
data['Frequency'] = this.frequency;
|
||||||
|
data['FrequencyNumber'] = this.frequencyNumber;
|
||||||
|
data['Image'] = this.image;
|
||||||
|
data['ImageExtension'] = this.imageExtension;
|
||||||
|
data['ImageSRCUrl'] = this.imageSRCUrl;
|
||||||
|
data['ImageString'] = this.imageString;
|
||||||
|
data['ImageThumbUrl'] = this.imageThumbUrl;
|
||||||
|
data['IsCovered'] = this.isCovered;
|
||||||
|
data['ItemDescription'] = this.itemDescription;
|
||||||
|
data['ItemID'] = this.itemID;
|
||||||
|
data['OrderDate'] = this.orderDate;
|
||||||
|
data['PatientID'] = this.patientID;
|
||||||
|
data['PatientName'] = this.patientName;
|
||||||
|
data['PhoneOffice1'] = this.phoneOffice1;
|
||||||
|
data['PrescriptionQR'] = this.prescriptionQR;
|
||||||
|
data['PrescriptionTimes'] = this.prescriptionTimes;
|
||||||
|
data['ProductImage'] = this.productImage;
|
||||||
|
data['ProductImageBase64'] = this.productImageBase64;
|
||||||
|
data['ProductImageString'] = this.productImageString;
|
||||||
|
data['ProjectID'] = this.projectID;
|
||||||
|
data['ProjectName'] = this.projectName;
|
||||||
|
data['Remarks'] = this.remarks;
|
||||||
|
data['Route'] = this.route;
|
||||||
|
data['SKU'] = this.sKU;
|
||||||
|
data['ScaleOffset'] = this.scaleOffset;
|
||||||
|
data['StartDate'] = this.startDate;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,92 @@
|
|||||||
|
class AskDoctorReqTypes {
|
||||||
|
dynamic setupID;
|
||||||
|
int parameterGroup;
|
||||||
|
int parameterType;
|
||||||
|
int parameterCode;
|
||||||
|
String description;
|
||||||
|
dynamic descriptionN;
|
||||||
|
dynamic alias;
|
||||||
|
dynamic aliasN;
|
||||||
|
dynamic prefix;
|
||||||
|
dynamic suffix;
|
||||||
|
dynamic isColorCodingRequired;
|
||||||
|
dynamic backColor;
|
||||||
|
dynamic foreColor;
|
||||||
|
bool isBuiltIn;
|
||||||
|
bool isActive;
|
||||||
|
int createdBy;
|
||||||
|
String createdOn;
|
||||||
|
dynamic editedBy;
|
||||||
|
dynamic editedOn;
|
||||||
|
dynamic rowVer;
|
||||||
|
|
||||||
|
AskDoctorReqTypes(
|
||||||
|
{this.setupID,
|
||||||
|
this.parameterGroup,
|
||||||
|
this.parameterType,
|
||||||
|
this.parameterCode,
|
||||||
|
this.description,
|
||||||
|
this.descriptionN,
|
||||||
|
this.alias,
|
||||||
|
this.aliasN,
|
||||||
|
this.prefix,
|
||||||
|
this.suffix,
|
||||||
|
this.isColorCodingRequired,
|
||||||
|
this.backColor,
|
||||||
|
this.foreColor,
|
||||||
|
this.isBuiltIn,
|
||||||
|
this.isActive,
|
||||||
|
this.createdBy,
|
||||||
|
this.createdOn,
|
||||||
|
this.editedBy,
|
||||||
|
this.editedOn,
|
||||||
|
this.rowVer});
|
||||||
|
|
||||||
|
AskDoctorReqTypes.fromJson(Map<String, dynamic> json) {
|
||||||
|
setupID = json['SetupID'];
|
||||||
|
parameterGroup = json['ParameterGroup'];
|
||||||
|
parameterType = json['ParameterType'];
|
||||||
|
parameterCode = json['ParameterCode'];
|
||||||
|
description = json['Description'];
|
||||||
|
descriptionN = json['DescriptionN'];
|
||||||
|
alias = json['Alias'];
|
||||||
|
aliasN = json['AliasN'];
|
||||||
|
prefix = json['Prefix'];
|
||||||
|
suffix = json['Suffix'];
|
||||||
|
isColorCodingRequired = json['IsColorCodingRequired'];
|
||||||
|
backColor = json['BackColor'];
|
||||||
|
foreColor = json['ForeColor'];
|
||||||
|
isBuiltIn = json['IsBuiltIn'];
|
||||||
|
isActive = json['IsActive'];
|
||||||
|
createdBy = json['CreatedBy'];
|
||||||
|
createdOn = json['CreatedOn'];
|
||||||
|
editedBy = json['EditedBy'];
|
||||||
|
editedOn = json['EditedOn'];
|
||||||
|
rowVer = json['RowVer'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['SetupID'] = this.setupID;
|
||||||
|
data['ParameterGroup'] = this.parameterGroup;
|
||||||
|
data['ParameterType'] = this.parameterType;
|
||||||
|
data['ParameterCode'] = this.parameterCode;
|
||||||
|
data['Description'] = this.description;
|
||||||
|
data['DescriptionN'] = this.descriptionN;
|
||||||
|
data['Alias'] = this.alias;
|
||||||
|
data['AliasN'] = this.aliasN;
|
||||||
|
data['Prefix'] = this.prefix;
|
||||||
|
data['Suffix'] = this.suffix;
|
||||||
|
data['IsColorCodingRequired'] = this.isColorCodingRequired;
|
||||||
|
data['BackColor'] = this.backColor;
|
||||||
|
data['ForeColor'] = this.foreColor;
|
||||||
|
data['IsBuiltIn'] = this.isBuiltIn;
|
||||||
|
data['IsActive'] = this.isActive;
|
||||||
|
data['CreatedBy'] = this.createdBy;
|
||||||
|
data['CreatedOn'] = this.createdOn;
|
||||||
|
data['EditedBy'] = this.editedBy;
|
||||||
|
data['EditedOn'] = this.editedOn;
|
||||||
|
data['RowVer'] = this.rowVer;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,76 @@
|
|||||||
|
class DoctorResponse {
|
||||||
|
int projectID;
|
||||||
|
int transactionNo;
|
||||||
|
int patientID;
|
||||||
|
int doctorID;
|
||||||
|
int requestType;
|
||||||
|
String requestTypeDescription;
|
||||||
|
dynamic requestTypeDescriptionN;
|
||||||
|
int status;
|
||||||
|
String remarks;
|
||||||
|
String createdOn;
|
||||||
|
dynamic readStatus;
|
||||||
|
String doctorName;
|
||||||
|
bool isDoctorRespond;
|
||||||
|
bool isPatientRead;
|
||||||
|
List<dynamic> transactions;
|
||||||
|
|
||||||
|
DoctorResponse(
|
||||||
|
{this.projectID,
|
||||||
|
this.transactionNo,
|
||||||
|
this.patientID,
|
||||||
|
this.doctorID,
|
||||||
|
this.requestType,
|
||||||
|
this.requestTypeDescription,
|
||||||
|
this.requestTypeDescriptionN,
|
||||||
|
this.status,
|
||||||
|
this.remarks,
|
||||||
|
this.createdOn,
|
||||||
|
this.readStatus,
|
||||||
|
this.doctorName,
|
||||||
|
this.isDoctorRespond,
|
||||||
|
this.isPatientRead,
|
||||||
|
this.transactions});
|
||||||
|
|
||||||
|
DoctorResponse.fromJson(Map<String, dynamic> json) {
|
||||||
|
projectID = json['ProjectID'];
|
||||||
|
transactionNo = json['TransactionNo'];
|
||||||
|
patientID = json['PatientID'];
|
||||||
|
doctorID = json['DoctorID'];
|
||||||
|
requestType = json['RequestType'];
|
||||||
|
requestTypeDescription = json['RequestTypeDescription'];
|
||||||
|
requestTypeDescriptionN = json['RequestTypeDescriptionN'];
|
||||||
|
status = json['Status'];
|
||||||
|
remarks = json['Remarks'];
|
||||||
|
createdOn = json['CreatedOn'];
|
||||||
|
readStatus = json['ReadStatus'];
|
||||||
|
doctorName = json['DoctorName'];
|
||||||
|
isDoctorRespond = json['IsDoctorRespond'];
|
||||||
|
isPatientRead = json['IsPatientRead'];
|
||||||
|
if (json['Transactions'] != null) {
|
||||||
|
transactions = json['Transactions'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['ProjectID'] = this.projectID;
|
||||||
|
data['TransactionNo'] = this.transactionNo;
|
||||||
|
data['PatientID'] = this.patientID;
|
||||||
|
data['DoctorID'] = this.doctorID;
|
||||||
|
data['RequestType'] = this.requestType;
|
||||||
|
data['RequestTypeDescription'] = this.requestTypeDescription;
|
||||||
|
data['RequestTypeDescriptionN'] = this.requestTypeDescriptionN;
|
||||||
|
data['Status'] = this.status;
|
||||||
|
data['Remarks'] = this.remarks;
|
||||||
|
data['CreatedOn'] = this.createdOn;
|
||||||
|
data['ReadStatus'] = this.readStatus;
|
||||||
|
data['DoctorName'] = this.doctorName;
|
||||||
|
data['IsDoctorRespond'] = this.isDoctorRespond;
|
||||||
|
data['IsPatientRead'] = this.isPatientRead;
|
||||||
|
if (this.transactions != null) {
|
||||||
|
data['Transactions'] = this.transactions.map((v) => v.toJson()).toList();
|
||||||
|
}
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,497 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class AppoimentAllHistoryResultList {
|
||||||
|
String setupID;
|
||||||
|
int projectID;
|
||||||
|
int appointmentNo;
|
||||||
|
String appointmentDate;
|
||||||
|
Null appointmentDateN;
|
||||||
|
int appointmentType;
|
||||||
|
DateTime bookDate;
|
||||||
|
dynamic patientType;
|
||||||
|
int patientID;
|
||||||
|
dynamic clinicID;
|
||||||
|
int doctorID;
|
||||||
|
String endDate;
|
||||||
|
String startTime;
|
||||||
|
String endTime;
|
||||||
|
dynamic status;
|
||||||
|
dynamic visitType;
|
||||||
|
int visitFor;
|
||||||
|
int patientStatusType;
|
||||||
|
int companyID;
|
||||||
|
int bookedBy;
|
||||||
|
String bookedOn;
|
||||||
|
int confirmedBy;
|
||||||
|
String confirmedOn;
|
||||||
|
int arrivalChangedBy;
|
||||||
|
String arrivedOn;
|
||||||
|
Null editedBy;
|
||||||
|
Null editedOn;
|
||||||
|
Null doctorName;
|
||||||
|
Null doctorNameN;
|
||||||
|
String statusDesc;
|
||||||
|
Null statusDescN;
|
||||||
|
bool vitalStatus;
|
||||||
|
Null vitalSignAppointmentNo;
|
||||||
|
int episodeID;
|
||||||
|
int actualDoctorRate;
|
||||||
|
String clinicName;
|
||||||
|
bool complainExists;
|
||||||
|
String doctorImageURL;
|
||||||
|
String doctorNameObj;
|
||||||
|
int doctorRate;
|
||||||
|
List<String> doctorSpeciality;
|
||||||
|
String doctorTitle;
|
||||||
|
int gender;
|
||||||
|
String genderDescription;
|
||||||
|
bool iSAllowOnlineCheckedIN;
|
||||||
|
bool isActiveDoctor;
|
||||||
|
bool isActiveDoctorProfile;
|
||||||
|
bool isDoctorAllowVedioCall;
|
||||||
|
bool isExecludeDoctor;
|
||||||
|
int isFollowup;
|
||||||
|
bool isLiveCareAppointment;
|
||||||
|
bool isMedicalReportRequested;
|
||||||
|
bool isOnlineCheckedIN;
|
||||||
|
String latitude;
|
||||||
|
List<ListHISGetContactLensPerscription> listHISGetContactLensPerscription;
|
||||||
|
List<ListHISGetGlassPerscription> listHISGetGlassPerscription;
|
||||||
|
String longitude;
|
||||||
|
int nextAction;
|
||||||
|
int noOfPatientsRate;
|
||||||
|
int originalClinicID;
|
||||||
|
int originalProjectID;
|
||||||
|
String projectName;
|
||||||
|
String qR;
|
||||||
|
int remaniningHoursTocanPay;
|
||||||
|
bool sMSButtonVisable;
|
||||||
|
|
||||||
|
AppoimentAllHistoryResultList(
|
||||||
|
{this.setupID,
|
||||||
|
this.projectID,
|
||||||
|
this.appointmentNo,
|
||||||
|
this.appointmentDate,
|
||||||
|
this.appointmentDateN,
|
||||||
|
this.appointmentType,
|
||||||
|
this.bookDate,
|
||||||
|
this.patientID,
|
||||||
|
this.doctorID,
|
||||||
|
this.endDate,
|
||||||
|
this.startTime,
|
||||||
|
this.endTime,
|
||||||
|
this.status,
|
||||||
|
this.visitFor,
|
||||||
|
this.patientStatusType,
|
||||||
|
this.companyID,
|
||||||
|
this.bookedBy,
|
||||||
|
this.bookedOn,
|
||||||
|
this.confirmedBy,
|
||||||
|
this.confirmedOn,
|
||||||
|
this.arrivalChangedBy,
|
||||||
|
this.arrivedOn,
|
||||||
|
this.editedBy,
|
||||||
|
this.editedOn,
|
||||||
|
this.doctorName,
|
||||||
|
this.doctorNameN,
|
||||||
|
this.statusDesc,
|
||||||
|
this.statusDescN,
|
||||||
|
this.vitalStatus,
|
||||||
|
this.vitalSignAppointmentNo,
|
||||||
|
this.episodeID,
|
||||||
|
this.actualDoctorRate,
|
||||||
|
this.clinicName,
|
||||||
|
this.complainExists,
|
||||||
|
this.doctorImageURL,
|
||||||
|
this.doctorNameObj,
|
||||||
|
this.doctorRate,
|
||||||
|
this.doctorSpeciality,
|
||||||
|
this.doctorTitle,
|
||||||
|
this.gender,
|
||||||
|
this.genderDescription,
|
||||||
|
this.iSAllowOnlineCheckedIN,
|
||||||
|
this.isActiveDoctor,
|
||||||
|
this.isActiveDoctorProfile,
|
||||||
|
this.isDoctorAllowVedioCall,
|
||||||
|
this.isExecludeDoctor,
|
||||||
|
this.isFollowup,
|
||||||
|
this.isLiveCareAppointment,
|
||||||
|
this.isMedicalReportRequested,
|
||||||
|
this.isOnlineCheckedIN,
|
||||||
|
this.latitude,
|
||||||
|
this.listHISGetContactLensPerscription,
|
||||||
|
this.listHISGetGlassPerscription,
|
||||||
|
this.longitude,
|
||||||
|
this.nextAction,
|
||||||
|
this.noOfPatientsRate,
|
||||||
|
this.originalClinicID,
|
||||||
|
this.originalProjectID,
|
||||||
|
this.projectName,
|
||||||
|
this.qR,
|
||||||
|
this.remaniningHoursTocanPay,
|
||||||
|
this.sMSButtonVisable,
|
||||||
|
this.clinicID,
|
||||||
|
this.patientType,
|
||||||
|
|
||||||
|
this.visitType});
|
||||||
|
|
||||||
|
AppoimentAllHistoryResultList.fromJson(Map<String, dynamic> json) {
|
||||||
|
setupID = json['SetupID'];
|
||||||
|
projectID = json['ProjectID'];
|
||||||
|
appointmentNo = json['AppointmentNo'];
|
||||||
|
appointmentDate = json['AppointmentDate'];
|
||||||
|
appointmentDateN = json['AppointmentDateN'];
|
||||||
|
appointmentType = json['AppointmentType'];
|
||||||
|
bookDate = DateUtil.convertStringToDate(json['BookDate']);
|
||||||
|
patientType = json['PatientType'];
|
||||||
|
patientID = json['PatientID'];
|
||||||
|
clinicID = json['ClinicID'];
|
||||||
|
doctorID = json['DoctorID'];
|
||||||
|
endDate = json['EndDate'];
|
||||||
|
startTime = json['StartTime'];
|
||||||
|
endTime = json['EndTime'];
|
||||||
|
status = json['Status'];
|
||||||
|
visitType = json['VisitType'];
|
||||||
|
visitFor = json['VisitFor'];
|
||||||
|
patientStatusType = json['PatientStatusType'];
|
||||||
|
companyID = json['CompanyID'];
|
||||||
|
bookedBy = json['BookedBy'];
|
||||||
|
bookedOn = json['BookedOn'];
|
||||||
|
confirmedBy = json['ConfirmedBy'];
|
||||||
|
confirmedOn = json['ConfirmedOn'];
|
||||||
|
arrivalChangedBy = json['ArrivalChangedBy'];
|
||||||
|
arrivedOn = json['ArrivedOn'];
|
||||||
|
editedBy = json['EditedBy'];
|
||||||
|
editedOn = json['EditedOn'];
|
||||||
|
doctorName = json['DoctorName'];
|
||||||
|
doctorNameN = json['DoctorNameN'];
|
||||||
|
statusDesc = json['StatusDesc'];
|
||||||
|
statusDescN = json['StatusDescN'];
|
||||||
|
vitalStatus = json['VitalStatus'];
|
||||||
|
vitalSignAppointmentNo = json['VitalSignAppointmentNo'];
|
||||||
|
episodeID = json['EpisodeID'];
|
||||||
|
actualDoctorRate = json['ActualDoctorRate'];
|
||||||
|
clinicName = json['ClinicName'];
|
||||||
|
complainExists = json['ComplainExists'];
|
||||||
|
doctorImageURL = json['DoctorImageURL'];
|
||||||
|
doctorNameObj = json['DoctorNameObj'];
|
||||||
|
doctorRate = json['DoctorRate'];
|
||||||
|
// doctorSpeciality = json['DoctorSpeciality'].cast<String>();
|
||||||
|
doctorTitle = json['DoctorTitle'];
|
||||||
|
gender = json['Gender'];
|
||||||
|
genderDescription = json['GenderDescription'];
|
||||||
|
iSAllowOnlineCheckedIN = json['ISAllowOnlineCheckedIN'];
|
||||||
|
isActiveDoctor = json['IsActiveDoctor'];
|
||||||
|
isActiveDoctorProfile = json['IsActiveDoctorProfile'];
|
||||||
|
isDoctorAllowVedioCall = json['IsDoctorAllowVedioCall'];
|
||||||
|
isExecludeDoctor = json['IsExecludeDoctor'];
|
||||||
|
isFollowup = json['IsFollowup'];
|
||||||
|
isLiveCareAppointment = json['IsLiveCareAppointment'];
|
||||||
|
isMedicalReportRequested = json['IsMedicalReportRequested'];
|
||||||
|
isOnlineCheckedIN = json['IsOnlineCheckedIN'];
|
||||||
|
latitude = json['Latitude'];
|
||||||
|
if (json['List_HIS_GetContactLensPerscription'] != null) {
|
||||||
|
listHISGetContactLensPerscription =
|
||||||
|
new List<ListHISGetContactLensPerscription>();
|
||||||
|
json['List_HIS_GetContactLensPerscription'].forEach((v) {
|
||||||
|
listHISGetContactLensPerscription
|
||||||
|
.add(new ListHISGetContactLensPerscription.fromJson(v));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
if (json['List_HIS_GetGlassPerscription'] != null) {
|
||||||
|
listHISGetGlassPerscription = new List<ListHISGetGlassPerscription>();
|
||||||
|
json['List_HIS_GetGlassPerscription'].forEach((v) {
|
||||||
|
listHISGetGlassPerscription
|
||||||
|
.add(new ListHISGetGlassPerscription.fromJson(v));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
longitude = json['Longitude'];
|
||||||
|
nextAction = json['NextAction'];
|
||||||
|
noOfPatientsRate = json['NoOfPatientsRate'];
|
||||||
|
originalClinicID = json['OriginalClinicID'];
|
||||||
|
originalProjectID = json['OriginalProjectID'];
|
||||||
|
projectName = json['ProjectName'];
|
||||||
|
qR = json['QR'];
|
||||||
|
remaniningHoursTocanPay = json['RemaniningHoursTocanPay'];
|
||||||
|
sMSButtonVisable = json['SMSButtonVisable'];
|
||||||
|
clinicID = json['clinicID'];
|
||||||
|
patientType = json['patientType'];
|
||||||
|
status = json['status'];
|
||||||
|
visitType = json['visitType'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['SetupID'] = this.setupID;
|
||||||
|
data['ProjectID'] = this.projectID;
|
||||||
|
data['AppointmentNo'] = this.appointmentNo;
|
||||||
|
data['AppointmentDate'] = this.appointmentDate;
|
||||||
|
data['AppointmentDateN'] = this.appointmentDateN;
|
||||||
|
data['AppointmentType'] = this.appointmentType;
|
||||||
|
data['BookDate'] = this.bookDate;
|
||||||
|
data['PatientType'] = this.patientType;
|
||||||
|
data['PatientID'] = this.patientID;
|
||||||
|
data['ClinicID'] = this.clinicID;
|
||||||
|
data['DoctorID'] = this.doctorID;
|
||||||
|
data['EndDate'] = this.endDate;
|
||||||
|
data['StartTime'] = this.startTime;
|
||||||
|
data['EndTime'] = this.endTime;
|
||||||
|
data['Status'] = this.status;
|
||||||
|
data['VisitType'] = this.visitType;
|
||||||
|
data['VisitFor'] = this.visitFor;
|
||||||
|
data['PatientStatusType'] = this.patientStatusType;
|
||||||
|
data['CompanyID'] = this.companyID;
|
||||||
|
data['BookedBy'] = this.bookedBy;
|
||||||
|
data['BookedOn'] = this.bookedOn;
|
||||||
|
data['ConfirmedBy'] = this.confirmedBy;
|
||||||
|
data['ConfirmedOn'] = this.confirmedOn;
|
||||||
|
data['ArrivalChangedBy'] = this.arrivalChangedBy;
|
||||||
|
data['ArrivedOn'] = this.arrivedOn;
|
||||||
|
data['EditedBy'] = this.editedBy;
|
||||||
|
data['EditedOn'] = this.editedOn;
|
||||||
|
data['DoctorName'] = this.doctorName;
|
||||||
|
data['DoctorNameN'] = this.doctorNameN;
|
||||||
|
data['StatusDesc'] = this.statusDesc;
|
||||||
|
data['StatusDescN'] = this.statusDescN;
|
||||||
|
data['VitalStatus'] = this.vitalStatus;
|
||||||
|
data['VitalSignAppointmentNo'] = this.vitalSignAppointmentNo;
|
||||||
|
data['EpisodeID'] = this.episodeID;
|
||||||
|
data['ActualDoctorRate'] = this.actualDoctorRate;
|
||||||
|
data['ClinicName'] = this.clinicName;
|
||||||
|
data['ComplainExists'] = this.complainExists;
|
||||||
|
data['DoctorImageURL'] = this.doctorImageURL;
|
||||||
|
data['DoctorNameObj'] = this.doctorNameObj;
|
||||||
|
data['DoctorRate'] = this.doctorRate;
|
||||||
|
data['DoctorSpeciality'] = this.doctorSpeciality;
|
||||||
|
data['DoctorTitle'] = this.doctorTitle;
|
||||||
|
data['Gender'] = this.gender;
|
||||||
|
data['GenderDescription'] = this.genderDescription;
|
||||||
|
data['ISAllowOnlineCheckedIN'] = this.iSAllowOnlineCheckedIN;
|
||||||
|
data['IsActiveDoctor'] = this.isActiveDoctor;
|
||||||
|
data['IsActiveDoctorProfile'] = this.isActiveDoctorProfile;
|
||||||
|
data['IsDoctorAllowVedioCall'] = this.isDoctorAllowVedioCall;
|
||||||
|
data['IsExecludeDoctor'] = this.isExecludeDoctor;
|
||||||
|
data['IsFollowup'] = this.isFollowup;
|
||||||
|
data['IsLiveCareAppointment'] = this.isLiveCareAppointment;
|
||||||
|
data['IsMedicalReportRequested'] = this.isMedicalReportRequested;
|
||||||
|
data['IsOnlineCheckedIN'] = this.isOnlineCheckedIN;
|
||||||
|
data['Latitude'] = this.latitude;
|
||||||
|
if (this.listHISGetContactLensPerscription != null) {
|
||||||
|
data['List_HIS_GetContactLensPerscription'] = this
|
||||||
|
.listHISGetContactLensPerscription
|
||||||
|
.map((v) => v.toJson())
|
||||||
|
.toList();
|
||||||
|
}
|
||||||
|
if (this.listHISGetGlassPerscription != null) {
|
||||||
|
data['List_HIS_GetGlassPerscription'] =
|
||||||
|
this.listHISGetGlassPerscription.map((v) => v.toJson()).toList();
|
||||||
|
}
|
||||||
|
data['Longitude'] = this.longitude;
|
||||||
|
data['NextAction'] = this.nextAction;
|
||||||
|
data['NoOfPatientsRate'] = this.noOfPatientsRate;
|
||||||
|
data['OriginalClinicID'] = this.originalClinicID;
|
||||||
|
data['OriginalProjectID'] = this.originalProjectID;
|
||||||
|
data['ProjectName'] = this.projectName;
|
||||||
|
data['QR'] = this.qR;
|
||||||
|
data['RemaniningHoursTocanPay'] = this.remaniningHoursTocanPay;
|
||||||
|
data['SMSButtonVisable'] = this.sMSButtonVisable;
|
||||||
|
data['clinicID'] = this.clinicID;
|
||||||
|
data['patientType'] = this.patientType;
|
||||||
|
data['status'] = this.status;
|
||||||
|
data['visitType'] = this.visitType;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
class ListHISGetContactLensPerscription {
|
||||||
|
String setupId;
|
||||||
|
int projectId;
|
||||||
|
int patientType;
|
||||||
|
int patientId;
|
||||||
|
int encounterType;
|
||||||
|
int encounterNo;
|
||||||
|
int oDOS;
|
||||||
|
dynamic brand;
|
||||||
|
dynamic baseCurve;
|
||||||
|
dynamic power;
|
||||||
|
dynamic diameter;
|
||||||
|
dynamic oZ;
|
||||||
|
dynamic cT;
|
||||||
|
dynamic blend;
|
||||||
|
String remarks;
|
||||||
|
int status;
|
||||||
|
bool isActive;
|
||||||
|
String createdOn;
|
||||||
|
|
||||||
|
ListHISGetContactLensPerscription(
|
||||||
|
{this.setupId,
|
||||||
|
this.projectId,
|
||||||
|
this.patientType,
|
||||||
|
this.patientId,
|
||||||
|
this.encounterType,
|
||||||
|
this.encounterNo,
|
||||||
|
this.oDOS,
|
||||||
|
this.brand,
|
||||||
|
this.baseCurve,
|
||||||
|
this.power,
|
||||||
|
this.diameter,
|
||||||
|
this.oZ,
|
||||||
|
this.cT,
|
||||||
|
this.blend,
|
||||||
|
this.remarks,
|
||||||
|
this.status,
|
||||||
|
this.isActive,
|
||||||
|
this.createdOn});
|
||||||
|
|
||||||
|
ListHISGetContactLensPerscription.fromJson(Map<String, dynamic> json) {
|
||||||
|
setupId = json['SetupId'];
|
||||||
|
projectId = json['ProjectId'];
|
||||||
|
patientType = json['PatientType'];
|
||||||
|
patientId = json['PatientId'];
|
||||||
|
encounterType = json['EncounterType'];
|
||||||
|
encounterNo = json['EncounterNo'];
|
||||||
|
oDOS = json['OD_OS'];
|
||||||
|
brand = json['Brand'];
|
||||||
|
baseCurve = json['BaseCurve'];
|
||||||
|
power = json['Power'];
|
||||||
|
diameter = json['Diameter'];
|
||||||
|
oZ = json['OZ'];
|
||||||
|
cT = json['CT'];
|
||||||
|
blend = json['Blend'];
|
||||||
|
remarks = json['Remarks'];
|
||||||
|
status = json['Status'];
|
||||||
|
isActive = json['IsActive'];
|
||||||
|
createdOn = json['CreatedOn'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['SetupId'] = this.setupId;
|
||||||
|
data['ProjectId'] = this.projectId;
|
||||||
|
data['PatientType'] = this.patientType;
|
||||||
|
data['PatientId'] = this.patientId;
|
||||||
|
data['EncounterType'] = this.encounterType;
|
||||||
|
data['EncounterNo'] = this.encounterNo;
|
||||||
|
data['OD_OS'] = this.oDOS;
|
||||||
|
data['Brand'] = this.brand;
|
||||||
|
data['BaseCurve'] = this.baseCurve;
|
||||||
|
data['Power'] = this.power;
|
||||||
|
data['Diameter'] = this.diameter;
|
||||||
|
data['OZ'] = this.oZ;
|
||||||
|
data['CT'] = this.cT;
|
||||||
|
data['Blend'] = this.blend;
|
||||||
|
data['Remarks'] = this.remarks;
|
||||||
|
data['Status'] = this.status;
|
||||||
|
data['IsActive'] = this.isActive;
|
||||||
|
data['CreatedOn'] = this.createdOn;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
class ListHISGetGlassPerscription {
|
||||||
|
dynamic projectID;
|
||||||
|
String setupID;
|
||||||
|
dynamic patientId;
|
||||||
|
dynamic encounterType;
|
||||||
|
dynamic encounterNo;
|
||||||
|
String visionType;
|
||||||
|
double rightEyeSpherical;
|
||||||
|
dynamic rightEyeCylinder;
|
||||||
|
dynamic rightEyeAxis;
|
||||||
|
dynamic rightEyePrism;
|
||||||
|
dynamic rightEyeVA;
|
||||||
|
String rightEyeRemarks;
|
||||||
|
dynamic leftEyeSpherical;
|
||||||
|
dynamic leftEyeCylinder;
|
||||||
|
dynamic leftEyeAxis;
|
||||||
|
dynamic leftEyePrism;
|
||||||
|
dynamic leftEyeVA;
|
||||||
|
String leftEyeRemarks;
|
||||||
|
dynamic pD;
|
||||||
|
dynamic bVD;
|
||||||
|
dynamic status;
|
||||||
|
bool isActive;
|
||||||
|
String createdOn;
|
||||||
|
|
||||||
|
ListHISGetGlassPerscription(
|
||||||
|
{this.projectID,
|
||||||
|
this.setupID,
|
||||||
|
this.patientId,
|
||||||
|
this.encounterType,
|
||||||
|
this.encounterNo,
|
||||||
|
this.visionType,
|
||||||
|
this.rightEyeSpherical,
|
||||||
|
this.rightEyeCylinder,
|
||||||
|
this.rightEyeAxis,
|
||||||
|
this.rightEyePrism,
|
||||||
|
this.rightEyeVA,
|
||||||
|
this.rightEyeRemarks,
|
||||||
|
this.leftEyeSpherical,
|
||||||
|
this.leftEyeCylinder,
|
||||||
|
this.leftEyeAxis,
|
||||||
|
this.leftEyePrism,
|
||||||
|
this.leftEyeVA,
|
||||||
|
this.leftEyeRemarks,
|
||||||
|
this.pD,
|
||||||
|
this.bVD,
|
||||||
|
this.status,
|
||||||
|
this.isActive,
|
||||||
|
this.createdOn});
|
||||||
|
|
||||||
|
ListHISGetGlassPerscription.fromJson(Map<String, dynamic> json) {
|
||||||
|
projectID = json['ProjectID'];
|
||||||
|
setupID = json['SetupID'];
|
||||||
|
patientId = json['PatientId'];
|
||||||
|
encounterType = json['EncounterType'];
|
||||||
|
encounterNo = json['EncounterNo'];
|
||||||
|
visionType = json['VisionType'];
|
||||||
|
rightEyeSpherical = json['RightEyeSpherical'];
|
||||||
|
rightEyeCylinder = json['RightEyeCylinder'];
|
||||||
|
rightEyeAxis = json['RightEyeAxis'];
|
||||||
|
rightEyePrism = json['RightEyePrism'];
|
||||||
|
rightEyeVA = json['RightEyeVA'];
|
||||||
|
rightEyeRemarks = json['RightEyeRemarks'];
|
||||||
|
leftEyeSpherical = json['LeftEyeSpherical'];
|
||||||
|
leftEyeCylinder = json['LeftEyeCylinder'];
|
||||||
|
leftEyeAxis = json['LeftEyeAxis'];
|
||||||
|
leftEyePrism = json['LeftEyePrism'];
|
||||||
|
leftEyeVA = json['LeftEyeVA'];
|
||||||
|
leftEyeRemarks = json['LeftEyeRemarks'];
|
||||||
|
pD = json['PD'];
|
||||||
|
bVD = json['BVD'];
|
||||||
|
status = json['Status'];
|
||||||
|
isActive = json['IsActive'];
|
||||||
|
createdOn = json['CreatedOn'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['ProjectID'] = this.projectID;
|
||||||
|
data['SetupID'] = this.setupID;
|
||||||
|
data['PatientId'] = this.patientId;
|
||||||
|
data['EncounterType'] = this.encounterType;
|
||||||
|
data['EncounterNo'] = this.encounterNo;
|
||||||
|
data['VisionType'] = this.visionType;
|
||||||
|
data['RightEyeSpherical'] = this.rightEyeSpherical;
|
||||||
|
data['RightEyeCylinder'] = this.rightEyeCylinder;
|
||||||
|
data['RightEyeAxis'] = this.rightEyeAxis;
|
||||||
|
data['RightEyePrism'] = this.rightEyePrism;
|
||||||
|
data['RightEyeVA'] = this.rightEyeVA;
|
||||||
|
data['RightEyeRemarks'] = this.rightEyeRemarks;
|
||||||
|
data['LeftEyeSpherical'] = this.leftEyeSpherical;
|
||||||
|
data['LeftEyeCylinder'] = this.leftEyeCylinder;
|
||||||
|
data['LeftEyeAxis'] = this.leftEyeAxis;
|
||||||
|
data['LeftEyePrism'] = this.leftEyePrism;
|
||||||
|
data['LeftEyeVA'] = this.leftEyeVA;
|
||||||
|
data['LeftEyeRemarks'] = this.leftEyeRemarks;
|
||||||
|
data['PD'] = this.pD;
|
||||||
|
data['BVD'] = this.bVD;
|
||||||
|
data['Status'] = this.status;
|
||||||
|
data['IsActive'] = this.isActive;
|
||||||
|
data['CreatedOn'] = this.createdOn;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -0,0 +1,12 @@
|
|||||||
|
import 'AppoimentAllHistoryResult.dart';
|
||||||
|
|
||||||
|
class AppointmentFilter {
|
||||||
|
List<AppoimentAllHistoryResultList> appointmentAllHistoryResultList = List();
|
||||||
|
String filterName;
|
||||||
|
|
||||||
|
AppointmentFilter(
|
||||||
|
AppoimentAllHistoryResultList allHistoryResultList, String filterName) {
|
||||||
|
appointmentAllHistoryResultList.add(allHistoryResultList);
|
||||||
|
this.filterName = filterName;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,90 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class BloodPressureResult {
|
||||||
|
int patientID;
|
||||||
|
int lineItemNo;
|
||||||
|
DateTime bloodPressureDate;
|
||||||
|
int measuredArm;
|
||||||
|
int systolicePressure;
|
||||||
|
int diastolicPressure;
|
||||||
|
dynamic remark;
|
||||||
|
bool isActive;
|
||||||
|
int chartYear;
|
||||||
|
String chartMonth;
|
||||||
|
dynamic yearSystolicePressureAverageResult;
|
||||||
|
dynamic monthSystolicePressureResult;
|
||||||
|
dynamic weekSystolicePressureResult;
|
||||||
|
int yearDiastolicPressureAverageResult;
|
||||||
|
dynamic monthDiastolicPressureResult;
|
||||||
|
dynamic weekDiastolicPressureResult;
|
||||||
|
String measuredArmDesc;
|
||||||
|
dynamic weekDesc;
|
||||||
|
|
||||||
|
BloodPressureResult(
|
||||||
|
{this.patientID,
|
||||||
|
this.lineItemNo,
|
||||||
|
this.bloodPressureDate,
|
||||||
|
this.measuredArm,
|
||||||
|
this.systolicePressure,
|
||||||
|
this.diastolicPressure,
|
||||||
|
this.remark,
|
||||||
|
this.isActive,
|
||||||
|
this.chartYear,
|
||||||
|
this.chartMonth,
|
||||||
|
this.yearSystolicePressureAverageResult,
|
||||||
|
this.monthSystolicePressureResult,
|
||||||
|
this.weekSystolicePressureResult,
|
||||||
|
this.yearDiastolicPressureAverageResult,
|
||||||
|
this.monthDiastolicPressureResult,
|
||||||
|
this.weekDiastolicPressureResult,
|
||||||
|
this.measuredArmDesc,
|
||||||
|
this.weekDesc});
|
||||||
|
|
||||||
|
BloodPressureResult.fromJson(Map<String, dynamic> json) {
|
||||||
|
patientID = json['PatientID'];
|
||||||
|
lineItemNo = json['LineItemNo'];
|
||||||
|
bloodPressureDate =DateUtil.convertStringToDate(json['BloodPressureDate']);
|
||||||
|
measuredArm = json['MeasuredArm'];
|
||||||
|
systolicePressure = json['SystolicePressure'];
|
||||||
|
diastolicPressure = json['DiastolicPressure'];
|
||||||
|
remark = json['Remark'];
|
||||||
|
isActive = json['IsActive'];
|
||||||
|
chartYear = json['ChartYear'];
|
||||||
|
chartMonth = json['ChartMonth'];
|
||||||
|
yearSystolicePressureAverageResult =
|
||||||
|
json['YearSystolicePressureAverageResult'];
|
||||||
|
monthSystolicePressureResult = json['MonthSystolicePressureResult'];
|
||||||
|
weekSystolicePressureResult = json['WeekSystolicePressureResult'];
|
||||||
|
yearDiastolicPressureAverageResult =
|
||||||
|
json['YearDiastolicPressureAverageResult'];
|
||||||
|
monthDiastolicPressureResult = json['MonthDiastolicPressureResult'];
|
||||||
|
weekDiastolicPressureResult = json['WeekDiastolicPressureResult'];
|
||||||
|
measuredArmDesc = json['MeasuredArmDesc'];
|
||||||
|
weekDesc = json['WeekDesc'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['PatientID'] = this.patientID;
|
||||||
|
data['LineItemNo'] = this.lineItemNo;
|
||||||
|
data['BloodPressureDate'] = this.bloodPressureDate;
|
||||||
|
data['MeasuredArm'] = this.measuredArm;
|
||||||
|
data['SystolicePressure'] = this.systolicePressure;
|
||||||
|
data['DiastolicPressure'] = this.diastolicPressure;
|
||||||
|
data['Remark'] = this.remark;
|
||||||
|
data['IsActive'] = this.isActive;
|
||||||
|
data['ChartYear'] = this.chartYear;
|
||||||
|
data['ChartMonth'] = this.chartMonth;
|
||||||
|
data['YearSystolicePressureAverageResult'] =
|
||||||
|
this.yearSystolicePressureAverageResult;
|
||||||
|
data['MonthSystolicePressureResult'] = this.monthSystolicePressureResult;
|
||||||
|
data['WeekSystolicePressureResult'] = this.weekSystolicePressureResult;
|
||||||
|
data['YearDiastolicPressureAverageResult'] =
|
||||||
|
this.yearDiastolicPressureAverageResult;
|
||||||
|
data['MonthDiastolicPressureResult'] = this.monthDiastolicPressureResult;
|
||||||
|
data['WeekDiastolicPressureResult'] = this.weekDiastolicPressureResult;
|
||||||
|
data['MeasuredArmDesc'] = this.measuredArmDesc;
|
||||||
|
data['WeekDesc'] = this.weekDesc;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,76 @@
|
|||||||
|
class MonthBloodPressureResultAverage {
|
||||||
|
dynamic weekfourSystolicePressureAverageResult;
|
||||||
|
dynamic weekfourDiastolicPressureAverageResult;
|
||||||
|
dynamic weekthreeSystolicePressureAverageResult;
|
||||||
|
dynamic weekthreeDiastolicPressureAverageResult;
|
||||||
|
dynamic weektwoSystolicePressureAverageResult;
|
||||||
|
dynamic weektwoDiastolicPressureAverageResult;
|
||||||
|
dynamic weekoneSystolicePressureAverageResult;
|
||||||
|
dynamic weekoneDiastolicPressureAverageResult;
|
||||||
|
String weekDesc;
|
||||||
|
int weekDiastolicPressureAverageResult;
|
||||||
|
int weekSystolicePressureAverageResult;
|
||||||
|
|
||||||
|
MonthBloodPressureResultAverage(
|
||||||
|
{this.weekfourSystolicePressureAverageResult,
|
||||||
|
this.weekfourDiastolicPressureAverageResult,
|
||||||
|
this.weekthreeSystolicePressureAverageResult,
|
||||||
|
this.weekthreeDiastolicPressureAverageResult,
|
||||||
|
this.weektwoSystolicePressureAverageResult,
|
||||||
|
this.weektwoDiastolicPressureAverageResult,
|
||||||
|
this.weekoneSystolicePressureAverageResult,
|
||||||
|
this.weekoneDiastolicPressureAverageResult,
|
||||||
|
this.weekDesc,
|
||||||
|
this.weekDiastolicPressureAverageResult,
|
||||||
|
this.weekSystolicePressureAverageResult});
|
||||||
|
|
||||||
|
MonthBloodPressureResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
weekfourSystolicePressureAverageResult =
|
||||||
|
json['weekfourSystolicePressureAverageResult'];
|
||||||
|
weekfourDiastolicPressureAverageResult =
|
||||||
|
json['weekfourDiastolicPressureAverageResult'];
|
||||||
|
weekthreeSystolicePressureAverageResult =
|
||||||
|
json['weekthreeSystolicePressureAverageResult'];
|
||||||
|
weekthreeDiastolicPressureAverageResult =
|
||||||
|
json['weekthreeDiastolicPressureAverageResult'];
|
||||||
|
weektwoSystolicePressureAverageResult =
|
||||||
|
json['weektwoSystolicePressureAverageResult'];
|
||||||
|
weektwoDiastolicPressureAverageResult =
|
||||||
|
json['weektwoDiastolicPressureAverageResult'];
|
||||||
|
weekoneSystolicePressureAverageResult =
|
||||||
|
json['weekoneSystolicePressureAverageResult'];
|
||||||
|
weekoneDiastolicPressureAverageResult =
|
||||||
|
json['weekoneDiastolicPressureAverageResult'];
|
||||||
|
weekDesc = json['WeekDesc'];
|
||||||
|
weekDiastolicPressureAverageResult =
|
||||||
|
json['WeekDiastolicPressureAverageResult'];
|
||||||
|
weekSystolicePressureAverageResult =
|
||||||
|
json['WeekSystolicePressureAverageResult'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['weekfourSystolicePressureAverageResult'] =
|
||||||
|
this.weekfourSystolicePressureAverageResult;
|
||||||
|
data['weekfourDiastolicPressureAverageResult'] =
|
||||||
|
this.weekfourDiastolicPressureAverageResult;
|
||||||
|
data['weekthreeSystolicePressureAverageResult'] =
|
||||||
|
this.weekthreeSystolicePressureAverageResult;
|
||||||
|
data['weekthreeDiastolicPressureAverageResult'] =
|
||||||
|
this.weekthreeDiastolicPressureAverageResult;
|
||||||
|
data['weektwoSystolicePressureAverageResult'] =
|
||||||
|
this.weektwoSystolicePressureAverageResult;
|
||||||
|
data['weektwoDiastolicPressureAverageResult'] =
|
||||||
|
this.weektwoDiastolicPressureAverageResult;
|
||||||
|
data['weekoneSystolicePressureAverageResult'] =
|
||||||
|
this.weekoneSystolicePressureAverageResult;
|
||||||
|
data['weekoneDiastolicPressureAverageResult'] =
|
||||||
|
this.weekoneDiastolicPressureAverageResult;
|
||||||
|
data['WeekDesc'] = this.weekDesc;
|
||||||
|
data['WeekDiastolicPressureAverageResult'] =
|
||||||
|
this.weekDiastolicPressureAverageResult;
|
||||||
|
data['WeekSystolicePressureAverageResult'] =
|
||||||
|
this.weekSystolicePressureAverageResult;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,30 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class WeekBloodPressureResultAverage {
|
||||||
|
int dailySystolicePressureAverageResult;
|
||||||
|
int dailyDiastolicPressureAverageResult;
|
||||||
|
DateTime bloodPressureDate;
|
||||||
|
|
||||||
|
WeekBloodPressureResultAverage(
|
||||||
|
{this.dailySystolicePressureAverageResult,
|
||||||
|
this.dailyDiastolicPressureAverageResult,
|
||||||
|
this.bloodPressureDate});
|
||||||
|
|
||||||
|
WeekBloodPressureResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
dailySystolicePressureAverageResult =
|
||||||
|
json['DailySystolicePressureAverageResult'];
|
||||||
|
dailyDiastolicPressureAverageResult =
|
||||||
|
json['DailyDiastolicPressureAverageResult'];
|
||||||
|
bloodPressureDate = DateUtil.convertStringToDate(json['BloodPressureDate']);
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['DailySystolicePressureAverageResult'] =
|
||||||
|
this.dailySystolicePressureAverageResult;
|
||||||
|
data['DailyDiastolicPressureAverageResult'] =
|
||||||
|
this.dailyDiastolicPressureAverageResult;
|
||||||
|
data['BloodPressureDate'] = this.bloodPressureDate;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,41 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class YearBloodPressureResultAverage {
|
||||||
|
int monthSystolicePressureAverageResult;
|
||||||
|
int monthDiastolicPressureAverageResult;
|
||||||
|
dynamic monthNumber;
|
||||||
|
String monthName;
|
||||||
|
String yearName;
|
||||||
|
DateTime date;
|
||||||
|
|
||||||
|
YearBloodPressureResultAverage(
|
||||||
|
{this.monthSystolicePressureAverageResult,
|
||||||
|
this.monthDiastolicPressureAverageResult,
|
||||||
|
this.monthNumber,
|
||||||
|
this.monthName,
|
||||||
|
this.yearName});
|
||||||
|
|
||||||
|
YearBloodPressureResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
monthSystolicePressureAverageResult =
|
||||||
|
json['monthSystolicePressureAverageResult'];
|
||||||
|
monthDiastolicPressureAverageResult =
|
||||||
|
json['monthDiastolicPressureAverageResult'];
|
||||||
|
monthNumber = json['monthNumber'];
|
||||||
|
monthName = json['monthName'];
|
||||||
|
yearName = json['yearName'];
|
||||||
|
date = DateUtil.getMonthDateTime(monthName,yearName);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['monthSystolicePressureAverageResult'] =
|
||||||
|
this.monthSystolicePressureAverageResult;
|
||||||
|
data['monthDiastolicPressureAverageResult'] =
|
||||||
|
this.monthDiastolicPressureAverageResult;
|
||||||
|
data['monthNumber'] = this.monthNumber;
|
||||||
|
data['monthName'] = this.monthName;
|
||||||
|
data['yearName'] = this.yearName;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,98 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class DiabtecPatientResult {
|
||||||
|
String chartMonth;
|
||||||
|
var chartYear;
|
||||||
|
DateTime dateChart;
|
||||||
|
var description;
|
||||||
|
var descriptionN;
|
||||||
|
int diabtecAvarage;
|
||||||
|
bool isActive;
|
||||||
|
int lineItemNo;
|
||||||
|
var listMonth;
|
||||||
|
var listWeek;
|
||||||
|
int measured;
|
||||||
|
String measuredDesc;
|
||||||
|
var monthAverageResult;
|
||||||
|
int patientID;
|
||||||
|
var remark;
|
||||||
|
var resultDesc;
|
||||||
|
int resultValue;
|
||||||
|
String unit;
|
||||||
|
var weekAverageResult;
|
||||||
|
String weekDesc;
|
||||||
|
var yearAverageResult;
|
||||||
|
|
||||||
|
DiabtecPatientResult(
|
||||||
|
{this.chartMonth,
|
||||||
|
this.chartYear,
|
||||||
|
this.dateChart,
|
||||||
|
this.description,
|
||||||
|
this.descriptionN,
|
||||||
|
this.diabtecAvarage,
|
||||||
|
this.isActive,
|
||||||
|
this.lineItemNo,
|
||||||
|
this.listMonth,
|
||||||
|
this.listWeek,
|
||||||
|
this.measured,
|
||||||
|
this.measuredDesc,
|
||||||
|
this.monthAverageResult,
|
||||||
|
this.patientID,
|
||||||
|
this.remark,
|
||||||
|
this.resultDesc,
|
||||||
|
this.resultValue,
|
||||||
|
this.unit,
|
||||||
|
this.weekAverageResult,
|
||||||
|
this.weekDesc,
|
||||||
|
this.yearAverageResult});
|
||||||
|
|
||||||
|
DiabtecPatientResult.fromJson(Map<String, dynamic> json) {
|
||||||
|
chartMonth = json['ChartMonth'];
|
||||||
|
chartYear = json['ChartYear'];
|
||||||
|
dateChart = DateUtil.convertStringToDate(json['DateChart']);
|
||||||
|
description = json['Description'];
|
||||||
|
descriptionN = json['DescriptionN'];
|
||||||
|
diabtecAvarage = json['DiabtecAvarage'];
|
||||||
|
isActive = json['IsActive'];
|
||||||
|
lineItemNo = json['LineItemNo'];
|
||||||
|
listMonth = json['List_Month'];
|
||||||
|
listWeek = json['List_Week'];
|
||||||
|
measured = json['Measured'];
|
||||||
|
measuredDesc = json['MeasuredDesc'];
|
||||||
|
monthAverageResult = json['MonthAverageResult'];
|
||||||
|
patientID = json['PatientID'];
|
||||||
|
remark = json['Remark'];
|
||||||
|
resultDesc = json['ResultDesc'];
|
||||||
|
resultValue = json['ResultValue'];
|
||||||
|
unit = json['Unit'];
|
||||||
|
weekAverageResult = json['WeekAverageResult'];
|
||||||
|
weekDesc = json['WeekDesc'];
|
||||||
|
yearAverageResult = json['YearAverageResult'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['ChartMonth'] = this.chartMonth;
|
||||||
|
data['ChartYear'] = this.chartYear;
|
||||||
|
data['DateChart'] = DateUtil.convertDateToString(this.dateChart);
|
||||||
|
data['Description'] = this.description;
|
||||||
|
data['DescriptionN'] = this.descriptionN;
|
||||||
|
data['DiabtecAvarage'] = this.diabtecAvarage;
|
||||||
|
data['IsActive'] = this.isActive;
|
||||||
|
data['LineItemNo'] = this.lineItemNo;
|
||||||
|
data['List_Month'] = this.listMonth;
|
||||||
|
data['List_Week'] = this.listWeek;
|
||||||
|
data['Measured'] = this.measured;
|
||||||
|
data['MeasuredDesc'] = this.measuredDesc;
|
||||||
|
data['MonthAverageResult'] = this.monthAverageResult;
|
||||||
|
data['PatientID'] = this.patientID;
|
||||||
|
data['Remark'] = this.remark;
|
||||||
|
data['ResultDesc'] = this.resultDesc;
|
||||||
|
data['ResultValue'] = this.resultValue;
|
||||||
|
data['Unit'] = this.unit;
|
||||||
|
data['WeekAverageResult'] = this.weekAverageResult;
|
||||||
|
data['WeekDesc'] = this.weekDesc;
|
||||||
|
data['YearAverageResult'] = this.yearAverageResult;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,36 @@
|
|||||||
|
class MonthDiabtectResultAverage {
|
||||||
|
var weekfourAverageResult;
|
||||||
|
var weekthreeAverageResult;
|
||||||
|
var weektwoAverageResult;
|
||||||
|
var weekoneAverageResult;
|
||||||
|
dynamic weekAverageResult;
|
||||||
|
String weekDesc;
|
||||||
|
|
||||||
|
MonthDiabtectResultAverage(
|
||||||
|
{this.weekfourAverageResult,
|
||||||
|
this.weekthreeAverageResult,
|
||||||
|
this.weektwoAverageResult,
|
||||||
|
this.weekoneAverageResult,
|
||||||
|
this.weekAverageResult,
|
||||||
|
this.weekDesc});
|
||||||
|
|
||||||
|
MonthDiabtectResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
weekfourAverageResult = json['weekfourAverageResult'];
|
||||||
|
weekthreeAverageResult = json['weekthreeAverageResult'];
|
||||||
|
weektwoAverageResult = json['weektwoAverageResult'];
|
||||||
|
weekoneAverageResult = json['weekoneAverageResult'];
|
||||||
|
weekAverageResult = json['WeekAverageResult'];
|
||||||
|
weekDesc = json['WeekDesc'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['weekfourAverageResult'] = this.weekfourAverageResult;
|
||||||
|
data['weekthreeAverageResult'] = this.weekthreeAverageResult;
|
||||||
|
data['weektwoAverageResult'] = this.weektwoAverageResult;
|
||||||
|
data['weekoneAverageResult'] = this.weekoneAverageResult;
|
||||||
|
data['WeekAverageResult'] = this.weekAverageResult;
|
||||||
|
data['WeekDesc'] = this.weekDesc;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,20 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class WeekDiabtectResultAverage {
|
||||||
|
int dailyAverageResult;
|
||||||
|
DateTime dateChart;
|
||||||
|
|
||||||
|
WeekDiabtectResultAverage({this.dailyAverageResult, this.dateChart});
|
||||||
|
|
||||||
|
WeekDiabtectResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
dailyAverageResult = json['DailyAverageResult'];
|
||||||
|
dateChart = DateUtil.convertStringToDate(json['DateChart']);
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['DailyAverageResult'] = this.dailyAverageResult;
|
||||||
|
data['DateChart'] = DateUtil.convertDateToString(this.dateChart);
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,36 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class YearDiabtecResultAverage {
|
||||||
|
dynamic monthAverageResult;
|
||||||
|
var monthNumber;
|
||||||
|
String monthName;
|
||||||
|
String yearName;
|
||||||
|
DateTime date;
|
||||||
|
|
||||||
|
YearDiabtecResultAverage(
|
||||||
|
{this.monthAverageResult,
|
||||||
|
this.monthNumber,
|
||||||
|
this.monthName,
|
||||||
|
this.yearName});
|
||||||
|
|
||||||
|
YearDiabtecResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
try {
|
||||||
|
monthAverageResult = json['monthAverageResult'];
|
||||||
|
monthNumber = json['monthNumber'];
|
||||||
|
monthName = json['monthName'];
|
||||||
|
yearName = json['yearName'];
|
||||||
|
date = DateUtil.getMonthDateTime(monthName,yearName);
|
||||||
|
} catch (e) {
|
||||||
|
print(e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['monthAverageResult'] = this.monthAverageResult;
|
||||||
|
data['monthNumber'] = this.monthNumber;
|
||||||
|
data['monthName'] = this.monthName;
|
||||||
|
data['yearName'] = this.yearName;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,6 @@
|
|||||||
|
class WeekChartDate {
|
||||||
|
final DateTime x;
|
||||||
|
final dynamic y;
|
||||||
|
|
||||||
|
WeekChartDate({this.x, this.y});
|
||||||
|
}
|
||||||
@ -0,0 +1,6 @@
|
|||||||
|
class YearMonthlyChartDate {
|
||||||
|
final dynamic x;
|
||||||
|
final dynamic y;
|
||||||
|
|
||||||
|
YearMonthlyChartDate({this.x, this.y});
|
||||||
|
}
|
||||||
@ -0,0 +1,36 @@
|
|||||||
|
class MonthWeightMeasurementResultAverage {
|
||||||
|
dynamic weekfourAverageResult;
|
||||||
|
dynamic weekthreeAverageResult;
|
||||||
|
dynamic weektwoAverageResult;
|
||||||
|
dynamic weekoneAverageResult;
|
||||||
|
dynamic weekAverageResult;
|
||||||
|
String weekDesc;
|
||||||
|
|
||||||
|
MonthWeightMeasurementResultAverage(
|
||||||
|
{this.weekfourAverageResult,
|
||||||
|
this.weekthreeAverageResult,
|
||||||
|
this.weektwoAverageResult,
|
||||||
|
this.weekoneAverageResult,
|
||||||
|
this.weekAverageResult,
|
||||||
|
this.weekDesc});
|
||||||
|
|
||||||
|
MonthWeightMeasurementResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
weekfourAverageResult = json['weekfourAverageResult'];
|
||||||
|
weekthreeAverageResult = json['weekthreeAverageResult'];
|
||||||
|
weektwoAverageResult = json['weektwoAverageResult'];
|
||||||
|
weekoneAverageResult = json['weekoneAverageResult'];
|
||||||
|
weekAverageResult = json['WeekAverageResult'];
|
||||||
|
weekDesc = json['WeekDesc'];
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['weekfourAverageResult'] = this.weekfourAverageResult;
|
||||||
|
data['weekthreeAverageResult'] = this.weekthreeAverageResult;
|
||||||
|
data['weektwoAverageResult'] = this.weektwoAverageResult;
|
||||||
|
data['weekoneAverageResult'] = this.weekoneAverageResult;
|
||||||
|
data['WeekAverageResult'] = this.weekAverageResult;
|
||||||
|
data['WeekDesc'] = this.weekDesc;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,21 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class WeekWeightMeasurementResultAverage {
|
||||||
|
dynamic dailyAverageResult;
|
||||||
|
DateTime weightDate;
|
||||||
|
|
||||||
|
WeekWeightMeasurementResultAverage(
|
||||||
|
{this.dailyAverageResult, this.weightDate});
|
||||||
|
|
||||||
|
WeekWeightMeasurementResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
dailyAverageResult = json['DailyAverageResult'];
|
||||||
|
weightDate = DateUtil.convertStringToDate(json['WeightDate']);
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['DailyAverageResult'] = this.dailyAverageResult;
|
||||||
|
data['WeightDate'] = this.weightDate;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,74 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class WeightMeasurementResult {
|
||||||
|
int patientID;
|
||||||
|
int lineItemNo;
|
||||||
|
int weightMeasured;
|
||||||
|
DateTime weightDate;
|
||||||
|
dynamic remark;
|
||||||
|
bool isActive;
|
||||||
|
int measured;
|
||||||
|
dynamic unit;
|
||||||
|
int chartYear;
|
||||||
|
dynamic chartMonth;
|
||||||
|
double yearAverageResult;
|
||||||
|
dynamic monthAverageResult;
|
||||||
|
dynamic weekAverageResult;
|
||||||
|
dynamic weekDesc;
|
||||||
|
|
||||||
|
WeightMeasurementResult(
|
||||||
|
{this.patientID,
|
||||||
|
this.lineItemNo,
|
||||||
|
this.weightMeasured,
|
||||||
|
this.weightDate,
|
||||||
|
this.remark,
|
||||||
|
this.isActive,
|
||||||
|
this.measured,
|
||||||
|
this.unit,
|
||||||
|
this.chartYear,
|
||||||
|
this.chartMonth,
|
||||||
|
this.yearAverageResult,
|
||||||
|
this.monthAverageResult,
|
||||||
|
this.weekAverageResult,
|
||||||
|
this.weekDesc});
|
||||||
|
|
||||||
|
WeightMeasurementResult.fromJson(Map<String, dynamic> json) {
|
||||||
|
try {
|
||||||
|
patientID = json['PatientID'];
|
||||||
|
lineItemNo = json['LineItemNo'];
|
||||||
|
weightMeasured = json['WeightMeasured'];
|
||||||
|
weightDate = DateUtil.convertStringToDate(json['WeightDate']);
|
||||||
|
remark = json['Remark'];
|
||||||
|
isActive = json['IsActive'];
|
||||||
|
measured = json['Measured'];
|
||||||
|
unit = json['Unit'];
|
||||||
|
chartYear = json['ChartYear'];
|
||||||
|
chartMonth = json['ChartMonth'];
|
||||||
|
yearAverageResult = json['YearAverageResult'];
|
||||||
|
monthAverageResult = json['MonthAverageResult'];
|
||||||
|
weekAverageResult = json['WeekAverageResult'];
|
||||||
|
weekDesc = json['WeekDesc'];
|
||||||
|
} catch (e) {
|
||||||
|
print(e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['PatientID'] = this.patientID;
|
||||||
|
data['LineItemNo'] = this.lineItemNo;
|
||||||
|
data['WeightMeasured'] = this.weightMeasured;
|
||||||
|
data['WeightDate'] = this.weightDate;
|
||||||
|
data['Remark'] = this.remark;
|
||||||
|
data['IsActive'] = this.isActive;
|
||||||
|
data['Measured'] = this.measured;
|
||||||
|
data['Unit'] = this.unit;
|
||||||
|
data['ChartYear'] = this.chartYear;
|
||||||
|
data['ChartMonth'] = this.chartMonth;
|
||||||
|
data['YearAverageResult'] = this.yearAverageResult;
|
||||||
|
data['MonthAverageResult'] = this.monthAverageResult;
|
||||||
|
data['WeekAverageResult'] = this.weekAverageResult;
|
||||||
|
data['WeekDesc'] = this.weekDesc;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,33 @@
|
|||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class YearWeightMeasurementResultAverage {
|
||||||
|
dynamic monthAverageResult;
|
||||||
|
int monthNumber;
|
||||||
|
String monthName;
|
||||||
|
String yearName;
|
||||||
|
DateTime date;
|
||||||
|
|
||||||
|
YearWeightMeasurementResultAverage(
|
||||||
|
{this.monthAverageResult,
|
||||||
|
this.monthNumber,
|
||||||
|
this.monthName,
|
||||||
|
this.yearName});
|
||||||
|
|
||||||
|
YearWeightMeasurementResultAverage.fromJson(Map<String, dynamic> json) {
|
||||||
|
monthAverageResult = json['monthAverageResult'];
|
||||||
|
monthNumber = json['monthNumber'];
|
||||||
|
monthName = json['monthName'];
|
||||||
|
yearName = json['yearName'];
|
||||||
|
date = DateUtil.getMonthDateTime(monthName,yearName);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() {
|
||||||
|
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||||
|
data['monthAverageResult'] = this.monthAverageResult;
|
||||||
|
data['monthNumber'] = this.monthNumber;
|
||||||
|
data['monthName'] = this.monthName;
|
||||||
|
data['yearName'] = this.yearName;
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,27 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/active_medications/ActivePrescriptionReport.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/base_service.dart';
|
||||||
|
|
||||||
|
class ActiveMedicationsService extends BaseService{
|
||||||
|
|
||||||
|
List<ActivePrescriptionReport> activePrescriptionReport = List();
|
||||||
|
|
||||||
|
getActiveMedication() async {
|
||||||
|
hasError = false;
|
||||||
|
super.error = "";
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
await baseAppClient.post(ADD_ACTIVE_PRESCRIPTIONS_REPORT_BY_PATIENT_ID,
|
||||||
|
onSuccess: (response, statusCode) async {
|
||||||
|
activePrescriptionReport.clear();
|
||||||
|
response['List_ActiveGetPrescriptionReportByPatientID'].forEach((appoitment) {
|
||||||
|
activePrescriptionReport
|
||||||
|
.add(ActivePrescriptionReport.fromJson(appoitment));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,25 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/Allergy/Allergy.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/base_service.dart';
|
||||||
|
|
||||||
|
class AllergiesService extends BaseService {
|
||||||
|
List<Allergy> allergies = List();
|
||||||
|
|
||||||
|
getAllergies() async {
|
||||||
|
hasError = false;
|
||||||
|
super.error = "";
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
body['OutSA'] = 0;
|
||||||
|
await baseAppClient.post(GET_PATIENT_ALLERGIES,
|
||||||
|
onSuccess: (response, statusCode) async {
|
||||||
|
allergies.clear();
|
||||||
|
response['Patient_Allergies'].forEach((allergy) {
|
||||||
|
allergies.add(Allergy.fromJson(allergy));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,100 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/BloodPressureResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/MonthBloodPressureResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/WeekBloodPressureResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/YearBloodPressureResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/DiabtecPatientResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/MonthDiabtectResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/WeekDiabtectResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/YearDiabtecResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/base_service.dart';
|
||||||
|
|
||||||
|
class BloodPressureService extends BaseService {
|
||||||
|
List<MonthBloodPressureResultAverage> monthDiabtectResultAverageList = List();
|
||||||
|
List<WeekBloodPressureResultAverage> weekDiabtectResultAverageList = List();
|
||||||
|
List<YearBloodPressureResultAverage> yearDiabtecResultAverageList = List();
|
||||||
|
|
||||||
|
///Result
|
||||||
|
List<BloodPressureResult> monthDiabtecPatientResult = List();
|
||||||
|
List<BloodPressureResult> weekDiabtecPatientResult = List();
|
||||||
|
List<BloodPressureResult> yearDiabtecPatientResult = List();
|
||||||
|
|
||||||
|
Future getBloodSugar() async {
|
||||||
|
hasError = false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
await baseAppClient.post(GET_BLOOD_PRESSURE_RESULT_AVERAGE,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
monthDiabtectResultAverageList.clear();
|
||||||
|
weekDiabtectResultAverageList.clear();
|
||||||
|
yearDiabtecResultAverageList.clear();
|
||||||
|
response['List_MonthBloodPressureResultAverage'].forEach((item) {
|
||||||
|
monthDiabtectResultAverageList
|
||||||
|
.add(MonthBloodPressureResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_WeekBloodPressureResultAverage'].forEach((item) {
|
||||||
|
weekDiabtectResultAverageList
|
||||||
|
.add(WeekBloodPressureResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_YearBloodPressureResultAverage'].forEach((item) {
|
||||||
|
yearDiabtecResultAverageList
|
||||||
|
.add(YearBloodPressureResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future getDiabtecResults() async {
|
||||||
|
hasError = false;
|
||||||
|
await baseAppClient.post(GET_BLOOD_PRESSURE_RESULT,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
monthDiabtecPatientResult.clear();
|
||||||
|
weekDiabtecPatientResult.clear();
|
||||||
|
yearDiabtecPatientResult.clear();
|
||||||
|
|
||||||
|
response['List_WeekBloodPressureResult'].forEach((item) {
|
||||||
|
weekDiabtecPatientResult.add(BloodPressureResult.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_MonthBloodPressureResult'].forEach((item) {
|
||||||
|
monthDiabtecPatientResult.add(BloodPressureResult.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_YearBloodPressureResult'].forEach((item) {
|
||||||
|
yearDiabtecPatientResult.add(BloodPressureResult.fromJson(item));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: Map());
|
||||||
|
}
|
||||||
|
|
||||||
|
addDiabtecResult(
|
||||||
|
{String bloodPressureDate,
|
||||||
|
String diastolicPressure,
|
||||||
|
String systolicePressure,
|
||||||
|
int measuredArm}) async {
|
||||||
|
hasError = false;
|
||||||
|
super.error = "";
|
||||||
|
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['BloodPressureDate'] = bloodPressureDate;
|
||||||
|
body['DiastolicPressure'] = diastolicPressure;
|
||||||
|
body['SystolicePressure'] = systolicePressure;
|
||||||
|
body['MeasuredArm'] = measuredArm;
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
|
||||||
|
await baseAppClient.post(ADD_BLOOD_PRESSURE_RESULT,
|
||||||
|
onSuccess: (response, statusCode) async {
|
||||||
|
|
||||||
|
},
|
||||||
|
onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,96 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/DiabtecPatientResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/MonthDiabtectResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/WeekDiabtectResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/YearDiabtecResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/base_service.dart';
|
||||||
|
|
||||||
|
class BloodSugarService extends BaseService {
|
||||||
|
List<MonthDiabtectResultAverage> monthDiabtectResultAverageList = List();
|
||||||
|
List<WeekDiabtectResultAverage> weekDiabtectResultAverageList = List();
|
||||||
|
List<YearDiabtecResultAverage> yearDiabtecResultAverageList = List();
|
||||||
|
|
||||||
|
///Result
|
||||||
|
List<DiabtecPatientResult> monthDiabtecPatientResult = List();
|
||||||
|
List<DiabtecPatientResult> weekDiabtecPatientResult = List();
|
||||||
|
List<DiabtecPatientResult> yearDiabtecPatientResult = List();
|
||||||
|
|
||||||
|
Future getBloodSugar() async {
|
||||||
|
hasError = false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
await baseAppClient.post(GET_DIABETIC_RESULT_AVERAGE,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
monthDiabtectResultAverageList.clear();
|
||||||
|
weekDiabtectResultAverageList.clear();
|
||||||
|
yearDiabtecResultAverageList.clear();
|
||||||
|
response['List_MonthDiabtectResultAverage'].forEach((item) {
|
||||||
|
monthDiabtectResultAverageList
|
||||||
|
.add(MonthDiabtectResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_WeekDiabtectResultAverage'].forEach((item) {
|
||||||
|
weekDiabtectResultAverageList
|
||||||
|
.add(WeekDiabtectResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_YearDiabtecResultAverage'].forEach((item) {
|
||||||
|
yearDiabtecResultAverageList
|
||||||
|
.add(YearDiabtecResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future getDiabtecResults() async {
|
||||||
|
hasError = false;
|
||||||
|
await baseAppClient.post(GET_DIABTEC_RESULT,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
monthDiabtecPatientResult.clear();
|
||||||
|
weekDiabtecPatientResult.clear();
|
||||||
|
yearDiabtecPatientResult.clear();
|
||||||
|
|
||||||
|
response['List_MonthDiabtecPatientResult'].forEach((item) {
|
||||||
|
monthDiabtecPatientResult.add(DiabtecPatientResult.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_WeekDiabtecPatientResult'].forEach((item) {
|
||||||
|
weekDiabtecPatientResult.add(DiabtecPatientResult.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_YearDiabtecPatientResult'].forEach((item) {
|
||||||
|
yearDiabtecPatientResult.add(DiabtecPatientResult.fromJson(item));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: Map());
|
||||||
|
}
|
||||||
|
|
||||||
|
addDiabtecResult(
|
||||||
|
{String bloodSugerDateChart,
|
||||||
|
String bloodSugerResult,
|
||||||
|
String diabtecUnit,
|
||||||
|
int measuredTime}) async {
|
||||||
|
hasError = false;
|
||||||
|
super.error = "";
|
||||||
|
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['BloodSugerDateChart'] = bloodSugerDateChart;
|
||||||
|
body['BloodSugerResult'] = bloodSugerResult;
|
||||||
|
body['DiabtecUnit'] = diabtecUnit;
|
||||||
|
body['MeasuredTime'] =2;// measuredTime;
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
|
||||||
|
await baseAppClient.post(ADD_BLOOD_PRESSURE_RESULT,
|
||||||
|
onSuccess: (response, statusCode) async {
|
||||||
|
var asd ="";
|
||||||
|
},
|
||||||
|
onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,26 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/eye/AppoimentAllHistoryResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/base_service.dart';
|
||||||
|
|
||||||
|
class EyeService extends BaseService {
|
||||||
|
List<AppoimentAllHistoryResultList> appoimentAllHistoryResultList = List();
|
||||||
|
|
||||||
|
getEyeMeasurement() async {
|
||||||
|
hasError = false;
|
||||||
|
super.error = "";
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
body['IsIrisPrescription'] = true;
|
||||||
|
await baseAppClient.post(GET_PATIENT_APPOINTMENT_HISTORY,
|
||||||
|
onSuccess: (response, statusCode) async {
|
||||||
|
appoimentAllHistoryResultList.clear();
|
||||||
|
response['AppoimentAllHistoryResultList'].forEach((appoitment) {
|
||||||
|
appoimentAllHistoryResultList
|
||||||
|
.add(AppoimentAllHistoryResultList.fromJson(appoitment));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,104 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/BloodPressureResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/MonthBloodPressureResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/WeekBloodPressureResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/YearBloodPressureResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/DiabtecPatientResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/MonthDiabtectResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/WeekDiabtectResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/YearDiabtecResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/weight/MonthWeightMeasurementResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/weight/WeekWeightMeasurementResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/weight/WeightMeasurementResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/weight/YearWeightMeasurementResultAverage.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/base_service.dart';
|
||||||
|
|
||||||
|
class WeightService extends BaseService {
|
||||||
|
|
||||||
|
///Average
|
||||||
|
List<MonthWeightMeasurementResultAverage> monthWeightMeasurementResultAverage = List();
|
||||||
|
List<WeekWeightMeasurementResultAverage> weekWeightMeasurementResultAverage = List();
|
||||||
|
List<YearWeightMeasurementResultAverage> yearWeightMeasurementResultAverage = List();
|
||||||
|
|
||||||
|
///Result
|
||||||
|
List<WeightMeasurementResult> monthWeightMeasurementResult = List();
|
||||||
|
List<WeightMeasurementResult> weekWeightMeasurementResult = List();
|
||||||
|
List<WeightMeasurementResult> yearWeightMeasurementResult = List();
|
||||||
|
|
||||||
|
Future getWeightAverage() async {
|
||||||
|
hasError = false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
await baseAppClient.post(GET_WEIGHT_PRESSURE_RESULT_AVERAGE,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
monthWeightMeasurementResultAverage.clear();
|
||||||
|
weekWeightMeasurementResultAverage.clear();
|
||||||
|
yearWeightMeasurementResultAverage.clear();
|
||||||
|
response['List_MonthWeightMeasurementResultAverage'].forEach((item) {
|
||||||
|
monthWeightMeasurementResultAverage
|
||||||
|
.add(MonthWeightMeasurementResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_WeekWeightMeasurementResultAverage'].forEach((item) {
|
||||||
|
weekWeightMeasurementResultAverage
|
||||||
|
.add(WeekWeightMeasurementResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_YearWeightMeasurementResultAverage'].forEach((item) {
|
||||||
|
yearWeightMeasurementResultAverage
|
||||||
|
.add(YearWeightMeasurementResultAverage.fromJson(item));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future getWeightMeasurementResult() async {
|
||||||
|
hasError = false;
|
||||||
|
await baseAppClient.post(GET_WEIGHT_PRESSURE_RESULT,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
monthWeightMeasurementResult.clear();
|
||||||
|
weekWeightMeasurementResult.clear();
|
||||||
|
yearWeightMeasurementResult.clear();
|
||||||
|
|
||||||
|
response['List_WeekWeightMeasurementResult'].forEach((item) {
|
||||||
|
weekWeightMeasurementResult.add(WeightMeasurementResult.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_MonthWeightMeasurementResult'].forEach((item) {
|
||||||
|
monthWeightMeasurementResult.add(WeightMeasurementResult.fromJson(item));
|
||||||
|
});
|
||||||
|
|
||||||
|
response['List_YearWeightMeasurementResult'].forEach((item) {
|
||||||
|
yearWeightMeasurementResult.add(WeightMeasurementResult.fromJson(item));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: Map());
|
||||||
|
}
|
||||||
|
|
||||||
|
addWeightResult(
|
||||||
|
{String weightDate,
|
||||||
|
String weightMeasured,
|
||||||
|
int weightUnit}) async {
|
||||||
|
hasError = false;
|
||||||
|
super.error = "";
|
||||||
|
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['WeightDate'] = weightDate;
|
||||||
|
body['WeightMeasured'] = weightMeasured;
|
||||||
|
body['weightUnit'] = weightUnit;
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
|
||||||
|
await baseAppClient.post(ADD_WEIGHT_PRESSURE_RESULT,
|
||||||
|
onSuccess: (response, statusCode) async {
|
||||||
|
|
||||||
|
},
|
||||||
|
onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,106 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/ask_doctor/AskDoctorReqTypes.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/ask_doctor/DoctorResponse.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/base_service.dart';
|
||||||
|
import 'package:diplomaticquarterapp/models/Appointments/DoctorListResponse.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
|
||||||
|
class AskDoctorService extends BaseService {
|
||||||
|
List<AskDoctorReqTypes> askDoctorReqTypes = List();
|
||||||
|
List<DoctorResponse> doctorResponseList = List();
|
||||||
|
|
||||||
|
Future getCallInfoHoursResult({int projectId, int doctorId}) async {
|
||||||
|
hasError = false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
body['DoctorID'] = doctorId;
|
||||||
|
body['ProjectID'] = projectId;
|
||||||
|
|
||||||
|
await baseAppClient.post(GET_CALL_INFO_HOURS_RESULT,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
///OKAY
|
||||||
|
var asd="";
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future getCallRequestTypeLOV() async {
|
||||||
|
hasError =false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
await baseAppClient.post(GET_CALL_REQUEST_TYPE_LOV,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
askDoctorReqTypes.clear();
|
||||||
|
response['ListReqTypes'].forEach((reqType) {
|
||||||
|
askDoctorReqTypes.add(AskDoctorReqTypes.fromJson(reqType));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future getDoctorResponse() async {
|
||||||
|
hasError =false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
body['from'] =
|
||||||
|
"${DateTime.now().year}-${DateTime.now().month}-${DateTime.now().day} 00:00:00";
|
||||||
|
body['from'] =
|
||||||
|
"${DateTime.now().year}-${DateTime.now().month}-${DateTime.now().day} ${DateTime.now().hour}:${DateTime.now().minute}:00";
|
||||||
|
await baseAppClient.post(GET_DOCTOR_RESPONSE,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
doctorResponseList.clear();
|
||||||
|
response['List_DoctorResponse'].forEach((reqType) {
|
||||||
|
doctorResponseList.add(DoctorResponse.fromJson(reqType));
|
||||||
|
});
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future updateReadStatus({int transactionNo}) async {
|
||||||
|
hasError =false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
body['TransactionNo'] = transactionNo;
|
||||||
|
await baseAppClient.post(UPDATE_READ_STATUS,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
//TODO fix it
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Future sendRequestLOV({DoctorList doctorList,String requestType,String remark}) async {
|
||||||
|
hasError =false;
|
||||||
|
Map<String, dynamic> body = Map();
|
||||||
|
body['ProjectID'] = doctorList.projectID;
|
||||||
|
body['SetupID'] = doctorList.setupID;
|
||||||
|
body['DoctorID'] = doctorList.doctorID;
|
||||||
|
body['PatientMobileNumber'] = user.mobileNumber;
|
||||||
|
body['IsMessageSent'] = false;
|
||||||
|
body['RequestDate'] = DateUtil.yearMonthDay(DateTime.now());
|
||||||
|
body['RequestTime'] = DateUtil.time(DateTime.now());
|
||||||
|
body['Remarks'] = remark;
|
||||||
|
body['Status'] = 2;// 4 for testing only.."cancelled status insert" else should be changed to 1 in live version
|
||||||
|
body['CreatedBy'] = 102;
|
||||||
|
body['CreatedOn'] = DateUtil.yearMonthDay(DateTime.now());
|
||||||
|
body['EditedBy'] = 102;
|
||||||
|
body['EditedOn'] = DateUtil.yearMonthDay(DateTime.now());
|
||||||
|
body['isDentalAllowedBackend'] = false;
|
||||||
|
await baseAppClient.post(INSERT_CALL_INFO,
|
||||||
|
onSuccess: (dynamic response, int statusCode) {
|
||||||
|
|
||||||
|
}, onFailure: (String error, int statusCode) {
|
||||||
|
hasError = true;
|
||||||
|
super.error = error;
|
||||||
|
}, body: body);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,28 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/active_medications/ActivePrescriptionReport.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/ActiveMedicationsService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/base_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/locator.dart';
|
||||||
|
|
||||||
|
class ActiveMedicationsViewModel extends BaseViewModel {
|
||||||
|
ActiveMedicationsService _activeMedicationsService =
|
||||||
|
locator<ActiveMedicationsService>();
|
||||||
|
|
||||||
|
List<ActivePrescriptionReport> get activePrescriptionReport =>
|
||||||
|
_activeMedicationsService.activePrescriptionReport;
|
||||||
|
|
||||||
|
getActiveMedication() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _activeMedicationsService.getActiveMedication();
|
||||||
|
if (_activeMedicationsService.hasError) {
|
||||||
|
error = _activeMedicationsService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,22 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/Allergy/Allergy.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/AllergiesService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/base_view_model.dart';
|
||||||
|
|
||||||
|
import '../../../locator.dart';
|
||||||
|
|
||||||
|
class AllergiesViewModel extends BaseViewModel {
|
||||||
|
AllergiesService _allergiesService = locator<AllergiesService>();
|
||||||
|
List<Allergy> get allergies => _allergiesService.allergies;
|
||||||
|
|
||||||
|
getAllergies() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _allergiesService.getAllergies();
|
||||||
|
if (_allergiesService.hasError) {
|
||||||
|
error = _allergiesService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,46 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/eye/AppoimentAllHistoryResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/eye/AppointmentFilter.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/EyeService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/base_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/locator.dart';
|
||||||
|
|
||||||
|
class EyeViewModel extends BaseViewModel {
|
||||||
|
EyeService _eyeService = locator<EyeService>();
|
||||||
|
|
||||||
|
List<AppoimentAllHistoryResultList> get appoimentAllHistoryResultList =>
|
||||||
|
_eyeService.appoimentAllHistoryResultList;
|
||||||
|
|
||||||
|
List<AppointmentFilter> appointmentFilter = List();
|
||||||
|
|
||||||
|
getEyeMeasurement() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _eyeService.getEyeMeasurement();
|
||||||
|
if (_eyeService.hasError) {
|
||||||
|
error = _eyeService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
_eyeService.appoimentAllHistoryResultList.forEach((element) {
|
||||||
|
List<AppointmentFilter> _appointmentFilter = appointmentFilter
|
||||||
|
.where(
|
||||||
|
(elementFilter) =>
|
||||||
|
elementFilter.filterName == element.projectName,
|
||||||
|
)
|
||||||
|
.toList();
|
||||||
|
|
||||||
|
if (_appointmentFilter.length != 0) {
|
||||||
|
appointmentFilter[appointmentFilter.indexOf(_appointmentFilter[0])]
|
||||||
|
.appointmentAllHistoryResultList
|
||||||
|
.add(element);
|
||||||
|
} else {
|
||||||
|
appointmentFilter.add(AppointmentFilter(
|
||||||
|
element,
|
||||||
|
element.projectName,
|
||||||
|
));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,110 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/ask_doctor/AskDoctorReqTypes.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/ask_doctor/DoctorResponse.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/ask_doctor_services.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/my_doctor_service.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/base_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/locator.dart';
|
||||||
|
import 'package:diplomaticquarterapp/models/Appointments/DoctorListResponse.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
|
||||||
|
|
||||||
|
class AskDoctorViewModel extends BaseViewModel {
|
||||||
|
AskDoctorService _askDoctorService = locator<AskDoctorService>();
|
||||||
|
MyDoctorService _myDoctorService = locator<MyDoctorService>();
|
||||||
|
|
||||||
|
List<PatientDoctorAppointmentList> patientDoctorAppointmentListHospital =
|
||||||
|
List();
|
||||||
|
|
||||||
|
List<AskDoctorReqTypes> get askDoctorReqTypes =>
|
||||||
|
_askDoctorService.askDoctorReqTypes;
|
||||||
|
|
||||||
|
List<DoctorResponse> get doctorResponseList =>
|
||||||
|
_askDoctorService.doctorResponseList;
|
||||||
|
|
||||||
|
Future getMyDoctor() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _myDoctorService.getPatientDoctorAppointmentList(
|
||||||
|
top: 25, beforeDays: 15);
|
||||||
|
if (_myDoctorService.hasError) {
|
||||||
|
error = _myDoctorService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else
|
||||||
|
var asd = "";
|
||||||
|
_myDoctorService.patientDoctorAppointmentList.forEach((element) {
|
||||||
|
List<PatientDoctorAppointmentList> doctorByClinic =
|
||||||
|
patientDoctorAppointmentListHospital
|
||||||
|
.where((elementClinic) =>
|
||||||
|
elementClinic.filterName == element.projectName)
|
||||||
|
.toList();
|
||||||
|
|
||||||
|
if (doctorByClinic.length != 0) {
|
||||||
|
patientDoctorAppointmentListHospital[
|
||||||
|
patientDoctorAppointmentListHospital.indexOf(doctorByClinic[0])]
|
||||||
|
.patientDoctorAppointmentList
|
||||||
|
.add(element);
|
||||||
|
} else {
|
||||||
|
patientDoctorAppointmentListHospital.add(PatientDoctorAppointmentList(
|
||||||
|
filterName: element.projectName,
|
||||||
|
patientDoctorAppointment: element));
|
||||||
|
}
|
||||||
|
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
Future getCallRequestTypeLOVs() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _askDoctorService.getCallRequestTypeLOV();
|
||||||
|
if (_askDoctorService.hasError) {
|
||||||
|
error = _askDoctorService.error;
|
||||||
|
setState(ViewState.ErrorLocal);
|
||||||
|
AppToast.showErrorToast(message: error);
|
||||||
|
} else
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future getCallInfoHoursResult({int projectId, int doctorId}) async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _askDoctorService.getCallInfoHoursResult(
|
||||||
|
projectId: projectId, doctorId: doctorId);
|
||||||
|
if (_askDoctorService.hasError) {
|
||||||
|
error = _askDoctorService.error;
|
||||||
|
setState(ViewState.ErrorLocal);
|
||||||
|
} else
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
|
||||||
|
getDoctorResponse() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _askDoctorService.getDoctorResponse();
|
||||||
|
if (_askDoctorService.hasError) {
|
||||||
|
error = _askDoctorService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future updateReadStatus({int transactionNo}) async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await _askDoctorService.updateReadStatus(transactionNo: transactionNo);
|
||||||
|
if (_askDoctorService.hasError) {
|
||||||
|
error = _askDoctorService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
|
||||||
|
Future sendRequestLOV(
|
||||||
|
{DoctorList doctorList, String requestType, String remark}) async {
|
||||||
|
setState(ViewState.BusyLocal);
|
||||||
|
await _askDoctorService.sendRequestLOV(
|
||||||
|
doctorList: doctorList, requestType: requestType, remark: remark);
|
||||||
|
if (_askDoctorService.hasError) {
|
||||||
|
error = _askDoctorService.error;
|
||||||
|
setState(ViewState.ErrorLocal);
|
||||||
|
AppToast.showErrorToast(message: error);
|
||||||
|
} else
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,151 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/BloodPressureResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/DiabtecPatientResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/WeekChartDate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/YearMonthlyChartDate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/BloodPressureService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/BloodSugarService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/locator.dart';
|
||||||
|
import 'package:charts_flutter/flutter.dart' as charts;
|
||||||
|
|
||||||
|
import '../../../core/viewModels/base_view_model.dart';
|
||||||
|
|
||||||
|
class BloodPressureViewMode extends BaseViewModel {
|
||||||
|
BloodPressureService bloodPressureService = locator<BloodPressureService>();
|
||||||
|
|
||||||
|
///BLOOD
|
||||||
|
List<WeekChartDate> _bloodDiastolicPressureWeeklyTimeSeriesSalesList = List();
|
||||||
|
List<WeekChartDate> _bloodSystolicePressureWeeklyTimeSeriesSalesList = List();
|
||||||
|
|
||||||
|
List<YearMonthlyChartDate> _bloodDiastolicMonthlyTimeSeriesSalesList = List();
|
||||||
|
List<YearMonthlyChartDate> _bloodSystolicMonthlyTimeSeriesSalesList = List();
|
||||||
|
|
||||||
|
List<WeekChartDate> _bloodSystoliceYearTimeSeriesSalesList = List();
|
||||||
|
List<WeekChartDate> _bloodDiastolicYearTimeSeriesSalesList = List();
|
||||||
|
|
||||||
|
List<BloodPressureResult> get monthDiabtecPatientResult => bloodPressureService.monthDiabtecPatientResult;
|
||||||
|
|
||||||
|
List<BloodPressureResult> get weekDiabtecPatientResult => bloodPressureService.weekDiabtecPatientResult;
|
||||||
|
|
||||||
|
List<BloodPressureResult> get yearDiabtecPatientResult => bloodPressureService.yearDiabtecPatientResult;
|
||||||
|
|
||||||
|
Future getBloodPressure() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await bloodPressureService.getBloodSugar();
|
||||||
|
await bloodPressureService.getDiabtecResults();
|
||||||
|
if (bloodPressureService.hasError) {
|
||||||
|
error = bloodPressureService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
bloodPressureService.weekDiabtectResultAverageList.forEach((element) {
|
||||||
|
_bloodDiastolicPressureWeeklyTimeSeriesSalesList.add(WeekChartDate(
|
||||||
|
x: element.bloodPressureDate,
|
||||||
|
y: element.dailyDiastolicPressureAverageResult));
|
||||||
|
_bloodSystolicePressureWeeklyTimeSeriesSalesList.add(WeekChartDate(
|
||||||
|
x: element.bloodPressureDate,
|
||||||
|
y: element.dailySystolicePressureAverageResult));
|
||||||
|
});
|
||||||
|
|
||||||
|
for (int index = 0;
|
||||||
|
index < bloodPressureService.monthDiabtectResultAverageList.length;
|
||||||
|
index++) {
|
||||||
|
_bloodDiastolicMonthlyTimeSeriesSalesList.add(YearMonthlyChartDate(
|
||||||
|
x: index,
|
||||||
|
y: bloodPressureService.monthDiabtectResultAverageList[index]
|
||||||
|
.weekDiastolicPressureAverageResult));
|
||||||
|
_bloodSystolicMonthlyTimeSeriesSalesList.add(YearMonthlyChartDate(
|
||||||
|
x: index,
|
||||||
|
y: bloodPressureService.monthDiabtectResultAverageList[index]
|
||||||
|
.weekSystolicePressureAverageResult));
|
||||||
|
}
|
||||||
|
|
||||||
|
bloodPressureService.yearDiabtecResultAverageList.forEach((element) {
|
||||||
|
_bloodSystoliceYearTimeSeriesSalesList
|
||||||
|
.add(WeekChartDate(x: element.date, y: element.monthSystolicePressureAverageResult));
|
||||||
|
|
||||||
|
_bloodDiastolicYearTimeSeriesSalesList
|
||||||
|
.add(WeekChartDate(x: element.date, y: element.monthDiastolicPressureAverageResult));
|
||||||
|
});
|
||||||
|
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<WeekChartDate, DateTime>> getBloodWeeklySeries() {
|
||||||
|
return [
|
||||||
|
charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Diastolic',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodDiastolicPressureWeeklyTimeSeriesSalesList,
|
||||||
|
),
|
||||||
|
charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Systolice',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.blue.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodSystolicePressureWeeklyTimeSeriesSalesList,
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<YearMonthlyChartDate, int>>
|
||||||
|
getBloodMonthlyTimeSeriesSales() {
|
||||||
|
return [
|
||||||
|
charts.Series<YearMonthlyChartDate, int>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (YearMonthlyChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (YearMonthlyChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodDiastolicMonthlyTimeSeriesSalesList,
|
||||||
|
),
|
||||||
|
charts.Series<YearMonthlyChartDate, int>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.blue.shadeDefault,
|
||||||
|
domainFn: (YearMonthlyChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (YearMonthlyChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodSystolicMonthlyTimeSeriesSalesList,
|
||||||
|
),
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<WeekChartDate, DateTime>> getBloodYearTimeSeriesSales() {
|
||||||
|
return [
|
||||||
|
charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodSystoliceYearTimeSeriesSalesList,
|
||||||
|
),
|
||||||
|
charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.blue.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodDiastolicYearTimeSeriesSalesList,
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
addDiabtecResult(
|
||||||
|
{String bloodPressureDate,
|
||||||
|
String diastolicPressure,
|
||||||
|
String systolicePressure,
|
||||||
|
int measuredArm}) async {
|
||||||
|
setState(ViewState.BusyLocal);
|
||||||
|
await bloodPressureService.addDiabtecResult(
|
||||||
|
bloodPressureDate: bloodPressureDate,
|
||||||
|
diastolicPressure: diastolicPressure,
|
||||||
|
systolicePressure: systolicePressure,
|
||||||
|
measuredArm: measuredArm);
|
||||||
|
if (bloodPressureService.hasError) {
|
||||||
|
error = bloodPressureService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
await getBloodPressure();
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,119 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/DiabtecPatientResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/WeekChartDate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/YearMonthlyChartDate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/BloodSugarService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/locator.dart';
|
||||||
|
import 'package:charts_flutter/flutter.dart' as charts;
|
||||||
|
|
||||||
|
import '../../../core/viewModels/base_view_model.dart';
|
||||||
|
|
||||||
|
class BloodSugarViewMode extends BaseViewModel {
|
||||||
|
BloodSugarService bloodSugarService = locator<BloodSugarService>();
|
||||||
|
|
||||||
|
///BLOOD
|
||||||
|
List<WeekChartDate> _bloodWeeklyTimeSeriesSalesList = List();
|
||||||
|
List<YearMonthlyChartDate> _bloodMonthlyTimeSeriesSalesList = List();
|
||||||
|
List<WeekChartDate> _bloodYearTimeSeriesSalesList = List();
|
||||||
|
|
||||||
|
List<DiabtecPatientResult> get monthDiabtecPatientResult =>
|
||||||
|
bloodSugarService.monthDiabtecPatientResult;
|
||||||
|
|
||||||
|
List<DiabtecPatientResult> get weekDiabtecPatientResult =>
|
||||||
|
bloodSugarService.weekDiabtecPatientResult;
|
||||||
|
|
||||||
|
List<DiabtecPatientResult> get yearDiabtecPatientResult =>
|
||||||
|
bloodSugarService.yearDiabtecPatientResult;
|
||||||
|
|
||||||
|
Future getBloodSugar() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await bloodSugarService.getBloodSugar();
|
||||||
|
await bloodSugarService.getDiabtecResults();
|
||||||
|
if (bloodSugarService.hasError) {
|
||||||
|
error = bloodSugarService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
bloodSugarService.weekDiabtectResultAverageList.forEach((element) {
|
||||||
|
_bloodWeeklyTimeSeriesSalesList.add(
|
||||||
|
WeekChartDate(x: element.dateChart, y: element.dailyAverageResult));
|
||||||
|
});
|
||||||
|
|
||||||
|
for (int index = 0;
|
||||||
|
index < bloodSugarService.monthDiabtectResultAverageList.length;
|
||||||
|
index++) {
|
||||||
|
_bloodMonthlyTimeSeriesSalesList.add(YearMonthlyChartDate(
|
||||||
|
x: index,
|
||||||
|
y: bloodSugarService
|
||||||
|
.monthDiabtectResultAverageList[index].weekAverageResult));
|
||||||
|
var asd="";
|
||||||
|
}
|
||||||
|
|
||||||
|
bloodSugarService.yearDiabtecResultAverageList.forEach((element) {
|
||||||
|
_bloodYearTimeSeriesSalesList
|
||||||
|
.add(WeekChartDate(x: element.date, y: element.monthAverageResult));
|
||||||
|
});
|
||||||
|
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<WeekChartDate, DateTime>> getBloodWeeklySeries() {
|
||||||
|
return [
|
||||||
|
new charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodWeeklyTimeSeriesSalesList,
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<YearMonthlyChartDate, int>>
|
||||||
|
getBloodMonthlyTimeSeriesSales() {
|
||||||
|
return [
|
||||||
|
new charts.Series<YearMonthlyChartDate, int>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (YearMonthlyChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (YearMonthlyChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodMonthlyTimeSeriesSalesList,
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<WeekChartDate, DateTime>> getBloodYearTimeSeriesSales() {
|
||||||
|
return [
|
||||||
|
new charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _bloodYearTimeSeriesSalesList,
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
addDiabtecResult(
|
||||||
|
{String bloodSugerDateChart,
|
||||||
|
String bloodSugerResult,
|
||||||
|
String diabtecUnit,
|
||||||
|
int measuredTime}) async {
|
||||||
|
setState(ViewState.BusyLocal);
|
||||||
|
await bloodSugarService.addDiabtecResult(
|
||||||
|
bloodSugerDateChart: bloodSugerDateChart,
|
||||||
|
bloodSugerResult: bloodSugerResult ,
|
||||||
|
diabtecUnit: diabtecUnit,
|
||||||
|
measuredTime: measuredTime);
|
||||||
|
if (bloodSugarService.hasError) {
|
||||||
|
error = bloodSugarService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
await getBloodSugar();
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,113 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_pressur/BloodPressureResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/DiabtecPatientResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/WeekChartDate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/YearMonthlyChartDate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/model/my_trakers/weight/WeightMeasurementResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/BloodPressureService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/BloodSugarService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/service/medical/WeightPressureService.dart';
|
||||||
|
import 'package:diplomaticquarterapp/locator.dart';
|
||||||
|
import 'package:charts_flutter/flutter.dart' as charts;
|
||||||
|
|
||||||
|
import '../../../core/viewModels/base_view_model.dart';
|
||||||
|
|
||||||
|
class WeightPressureViewMode extends BaseViewModel {
|
||||||
|
WeightService weightService = locator<WeightService>();
|
||||||
|
|
||||||
|
List<WeekChartDate> _weightWeeklyTimeSeriesSalesList = List();
|
||||||
|
List<YearMonthlyChartDate> _weightMonthlyTimeSeriesSalesList = List();
|
||||||
|
List<WeekChartDate> _weightYearTimeSeriesSalesList = List();
|
||||||
|
|
||||||
|
List<WeightMeasurementResult> get monthWeightMeasurementResult =>
|
||||||
|
weightService.monthWeightMeasurementResult;
|
||||||
|
|
||||||
|
List<WeightMeasurementResult> get weekWeightMeasurementResult =>
|
||||||
|
weightService.weekWeightMeasurementResult;
|
||||||
|
|
||||||
|
List<WeightMeasurementResult> get yearWeightMeasurementResult =>
|
||||||
|
weightService.yearWeightMeasurementResult;
|
||||||
|
|
||||||
|
Future getWeight() async {
|
||||||
|
setState(ViewState.Busy);
|
||||||
|
await weightService.getWeightAverage();
|
||||||
|
await weightService.getWeightMeasurementResult();
|
||||||
|
if (weightService.hasError) {
|
||||||
|
error = weightService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
weightService.weekWeightMeasurementResultAverage.forEach((element) {
|
||||||
|
_weightWeeklyTimeSeriesSalesList.add(WeekChartDate(
|
||||||
|
x: element.weightDate, y: element.dailyAverageResult));
|
||||||
|
});
|
||||||
|
|
||||||
|
for (int index = 0;
|
||||||
|
index < weightService.monthWeightMeasurementResultAverage.length;
|
||||||
|
index++) {
|
||||||
|
_weightMonthlyTimeSeriesSalesList.add(YearMonthlyChartDate(
|
||||||
|
x: index,
|
||||||
|
y: weightService.monthWeightMeasurementResultAverage[index].weekAverageResult));
|
||||||
|
}
|
||||||
|
|
||||||
|
weightService.yearWeightMeasurementResultAverage.forEach((element) {
|
||||||
|
_weightYearTimeSeriesSalesList
|
||||||
|
.add(WeekChartDate(x: element.date, y: element.monthAverageResult));
|
||||||
|
});
|
||||||
|
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<WeekChartDate, DateTime>> getWeightWeeklySeries() {
|
||||||
|
return [
|
||||||
|
charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Diastolic',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _weightWeeklyTimeSeriesSalesList,
|
||||||
|
),
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<YearMonthlyChartDate, int>>
|
||||||
|
getWeightMonthlyTimeSeriesSales() {
|
||||||
|
return [
|
||||||
|
charts.Series<YearMonthlyChartDate, int>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (YearMonthlyChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (YearMonthlyChartDate sales, _) => sales.y,
|
||||||
|
data: _weightMonthlyTimeSeriesSalesList,
|
||||||
|
),
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
List<charts.Series<WeekChartDate, DateTime>> getWeightYearTimeSeriesSales() {
|
||||||
|
return [
|
||||||
|
charts.Series<WeekChartDate, DateTime>(
|
||||||
|
id: 'Sales',
|
||||||
|
colorFn: (_, __) => charts.MaterialPalette.red.shadeDefault,
|
||||||
|
domainFn: (WeekChartDate sales, _) => sales.x,
|
||||||
|
measureFn: (WeekChartDate sales, _) => sales.y,
|
||||||
|
data: _weightYearTimeSeriesSalesList,
|
||||||
|
),
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
addWeightResult(
|
||||||
|
{String weightDate, String weightMeasured, int weightUnit}) async {
|
||||||
|
setState(ViewState.BusyLocal);
|
||||||
|
await weightService.addWeightResult(
|
||||||
|
weightDate: weightDate,
|
||||||
|
weightMeasured: weightMeasured,
|
||||||
|
weightUnit: weightUnit,);
|
||||||
|
if (weightService.hasError) {
|
||||||
|
error = weightService.error;
|
||||||
|
setState(ViewState.Error);
|
||||||
|
} else {
|
||||||
|
await getWeight();
|
||||||
|
setState(ViewState.Idle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,131 @@
|
|||||||
|
import 'package:diplomaticquarterapp/config/size_config.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/ActiveMedicationsViewModel.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/medical/active_medications/reminder_page.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/utils.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
class ActiveMedicationsPage extends StatelessWidget {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return BaseView<ActiveMedicationsViewModel>(
|
||||||
|
onModelReady: (model) => model.getActiveMedication(),
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
baseViewModel: model,
|
||||||
|
appBarTitle: TranslationBase.of(context).activeMedications,
|
||||||
|
isShowAppBar: true,
|
||||||
|
body: Container(
|
||||||
|
child: ListView.builder(
|
||||||
|
itemCount: model.activePrescriptionReport.length,
|
||||||
|
itemBuilder: (context, index) => Container(
|
||||||
|
padding: EdgeInsets.all(10),
|
||||||
|
margin: EdgeInsets.all(10),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(8), color: Colors.white),
|
||||||
|
child: Row(
|
||||||
|
children: [
|
||||||
|
Image.memory(
|
||||||
|
Utils.dataFromBase64String(model
|
||||||
|
.activePrescriptionReport[index].productImageBase64),
|
||||||
|
height: SizeConfig.imageSizeMultiplier * 19,
|
||||||
|
width: SizeConfig.imageSizeMultiplier * 18,
|
||||||
|
fit: BoxFit.cover,
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Texts(
|
||||||
|
model.activePrescriptionReport[index].itemDescription,
|
||||||
|
bold: true,
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 5,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
TranslationBase.of(context).expDate+' :' +
|
||||||
|
DateUtil.getDayMonthYearDateFormatted(model
|
||||||
|
.activePrescriptionReport[index].orderDate),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 5,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
TranslationBase.of(context).route+ ' :' +
|
||||||
|
model.activePrescriptionReport[index].route,
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 5,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
TranslationBase.of(context).frequency+ ' :' +
|
||||||
|
model.activePrescriptionReport[index].frequency,
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 5,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
TranslationBase.of(context).dailyQuantity + ' :${model.activePrescriptionReport[index].doseDailyQuantity}',
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Icon(
|
||||||
|
Icons.notifications,
|
||||||
|
color: Colors.red,
|
||||||
|
size: 28,
|
||||||
|
),
|
||||||
|
SizedBox(height: 25,),
|
||||||
|
InkWell(
|
||||||
|
onTap: (){
|
||||||
|
Navigator.push(
|
||||||
|
context,
|
||||||
|
FadePage(
|
||||||
|
page: ReminderPage(
|
||||||
|
frequency: model.activePrescriptionReport[index]
|
||||||
|
.frequencyNumber,
|
||||||
|
days: model.activePrescriptionReport[index].days,
|
||||||
|
itemDescription: model
|
||||||
|
.activePrescriptionReport[index]
|
||||||
|
.itemDescription,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
child: Row(
|
||||||
|
children: [
|
||||||
|
Icon(
|
||||||
|
Icons.notifications_active,
|
||||||
|
color: Colors.red,
|
||||||
|
size: 28,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
TranslationBase.of(context).addReminder,
|
||||||
|
color: Colors.red,
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,161 @@
|
|||||||
|
import 'package:device_calendar/device_calendar.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
class DayCheckBoxDialog extends StatefulWidget {
|
||||||
|
final Function(List<DayOfWeek>) onValueSelected;
|
||||||
|
final String title;
|
||||||
|
final List<DayOfWeek> selectedDaysOfWeek;
|
||||||
|
final List<DayOfWeek> daysOfWeek = [
|
||||||
|
DayOfWeek.Monday,
|
||||||
|
DayOfWeek.Tuesday,
|
||||||
|
DayOfWeek.Wednesday,
|
||||||
|
DayOfWeek.Thursday,
|
||||||
|
DayOfWeek.Friday,
|
||||||
|
DayOfWeek.Saturday,
|
||||||
|
DayOfWeek.Sunday,
|
||||||
|
];
|
||||||
|
|
||||||
|
DayCheckBoxDialog(
|
||||||
|
{Key key, this.onValueSelected, this.selectedDaysOfWeek, this.title});
|
||||||
|
|
||||||
|
@override
|
||||||
|
_DayCheckBoxDialogState createState() => _DayCheckBoxDialogState();
|
||||||
|
}
|
||||||
|
|
||||||
|
class _DayCheckBoxDialogState extends State<DayCheckBoxDialog> {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return SimpleDialog(
|
||||||
|
title: Container(
|
||||||
|
width: double.infinity,
|
||||||
|
child: Center(
|
||||||
|
child: Texts(
|
||||||
|
widget.title,
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
))),
|
||||||
|
children: [
|
||||||
|
Container(
|
||||||
|
height: widget.daysOfWeek.length > 3
|
||||||
|
? MediaQuery.of(context).size.height * 0.6
|
||||||
|
: null,
|
||||||
|
child: SingleChildScrollView(
|
||||||
|
child: Column(
|
||||||
|
children: [
|
||||||
|
Divider(),
|
||||||
|
...List.generate(
|
||||||
|
widget.daysOfWeek.length,
|
||||||
|
(index) => Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
SizedBox(
|
||||||
|
height: 2,
|
||||||
|
),
|
||||||
|
Row(
|
||||||
|
children: <Widget>[
|
||||||
|
Expanded(
|
||||||
|
flex: 1,
|
||||||
|
child: InkWell(
|
||||||
|
onTap: () {
|
||||||
|
setState(() {
|
||||||
|
if (widget.selectedDaysOfWeek
|
||||||
|
.contains(widget.daysOfWeek[index]))
|
||||||
|
widget.selectedDaysOfWeek
|
||||||
|
.remove(widget.daysOfWeek[index]);
|
||||||
|
else
|
||||||
|
widget.selectedDaysOfWeek
|
||||||
|
.add(widget.daysOfWeek[index]);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
child: ListTile(
|
||||||
|
title: Text(DateUtil.getDay(widget.daysOfWeek[index])),
|
||||||
|
leading: Checkbox(
|
||||||
|
value: widget.selectedDaysOfWeek
|
||||||
|
.contains(widget.daysOfWeek[index]),
|
||||||
|
onChanged: (value) {
|
||||||
|
setState(() {
|
||||||
|
if (widget.selectedDaysOfWeek
|
||||||
|
.contains(widget.daysOfWeek[index]))
|
||||||
|
widget.selectedDaysOfWeek
|
||||||
|
.remove(widget.daysOfWeek[index]);
|
||||||
|
else
|
||||||
|
widget.selectedDaysOfWeek
|
||||||
|
.add(widget.daysOfWeek[index]);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 5.0,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 5.0,
|
||||||
|
),
|
||||||
|
Row(
|
||||||
|
children: <Widget>[
|
||||||
|
Expanded(
|
||||||
|
flex: 1,
|
||||||
|
child: InkWell(
|
||||||
|
onTap: () {
|
||||||
|
Navigator.pop(context);
|
||||||
|
},
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Container(
|
||||||
|
child: Center(
|
||||||
|
child: Texts(
|
||||||
|
TranslationBase.of(context)
|
||||||
|
.cancel
|
||||||
|
.toUpperCase(),
|
||||||
|
color: Colors.red,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
width: 1,
|
||||||
|
height: 30,
|
||||||
|
color: Colors.grey[500],
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
flex: 1,
|
||||||
|
child: InkWell(
|
||||||
|
onTap: () {
|
||||||
|
widget.onValueSelected(widget.selectedDaysOfWeek);
|
||||||
|
Navigator.pop(context);
|
||||||
|
},
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Center(
|
||||||
|
child: Texts(
|
||||||
|
TranslationBase.of(context).ok,
|
||||||
|
fontWeight: FontWeight.w400,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,332 @@
|
|||||||
|
import 'package:device_calendar/device_calendar.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/ActiveMedicationsViewModel.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/CalendarUtils.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:flutter_datetime_picker/flutter_datetime_picker.dart';
|
||||||
|
import 'package:provider/provider.dart';
|
||||||
|
|
||||||
|
import 'DayCheckBoxDialog.dart';
|
||||||
|
|
||||||
|
// ignore: must_be_immutable
|
||||||
|
class ReminderPage extends StatefulWidget {
|
||||||
|
final int frequency;
|
||||||
|
final int days;
|
||||||
|
final String itemDescription;
|
||||||
|
|
||||||
|
List<DateTime> _scheduleList = List();
|
||||||
|
List<DayOfWeek> daysOfWeek = [
|
||||||
|
DayOfWeek.Monday,
|
||||||
|
DayOfWeek.Tuesday,
|
||||||
|
DayOfWeek.Wednesday,
|
||||||
|
DayOfWeek.Thursday,
|
||||||
|
DayOfWeek.Friday,
|
||||||
|
DayOfWeek.Saturday,
|
||||||
|
DayOfWeek.Sunday
|
||||||
|
];
|
||||||
|
|
||||||
|
DateTime startDay;
|
||||||
|
DateTime endDay;
|
||||||
|
|
||||||
|
ReminderPage({Key key, this.frequency, this.days, this.itemDescription}) {
|
||||||
|
startDay = DateTime.now();
|
||||||
|
endDay = DateTime.now().add(Duration(days: days));
|
||||||
|
int hour = (24 ~/ frequency).round();
|
||||||
|
int durations = 24 ~/ hour;
|
||||||
|
for (int count = 0; count < durations; count++) {
|
||||||
|
_scheduleList.add(DateTime(DateTime.now().year, DateTime.now().month,
|
||||||
|
DateTime.now().day, (hour * count)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
_ReminderPageState createState() => _ReminderPageState();
|
||||||
|
}
|
||||||
|
|
||||||
|
class _ReminderPageState extends State<ReminderPage> {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
ProjectViewModel projectViewModel = Provider.of(context);
|
||||||
|
|
||||||
|
return BaseView<ActiveMedicationsViewModel>(
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
baseViewModel: model,
|
||||||
|
isShowAppBar: true,
|
||||||
|
appBarTitle: TranslationBase.of(context).reminder,
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.all(8.0),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Container(
|
||||||
|
width: double.maxFinite,
|
||||||
|
child: Texts(TranslationBase.of(context).reminderDes),
|
||||||
|
),
|
||||||
|
Divider(),
|
||||||
|
SizedBox(
|
||||||
|
height: 12,
|
||||||
|
),
|
||||||
|
Texts(TranslationBase.of(context).startDay),
|
||||||
|
SizedBox(
|
||||||
|
height: 6,
|
||||||
|
),
|
||||||
|
InkWell(
|
||||||
|
onTap: () {
|
||||||
|
DatePicker.showDatePicker(context,
|
||||||
|
showTitleActions: true,
|
||||||
|
minTime: DateTime(
|
||||||
|
DateTime.now().year, DateTime.now().month - 1, 1),
|
||||||
|
maxTime: DateTime.now(), onConfirm: (date) {
|
||||||
|
setState(() {
|
||||||
|
widget.startDay = date;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
currentTime: widget.startDay,
|
||||||
|
locale: projectViewModel.localeType);
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
padding: EdgeInsets.all(12),
|
||||||
|
width: double.infinity,
|
||||||
|
height: 65,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(12),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Texts(getStartDay()),
|
||||||
|
Icon(
|
||||||
|
Icons.calendar_today,
|
||||||
|
color: Colors.black,
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 12,
|
||||||
|
),
|
||||||
|
Texts(TranslationBase.of(context).endDay),
|
||||||
|
SizedBox(
|
||||||
|
height: 6,
|
||||||
|
),
|
||||||
|
InkWell(
|
||||||
|
onTap: () {
|
||||||
|
DatePicker.showDatePicker(context,
|
||||||
|
showTitleActions: true,
|
||||||
|
minTime: DateTime(
|
||||||
|
DateTime.now().year, DateTime.now().month - 1, 1),
|
||||||
|
maxTime: DateTime.now(), onConfirm: (date) {
|
||||||
|
setState(() {
|
||||||
|
widget.endDay = date;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
currentTime: widget.endDay,
|
||||||
|
locale: projectViewModel.localeType);
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
padding: EdgeInsets.all(12),
|
||||||
|
width: double.infinity,
|
||||||
|
height: 65,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(12),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Texts(getEndDay()),
|
||||||
|
Icon(
|
||||||
|
Icons.calendar_today,
|
||||||
|
color: Colors.black,
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 12,
|
||||||
|
),
|
||||||
|
Texts(TranslationBase.of(context).days),
|
||||||
|
SizedBox(
|
||||||
|
height: 6,
|
||||||
|
),
|
||||||
|
InkWell(
|
||||||
|
onTap: () => confirmSelectDayDialog(),
|
||||||
|
child: Container(
|
||||||
|
padding: EdgeInsets.all(12),
|
||||||
|
width: double.infinity,
|
||||||
|
height: 65,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(12),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: Texts(
|
||||||
|
getDays(),
|
||||||
|
)),
|
||||||
|
Icon(
|
||||||
|
Icons.arrow_drop_down,
|
||||||
|
color: Colors.black,
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
...List.generate(
|
||||||
|
widget._scheduleList.length,
|
||||||
|
(index) => Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
SizedBox(
|
||||||
|
height: 7,
|
||||||
|
),
|
||||||
|
Texts(TranslationBase.of(context).scheduleTime),
|
||||||
|
SizedBox(
|
||||||
|
height: 7,
|
||||||
|
),
|
||||||
|
InkWell(
|
||||||
|
onTap: () {
|
||||||
|
DatePicker.showTimePicker(context,
|
||||||
|
showTitleActions: true, onConfirm: (date) {
|
||||||
|
setState(() {
|
||||||
|
widget._scheduleList[index] = date;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
currentTime: widget._scheduleList[index],
|
||||||
|
locale: projectViewModel.localeType);
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
padding: EdgeInsets.all(12),
|
||||||
|
width: double.infinity,
|
||||||
|
height: 65,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(12),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment:
|
||||||
|
MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Texts(getDateTime(
|
||||||
|
widget._scheduleList[index])),
|
||||||
|
Icon(
|
||||||
|
Icons.access_time,
|
||||||
|
color: Colors.black,
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
)),
|
||||||
|
Container(
|
||||||
|
width: double.maxFinite,
|
||||||
|
height: MediaQuery.of(context).size.height * 0.12,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
bottomSheet: Container(
|
||||||
|
width: double.infinity,
|
||||||
|
height: MediaQuery.of(context).size.height * 0.2,
|
||||||
|
padding: EdgeInsets.all(10),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
SecondaryButton(
|
||||||
|
label: TranslationBase.of(context).ok,
|
||||||
|
color: Colors.grey[800],
|
||||||
|
textColor: Colors.white,
|
||||||
|
onTap: () {
|
||||||
|
schedule();
|
||||||
|
},
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 15,
|
||||||
|
),
|
||||||
|
SecondaryButton(
|
||||||
|
label: TranslationBase.of(context).cancel,
|
||||||
|
color: Colors.red[800],
|
||||||
|
textColor: Colors.white,
|
||||||
|
onTap: () {
|
||||||
|
Navigator.pop(context);
|
||||||
|
},
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
schedule() async {
|
||||||
|
List<DateTime> scheduleDateTime =
|
||||||
|
calculateDaysInterval(widget.startDay, widget.endDay);
|
||||||
|
|
||||||
|
CalendarUtils calendarUtils = await CalendarUtils.getInstance();
|
||||||
|
|
||||||
|
calendarUtils.createOrUpdateEvents(
|
||||||
|
scheduleList: widget._scheduleList,
|
||||||
|
description: widget.itemDescription,
|
||||||
|
title: widget.itemDescription,
|
||||||
|
scheduleDateTime: scheduleDateTime);
|
||||||
|
|
||||||
|
Navigator.pop(context);
|
||||||
|
}
|
||||||
|
|
||||||
|
List<DateTime> calculateDaysInterval(DateTime startDate, DateTime endDate) {
|
||||||
|
List<DateTime> days = [];
|
||||||
|
for (int i = 0; i <= endDate.difference(startDate).inDays; i++) {
|
||||||
|
widget._scheduleList.forEach((element) {
|
||||||
|
days.add(startDate.add(
|
||||||
|
Duration(days: i, hours: element.hour, minutes: element.minute)));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return days;
|
||||||
|
}
|
||||||
|
|
||||||
|
String getStartDay() {
|
||||||
|
return "${DateUtil.getMonth(widget.startDay.month)} ${widget.startDay.day}, ${widget.startDay.year}";
|
||||||
|
}
|
||||||
|
|
||||||
|
String getEndDay() {
|
||||||
|
return "${DateUtil.getMonth(widget.endDay.month)} ${widget.endDay.day}, ${widget.endDay.year}";
|
||||||
|
}
|
||||||
|
|
||||||
|
String getDateTime(DateTime dateTime) {
|
||||||
|
return '${dateTime.hour}:${dateTime.minute}';
|
||||||
|
}
|
||||||
|
|
||||||
|
String getDays() {
|
||||||
|
String days = "";
|
||||||
|
widget.daysOfWeek.forEach((element) {
|
||||||
|
days += "${DateUtil.getDay(element)},";
|
||||||
|
});
|
||||||
|
return days;
|
||||||
|
}
|
||||||
|
|
||||||
|
void confirmSelectDayDialog() {
|
||||||
|
showDialog(
|
||||||
|
context: context,
|
||||||
|
child: DayCheckBoxDialog(
|
||||||
|
title: 'Select Day',
|
||||||
|
selectedDaysOfWeek: widget.daysOfWeek,
|
||||||
|
onValueSelected: (value) {
|
||||||
|
setState(() {
|
||||||
|
widget.daysOfWeek = value;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,54 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/AllergiesViewModel.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
class AllergiesPage extends StatelessWidget {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return BaseView<AllergiesViewModel>(
|
||||||
|
onModelReady: (model) => model.getAllergies(),
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
isShowAppBar: true,
|
||||||
|
appBarTitle: TranslationBase.of(context).allergies,
|
||||||
|
baseViewModel: model,
|
||||||
|
body: ListView.builder(
|
||||||
|
itemCount: model.allergies.length,
|
||||||
|
itemBuilder: (context, index) => Container(
|
||||||
|
margin: EdgeInsets.all(15),
|
||||||
|
padding: EdgeInsets.all(10),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
shape: BoxShape.rectangle,
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
child: Row(
|
||||||
|
children: [
|
||||||
|
Image.asset(
|
||||||
|
'assets/images/new-design/allergiesDetails.png',
|
||||||
|
width: 50,
|
||||||
|
height: 50,
|
||||||
|
fit: BoxFit.cover,
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
width: 15,
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Texts(TranslationBase.of(context).remarks+" :"),
|
||||||
|
Texts(TranslationBase.of(context).description + model.allergies[index].description ?? ''),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,33 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/model/ask_doctor/DoctorResponse.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/ask_doctor_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
|
||||||
|
class ViewDoctorResponsesPage extends StatelessWidget {
|
||||||
|
final DoctorResponse doctorResponse;
|
||||||
|
|
||||||
|
const ViewDoctorResponsesPage({Key key, this.doctorResponse})
|
||||||
|
: super(key: key);
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return BaseView<AskDoctorViewModel>(
|
||||||
|
onModelReady: (model) => model.updateReadStatus(transactionNo: doctorResponse.transactionNo),
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
isShowAppBar: true,
|
||||||
|
appBarTitle: TranslationBase.of(context).viewDoctorResponses,
|
||||||
|
baseViewModel: model,
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,125 @@
|
|||||||
|
import 'dart:ui';
|
||||||
|
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/ask_doctor_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/prescriptions_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/medical/prescriptions/prescriptions_history_page.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/medical/prescriptions/prescriptions_page.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
import 'ask_doctor_page.dart';
|
||||||
|
import 'doctor_response.dart';
|
||||||
|
|
||||||
|
class AskDoctorHomPage extends StatefulWidget {
|
||||||
|
@override
|
||||||
|
_AskDoctorHomPageState createState() => _AskDoctorHomPageState();
|
||||||
|
}
|
||||||
|
|
||||||
|
class _AskDoctorHomPageState extends State<AskDoctorHomPage>
|
||||||
|
with SingleTickerProviderStateMixin {
|
||||||
|
TabController _tabController;
|
||||||
|
|
||||||
|
@override
|
||||||
|
void initState() {
|
||||||
|
super.initState();
|
||||||
|
_tabController = TabController(length: 2, vsync: this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
void dispose() {
|
||||||
|
super.dispose();
|
||||||
|
_tabController.dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return AppScaffold(
|
||||||
|
isShowAppBar: true,
|
||||||
|
appBarTitle: TranslationBase.of(context).askDoctor,
|
||||||
|
body: Scaffold(
|
||||||
|
extendBodyBehindAppBar: true,
|
||||||
|
appBar: PreferredSize(
|
||||||
|
preferredSize: Size.fromHeight(65.0),
|
||||||
|
child: Stack(
|
||||||
|
children: <Widget>[
|
||||||
|
Positioned(
|
||||||
|
bottom: 1,
|
||||||
|
left: 0,
|
||||||
|
right: 0,
|
||||||
|
child: BackdropFilter(
|
||||||
|
filter: ImageFilter.blur(sigmaX: 10, sigmaY: 10),
|
||||||
|
child: Container(
|
||||||
|
color: Theme.of(context)
|
||||||
|
.scaffoldBackgroundColor
|
||||||
|
.withOpacity(0.8),
|
||||||
|
height: 70.0,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Center(
|
||||||
|
child: Container(
|
||||||
|
height: 60.0,
|
||||||
|
margin: EdgeInsets.only(top: 10.0),
|
||||||
|
width: MediaQuery.of(context).size.width * 0.9,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
border: Border(
|
||||||
|
bottom: BorderSide(
|
||||||
|
color: Theme.of(context).dividerColor,
|
||||||
|
width: 0.9),
|
||||||
|
),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Center(
|
||||||
|
child: TabBar(
|
||||||
|
isScrollable: true,
|
||||||
|
controller: _tabController,
|
||||||
|
indicatorWeight: 5.0,
|
||||||
|
//indicatorSize: TabBarIndicatorSize.label,
|
||||||
|
indicatorColor: Colors.red[800],
|
||||||
|
labelColor: Theme.of(context).primaryColor,
|
||||||
|
labelPadding: EdgeInsets.only(top: 4.0, left: 18.0, right: 18.0),
|
||||||
|
unselectedLabelColor: Colors.grey[800],
|
||||||
|
tabs: [
|
||||||
|
Tab(
|
||||||
|
child: Container(
|
||||||
|
width: MediaQuery.of(context).size.width * 0.36,
|
||||||
|
child: Center(
|
||||||
|
child: Texts(TranslationBase.of(context).askDoctor),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Tab(child: Container(
|
||||||
|
width: MediaQuery.of(context).size.width * 0.36,
|
||||||
|
child: Center(
|
||||||
|
child: Texts(TranslationBase.of(context).doctorResponses,textAlign: TextAlign.start,),
|
||||||
|
),
|
||||||
|
),)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
body: Column(
|
||||||
|
children: <Widget>[
|
||||||
|
Expanded(
|
||||||
|
child: TabBarView(
|
||||||
|
physics: BouncingScrollPhysics(),
|
||||||
|
controller: _tabController,
|
||||||
|
children: <Widget>[
|
||||||
|
AskDoctorPage(),
|
||||||
|
DoctorResponse()
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,240 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/ask_doctor_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/models/Appointments/DoctorListResponse.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/BookAppointment/widgets/DoctorView.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/medical/ask_doctor/request_type.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_expandable_notifier.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:rating_bar/rating_bar.dart';
|
||||||
|
import 'package:smart_progress_bar/smart_progress_bar.dart';
|
||||||
|
|
||||||
|
class AskDoctorPage extends StatelessWidget {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return BaseView<AskDoctorViewModel>(
|
||||||
|
onModelReady: (model) => model.getMyDoctor(),
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
baseViewModel: model,
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.all(10),
|
||||||
|
child: Column(
|
||||||
|
children: [
|
||||||
|
SizedBox(
|
||||||
|
height: 70,
|
||||||
|
),
|
||||||
|
...List.generate(
|
||||||
|
model.patientDoctorAppointmentListHospital.length,
|
||||||
|
(index) => AppExpandableNotifier(
|
||||||
|
title:
|
||||||
|
model.patientDoctorAppointmentListHospital[index].filterName,
|
||||||
|
bodyWidget: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children:
|
||||||
|
model.patientDoctorAppointmentListHospital[index].patientDoctorAppointmentList.map((doctor) {
|
||||||
|
return InkWell(
|
||||||
|
onTap: () {
|
||||||
|
model
|
||||||
|
.getCallInfoHoursResult(
|
||||||
|
doctorId: doctor.doctorID,
|
||||||
|
projectId: doctor.projectID)
|
||||||
|
.then((value) {
|
||||||
|
if (model.state != ViewState.ErrorLocal &&
|
||||||
|
model.state != ViewState.Error) {
|
||||||
|
// Navigator.pop(context);
|
||||||
|
Navigator.push(
|
||||||
|
context,
|
||||||
|
FadePage(
|
||||||
|
page: RequestTypePage(doctorList: doctor,),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
AppToast.showErrorToast(message: model.error);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
///.showProgressBar(
|
||||||
|
// text: "Loading",
|
||||||
|
// backgroundColor:
|
||||||
|
// Colors.blue.withOpacity(0.6))
|
||||||
|
},
|
||||||
|
child: Card(
|
||||||
|
margin:
|
||||||
|
EdgeInsets.fromLTRB(10.0, 16.0, 10.0, 8.0),
|
||||||
|
color: Colors.white,
|
||||||
|
shape: RoundedRectangleBorder(
|
||||||
|
borderRadius: BorderRadius.circular(10),
|
||||||
|
),
|
||||||
|
child: Container(
|
||||||
|
decoration: BoxDecoration(),
|
||||||
|
padding: EdgeInsets.all(7.0),
|
||||||
|
width: MediaQuery.of(context).size.width,
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.start,
|
||||||
|
children: <Widget>[
|
||||||
|
Expanded(
|
||||||
|
flex: 1,
|
||||||
|
child: ClipRRect(
|
||||||
|
borderRadius:
|
||||||
|
BorderRadius.circular(100.0),
|
||||||
|
child: Image.network(
|
||||||
|
doctor.doctorImageURL,
|
||||||
|
fit: BoxFit.fill,
|
||||||
|
height: 60.0,
|
||||||
|
width: 60.0),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
flex: 4,
|
||||||
|
child: Container(
|
||||||
|
width:
|
||||||
|
MediaQuery.of(context).size.width *
|
||||||
|
0.55,
|
||||||
|
margin: EdgeInsets.fromLTRB(
|
||||||
|
20.0, 10.0, 10.0, 0.0),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment:
|
||||||
|
CrossAxisAlignment.start,
|
||||||
|
children: <Widget>[
|
||||||
|
if (doctor.doctorTitle != null)
|
||||||
|
Text(
|
||||||
|
doctor.doctorTitle +
|
||||||
|
" " +
|
||||||
|
doctor.name,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 14.0,
|
||||||
|
color: Colors.grey[700],
|
||||||
|
letterSpacing: 1.0)),
|
||||||
|
Container(
|
||||||
|
margin: EdgeInsets.only(top: 3.0),
|
||||||
|
child: Text(doctor.clinicName,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 12.0,
|
||||||
|
color: Colors.grey[600],
|
||||||
|
letterSpacing: 1.0)),
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
margin: EdgeInsets.only(top: 3.0),
|
||||||
|
child: Text(doctor.projectName,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 12.0,
|
||||||
|
color: Colors.grey[600],
|
||||||
|
letterSpacing: 1.0)),
|
||||||
|
),
|
||||||
|
if (doctor.speciality != null)
|
||||||
|
Container(
|
||||||
|
margin: EdgeInsets.only(
|
||||||
|
top: 3.0, bottom: 3.0),
|
||||||
|
child: Text(
|
||||||
|
getDoctorSpeciality(
|
||||||
|
doctor.speciality)
|
||||||
|
.trim(),
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 12.0,
|
||||||
|
color: Colors.grey[600],
|
||||||
|
letterSpacing: 1.0)),
|
||||||
|
),
|
||||||
|
doctor.nearestFreeSlot != null
|
||||||
|
? Container(
|
||||||
|
margin: EdgeInsets.only(
|
||||||
|
top: 3.0, bottom: 3.0),
|
||||||
|
child: Text(
|
||||||
|
getDate(doctor
|
||||||
|
.nearestFreeSlot),
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 14.0,
|
||||||
|
fontWeight:
|
||||||
|
FontWeight.bold,
|
||||||
|
color: Colors
|
||||||
|
.green[600],
|
||||||
|
letterSpacing:
|
||||||
|
1.0)),
|
||||||
|
)
|
||||||
|
: Container(),
|
||||||
|
Row(
|
||||||
|
mainAxisAlignment:
|
||||||
|
MainAxisAlignment
|
||||||
|
.spaceBetween,
|
||||||
|
mainAxisSize: MainAxisSize.max,
|
||||||
|
children: <Widget>[
|
||||||
|
RatingBar.readOnly(
|
||||||
|
initialRating: doctor
|
||||||
|
.actualDoctorRate
|
||||||
|
.toDouble(),
|
||||||
|
size: 20.0,
|
||||||
|
filledColor:
|
||||||
|
Colors.yellow[700],
|
||||||
|
emptyColor: Colors.grey[500],
|
||||||
|
isHalfAllowed: true,
|
||||||
|
halfFilledIcon:
|
||||||
|
Icons.star_half,
|
||||||
|
filledIcon: Icons.star,
|
||||||
|
emptyIcon: Icons.star,
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
child: Image.network(
|
||||||
|
doctor.nationalityFlagURL,
|
||||||
|
width: 25.0,
|
||||||
|
height: 25.0),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}).toList(),
|
||||||
|
)),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
String getDoctorSpeciality(List<String> docSpecial) {
|
||||||
|
String docSpeciality = "";
|
||||||
|
docSpecial.forEach((v) {
|
||||||
|
docSpeciality = docSpeciality + v + "\n";
|
||||||
|
});
|
||||||
|
return docSpeciality;
|
||||||
|
}
|
||||||
|
|
||||||
|
String getDate(String date) {
|
||||||
|
DateTime dateObj = DateUtil.convertStringToDate(date);
|
||||||
|
return DateUtil.getWeekDay(dateObj.weekday) +
|
||||||
|
", " +
|
||||||
|
dateObj.day.toString() +
|
||||||
|
" " +
|
||||||
|
DateUtil.getMonth(dateObj.month) +
|
||||||
|
" " +
|
||||||
|
dateObj.year.toString() +
|
||||||
|
" " +
|
||||||
|
dateObj.hour.toString() +
|
||||||
|
":" +
|
||||||
|
getMinute(dateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
String getMinute(DateTime dateObj) {
|
||||||
|
if (dateObj.minute == 0) {
|
||||||
|
return dateObj.minute.toString() + "0";
|
||||||
|
} else {
|
||||||
|
return dateObj.minute.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@ -0,0 +1,189 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/ask_doctor_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_expandable_notifier.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:provider/provider.dart';
|
||||||
|
|
||||||
|
import 'ViewDoctorResponsesPage.dart';
|
||||||
|
|
||||||
|
class DoctorResponse extends StatelessWidget {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
ProjectViewModel projectViewModel = Provider.of(context);
|
||||||
|
return BaseView<AskDoctorViewModel>(
|
||||||
|
onModelReady: (model) => model.getDoctorResponse(),
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
baseViewModel: model,
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.all(12),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
SizedBox(
|
||||||
|
height: 65,
|
||||||
|
),
|
||||||
|
AppExpandableNotifier(
|
||||||
|
header: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Texts(TranslationBase.of(context).newDes),
|
||||||
|
Container(
|
||||||
|
width: 30,
|
||||||
|
height: 30,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
shape: BoxShape.circle,
|
||||||
|
color: Colors.red[800],
|
||||||
|
),
|
||||||
|
child: Center(
|
||||||
|
child: Texts(
|
||||||
|
'${model.doctorResponseList.length}',
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
bodyWidget: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: model.doctorResponseList.map(
|
||||||
|
(doctor) {
|
||||||
|
return InkWell(
|
||||||
|
onTap: () {
|
||||||
|
///go to page ViewDoctorResponsesPage
|
||||||
|
Navigator.push(
|
||||||
|
context,
|
||||||
|
FadePage(
|
||||||
|
page: ViewDoctorResponsesPage(
|
||||||
|
doctorResponse: doctor,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
height: 70,
|
||||||
|
margin: EdgeInsets.only(top: 8, bottom: 8),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(8),
|
||||||
|
color: Colors.white,
|
||||||
|
border: Border.all(color: Colors.grey[300]),
|
||||||
|
),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment:
|
||||||
|
CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Texts('${doctor.doctorName}'),
|
||||||
|
SizedBox(
|
||||||
|
height: 5,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
'${doctor.requestTypeDescription}'),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Icon(projectViewModel.isArabic
|
||||||
|
? Icons.arrow_forward_ios
|
||||||
|
: Icons.arrow_back_ios)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
).toList(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
AppExpandableNotifier(
|
||||||
|
header: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Texts(TranslationBase.of(context).all),
|
||||||
|
Container(
|
||||||
|
width: 30,
|
||||||
|
height: 30,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
shape: BoxShape.circle,
|
||||||
|
color: Colors.red[800],
|
||||||
|
),
|
||||||
|
child: Center(
|
||||||
|
child: Texts(
|
||||||
|
'${model.doctorResponseList.length}',
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
bodyWidget: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: model.doctorResponseList.map(
|
||||||
|
(doctor) {
|
||||||
|
return InkWell(
|
||||||
|
onTap: () {},
|
||||||
|
child: Container(
|
||||||
|
height: 70,
|
||||||
|
margin: EdgeInsets.only(top: 8, bottom: 8),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(8),
|
||||||
|
color: Colors.white,
|
||||||
|
border: Border.all(color: Colors.grey[300]),
|
||||||
|
),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment:
|
||||||
|
CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Texts('${doctor.doctorName}'),
|
||||||
|
SizedBox(
|
||||||
|
height: 5,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
'${doctor.requestTypeDescription}'),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Icon(projectViewModel.isArabic
|
||||||
|
? Icons.arrow_forward_ios
|
||||||
|
: Icons.arrow_back_ios)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
).toList(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,134 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/enum/viewstate.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/ask_doctor_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/models/Appointments/DoctorListResponse.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/medical/balance/new_text_Field.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
class RequestTypePage extends StatefulWidget {
|
||||||
|
final DoctorList doctorList;
|
||||||
|
|
||||||
|
RequestTypePage({Key key, this.doctorList});
|
||||||
|
|
||||||
|
@override
|
||||||
|
_RequestTypePageState createState() => _RequestTypePageState();
|
||||||
|
}
|
||||||
|
|
||||||
|
class _RequestTypePageState extends State<RequestTypePage> {
|
||||||
|
String selected = "";
|
||||||
|
int parameterCode = -1;
|
||||||
|
String question = "";
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return BaseView<AskDoctorViewModel>(
|
||||||
|
onModelReady: (model) => model.getCallRequestTypeLOVs(),
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
isShowAppBar: true,
|
||||||
|
appBarTitle: TranslationBase.of(context).requestType,
|
||||||
|
baseViewModel: model,
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.all(10),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
...List.generate(
|
||||||
|
model.askDoctorReqTypes.length,
|
||||||
|
(index) => Container(
|
||||||
|
width: double.maxFinite,
|
||||||
|
height: 55,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
color: Colors.white,
|
||||||
|
borderRadius: BorderRadius.circular(8.0)),
|
||||||
|
margin: EdgeInsets.all(8.0),
|
||||||
|
child: InkWell(
|
||||||
|
onTap: () {
|
||||||
|
setState(() {
|
||||||
|
selected = model.askDoctorReqTypes[index].description;
|
||||||
|
parameterCode =
|
||||||
|
model.askDoctorReqTypes[index].parameterCode;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Text(
|
||||||
|
model.askDoctorReqTypes[index].description),
|
||||||
|
),
|
||||||
|
Radio(
|
||||||
|
value: model.askDoctorReqTypes[index].description,
|
||||||
|
groupValue: selected,
|
||||||
|
activeColor: Colors.red[800],
|
||||||
|
onChanged: (value) {
|
||||||
|
setState(() {
|
||||||
|
selected = value;
|
||||||
|
parameterCode = model
|
||||||
|
.askDoctorReqTypes[index].parameterCode;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
if (parameterCode == 6)
|
||||||
|
Container(
|
||||||
|
margin: EdgeInsets.only(left: 10, right: 10),
|
||||||
|
child: NewTextFields(
|
||||||
|
hintText: TranslationBase.of(context).questionHere,
|
||||||
|
minLines: 2,
|
||||||
|
maxLines: 15,
|
||||||
|
onChanged: (value) {
|
||||||
|
setState(() {
|
||||||
|
question = value;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
width: double.maxFinite,
|
||||||
|
height: MediaQuery.of(context).size.height * 0.2,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
bottomSheet: Container(
|
||||||
|
width: double.maxFinite,
|
||||||
|
height: MediaQuery.of(context).size.height * 0.1,
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(12.0),
|
||||||
|
child: SecondaryButton(
|
||||||
|
label: TranslationBase.of(context).submit,
|
||||||
|
loading: model.state == ViewState.BusyLocal,
|
||||||
|
textColor: Colors.white,
|
||||||
|
onTap: () {
|
||||||
|
model
|
||||||
|
.sendRequestLOV(
|
||||||
|
doctorList: widget.doctorList,
|
||||||
|
requestType: parameterCode.toString(),
|
||||||
|
remark: question)
|
||||||
|
.then((value) {
|
||||||
|
if (model.state != ViewState.ErrorLocal ||
|
||||||
|
model.state != ViewState.Error) {
|
||||||
|
Navigator.pop(context);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
color: Colors.grey[800],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,126 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/model/eye/AppoimentAllHistoryResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/EyeViewModel.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
class ClassesPage extends StatelessWidget {
|
||||||
|
final ListHISGetGlassPerscription glassPerscription;
|
||||||
|
|
||||||
|
const ClassesPage({Key key, this.glassPerscription}) : super(key: key);
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return BaseView<EyeViewModel>(
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.only(top: 70, left: 15, right: 15, bottom: 15),
|
||||||
|
child: Column(
|
||||||
|
children: [
|
||||||
|
Container(
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
shape: BoxShape.rectangle,
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(8)),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Texts(
|
||||||
|
TranslationBase.of(context).rightEye,
|
||||||
|
fontSize: 23,
|
||||||
|
bold: true,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
getRow(TranslationBase.of(context).sphere, '${glassPerscription.rightEyeSpherical}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).cylinder, '${glassPerscription.rightEyeCylinder}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).axis, '${glassPerscription.rightEyeAxis}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).prism, '${glassPerscription.rightEyePrism}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).va, '${glassPerscription.rightEyeVA}', '-'),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 17,
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
shape: BoxShape.rectangle,
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(8)),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Texts(
|
||||||
|
TranslationBase.of(context).leftEye,
|
||||||
|
fontSize: 23,
|
||||||
|
bold: true,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
getRow(TranslationBase.of(context).sphere, '${glassPerscription.leftEyeSpherical}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).cylinder, '${glassPerscription.leftEyeCylinder}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).axis, '${glassPerscription.leftEyeAxis}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).prism, '${glassPerscription.leftEyePrism}', '-'),
|
||||||
|
getRow(TranslationBase.of(context).va, '${glassPerscription.leftEyeVA}', '-'),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 17,
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
width: double.infinity,
|
||||||
|
child: SecondaryButton(
|
||||||
|
label: TranslationBase.of(context).sendEmail,
|
||||||
|
textColor: Colors.white,
|
||||||
|
color: Colors.red[700],
|
||||||
|
icon: Icon(
|
||||||
|
Icons.email,
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
Widget getRow(String title, String val1, String val2) => Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
mainAxisAlignment: MainAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Expanded(flex: 4, child: Texts(title)),
|
||||||
|
Expanded(
|
||||||
|
flex: 2,
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
children: [
|
||||||
|
Texts(val1 == 'null' ? '-' : val1),
|
||||||
|
Texts(val2 != 'null' ? '-' :val2),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
Divider()
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
@ -0,0 +1,129 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/model/eye/AppoimentAllHistoryResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
class ContactLensPage extends StatelessWidget {
|
||||||
|
final ListHISGetContactLensPerscription listHISGetContactLensPerscription;
|
||||||
|
|
||||||
|
const ContactLensPage({Key key, this.listHISGetContactLensPerscription})
|
||||||
|
: super(key: key);
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return AppScaffold(
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.only(top: 70, left: 15, right: 15, bottom: 15),
|
||||||
|
child: Column(
|
||||||
|
children: [
|
||||||
|
Container(
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
shape: BoxShape.rectangle,
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(8)),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Texts(
|
||||||
|
TranslationBase.of(context).rightEye,
|
||||||
|
fontSize: 23,
|
||||||
|
bold: true,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
getRow(TranslationBase.of(context).brand, '${listHISGetContactLensPerscription.brand}'),
|
||||||
|
getRow('B.C', '${listHISGetContactLensPerscription.baseCurve}'),
|
||||||
|
getRow(TranslationBase.of(context).power, '${listHISGetContactLensPerscription.power}'),
|
||||||
|
getRow(TranslationBase.of(context).diameter, '${listHISGetContactLensPerscription.diameter}'),
|
||||||
|
getRow('OZ', '${listHISGetContactLensPerscription.oZ}'),
|
||||||
|
getRow('CT', '${listHISGetContactLensPerscription.cT}'),
|
||||||
|
getRow('Blend', '${listHISGetContactLensPerscription.blend}'),
|
||||||
|
getRow(TranslationBase.of(context).reminder, '${listHISGetContactLensPerscription.remarks}'),
|
||||||
|
|
||||||
|
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 17,
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
shape: BoxShape.rectangle,
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(8)),
|
||||||
|
color: Colors.white),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Texts(
|
||||||
|
TranslationBase.of(context).leftEye,
|
||||||
|
fontSize: 23,
|
||||||
|
bold: true,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
getRow(TranslationBase.of(context).brand, '${listHISGetContactLensPerscription.brand}'),
|
||||||
|
getRow('B.C', '${listHISGetContactLensPerscription.baseCurve}'),
|
||||||
|
getRow(TranslationBase.of(context).power, '${listHISGetContactLensPerscription.power}'),
|
||||||
|
getRow(TranslationBase.of(context).diameter, '${listHISGetContactLensPerscription.diameter}'),
|
||||||
|
getRow('OZ', '${listHISGetContactLensPerscription.oZ}'),
|
||||||
|
getRow('CT', '${listHISGetContactLensPerscription.cT}'),
|
||||||
|
getRow('Blend', '${listHISGetContactLensPerscription.blend}'),
|
||||||
|
getRow(TranslationBase.of(context).reminder, '${listHISGetContactLensPerscription.remarks}'),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 17,
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
width: double.infinity,
|
||||||
|
child: SecondaryButton(
|
||||||
|
label: TranslationBase.of(context).sendEmail,
|
||||||
|
textColor: Colors.white,
|
||||||
|
color: Colors.red[700],
|
||||||
|
icon: Icon(
|
||||||
|
Icons.email,
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
Widget getRow(String title, String val1) => Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
children: [
|
||||||
|
Expanded(flex: 4, child: Texts(title)),
|
||||||
|
Expanded(
|
||||||
|
flex: 2,
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Texts(val1 == 'null' ? '-' : val1),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
Divider()
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
@ -0,0 +1,128 @@
|
|||||||
|
import 'dart:ui';
|
||||||
|
|
||||||
|
import 'package:diplomaticquarterapp/core/model/eye/AppoimentAllHistoryResult.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/EyeViewModel.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/weight_pressure_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
import 'ClassesPage.dart';
|
||||||
|
import 'ContactLensPage.dart';
|
||||||
|
|
||||||
|
class EyeHomePage extends StatefulWidget {
|
||||||
|
final AppoimentAllHistoryResultList appointmentAllHistoryResultList;
|
||||||
|
|
||||||
|
const EyeHomePage({Key key, this.appointmentAllHistoryResultList})
|
||||||
|
: super(key: key);
|
||||||
|
|
||||||
|
@override
|
||||||
|
_EyeHomePageState createState() => _EyeHomePageState();
|
||||||
|
}
|
||||||
|
|
||||||
|
class _EyeHomePageState extends State<EyeHomePage>
|
||||||
|
with SingleTickerProviderStateMixin {
|
||||||
|
TabController _tabController;
|
||||||
|
|
||||||
|
@override
|
||||||
|
void initState() {
|
||||||
|
super.initState();
|
||||||
|
_tabController = TabController(length: 2, vsync: this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
void dispose() {
|
||||||
|
super.dispose();
|
||||||
|
_tabController.dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return AppScaffold(
|
||||||
|
isShowAppBar: true,
|
||||||
|
appBarTitle: TranslationBase.of(context).measurements,
|
||||||
|
body: Scaffold(
|
||||||
|
extendBodyBehindAppBar: true,
|
||||||
|
appBar: PreferredSize(
|
||||||
|
preferredSize: Size.fromHeight(60.0),
|
||||||
|
child: Stack(
|
||||||
|
children: <Widget>[
|
||||||
|
Positioned(
|
||||||
|
bottom: 1,
|
||||||
|
left: 0,
|
||||||
|
right: 0,
|
||||||
|
child: BackdropFilter(
|
||||||
|
filter: ImageFilter.blur(sigmaX: 10, sigmaY: 10),
|
||||||
|
child: Container(
|
||||||
|
color: Theme.of(context)
|
||||||
|
.scaffoldBackgroundColor
|
||||||
|
.withOpacity(0.8),
|
||||||
|
height: 70.0,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Center(
|
||||||
|
child: Container(
|
||||||
|
height: 55.0,
|
||||||
|
margin: EdgeInsets.only(left: 20,right: 20,top: 15),
|
||||||
|
color: Colors.white,
|
||||||
|
child: Center(
|
||||||
|
child: TabBar(
|
||||||
|
isScrollable: true,
|
||||||
|
controller: _tabController,
|
||||||
|
indicatorWeight: 5.0,
|
||||||
|
indicatorSize: TabBarIndicatorSize.label,
|
||||||
|
indicatorColor: Colors.red[800],
|
||||||
|
labelColor: Theme.of(context).primaryColor,
|
||||||
|
labelPadding:
|
||||||
|
EdgeInsets.only(top: 4.0, left: 5.0, right: 5.0),
|
||||||
|
unselectedLabelColor: Colors.grey[800],
|
||||||
|
tabs: [
|
||||||
|
Container(
|
||||||
|
width: MediaQuery.of(context).size.width * 0.27,
|
||||||
|
child: Center(
|
||||||
|
child: Texts(TranslationBase.of(context).classes),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Container(
|
||||||
|
width: MediaQuery.of(context).size.width * 0.27,
|
||||||
|
child: Center(
|
||||||
|
child: Texts(TranslationBase.of(context).contactLens),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
body: Column(
|
||||||
|
children: <Widget>[
|
||||||
|
Expanded(
|
||||||
|
child: TabBarView(
|
||||||
|
physics: BouncingScrollPhysics(),
|
||||||
|
controller: _tabController,
|
||||||
|
children: <Widget>[
|
||||||
|
ClassesPage(
|
||||||
|
glassPerscription: widget.appointmentAllHistoryResultList
|
||||||
|
.listHISGetGlassPerscription[0],
|
||||||
|
),
|
||||||
|
ContactLensPage(
|
||||||
|
listHISGetContactLensPerscription: widget
|
||||||
|
.appointmentAllHistoryResultList
|
||||||
|
.listHISGetContactLensPerscription[0],
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,123 @@
|
|||||||
|
import 'package:diplomaticquarterapp/core/viewModels/medical/EyeViewModel.dart';
|
||||||
|
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
|
||||||
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
||||||
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/avatar/large_avatar.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/StarRating.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_expandable_notifier.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||||
|
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
|
||||||
|
import 'package:flutter/cupertino.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:provider/provider.dart';
|
||||||
|
|
||||||
|
import 'EyeHomePage.dart';
|
||||||
|
|
||||||
|
class EyeMeasurementsPage extends StatelessWidget {
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
ProjectViewModel projectViewModel = Provider.of(context);
|
||||||
|
return BaseView<EyeViewModel>(
|
||||||
|
onModelReady: (model) => model.getEyeMeasurement(),
|
||||||
|
builder: (_, model, w) => AppScaffold(
|
||||||
|
isShowAppBar: true,
|
||||||
|
baseViewModel: model,
|
||||||
|
appBarTitle: TranslationBase.of(context).eyeMeasurements,
|
||||||
|
body: SingleChildScrollView(
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.all(8),
|
||||||
|
child: Column(
|
||||||
|
children: [
|
||||||
|
...List.generate(
|
||||||
|
model.appointmentFilter.length,
|
||||||
|
(index) => AppExpandableNotifier(
|
||||||
|
title: model.appointmentFilter[index].filterName,
|
||||||
|
bodyWidget: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: model.appointmentFilter[index]
|
||||||
|
.appointmentAllHistoryResultList
|
||||||
|
.map((appointment) {
|
||||||
|
return InkWell(
|
||||||
|
onTap: () {
|
||||||
|
Navigator.push(
|
||||||
|
context,
|
||||||
|
FadePage(
|
||||||
|
page: EyeHomePage(
|
||||||
|
appointmentAllHistoryResultList: appointment,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.all(8),
|
||||||
|
padding: EdgeInsets.all(8.0),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(8),
|
||||||
|
color: Colors.white,
|
||||||
|
border: Border.all(color: Colors.grey),
|
||||||
|
),
|
||||||
|
child: Row(
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
flex: 1,
|
||||||
|
child: LargeAvatar(
|
||||||
|
name: appointment.doctorNameObj,
|
||||||
|
url: appointment.doctorImageURL,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
flex: 4,
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.all(10),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment:
|
||||||
|
CrossAxisAlignment.start,
|
||||||
|
children: <Widget>[
|
||||||
|
Texts(
|
||||||
|
appointment.doctorNameObj,
|
||||||
|
bold: true,
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
appointment.clinicName,
|
||||||
|
variant: 'caption3',
|
||||||
|
),
|
||||||
|
Texts(
|
||||||
|
DateUtil.getMonthDayYearDateFormatted(
|
||||||
|
appointment.bookDate),
|
||||||
|
variant: 'caption3',
|
||||||
|
),
|
||||||
|
StarRating(
|
||||||
|
totalAverage: appointment
|
||||||
|
.actualDoctorRate
|
||||||
|
.toDouble(),
|
||||||
|
forceStars: true),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Icon(
|
||||||
|
projectViewModel.isArabic
|
||||||
|
? Icons.arrow_forward_ios
|
||||||
|
: Icons.arrow_back_ios,
|
||||||
|
color: Colors.grey,
|
||||||
|
size: 18,
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}).toList(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||