fix: update SQL insert statement to include external_name and correct build number in library.json

This commit is contained in:
jhartworks
2026-04-16 13:24:18 +02:00
parent fccdeaa3b9
commit 24f25f17eb
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -66,18 +66,18 @@ class CounterServer extends IPSModule
// ---------- UPSERT ----------
$sql = "
INSERT INTO meter_devices
(project_id, client_id, counter_id, meter_uuid, meter_name, external_id, meter_type, billing_unit, description, is_active)
(project_id, counter_id, meter_uuid, meter_name, external_id, external_name, meter_type, billing_unit, is_active)
VALUES
(
" . ($projectId === 'NULL' ? 'NULL' : $projectId) . ",
'" . $this->esc($clientId) . "',
'" . $this->esc($counterId) . "',
'" . $this->esc($clientId . '_' . $counterId) . "',
'" . $this->esc($counterName) . "',
'" . $this->esc($counterId) . "',
'" . $this->esc($clientId) . "',
'" . $this->esc($clientName) . "',
'" . $this->esc($type) . "',
'" . $this->esc($unit) . "',
'" . $this->esc('Client: ' . $clientName) . "',
1
)
ON DUPLICATE KEY UPDATE
+1 -1
View File
@@ -8,6 +8,6 @@
"date": 1491343200
},
"version": "1.0",
"build": 2,
"build": 3,
"date": 0
}