mirror of https://gitee.com/bigwinds/arangodb
update database selector after adding/dropping databases
This commit is contained in:
parent
1e347a0d19
commit
9f340c10d5
|
@ -157,6 +157,14 @@ window.databaseView = Backbone.View.extend({
|
|||
this.collection.fetch({
|
||||
success: function() {
|
||||
self.render();
|
||||
var select = $("#dbSelectionList");
|
||||
select.empty();
|
||||
self.collection.toJSON().forEach(function(item) {
|
||||
select.append($("<option></option>")
|
||||
.attr("value", item.name)
|
||||
.text(item.name)
|
||||
.attr("selected", item.name === this.currentDB));
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue