Our flexible Kanban board for managing tasks with drag drop


Post by yingtao »

I need to custom swimlane header?how can I do?
Image

like this:
Image


Post by johan.isaksson »

Hi,

This demo has custom content in swimlane headers, please take a look: https://bryntum.com/examples/taskboard/swimlanes-content/

It uses a https://bryntum.com/docs/taskboard/api/TaskBoard/view/TaskBoardBase#config-swimlaneRenderer to achieve it

Best regards,
Johan Isaksson

Post by yingtao »

I tried and I can do it. But how can I add 'click' event。

Image


Post by johan.isaksson »

Unfortunately there is no way of adding a listener in a DomConfig, although it would have been nice. Supplying onclick like that will work in the same way as it would if you had it on a normal DOM element, but I would advice against it.

I instead recommend adding a click listener to an ancestor element, taking conditional action based on which element was clicked. You could do it using normal DOM functionality, or with our EventHelper (see https://bryntum.com/docs/taskboard/api/Core/helper/EventHelper#function-on-static):

EventHelper.on({
  element : taskboard.element,
  delegate : '.team-info', // filter clicks, only care about those on team-info elements
  click() {
     // code goes here
  }
});
Best regards,
Johan Isaksson

Post Reply