Commit Graph

1812 Commits

Author SHA1 Message Date
Maxime Beauchemin
222671675c [exploreV2] mapStateToProps for fields (#1882)
* Controls support for mapStateToProps

* Binding methods in the constructor

* Adressing comments

* Fixing tests
2017-01-06 12:38:44 -08:00
Maxime Beauchemin
9a62d94630 [sqllab] bugfix visualizing a query with a semi-colon (#1869)
* [sqllab] bugfix visualizing a query with a semi-colon

* Fixing tests
2017-01-06 12:24:07 -08:00
vera-liu
c3edc6e24b [WIP] Add dual-axis line chart to viz (#1782)
* Add dual-axis line chart to viz
 - Add a new viz using two y axis for multi-chart in nvd3
 - Option to set metric and axis format for two y axis

* Resolve conflicts

* Fixed x axis and resized thumbnail

* Added example to __init__.py

* Change get_df to match with format
2017-01-06 10:30:27 -08:00
Maxime Beauchemin
119b0c55e9 [explore] fix height in embed mode (#1898)
* [explore] fix height in embed mode

* Linting
2017-01-06 09:41:53 -08:00
Maxime Beauchemin
c14c7edc5e [explore] show the broken query when failing (#1871)
* Return query when failing

* Linting

* sjson -> simplejson
2017-01-05 10:00:39 -08:00
Riccardo Magliocchetti
e3b296c558 utils: teach our json serializer to handle more types (#1907)
Namely datetime.time and numpy.bool_

Refs: #1900
Refs: #1903
2017-01-05 09:56:07 -08:00
Maxime Beauchemin
c2d29fb54b Change ordering of fields when adding a table (#1899) 2017-01-04 17:36:37 -08:00
Maxime Beauchemin
7aab8b0ae3 Simplifying the Fields (Controls) interface (#1868)
* Simplifying the Field interface / logic

* Moving ControlLabelWithTooltip where it belongs

* Progress

* Rename FieldClass->FieldType
2017-01-04 15:46:52 -08:00
andreamelloncelli
861a3bd4ae docs: 8088 is the default port, no need to specify it (#1861)
* docs: 8088 is the default port, no need to specify it

* docs: hint to use a non default port
2017-01-04 14:43:56 -08:00
vera-liu
9bc7ad9cd5 Do not use persistState for explorev2 (#1894)
* Do not use persistState for explorev2

* Change enhancerWithPersistState to enhancer and function name to initEnhancer
2017-01-03 20:23:43 -08:00
Maxime Beauchemin
a1e3fc1c23 [explorev2] giving more room for long textboxes (#1881) 2017-01-03 18:06:49 -08:00
Alanna Scott
242869db3a [sql lab] only show single run query button (#1858)
* only show single run query button, allow async if possible

* only pass the needed props, rather than entire objects to the component

* add simple test

* fix linting
2017-01-03 17:20:30 -08:00
Maxime Beauchemin
8924bb79e7 [explorev2] moving the "Time" section up to 2nd section (#1885)
This keeps the same section ordering as in v1.
2017-01-03 14:18:55 -08:00
David Moodie
a0d103dac3 Fix small typo (#1888) 2016-12-29 17:51:25 -08:00
Maxime Beauchemin
d52b299df8 Updating CHANGELOG 2016-12-28 14:02:26 -08:00
Maxime Beauchemin
092432f04f v0.15.1 2016-12-28 13:29:17 -08:00
willgroves
ea8e6634d6 read anon user role from config, remove reference to public role (#1878)
* read anon user role from configuration, add anon user role as 'Public' to testing configuration

* apply suggestions
2016-12-27 14:30:01 -08:00
Dongkyu Hwangbo
3e6f90cf72 Upgrading pydruid version and adopt 'merge' flag during refresh_druid operation (#1879)
* Initial

* rewrite some line to make it short and setting merge variable temporarily

* rewrite commit author

* add emitted attribute

* Fix typo

* fix test error

* fix typo

* test added
2016-12-27 14:27:55 -08:00
Maxime Beauchemin
16731056ed [sqllab] async queries - better error handling (#1853) 2016-12-19 22:33:55 -08:00
Maxime Beauchemin
0712894353 Improving database logging by adding duration, referrer and post data (#1830)
* Improving logging with duration and referrer

* Handling case where referrer is None

* Providing log_this with its own session

* Attempting to fix tests

* Fixing tests
2016-12-19 22:32:50 -08:00
Riccardo Magliocchetti
36fad803ed sqllab: don't hold database deletion because of query reference (#1863)
Let people delete the database even if there are sqllab queries
on that database. Instead delete them too.

Fix #1848
2016-12-18 17:12:23 -08:00
vera-liu
6732f01cb7 Enable freeform-select with fetched column values for filter values (#1697)
* Enable freeform-select with fetched column values for filter values
 - db migration to add filter_select_enabled
 - add freeform-multi option for Selectfield
 - modify formatFilter() function on query to accomodate filter-select

* Fix js tests

* Fix codeclimate issue

* Changes based on comments

* Add test for filter endpoint

* Extract out renderFilterFormField function from render

* Fix landscape issues
2016-12-16 14:23:48 -08:00
szmate1618
bb04e6fcfa Use APP_ICON in template (#1855)
* use APP_ICON in template

* use APP_NAME in navbar template
2016-12-16 08:56:26 -08:00
Maxime Beauchemin
007ee88d33 [explorev2] improving the scrolling/scrollbars placement (#1840) 2016-12-16 08:06:40 -08:00
vera-liu
7a5bb94754 Stop ChartContainer from rendering twice on chartStatus change (#1828)
* Stop ChartContainer from rendering twice on chartStatus change

* Make spinner overlay and dim chart while laoding

* Added timeout to make render more stable on resize

* Put viz in state and call resize at browser size change

* add render after height change since resize depends on render called on the same object

* Change name of renderVis to renderVisOnChange

* Only call resize at height change, persist viz in state

* Call resize wihout render at window size change
2016-12-15 14:06:54 -08:00
vera-liu
e06a0cd89b Add force_ctas_schema to query model when enabled (#1825)
* Add force_ctas_schema to query model when enabled

* Add schema to temp_table_name

* Remove extra arg in create_table_as
2016-12-15 13:19:54 -08:00
Maxime Beauchemin
b6cba13293 [explorev2] enabling redux dev tools (#1842) 2016-12-15 08:54:02 -08:00
Maxime Beauchemin
d929bbfe30 [explorev2] making QueryAndSaveBtns disabled while running queries (#1841)
As I altered QueryAndSaveBtns to add the `disabled` prop
I also moved it to using react-boostrap
2016-12-15 08:53:33 -08:00
Maxime Beauchemin
bf67d64708 [explorev2] making Datasource an Viz controls not clearable (#1845)
* [explorev2] making Datasource an Viz controls not clearable

* Making choices default to empty list
2016-12-15 08:53:15 -08:00
Bogdan
92aa1a6124 Permissions refactoring, optimizations and unit testing. (#1798)
* Refactor and speed up superset init

* Add unit tests.

* Test fixes.

* More test updates.

* Fix read only perms

* Address comments.
2016-12-15 08:38:34 -05:00
Maxime Beauchemin
733ab8014b [explorev2] using a loader to load the explorev2 specific css (#1843) 2016-12-14 18:31:50 -08:00
Alexander Mancevice
6aaa49f0bf Change default gunicorn address (#1838)
Use `0.0.0.0` as default instead of `127.0.0.1`
2016-12-14 16:34:35 -08:00
vera-liu
638f27c2df [sqllab] Fix sql expression bug with count distinct metrics (#1805)
* Return error message when metrics are not valid

* Fix bug with count distinct expression

* Fixed codeclimate issue
2016-12-14 16:09:22 -08:00
Maxime Beauchemin
84a3b55912 [explorev2] remove unused file SqlClause.jsx (#1839) 2016-12-14 15:17:45 -08:00
Maxime Beauchemin
552d46479b [explorev2] no bootstrap data, just metadata in exploreV2 (#1827)
json_data really just returns the *metadata* for the slice, where
get_json returns both the metadata and the data
2016-12-14 14:42:14 -08:00
vera-liu
fa9c066ffe Add email-to option in action buttons for dashboard and slice (#1705)
* Add email-to option in explore action buttons

* email to option for dashboard
2016-12-14 11:52:53 -08:00
vera-liu
e1e20b8757 Sort searched queries by recency (#1735)
* Sort searched queries by recency

* Fixed sqllab tests

* Add one more tr to QueryTable spec for pagination

* Change desc to asc as we reverse queries in component
2016-12-14 10:14:54 -08:00
Rossouw Minnaar
2fb94a89e2 Add ADDITIONAL_MIDDLEWARE option to config (#1832)
Add documentation to explain ADDITIONAL_MIDDLEWARE
2016-12-14 09:39:59 -08:00
rlei
7a9604a3c9 Workaround for slices "Not Found" issue in IE <= 11 (#1821)
This should fix issue #1339.

IE 11 and lower has a long standing issue: out-of-document element's
pathname has no leading '/'. See

https://connect.microsoft.com/IE/feedbackdetail/view/1002846/pathname-incorrect-for-out-of-document-elements

And Superset's Slice.jsonEndpoint() method relies on pathname() to build
JSON API URL for slices:

```javascript
      jsonEndpoint() {
        const parser = document.createElement('a');
        parser.href = data.json_endpoint;
        let endpoint = parser.pathname + this.querystring();
        endpoint += '&json=true';
        endpoint += '&force=' + this.force;
        return endpoint;
      },
```

`parser` above is exactly an out-of-document element. Therefore when
running in IE <= 11, Superset would build wrong JSON endpoint URLs,
hence the 404 errors for loading data for slices.

This commit adds a simple workaround when leading '/' is missing in the
value returned by pathname().
2016-12-14 08:41:03 -08:00
Maxime Beauchemin
e099088012 [hotfix] fixing the build 2016-12-13 16:05:05 -08:00
Alanna Scott
34e107e7d3 [explore-v2] add config option for explore v2 beta users, and send through v2 path (#1671)
* add config option for explore v2 beta users, and send through v2 path

* fix long lines

* use role rather than user ids in config

* add test

* simplify role check

* remove extra  line

* use different test user for v2 tests
2016-12-12 16:42:38 -08:00
Maxime Beauchemin
2254a4d0b4 v0.15.0 2016-12-12 11:30:11 -08:00
vera-liu
9f7486f402 remove extra call to get_viz in explorev2 (#1812)
* Not working errors

* Remove update_explore endpoint, only update explore endpoints in reducer on query

* Change scroll to auto and make container reponse to height:

* Remove update_explore endpoint

* Remove can_update_explore perm
2016-12-12 10:58:07 -08:00
vera-liu
699602d1c5 Add tooltips to RunAsync and CTAS button (#1792)
* Add tooltips to RunAsync and CTAS button

* Use button from components

* Phrasing
2016-12-12 10:13:01 -08:00
Daniel Darabos
2993ff1d75 Add NVD3's bullet chart (#1775)
* Add NVD3's bullet chart.

* Add empty lines before nested function definitions.

* Add thumbnail for bullet chart.

* Add bullet chart to gallery.rst.

* Add "requiresTime: false", fix indentation.

* Avoid scaling bullet chart vertically.

* Use a default if no range is specified.

* Fix coloring of bullet chart.
2016-12-12 08:58:13 -08:00
Maxime Beauchemin
afb3c24d5a Showing more fields in DatabaseView 2016-12-10 08:06:58 -08:00
vera-liu
8ef730b5fe Added timer to explore v2 and share it with sqllab (#1802)
* Added timer to explore v2 and share it with sqllab

* Fixed js tests

* Add timer to initial load

* Make timer smaller

* nits
2016-12-09 13:39:53 -08:00
vera-liu
866cfe5279 Add schema name to output column in query history (#1790)
* Add schema name to output column in query history

* Replace line break with dot between schema and table name
2016-12-09 11:03:31 -08:00
Maxime Beauchemin
68c2eab6b9 [hotfix] handling 0% change in big number with trendline (#1801) 2016-12-08 12:59:35 -08:00
Maxime Beauchemin
aeda5bd260 [sqllab] config item for SQLLAB_DEFAULT_DBID (#1793) 2016-12-07 21:01:02 -08:00