diff --git a/collect_app/src/androidTest/java/org/odk/collect/android/feature/formentry/FormEndTest.kt b/collect_app/src/androidTest/java/org/odk/collect/android/feature/formentry/FormEndTest.kt index f84d1aa92e1..78304e973f1 100644 --- a/collect_app/src/androidTest/java/org/odk/collect/android/feature/formentry/FormEndTest.kt +++ b/collect_app/src/androidTest/java/org/odk/collect/android/feature/formentry/FormEndTest.kt @@ -42,8 +42,8 @@ class FormEndTest { .assertNumberOfFinalizedForms(0) .clickDrafts(1) - .assertText(string.complete) - .assertTextDoesNotExist(string.incomplete) + .assertText(string.draft_no_errors) + .assertTextDoesNotExist(string.draft_errors) } @Test @@ -58,8 +58,8 @@ class FormEndTest { .assertNumberOfFinalizedForms(0) .clickDrafts(1) - .assertText(string.incomplete) - .assertTextDoesNotExist(string.complete) + .assertText(string.draft_errors) + .assertTextDoesNotExist(string.draft_no_errors) } @Test diff --git a/collect_app/src/androidTest/java/org/odk/collect/android/feature/formmanagement/BulkFinalizationTest.kt b/collect_app/src/androidTest/java/org/odk/collect/android/feature/formmanagement/BulkFinalizationTest.kt index d3745329e6f..715529bbef1 100644 --- a/collect_app/src/androidTest/java/org/odk/collect/android/feature/formmanagement/BulkFinalizationTest.kt +++ b/collect_app/src/androidTest/java/org/odk/collect/android/feature/formmanagement/BulkFinalizationTest.kt @@ -87,8 +87,8 @@ class BulkFinalizationTest { .clickFinalize() .checkIsSnackbarWithQuantityDisplayed(plurals.bulk_finalize_failure, 1) - .clickOptionsIcon(string.finalize_all_forms) - .clickOnString(string.finalize_all_forms) + .clickOptionsIcon(string.finalize_all_drafts) + .clickOnString(string.finalize_all_drafts) .clickOnButtonInDialog(string.finalize, EditSavedFormPage(false)) .checkIsSnackbarWithQuantityDisplayed(plurals.bulk_finalize_failure, 1) } @@ -106,8 +106,8 @@ class BulkFinalizationTest { .killAndReopenApp(MainMenuPage()) .clickDrafts(false) - .clickOptionsIcon(string.finalize_all_forms) - .clickOnString(string.finalize_all_forms) + .clickOptionsIcon(string.finalize_all_drafts) + .clickOnString(string.finalize_all_drafts) .checkIsSnackbarWithQuantityDisplayed(plurals.bulk_finalize_failure, 1) .assertText("One Question") .pressBack(MainMenuPage()) @@ -199,7 +199,7 @@ class BulkFinalizationTest { .clickSettings() .clickAccessControl() .clickFormEntrySettings() - .clickOnString(string.finalize_all_forms) + .clickOnString(string.finalize_all_drafts) .pressBack(AccessControlPage()) .pressBack(ProjectSettingsPage()) .pressBack(MainMenuPage()) diff --git a/collect_app/src/androidTest/java/org/odk/collect/android/support/pages/EditSavedFormPage.java b/collect_app/src/androidTest/java/org/odk/collect/android/support/pages/EditSavedFormPage.java index 6dccfed0995..de1f4f56a97 100644 --- a/collect_app/src/androidTest/java/org/odk/collect/android/support/pages/EditSavedFormPage.java +++ b/collect_app/src/androidTest/java/org/odk/collect/android/support/pages/EditSavedFormPage.java @@ -53,7 +53,7 @@ public EditSavedFormPage assertOnPage() { private void closeDraftsPillsEducationDialog() { if (firstOpen) { - assertText(org.odk.collect.strings.R.string.drafts_pills_education_title); + assertText(org.odk.collect.strings.R.string.new_feature); clickOKOnDialog(); } } @@ -108,8 +108,8 @@ public EditSavedFormPage searchInBar(String query) { } public BulkFinalizationConfirmationDialogPage clickFinalizeAll(int count) { - this.clickOptionsIcon(org.odk.collect.strings.R.string.finalize_all_forms) - .clickOnString(org.odk.collect.strings.R.string.finalize_all_forms); + this.clickOptionsIcon(org.odk.collect.strings.R.string.finalize_all_drafts) + .clickOnString(org.odk.collect.strings.R.string.finalize_all_drafts); return new BulkFinalizationConfirmationDialogPage(count).assertOnPage(); } diff --git a/collect_app/src/main/java/org/odk/collect/android/activities/InstanceChooserList.java b/collect_app/src/main/java/org/odk/collect/android/activities/InstanceChooserList.java index 53d0e7ecab0..cec7850fa1a 100644 --- a/collect_app/src/main/java/org/odk/collect/android/activities/InstanceChooserList.java +++ b/collect_app/src/main/java/org/odk/collect/android/activities/InstanceChooserList.java @@ -123,7 +123,7 @@ public void onCreate(Bundle savedInstanceState) { if (!settingsProvider.getMetaSettings().getBoolean(MetaKeys.DRAFTS_PILLS_EDUCATION_SHOWN)) { new MaterialAlertDialogBuilder(this) - .setTitle(string.drafts_pills_education_title) + .setTitle(string.new_feature) .setMessage(string.drafts_pills_education_message) .setPositiveButton(string.ok, null) .show(); diff --git a/collect_app/src/main/java/org/odk/collect/android/instancemanagement/InstanceListItemView.kt b/collect_app/src/main/java/org/odk/collect/android/instancemanagement/InstanceListItemView.kt index 910327106e9..2557fca0281 100644 --- a/collect_app/src/main/java/org/odk/collect/android/instancemanagement/InstanceListItemView.kt +++ b/collect_app/src/main/java/org/odk/collect/android/instancemanagement/InstanceListItemView.kt @@ -33,14 +33,14 @@ object InstanceListItemView { if (instance.status == Instance.STATUS_INVALID || instance.status == Instance.STATUS_INCOMPLETE) { pill.visibility = View.VISIBLE pill.setIcon(R.drawable.baseline_rule_24) - pill.setText(string.incomplete) + pill.setText(string.draft_errors) pill.setPillBackgroundColor(getThemeAttributeValue(context, com.google.android.material.R.attr.colorErrorContainer)) pill.setTextColor(getThemeAttributeValue(context, com.google.android.material.R.attr.colorOnErrorContainer)) pill.setIconTint(getThemeAttributeValue(context, com.google.android.material.R.attr.colorOnErrorContainer)) } else if (instance.status == Instance.STATUS_VALID) { pill.visibility = View.VISIBLE pill.setIcon(R.drawable.baseline_check_24) - pill.setText(string.complete) + pill.setText(string.draft_no_errors) pill.setPillBackgroundColor(getThemeAttributeValue(context, R.attr.colorSurfaceContainerHighest)) pill.setTextColor(getThemeAttributeValue(context, R.attr.colorOnSurfaceContainerHighest)) pill.setIconTint(getThemeAttributeValue(context, R.attr.colorOnSurfaceContainerHighest)) diff --git a/collect_app/src/main/res/menu/drafts.xml b/collect_app/src/main/res/menu/drafts.xml index 5ece8ef546b..a1411d3013a 100644 --- a/collect_app/src/main/res/menu/drafts.xml +++ b/collect_app/src/main/res/menu/drafts.xml @@ -3,6 +3,6 @@ + android:title="@string/finalize_all_drafts"> diff --git a/collect_app/src/main/res/xml/form_entry_access_preferences.xml b/collect_app/src/main/res/xml/form_entry_access_preferences.xml index 248e68eadac..d1884e1e061 100644 --- a/collect_app/src/main/res/xml/form_entry_access_preferences.xml +++ b/collect_app/src/main/res/xml/form_entry_access_preferences.xml @@ -54,7 +54,7 @@ app:iconSpaceReserved="false"> diff --git a/collect_app/src/test/java/org/odk/collect/android/instancemanagement/InstanceListItemViewTest.kt b/collect_app/src/test/java/org/odk/collect/android/instancemanagement/InstanceListItemViewTest.kt index a0cf26d9360..0d8a35f58cc 100644 --- a/collect_app/src/test/java/org/odk/collect/android/instancemanagement/InstanceListItemViewTest.kt +++ b/collect_app/src/test/java/org/odk/collect/android/instancemanagement/InstanceListItemViewTest.kt @@ -35,7 +35,7 @@ class InstanceListItemViewTest { InstanceListItemView.setInstance(binding.root, instance, false) assertThat(binding.chip.visibility, equalTo(View.VISIBLE)) - assertThat(binding.chip.text, equalTo(context.getString(string.incomplete))) + assertThat(binding.chip.text, equalTo(context.getString(string.draft_errors))) } @Test @@ -46,7 +46,7 @@ class InstanceListItemViewTest { InstanceListItemView.setInstance(binding.root, instance, false) assertThat(binding.chip.visibility, equalTo(View.VISIBLE)) - assertThat(binding.chip.text, equalTo(context.getString(string.complete))) + assertThat(binding.chip.text, equalTo(context.getString(string.draft_no_errors))) } @Test @@ -57,7 +57,7 @@ class InstanceListItemViewTest { InstanceListItemView.setInstance(binding.root, instance, false) assertThat(binding.chip.visibility, equalTo(View.VISIBLE)) - assertThat(binding.chip.text, equalTo(context.getString(string.incomplete))) + assertThat(binding.chip.text, equalTo(context.getString(string.draft_errors))) } @Test @@ -77,12 +77,12 @@ class InstanceListItemViewTest { InstanceListItemView.setInstance(binding.root, valid, false) assertThat(binding.chip.visibility, equalTo(View.VISIBLE)) - assertThat(binding.chip.text, equalTo(context.getString(string.complete))) + assertThat(binding.chip.text, equalTo(context.getString(string.draft_no_errors))) val invalid = InstanceFixtures.instance(status = Instance.STATUS_INVALID) InstanceListItemView.setInstance(binding.root, invalid, false) assertThat(binding.chip.visibility, equalTo(View.VISIBLE)) - assertThat(binding.chip.text, equalTo(context.getString(string.incomplete))) + assertThat(binding.chip.text, equalTo(context.getString(string.draft_errors))) } } diff --git a/strings/src/main/res/values/strings.xml b/strings/src/main/res/values/strings.xml index 643ebd291eb..c1f230b8439 100644 --- a/strings/src/main/res/values/strings.xml +++ b/strings/src/main/res/values/strings.xml @@ -1220,46 +1220,48 @@ In later versions, finalized forms will no longer be editable. - - Finalize all forms + + Finalize all drafts - - - Success! %d form finalized. - Success! %d forms finalized. + + + Do you want to finalize %d draft? + Do you want to finalize %d drafts? - - - %d form has an error. Address issues before finalizing all forms. - %d forms have errors. Address issues before finalizing all forms. + + Once you finalize all drafts, they will be in "Ready to send" and you will not be able to make edits. Any drafts that have errors will not be finalized.\n\nYou will not be able to undo this action. + + + + Success! %d draft finalized. + Success! %d drafts finalized. - - %d forms finalized. %d forms have errors. Address issues before finalizing all forms. + + + %d draft has errors that must be addressed before finalizing. + %d drafts have errors that must be addressed before finalizing. + - - Incomplete + + %d drafts finalized. %d drafts have errors that must be addressed before finalizing. - - Complete + + %d drafts finalized. Drafts that are left need to be finalized manually. - - %d forms finalized. Some forms need to be finalized manually. + + Errors - - Once you finalize all forms, they will be in "Ready to send" and you will not be able to make edits. Any forms that have errors will not be finalized.\n\nYou will not be able to undo this action. - - - - Do you want to finalize %d form? - Do you want to finalize %d forms? - + + No errors Uncheck to hide from Drafts - - Drafts have changed - The draft list now shows validation errors. Drafts marked with \"Errors\" are either missing required questions or have values that are not allowed. Each time you save a form as draft, its validation status is updated. + + New feature + + + The draft list now shows validation errors. Each time you save a form as draft, its validation status is updated.\n\nDrafts marked with \"Errors\" are either missing required questions or have values that are not allowed.