Skip to content

Commit

Permalink
fix boolean type issue mobz#210 in structured query tab; remove depre…
Browse files Browse the repository at this point in the history
…cated 'from and 'to' for range query in structured query tab
  • Loading branch information
philipskokoh committed Nov 20, 2015
1 parent 7377f7f commit c011771
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions _site/app.js
Expand Up @@ -3935,6 +3935,8 @@
ops = ["missing"];
} else if(spec.type === 'ip') {
ops = ["term", "range", "fuzzy", "query_string", "missing"];
} else if(spec.type === 'boolean') {
ops = ["term"]
}
select.after({ tag: "SELECT", cls: "op", onchange: this._changeQueryOp_handler, children: ops.map(ut.option_template) });
select.next().change();
Expand Down Expand Up @@ -3985,9 +3987,9 @@

_range_template: function() {
return { tag: "SPAN", cls: "range", children: [
{ tag: "SELECT", cls: "lowop", children: ["from", "gt", "gte"].map(ut.option_template) },
{ tag: "SELECT", cls: "lowop", children: ["gt", "gte"].map(ut.option_template) },
{ tag: "INPUT", type: "text", cls: "lowqual" },
{ tag: "SELECT", cls: "highop", children: ["to", "lt", "lte"].map(ut.option_template) },
{ tag: "SELECT", cls: "highop", children: ["lt", "lte"].map(ut.option_template) },
{ tag: "INPUT", type: "text", cls: "highqual" }
]};
},
Expand Down
6 changes: 4 additions & 2 deletions src/app/ui/filterBrowser/filterBrowser.js
Expand Up @@ -134,6 +134,8 @@
ops = ["missing"];
} else if(spec.type === 'ip') {
ops = ["term", "range", "fuzzy", "query_string", "missing"];
} else if(spec.type === 'boolean') {
ops = ["term"]
}
select.after({ tag: "SELECT", cls: "op", onchange: this._changeQueryOp_handler, children: ops.map(ut.option_template) });
select.next().change();
Expand Down Expand Up @@ -184,9 +186,9 @@

_range_template: function() {
return { tag: "SPAN", cls: "range", children: [
{ tag: "SELECT", cls: "lowop", children: ["from", "gt", "gte"].map(ut.option_template) },
{ tag: "SELECT", cls: "lowop", children: ["gt", "gte"].map(ut.option_template) },
{ tag: "INPUT", type: "text", cls: "lowqual" },
{ tag: "SELECT", cls: "highop", children: ["to", "lt", "lte"].map(ut.option_template) },
{ tag: "SELECT", cls: "highop", children: ["lt", "lte"].map(ut.option_template) },
{ tag: "INPUT", type: "text", cls: "highqual" }
]};
},
Expand Down

0 comments on commit c011771

Please sign in to comment.