How to sort options in combo

edited September 2018 in Technical questions

I saw in datable has

view: "datatable",
$sort: { by: "value", dir: "asc"}
Tagged:

Comments

  • edited September 2018

    Ok I got it.

    this.assigned_combo = this.form.elements.assigned;
    this.assigned_optoins = new webix.DataCollection({
        url: "/api/test",
        scheme: {
            $sort: {
            by: "value",
            dir: "asc",
            as: "string"
            }
        }
    });
    
    this.assigned_combo.getList().clearAll();
    this.assigned_combo.getList().parse(this.assigned_optoins);
    
  • edited September 2018
    {
        view: "multiselect",
        name: "status",
        options: {
            body: {
                scheme: {
                    $sort: {
                        by: "value",
                        dir: "asc",
                        as: "string"
                    }
                },
                url: "api/test""
            }
        },
        placeholder: "Status",
        width: 200
    }
    
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