-
-
Notifications
You must be signed in to change notification settings - Fork 429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[automation] Added 'EphemerisConditions' for NGRE #915
[automation] Added 'EphemerisConditions' for NGRE #915
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple of your automation PRs were merged before I could get a test done. This time I'm going to review first and then test. 😄 Although, I'm not sure that is going to be possible due to #903.
Should this be placed in an own package org.openhab.core.automation.module.ephmeris?
IMO, there's no need to separate it. I also question why you didn't put the factory into CoreModuleHandlerFactory with all the other core module handler factories.
...ab.core.automation/src/main/resources/ESH-INF/automation/moduletypes/EphmerisConditions.json
Outdated
Show resolved
Hide resolved
...ab.core.automation/src/main/resources/ESH-INF/automation/moduletypes/EphmerisConditions.json
Outdated
Show resolved
Hide resolved
...c/main/java/org/openhab/core/automation/internal/module/handler/CompareConditionHandler.java
Show resolved
Hide resolved
Because - to be honest - for practice reasons. And I was not sure if I should split the packages. If you think the packaging is okay, I will merge them and change the Condition UID to something like "ephmeris.HolidayCondition" and "ephmeris.WeekendCondition". |
Yeah... I don't see any benefit in splitting it out. It's nice to see them all in one place too. Just thought of something... it should be really easy to add a weekday condition too. |
0f7cbdf
to
c577b4e
Compare
The only reason to keep the factory is the reference to the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One typo and a couple suggestions
"name": "dayset", | ||
"type": "text", | ||
"label": "Dayset", | ||
"description": "Name of the requested dayset, witout prefix.", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
witout -> without
}, | ||
{ | ||
"uid": "ephmeris.WeekdayCondition", | ||
"label": "It is a day in a week", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is a weekday
}, | ||
{ | ||
"uid": "ephmeris.WeekendCondition", | ||
"label": "It is a day on the weekend", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is a weekend
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
} | ||
} | ||
|
||
logger.error("The ModuleHandler is not supported:{}", moduleTypeUID); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should there be a whitespace after the colon?
EphmerisConditions
for NGREEphemerisConditions
for NGRE
e1946e1
to
9d2aabb
Compare
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
9d2aabb
to
3d4e735
Compare
Signed-off-by: Christoph Weitkamp <[email protected]>
Signed-off-by: Christoph Weitkamp <[email protected]>
Signed-off-by: Christoph Weitkamp <[email protected]>
Signed-off-by: Christoph Weitkamp <[email protected]>
Signed-off-by: Christoph Weitkamp <[email protected]>
Signed-off-by: Christoph Weitkamp <[email protected]>
3d4e735
to
4a6d24b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks useful, thanks!
EphemerisConditions
for NGRESigned-off-by: Christoph Weitkamp <[email protected]> GitOrigin-RevId: a3d91be
EphemerisConditions
for NGREShould this be placed in an own package
org.openhab.core.automation.module.ephemeris
?Signed-off-by: Christoph Weitkamp [email protected]