1
0
Fork 0

fixed #1743, fixed a bug in query management

This commit is contained in:
hkernbach 2016-02-18 20:45:37 +01:00
parent 53f89809c6
commit 2cdce150e1
4 changed files with 52 additions and 13 deletions

View File

@ -1,19 +1,6 @@
<script id="foxxActiveView.ejs" type="text/template"> <script id="foxxActiveView.ejs" type="text/template">
<div class="borderBox"></div> <div class="borderBox"></div>
<img src="foxxes/thumbnail?mount=<%= model.encodedMount() %>" height="50" width="50" alt="Icon for Service" class="icon"> <img src="foxxes/thumbnail?mount=<%= model.encodedMount() %>" height="50" width="50" alt="Icon for Service" class="icon">
<% if (model.needsAttention()) { %>
<span class="warning-icons">
<% if (model.isBroken()) { %>
<span class="fa fa-warning" title="Mount error"></span>
<% } %>
<% if (model.needsConfiguration()) { %>
<span class="fa fa-cog" title="Needs configuration"></span>
<% } %>
<% if (model.hasUnconfiguredDependencies()) { %>
<span class="fa fa-cubes" title="Unconfigured dependencies">!</span>
<% } %>
</span>
<% } %>
<% if(model.isDevelopment()) { %> <% if(model.isDevelopment()) { %>
<div class="tileBadge"> <div class="tileBadge">
<span> <span>

View File

@ -46,9 +46,53 @@
}, },
render: function(){ render: function(){
$(this.el).html(this.template.render({ $(this.el).html(this.template.render({
model: this.model model: this.model
})); }));
var conf = function() {
if (this.model.needsConfiguration()) {
if ($(this.el).find('.warning-icons').length > 0) {
$(this.el).find('.warning-icons')
.append('<span class="fa fa-cog" title="Needs configuration"></span>');
}
else {
$(this.el).find('img')
.after(
'<span class="warning-icons"><span class="fa fa-cog" title="Needs configuration"></span></span>'
);
}
}
}.bind(this);
var depend = function() {
if (this.model.hasUnconfiguredDependencies()) {
if ($(this.el).find('.warning-icons').length > 0) {
$(this.el).find('.warning-icons')
.append('<span class="fa fa-cubes" title="Unconfigured dependencies"></span>');
}
else {
$(this.el).find('img')
.after(
'<span class="warning-icons"><span class="fa fa-cubes" title="Unconfigured dependencies"></span></span>'
);
}
}
}.bind(this);
/*isBroken function in model doesnt make sense
var broken = function() {
$(this.el).find('warning-icons')
.append('<span class="fa fa-warning" title="Mount error"></span>');
}.bind(this);
*/
this.model.getConfiguration(conf);
this.model.getDependencies(depend);
return $(this.el); return $(this.el);
} }
}); });

View File

@ -187,6 +187,7 @@
message, message,
"", "",
"", "",
"",
"" ""
]); ]);
} }

View File

@ -43,6 +43,12 @@ toolbar {
} }
} }
#queryManagementContent,
#arangoQueryManagementTable {
.table-cell1 {
word-break: break-all;
}
}
.queryMethods { .queryMethods {
@ -445,4 +451,5 @@ toolbar {
.arango-icon-disk { .arango-icon-disk {
margin-top: 1px; margin-top: 1px;
} }
} }