diff --git a/i18n/en.pot b/i18n/en.pot index b0ac10ae..ffeebd66 100644 --- a/i18n/en.pot +++ b/i18n/en.pot @@ -5,8 +5,8 @@ msgstr "" "Content-Type: text/plain; charset=utf-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -"POT-Creation-Date: 2024-11-25T10:03:10.019Z\n" -"PO-Revision-Date: 2024-11-25T10:03:10.019Z\n" +"POT-Creation-Date: 2024-11-27T08:30:38.416Z\n" +"PO-Revision-Date: 2024-11-27T08:30:38.417Z\n" msgid "schemas" msgstr "schemas" @@ -891,6 +891,9 @@ msgstr "This field requires a unique value, please choose another one" msgid "{{label}} (required)" msgstr "{{label}} (required)" +msgid "Should not exceed {{maxLength}} characters" +msgstr "Should not exceed {{maxLength}} characters" + msgid "No changes to be saved" msgstr "No changes to be saved" @@ -1241,8 +1244,8 @@ msgstr "" "Choose where this new organisation unit should be placed in the existing " "hierarchy" -msgid "Set up the basic information for this organisation unit." -msgstr "Set up the basic information for this organisation unit." +msgid "Set up the basic information for this organisation unit" +msgstr "Set up the basic information for this organisation unit" msgid "Opening date" msgstr "Opening date" @@ -1311,6 +1314,22 @@ msgstr "" "This is the first organisation unit and will be created as the root of the " "hierarchy." +msgid "Must be a valid mobile number" +msgstr "Must be a valid mobile number" + +msgid "Must be a valid url" +msgstr "Must be a valid url" + +msgid "" +"Longitude should be between -90 and 90. Latitude should be between -180 and " +"180" +msgstr "" +"Longitude should be between -90 and 90. Latitude should be between -180 and " +"180" + +msgid "Parent organisation unit cannot be itself or a descendant of itself." +msgstr "Parent organisation unit cannot be itself or a descendant of itself." + msgid "No organisation units available" msgstr "No organisation units available" diff --git a/src/pages/indicatorTypes/form/IndicatorTypesSchema.ts b/src/pages/indicatorTypes/form/IndicatorTypesSchema.ts index 0c20681d..e530b214 100644 --- a/src/pages/indicatorTypes/form/IndicatorTypesSchema.ts +++ b/src/pages/indicatorTypes/form/IndicatorTypesSchema.ts @@ -7,11 +7,13 @@ export const IndicatorSchema = identifiable.extend({ factor: z.coerce .number({ invalid_type_error: 'Please enter a number' }) .int() - .min(1, 'Please enter a value above 0') .max( Number.MAX_SAFE_INTEGER, `The number is too large. Please enter a valid integer.` - ), + ) + .refine((value) => value !== 0, { + message: 'Zero is not a valid value for factor', + }), }) export const initialValues = getDefaults(IndicatorSchema)