Skip to content
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

Blockly: Support String/Number/Quantity on eventcontext state/command #1992

Merged
merged 3 commits into from
Jul 27, 2023

Conversation

stefan-hoehn
Copy link
Contributor

@stefan-hoehn stefan-hoehn commented Jul 27, 2023

Fixes #1991.

Support conversion of event context types itemState, oldItemState, itemCommand as String or Number by supplying a mutating block with a choise of Number / String.

image

@stefan-hoehn stefan-hoehn requested a review from a team as a code owner July 27, 2023 15:24
@rkoshak
Copy link

rkoshak commented Jul 27, 2023

Awesome! Could it also support Quantity?

@relativeci
Copy link

relativeci bot commented Jul 27, 2023

Job #1087: Bundle Size — 15.75MiB (~+0.01%).

093b1a7(current) vs 4978d9f main#1086(baseline)

⚠️ Bundle contains 16 duplicate packages

Metrics (no changes)
                 Current
Job #1087
     Baseline
Job #1086
Initial JS 1.67MiB 1.67MiB
Initial CSS 608.89KiB 608.89KiB
Cache Invalidation 93.95% 93.95%
Chunks 219 219
Assets 689 689
Modules 1700 1700
Duplicate Modules 90 90
Duplicate Code 1.95% 1.95%
Packages 138 138
Duplicate Packages 15 15
Total size by type (2 changes)
                 Current
Job #1087
     Baseline
Job #1086
CSS 859.34KiB 859.34KiB
Fonts 526.1KiB 526.1KiB
HTML 1.23KiB 1.23KiB
IMG 140.74KiB 140.74KiB
JS 9.25MiB (~+0.01%) 9.25MiB
Media 295.6KiB 295.6KiB
Other 4.72MiB (~+0.01%) 4.72MiB

View job #1087 reportView main branch activity

@florian-h05 florian-h05 changed the title Support String/Number on eventcontext state/command Blockly: Support String/Number on eventcontext state/command Jul 27, 2023
Copy link
Contributor

@florian-h05 florian-h05 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You forgot to update the code generation, I did it.

@rkoshak I've added Quantity.

@florian-h05 florian-h05 added this to the 4.1 milestone Jul 27, 2023
@florian-h05 florian-h05 added bug Something isn't working enhancement New feature or request main ui Main UI patch A PR that has been cherry-picked to a patch release branch labels Jul 27, 2023
@florian-h05 florian-h05 merged commit edc124e into openhab:main Jul 27, 2023
4 checks passed
@florian-h05 florian-h05 deleted the blockly_4_0_1_context_change branch July 27, 2023 21:41
florian-h05 pushed a commit that referenced this pull request Jul 27, 2023
Fixes #1991.

Support conversion of event context types itemState, oldItemState,
itemCommand as String or Number by supplying a mutating block with a
choise of Number / String.

Also-by: Florian Hotze <[email protected]>
Signed-off-by: Stefan Höhn <[email protected]>
(cherry picked from commit edc124e)
@florian-h05 florian-h05 changed the title Blockly: Support String/Number on eventcontext state/command Blockly: Support String/Number/Quantity on eventcontext state/command Jul 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request main ui Main UI patch A PR that has been cherry-picked to a patch release branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Blockly] Automatically convert event.newItemState et. al. to String
3 participants