Skip to content

Commit 84cad42

Browse files
committed
fix(event-scripts): wire scriptMethod selection + fallback on empty name
Two bugs prevented saving a new event script: 1. The Script Method <mat-select> had no (selectionChange) handler, so selectedRoute() never fired. completeScriptName was therefore never populated from the chosen method; it remained the empty string that selectedServiceItemEvent() resets it to. 2. The submit fallback used `??`, which only treats null/undefined as missing. The empty-string completeScriptName passed through unchanged, so scriptItem.name became '' and the POST went to /system/event_script (no resource id) — backend then rejects with 400 "No record(s) detected". Wire selectedRoute() to scriptMethod's selectionChange and use || so the fallback also kicks in for empty string.
1 parent 7f0747b commit 84cad42

6 files changed

Lines changed: 10 additions & 5 deletions

File tree

dist/6070.08e277e12a953d00.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)