Migrate Table visualization to React Part 1: Renderer (#3963)

This commit is contained in:
Levko Kravets
2019-07-31 17:33:33 +03:00
committed by GitHub
parent db89c4f7bc
commit 9b290913a6
40 changed files with 1091 additions and 827 deletions

View File

@@ -30,6 +30,14 @@ export function createQuery(data, shouldPublish = true) {
return request;
}
export function createVisualization(queryId, type, name, options) {
const data = { query_id: queryId, type, name, options };
return cy.request('POST', '/api/visualizations', data).then(({ body }) => ({
query_id: queryId,
...body,
}));
}
export function addTextbox(dashboardId, text = 'text', options = {}) {
const defaultOptions = {
position: { col: 0, row: 0, sizeX: 3, sizeY: 3 },