Is there a way to bind multiple editors to KeyTable?

Is there a way to bind multiple editors to KeyTable?

OnLogOnLog Posts: 12Questions: 4Answers: 1

I have one editor that is representing the "edit" button and one editor that is representing the "create" button. I tried to bind both these to the KeyTable, but it did not work. I tried something like this:

keys: {
        editor: [ 
                   {editor1}, 
                   {editor2}
                ]
    }

Answers

  • allanallan Posts: 61,972Questions: 1Answers: 10,160 Site admin

    I'm afraid there is no way to do that - only a single instance of Editor can be used with KeyTable.

    Moreover, it isn't possible to use KeyTable to create a new row - so even if it was possible with KeyTable, what you are looking for overall wouldn't work. Sorry!

    Allan

  • OnLogOnLog Posts: 12Questions: 4Answers: 1
    edited September 2020

    The problem is that when I press the "create" button, and the lightbox opens, I can not tab between the input boxes, instead the tab moves in the background on the main table. But when I bind it to the editor, that fills the "create" button, I can tab!
    The walkearound is that I bind one of my editors and for the other one I disables the keys on open, and enables on close:

    editor[subMenuID].on('open', function (e, json, data) {
                                 table[subMenuID].keys.disable(); 
                         });
    editor[subMenuID].on('close', function (e, json, data) {
                                 table[subMenuID].keys.enable(); 
                         });  
    

This discussion has been closed.