Browse Source

Merge pull request #17940 from frappe/mergify/bp/version-14-hotfix/pr-17937

version-14
Suraj Shetty 2 years ago
committed by GitHub
parent
commit
affcf4940c
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 4 deletions
  1. +1
    -0
      frappe/public/js/frappe/form/controls/attach.js
  2. +0
    -3
      frappe/public/js/frappe/form/controls/base_control.js
  3. +2
    -1
      frappe/public/js/frappe/form/controls/check.js

+ 1
- 0
frappe/public/js/frappe/form/controls/attach.js View File

@@ -89,6 +89,7 @@ frappe.ui.form.ControlAttach = class ControlAttach extends frappe.ui.form.Contro
}

set_input(value, dataurl) {
this.last_value = this.value;
this.value = value;
if (this.value) {
this.$input.toggle(false);


+ 0
- 3
frappe/public/js/frappe/form/controls/base_control.js View File

@@ -278,9 +278,6 @@ frappe.ui.form.Control = class BaseControl {
} else {
if (this.doc) {
this.doc[this.df.fieldname] = value;
} else {
// case where input is rendered on dialog where doc is not maintained
this.value = value;
}
this.set_input(value);
return Promise.resolve();


+ 2
- 1
frappe/public/js/frappe/form/controls/check.js View File

@@ -31,11 +31,12 @@ frappe.ui.form.ControlCheck = class ControlCheck extends frappe.ui.form.ControlD
return cint(value);
}
set_input(value) {
this.last_value = this.value;
value = cint(value);
this.value = value;
if (this.input) {
this.input.checked = value ? 1 : 0;
}
this.last_value = value;
this.set_mandatory(value);
this.set_disp_area(value);
}


Loading…
Cancel
Save