Commit graph

113 commits

Author SHA1 Message Date
Arpit
aa1acbe230
bugfix - Fixes add constants support to auth headers (#7271)
* fixes: prevent the default form submission behavior when the user presses "Enter"

* should allow empty strings as value

* handle loading state

* adds support of constants to restapi auth components, openapi

* support of constants to oauth

* support of constants to zendesk

* support of constants to restapi headers
2023-08-17 14:50:31 +05:30
Arpit
ee79b2015a
Feature - Workspace environment constants (#6810)
* init--

* org constants: controllers, services, module and api for creating new constants

* read operation: all constants from all envs and all constants from a env

* update and delete operation

* updated delete msg

* encrypt constant value before saving and decrypt before sending back to controller

* adds group permission for org constants and required migrations

* adds ability to create constant

* adds group permissions and fixes migrations

* adds workspace constant permission to workspace settings UI

* ToolJetUI - componenst, ref: ee/5c92dc9c03b73d7006562d71d639fe4eb1971dee

* Org constants UI

* UI updates: display constant value as per enviroment

* Added client side pagination

* groups without create/edit/delete permission can only view the the constants

* group permission: Create and Edit - UI updates

* create/update/date flow - UI

* extending api support to create constant in multiple environments

* UI - add constant for multiple envs

* disable name input for update operation

* UI fixes and updates

* adds deprecating banner to variables dashboard

* removes update/create from UI --variables

* adding depricating soon alert in codehinter when workspace vars are used

* extra check to display the banner in preview of cdehinter

* resolves constants for admin in client-side

* resolves constants client-side and server side for queries

* include grp permission for create/delete for org constants

* resolves org constants in runJS and runPY

* cleanup

* updated the tab UI

* fixed: constant pagination footer

* fixes client side pagination bug

* adds docs link

* ui updates and fixes ui flickering on closing the drawer

* refactor updating table data

* adds error state to constant forms

* remove the alert from runJS and runPY after 5s

* added max length constraint for constant value

* refactor: component form

* delete only constant as per environment

* remove unwanted logs

* resolves constants in gds connection forms

* resolve gds source options for testConnections, preview and runQuery

* UI style fixes: banner

* remove alert banner for runJS and runPY

* input text color fixed

* style fixes for disabled inputs

* Edit constant- Until value is changed- CTA should be disabled

* adds tooltip for table name and value

* adds tooltip for disbaled input in edit drawer

* updated the tooltip position

* handle input height on type for large strings

* added empty state

* adds new badge for workspace constants

* substring should be different for viewers

* resolve constants in viewer

* add support to resolve constants for widgets and queires in public apps

* changed the api endpoint for org constant for env

* bugfix: handle org constants for encrypted value from source options

* add support to resolve app variables and constants in a single single

* fixes: multiple multiline and same line variables

* refactor

* cleanup

* remove encryption for ce

* remove group permission from permission dashboard

* text transform for badge

* added padding for each table row

* updated alert banner padding

* updated alert banner padding

* updates width for empty banner

* refactor

* adds tests for constant api

* added validations for constant name

* updates textare dynamic form

* updates the resolvers for constants

* removes decryptiong for source options in services

* refactor - frontend

* resolved conflicts

* fixes: typo-1 ~ workspace variables alert

* fixes: inconsistency in alert info icon

* fixes: naming convention consistency

* fixes: dark theme for confirm box

* disable create button for  add constant with same name,

* adds error state for updating constant with same value

* fixes: error message typo

* fixes: error message typo

* fixes position of tooltip

* fixes frontend lint issues

* update lock file

* UI updates and typos

* cleanup-refactor

* checking error state before creating

* should check all error states

* resolving multiple constants and app variables in a single line

* reafactore

* fixed: depricating icon : codehinter preview box

* remove log

* remove repeated logic for deleteOrgEnvironmentConstant

* only return status code for delete request for org constants

* Add data-cy for workspace constants elements (#7251)

* updates contants doc link

---------

Co-authored-by: Ajith KV <ajith.jaban@gmail.com>
2023-08-14 14:28:51 +05:30
Johnson Cherian
55cdc7a0b5
Query manager revamp (#6680)
* global store init

* Moved query data to new component

* Removed unwanted code

* Removed data queries prop drilling

* Moved query state out of editor

* Added unsafe to componentWillReceiveProps

* Selected first query when the version is changed

* Fixed bug on renaming query

* Fixed issue on dark theme

* Fixed running query on page load in viewer

* Query manager refactor init

* Added global data source in store

* Disabled devtools on production

* Fixed bug on selecting query after deletion

* Reset store when editor is loaded

* Moved query manager to functional component

* Fixed conflict issues

* Fixed infinite loop on tooljetDB

* Set the store name and updated devtools logic

* Fixed issue on displaying draft query from data sources

* Updated comments on the store

* Fixed bug on changing data source and creating query from data source

* Fixed bug on showing unsaved changes popup

* Fixed issue on showing confirmation modal everytime without any changes

* feat: autosave data query functionality

* feat: show publish button only when the status in draft state

* Fixed issues on query renaming

* feat: removed discard popup for data query create/edit widget

* stye: reduced autosave api call timeout and added draft tag

* feat: added minor style changes

* feat: fixed issues with restapi plugin, removed unused api calls

* fix: fixed issue that breaks restapi creation

* fix: reload selected query details after update query

* perf: reduced debounce time for data query update apis

* feat: removed full reloading of query list on query renaming

* feat: duplicate data query feature added

* Fixed issue on creating restAPI query

* fix: fixed issue in transforming response from update queyr api

* fix: refresh selected query details when the selected query is updated

* fix: rename query on click enter

* fix: full refresh of query list on update

* fix: style changes

* fix: subscribing to state to autsave

* feat: updated the query manager styles to new design

* feat: revamped the querypane header buttons

* fix: fixed the padding for query panel maximize button

* feat: updated search box style

* refactor: moved function to render data source icon to its own component

* fix: fixed querymanager widget breaking issue

* merged with feat/query-manager-autosave

* refactor: removed unused consoles

* refactor: removed unused consoles

* refactor: removed unused consoles

* fix: removed commented code

* fix: removed unused code

* refactor: removed unused comments

* fix: show change datasource select only if valid ds available

* Update frontend/src/Editor/Inspector/EventManager.jsx

Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>

* Update frontend/src/Editor/QueryManager/Components/DataSourceLister.jsx

Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>

* Update frontend/src/Editor/QueryManager/Components/DataSourceLister.jsx

Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>

* Update frontend/src/Editor/QueryManager/Components/QueryManagerBody.jsx

Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>

* feat: modify behaviour of search icon in query panel

* fix: fixed theme color mismatch in query manager

* refactor: remove dead code

* refactor: updated theme for data source listner

* fix: theming in filter and sort popup

* refactor: remove unused variables

* fix: removed draftQuery logic from query manager

* refactor: removed unused varibales

* Update frontend/src/Editor/QueryManager/QueryEditors/Restapi/TabParams.jsx

Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>

* Update frontend/src/Editor/QueryPanel/QueryCard.jsx

Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>

* feat: diable preview for draft queries

* fix: added tooltip for query panel button

* fix: fixed issues in saving query manager events

* fix: moved query save subscriber to QuerPanel component

* feat: converted query run api to save and run

* fix: made varibale an optional param in updateDataQuery dto

* refactor: cleanup update dataquery status api response

* refactor: moved query status to constants file

* feat: prompt for queryname when creating new query

* fix: store new queryname in state on create query pageload

* fix: fixed alignment of Tooljet db component form

* fix: correct translation and format file

* refactor: removed consoles

* merge: merge appbuilder-1.2

* style: updated rename input/button UX

* style: revamped dataquery create widget styles

* style: revamped data source selector styles

* fix: removed code added for debugging

* style: updated data query filter design

* style: Add prop to control visibility of clear button in search box

* style: implement new style for query filter

* merge appbuilder-1.2 to feat/query-manager-sort-filter

* refactor: remove unintended file change

* fix: set default value for method in respapi

* style: updated copilot info popup style

* style: updated quer panel header icons

* style: updated button styles

* style: fixed query manager button styles

* style: smoothened query preview modal view

* fix: correct import for some funs

* fix: fixed minor UX bugs

* style: fixed styling of REST api GDS

* style: fixed styleing of sort and filter popup

* style: improved data queries sort filter UI/UX

* fix: remove click listner when overlay is closed

* fix: moved component declaration out of parent component

* fix: set selected datasource for default sources

* fix: filter DS based on saerch in create dropdown

* fix: restrict draft query running to preview mode

* fix: query renamed on input change in create screen

* fix: set name to state as soon as user renames query

* fix: make query notification message consistent

* style: correct s3 bucket plugin layout config

* fix: fixed issues with cloning of Static DS queries

* fix: made change so that newly created query is reflected immediatly

* style: updated spacing for query manager components

* fix: hide rename input when no query selected

* fix: check bothe selected query and DS before rendering query manager

* fix: set isSaving to true only for api calls in querymanager

* fix: added success message form in qm

* fix: filter out draft queries from viewer on running

* fix: fixed inconsistent gutter for runpy and runjs editors

* fix: reload dataqueris on LDS deletion

* fix: redesigned filter/sort popup

* fix: fixed issue that resets filter on search

* fix: fixed query manager breaking on plugin select

* fix: diable json preview for text output

* fix: reset to filter and sort main menu on close filter popup

* refactor: rename varibales

* stye: redesigned query create panel

* feat: revert data query status column from backend

* style: redesign query picker section

* refactor: removed dead code

* style: querypanel expand/collapse btn style

* style: add query select and query filter popup style redesign

* style: updated filter popup style

* feat: removed draft query checks everywhere

* style: empty dataqueries style changed

* style: updated query selector popup and rest options styles

* style: removed 100% height to query option remove btn

* feat: added the query runnable status check

* style: updated query manager footer style

* feat: changed DS filter from kind to DS ID

* style: minor ui tweaks in filter popup

* style: disable DS filter if no DQs created

* style: minor ui change

* fix: rerender filter popup post DS api call. fixed rest api copy feature

* fix: add local DS to filter popup

* refactor: removed dead code/comments

* add new row is crashing when no data is fed to table (#7102)

* fix: fixed condition that blocked GDS run on load

* fix: revert name back to og name if update fails in rename query

* feat: added tooltip for show query btn

* fix: added click interaction for pill btn as well

* fix: minor UI tweaks to make UX better

* style: fixed the styling of filter popup

* style: minor UI tweaks in query filter popup

* fix: fixed minor css issue in ds picker

* style: wrap overflowing text in queryname

* fix: update updated_at after query update api call success

* fix: update remove the caller query from event query dropdown

* style: minor ui spacing tweaks

* fix: fix issue that cuased app crash when tjdb opened

* fix: fixed update row styles

* fix: fixed info popup dark theme bg

* fix: fixed headers styling according to general QM styles

* style: fixed stripe QM UI

* fix: added tooltip for quernames

* feat: add tooltip for select ds options

* added consoles to debug debugger issue

* fix: fixed :active style of ds select dropdown in QM

* fix: fixed DS kind name in data source selector in QM

* fix: fixed border color mismatch for ds select dd

* fix: change tooltip msg for maximize/minize QM

* Fix automation for query manager revamp. (#7223)

* Add data-cy to support modified specs

* Fix event handler

* Fix RunPy and RunJS specs

* Fix event handler label

* Fix basic components spec

* Fix basic components failure

* Fix tabel spec failure.

* Fix runjs and runpy actions

* Fix table column options

* Add data-cy

* version: version updated to 2.13.0

* Version bump

---------

Co-authored-by: Kavin Venkatachalam <kavin.saratha@gmail.com>
Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>
Co-authored-by: Manish Kushare <37823141+manishkushare@users.noreply.github.com>
Co-authored-by: Midhun Kumar E <midhun752@gmail.com>
2023-08-09 18:01:48 +05:30
Akshay Sasidharan
22ae4925c7 Merge branch 'develop' into release/marketplace_1.2 2023-08-03 12:13:24 +05:30
Akshay Sasidharan
d2a99c6853 Merge branch 'release/marketplace_1.2' of github.com:ToolJet/ToolJet into release/marketplace_1.2 2023-08-01 14:43:00 +05:30
Muhsin Shah C P
b909485201
[fix] Local datasource is crashing for cloned apps. (#7165)
* Adding cypress workflow to main (#7162)

* fixed local datasource issue

---------

Co-authored-by: Adish M <44204658+adishM98@users.noreply.github.com>
2023-07-31 22:46:04 +05:30
Nakul Nagargade
2a83ef5b09
[BugFix] Fix dynamic form breaking in case "react-component-headers" form type outside of the editor (#7113) 2023-07-24 16:34:26 +05:30
Muhsin Shah C P
80ee7b7cac
[Improvement] Auth flow improvements for RestAPI, OpenAPI & GraphQL (#5324)
* Added access token url headers option to open api

* removing and adding code

* add authentication in GraphQL as RestAPI (#6687)

* add authentication in GraphQL as RestAPI

* fix: remove double header check

---------

Co-authored-by: Jean-Baptiste PIN <jeanbaptiste@idruide.com>

* refactor auth flows for restapi, openapi & graphql

* fix type errors

* remove redundant declarations

* fix openapi build error

* update authUrl for OAuth

* fix oauth check

---------

Co-authored-by: Akshay Sasidharan <akshaysasidharan93@gmail.com>
Co-authored-by: Jean-Baptiste PIN <jibet.pin@gmail.com>
Co-authored-by: Jean-Baptiste PIN <jeanbaptiste@idruide.com>
2023-07-21 15:38:56 +05:30
Nakul Nagargade
3f75baa7ef
Move the entire current state to Zustand store (#6812)
* Move current state to Zustand store

* Remove console logs

* Bug fixes

* Bug fix

* Code refactor

* Fix table not rendering when selected

* Refactor

* Resolve imports

* Resolve code comments

* Prevent current state store zustand actions not to exposed to user

* Fix

* Move current state from viewer to Zustand store

* Bug fix

* Resolve code comments

* BugFix

* Bug fix

* bug fix

* fix action button event not being triggered in table

* Resolved comments
2023-07-19 11:42:28 +05:30
Arpit
10668546d9
Improvement - adds ability to resolve workspace variables in GDS connection forms (#6824)
* adds ability to resolveworkspace variables in GDS connection forms

* clean up

* resolves workpace variables in GDS connection form UI (client-side)

* fixes: encrypted source options resolver helper

* add workspace vars support for textarea components used in gds

* updates warning banner

* update textarea with the new UI

* Revert "Merge branch 'develop' into improvements/add-support-workspace-vars-datasource-forms"

This reverts commit f3b42005aa, reversing
changes made to 68334ca281.

* Revert "Revert "Merge branch 'develop' into improvements/add-support-workspace-vars-datasource-forms""

This reverts commit 9b19e5b530.

* fixes crash when trting to resolve variables

* remove comments
2023-07-04 15:32:45 +05:30
arpitnath
33416b2563 Merge branch 'develop' into plugin/textract 2023-05-03 13:21:05 +05:30
arpitnath
752cd7c436 clean up 2023-05-02 15:24:31 +05:30
arpitnath
74f02a3bf3 gRPC UI: Source connection form and query builder 2023-05-02 05:20:33 +05:30
arpitnath
eff47e0cbb Merge branch 'plugin/textract' of github.com:ToolJet/ToolJet into plugin/textract 2023-04-25 15:13:36 +05:30
arpitnath
616c8e17ed fixes selcecting feature types 2023-04-25 15:08:38 +05:30
Akshay Sasidharan
34e074f229 fix import 2023-04-24 13:40:58 +05:30
Adish M
9f509c6e40 adding index.js 2023-04-24 11:46:55 +05:30
Adish M
68779b377a removed extra back slash 2023-04-24 11:34:16 +05:30
arpitnath
73ffcd3397 adapt to new UI styles 2023-04-23 02:50:17 +05:30
arpitnath
30f5b26e98 Merge branch 'develop' into plugin/textract 2023-04-23 02:28:59 +05:30
arpitnath
865f1d3226 resolve file path 2023-04-23 02:28:23 +05:30
arpitnath
16c7b1f8c0 resolved path 2023-04-21 18:20:49 +05:30
arpitnath
b18e0cf79a Option to select feature types 2023-04-21 15:35:51 +05:30
Kiran Ashok
65259afeb2
Feature Homepage and settings redesign (#5763)
* adding colors

* feat :: add button

* feat :: added typography

* feat: init storybook

* removes browserlist

* feat :: adding button styles and button component

* feat :: added sass addon

* stories update

* feat :: replacing with radix colors

* danger variants

* updates buttin story

* fix :: removing default items

* cleanup

* fix icons update

* feat :: folder list component

* fix :: naming

* icon and split button :: init

* intermediate save :: app card component

* renaming

* updates

* update for module imports

* updates icon

* update :: homepage design updates

* design changes dashboard

* updates :: apps section

* workspace stting new design upate

* updates dasboard design

* style :: fixes

* feat :: added context for sidebar nav breadcrumb

* added all solid icons

* intermediate update

* change: conditions for fetching users

* sorybook updates

* design updates :: workspace settings page

* manage users page

* lint fixes

* fix :: styling

* stle fixes :: workspace settings

* homepage redesign

* fix :: all drawer colors and position ,teplate page revamp , database page header fixes

* imported all bulk icons

* svg to jsx : bulk icons

* minor :: cleanup

* fix :: manage users drawer

* fix :: searchboxes , userspage fixes

* fix :: all inputs and minor ui fixes

* database page ui fixes

* fix :: database and folder search functionality and iconlist in homecard

* fixed some db functionality and edge cases for longer texts

* fix :: user addition manage user page

* self review cleanup and change in bulk icon fill state

* fix :: homepage seacbar

* merging develop and resolving conflicts

* remove unwanted stories

* reverting merge with develop

* Revert "reverting merge with develop"

This reverts commit 2150c8ec0c.

* clearing out warnings

* lint fixes

* feat :: added org modal in database page

* fix :: sso loader theme

* fix :: broken styles select

* fixed icon warning and select ui

* fix :: upload bulk and user select dark mode

* merge styles  with develop

* feat :: integrated new ui for database

* removing storybook files

* fix :: all bugs related to users dropdown and cleanup

* fix: user search api for organization page

* cleanup and splitting dropzone component

* fix :: overflow issue in app card time

* fix for scrollbars in homepage

* PR review fixes

* updates :: fix d=global datasource design issues , homepage responsiveness

* tj db operations

* breadcrumb bug fixes

* lint fixes

* removing logs , removed fade in in datasource and database page

* marketplace page ui fix

* removing inital users table fetch

* Pr :: review changes

* remove logs

* fix :: popover bug

* minot style fix

* fix :: remove arrow from all popovers

* fix :: for loading states

* ux :: sidebar items reorder

* style :: fix

* style fix :: templates

* fix :: qa bugs

* fix :: Qa reported bugs

* removes :: folder fetch bug

* share link and datsource bg color fix

* fixes :: rename group ,

* removed logs

* pages popover background fix

* fix :: tj db table addition ui bug

* fix :: ui bug confirm modal password disable

* modal , revert name capitalize in lists, typos fix

* typos , users page route bugfix

* users page header bugfix

* workspace archive btn , datasources form style for select

* groups updated , delete, create flow updated

* avatar bug in profile page fix

* revert styles

* fix :: for create new table nav breadcrumb not being updated

* click state bug fix in avatar

* fix bug with appcard popover

* fix :: text capitalize issue

* fix :: lints and updated icon for filter delete

* fix warnings

---------

Co-authored-by: gandharv <gandharvkumargarg@gmail.com>
Co-authored-by: Vijaykant Yadav <vjy239@gmail.com>
2023-04-21 11:45:48 +05:30
vjaris42
bb9a211e55
[Feature] :: Global datasources (#5504)
* add: columns and migrations for data queries and sources

* add: migrations for app environments

* fix: datasources and queries api

* fix: import apis

* add: radixui colors

* create: global datasource page

* fix: version creation not including global datasources queries

* fix: version deletion failure

* fix: ui and other bugs

* add: check for abilities on global ds

* fix: bugs

* fix: existing test cases

* fix: migration and bugs

* fix: rest api oauthorize bugs

* hide: add button for local ds

* fix: query bugs

* fix: new organization environment creation

* fix: local ds label showing for new apps

* fix: on page load queries for preview app and published app

* fix: import bugs from v1

* fix: merge conflicts

* fix: import apis

* fix: apss with mulit envs

* fix: ui bugs

* fix: environments not being created on db:seed

* fix: ui bugs

* fix: route settings for global datasources

* fix: customer dashboard template

* fix: local ds queries not being saved

* fix: runpy issues

* changes: ui

* fix: migration issues

* fix: ui

* hide datasources when no local datasources

* fix: test cases

* fix: unit test cases and global queries on app import/export

* cleanup

* add: package-lock file

* undo: migration rename

* cleanup

* fix: ui bugs

* migration fixes

* fix: dark mode issues

* fix: change datasource failing on query create mode

* fix: workspace selector issues

* fix: clickoutside for change scope option

* migration changes

* fix: open api issue

* reverting configs changes

* [Fix] Global datasources & Environment Id issue (#5830)

* fix: oauth env id issue

* code changes

---------

Co-authored-by: gsmithun4 <gsmithun4@gmail.com>
Co-authored-by: Muhsin Shah <muhsinshah21@gmail.com>
2023-03-24 21:41:21 +05:30
Arpit
7dea6c9ad1
Enhancements to the process of developing a Marketplace plugin (#5777)
* in dev mode, start watching for changes in all packages

* plugin reload service

* typo

* fixes updates from fs

* checks if marketplace dev mode is on to decode the run code from plugin index file

* clean up

* removes console.log

* refactor: marketplace dashboard

* prep to merge

* dotenv

* fixes: install new upadates for one plugin at a time

* fixes app crash for new plugins(marketplace/datasource) with default schema

* avoid creating docs for marketplace to root docs

* Before starting watcher, build the marketplace once.

* fixes: installed plugin crashes if deleting the entire plugin from the dir, but the build still haves the plugin files
2023-03-24 17:05:08 +05:30
Arpit
29bdabb176
eslint fixes: frontend (#5464) 2023-02-02 20:58:06 +05:30
Arpit
b19c854dbd
fixes app crash for adding and then removing ds (#5281)
* fixes app crash dues to options obj empty

* undefined selected ds fix

* undefined selected ds fix

* undefined selected ds fix:slack

* undefined selected ds fix:zendesk

* undefined selected ds fix:zendesk

* undefined selected ds fix:zendesk ds id
2023-01-25 12:09:02 +05:30
vjaris42
1b9304835a
add: check for incoming new datasource (#5359) 2023-01-25 11:42:04 +05:30
Yuku Takahashi
5448e6d148
Enhance GraphQL plugin to be able to send custom headers (#5127) 2023-01-16 15:04:12 +05:30
Manish Kushare
55acd6c4d9
[ Bug fixed ] : select custom component styles not getting applied in query manager (#5128)
* bug fixed : select custom component styles not getting applied in query manager

* bug fix : not able to custom style select component

* fixed: Operation dropdown options are not fully visible.
2023-01-03 17:12:43 +05:30
Sherfin Shamsudeen
d6a72b50bd Merge develop to v2-beta 2022-12-27 20:10:33 +05:30
Akshay
602b1b4ad3
Feature: Tooljet Database (#4951)
* wip

* internal db per workspace

* fix async query

* feat: add storage layer route

* feat: add drawer component

* feat: add react-table to load data

* feat: add columns form

* feat: add create column form, create row form

* feat: add postgrest js

* add tooljet db controller to proxy requests to postgrest

* util: add postgrest filter builder helper utility

* feat: add filter popover

* use helper utility for building query

* add sortable filters

* add box shadow for filter popup

* use overlay trigger

* use react select

* add new column addition

* add dropdown for table header, table list

* Move filter.jsx

* feat: add sort popover

* feat: add postgrest js .order fn

* setup tooljetdb with restricted grants for users

* make db schemas added loaded dynamically on postgrest server

* fix query

* sign jwt token to auth user at postgrest

* update db schema user with workspace

* chore: add table listing

* update data and columns from api

* feat: add context api for sharing data

* add ability to create table, view tables and add columns

* use columns for sort from context api

* fix ormconfig

* feat: add table listing integration

* feat: add create table integration

* fix for rds deployment

* add internal table translation instead of schema

* remove tooljetdb as a datasource

* wrap placeholder on proxy query

* add active workspace guard

* scope tooljetdb by workspace

* update active workspace guard

* seperate proxy related concerns to different service

* make use of org id param

* rename storage layer to tooljet databse

* update specs

* feat: Update list when new table added

* feat: add create column

* chore: add orgId to url + misc changes

* chore: move popover to separate file

* remove unused var

* rename files

* feat: add multiple columns

* feat: add new row

* removes postgrest-js from pkg lock

* feat: add row data

* feat: add sorting

* feat: allow row deletion

* feat: add search

* feat: add filtering

* feat: add edit mode

* feat: add columns while edit table

* add view table action

* update setup for column constraint

* fix query

* integrate view_table, primary key field

* render toogle for boolean data type

* update view table query for primary key

* fetch metadata refactor

* add capability to set default values

* feat: allow deletion of record based on primary key

* feat: add default value while creating column

* send query from sort & filter component

* css changes

* allow empty data

* add requested changes

* add err message

* add common fn

* allow sort + filter

* remove unwanted defaults key

* css changes

* add more operators

* dark mode fixes

* add drawer footer

* add loader for list tables

* add dashboard design changes

* design changes

* add capability to drop table and delete column

* add breadcrumbs

* design changes

* add profile

* refactor tooljetdb controller

* update routes

* add empty page changes

* delete column fix

* fix delete column

* design changes

* fetch tables post delete

* homepage changes

* hide ellipsis on hover

* add org settings page

* add edit + create org

* add notification center

* fix: group permissions switch issue

* add logo

* remove anchor tag

* fix merge conflicts

* css changes

* add err boundary

* setup query editor

* css changes

* fix: merge conflicts

* add menuPortal prop to filterform and sort form

* fix seed

* fix: build

* design changes

* design changes + refactor code

* fix imports

* fix: drawer issue on delete table

* add search box changes

* fix: tablename max-length 255

* fix: set newly created table as selected item

* remove edit column option

* added badges to enterprise only features

* disable edit column

* table styles

* fix: popover position, placeholder default

* fix: display boolean values in table

* fix: tooljet database default type values

* css changes

* add query manager for tooljet db with create and list row

* dark mode fixes

* remove Header component

* add ability to delete tooljetdb rows from query manager

* add ability to update tooljetdb rows

* dark mode fixes

* css changes

* display actions icon on hover

* folder onclick change

* add empty page styles

* fix proxy requests

* feat: randomize icon creation

* add max items per page prop for pagination

* removes unwanted position attr

* add table name validation + disable submit btn while api fetch

* [Bugfix] internal storage toast  | trigger toasts for running preview db queries (#5019)

* resolves: no toasts are fired when preview query is run for db queries

* fire success toast for created and no content status text for query success

* remove invalid migration

* skip migration if tooljet db already created

* fix: app clone icon param

* fix: show confirmation box if filter options are empty in query (#5021)

* for now: show native confirmation box of the brower to confirm the delete all query

* typo

* Revert "typo"

This reverts commit b5ce5ed889.

* cleaned

* cleaned

* show confirmation box if filter options are empty in query

* [Refactor/Bugfix] database query (#5028)

* refactored list rows operations

* remove unwanted cls

* refactor create row

* reafactored update rows

* refactored delete rows

* padding fix for tj-query

* add static templates

* review changes

* remove unused file

* Chore: tooljetdb render setup (#5033)

* add postgrest for render preview deploy

* pin version

* add healthCheckPath

* remove health check

* handle database url parsing db params

* add defaults for tooljetdb env

* fix hostname

* handle env in migration files

* refactor dbconfig build

* fix pg db usage

* add parsed env context

* add tooljetdb env

* refactor db config utils

Co-authored-by: gandharv <gandharvkumargarg@gmail.com>
Co-authored-by: Shubhendra <withshubh@gmail.com>
Co-authored-by: Arpit <arpitnath42@gmail.com>
2022-12-23 02:09:57 +05:30
Manish Kushare
ba7e38b7d9
[ Enhancement ] : Query panel UI design (#4757)
* added colors variable in color.scss

* made left side bar of query panel width fixed to 249px and main container width to grow accoding to available width of query panel

* made UI updates in query container - left sidebar of query panel

* set query name font weight to 400

change the border color of left sidebar of query panel

added colors in colors.scss

commented unused variable

* UI update for header in the leftsidebar of the query panel

* updated width of the primary default secondary button

* Updated UI for query panel header

* draf : tranfomration UI update

* draft - preview section UI update

* draft : query manager advance options UI update

* draft : UI update for restApi query editor

* update

* femoved disable save button logic

* small updates

removing box shadow for rest api options button

adjusted spacing for data source selectionn div

* reverting changes in _ui/Search component

* bug fixed : Query Panel header spacing and alignment issues

dark theme update

* spacing and dark theme update in query container

* bug fixed : transition issue in tabs

* dark theme updates and bug fixes

* input checkbox update

* added cursor pointer to input checkbox

* updates

* updates

* bug fixed : removed typo error from last commit

* update

* added 3 rows in rest api tab content by default

* update spacing between datasource picker and element to render div

* spacing top for event manager section

* removed inline style from preview component

* data source lister font size update

* removed inline style from editor component and added style in css

* small updates

* applied color theme for dropdown options in the query manager

* added cursor pointer to control section of dropdown

* updated select data source section in query manager

* dynamic form bug fixed

* bug fixed : breadcrum

* bug fixed : toggle in GroupHeaders is not consistent with the dark theme

* bug fixed : clear icon in searchbox in query manager

* bug fixed : color in rest api in request url

* search box query manager final design

* small update

* made suggested changes

* query editor design for stripe query

* made changes in stripe

* updated the files with minor changes

* made minor updates in stripe

* set Get as default method in rest api

* add functionality to update query name from query panel header as well

* change the width of list data queries section

change size of icon to 20px

* updated changes

* created queryManager.scss file

* added default value to input text box in the query panel header

* bug fixed

* fixed minor bugs

* moved custom-toggle css in queryManager.scss

added on focus css for ternary button

* removed unsued lines from queryManager.jsx

* bug fixed: spacing in search box

* bug fixed: spacing in search box

* code enhancement as per changes requested

* fixed : search box component breaking inside DataSourceManager component

* made a function to style select component in query manager

* styles select component in rest api and transformation using common method

* chnaged run query on page load to application load
2022-12-20 18:38:51 +05:30
vjaris42
21177d1317
add: custom endpoint for s3 hosts (#4881) 2022-12-07 14:15:05 +05:30
Midhun Kumar E
138ad797d0
Added cypress test for data source PostgreSQL (#4602)
* Add data-cy

* Add basic spec

* Add basic method to create query

* Add data-cy for query section components

* Add common method for postgreSQL

* Update spec with methods

* Add data-cy for alert-box and query search elements

* Add method for widget integrations and event handler

* Add selector into selectorFile.

* Fix failing cases

* Add labels on Text file

* Fix failing specs due to rerendering

* Remove creds from spec
2022-11-11 11:15:12 +05:30
Arpit
74beb544fe
[Feature/plugin] Zendesk integration 🚀 (#3943)
* plugin:init

* zendesk svg icon

* zendesk integration 🚀

* clean up

* unit tests

* docs: zendesk

* resolves: error proof

* fix typos
2022-10-06 13:45:42 +05:30
Muhsin Shah C P
638fcf7223
[Feature] Now multiple users can login through RestAPI-Oauth 🚀 (#4052)
* Implemented multiple access token feature
- working on refresh token case

* worked on refresh token flow

* added multiple token ability to openapi plugin too
- fixed some bugs

* changed tokenData to token_data
- fixed some issues

* added user type with user id

* changed user type

* Rewrote some function
- added switch for enabling and disable multi auth
- fixed some bugs
- refactored the code

* fixed view app issue

* Fixed public app issue

* cleaning some code

* (public_app) add a check to avoid oauth login redirect when there is no access token

* reverted all changes of openapi (temporary)
- will add multi token functionality once done with restapi

* fixed a bug

* fixed a bug

* refactored some code

* changed the switch text

* pr changes

* changed token_data back to tokenData

* cleaning code

* removed token data from datasources query

* removed some lines

* added a comment
2022-09-19 20:27:37 +05:30
Navaneeth Pk
98bb7519dd
Reverse proxy using base tag (#3889)
* reverse proxy

* reverse proxy

* Fix for yjs

* Fix for ws

* Fixes org switching

* Fixes org creation

* Fixes login logo

* Fixes download icon

* Construct use invite URL from base URI

* Fixes apiUrl if sub path is set

* Remove commented code

* Fix profile link

* invitation url changes

* Fixes dev env

* Use url-join lib to connect urls for goto app and invitation link

* Use useHistory instead of helper to get history for template modal

* Review changes

Co-authored-by: Sherfin Shamsudeen <sherfin94@gmail.com>
Co-authored-by: gsmithun4 <gsmithun4@gmail.com>
2022-08-27 21:58:24 +05:30
Kiran Ashok
c49d752b5a
Fix for app breaking when deleting a datasource and then trying to add DynamoDB / Elastic search (#3195) 2022-06-06 06:58:04 +05:30
Muhsin Shah C P
66764d5511
Added custom headers for access token URL (#3078) 2022-05-19 18:42:44 +05:30
Muhsin Shah C P
dcee0885d6
Feature: OpenApi import plugin (#2728)
* Initialized OpenApi plugin

* Added definition field to manifest file

* Added an openapi parser

* Implemented JSON/YAML resolver
- Removed swagger parser lib
- Added a field for choosing definition format type
- Implemented a resolver for resolving $ref

* Implemented a basic operations drop down from spec paths

* Added params and body ui

* Now, can view general parameters and servers

* Added an option to override general params
- Resolved a bug

* Implemented basic openapi plugin
- Added got lib
- Tested basic queries

* Added one more method

* Resolved a common bug

* Working on Parsing definition from datasource modal
- Created new form component for openapi
- Populated select array from security array

* Added ui for authentication

* Added bearer & basic plugin code

* Resolved some ui issues of Apikeys auth option

* Added apikey auth

* Resolved an issue
- Also replaced validate btn with auto validation
- Now spec will be added to db from data-source modal

* Added error text to show validation error

* Now spec will load from props for query manager

* Added some padding to operation description

* Added ui for openapi oauth2 auth

* Implemented oauth2

* Fixed a state issue with a temporary hack

* Now we can show multiple same auth types

* added the icon

* Resolved a bug & improved multiple apikeys process

* Resolved some realtime parsing error

* Resolved a bug from options fn

* Resolved PR changes

* Updated documentation with brief details about the open API plugin

* Removed unwanted package

* Changed if-else to switch

* Code changes

* added setLoadingSpec fn to catch section

* Solved typos and error in doc

* Resolved dropdown issue

* Resolved a bug

* updated openapi icon
2022-04-26 14:14:12 +05:30
Muhsin Shah C P
b3ca2b64fd
Feature: added basic & bearer auth to Rest API (#2742)
* Added basic and bearer auth fields

* Implemented basic and bearer auth

* Changed token name

* Added encrpyted icon along side label

* resolved a basic-auth bug

* Refactored basic auth code
2022-04-22 13:01:08 +05:30
Arpit
e792e074f1
[Improvement] migrates to react-select: selection dropdown component (#2322)
* migrates to react-select: selection dropdown component

* styles fixes

* decomposing @ui/Select component into sub-components

* migrates Editor-Select component

* adds width to oauth selection dropdown

* updates datasource: oauth and authentication dropdowns (source component)

* Update frontend/src/_ui/Select/SelectComponent.jsx

Co-authored-by: Gandharv <gandharvkumargarg@gmail.com>

* resolves currentValue

* fixes scroll issue for dropdown options component

* updates queryManager react-select component

* updates rest api query to react-select

* adds options to render select menuwith portal

* adds: select menu render option for dynamic dropdowns and drodown-component-flip

* fixes: dropdown selection menu for restapi-oauth

* removes unused imports

Co-authored-by: Gandharv <gandharvkumargarg@gmail.com>
2022-04-11 17:27:07 +05:30
Muhsin Shah C P
81bed483f9
Feature: Added a field for custom query params (REST API OAuth setup) (#2605)
* Added custom query params to rest api oauth flow
- Also resolved a bug

* Refactoring code
2022-03-24 21:21:34 +05:30
Kiran Ashok
9732004fc6
app crash bugfix while adding same datasource (#2617) 2022-03-23 18:35:19 +05:30
Muhsin Shah C P
2cc788ab6c
Feature/plugin: n8n integration 🔥 (#2227)
* Integrated new n8n datasource [initial]

* Resolved some bugs

* Added a dropdown for auth type
- changed sensitive fields to encrypted
- Added basic & header auth

* Added changes
- Plugin icon
- Removed ecrypted option from username
- Chnaged some placeholder text and field names

* Changed datasource fields
- Removed host from datasource modal
- Added url field to operations
- Changed operation names

* Redesigned dynamic list

* changed error message

* Changed icon

* Added helpText to dropdown-flip component

* Cleaning code

* Cleaning code

* Added n8n documentation

* Edited hint text
2022-02-21 23:37:09 +05:30
Arpit
3a62ac9820
[improvement] Query panel redesign (#1947)
* query panel headers styles

* create query button style update

* create query button style update

* create query button style update: mixins

* querypanel header nav-links updated

* querypanel header buttons

* restapi: url hinter styles

* fixes querypane header width, undo prev styles applied

* querypanel header icons margin fix

* restapi: header tab

* restapi: params tab

* restapi: body tab

* base url style fixed

* added alert component to @/_ui

* adds margin top to query-panel tabs

* bumped font weight of preview

* on hover query style updated

* selected query style update and along with dark themed

* adds new searchbox component, added search queries

* fixes query panel query lists icons margin

* query selected hover bg

* back icon should not be render if callback is a function

* airtable: queries redesigned

* stripe: queries redesigned

* fixed query-pane header responsiveness

* fixes tab title typo

* undp/redo select datasource only when mode='create'

* removes comments

* refactor restapi url codehinter styles

* fixes white spaces in query pane and query pane header

* minor updates for restapi query options styles

* removes tool-tip for lens svg icon for search: query-pane header

* adds button loading spinner with primary color

* fixes hover bg color for queries

* update: query hover bg color to lighter tint

* update query list icons: trash and play svgs

* adds icons to the selection component

* fixes tabs alignments restapi

* fixes codehonter text margin: restapi url

* fixes advanced-options-container margintop

* new UI query: dynamodb

* new UI query: elasticsearch

* new UI query: firestore

* new UI query: mongodb

* new UI query: mysql

* new UI query: psql

* new UI query: typesenseapi

* new UI query: gsheet

* new UI query: sendgrid

* new UI query: twillio

* new UI query: gcs

* new UI query: minio

* new UI query: aws

* update query bg color and hover bg color

* fixes run query icon for dark theme

* fixes input query title text alignment

* update query header title

* adds search queries placeholder and add icon when search box is displayed

* updated No results query text

* undo/redo rest-api tabs: fixes whote spaces

* undo/redo: rest-api tabs conde hinter placeholder paddinleft

* adding new queries when search box component is mounted:fix

* fixes creating a new query after filtering queries

* fixes dark theme for select search components

* reverts query pane header search box with add icon

* fixes input left margin

* fixes bottom padding rest api tabs

* fixes toggle button:not selected in dark theme

* fixes typos

* fixes preview button spinner size

* undo/redo: query-trash-icon.svg for queries and trash.svg for components

* query icons badge bg update[options]

* icon badge fix

* move static styles to theme.scss

* restapi: url field height increment

* fixes query name when adding a new query with filtered querylist

* fixes alignment issues of the query header icon

* revert back to 32px code hinter height

* adds apdding to code mirror line

* updates to react-select

* remove component unmounts and mounts side effect
2022-02-02 22:29:57 +05:30
Gandharv
2f3b441c0a
Move plugins to root (#1728)
* feat: move plugins to root

* modify tsconfig

* add .gitignore

* delete old plugins file

* add parcel

* docker compose volume mount

* add gcs

* add typescript to plugins folder

* gcs to ts

* add dynamodb

* add elastic search

* add firestore

* add gsheets

* add graphql

* add mongodb

* mssql

* add mysql

* add postgresql

* add redis

* add s3

* add slack

* add stripe

* remove plugin related packages from pkgjson

* add lib folder

* add gitignore

* remove typescript generated files

* remove generated file

* remove generated files

* add twilio

* add dist to docker compose cache binding

* add dist prefix

* cleanup - 1

* delete dist

* rename to index.ts + add jest config

* add it.todo in tests

* test fixes

* test file changes

* fix type checks

* add @tooljet/plugins to server package json

* esm vs commonjs bug, reduce got to 11.8.2 from 12.0.0

* docker file npm package version fix

* add typesense

* cleaup - 2

* add sendgrid

* add lerna build and clean script for all packages + tsconfig

* cleanup -3

* add plugins build step

* add missing plugins build step in npm run build

* add mssql, mysql & postgres as singleton classes

* add db connection to cache only if datasourceId is available

* client: add data source schema/manifest files

* add query operations files

* logic for wrapping form with schema

* add script to create index file

* add @tooljet/plugins to frontend folder

* cleanup 1 -frontend

* cleanup - 2 // frontend // data queries

* add client and index to gitignore

* update gitignore

* fix lint & test

* update ci

* fix unit, e2e

* cleanup -3

* fix test

* fix tests

* fix indent

* try npm ci

* fix tests

* fix typo

* fix

* rename file for server entry

* heroku fix

* add main and types entry points in pkg json

* move common to root

* cleanup - 4: remove redundant $ sign prefix

* cleanup - 4: remove redundant $ sign prefix

* update options in-sync before DOM is painted

* change type cloud to cloud storage

* update readme

* update ci.yml

* update ci yml

* add pkg-lock.json

* rename index.ts to server.ts

* update lock files

* add server package.lock

* remove unused import

* revert commit: add minio

* add root dep

* import server.ts

* remove plugins build step

* add npm shrinkwrap

* update version - plugins

* add new version - 0.0.8

* upgrade version

* move to symlinked package

* add lock file

* feat: add icon inside package

* add plugin creation docs

* Remove seed

* move icons to plugins folder

* install pg dep

* add react to packages

* add seed cmd

* revert change

* add plugins build in lint, e2e, unit

* e2e, lint use npm ci

* update dockerfile for plugins

* try combining release with web

* limit memory on release

* try executing seed script post transpile

* try executing seed from server directory

* update seed execution

* add minio

* add correct type

* add minio to pkg json

* remove old file

* fix provider key

* add python installable + npm ^7.2.0 (#1752)

* add python installable + npm ^7.2.0

* add py to prod file

* pin npm version to 7.20.0

* pin npm version to 7.20.0

* split into multi stage build and remove python for buildx

* copy plugins from buider stage

* update dependencies

* add freetds dependency

* update server dockerfile

* update client dockerfile

* update dev dockerfile and compose file

* fix entrypoint

* fix server dev dockerfile

* update docker-compose

* remove npm install on root dir on docker build

* fix heroku script

* make lerna prod dependency to enable prod builds

* remove redundant env setup

Co-authored-by: Akshay Sasidharan <akshaysasidharan93@gmail.com>
Co-authored-by: navaneeth <navaneethpk@outlook.com>
2022-01-17 12:38:17 +05:30
Arpit
b4f7334b1f
Bugfix: Scrolling is broken for code editor on postgresql query manager (#1583)
* fixes: Scrolling is broken for code editor on postgresql query manager

* resolves comments
2021-12-25 08:51:19 +05:30
Arpit
b9754c4b6b
[Feature] popup modal for code hinter (#1465)
* portal for code hinter popup

* codehinter portal styles

* portal editor height

* update icons

* hinter changes

* refactoring to a separate dir

* code hinter - portal

* component details added in the portal header

* portal header: source name fixed

* portal header: inlcludes field name in the header

* display field names for rest api

* display field names for transformation

* handle for empty component names

* portal preview code bg

* foreUpdate

* foreUpdate

* refactored and using same codemirror component to render portal's editor

* clone codemirror to two different component

* fixed - need click to render the field data

* force update

* table component cell types: included

* chart component types: included

* alignment of the preview area

* btn color adapts to theme-fix

* remove console.logs

* disable portal editor for event manager

* scss unsued ruleset removed

* name fixes and remove unsued var

* .

* null check

* removed hardcode componentName

* app z-indexes: added z-index for suggestion-hints

* hook exhaustive-deps

* portal custom hook

* updated function name

* icon position fix

* hinter fails to open in certail scenarios: fixed
2021-12-10 08:39:23 +05:30
Gandharv
d398266991
fix toggle value (#1525) 2021-12-07 15:41:12 +05:30
Gandharv
7a8698645e
Add checked prop to toggle element (#1520)
* fix: add checked prop to toogle element

* add onChange value based on event.target.checked
2021-12-07 11:21:56 +05:30
Arpit
2b303c026b
[Feature] : Gsheet update operation (#1453)
* gsheet update op: schema and UI

* gsheet update op: server

* update operation for google sheet datsource api

* remove unsued comments

* backward compatiable: removed custom rule for sheet

* unsused consolelogs

* .

* Show gsheets update query body as a single-line codehinter

Co-authored-by: Sherfin Shamsudeen <sherfin94@gmail.com>
2021-12-02 12:25:40 +05:30
Gandharv
29b20ce1e8
fix rest api defaults (#1450) 2021-11-24 16:12:16 +05:30
Gandharv
b61d07e0c5
Refactor: move default options to schema files (#1425)
* refactor: move default options to schema files

* fix: use options instead of source.options

* add default empty object when defaults not present in schema

* add null checks for gsheets and slack component

* removes un-necessary console log

* delete constancts file

* delete default options file for data sources
2021-11-22 13:52:32 +05:30
Arpit
31e8752b65
code hinter height fixed for queryEditors - datasources (#1431) 2021-11-21 09:44:26 +05:30
Gandharv
1ddd170539
Add schema for data query editor (#1361)
* Initial commit for data query schema changes

* db: add mssql schema

* api: add graphql schema

* api: add redis data query editor

* db: add my sql db

* api: dataquery - add airtable api schema

* api: dataquery - add dynamodb api schema

* database: dataquery - add database api schema

* database: dataquery - add elastic search api schema

* database: dataquery - add mongo db schema

* database: dataquery - add postgre sql schema

* api: dataquery - add slack schema

* api: dataquery - add google sheets schema

* database: dataquery - add gcs schema

* fix: dynamodb styles

* fix: elastic search styles

* fix: firestore styles

* fix: remove line numbers + add className prop + add initialValue prop

* remove line numbers

* cleanup: remove jsx files of data queries

* cleanup: fix merge conflicts

* fix: on edit dropdowns not retaining value

* fix: remove unnecessary log statement
2021-11-17 23:29:00 +05:30
Gandharv
c8f3479432
add encrypted icon to firestore data source (#1272) 2021-10-25 14:46:46 +05:30
Arnav Puri
6c137306d8
Fixed #1049 Broken Toggle Button (#1061) 2021-10-15 07:40:08 +05:30
Arpit
26c9cc655c
Fix linting errors across the app (#785)
* eslint-setup: rules for frontend and server

* setup pre-commit:hook

* frontend:eslint fixes

* frontend eslint errors and warning fixed

* eslint:fix for ./server

* fix server/test: expectatin string lint/error

* pre-commit:updated

* removed unwanted install cmd from docker file

* recommended settings and extension for vscode

* husky prepare script added

* updated extension recommendations

* added prettier as recommended extension

* added pre-commit to package.json

* remove .prettierrc file

* resolve changes

* resolve changes
2021-09-21 19:18:28 +05:30
Gandharv
9d347ff38f
fix import camelcase of GoogleSheets 2021-09-15 13:10:11 +05:30
Gandharv
a07bc59a72
Feature: Add dynamic form for datasources (#676)
* feat: add dynamic form (airtable)

* feat: add schema for rest api

* feat: add schema for graphql

* feat: add schema for stripe

* feat: add schema for google sheets

* feat: add schema for slack

* fix: options from correct key

* fix: schema url

* rename headers to http-headers

* fix placeholder

* feat: add schema for dynamodb

* feat: add schema for redis, elastic search, firestore

* feat: add shema for mongodb, postgresql

* feat: add mysql schema

* fix: remove azure option

* feat: add dropdown component flip type

* feat: add mssql schema

* chore: delete previous components

* remove console log

* fix: database value set as port

* feat: add helptext prop to input

* remove unwanted class on toggle

* change placeholders

* change placeholder

* fix typo

* add ssl_enabled to schema
2021-09-15 08:20:55 +05:30