Get values from selected box in bs dual list angularJS -


i trying selected values in dual box. refference of link http://www.virtuosoft.eu/code/bootstrap-duallistbox/

i have done below code snippet:

.html

<select name="duallistbox_demo1[]"                         ng-model="recschedule"                          ng-options="recschedule recschedule.recschedulingname recschedule in recordingschedules"                         size="10"                         multiple                         bs-duallistbox                         selected-list-label="{{ settings.selectedlistlabel }}"                         non-selected-list-label="{{ settings.nonselectedlistlabel }}">                 </select> 

json file:

[      {         "id": "1",                 "recschedulingname": "record schedule 1"     },     {         "id": "2",         "recschedulingname": "record schedule 2"     },     {         "id": "3",         "recschedulingname": "record schedule 3"     } ] 

.js

console.log($('[name="duallistbox_demo1[]"]').val()); 

i getting this:

["object:326"] 

i need show id or recschedulingname here.

the code have written console.log($('[name="duallistbox_demo1[]"]').val()); node js code. not compatible angualrjs.

all data can object ng-model="recschedule". can put object in foreach , see values.


Comments

Popular posts from this blog

matlab - error with cyclic autocorrelation function -

django - (fields.E300) Field defines a relation with model 'AbstractEmailUser' which is either not installed, or is abstract -

c# - What is a good .Net RefEdit control to use with ExcelDna? -