mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
Server input was not set upon server change in es.js
This commit is contained in:
parent
ea5d764f14
commit
faed2ae390
3 changed files with 11 additions and 3 deletions
|
@ -100,6 +100,7 @@ define([
|
|||
resetToValues(previousSaveState.server, previousSaveState.content);
|
||||
}
|
||||
else {
|
||||
resetToValues("localhost:9200");
|
||||
input.autoIndent();
|
||||
}
|
||||
}
|
||||
|
@ -112,8 +113,11 @@ define([
|
|||
}
|
||||
else if (previousSaveState) {
|
||||
resetToValues(previousSaveState.server);
|
||||
} else {
|
||||
resetToValues("localhost:9200")
|
||||
}
|
||||
|
||||
|
||||
if (document.location.pathname && document.location.pathname.indexOf("_plugin") == 1) {
|
||||
// running as an ES plugin. Always assume we are using that elasticsearch
|
||||
resetToValues(document.location.host);
|
||||
|
|
|
@ -57,7 +57,11 @@ define([
|
|||
});
|
||||
|
||||
var $resizer = input.$el.siblings('.ui-resizable-e');
|
||||
es.setBaseUrl($esServer.val());
|
||||
|
||||
es.addServerChangeListener(function (server) {
|
||||
$esServer.val(server);
|
||||
});
|
||||
|
||||
return {
|
||||
$esServer: $esServer,
|
||||
$send: $send,
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<span class="brand" id="server_label">Server</span>
|
||||
|
||||
<form class="navbar-form pull-left">
|
||||
<input id="es_server" type="text" class="span5" value="localhost:9200"/>
|
||||
<input id="es_server" type="text" class="span5" value=""/>
|
||||
</form>
|
||||
<span class="pull-left btn btn-link"><span id="notification" style="visibility: hidden"
|
||||
class="label label-info"></span></span>
|
||||
|
@ -44,7 +44,7 @@
|
|||
<div id="main" class="container-fluid">
|
||||
<div id="editor_container">
|
||||
<div id="editor">GET _search
|
||||
{
|
||||
{
|
||||
"query": { "match_all": {} }
|
||||
}</div>
|
||||
<div id="editor_actions">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue