PromucFlow_constructor/app/client/src/actions/queryPaneActions.ts
akash-codemonk a0351bfe81
Get query ui from form config (#205)
* Get query ui from form config

* Update editor config selector

* Show error message when config is undefined

* Move FormLabel to components

* Show dark theme in query editor

* Allow query name to be focused
2020-08-12 11:57:35 +05:30

30 lines
725 B
TypeScript

import { ReduxActionTypes, ReduxAction } from "constants/ReduxActionConstants";
import { RestAction } from "entities/Action";
export const createQueryRequest = (payload: Partial<RestAction>) => {
return {
type: ReduxActionTypes.CREATE_QUERY_INIT,
payload,
};
};
export const initQueryPane = (
pluginType: string,
urlId?: string,
): ReduxAction<{ pluginType: string; id?: string }> => {
return {
type: ReduxActionTypes.INIT_QUERY_PANE,
payload: { id: urlId, pluginType },
};
};
export const changeQuery = (
id: string,
newQuery?: boolean,
): ReduxAction<{ id: string; newQuery?: boolean }> => {
return {
type: ReduxActionTypes.QUERY_PANE_CHANGE,
payload: { id, newQuery },
};
};