diff --git a/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/SyncInfoFragment.kt b/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/SyncInfoFragment.kt index 8bc60e4b10..f5285274a2 100644 --- a/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/SyncInfoFragment.kt +++ b/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/SyncInfoFragment.kt @@ -263,7 +263,7 @@ internal class SyncInfoFragment : Fragment(R.layout.fragment_sync_info) { // Footer val isFooterSyncInProgressVisible = config.isSyncInfoLogoutOnComplete && records.isFooterSyncInProgressVisible binding.textFooterRecordSyncInProgress.isGone = !isFooterSyncInProgressVisible - binding.textFooterRecordLoggingOut.isGone = !records.isFooterReadyToLogOutVisible + binding.layoutFooterRecordLoggingOut.isGone = !records.isFooterReadyToLogOutVisible binding.textFooterRecordSyncIncomplete.isGone = !records.isFooterSyncIncompleteVisible binding.textFooterRecordLastSyncedWhen.isGone = !records.isFooterLastSyncTimeVisible binding.textFooterRecordLastSyncedWhen.text = diff --git a/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCase.kt b/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCase.kt index 4652e62a35..082901a8b8 100644 --- a/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCase.kt +++ b/feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCase.kt @@ -287,7 +287,7 @@ internal class ObserveSyncInfoUseCase @Inject constructor( counterRecordsToDownload = recordsToDownload?.let { "${it.count}${if (it.isLowerBound) "+" else ""}" }.orEmpty(), isCounterImagesToUploadVisible = isPreLogoutUpSync, counterImagesToUpload = imagesToUpload?.toString().orEmpty(), - isInstructionDefaultVisible = eventSyncVisibleState == OnStandby, + isInstructionDefaultVisible = eventSyncVisibleState == OnStandby && !isPreLogoutUpSync, isInstructionCommCarePermissionVisible = eventSyncVisibleState == CommCareError, isInstructionNoModulesVisible = eventSyncVisibleState == NoModulesError, isInstructionOfflineVisible = eventSyncVisibleState == OfflineError, diff --git a/feature/dashboard/src/main/res/layout/fragment_sync_info.xml b/feature/dashboard/src/main/res/layout/fragment_sync_info.xml index 92dbd89cb8..5d935330a9 100644 --- a/feature/dashboard/src/main/res/layout/fragment_sync_info.xml +++ b/feature/dashboard/src/main/res/layout/fragment_sync_info.xml @@ -552,16 +552,39 @@ android:text="@string/sync_info_footer_sync_incomplete" android:visibility="gone" /> - + android:visibility="gone"> + + + + + + @@ -815,4 +838,3 @@ - diff --git a/feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCaseTest.kt b/feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCaseTest.kt index 6778a0a733..9c2c7a59e4 100644 --- a/feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCaseTest.kt +++ b/feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/syncinfo/usecase/ObserveSyncInfoUseCaseTest.kt @@ -1050,6 +1050,24 @@ class ObserveSyncInfoUseCaseTest { assertThat(result.syncInfoSectionRecords.isInstructionDefaultVisible).isTrue() } + @Test + fun `should hide default instruction for pre-logout sync`() = runTest { + createUseCase() + + val result = useCase(isPreLogoutUpSync = true).first() + + assertThat(result.syncInfoSectionRecords.isInstructionDefaultVisible).isFalse() + } + + @Test + fun `should not hide default instruction for regular non-pre-logout sync`() = runTest { + createUseCase() + + val result = useCase().first() + + assertThat(result.syncInfoSectionRecords.isInstructionDefaultVisible).isTrue() + } + @Test fun `sync button should be disabled when not on standby`() = runTest { val mockSyncingEventSyncState = mockk(relaxed = true) { diff --git a/infra/resources/src/main/res/values-am-rET/strings.xml b/infra/resources/src/main/res/values-am-rET/strings.xml index 85debd634e..c2d9f38aef 100644 --- a/infra/resources/src/main/res/values-am-rET/strings.xml +++ b/infra/resources/src/main/res/values-am-rET/strings.xml @@ -445,7 +445,6 @@ መውጣት ሳይመሳሰል ውጣ - በመሳሪያዎ ላይ ከመውጣትዎ በፊት መመሳሰል ያለባቸው መዝገቦች አሉ። እባክህ የማመሳሰል ሂደቱ እንዲጠናቀቅ ፍቀድ። ማመሳሰል እንደጨረሰ ዘግተህ መውጣት ትችላለህ። ማስጠንቀቂያ የእርስዎ ፕሮጀክት ወቅታዊ መዛግብት እንዳለው ለማረጋገጥ የውሂብ ማመሳሰል አስፈላጊ ነው። ያለ ትክክለኛ ምክንያት የእርስዎን ውሂብ ማመሳሰል አለመቻል የስራ ባልደረቦችዎ ጠቃሚ መዝገቦችን ማግኘት እና የፕሮጀክቱን ትክክለኛ ሪፖርት የማድረግ ችሎታ ላይ ተጽእኖ ያሳድራል። እና ለእርስዎ እና ለፕሮጀክቱ የማይፈለጉ ውጤቶችን ሊያስከትል ይችላል. መውጣት diff --git a/infra/resources/src/main/res/values-am/strings.xml b/infra/resources/src/main/res/values-am/strings.xml index 5cdd03b217..3ea4355117 100644 --- a/infra/resources/src/main/res/values-am/strings.xml +++ b/infra/resources/src/main/res/values-am/strings.xml @@ -448,7 +448,6 @@ መውጣት ሳይመሳሰል ውጣ - በመሳሪያዎ ላይ ከመውጣትዎ በፊት መመሳሰል ያለባቸው መዝገቦች አሉ። እባክህ የማመሳሰል ሂደቱ እንዲጠናቀቅ ፍቀድ።\n\nአንዴ ማመሳሰል እንደተጠናቀቀ ዘግተህ መውጣት ትችላለህ። ማስጠንቀቂያ የእርስዎ ፕሮጀክት ወቅታዊ መዛግብት እንዳለው ለማረጋገጥ የውሂብ ማመሳሰል አስፈላጊ ነው። ያለ ትክክለኛ ምክንያት የእርስዎን ውሂብ ማመሳሰል አለመቻል የስራ ባልደረቦችዎ ጠቃሚ መዝገቦችን ማግኘት እና የፕሮጀክቱን ትክክለኛ ሪፖርት የማድረግ ችሎታ ላይ ተጽእኖ ያሳድራል። እና ለእርስዎ እና ለፕሮጀክቱ የማይፈለጉ ውጤቶችን ሊያስከትል ይችላል. መውጣት diff --git a/infra/resources/src/main/res/values-bn/strings.xml b/infra/resources/src/main/res/values-bn/strings.xml index bce3802e17..6eb8190ad6 100644 --- a/infra/resources/src/main/res/values-bn/strings.xml +++ b/infra/resources/src/main/res/values-bn/strings.xml @@ -444,7 +444,6 @@ লগআউট করুন সিঙ্ক ব্যাতিত লগ আউট করুন - আপনার এই ডিভাইসে কিছু তথ্য সংরক্ষিত আছে যা সিঙ্ক করা প্রয়োজন। অনুগ্রহ করে সিঙ্ক প্রক্রিয়া সম্পন্ন করুণ। \n\nসিঙ্ক প্রক্রিয়া সম্পন্ন হলে লগ আউট করতে পারবেন। সতর্কতা আপনার প্রকল্পের সকল রেকর্ড আপ-টু-ডেট রয়েছে তা নিশ্চিত করার জন্য ডেটা সিঙ্ক্রোনাইজেশন অপরিহার্য। কোনো বৈধ কারণ ছাড়া ডেটা সিঙ্ক্রোনাইজ করতে ব্যর্থ হলে তা আপনার সহকর্মীদের গুরুত্বপূর্ণ রেকর্ডে অ্যাক্সেস এবং প্রকল্পের সঠিকভাবে রিপোর্ট করার ক্ষমতাকে প্রভাবিত করবে।\n\nকোনও বৈধ কারণ ছাড়া ডেটা সিঙ্ক্রোনাইজ করতে ব্যর্থ হওয়া ডেটা সংগ্রহ প্রোটোকলের লঙ্ঘনও হিসেবে গণ্য হতে পারে যার ফলে প্রকল্পের অবাঞ্ছিত পরিণতি হবার সুযোগ থাকে। লগআউট করুন diff --git a/infra/resources/src/main/res/values-fr/strings.xml b/infra/resources/src/main/res/values-fr/strings.xml index 0ee536dbdd..5788387486 100644 --- a/infra/resources/src/main/res/values-fr/strings.xml +++ b/infra/resources/src/main/res/values-fr/strings.xml @@ -448,7 +448,6 @@ Déconnexion Se déconnecter sans synchronisation - Il y a des enregistrements sur votre appareil qui doivent être synchronisés avant de vous déconnecter. Veuillez laisser le processus de synchronisation se terminer.\n\nUne fois la synchronisation terminée, vous pourrez vous déconnecter. Avertissement La synchronisation des données est essentielle pour garantir que votre projet dispose d\'enregistrements à jour. Ne pas synchroniser vos données sans raison valable aura un impact sur l\'accès de vos collègues aux enregistrements importants et sur la capacité du projet à générer des rapports précis.\n\nNe pas synchroniser les données sans raison valable peut également constituer une violation du protocole de collecte de données et peut entraîner des conséquences indésirables pour vous et le projet. Déconnexion diff --git a/infra/resources/src/main/res/values-hi/strings.xml b/infra/resources/src/main/res/values-hi/strings.xml index f44a37f5ff..6e46687bfb 100644 --- a/infra/resources/src/main/res/values-hi/strings.xml +++ b/infra/resources/src/main/res/values-hi/strings.xml @@ -440,7 +440,6 @@ लॉग-आउट डेटा सिंक किए बिना लॉग आउट करें - आपके डिवाइस पर ऐसे रिकॉर्ड हैं जिन्हें लॉग आउट करने से पहले सिंक्रनाइज़ करने की आवश्यकता है। कृपया सिंक्रोनाइज़ेशन प्रक्रिया को पूरा होने दें।\n\nएक बार सिंक्रोनाइज़ेशन समाप्त हो जाने पर आप लॉग आउट कर सकेंगे। चेतावनी यह सुनिश्चित करने के लिए कि आपके प्रोजेक्ट में अद्यतन रिकॉर्ड हैं, डेटा सिंक्रनाइज़ेशन आवश्यक है। बिना किसी वैध कारण के आपके डेटा को सिंक्रोनाइज़ करने में विफल रहने से आपके सहकर्मियों की महत्वपूर्ण रिकॉर्ड तक पहुंच और प्रोजेक्ट की सटीक रिपोर्ट करने की क्षमता प्रभावित होगी।\n\nबिना किसी वैध कारण के डेटा को सिंक्रोनाइज़ करने में विफल होना भी डेटा संग्रह प्रोटोकॉल का उल्लंघन हो सकता है और इसके परिणामस्वरूप आपके और प्रोजेक्ट के लिए अवांछित परिणाम हो सकते हैं। लॉग-आउट diff --git a/infra/resources/src/main/res/values-om/strings.xml b/infra/resources/src/main/res/values-om/strings.xml index 95f3c09178..95a1416894 100644 --- a/infra/resources/src/main/res/values-om/strings.xml +++ b/infra/resources/src/main/res/values-om/strings.xml @@ -347,7 +347,6 @@ Keessaa bahi Walsimsiisaa malee ba\'aa - Meeshaa keessan irratti galmeewwan osoo hin ba\'iin dura walsimsiisuu qaban jiru. Mee adeemsi walsimsiisaa akka xumuramu hayyami.Erga walsimsiisni xumurame bahuu ni dandeessa. Akeekkachiisa Pirojektiin kee galmee yeroo ammaa akka qabu mirkaneessuuf walsimsiisni deetaa barbaachisaa dha. Sababa sirrii malee deetaa kee walsimsiisuu dadhabuun galmeewwan barbaachisoo ta\'uu fi dandeettii pirojektichi sirritti gabaasuu irratti dhiibbaa qaba.\n\nSababni sirrii malee deetaa walsimsiisuu dadhabuunis pirootokoolii walitti qabuu deetaa cabsuu ta\'uu danda\'a akkasumas bu’aa hin barbaachifne siifi pirojektichaaf fiduu danda’a. Keessaa bahi diff --git a/infra/resources/src/main/res/values/strings.xml b/infra/resources/src/main/res/values/strings.xml index 4efcecae4b..b1ceb968d1 100644 --- a/infra/resources/src/main/res/values/strings.xml +++ b/infra/resources/src/main/res/values/strings.xml @@ -372,6 +372,8 @@ Total records + Last sync: %1$s + Sync in progress Sync incomplete Sync complete, logging you out… @@ -446,7 +448,7 @@ Logout Log out without sync - There are records on your device that need to be synchronised before logging out. Please allow the synchronisation process to complete.\n\nOnce the synchronization is finished you will be able to log out. + Records on your device will be automatically synchronised before logging out. Please allow the synchronisation process to complete.\n\nOnce the synchronization is finished you will be able to log out. Warning Data synchronisation is essential for ensuring your project has up-to-date records. Failing to synchronise your data without a valid reason will impact your colleagues\' access to important records and the project\'s ability to report accurately.\n\nFailing to synchronise data without a valid reason may also be a breach of data collection protocol and may result in unwanted consequences for you and the project. Logout