Doubly List Insert Order Issue in RightSide list

Hello webix team,

Please refer below snippet.

Here, I would like to have the right list preserve the order in which a user adds items to it and not order them as defined in the left list.

Please provide solution for the same.


Hello webix team,

Is there any solution for this? , Or Please suggest us alternative way for the same .



When you add or remove some item to/from the right list, in reality it’s not adding/removal. Double List has 2 lists that contain same data. Filtering is what’s happening when you add/remove.
Well, I thought of a solution that besides filtering would sort values in the right list. The changes to the code are minimal, yet since there is a lot of private API involved (methods and properties the names of which start with _), I had to copy most of dbllist code…

The real changes are:

  • in this._moved store some kind of constantly incrementing values instead of booleans (webix.uid() seems to be most helpful here), so it’s setValue and select redefined
  • when data in the right list are refiltered, sort them by this constantly incrementing value (that’s in _refresh, which is a private method…)

I marked the changes to the logic with // HERE! comments.

@kuro Thanks for your Solution!!