-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from spenceralger/discover_crud
On the road to setting up the discover skelly
- Loading branch information
Showing
15 changed files
with
300 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<ul> | ||
<li ng-repeat="field in fields"> | ||
<span ng-click="toggle(field.name)"> | ||
<i | ||
class="fa" | ||
ng-class="{ | ||
'fa-check-square': !field.hidden, | ||
'fa-square-o': field.hidden | ||
}"> | ||
</i> | ||
{{field.name}} | ||
</span> | ||
</li> | ||
</ul> | ||
<small class="pull-right"><a ng-click="refresh()">refresh field list</a></small> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
define(function (require) { | ||
var app = require('angular').module('app/discover'); | ||
var html = require('text!./field_chooser.html'); | ||
|
||
app.directive('discFieldChooser', function () { | ||
return { | ||
restrict: 'E', | ||
scope: { | ||
fields: '=', | ||
toggle: '=', | ||
refresh: '=' | ||
}, | ||
template: html | ||
}; | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,39 @@ | ||
<div ng-controller="discover"> | ||
<h1>Discover</h1> | ||
<div class="form-horizontal"> | ||
<div class="form-group"> | ||
<label class="control-label col-sm-2">Index</label> | ||
<div class="col-sm-10"> | ||
<input class="form-control" ng-model="index"> | ||
</div> | ||
</div> | ||
<!-- <div class="form-group"> | ||
<label class="control-label col-sm-3">Repeat Interval</label> | ||
<div class="col-sm-9"> | ||
<select | ||
<nav class="navbar navbar-default navbar-static-top subnav"> | ||
<form class="navbar-form navbar-left form-inline" role="search" ng-submit="fetch()"> | ||
<label class="control-label">Index</label> | ||
<input class="form-control" ng-model="index"> | ||
<label class="control-label" for="size">Query</label> | ||
<input type="text" class="form-control" ng-model="query" placeholder="search"> | ||
<label class="control-label" for="size">Limit</label> | ||
<select | ||
class="form-control" | ||
name="size" | ||
ng-model="size" | ||
ng-options="size.display for size in sizeOptions"> | ||
</select> | ||
<label class="control-label" for="sort">Sort</label> | ||
<select | ||
class="form-control" | ||
ng-model="interval" | ||
ng-options="i.display for i in intervalOptions"> | ||
name="sort" | ||
ng-model="sort" | ||
ng-options="field.name for field in fields"> | ||
</select> | ||
</div> | ||
</div> --> | ||
<form class="form-group" ng-submit="reset()"> | ||
<label class="control-label col-sm-2">Query</label> | ||
<div class="col-sm-10"> | ||
<div class="input-group"> | ||
<input class="form-control" ng-model="query" > | ||
<span class="input-group-btn"> | ||
<button type="button" class="btn" ng-click="reset()"> | ||
<i class="glyphicon glyphicon-search"></i> | ||
</button> | ||
</span> | ||
</div> | ||
</div> | ||
<button type="submit" class="btn btn-default"> | ||
<i class="fa fa-search"></i> | ||
</button> | ||
</form> | ||
</nav> | ||
<div class="row"> | ||
<div class="col-md-10"> | ||
<kbn-table rows="rows" columns="columns"></kbn-table> | ||
</div> | ||
<div class="col-md-2"> | ||
<disc-field-chooser | ||
fields="fields" | ||
toggle="toggleField" | ||
refresh="refreshFieldList"> | ||
</disc-field-chooser> | ||
</div> | ||
</div> | ||
<div class="input-group"> | ||
<label class="control-label col-sm-2">Limit</label> | ||
<select | ||
class="form-control" | ||
ng-model="size" | ||
ng-options="size.display for size in sizeOptions"> | ||
</select> | ||
</div> | ||
<kbn-table rows="rows" columns="columns"></kbn-table> | ||
</div> |
Oops, something went wrong.