iobroker-ucl 1.0.28 → 1.0.29

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.
Files changed (3) hide show
  1. package/package.json +1 -1
  2. package/test.js +4 -1
  3. package/test.ts +5 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker-ucl",
3
- "version": "1.0.28",
3
+ "version": "1.0.29",
4
4
  "main": "main.js",
5
5
  "scripts": {
6
6
  "build": "tsc --build",
package/test.js CHANGED
@@ -15,7 +15,10 @@ var DateCalendarTest = /** @class */ (function () {
15
15
  read: true,
16
16
  write: true
17
17
  });
18
- this.adapter.setState(mediolaText, new Date().getTime());
18
+ var now = new Date();
19
+ var lastUpdate = now.getDate().toString().padStart(2, '0') + "." + (now.getMonth() + 1).toString().padStart(2, '0') + "." + now.getFullYear();
20
+ lastUpdate = lastUpdate + ", " + now.getHours().toString().padStart(2, '0') + ":" + now.getMinutes().toString().padStart(2, '0') + ":" + now.getSeconds().toString().padStart(2, '0') + "";
21
+ this.adapter.setState(mediolaText, lastUpdate);
19
22
  this.adapter.log("<<< State created!");
20
23
  var now = new Date();
21
24
  var weekday = now.getDay();
package/test.ts CHANGED
@@ -15,7 +15,11 @@ export class DateCalendarTest {
15
15
  read: true,
16
16
  write: true
17
17
  });
18
- this.adapter.setState(mediolaText, new Date().getTime());
18
+
19
+ var now = new Date();
20
+ var lastUpdate = now.getDate().toString().padStart(2,'0') + "." + (now.getMonth()+1).toString().padStart(2,'0') + "." + now.getFullYear();
21
+ lastUpdate = lastUpdate + ", " + now.getHours().toString().padStart(2,'0') + ":" + now.getMinutes().toString().padStart(2,'0') + ":" + now.getSeconds().toString().padStart(2,'0') + "";
22
+ this.adapter.setState(mediolaText, lastUpdate);
19
23
  this.adapter.log("<<< State created!");
20
24
 
21
25
  var now = new Date();