diff --git a/.changeset/good-peaches-wave.md b/.changeset/good-peaches-wave.md new file mode 100644 index 000000000..0c0c9a3bf --- /dev/null +++ b/.changeset/good-peaches-wave.md @@ -0,0 +1,5 @@ +--- +"@nmi-agro/fdm-app": minor +--- + +Importing fields from RVO with eHerkenning sign-in is now available to all users diff --git a/fdm-app/app/routes/farm.$b_id_farm.$calendar.rvo.tsx b/fdm-app/app/routes/farm.$b_id_farm.$calendar.rvo.tsx index b904ba0c2..69342d1d0 100644 --- a/fdm-app/app/routes/farm.$b_id_farm.$calendar.rvo.tsx +++ b/fdm-app/app/routes/farm.$b_id_farm.$calendar.rvo.tsx @@ -14,8 +14,7 @@ import { type UserChoiceMap, } from "@nmi-agro/fdm-rvo/types" import { getItemId } from "@nmi-agro/fdm-rvo/utils" -import { AlertTriangle, CloudDownload, Loader2 } from "lucide-react" -import { useFeatureFlagEnabled } from "posthog-js/react" +import { AlertTriangle, Loader2 } from "lucide-react" import { useEffect, useState } from "react" import { type ActionFunctionArgs, @@ -225,8 +224,6 @@ export default function RvoImportReviewPage() { const navigation = useNavigation() const location = useLocation() - const isRvoEnabled = useFeatureFlagEnabled("rvo") - const isImporting = navigation.state === "submitting" && navigation.formData?.get("intent") === "start_import" @@ -298,39 +295,6 @@ export default function RvoImportReviewPage() { ) const hasChanges = Object.values(changes).some((count) => count > 0) - if (isRvoEnabled === false) { - return ( - -
- -
- -
-
- -

- Percelen ophalen bij RVO is nog niet beschikbaar - voor je. -

-

- Deze functionaliteit is momenteel in - ontwikkeling en is nog niet voor iedereen - beschikbaar. Neem contact op met Ondersteuning - als je hier vragen over hebt. -

-
-
-
-
- ) - } - if (error) { return ( diff --git a/fdm-app/app/routes/farm.$b_id_farm._index.tsx b/fdm-app/app/routes/farm.$b_id_farm._index.tsx index 7a784bb25..eec997ce0 100644 --- a/fdm-app/app/routes/farm.$b_id_farm._index.tsx +++ b/fdm-app/app/routes/farm.$b_id_farm._index.tsx @@ -25,7 +25,6 @@ import { Trash2, UserRoundCheck, } from "lucide-react" -import { useFeatureFlagEnabled } from "posthog-js/react" import { useState } from "react" import { data, @@ -156,7 +155,6 @@ export async function loader({ request, params }: LoaderFunctionArgs) { export default function FarmDashboardIndex() { const loaderData = useLoaderData() - const isRvoEnabled = useFeatureFlagEnabled("rvo") const calendar = useCalendarStore((state) => state.calendar) const setCalendar = useCalendarStore((state) => state.setCalendar) @@ -451,10 +449,8 @@ export default function FarmDashboardIndex() { - {loaderData.isRvoConfigured && - isRvoEnabled !== false && ( - () - const isRvoEnabled = useFeatureFlagEnabled("rvo") - const showRvoOption = isRvoConfigured && isRvoEnabled !== false + const showRvoOption = isRvoConfigured return ( diff --git a/fdm-app/app/routes/farm.create.$b_id_farm.$calendar.rvo.tsx b/fdm-app/app/routes/farm.create.$b_id_farm.$calendar.rvo.tsx index e8ea535b8..497c8aeca 100644 --- a/fdm-app/app/routes/farm.create.$b_id_farm.$calendar.rvo.tsx +++ b/fdm-app/app/routes/farm.create.$b_id_farm.$calendar.rvo.tsx @@ -12,8 +12,7 @@ import type { UserChoiceMap, } from "@nmi-agro/fdm-rvo/types" import { getItemId } from "@nmi-agro/fdm-rvo/utils" -import { AlertTriangle, CloudDownload, Loader2 } from "lucide-react" -import { useFeatureFlagEnabled } from "posthog-js/react" +import { AlertTriangle, Loader2 } from "lucide-react" import { useEffect, useState } from "react" import { type ActionFunctionArgs, @@ -198,8 +197,6 @@ export default function RvoImportCreatePage() { const navigation = useNavigation() const location = useLocation() - const isRvoEnabled = useFeatureFlagEnabled("rvo") - const isImporting = navigation.state === "submitting" && navigation.formData?.get("intent") === "start_import" @@ -249,33 +246,6 @@ export default function RvoImportCreatePage() { setUserChoices((prev: UserChoiceMap) => ({ ...prev, [id]: action })) } - if (isRvoEnabled === false) { - return ( - -
- -
- -
-
- -

- Percelen ophalen bij RVO is nog niet beschikbaar - voor je. -

-

- Deze functionaliteit is momenteel in - ontwikkeling en is nog niet voor iedereen - beschikbaar. Neem contact op met Ondersteuning - als je hier vragen over hebt. -

-
-
-
-
- ) - } - if (error) { return ( @@ -350,7 +320,7 @@ export default function RvoImportCreatePage() { De RVO koppeling is nog niet ingesteld op deze server. Neem contact op met de beheerder om de - RVO toeggangegevens toe te voegen. + RVO toegangsgegevens toe te voegen. diff --git a/fdm-app/app/routes/signin._index.tsx b/fdm-app/app/routes/signin._index.tsx index 8b17cfb7a..07e83979e 100644 --- a/fdm-app/app/routes/signin._index.tsx +++ b/fdm-app/app/routes/signin._index.tsx @@ -1296,14 +1296,11 @@ export default function SignIn() {

Start direct door uw percelen in te lezen - via een RVO shapefile. Uw percelen staan - binnen enkele seconden correct op de kaart, - inclusief het gewas. -

-

- Binnenkort heeft u ook de mogelijkheid - direct vanuit RVO percelen te importeren met - behulp van eHerkenning. + via een RVO shapefile of direct te + importeren vanuit RVO met behulp van + eHerkenning. Uw percelen staan daarmee + direct goed in de applicatie, inclusief het + gewas.