app/views/collection_json_browser/home/index.html in collection-json-browser-0.0.6 vs app/views/collection_json_browser/home/index.html in collection-json-browser-0.0.7
- old
+ new
@@ -29,12 +29,14 @@
<h2>Template</h2>
<div class="template thumbnail">
<form class="form-horizontal" ng-submit="submit()">
<fieldset class="control-group" ng-repeat="field in collection.template.data">
<label class="control-label" for='{{field.name}}'>{{field.name}}</label>
- <div class="controls">
- <input id='{{field.name}}' value="{{field.value}}" ng-model='field.value'>
+ <div class="controls" ng-switch on="field.array">
+ <input ng-switch-when="undefined" id='{{field.name}}' value="{{field.value}}" ng-model='field.value'>
+ <select ng-switch-default id='{{field.name}}' value="{{field.value}}" ng-model='field.value' ng-options="option for option in field.array">
+ </select>
</div>
</fieldset>
<div class="control-group">
<div class="controls">
<button type="submit" class="btn">Submit</button>
@@ -87,10 +89,10 @@
</dd>
<dt>
get
</dt>
<dd class="get">
- <a href="" ng-click="goTo(item.href)">{{item.href}}</a>
+ <a href="" ng-click="goTo(item.href, 'edit-form')">{{item.href}}</a>
</dd>
<dt>
delete
</dt>
<dd class="delete">