Add click on explore table cell to add filter to query (#12729)

* Add click on explore table cell to add filter to query

- move query state from query row to explore container to be able to set
  modified queries
- added TS interface for columns in table model
- plumbing from table cell click to datasource
- add modifyQuery to prometheus datasource
- implement addFilter as addLabelToQuery with tests

* Review feedback

- using airbnb style for Cell declaration
- fixed addLabelToQuery for complex label values
This commit is contained in:
David
2018-08-03 11:20:13 +03:00
committed by Alexander Zobnin
parent 72af8a7044
commit bda49fcaa2
9 changed files with 190 additions and 36 deletions
+11 -1
View File
@@ -1,5 +1,15 @@
interface Column {
text: string;
title?: string;
type?: string;
sort?: boolean;
desc?: boolean;
filterable?: boolean;
unit?: string;
}
export default class TableModel {
columns: any[];
columns: Column[];
rows: any[];
type: string;
columnMap: any;