Open caldera500 opened 1 year ago
Is there a way to detect when the value of a dropdown gets changed when inserting a new item. I want to disable some of the other inputs depending on the value that is detected.
{insertTemplate: function(value, item){ if(item.value == 'A'){ $("#grid").jsGrid("fieldOption", "Size", "inserting", false); }, name: 'category', title: 'Category', type: 'select', items:['', A ', 'B', 'C, 'D']},
I can detect the value of the dropdown like this:
$(document).on('change','#grid .jsgrid-insert-row select',function(){ console.log("change detected", this.value); });
However setting the field option after the grid is created is not possible using $("#grid").jsGrid("fieldOption", "Size", "inserting", false);
$("#grid").jsGrid("fieldOption", "Size", "inserting", false);
Is there a way to detect when the value of a dropdown gets changed when inserting a new item. I want to disable some of the other inputs depending on the value that is detected.
I can detect the value of the dropdown like this:
However setting the field option after the grid is created is not possible using
$("#grid").jsGrid("fieldOption", "Size", "inserting", false);