This is a migrated thread and some comments may be shown as answers.

Resources PopUp customization

1 Answer 74 Views
Gantt
This is a migrated thread and some comments may be shown as answers.
Raghu
Top achievements
Rank 1
Raghu asked on 11 May 2018, 06:57 AM
hai how to keep our own popup instead of Resources popUp  in gantt chart 

1 Answer, 1 is accepted

Sort by
0
Ivan Danchev
Telerik team
answered on 15 May 2018, 07:25 AM
Hello Raghu,

You can open your own custom popup by attaching a mousedown event handler to the "Assign"  button in the default Gantt editor, then stopping the event's propagation and initializing your own custom popup. Here's a dojo example, which shows how this can be done. The relevant logic is in the Gantt's edit event handler:
function onEdit(e){
  var element = $(".k-edit-form-container").find("div[data-container-for='resources']");
 
  //handle Assign button click
  var btnAssign = element.contents().eq(0)
   
  btnAssign.on('mousedown', function(e){
    e.stopPropagation();
 
    var dialog = $("#dialog").data("kendoWindow");
     
    if(!dialog) {
      $("#dialog").kendoWindow({
       width: 500,
       height: 600,
       title: "My Custom Dialog Title"
      });
      var dialog = $("#dialog").data("kendoWindow");
      dialog.center();
    }
    else {
      dialog.open().center();
    }
  })
}


Regards,
Ivan Danchev
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Gantt
Asked by
Raghu
Top achievements
Rank 1
Answers by
Ivan Danchev
Telerik team
Share this question
or