Переглянути джерело

[hotfix] don't add trigger if the autoname field and fieldname is not same (#4072)

version-14
Makarand Bauskar 7 роки тому
committed by GitHub
джерело
коміт
a722b64eb1
1 змінених файлів з 2 додано та 1 видалено
  1. +2
    -1
      frappe/public/js/frappe/form/controls/data.js

+ 2
- 1
frappe/public/js/frappe/form/controls/data.js Переглянути файл

@@ -29,7 +29,8 @@ frappe.ui.form.ControlData = frappe.ui.form.ControlInput.extend({
if (!this.df.parent) return;
this.meta = frappe.get_meta(this.df.parent);
if (this.meta && this.meta.autoname
&& this.meta.autoname.substr(0, 6)==='field:') {
&& this.meta.autoname.substr(0, 6)==='field:'
&& this.meta.autoname.substr(6) === this.df.fieldname) {
this.$input.on('keyup', () => {
this.set_description('');
if (this.doc && this.doc.__islocal) {


Завантаження…
Відмінити
Зберегти