Skip to content

Commit

Permalink
fix(ui): allow manual entry of nodeid (#885)
Browse files Browse the repository at this point in the history
* fix(ui): allow manual entry of nodeid

Fixes #865

* fix: parse int nodeId
  • Loading branch information
robertsLando authored Mar 15, 2021
1 parent 5d72a2f commit cd5691a
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
19 changes: 18 additions & 1 deletion src/components/Confirm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -54,17 +54,34 @@
:required="input.required"
></v-switch>
<v-select
v-if="input.type === 'list'"
v-if="input.type === 'list' && !input.allowManualEntry"
v-model="values[input.key]"
:item-text="input.itemText || 'text'"
:item-value="input.itemValue || 'value'"
:items="input.items"
:rules="input.rules || []"
:label="input.label"
:persistent-hint="!!input.hint"
:multiple="!!input.multiple"
:hint="input.hint"
:required="input.required"
></v-select>
<v-combobox
v-if="input.type === 'list' && input.allowManualEntry"
v-model="values[input.key]"
:item-text="input.itemText || 'text'"
:item-value="input.itemValue || 'value'"
chips
:items="input.items"
:rules="input.rules || []"
:label="input.label"
:multiple="!!input.multiple"
:persistent-hint="!!input.hint"
:hint="input.hint"
:return-object="false"
:required="input.required"
>
</v-combobox>
</v-col>
</v-row>
</v-form>
Expand Down
3 changes: 2 additions & 1 deletion src/components/ControlPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ export default {
inputs: [
{
type: 'list',
allowManualEntry: true,
items: this.nodes,
label: 'Node',
hint: 'Select a node',
Expand All @@ -267,7 +268,7 @@ export default {
this.showSnackbar('Node ID must be an integer value')
return
}
args.push(nodeId)
args.push(parseInt(nodeId))
}
}
Expand Down

0 comments on commit cd5691a

Please sign in to comment.