Add battery and speed fields to tracker-db workflow

- Add battery and speed fields to Location processing node
- Add battery and speed fields to NocoDB storage
- Update API URL to home64.de domain
- Add new index_owntrack.html with battery/speed display

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-14 14:50:46 +00:00
parent 035148df2e
commit ea058828b8
3 changed files with 184 additions and 2 deletions

View File

@@ -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 }}"
}
]
}