Hello team,
I want to add filter functionality on a custom dropdown field based on other custom field value inside feature property of bryntum library.?? Please help me out.
Thanks,
Shruti Singh
Hello Tasnim,
I have a task editor inside feature property where i have added two custom field (dropdown). Now i want to populate one custom field value based on the other custom field value i.e., i want a filter functionality on that field. Example: i have selected a value from one custom filed now based on this value ,another custom field value will be populated.
Hey shruti,
If I understood correctly what you want to achieve, you can use the following snippet, just replace the respective tab and the fields that you're trying to listen to change to update the data
features: {
taskEdit: {
items: {
advancedTab: {
items: {
effortDrivenField: {
listeners: {
action: ev => {
const calendarCombo = ev.source.parent.widgetMap.calendarField
// Load the items and assign them to the combo
tab.items = ["new item"]
}
}
}
}
}
}
}
}
https://bryntum.com/products/gantt/docs/api/Gantt/feature/TaskEdit#customizing-tabs-and-their-widgets
https://bryntum.com/products/gantt/docs/api/Core/widget/Combo
Best regards,
Márcio
Hello Team,
I have added multiple custom field on editTask widget through combo feature . now i want to reset the value(blank) of all the field when i am clicking on new task button. but whenever am clicking on the button it showing the previous value. Can you help me with the solution.
Regards,
Shruti Singh
Hey Shruti,
That looks like a different topic not related to the initial thread. We have a "one thread per topic" policy to maintain the order of forums, please let's keep the discussion in a new post.
Besides that, how are you configuring the custom fields with the editor? At first sight, by your description, you can use https://bryntum.com/products/gantt/docs/api/Gantt/widget/TaskEditor#event-beforeSetRecord or https://bryntum.com/products/gantt/docs/api/Gantt/widget/TaskEditor#event-beforeShow event listener to see which value is being set there.
Or use https://bryntum.com/products/gantt/docs/api/Gantt/widget/TaskEditor#event-beforeHide to access the widgetMap of the form https://bryntum.com/products/gantt/docs/api/Gantt/widget/TaskEditor#property-widgetMap and from there, clear the inputs manually.
Best regards,
Márcio