Adding new element into existing layout

Hi,

I have layout set similar way like this:

var leftCol = {
id: ‘left’,
width:200,
template: ’ ’
};
var mainCol = {
id: ‘main’,
template: ’ ’
};
var rightCol = {
id: ‘right’,
width:200,
template: ’ ’
};

var layout={
rows:[
{ type:“header”, template:“Header” },
{
cols:[
leftCol,
mainCol,
rightCol
]
}
]
};

webix.ui(layout);

And now I want to add something dynamically (f.e calendar) into “main” column. How to do it? I know about “container” property but it seems it works only when DOM id is given and id set in mainCol object is sth different. Any help really appreciated.

You can use webix.ui command to replace any existing view with new one
http://webix.com/snippet/69ce3ec0

Or you can use addView API of layout
http://webix.com/snippet/799d55f6

This is what I’ve wanted. Thanks a lot!