From 7910580f4bb0c6a0f14eee4cd6270c458eed1b97 Mon Sep 17 00:00:00 2001 From: "Yassine R." Date: Wed, 13 Dec 2023 20:31:09 +0100 Subject: [PATCH] feat(open-data): add soliguide link --- packages/backend/src/open-data-places/load-domifa.ts | 2 ++ packages/backend/src/run-app.ts | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/backend/src/open-data-places/load-domifa.ts b/packages/backend/src/open-data-places/load-domifa.ts index 42891e1080..f31f94a6fe 100644 --- a/packages/backend/src/open-data-places/load-domifa.ts +++ b/packages/backend/src/open-data-places/load-domifa.ts @@ -25,6 +25,7 @@ export const loadDomifaData = async () => { "latitude", "longitude", "email", + "structureType", "id", ], }); @@ -51,6 +52,7 @@ export const loadDomifaData = async () => { domifaStructureId: place.id, soliguideStructureId: null, mail: place.email, + structureType: place.structureType, uniqueId: place.id.toString(), }) ); diff --git a/packages/backend/src/run-app.ts b/packages/backend/src/run-app.ts index 7d69e3e7f2..cd5b496be0 100644 --- a/packages/backend/src/run-app.ts +++ b/packages/backend/src/run-app.ts @@ -17,7 +17,7 @@ import { domifaConfig } from "./config"; server.setTimeout(1000 * 60 * 5); appLogger.warn(`[${__filename}] Application listening on port 3000`); - if (domifaConfig().envId === "local") { + if (domifaConfig().envId === "local" && domifaConfig().cron.enable) { await loadDomifaData(); await loadSoliguideData(); // await loadDataInclusionData("CCAS");