fix: reset read-only on fetch-from fields
This commit is contained in:
parent
f6b7b5537b
commit
ac4f040228
2 changed files with 6 additions and 0 deletions
|
|
@ -244,6 +244,7 @@ frappe.ui.form.Control = class BaseControl {
|
|||
}
|
||||
me.set_invalid && me.set_invalid();
|
||||
},
|
||||
() => me?.after_set_value?.(),
|
||||
]);
|
||||
}
|
||||
value = this.validate(value);
|
||||
|
|
|
|||
|
|
@ -852,6 +852,11 @@ frappe.ui.form.ControlLink = class ControlLink extends frappe.ui.form.ControlDat
|
|||
|
||||
return this.validate_link_and_fetch(value);
|
||||
}
|
||||
after_set_value() {
|
||||
for (const target_field of Object.keys(this.fetch_map)) {
|
||||
this.frm.refresh_field(target_field);
|
||||
}
|
||||
}
|
||||
validate_link_and_fetch(value) {
|
||||
const args = this.get_search_args(value);
|
||||
if (!args) return;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue