add ledfx
This commit is contained in:
@@ -1,3 +1,6 @@
|
|||||||
[submodule "coned-fetch"]
|
[submodule "coned-fetch"]
|
||||||
path = coned-fetch
|
path = coned-fetch
|
||||||
url = https://github.com/jpoles1/coned-fetch
|
url = https://github.com/jpoles1/coned-fetch
|
||||||
|
[submodule "addon-ledfx"]
|
||||||
|
path = addon-ledfx
|
||||||
|
url = https://github.com/hassio-addons/addon-ledfx.git
|
||||||
|
|||||||
Submodule
+1
Submodule addon-ledfx added at bf3ffb2ae9
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "ConEd Meter to Hass Supervisor API",
|
"name": "ConEd Meter to Hass Supervisor API",
|
||||||
"version": "0.1.0c",
|
"version": "0.1.0d",
|
||||||
"slug": "coned",
|
"slug": "coned",
|
||||||
"description": "ConEd Meter Reader to Hass Supervisor API",
|
"description": "ConEd Meter Reader to Hass Supervisor API",
|
||||||
"url": "https://gitlab.intrepidnet.org/home-assistant-addons/~/tree/master/coned-fetch",
|
"url": "https://gitlab.intrepidnet.org/home-assistant-addons/~/tree/master/coned-fetch",
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ async function main() {
|
|||||||
return row.value !== null && row.value !== undefined;
|
return row.value !== null && row.value !== undefined;
|
||||||
})
|
})
|
||||||
const latest_read = filtered_data[0];
|
const latest_read = filtered_data[0];
|
||||||
update_sensor(latest_read);
|
// update_sensor(latest_read);
|
||||||
for (const row of filtered_data) {
|
for (const row of filtered_data) {
|
||||||
await energyModel.updateOrCreate({ startTime: new Date(row.startTime), endTime: new Date(row.endTime) }, { energy: row.value }).catch((e) => {
|
await energyModel.updateOrCreate({ startTime: new Date(row.startTime), endTime: new Date(row.endTime) }, { energy: row.value }).catch((e) => {
|
||||||
console.log(chalk.red(`Err: ${e}`));
|
console.log(chalk.red(`Err: ${e}`));
|
||||||
|
|||||||
Reference in New Issue
Block a user