yuche / vue-strap

Bootstrap components built with Vue.js
http://yuche.github.io/vue-strap/
MIT License
4.71k stars 929 forks source link

key value selected in tags #365

Open NightZpy opened 8 years ago

NightZpy commented 8 years ago

I have:

<v-select
    :options="array"
    placeholder="Seleccione los utensilios"
    :value.sync="row.pivot_utensil.utensil_id"
    multiple
    search justified required  clear-buttont>
</v-select>

My object array:

[
    {value: '1', label: 'Cat'},
    {value: '2', label: 'Cow'},
    {value: '3', label: 'Dog'},
    {value: '4', label: 'Elephant'},
    {value: '5', label: 'Fish'},
    {value: '6', label: 'Lion'},
    {value: '7', label: 'Tiger'},
    {value: '8', label: 'Turtle'}
]

The result when use the component

wffranco commented 8 years ago

El objeto que estas utilizando no es el que estas mostrando. A simple vista parece que los datos estan bien, solo que no te los muestra por orden de numero sino por el orden en que han sido seleccionados.

NightZpy commented 8 years ago

The object is the correct, the v-select showing the value and not the text!

wffranco commented 8 years ago

The component work right, here an example with mixed values in the object: https://jsfiddle.net/wffranco/goLmr7ty/

NightZpy commented 8 years ago

@wffranco ready solve this issue, was the version, thanks for your support!