Hi Stanislav,
Unfortunately I can’t give you an online sample as the app is on a private intranet; however I can give you the js and html code I am using to generate the timeline.
Using jQuery, and in the head of the html document:
function init() {
scheduler.locale.labels.timeline_tab = ‘Timeline’;
scheduler.locale.labels.section_custom = ‘Section’
scheduler.config.details_on_create = false;
scheduler.config.details_on_dblclick = true;
scheduler.config.icons_edit = [‘icon_cancel’];
scheduler.config.xml_date = ‘%Y-%m-%d %H:%i’;
var sections=[{key:1, label:‘Service Desk Executive Readerboard’}];
scheduler.createTimelineView({name: ‘timeline’,
x_unit: ‘day’,
x_date: ‘%D %M %d’,
x_step: 1,
x_size: 7,
//x_start: 16,
//x_length: 48,
y_unit:sections,
y_property: ‘section_id’,
render:‘bar’
});
scheduler.config.lightbox.sections=[{name:‘description’, height:130, map_to: ‘text’, type:‘textarea’, focus:true}];
scheduler.init(‘scheduler_here’,new Date(2010,4,2),‘timeline’);
scheduler.parse([
{ id: ‘54376183-6b22-43cb-9750-80e902ddbb98’, start_date: ‘2010-5-6’, end_date: ‘2010-5-18’, text: ‘Milestone :: Draft Deadline 1 :: May 06 2010 Achieved :: True’, section_id:1},
{ id: ‘54376183-6b22-43cb-9750-80e902ddbb99’, start_date: ‘2010-5-23’, end_date: ‘2010-5-30’, text: ‘Milestone :: Draft Deadline 2 :: May 06 2010 Achieved :: True’, section_id:1},
{ id: ‘54376183-6b22-43cb-9750-80e902ddbb97’, start_date: ‘2010-6-10’, end_date: ‘2010-6-29’, text: ‘Milestone :: Draft Deadline 3:: May 06 2010 Achieved :: True’, section_id:1}
],‘json’);
}
Html code:
'Milestone :: Draft Deadline 1
'Milestone :: Draft Deadline 2
'Milestone :: Draft Deadline 3
So if I was to repopulate and redraw the events for the timeline when I make a selection from the drop down list what would be the statements? I am thinking:
(pseudo-code)
scheduler.removeallevents
scheduler.parse(json array)
anything else?
Cheers,
pipes