Commit bf61b097 authored by Izol's avatar Izol

fix_idle_back_phonevalidation_denom&&fixed_background_service_injury_time_30_seconds

parent a3814f63
This diff is collapsed.
......@@ -15,15 +15,15 @@
</component>
<component name="ChangeListManager">
<list default="true" id="8704a1d9-96ef-4cdc-ac57-c88bc9c0306e" name="Default Changelist" comment="">
<change beforePath="$PROJECT_DIR$/.flutter-plugins-dependencies" beforeDir="false" afterPath="$PROJECT_DIR$/.flutter-plugins-dependencies" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/7.4/checksums/checksums.lock" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/7.4/checksums/checksums.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/7.4/dependencies-accessors/dependencies-accessors.lock" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/7.4/dependencies-accessors/dependencies-accessors.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/7.4/executionHistory/executionHistory.bin" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/7.4/executionHistory/executionHistory.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/7.4/executionHistory/executionHistory.lock" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/7.4/executionHistory/executionHistory.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/7.4/fileHashes/fileHashes.bin" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/7.4/fileHashes/fileHashes.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/7.4/fileHashes/fileHashes.lock" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/7.4/fileHashes/fileHashes.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/buildOutputCleanup/outputFiles.bin" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/buildOutputCleanup/outputFiles.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.gradle/file-system.probe" beforeDir="false" afterPath="$PROJECT_DIR$/android/.gradle/file-system.probe" afterDir="false" />
<change beforePath="$PROJECT_DIR$/android/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/android/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/daemon/7.4/registry.bin" beforeDir="false" afterPath="$PROJECT_DIR$/daemon/7.4/registry.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/daemon/7.4/registry.bin.lock" beforeDir="false" afterPath="$PROJECT_DIR$/daemon/7.4/registry.bin.lock" afterDir="false" />
......
......@@ -13,21 +13,17 @@
<option name="autoReloadType" value="NONE" />
</component>
<component name="ChangeListManager">
<list default="true" id="67682c65-0998-4576-a05a-80519b1456cd" name="Changes" comment="">
<list default="true" id="562556ad-c07b-4e55-a51b-fa66738ba528" name="Changes" comment="">
<change beforePath="$PROJECT_DIR$/../.flutter-plugins-dependencies" beforeDir="false" afterPath="$PROJECT_DIR$/../.flutter-plugins-dependencies" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/../.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/checksums/checksums.lock" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/checksums/checksums.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/checksums/md5-checksums.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/checksums/md5-checksums.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/checksums/sha1-checksums.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/checksums/sha1-checksums.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/executionHistory/executionHistory.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/executionHistory/executionHistory.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/executionHistory/executionHistory.lock" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/executionHistory/executionHistory.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/fileHashes/fileHashes.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/fileHashes/fileHashes.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/fileHashes/fileHashes.lock" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/fileHashes/fileHashes.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/7.4/fileHashes/resourceHashesCache.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/7.4/fileHashes/resourceHashesCache.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/buildOutputCleanup/buildOutputCleanup.lock" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/buildOutputCleanup/buildOutputCleanup.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/buildOutputCleanup/outputFiles.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/buildOutputCleanup/outputFiles.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.gradle/file-system.probe" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/file-system.probe" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/app/debug/app-debug.apk" beforeDir="false" afterPath="$PROJECT_DIR$/app/debug/app-debug.apk" afterDir="false" />
<change beforePath="$PROJECT_DIR$/app/release/app-release.apk" beforeDir="false" afterPath="$PROJECT_DIR$/app/release/app-release.apk" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../daemon/7.4/registry.bin" beforeDir="false" afterPath="$PROJECT_DIR$/../daemon/7.4/registry.bin" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../daemon/7.4/registry.bin.lock" beforeDir="false" afterPath="$PROJECT_DIR$/../daemon/7.4/registry.bin.lock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../lib/ui/pages/home_page.dart" beforeDir="false" afterPath="$PROJECT_DIR$/../lib/ui/pages/home_page.dart" afterDir="false" />
......@@ -37,40 +33,30 @@
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
<option name="LAST_RESOLUTION" value="IGNORE" />
</component>
<component name="ExecutionTargetManager" SELECTED_TARGET="device_and_snapshot_combo_box_target[192.168.62.108:5555]" />
<component name="ExecutionTargetManager" SELECTED_TARGET="device_and_snapshot_combo_box_target[192.168.164.108:5555]" />
<component name="ExternalProjectsData">
<projectState path="$PROJECT_DIR$">
<ProjectState />
</projectState>
</component>
<component name="GenerateSignedApkSettings">
<option name="KEY_STORE_PATH" value="C:\Users\MDD HP\Downloads\com.mdd.trendpos.jks" />
<option name="KEY_ALIAS" value="dolan-self-service" />
<option name="REMEMBER_PASSWORDS" value="true" />
<option name="BUILD_TARGET_KEY" value="apk" />
</component>
<component name="Git.Settings">
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$/.." />
</component>
<component name="MarkdownSettingsMigration">
<option name="stateVersion" value="1" />
</component>
<component name="ProjectId" id="2IKtyqelZZSp7IvHoVXCPaWLQWQ" />
<component name="ProjectId" id="2IM1zUmuC9H1d1nyxuQxLKL4VgW" />
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
<component name="ProjectViewState">
<option name="hideEmptyMiddlePackages" value="true" />
<option name="showLibraryContents" value="true" />
</component>
<component name="PropertiesComponent">
<property name="ApkExportedModule" value="android.app" />
<property name="ExportApk.ApkPath" value="C:\Users\MDD HP\dolan-selfservice-master\android\app" />
<property name="ExportApk.BuildVariants" value="debug&#10;release" />
<property name="RunOnceActivity.OpenProjectViewOnStart" value="true" />
<property name="RunOnceActivity.ShowReadmeOnStart" value="true" />
<property name="RunOnceActivity.cidr.known.project.marker" value="true" />
<property name="cidr.known.project.marker" value="true" />
<property name="dart.analysis.tool.window.visible" value="false" />
<property name="last_opened_file_path" value="$USER_HOME$/Downloads/com.mdd.trendpos.jks" />
<property name="show.migrate.to.gradle.popup" value="false" />
</component>
<component name="RunManager">
......@@ -137,11 +123,11 @@
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
<component name="TaskManager">
<task active="true" id="Default" summary="Default task">
<changelist id="67682c65-0998-4576-a05a-80519b1456cd" name="Changes" comment="" />
<created>1669942360930</created>
<changelist id="562556ad-c07b-4e55-a51b-fa66738ba528" name="Changes" comment="" />
<created>1669976901638</created>
<option name="number" value="Default" />
<option name="presentableId" value="Default" />
<updated>1669942360930</updated>
<updated>1669976901638</updated>
</task>
<servers />
</component>
......
No preview for this file type
......@@ -74,7 +74,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
late Timer? timer;
bool isShowingDialog = false;
// now
var infoCard,
balance,
cardExpirity,
......@@ -342,6 +342,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
isHitApi = false;
} else {
print('topup gagal');
isShowingDialog = true;
// String companyName, companyPhone, denom;
// companyName = PreferencesHelper.getString('outletname');
......@@ -447,6 +448,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
} else {
AwesomeDialog(
context: context,
dismissOnTouchOutside: false,
dialogType: DialogType.error,
animType: AnimType.rightSlide,
headerAnimationLoop: true,
......@@ -459,6 +461,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
}else{
AwesomeDialog(
context: context,
dismissOnTouchOutside: false,
dialogType: DialogType.error,
animType: AnimType.rightSlide,
headerAnimationLoop: true,
......@@ -469,7 +472,6 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
String companyPhone = PreferencesHelper.getString('companyphone');
String companyAddress = PreferencesHelper.getString('companyaddress');
String denoms = amountController!.text.replaceAll(",", "");
Navigator.pop(context);
infoM = await StartService.print(
info,
companyName.split("-")[0],
......@@ -481,6 +483,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
(int.parse("10") + int.parse("1") + int.parse("0")).toString(),
denoms
);
Navigator.pop(context);
},
btnOkIcon: Icons.cancel,
btnOkColor: Colors.red)
......@@ -490,13 +493,13 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
btnOkIcon: Icons.cancel,
btnOkColor: Colors.red)
.show();
Future.delayed(Duration(seconds: int.parse(idle)), () {
Navigator.pop(context);
timer?.cancel();
isShowingDialog = true;
_showTap();
tapDial();
});
// Future.delayed(Duration(seconds: int.parse(idle)), () {
// Navigator.pop(context);
// timer?.cancel();
// isShowingDialog = true;
// _showTap();
// tapDial();
// });
}
}
});
......@@ -655,6 +658,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
void tapIdle() {
timer = Timer.periodic(Duration(seconds: int.parse(idle)), (timer) {
print("ini pesan waktu idle : $idle");
print("isShowingdialog : $isShowingDialog");
if (!isShowingDialog) {
isShowingDialog = true;
timer?.cancel();
......@@ -788,7 +792,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
}
Future<void> showPop(String approvalCode) async {
isShowingDialog = true;
if (timer != null) timer?.cancel();
// Future.delayed(Duration(seconds: 10), () {
// topUpBalance(approvalCode);
// });
......@@ -858,7 +862,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
);
}
Future<void> phone4CharValidation(String subPhone, String info) async {
Future<void> phone4CharValidation(String subPhone, String info, idle) async {
showDialog(
context: context,
builder: (context) {
......@@ -876,6 +880,9 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
alignment: Alignment.topLeft,
child: GestureDetector(
onTap: () {
setState((){
isShowingDialog = false;
});
Navigator.pop(context);
if (timer != null) timer?.cancel();
tapIdle();
......@@ -1077,6 +1084,9 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
child: GestureDetector(
onTap: () {
Navigator.pop(context);
setState((){
isShowingDialog =false;
});
if (timer != null) timer?.cancel();
tapIdle();
},
......@@ -1371,7 +1381,6 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
if (timer != null)
timer?.cancel();
// tapIdle();
if (mounted) {
denomLimits(
outletName,
......@@ -1761,7 +1770,8 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
// todo for checking in 30 seconds lates
// debugPrint("values in seconds ${value.inSeconds}");
debugPrint("ini pesan second: ${seconds}");
if (int.parse(seconds) == int.parse("30")) {
debugPrint("ini pesan minutes: ${minutes}");
if (minutes == '00' && int.parse(seconds) == int.parse("30") ) {
if (!isHitApi) {
isHitApi = true;
_cekStatus(isBackgroundServices: true);
......@@ -2146,7 +2156,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
fullPhone.length - 4, fullPhone.length);
// Navigator.pop(context);
// _topUp(outletName, info);
phone4CharValidation(subPhone, infoCard);
phone4CharValidation(subPhone, infoCard, idle);
} else {
AwesomeDialog(
context: context,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment