Premium support for our pure JavaScript UI components


Post by beotech »

Hi, I would like to customize the dependency field of predecessor column.

When the dropdown list is opened, the items are displayed this way :

  • TaskName (sequenceNumber) [button]

The [button] allows to select the dependency type.

We would like to display the items this way :

  • sequenceNumber : TaskName [button]

We managed to do this :

{  
type: 'successor', editor: { listItemTpl: taskModel => `${taskModel.sequenceNumber} : ${taskModel.name}` } }

Unfortunately, we lose the [button]. Is there any way to keep it ?


Post by marcio »

Hey beotech,

Thanks for reaching out.

You can manually add the following structure to have the buttons back

{  
type: 'successor', editor: { listItemTpl: taskModel => `${taskModel.sequenceNumber} : ${taskModel.name} <div class="b-sch-box b-from" data-side="from"></div> <div class="b-sch-box b-to" data-side="to"></div>` } }

and you can test it live on our demo here https://bryntum.com/products/gantt/examples/basic/.

Best regards,
Márcio

How to ask for help? Please read our Support Policy


Post by beotech »

Thank you, working fine !


Post Reply