riktar / jkanban

Vanilla Javascript plugin for manage kanban boards
https://www.riccardotartaglia.it/jkanban/
Apache License 2.0
1.07k stars 299 forks source link

Get the order of the tabs #12

Closed asabashi44 closed 5 years ago

asabashi44 commented 6 years ago

How can get the order of the tabs. When move the columns i cant store the order. I mean in the event dropEndl get the order and save the sequence.

riktar commented 6 years ago

Hi @asabashi44 , currently jKanban does not support the return of positions or sorting, you should do it with your own json and the use of events.

I will add this feature in the next release.

asabashi44 commented 6 years ago

Thanks for your answer!

marcosrocha85 commented 6 years ago

As far as I know, you can use jQuery in order to get the ID of the tabs on dropEl event by doing.

dropEl: function(el, target, source, sibling){
    console.log($(source.parentElement).data("id"));
    console.log($(target.parentElement).data("id"));
},

I think that would be nice if we could get id by simple doing source.id and target.id. But this workaround is nice for now.

marcosrocha85 commented 5 years ago

@asabashi44 can you check if the last commit helps you with order of boards?

marcosrocha85 commented 5 years ago

@riktar Can you close this issue?