"showOverlay" is not working.

Hi,

By loading data from server side , I use “init(view)” instead of “url:xxx.php” , but “showOverlay” is not working.

How can I solve the question ?
Please help.

Thanks
Willy

import {data} from "models/device_trans";

export default class DeviceTransView extends JetView{
	config(){
		return layout;
	}
	init(view){
		view.queryView({ view:"datatable" }).parse(data);
	}
}
-----------------------------------------------------
webix.ui({
    view:"datatable",
    on:{
        onBeforeLoad:function(){
            this.showOverlay("Loading...");
        },
        onAfterLoad:function(){
            this.hideOverlay();
        }
    },
    //url:"data/table_data.php"
});});

Hello,

you can use something like next

//shows overlay by default
  this.showOverlay("Loading..."); 
  //use data loading promise
  model.data.waitData.then(function(){
     //hide overlay after data loading
     this.hideOverlay();
  });

here data.waitData is the data promise, so you can call a showOverlay as part of initialization, and assign a code to hide it after data loading.

Some more details about waitData usage:

http://docs.webix.com/api__link__ui.treetable_waitdata_other.html

http://docs.webix.com/desktop__data_loading.html#promiseapiindataloading