Perhaps i’m just not seeing it in the documentation, but is there a way to listen for close events? For instance, in a tabview,tab bar etc when close is true it allows the tabs to be closed via the x button. I would like to be able to listen for the event so i can perform some clean up on the views.
Is it possible to programmatically add new tabview tab/view cells? browsing through the api documentation shows an example of using the template functionality but i haven’t been able to find anything regarding creating and adding new tabs which contain components in the body element.
Awesome, i found that, but was having issues with nested components. I think i got it now though…
One last question.
I’ve noticed that when i set the dataFeed property on a list, it doesnt refresh. Is there an example that shows polling a rest service for updates to a list?
Ok, i went through the webix_debug.js and created a solution that will send out a ‘onTabClosed’ event within the TabView when a tab is closed. In this event it will pass the tab id as the event param. If you like i can share these edits for the greater community?
around line 6966 is the definition of the button component with webix.protoUI
if you go down to the onclick function there are various functions within it obviously, however around line 7278 i modified the webix_tab_close function to the following:
I’m also wondering if there is a bug within the list component where the list does not poll the specified datafeed/url etc. I’ll test and let you know but it doesnt seem to work on my end.
We added the onBeforeTabClose event, that can cancel tab deletion in case the handler returns false.
Also, we added the onOptionRemove event that fires after an option has been removed.
Yet I couldn’t reproduce the undefined error on my end. Could you please provide more details about the situation when it occurs or probably share the sample?
Regarding the undefined error, i think it’s probably just something within my code, if you couldnt produce it then i wouldnt worry about it.
I’m noticing an issue with the index / id property within the datastore. When i load a list with a json data object with an item where the id property is zero, it cannot be found within the index of the list. It displays in the list correctly but cannot be accessed, or updated with the id equal to zero.
I’m using a datatable within a window, i have the autoheight/autowidth set to true however the datatable doesnt fill the window… is this the right method for achieving this result or should i use something else?
Autoheight and autowidth adjust the datatable to its content (the total height or rows/columns respectively).
If you want a datatable to take the whole available space of a container, set a fillspace property to at least one of its columns: http://webix.com/snippet/b1c86d10