Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by dvgrimm on Jun 11, 2009 11:13
open dhtmlx forum
Scheduler: how to add new tabs for custom addons eg: search feature and tab to schedule reoccuring events.

I can see huge potential to this product.
Is it possible to add new tabs to the existing 'day' 'week' 'month'?

I need to add two features:
1. a html form so my users can schedule reoccurring events;
2. a 'search' function so users can search for scheduled events.

I could add these features outside...eg. use iframe, however, need a way to programmatically go to a specified date.

It would be great if I could add tabs to launch these custom features.
It would be better if these features could be integrated into your API...

thanks,
David
Answer posted by Support on Jun 12, 2009 01:44
>>Is it possible to add new tabs to the existing 'day' 'week' 'month'?

a) add tab to html template of scheduler


<div class="dhx_cal_tab" name="day_tab" style="right:204px;"></div>
<div class="dhx_cal_tab" name="week_tab" style="right:140px;"></div>
<div class="dhx_cal_tab" name="month_tab" style="right:76px;"></div>
<div class="dhx_cal_tab" name="custom_tab" style="right:270px;"></div>

b) add new tab name to locale

scheduler.locale.labels.custom_tab="Custom 1";

c) add wrapper to update_view method, to handle your custom tab


scheduler.update_view = function(){
if (this._mode=="custom")
        alert("Date:"+this._date+", mode:"+this._mode);
        else return this.update_viewA();
}


name of mode , for custom tab, taken from name attribute inside html template.

Sample is attached. 

Adding support of recurring events is topmost feature in our todo list. 

>>2. a 'search' function so users can search for scheduled events.
Can be done as

for (var event in scheduler._events ){
    if (event.start_date == some ) //or any other kind of check
   {
                 scheduler.setCurrentView (event.start_date, "week");
                 return;
   }
}

Attachments (1)
sch12.zip52.31 Kb