@uns-kit/cli 0.0.73 → 0.0.75
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uns-kit/cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.75",
|
|
4
4
|
"description": "Command line scaffolding tool for UNS applications",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -26,13 +26,13 @@
|
|
|
26
26
|
],
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"azure-devops-node-api": "^15.1.1",
|
|
29
|
-
"@uns-kit/core": "1.0.
|
|
29
|
+
"@uns-kit/core": "1.0.42"
|
|
30
30
|
},
|
|
31
31
|
"unsKitPackages": {
|
|
32
|
-
"@uns-kit/core": "1.0.
|
|
33
|
-
"@uns-kit/api": "0.0.
|
|
34
|
-
"@uns-kit/cron": "0.0.
|
|
35
|
-
"@uns-kit/temporal": "0.0.
|
|
32
|
+
"@uns-kit/core": "1.0.42",
|
|
33
|
+
"@uns-kit/api": "0.0.51",
|
|
34
|
+
"@uns-kit/cron": "0.0.50",
|
|
35
|
+
"@uns-kit/temporal": "0.0.49"
|
|
36
36
|
},
|
|
37
37
|
"scripts": {
|
|
38
38
|
"build": "tsc -p tsconfig.build.json",
|
|
@@ -49,6 +49,8 @@ mqttInput.event.on("input", async (event) => {
|
|
|
49
49
|
const eventDate = new Date(Number.parseInt(timestampRaw, 10));
|
|
50
50
|
const sensorValue = Number.parseFloat(sensorRaw);
|
|
51
51
|
const time: ISO8601 = eventDate.toISOString() as ISO8601;
|
|
52
|
+
const intervalStart: ISO8601 = new Date(eventDate.getTime() - 1000).toISOString() as ISO8601;
|
|
53
|
+
const intervalEnd: ISO8601 = eventDate.toISOString() as ISO8601;
|
|
52
54
|
|
|
53
55
|
const dataGroup = "sensor";
|
|
54
56
|
|
|
@@ -65,11 +67,11 @@ mqttInput.event.on("input", async (event) => {
|
|
|
65
67
|
attributes: [
|
|
66
68
|
{
|
|
67
69
|
attribute: GeneratedAttributesByType["energy-resource"]["current"],
|
|
68
|
-
data: { dataGroup, time, value: numberValue, uom: GeneratedPhysicalMeasurements.Ampere },
|
|
70
|
+
data: { dataGroup, time, value: numberValue, uom: GeneratedPhysicalMeasurements.Ampere, intervalStart, intervalEnd },
|
|
69
71
|
},
|
|
70
72
|
{
|
|
71
73
|
attribute: GeneratedAttributes["voltage"],
|
|
72
|
-
data: { dataGroup, time, value: sensorValue, uom: GeneratedPhysicalMeasurements.Volt },
|
|
74
|
+
data: { dataGroup, time, value: sensorValue, uom: GeneratedPhysicalMeasurements.Volt, intervalStart, intervalEnd },
|
|
73
75
|
},
|
|
74
76
|
],
|
|
75
77
|
});
|
|
@@ -56,6 +56,8 @@ mqttInput.event.on("input", async (event) => {
|
|
|
56
56
|
const sensorValue = Number.parseFloat(sensorRaw);
|
|
57
57
|
|
|
58
58
|
const time: ISO8601 = eventDate.toISOString() as ISO8601;
|
|
59
|
+
const intervalStart: ISO8601 = new Date(eventDate.getTime() - 1000).toISOString() as ISO8601;
|
|
60
|
+
const intervalEnd: ISO8601 = eventDate.toISOString() as ISO8601;
|
|
59
61
|
const dataGroup = "sensor_table";
|
|
60
62
|
const columns: IUnsTableColumn[] = [
|
|
61
63
|
{ name: "current", type: "double", value: currentValue, uom: GeneratedPhysicalMeasurements.Ampere },
|
|
@@ -77,6 +79,8 @@ mqttInput.event.on("input", async (event) => {
|
|
|
77
79
|
table: {
|
|
78
80
|
dataGroup,
|
|
79
81
|
time,
|
|
82
|
+
intervalStart,
|
|
83
|
+
intervalEnd,
|
|
80
84
|
columns,
|
|
81
85
|
},
|
|
82
86
|
},
|