angularjs directive - Ng-repeat in Sightly -


i trying populate drop-down values using ng-repeat in sightly. aem node saves data string array , able fetch properly, not able populate them throws "? undefined:undefined ?" error.

my code:

<select name="${validation.elementname}" id="${validation.elementname}" ng-model="${validation.elementname}" ng-change="${properties.clickfunction}">         <option ng-repeat="opt in ${properties.options}" value={{opt}}>opt</option>                          </select> 

and output:

output:

is there missing? sightly totally new me. grateful improve code or pointing mistake.

first of all, need wrap data pass value in quotes, should this:

value="{{opt}}"  

second, looks passing values without single quotes , not being recognized strings. take @ plunker:

http://plnkr.co/edit/a2gzjbvvv9ozhlolkf4b?p=preview

you can see first ng-repeat works expected, second throws error in console , doesn't display anything. basically, need put quotes around each string in array.


Comments

Popular posts from this blog

html - Styling progress bar with inline style -

java - Oracle Sql developer error: could not install some modules -

How to use autoclose brackets in Jupyter notebook? -