diff --git a/app.js b/app.js index c85f8dd..9f6fdc2 100644 --- a/app.js +++ b/app.js @@ -19,7 +19,7 @@ document.addEventListener('DOMContentLoaded', async () => { const getProjektId = () => { const urlParams = new URLSearchParams(window.location.search); - return urlParams.get('project') || urlParams.get('projekt') || urlParams.get('projekt_id') || "BWSamern-Ohne"; + return urlParams.get('project') || urlParams.get('projekt') || urlParams.get('projekt_id') || "test"; }; const STATUS_MAP = { @@ -1225,7 +1225,7 @@ document.addEventListener('DOMContentLoaded', async () => { // Priority 2: Use globalThis.LAYER_CONFIG (Script-based config) or remote config // Only load local config layers if the project is the default (bwsamern-ohne) - if (projId.toLowerCase() === 'bwsamern-ohne') { + if (projId.toLowerCase() === 'bwsamern-ohne' || projId.toLowerCase() === 'test') { const layers = await resolveLayerConfig(isLocalFile, statusEl); if (layers) { await loadConfigLayers(layers); diff --git a/server.js b/server.js index 468da5f..0188279 100644 --- a/server.js +++ b/server.js @@ -57,7 +57,7 @@ app.get('/api/logs', (req, res) => { // API to save turbines app.post('/api/wea', async (req, res) => { const { projekt_id, turbines } = req.body; - const targetProject = projekt_id || 'BWSamern-Ohne'; + const targetProject = projekt_id || 'test'; const schema = process.env.DB_SCHEMA || 'geodaten'; log(`Empfange Save-Request für Projekt: ${targetProject} (${turbines?.length || 0} WEAs)`);