Custom suggest, method _get_extendable_cell not called

I've made a custom suggest; however, the method _get_extendable_cell is never called. If I look at the source code in GitHub this method should always be called... What I'm doing wrong? Here's a snippet:



  • edited July 14

    Methods, the names of which start with _, are private. In the minified Webix code, their names are changed. So you cannot call them and cannot redefine them.
    As far as I see, _get_extendable_cell is called inside $init. So to change the logic of this method (_get_extendable_cell), you will have to redefine $init (then inside you can call your custom _get_extendable_cell). Since it's public (and stays by the same name in the minified source) you can do that. Also, mind that inside $init, you cannot call other private methods or refer to private properties. Use their public analogues (like this._settings => this.config) if possible; if not, you will have to define them in your custom component.

  • Hi Kuro, thanks for your detailed and clear answer. I'll try to overwrite the $init method.

    Maybe you should consider to make this a public method because using this method you could easily extend the suggest with a complex body (not only list or datatable view but layout views, etc.). There is also a public method called getList() which suggest you can extend the body with more complex views.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion