Commit 81a809e7 authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Update harvester/layout to select the row properly.

parent 022ae708
......@@ -381,18 +381,28 @@
});
gridLog.on('itemcontextmenu', function(view, record, item, index, event) {
var grid = this;
event.stopEvent();
// the editAndInsert action is only available when the record is
// not already in the database
if (record.get('action') === 'idle') {
// disable the contextmenu
menu.items.get('editAndInsert').setDisabled(true);
} else {
// enable the context menu and select the row
menu.items.get('editAndInsert').setDisabled(false);
grid.getSelectionModel().select(record);
}
// show the menu
menu.showAt(event.getXY());
});
}, gridLog);
</script>
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment