From 43f23115af1dc39d034e0cbb03c62e37239d8f95 Mon Sep 17 00:00:00 2001 From: isa Date: Wed, 22 May 2024 18:17:07 +0200 Subject: [PATCH] my config --- .env.local | 4 +++- components/MapComponent.js | 4 ++-- config/config.js | 8 ++++---- pages/api/[...path].js | 3 ++- pages/api/readPoiTyp.js | 2 +- 5 files changed, 12 insertions(+), 9 deletions(-) diff --git a/.env.local b/.env.local index 9ef524593..d20fccec5 100644 --- a/.env.local +++ b/.env.local @@ -1,4 +1,6 @@ -DB_HOST=localhost + +#DB_HOST=localhost +DB_HOST=192.168.10.58 DB_USER=root DB_PASSWORD="root#$" DB_NAME=talas_v5 diff --git a/components/MapComponent.js b/components/MapComponent.js index 6f3a61174..50a9163c7 100644 --- a/components/MapComponent.js +++ b/components/MapComponent.js @@ -71,8 +71,8 @@ const MapComponent = ({ locations, onLocationUpdate }) => { const zoomTrigger = useRecoilValue(zoomTriggerState); const offlineTileLayer = "/mapTiles/{z}/{x}/{y}.png"; //const onlineTileLayer = "/mapTiles/{z}/{x}/{y}.png"; - //const onlineTileLayer = "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"; - const onlineTileLayer = "http://10.10.0.13:3000/mapTiles/{z}/{x}/{y}.png"; //Talas_v5 Server + const onlineTileLayer = "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"; + //const onlineTileLayer = "http://10.10.0.13:3000/mapTiles/{z}/{x}/{y}.png"; //Talas_v5 Server // Create map layers const TALAS = new L.layerGroup(); const ECI = new L.layerGroup(); diff --git a/config/config.js b/config/config.js index 323a9fc1a..438c781ba 100644 --- a/config/config.js +++ b/config/config.js @@ -24,17 +24,17 @@ if (typeof window !== "undefined") { // Konstruktion von URLs, die auf spezifische Ressourcen auf dem Server zeigen //http://localhost:3000/?m=10&u=485 - mapGisStationsStaticDistrictUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsStaticDistrict?idMap=${c}&idUser=${user}`; //idMap: 10, idUser: 484 + /* mapGisStationsStaticDistrictUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsStaticDistrict?idMap=${c}&idUser=${user}`; //idMap: 10, idUser: 484 mapGisStationsStatusDistrictUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsStatusDistrict?idMap=${c}&idUser=${user}`; mapGisStationsMeasurementsUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsMeasurements?idMap=${c}`; mapGisSystemStaticUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisSystemStatic?idMap=${c}&idUser=${user}`; - mapDataIconUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GetIconsStatic`; + mapDataIconUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GetIconsStatic`; */ - /* mapGisStationsStaticDistrictUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsStaticDistrict`; + mapGisStationsStaticDistrictUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsStaticDistrict`; mapGisStationsStatusDistrictUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsStatusDistrict`; mapGisStationsMeasurementsUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisStationsMeasurements`; mapGisSystemStaticUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GisSystemStatic`; - mapDataIconUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GetIconsStatic`; */ + mapDataIconUrl = `${serverURL}/talas5/ClientData/WebserviceMap.asmx/GetIconsStatic`; } // Export der definierten Variablen und URLs, damit sie in anderen Teilen der Anwendung verwendet werden können diff --git a/pages/api/[...path].js b/pages/api/[...path].js index 299b2253b..e35627ffb 100644 --- a/pages/api/[...path].js +++ b/pages/api/[...path].js @@ -2,7 +2,8 @@ import { createProxyMiddleware } from "http-proxy-middleware"; export default createProxyMiddleware({ - target: "http://10.10.0.13", // Ziel-URL des Proxys + target: "http://192.168.10.58:3001", + // target: "http://10.10.0.13", // Ziel-URL des Proxys //target: "http://192.168.10.187:3000", // Ziel-URL des Proxys changeOrigin: true, pathRewrite: { diff --git a/pages/api/readPoiTyp.js b/pages/api/readPoiTyp.js index 0553848ae..8e2ef8132 100644 --- a/pages/api/readPoiTyp.js +++ b/pages/api/readPoiTyp.js @@ -14,7 +14,7 @@ export default function handler(req, res) { console.log("Empfangene Query-Parameter:", req.query); // Gibt alle empfangenen Query-Parameter aus const connection = mysql.createConnection(dbConfig); - const query = "SELECT * FROM poiTyp"; // Vereinfachte Abfrage zum Testen + const query = "SELECT * FROM poityp"; // Vereinfachte Abfrage zum Testen connection.query(query, (error, results) => { connection.end();