This commit is contained in:
Mohamed Nouffer
2022-11-04 14:11:18 +05:30
parent 9987b243f7
commit d2517cd0bf
3 changed files with 96 additions and 17 deletions

View File

@ -148,6 +148,7 @@ class DestinationController extends GetxController {
//start
print("---- in start -----");
chekcs = 1;
is_in_checkin.value = true;
is_at_start.value = true;
showModalBottomSheet(context: Get.context!, isScrollControlled: true,
builder:((context) => BottomSheetNew())
@ -155,13 +156,14 @@ class DestinationController extends GetxController {
skip_gps = false;
chekcs = 0;
is_at_start.value = false;
is_in_checkin.value = false;
});
}
else
else if(is_in_rog.value == false)
{
print("----- in location popup checkin cp - ${d.cp}----");
chekcs = 2;
//is_in_checkin.value = true;
is_in_checkin.value = true;
showModalBottomSheet(context: Get.context!, isScrollControlled: true,
builder:((context) => BottomSheetNew())
).whenComplete((){
@ -185,8 +187,9 @@ class DestinationController extends GetxController {
}
}
else{
print("--- hidden loc ${d.hidden_location} ----");
// ask for checkin
if(d.hidden_location != null && d.hidden_location ==true && is_in_rog.value == true && d.cp != -1){
if(d.hidden_location != null && d.hidden_location == 0 && is_in_rog.value == true && d.cp != -1){
chekcs = 3;
is_in_checkin.value = true;
showModalBottomSheet(context: Get.context!, isScrollControlled: true,
@ -217,7 +220,7 @@ class DestinationController extends GetxController {
print("--- loc already checked in ${location_already_checked_in} ---");
if(isUser_logged_in && d.cp == -1 && location_already_checked_in){
//check for rogaining
if(is_at_goal.value == false && rogaining_counted.value){
if(is_at_goal.value == false && rogaining_counted.value && indexController.rog_mode == 1){
//goal
print("---- in goal -----");
chekcs = 5;
@ -230,7 +233,7 @@ class DestinationController extends GetxController {
is_at_goal.value = false;
});
}
else if(is_in_rog.value == false){
else if(is_in_rog.value == false && indexController.rog_mode == 1){
//start
print("---- in start -----");
chekcs = 6;