Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Omit date selection field for non time based searches #160

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions htdocs/assets/js/views/searches/search.js
Original file line number Diff line number Diff line change
Expand Up @@ -529,6 +529,7 @@ define(function(require) {
no_freq: this.no_freq,
has_sources: _.isArray(sources),
host: Data.Host,
is_time_based: Search.Data().TimeBased[this.model.get('type')]
});
// Render any additional content.
vars.addn_fields_a = this.addnFieldsATpl(vars);
Expand Down
4 changes: 4 additions & 0 deletions htdocs/assets/templates/searches/search.html
Original file line number Diff line number Diff line change
Expand Up @@ -237,18 +237,22 @@
<button id="test-button" type="button" class="btn btn-info">
<span class="glyphicon glyphicon-list-alt"></span> Test
</button>
{{#if is_time_based}}
<button id="custom-test-button" type="button" class="btn btn-info">
<span class="glyphicon glyphicon-wrench"></span>
</button>
{{/if}}
</div>
{{#unless new_search}}
<div class="btn-group">
<button id="execute-button" type="button" class="btn btn-primary">
<span class="glyphicon glyphicon-play"></span> Execute
</button>
{{#if is_time_based}}
<button id="custom-execute-button" type="button" class="btn btn-primary">
<span class="glyphicon glyphicon-wrench"></span>
</button>
{{/if}}
</div>
{{/unless}}
{{#if new_search}}
Expand Down