Browse Source

Don't hide checkboxes in grid row after submission (#4951)

version-14
Nabin Hait 7 years ago
committed by Rushabh Mehta
parent
commit
04cb1d0833
2 changed files with 0 additions and 10 deletions
  1. +0
    -2
      frappe/public/js/frappe/form/grid.js
  2. +0
    -8
      frappe/public/js/frappe/form/grid_row.js

+ 0
- 2
frappe/public/js/frappe/form/grid.js View File

@@ -171,8 +171,6 @@ frappe.ui.form.Grid = Class.extend({
// redraw
var _scroll_y = $(document).scrollTop();
this.make_head();
// to hide checkbox if grid is not editable
this.header_row && this.header_row.toggle_check();

if(!this.grid_rows) {
this.grid_rows = [];


+ 0
- 8
frappe/public/js/frappe/form/grid_row.js View File

@@ -121,8 +121,6 @@ frappe.ui.form.GridRow = Class.extend({
if(this.grid_form) {
this.grid_form.layout && this.grid_form.layout.refresh(this.doc);
}

this.toggle_check();
},
render_template: function() {
this.set_row_index();
@@ -596,11 +594,5 @@ frappe.ui.form.GridRow = Class.extend({
},
toggle_editable: function(fieldname, editable) {
this.set_field_property(fieldname, 'read_only', editable ? 0 : 1);
},
toggle_check: function() {
// to hide checkbox if grid is not editable
this.wrapper
.find('.grid-row-check')
.css("display", this.grid.is_editable()? 'block':'none');
}
});

Loading…
Cancel
Save