fix: ReferenceError projekt_id typo in app.js
Deploy Bürgerwind / deploy (push) Successful in 16s Details

This commit is contained in:
Johannes Baumeister 2026-04-28 13:37:57 +02:00
parent 5ad4cd1344
commit c6642c25fc
1 changed files with 4 additions and 4 deletions

8
app.js
View File

@ -1423,7 +1423,7 @@ document.addEventListener('DOMContentLoaded', async () => {
const statusEl = document.getElementById('statusInfo'); const statusEl = document.getElementById('statusInfo');
statusEl.innerText = "Speichere in Datenbank..."; statusEl.innerText = "Speichere in Datenbank...";
const project_id = "BWSamern-Ohne"; // Could be dynamic from config const projekt_id = "BWSamern-Ohne"; // Could be dynamic from config
const turbineData = state.turbines.map(t => ({ const turbineData = state.turbines.map(t => ({
nr: t.nr, nr: t.nr,
variant: t.variant, variant: t.variant,
@ -1454,11 +1454,11 @@ document.addEventListener('DOMContentLoaded', async () => {
} }
async function loadTurbinesFromDB() { async function loadTurbinesFromDB() {
const project_id = "BWSamern-Ohne"; const projekt_id = "BWSamern-Ohne";
const statusEl = document.getElementById('statusInfo'); const statusEl = document.getElementById('statusInfo');
console.log(`Lade WEAs aus Datenbank für Projekt: ${project_id}...`); console.log(`Lade WEAs aus Datenbank für Projekt: ${projekt_id}...`);
try { try {
const response = await fetch(`/api/wea/${project_id}`); const response = await fetch(`/api/wea/${projekt_id}`);
if (response.ok) { if (response.ok) {
const dbTurbines = await response.json(); const dbTurbines = await response.json();
console.log(`Datenbank-Response: ${dbTurbines.length} WEAs erhalten.`); console.log(`Datenbank-Response: ${dbTurbines.length} WEAs erhalten.`);