Skip to content
This repository has been archived by the owner on Jan 21, 2020. It is now read-only.

Commit

Permalink
Merge branch 'hotfix/136'
Browse files Browse the repository at this point in the history
Close #136
Fixes #133
  • Loading branch information
weierophinney committed Dec 19, 2016
2 parents ddca8fa + 25dc7ac commit 20f5b79
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 7 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

All notable changes to this project will be documented in this file, in reverse chronological order by release.

## 1.3.9 - TBD
## 1.3.9 - 2016-12-19

### Added

Expand All @@ -21,6 +21,9 @@ All notable changes to this project will be documented in this file, in reverse
- [#130](https://github.com/zfcampus/zf-apigility-admin-ui/pull/130) updates the
UI to ensure the `object_manager` key is passed when creating or updating a
Doctrine-based service.
- [#136](https://github.com/zfcampus/zf-apigility-admin-ui/pull/136) updates the
UI to allow selecting one of many Doctrine object managers; previously, the
first item was always selected.

## 1.3.8 - 2016-08-17

Expand Down

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@

<script src="apigility-ui/1bc54cd5.vendor.js" charset="utf-8"></script>

<script src="apigility-ui/cc549c05.apigility.js" charset="utf-8"></script>
<script src="apigility-ui/c1e92bf7.apigility.js" charset="utf-8"></script>

<script>
$(document).ready(function () {
Expand Down
5 changes: 4 additions & 1 deletion src/apigility-ui/rest/rest.controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
function initGeneral() {
vm.selectorNames = [];
vm.adapterNames = [];
vm.objectManagerNames = [];

vm.tags = {
accept_whitelist : [],
Expand All @@ -39,7 +40,9 @@
});

api.getDoctrineAdapters(function(err, response) {
vm.doctrine = response.doctrine_adapter;
for(var i in response.doctrine_adapter){
vm.objectManagerNames.push(response.doctrine_adapter[i].adapter_name);
}
});

api.getRest(vm.apiName, vm.version, vm.restName, function(result){
Expand Down
10 changes: 9 additions & 1 deletion src/apigility-ui/rest/rest.html
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,15 @@ <h3 class="panel-title">
<div class="form-group">
<label for="doctrine_object_manager" class="col-sm-2 control-label">Object Manager</label>
<div class="col-sm-8">
<select class="form-control" id="doctrine_object_manager" ng-model="vm.rest.object_manager" ng-options="om.adapter_name as om.adapter_name for om in vm.doctrine track by vm.rest.object_manager"></select>
<ui-select
ng-model="vm.rest.object_manager"
ng-disabled="vm.disabled">
<ui-select-match placeholder="Select Doctrine Object Manager...">{{$select.selected}}</ui-select-match>
<ui-select-choices
repeat="adapter in vm.objectManagerNames | filter: $select.search">
<div ng-bind-html="adapter | highlight: $select.search"></div>
</ui-select-choices>
</ui-select>
</div>
</div>
<div class="form-group">
Expand Down
10 changes: 9 additions & 1 deletion src/apigility-ui/templates.js
Original file line number Diff line number Diff line change
Expand Up @@ -2095,7 +2095,15 @@ angular.module("apigility-ui/rest/rest.html", []).run(["$templateCache", functio
" <div class=\"form-group\">\n" +
" <label for=\"doctrine_object_manager\" class=\"col-sm-2 control-label\">Object Manager</label>\n" +
" <div class=\"col-sm-8\">\n" +
" <select class=\"form-control\" id=\"doctrine_object_manager\" ng-model=\"vm.rest.object_manager\" ng-options=\"om.adapter_name as om.adapter_name for om in vm.doctrine track by vm.rest.object_manager\"></select>\n" +
" <ui-select\n" +
" ng-model=\"vm.rest.object_manager\"\n" +
" ng-disabled=\"vm.disabled\">\n" +
" <ui-select-match placeholder=\"Select Doctrine Object Manager...\">{{$select.selected}}</ui-select-match>\n" +
" <ui-select-choices\n" +
" repeat=\"adapter in vm.objectManagerNames | filter: $select.search\">\n" +
" <div ng-bind-html=\"adapter | highlight: $select.search\"></div>\n" +
" </ui-select-choices>\n" +
" </ui-select>\n" +
" </div>\n" +
" </div>\n" +
" <div class=\"form-group\">\n" +
Expand Down

0 comments on commit 20f5b79

Please sign in to comment.