Преглед на файлове

fix frappe/erpnext#12112 (#4677)

version-14
Faris Ansari преди 7 години
committed by GitHub
родител
ревизия
2f8e68b81d
No known key found for this signature in database GPG ключ ID: 4AEE18F83AFDEB23
променени са 2 файла, в които са добавени 5 реда и са изтрити 1 реда
  1. +2
    -0
      frappe/public/js/frappe/form/grid.js
  2. +3
    -1
      frappe/public/js/legacy/form.js

+ 2
- 0
frappe/public/js/frappe/form/grid.js Целия файл

@@ -480,6 +480,8 @@ frappe.ui.form.Grid = Class.extend({
},

setup_visible_columns: function() {
if (this.visible_columns) return;

var total_colsize = 1,
fields = this.editable_fields || this.docfields;



+ 3
- 1
frappe/public/js/legacy/form.js Целия файл

@@ -197,7 +197,7 @@ _f.Frm.prototype.watch_model_updates = function() {
if(doc.name===me.docname) {
if ((value==='' || value===null) && !doc[value]) {
// both the incoming and outgoing values are falsy
// the texteditor, summernote, changes nulls to empty strings on render,
// the texteditor, summernote, changes nulls to empty strings on render,
// so ignore those changes
} else {
me.dirty();
@@ -385,6 +385,8 @@ _f.Frm.prototype.refresh = function(docname) {
frappe.utils.scroll_to(0);
this.hide_print();
}
// reset visible columns, since column headings can change in different docs
this.grids.forEach(grid_obj => grid_obj.grid.visible_columns = null);
frappe.ui.form.close_grid_form();
this.docname = docname;
}


Зареждане…
Отказ
Запис