Only display sections in y-axis that have been selected

I am using the Multi-scheduler to make a scheduler for employees to sign out with.

We have 30+ employees and I didn’t want to list each employee on the left side (y-axis).

I would prefer to have it only display employees that have been selected in the dropdown upon event creation. Are there any existing samples for something similar?

How should I go about this?

You can use updateCollection API method to redefine list of visible sections

docs.dhtmlx.com/scheduler/api__s … ction.html

Hi, I am still having issues with this.

Are there any examples/html pages that utilize this?

This is my script:

[code] function init() {

	scheduler.locale.labels.timeline_tab = "Person";
	scheduler.locale.labels.section_custom="Section";
	scheduler.config.details_on_create=true;
	scheduler.config.details_on_dblclick=true;
	scheduler.config.xml_date="%Y-%m-%d %H:%i";
	scheduler.config.hour_date = "%g:%i%a";
	scheduler.config.collision_limit = 1;



	//===============
	//Configuration
	//===============	
	
	elements = [ // original hierarhical array to display

{key:10, label:“Johnson ssd”},
{key:20, label:“Johnson adsas”},
{key:30, label:“Johnson sda”},
{key:40, label:“Johnson a”},
{key:50, label:“Johnson sad”},
{key:60, label:“Johnson Fasdsadostel”},
{key:70, label:“Johnson asdsad”},

	];

	
	scheduler.createTimelineView({
		section_autoheight: false,
		name:	"timeline",
		x_unit:	"minute",
		x_date:	"%H:%i",
		x_step:	30,
		x_size: 24,
		x_start: 16,
		x_length:	48,
		y_unit: elements,
		y_property:	"section_id",
		render: "tree",
		folder_events_available: true,
		dy:60
	});
	
	

	//===============
	//Data loading
	//===============
	scheduler.config.lightbox.sections=[	
		{name:"description", height:130, map_to:"text", type:"textarea" , focus:true},
		{name:"custom", height:23, type:"timeline", options:serverList("goods"), map_to:"section_id" }, //type should be the same as name of the tab
		{name:"time", height:72, type:"time", map_to:"auto"}
	]
	
	
	scheduler.updateCollection("goods", new_goods_array);
	
	scheduler.init('scheduler_here',new Date(2009,5,30),"timeline");
	scheduler.load("data/events_tree_db.php");
	


	
}[/code]

I tried the “goods” option in the example

I tried this as per the “units” suggestions:

[code] scheduler.createTimelineView({
section_autoheight: false,
name: “timeline”,
x_unit: “minute”,
x_date: “%H:%i”,
x_step: 30,
x_size: 24,
x_start: 16,
x_length: 48,
y_unit: elements,
y_property: “section_id”,
render: “tree”,
folder_events_available: true,
dy:60
});

	scheduler.updateCollection("timeline", new_sections_array);[/code]

Change in timeline config

 y_unit: elements,

with

  y_unit: scheduler.serverList("elements", elements);

and later, to refresh options, you can use

   scheduler.updateCollection("elements", new_sections_array);