Skip to content

Commit

Permalink
added example
Browse files Browse the repository at this point in the history
  • Loading branch information
Hypnos3 committed Mar 13, 2022
1 parent a9a5dc5 commit e506d3c
Show file tree
Hide file tree
Showing 4 changed files with 88 additions and 5 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Install of a specific Version in Redmatic (on a Homematic):
- `npm install --save --no-package-lock --global-style --save-prefix="~" --production [email protected]`

This can be also used to go back to an older Version.
### 2.2.0: enhancement
### 2.2.0-beta: enhancement

- general
- first implementation of tests with `mocha` and some changes due to the test implementation (inject enhance and delay-until)
Expand Down
83 changes: 83 additions & 0 deletions examples/delay-until/1 - wiki - simple usage.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
[
{
"id": "a5f09193a7042daa",
"type": "rdg-delay-until",
"z": "5f922dadd3c06750",
"name": "",
"positionConfig": "",
"time": "10:00",
"timeType": "entered",
"offset": 0,
"offsetType": "none",
"offsetMultiplier": 60000,
"queuingBehavior": "all",
"flushMsgs": "",
"flushMsgsType": "none",
"flushMsgsValue": "true",
"flushMsgsValueType": "bool",
"dropMsgs": "",
"dropMsgsType": "none",
"dropMsgsValue": "true",
"dropMsgsValueType": "bool",
"enqueueMsg": "",
"enqueueMsgType": "none",
"enqueueMsgValue": "true",
"enqueueMsgValueType": "bool",
"ctrlPropChange": false,
"ctrlPropValue": "",
"ctrlPropValueType": "delete",
"tsCompare": "0",
"x": 710,
"y": 640,
"wires": [
[
"76deb05ef54bb8f9"
]
]
},
{
"id": "e926c223c334b655",
"type": "inject",
"z": "5f922dadd3c06750",
"name": "",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "",
"payloadType": "date",
"x": 540,
"y": 640,
"wires": [
[
"a5f09193a7042daa"
]
]
},
{
"id": "76deb05ef54bb8f9",
"type": "debug",
"z": "5f922dadd3c06750",
"name": "",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"statusVal": "",
"statusType": "auto",
"x": 910,
"y": 640,
"wires": []
}
]
6 changes: 3 additions & 3 deletions nodes/static/htmlglobal.js
Original file line number Diff line number Diff line change
Expand Up @@ -356,26 +356,26 @@ function getTypes(node) { // eslint-disable-line no-unused-vars
label: node._('node-red-contrib-sun-position/position-config:common.types.randomNumber','randomNumber'),
icon: 'icons/node-red-contrib-sun-position/inputTypeRandomNumber.svg',
hasValue: true,
// eslint-disable-next-line no-useless-escape
// @ts-ignore
// eslint-disable-next-line no-useless-escape
validate: /** @type {runtimeRED} */ RED.validators.regex(/^(?:[1-9]|-0\.|0\.|-)\d*(?:\.\d+)?([\/|](?:[1-9]|-0\.|0\.|-)\d*(?:\.\d+)?)?$/)()
},
randmNumCachedDay: {
value: 'randmNumCachedDay',
label: node._('node-red-contrib-sun-position/position-config:common.types.randmNumCachedDay','randmNumCachedDay'),
icon: 'icons/node-red-contrib-sun-position/inputTypeRandomNumber.svg',
hasValue: true,
// eslint-disable-next-line no-useless-escape
// @ts-ignore
// eslint-disable-next-line no-useless-escape
validate: /** @type {runtimeRED} */ RED.validators.regex(/^(?:[1-9]|-0\.|0\.|-)\d*(?:\.\d+)?([\/|](?:[1-9]|-0\.|0\.|-)\d*(?:\.\d+)?)?$/)()
},
randmNumCachedWeek: {
value: 'randmNumCachedWeek',
label: node._('node-red-contrib-sun-position/position-config:common.types.randmNumCachedWeek','randmNumCachedWeek'),
icon: 'icons/node-red-contrib-sun-position/inputTypeRandomNumber.svg',
hasValue: true,
// eslint-disable-next-line no-useless-escape
// @ts-ignore
// eslint-disable-next-line no-useless-escape
validate: /** @type {runtimeRED} */ RED.validators.regex(/^(?:[1-9]|-0\.|0\.|-)\d*(?:\.\d+)?([\/|](?:[1-9]|-0\.|0\.|-)\d*(?:\.\d+)?)?$/)()
},
TimeSun: {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "node-red-contrib-sun-position",
"version": "2.2.0-betha",
"version": "2.2.0-beta",
"description": "NodeRED nodes to get sun and moon position",
"keywords": [
"node-red",
Expand Down

0 comments on commit e506d3c

Please sign in to comment.