2024-09-02 ほぼOK
This commit is contained in:
@ -175,7 +175,12 @@ class BottomSheetNew extends GetView<BottomSheetController> {
|
||||
destinationController.currentLat, destinationController.currentLon),
|
||||
LatLng(cdest.lat!, cdest.lon!));
|
||||
|
||||
// Check conditions to show confirmation dialog
|
||||
// スタートボタン:
|
||||
// 表示条件:
|
||||
// 1. 目的地のCP番号が-1または0の場合
|
||||
// 2. ロゲイニングがまだ開始されていない場合(destinationController.isInRog.value == false)
|
||||
// 3. 最後のゴールから10時間以上経過している場合
|
||||
//
|
||||
if (destinationController.isInRog.value == false &&
|
||||
(destinationController.distanceToStart() <= 100 || destinationController.isGpsSignalWeak() ) && //追加 Akira 2024-4-5
|
||||
(destination.cp == -1 || destination.cp == 0 ) &&
|
||||
@ -294,7 +299,15 @@ class BottomSheetNew extends GetView<BottomSheetController> {
|
||||
//print("counted ${destinationController.rogainingCounted.value}");
|
||||
|
||||
|
||||
// ゴールボタン:
|
||||
// 表示条件:
|
||||
// 1. 目的地のCP番号が0、-2、または-1の場合
|
||||
// 2. ロゲイニングが開始されている場合(destinationController.rogainingCounted.value == true)
|
||||
// 3. スタート地点から500m以内にいる場合、または GPS信号が弱い場合
|
||||
// 4. ゴール準備完了フラグが立っている場合(DestinationController.ready_for_goal == true)
|
||||
//
|
||||
}else if (destinationController.rogainingCounted.value == true &&
|
||||
destinationController.isInRog.value == true &&
|
||||
// destinationController.distanceToStart() <= 500 && ... GPS信号が弱い時でもOKとする。
|
||||
(destinationController.distanceToStart() <= 500 || destinationController.isGpsSignalWeak() ) &&
|
||||
(destination.cp == 0 || destination.cp == -2 || destination.cp == -1) &&
|
||||
@ -334,7 +347,7 @@ class BottomSheetNew extends GetView<BottomSheetController> {
|
||||
}
|
||||
: null,
|
||||
child: Text(
|
||||
"finish_rogaining".tr,
|
||||
"finish_rogaining".tr, // ロゲゴール
|
||||
style: const TextStyle(color: Colors.white),
|
||||
));
|
||||
|
||||
@ -353,6 +366,9 @@ class BottomSheetNew extends GetView<BottomSheetController> {
|
||||
destinationController.isCheckingIn.value = true; // ここを追加
|
||||
Get.back();
|
||||
Get.back();
|
||||
if(destinationController.isInRog.value==false && destination.cp == -1){
|
||||
destinationController.rogainingCounted.value = false;
|
||||
}
|
||||
await Future.delayed(const Duration(milliseconds: 500));
|
||||
await destinationController.callforCheckin(destination);
|
||||
destinationController.isCheckingIn.value = false;
|
||||
@ -371,8 +387,8 @@ class BottomSheetNew extends GetView<BottomSheetController> {
|
||||
},
|
||||
child: Text(
|
||||
destination.cp == -1 &&
|
||||
destinationController.isInRog.value == false &&
|
||||
destinationController.rogainingCounted.value == false
|
||||
destinationController.isInRog.value == false //&&
|
||||
//destinationController.rogainingCounted.value == false
|
||||
? "ロゲ開始"
|
||||
: destinationController.isInRog.value == true &&
|
||||
destination.cp == -1
|
||||
|
||||
Reference in New Issue
Block a user