diff --git a/index.html b/index.html
index 475661a..3b6af55 100644
--- a/index.html
+++ b/index.html
@@ -82,7 +82,7 @@
}).addTo(map);
// API URL - anpassen an deine Domain
- const API_URL = 'https://n8n.unixweb.eu/webhook/location';
+ const API_URL = 'https://n8n.unixweb.home64.de/webhook/location';
// Auto-Refresh State
let autoRefreshEnabled = true;
diff --git a/index_owntrack.html b/index_owntrack.html
new file mode 100644
index 0000000..2dd0633
--- /dev/null
+++ b/index_owntrack.html
@@ -0,0 +1,174 @@
+
+
+
+
+
+ Location Test
+
+
+
+
+
+
+
📍 Location Tracker
+
Lade...
+
+
+
+
+
+
+
+
diff --git a/tracker-db.json b/tracker-db.json
index 5df4bcd..2daa82f 100644
--- a/tracker-db.json
+++ b/tracker-db.json
@@ -46,7 +46,7 @@
},
{
"parameters": {
- "jsCode": "// Extrahiere Location-Daten fĂĽr NocoDB\nconst items = $input.all();\nconst results = [];\n\nfor (const item of items) {\n const location = item.json.message.location;\n const from = item.json.message.from;\n const messageDate = item.json.message.date;\n \n const timestamp = new Date(messageDate * 1000).toISOString();\n const displayTime = new Date(messageDate * 1000).toLocaleString('de-DE');\n \n results.push({\n json: {\n latitude: location.latitude,\n longitude: location.longitude,\n timestamp: timestamp,\n user_id: from.id,\n first_name: from.first_name || '',\n last_name: from.last_name || '',\n username: from.username || '',\n marker_label: `${from.first_name || ''} ${from.last_name || ''}`.trim(),\n display_time: displayTime,\n chat_id: item.json.message.chat.id\n }\n });\n}\n\nreturn results;"
+ "jsCode": "// Extrahiere Location-Daten fĂĽr NocoDB\nconst items = $input.all();\nconst results = [];\n\nfor (const item of items) {\n const location = item.json.message.location;\n const from = item.json.message.from;\n const messageDate = item.json.message.date;\n \n const timestamp = new Date(messageDate * 1000).toISOString();\n const displayTime = new Date(messageDate * 1000).toLocaleString('de-DE');\n \n results.push({\n json: {\n latitude: location.latitude,\n longitude: location.longitude,\n timestamp: timestamp,\n user_id: from.id,\n first_name: from.first_name || '',\n last_name: from.last_name || '',\n username: from.username || '',\n marker_label: `${from.first_name || ''} ${from.last_name || ''}`.trim(),\n display_time: displayTime,\n chat_id: item.json.message.chat.id,\n battery: null,\n speed: null\n }\n });\n}\n\nreturn results;"
},
"id": "648a42c5-99ce-4c7b-8a85-380cd40050d0",
"name": "Location verarbeiten",
@@ -104,6 +104,14 @@
{
"fieldName": "chat_id",
"fieldValue": "={{ $json.chat_id }}"
+ },
+ {
+ "fieldName": "battery",
+ "fieldValue": "={{ $json.battery }}"
+ },
+ {
+ "fieldName": "speed",
+ "fieldValue": "={{ $json.speed }}"
}
]
}