scheduler.templates.event_text is not working

Hi, I got a strange problem: I am trying to change the event_text. But the scheduler.templates.event_text function is neven been called. In contrast I tried with scheduler.templates.event_class which works quiet well. Can anybody tell my why the event_text does not work in my case (when I paste the code into your snippet engine it is working as well…)?

Thanks in advance,
Mark

scheduler.config.details_on_create=true;
	scheduler.config.details_on_dblclick=true;
	scheduler.config.xml_date="%Y-%m-%d %H:%i";
	
	//has been called!
	scheduler.templates.event_class = function(start, end, event) {
		event.color = event.position == 0 ? "red" : "";
		return "";
	};
	//NOT called!
	scheduler.templates.event_text = function(start, end, event){
	    return event.start_date;
	};
	
	var sections = scheduler.serverList(sections");
	scheduler.createTimelineView({
		name:	"timeline",
		x_unit:	"hour",
		x_date:	"%H:%i",
		x_step:	1,
		x_size: 24,
		x_start: 0,
		x_length: 24,
		y_unit:	sections,
		y_property:	"section_id",
		render:"bar"
	});
		
	scheduler.init('scheduler_main',new Date(1985,9,21),"timeline");	
	scheduler.load(URL, "json");
	
	dataProcessor = new dataProcessor(URL);
	dataProcessor.setUpdateMode("OFF");
	dataProcessor.init(scheduler);

Hello,

As template works in the snippet, then the case in your code.
Please show your code or provide with a demo so we could understand what’s happening.

Hi,

I send you a PM… Don’t care about it anymore :slight_smile: I could simplify the code to a snippet:

docs.dhtmlx.com/scheduler/snippet/e1cba05a

Hi,
note that there are two templates for text content -
docs.dhtmlx.com/scheduler/api__s … plate.html
docs.dhtmlx.com/scheduler/api__s … plate.html
event_text is called in day/week/units views, and event_bar_text for month and timeline views

Thank you!