mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 20:54:07 -08:00
fix(editor): Update to 'Expression/Fixed' toggle - Keep expression when switching to Fixed (#4599)
✨ Keep the expression string when switching to `Fixed` parameter value
This commit is contained in:
parent
531a290fad
commit
6eee155ecb
|
@ -1013,7 +1013,14 @@ export default mixins(
|
|||
if (this.isResourceLocatorParameter && isResourceLocatorValue(this.value)) {
|
||||
this.valueChanged({ __rl: true, value, mode: this.value.mode });
|
||||
} else {
|
||||
this.valueChanged(typeof value !== 'undefined' ? value : null);
|
||||
let newValue = typeof value !== 'undefined' ? value : null;
|
||||
|
||||
if (this.parameter.type === 'string') {
|
||||
// Strip the '=' from the beginning
|
||||
newValue = this.value ? this.value.toString().substring(1) : null;
|
||||
}
|
||||
|
||||
this.valueChanged(newValue);
|
||||
}
|
||||
} else if (command === 'refreshOptions') {
|
||||
if (this.isResourceLocatorParameter) {
|
||||
|
|
Loading…
Reference in a new issue