Commit graph

320 commits

Author SHA1 Message Date
gsmithun4
b13e30c880 Merge branch 'main' into release/v3.21.34-beta 2026-05-18 23:01:11 +05:30
Shaurya Sharma
8631b6d9c8
feat: QueryManager - add fx and custom message for query confirmation (#16320)
* feat: QueryManager - add fx and custom message for query confirmation

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* Minor fix

* Design update

* Yes button same size as cancel button

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-18 22:33:39 +05:30
Ganesh Kumar
23dfa559f7
TJDB join query snake case to camel case fix (#16408) 2026-05-18 22:16:31 +05:30
gsmithun4
5b48e4f71e Merge branch 'lts-3.16' into release/v3.21.30-beta 2026-05-09 01:36:54 +05:30
Shaurya Sharma
a4d36c7b58
feat: ModuleViewer - support padding toggle by passing styles to wrapper (#16302)
* feat: ModuleViewer - support padding toggle by passing styles to wrapper

* Minor fix
2026-05-07 12:27:15 +05:30
Midhun G S
90c199bdca
chore: update version to 3.21.29-beta and comment out migration query for BigQuery authentication type (#16278)
Some checks failed
CI / build (push) Has been cancelled
CI / lint-for-plugins (push) Has been cancelled
CI / lint-for-frontend (push) Has been cancelled
CI / lint-for-server (push) Has been cancelled
CI / unit-test (push) Has been cancelled
CI / e2e-test (push) Has been cancelled
2026-05-03 18:38:01 +05:30
gsmithun4
b0ac5172d3 feat: add migration to backfill authentication_type for BigQuery datasources 2026-05-01 22:18:19 +05:30
gsmithun4
158e31a037 refactor: remove obsolete BigQuery migration script 2026-05-01 22:18:07 +05:30
gsmithun4
b3218d434c Merge branch 'main' into release/v3.21.28-beta 2026-05-01 20:48:41 +05:30
gsmithun4
74f60a343f Merge branch 'lts-3.16' into release/v3.21.28-beta 2026-05-01 20:38:33 +05:30
Muhsin Shah C P
3cf30f8395
Fix: Module migration single-target seed with origin restore (#16274)
* fix: update migration to seed module versions only on the push-modules branch

* fix: drop module origin branch staging table after processing all organizations
2026-05-01 16:33:32 +05:30
Shaurya Sharma
813a3bf7e4
Added max limit to multiselectV2 (#16250)
Co-authored-by: johnsoncherian <johnsonc.dev@gmail.com>
2026-04-30 20:48:48 +05:30
Ganesh Kumar
df5da1b925
Hotfix: Update primary key column variable names for PostgreSQL and MySQL (#16072)
* migration for Postgresql and MySQL primary key column variable name update

* Batch size updated
2026-04-29 20:41:05 +05:30
Rudhra Deep Biswas
0c9921a92e
Merge pull request #16035 from ToolJet/fix/bigquery-oauth
BigQuery Improvements
2026-04-29 20:38:51 +05:30
Muhsin Shah C P
a30110a97a
chore: remove obsolete migration files and clean up module version handling (#16246) 2026-04-29 17:48:36 +05:30
Shaurya Sharma
67b725fd49
Migration for collapseOnHide toggle (#16196)
* Added CollapseOnHide to Image component

* Added collapseOnHide migration for rest of components
2026-04-29 16:19:40 +05:30
Vijaykant Yadav
046c5556eb Merge remote-tracking branch 'origin/main' into feaure/modules-branching 2026-04-29 14:10:35 +05:30
Muhsin Shah C P
4e8c6ada30
Change module version name to module_reference_id (#16216)
* feat: introduce module_reference_id for stable versioning across environments

* fix: update versionId assignment to use module_reference_id for consistency

* feat: update module version handling to use module_reference_id for stable versioning

* feat: enhance module definition caching for improved content refresh on version switch

* feat: enhance module version handling to differentiate between DRAFT and user-pinned versions

* feat: update moduleReferenceId handling to ensure UUIDs are assigned only for module-type apps

* feat: add moduleReferenceId generation using UUID for module-only migrations

* feat: refactor module version cloning to use UUID for module_reference_id and enhance app version handling

* feat: enhance module export logic to handle branch-local versions and prevent name collisions

* feat: lock source version during cloning to ensure stable app version selection across iterations
2026-04-29 10:34:06 +05:30
Vijaykant Yadav
045169fc9f feat: add migration to remove app_version_id from data_source_versions 2026-04-28 16:28:19 +05:30
johnsoncherian
867836be33 Merge branch 'lts-3.16' into chore/merge-3.20.150-lts-main 2026-04-28 16:11:33 +05:30
Shaurya Sharma
b79c7e2254
Dynamic height (#15993)
Some checks are pending
CI / build (push) Waiting to run
CI / lint-for-plugins (push) Blocked by required conditions
CI / lint-for-frontend (push) Blocked by required conditions
CI / lint-for-server (push) Blocked by required conditions
CI / unit-test (push) Blocked by required conditions
CI / e2e-test (push) Blocked by required conditions
* Dynamic height revamp

* Redundant code cleanup

* Minor fix

* Add collapse on hide toggle to button component

* Fixed table collapse on hidden toggle missing

* Fixed listview min height issue

* Listview footer not at the bottom when dynamic height enabled fix

* Extra padding removed from textarea

* Fixed CollapseOnHide missing for KeyValuePair, CodeEditor, Richtextarea

* Fixed container height not getting properly calculated when a component with alignment set to top is present

* Accordian causing overlap fix

* Fix for container based components not recomputing height when invisible by default

* Toggling dynamic height toggle using fx fix

* Backfill CollapseOnHidden

* Minor listview fix
2026-04-23 20:23:42 +05:30
Akshay Sasidharan
52a7766a0c Merge remote-tracking branch 'origin/main' into feaure/modules-branching
# Conflicts:
#	frontend/ee
#	server/ee
2026-04-21 16:39:29 +05:30
Vijaykant Yadav
4689fa2be9 refactor: streamline code formatting and error logging in SeedPushModulesBranch migration 2026-04-21 03:49:56 +05:30
Vijaykant Yadav
523fad59fc feat: backfill creationMode for legacy modules and seed DRAFT versions on non-default branches 2026-04-21 03:49:02 +05:30
gsmithun4
bd9ff40e3b Merge branch 'main' into rebase/lts-main-16-mgs 2026-04-20 22:41:23 +05:30
Pratush
ed7792a0af feat: add data migration to seed push-modules branch for existing modules 2026-04-20 22:11:03 +05:30
Muhsin Shah C P
61df02f459
feat: add migration to backfill co_relation_id for data_sources (#16008) 2026-04-20 21:49:01 +05:30
Vijaykant Yadav
0b54ec5ebe feat: implement module branching support across various components and services 2026-04-20 08:44:37 +05:30
Akshay
0b8883ce34
Feature: Version control for modules [BETA] (#15857)
* feat: enable version management panel for modules

Move VersionManagerDropdown and RightTopHeaderButtons outside the
isModuleEditor gate so module builders get the same version management
UI as apps — create drafts, save versions, promote, edit details,
and delete. BranchDropdown stays gated (git sync is Phase 2).

Refs: ToolJet/tj-ee#4925

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule for module version pinning

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — version dropdown design fix

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — compact dropdown styling

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat: prevent deletion of module versions pinned by consuming apps

Query all ModuleViewer components to check if any app references the
target version via moduleVersionId. If in use, reject deletion with
a list of consuming app names.

Refs: ToolJet/tj-ee#4927

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — version selection fix

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat: enable runtime resolution for pinned module versions

When a module component has a pinned versionId, use the version-specific
API (appVersionService.getAppVersionData) to load that version's definition
instead of always loading the module's current/latest version.

Also add versionId to useEffect deps so the module re-fetches when the
user changes the pinned version in the dropdown.

Refs: ToolJet/tj-ee#4926

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: address review findings — scoped deletion query, error handling

- Replace full table scan in checkModuleVersionInUse with scoped SQL
  query using JSON extraction (properties::jsonb -> 'moduleVersionId')
  instead of loading all ModuleViewer components into memory
- Add try-catch with user-friendly error message
- Update frontend/ee submodule with error logging and DRAFT fallback fixes

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: module deletion guard, import version mapping, and error display

- Prevent deletion of modules referenced by consuming apps (checks
  ModuleViewer components by moduleAppId)
- Fix import version ID remapping: map ALL version IDs instead of only
  editingVersion, and match existing module versions by name
- Fix showViewerNavigation defaulting to true on import (|| → ??)
- Show actual API error message in delete toast instead of generic text
- Clean up error messages: remove em-dash, use multiline format

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: hide Configure Git button in module builder

Git sync for modules is Phase 2. Hide the LifecycleCTAButton when
in module editor context.

Refs: #15857

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: hide freeze banner in module builder to prevent canvas shift

The AppCanvasBanner renders a FreezeVersionInfo banner when a version
is saved (frozen). In the module builder, this banner pushed the canvas
down. Since git sync banners are not applicable to modules (Phase 2),
skip rendering entirely for module editors.

Refs: #15857

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — version dropdown loading state

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — canvas padding fix

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: remove hardcoded 'development' environment for modules

Modules now support environments, so remove the special case that
hardcoded the development environment for module viewer mode. Use
the same appEnvironmentService.getEnvironment call as apps.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: freeze editor for promoted module versions

Remove the blanket `if (isModuleEditor) return false` from
getShouldFreeze(). Modules now have environments, so promoted/saved
versions should freeze the editor and query panel just like apps.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — version lock banner for modules

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — latest version pre-selection

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — robust latest version sort

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat: release gate blocks app release with unreleased modules

Check all ModuleViewer components in the app version being released.
If any pinned module version is not RELEASED, block with error listing
the unreleased modules.

Also updates frontend/ee submodule with env check and status badges.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — debugger integration for env mismatch

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat: block app promotion when pinned modules not in target env

Add promote gate in promoteVersion() that checks all ModuleViewer
components. If any pinned module version hasn't been promoted to the
target environment, block with error listing the modules.

Also updates frontend/ee: simplified dropdown badges, removed
env mismatch placeholder (now prevented by this backend gate).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: show actual API error in release and promote toasts

Release button was showing "Oops, something went wrong" and promote
button was showing a generic retry message. Now both show the actual
backend error (e.g., module not released/promoted). Release errors
are also pushed to the app debugger.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: use raw table names in release and promote gate queries

TypeORM innerJoin with entity classes generates incorrect SQL when
join conditions use ::text casts. Switch to raw table/column names
(app_versions, apps, app_environments) instead of entity references.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: use lowercase aliases and correct enum in gate queries

- Use snake_case aliases (mod_ver, mod_app, mod_env) to avoid
  PostgreSQL case-sensitivity issues with camelCase aliases
- Check for DRAFT status instead of RELEASED (RELEASED doesn't
  exist in the DB version_status_enum)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: release gate checks current_version_id, errors in debugger

- Release gate now checks if pinned module version matches the
  module's current_version_id (actual release mechanism), not just
  DRAFT status
- Promote gate uses APP_TYPES.FRONT_END constant instead of raw string
- Both release and promote errors now show actual API message in toast
  AND push to the app debugger
- Fixed inline ReleaseVersionButton (version panel) error handler

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: debugger log format and version dropdown design language

- Use type 'component' with description field for debugger logs
  so the error message is visible in the debugger panel
- Update frontend/ee submodule: status dots in dropdown, draft
  modules visible in component panel

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update server/ee submodule — promote gate in EE override

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* refactor: move module guards from CE to EE only

Module-specific guards (deletion, release, promote) belong in EE
since modules are an EE-only feature. CE users who downgrade would
be blocked by stale module references they can't fix.

- Removed module deletion guard from CE apps/service.ts
- Removed release gate from CE apps/service.ts
- Removed dead promote gate from CE versions/service.ts
- All three guards now live in EE overrides only

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: format module names on separate lines in error messages

Each module name now appears on its own line in error toasts for
deletion, release, and promote gates.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update frontend/ee submodule — Released badge in version dropdown

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update server/ee submodule — newline formatting in error messages

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: code review findings + design feedback

Review fixes:
- Guard checkModuleVersionInUse with app.type === 'module' to skip
  unnecessary JSONB queries for non-module version deletions
- Exclude self-references in EE deletion guard
- Add DISTINCT to release gate query
- LEFT JOIN on environments in promote gate to catch NULL env IDs

Design feedback (Nechal):
- Remove status dots from version dropdown (clutter in small dropdown)
- Badge hugs the version name with tighter gap

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: code review fixes + module version audit log keys

PR review fixes:
- Move hooks above early return in LifecycleCTAButton (Rules of Hooks)
- Move UI state cleanup before debugger.log in error handlers
- Add missing setShowConfirmation(false) in modules ReleaseVersionButton
- Add fallback mapping for unmatched version IDs on module import
- Add Logger for checkModuleVersionInUse error logging

Audit log event names for module versioning:
- Add MODULE_VERSION_AUDIT_KEYS constants (CREATE/DELETE/SAVE/PROMOTE/RELEASE)
- Interceptor prefers service-set actionType over feature config
- Version/app services set module-specific audit keys when app.type === 'module'
- Add auditLogsKey for module CRUD features (MODULE_CREATE/DELETE/UPDATE)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: revert unrelated review changes + move audit keys to modules

- Revert LifecycleCTAButton hooks reorder (unrelated to this PR)
- Revert ReleaseVersionButton/PromoteConfirmationModal try-catch wrappers
- Move MODULE_VERSION_AUDIT_KEYS from versions/constants to modules/constants

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update server/ee submodule pointer

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: skip git sync freeze for modules in version service

Modules are common across all branches — git sync freeze does not apply.
Adds app.type !== 'module' guard in CE prepareResponse.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: scalable error copy for module dependency gates

Frontend catch handlers now extract structured errors — toast shows
generic message, debugger description shows full module list.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: read structured error fields correctly in catch handlers

Read rawError.error (not rawError.message) to match the { error, details }
shape from BadRequestException({ message: { error, details } }).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update server/ee submodule — error copy polish

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update server/ee submodule — freeze module after version save

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* chore: update server/ee submodule — widen module freeze check

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: module environment derivation, version switch crash, and delete toast

- Derive module environment from parent app's store instead of static
  moduleEnvironmentId property. Ensures constants/secrets/queries
  resolve from the correct environment per the compatibility matrix.

- Remove moduleEnvironmentId from all write/read/import-export paths.
  Existing DB values are inert and harmless.

- Add key={moduleVersionId} to <Viewer> to force clean re-mount on
  version switch, preventing stale state crash (empty canvas).

- Add stale-request cancellation guard in useAppData to prevent
  unmounted component's async callback from overwriting new state.

- Fix delete-version toast: "Cannot delete only version of module"
  instead of "app" when deleting the last module version.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat: block app version save when using draft module versions

Saving an app version is now blocked if any ModuleViewer components
reference draft module versions. The draft module is still editable,
so saving the app would break the contract that saved = immutable.

- Added checkDraftModulesInApp() in CE util.service.ts (mirrors
  checkModuleVersionInUse pattern)
- Called from update() before DRAFT→PUBLISHED status transition
- Structured error format: toast shows message, debugger shows
  full module list
- Module saving itself is unaffected (guard checks app.type)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: make checkDraftModulesInApp public (TS2445)

Called from VersionService.update() which is outside the class.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat: data migration to promote and release existing module versions

Modules now inherit the parent app's environment for constants and
data sources. Existing modules had current_environment_id pointing
to Development, which would break apps viewing them in Staging or
Production.

This migration promotes the latest version of each module to the
production environment and sets it as released - mirroring the
workflow versioning migration pattern.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: modules in public apps - cache-first load + constantsResp guard

Public app viewers are unauthenticated, so module data fetches via
getAppVersionData (JwtAuthGuard) fail with 401. Two fixes:

1. Try getModuleDefinition() cache before API call. Parent app's
   public response includes module definitions, so the cache hit
   avoids the authenticated endpoint entirely.

2. Guard constantsResp against undefined. When the environment
   fetch fails (401 for public apps), constantsResp was undefined
   causing a TypeError crash on extractEnvironmentConstantsFromConstantsList.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: restrict cache-first module loading to public access only

Cache-first was overly broad - could serve stale definitions in
authenticated editor previews. Now gated on isPublicAccess so
version-pinned API calls are preserved for authenticated flows.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: modules with data queries crash in public/released apps

Two issues (ported from PR #15874):

1. Deep-clone cached module definitions before resolving. Zustand/Immer
   returns frozen objects, but normalizeQueryTransformationOptions
   mutates query options in-place causing TypeError on frozen objects.
   Only manifests when modules have data queries.

2. Add id field to CE getBySlug module response. setModuleDefinition
   stores by module.id - without it, getModuleDefinition(appId) cannot
   find the cached definition. EE already had this (line 694).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: allow module query execution in public apps

QueryAuthGuard.findByDataQuery returns the MODULE app (query owner),
not the parent app. Modules aren't marked is_public, so the guard
rejected unauthenticated requests with "Authentication is required."

Added isModuleInPublicApp() check: when the query's owning app is a
module and not public itself, check if it's used in the released
version of any public app. Only checks current_version_id (released)
to prevent unauthorized access via unpublished app versions.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Revert "fix: allow module query execution in public apps"

This reverts commit 7917eba47b.

* fix: modules should not inherit git branching locked state

- Backend: skip git sync freeze for modules in CE getOne, add
  version-status freeze for non-draft module versions
- Frontend: make getShouldFreeze accept and use isModuleEditor param
  (was silently ignored, affecting 20+ UI disable points)

* chore: update submodule pointers

* fix: getShouldFreeze module bypass must check version status not just released

The previous module bypass only checked isVersionReleased, missing
PUBLISHED (saved/promoted) versions. Check selectedVersion.status
directly since isEditorFreezed is shared state contaminated by the
parent app's git sync freeze.

* fix: handle nullable version status in module freeze check

Status column is nullable — null/undefined should be treated as DRAFT
(editable), not frozen. Use AppVersionStatus enum in CE backend.

* chore: update submodule pointers

* chore: update submodule pointers

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-17 23:49:51 +05:30
Devanshu Rastogi
09339fd1b1
Chore: Add migration to backfill Table component properties (#15982)
* feat: add migration to backfill refresh button and expandable rows properties for Table components

* Implemented a new migration to set default values for showRefreshButton, enableExpandableRows, and expansionHeight in Table components.
* Added logging for migration progress and success.
* Included functionality to delete app history for structural migrations if updates occur.

* chore: remove obsolete migration for backfilling showRefreshButton property in Table components

* Deleted the migration file that backfilled the showRefreshButton property, as it is no longer needed.
* This cleanup helps maintain the codebase by removing unused files.
2026-04-17 20:03:00 +05:30
Manish Kushare
7a89531e18
feat: add refresh button functionality to table components (#15912)
* feat: add refresh button functionality to table components

* fix: update refresh button icon from IconRefresh to IconReload

* Made the showRefershButton to false by default

* supported support for data queries as well other than raw json

* Used dependency graph to check the query reference

* Added migration for show refresh button to support backward compatibility

* fix: update loading state handling to include refresh status in Table and Header components

* enhanceed migration to backfill showRefreshButton property for Table components
2026-04-17 18:53:00 +05:30
Shantanu Mane
d91137edb3
feat: Workspace Env Config (#15593)
* feat: add environment configuration support for Git providers and enhance git sync functionality

* feat: update Git environment constants and integrate OrganizationGitSyncRepository

* feat: add testProviderConnection method to gitSyncService for testing Git provider connections

* chore: remove scanning on module init

* feat: integrate OrganizationEnvRegistryService and reload envConfig on workspace create and slug update

* feat: eload env config on onboarding

* feat: add testProviderConnection method and update LicenseBase for envGitMapping

* fix: handle downgrade path for env registry

* fix flaky case in granular access

* uncommented changes

* feat: update .gitignore to include additional environment files

* feat: refactor organization environment handling and remove deprecated service

* feat: implement Git environment registry service and refactor organization environment handling

* feat: rename envGitMapping to workspaceEnv across licensing module

* chore: remove unnecessary try-catch

* refactor(org-env): update interfaces — remove callback contract, add ensureResolved

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* feat: remove reload-on-org-event, swap bootstrap init order

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* feat(org-env): add getResolvedOrganizationIds() to interface, CE stub, and test

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* test: improve assertions in getResolvedOrganizationIds() test

* feat: refactor GitEnvRegistryService import paths and add new service implementation

* feat: add applyLicenseToResolvedOrgs method to IGitEnvRegistryService and GitEnvRegistryService

* refactor: replace GitEnvRegistryService with GitSyncEnvUtilService and update related references

* feat: add use_env_config column to organization_git_sync and remove env_git_provider column

* refactor: remove EncryptionModule import and update OrganizationEnvModule imports

* feat: introduce OrganizationEnvUtilService and update OrganizationEnvModule to utilize it

---------

Co-authored-by: Yukti Goyal <yuktigoyal02@gmail.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-13 23:14:46 +05:30
Midhun G S
0db8eb4e99
Merge pull request #15877 from ToolJet/rebase/lts-main-14-mgs
Merge LTS to main
2026-04-13 12:26:18 +05:30
vjaris42
3f82415386
fix: update unique index creation for default data source names (#15885) 2026-04-10 16:33:24 +05:30
Pratush Sinha
fbc8506949
fix: enforce unique data source names at org level (#15866)
* fix: enforce unique data source names at org level

* fix: remove unique index creation and drop logic for data sources

* fix: enforce unique data source names for active versions and add version-specific index

* fix: update unique index for default data source names to exclude organization ID

* fix: remove conflict logging for unique data source name indexes

---------

Co-authored-by: Pratush <pratush@Pratushs-MBP.lan>
Co-authored-by: gsmithun4 <gsmithun4@gmail.com>
2026-04-09 23:30:35 +05:30
gsmithun4
d0f4d619b4 Merge branch 'main' into rebase/lts-main-14-mgs 2026-04-09 21:07:43 +05:30
johnsoncherian
d6c10efb84 Merge branch 'lts-3.16' into release/appbuilder-s25.3 2026-04-06 12:56:03 +05:30
Siddharthpl
1015e11d42 Created new migration 2026-04-06 12:31:02 +05:30
Siddharthpl
6d504c6aea Remove the mssql auth migration 2026-04-06 12:21:18 +05:30
gsmithun4
7216934136 Merge branch 'main' into rebase/lts-main-13-mgs 2026-04-02 22:49:55 +05:30
Avinash
a7771b76b0
Feat/selfhost ai (#15730)
* Feature: add self-host AI support in licensing module

* chore: update submodule commits for frontend and server

* Feature: add self-host AI check in LicenseBase class

* chore: update submodule commit for server

* Feature: add AITripleSparkles icon and update icon switch case

* chore: update submodule commit for frontend

* Feature: add BYOK support in LicenseBase and related modules

* Feature: add updateKey function to aiService and new route for LLM key in breadcrumbs

* Feature: add getKeySettings function to aiService and update service exports

* chore: update submodule commits for frontend and server

* Feature: add LLM_KEY_ENV_CONFIGURED to INSTANCE_SYSTEM_SETTINGS and create migration for its initial value

* chore: update submodule commits for frontend and server

* chore: update submodule commits for frontend and server

* chore: update submodule commit for frontend

* refactor: replace selfhostAI and byok with aiPlan in LicenseBase and related files

* chore: update submodule commits for frontend and server

* chore: update submodule commits for frontend and server
refactor: enhance error handling in sendMessage function

* refactor: adjust formatting in generatePayloadForLimits function for consistency

* feat: add EncryptionModule registration and LLM_API_KEY enum to instance settings

* chore: update submodule commits for frontend and server

* feat: implement handleAITextResponse for improved API response handling and update aiPlan logic in LicenseBase

* chore: update submodule commits for frontend and server

* chore: update submodule commits for frontend and server

* chore: update submodule commit for server

* feat: update aiPlan logic to include selfhostai and byok options

* chore: update submodule commit for server

* chore: mark subproject commits as dirty for frontend and server

* feat: simplify AI plan check in LicenseBase class

* feat: add update and get key settings features to AI ability

* feat: implement organization AI key management with rotation and migration

* chore: update submodule commit for server

* chore: update subproject commit for server

* chore: update subproject commit for server

* chore: update subproject commit for server

* chore: update subproject commits for frontend and server

* chore: update subproject commit for frontend

* chore: update subproject commit reference in server/ee

* chore: update subproject commit reference in frontend/ee

---------

Co-authored-by: Kartik Gupta <gupta.kartik18kg@gmail.com>
2026-04-02 22:26:30 +05:30
Siddharth Pundir
668807c2c9
Mssql entra auth implementation (#15760)
* Mssql entra auth implementation

* migration for sql auth type

* Update index.ts

* automation fix

* Undoing the change

* fixed mssql authdropdown (#15811)

---------

Co-authored-by: Srimaniteja <mani@tooljet.com>
2026-04-02 21:05:27 +05:30
rahulprasad00
a37424564e
Added Loading State for ListView Component (#15681)
* Added the loading state in the Listview

* Added the migration and import-export

* Migrated Visiblility, Disable to Properties and Removed Box Shadow and tooltip out of General

* feat(migration): add backfill migration for loading state in Listview components

---------

Co-authored-by: kavinvenkatachalam <kavin.saratha@gmail.com>
Co-authored-by: Kavin Venkatachalam <50441969+kavinvenkatachalam@users.noreply.github.com>
2026-04-02 13:25:22 +05:30
Devanshu Rastogi
b0ede5fb45
Feat: Color Picker 2.0 (#15690)
* Revamp component inspector for Color picker to support new properties and styles

* Fix: Mandatory property not working on component drop

* Update default placeholder value

* Revamp ColorPicker component

* Fix: Renamed class to avoid conflicts

* Add base layer for opacity in preview box

* Implemented migrations

* Update submodule reference

* Update server/src/modules/apps/services/widget-config/colorPicker.js

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update frontend/src/AppBuilder/WidgetManager/widgets/colorPicker.js

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fixes

* Update submodule reference

* Update submodule references

* Fix: Remove width type field from label styles since only 'of the component' supported for new components

* Fix: Placeholder overflows when label width is large and height of hue bar breaks when alpha is turned off

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-04-02 12:38:07 +05:30
gsmithun4
8324ba0f24 Merge branch 'main' into rebase/lts-main-12-mgs 2026-03-30 22:14:10 +05:30
johnsoncherian
cbf869e0e4 Merge branch 'lts-3.16' into release/appbuilder-s25.2 2026-03-30 11:45:28 +05:30
vjaris42
58ba6b8563
Enable Git Sync for Datasources, constants and dashboard (#15434)
* feat: Folder permission system

* fix(group-permissions): resolve custom group validation, folder edit check, and UI inconsistencie

* edit folder container && no folder in custom resource

* fix the ui for custom in empty state

* fix: coercion logic for folder permissions

* feat: enhance folder permissions handling in app components

* feat: add folder granular permissions handling in user apps permissions

* feat: implement granular folder permissions in ability guard and service

* feat: improve error handling for folder permissions with specific messages

* feat: enhance EnvironmentSelect component to handle disabled state and improve display logic

* chore: bump ee submodules

* add basic framework to support platform git

* feat: Update permission prop to isEditable in BaseManageGranularAccess component

* chore: bump ee server submodule

* fix: refine folder visibility logic based on user permissions

* feat: enhance MultiValue rendering and styling for "All environments" option

* fix:Uniqueness-of-data-source

* revert folder changes

* fix folder imports

* feat: allow app lazy loading

feat: import all apps of branches

* feat: implement folder ownership checks and enhance app permissions handling

* fix:ui changes

* feat: update WorkspaceGitSyncModal UI

* feat: enhance folder permissions handling for app ownership and actions

* chore: clarify folder creation and deletion permissions in workspace context

* fix: pull commit button & swtich branch visibility

* feat: import app from git repo

* fix: freezed state

* remove reference of activebranchId

* fix linting

* fix: update folder permission labels

* fixed folder permission cases

* fixed css class issue

* fix: datasource UI

* minor fix

* feat: streamline folder permissions handling by removing redundant checks and simplifying access logic

* refactor: made error message consistent

* fix:ui changes and PR fetching on master

* fix: datasource and snapshot creation

* fix: app rendering and stub loading

* fix: add missing permission message for folder deletion action

* refactor: consolidate forbidden messages for folder actions and maintain consistency

* fix: allow pull into current branch

* fix renaming of tags and reload on branch switch

* fix: allow branches import from git

* fix:push or tab removed

* feat: streamline permission handling and improve app visibility logic

* fix: remove default access denial message in AbilityGuard

* fixed all user page functionality falky case

* feat: add workspace-level PR fetch endpoint (returns all repo PRs without app filtering)

* fix: remove app_branch_table

* Fixed profile flaky case

* fixed granular access flaky case

* fix: allow branch creation from tags

* fix: update default branch creation logic to use provider config

* fix: dso and dsv operations on codebase

* fix: constants reloading and refetch org git details on data

* uniquness per branch

* removed comment

* fix: update app version handling and add is_stub column for branch-level tracking

* fix workspace branch backfilling for scoped branches

* added unique constraint - migration

* fix: update app version unique constraint to include branchId for branch-aware handling

* fix: update subproject commit reference in server/ee

* chore: revert package-lock.json

* chore: revert frontend/package-lock.json to main

* removed banner and changed migration

* minor fix

* fix: remove unused import and handle UUID parse error gracefully in AppsUtilService

* fix: update app stub checks to safely access app_versions

* refactor: revert folder operations

* fix: removed branch id logic

* fix: ds migration

* fix encrypted diff logic

* fix: update openCreateAppModal to handle workspace branch lock

* fix: subscriber filtering, freeze priority, meta hash optimization, and co_relation_id backfill

* feat: add script to generate app metadata from app.json files

* fix: meta script

fix: backfilling of co-realtion-ids

* refactor: streamline parameter formatting in workspace git sync adapter methods

* Improves data source handling for workspace git sync

Fixes workspace git sync to properly recognize data sources across branches by improving correlation ID handling and branch-aware data source version creation.

Uses strict equality comparison in deep equal utility to prevent type coercion issues.

Excludes credential_id from data source comparison to prevent unnecessary save button states.

Removes is_active filter from branch data source queries to include all versions for proper synchronization.

* refactor: update branch switching logic and improve error handling for data source creation

* fix: migration order

* 🚀 chore: update submodules to latest main after auto-merge (#15628)

Co-authored-by: gsmithun4 <3417097+gsmithun4@users.noreply.github.com>

* chore: update version to 3.21.8-beta across all components

* fix:import app from device

* fix:ui Edit&launch,folderCopy,branching dropdown in apps and ds

* fix:encrypted helper text on master

* fix: import from git flow

* logs cleanup

* fix:migration-datasource-uniqueness

* fix: app on pull

* chore: update server submodule hash

* fix: corelation-id generation and version naming

* fix: last versions deletion error

fix: no multiple version creation

* fix:ui and toast

* chore: update server submodule hash

* feat: add branch handling for app availability and improve error handling

* fix: update encrypted value handling in DynamicForm and improve workspace constant validation logic

* fix: improve formatting of help text in DynamicForm and enhance error message for adding constants on master branch

* fix: correct version creation and pull in default branch

* chore: update server submodule hash

fix: remove logs from other PR

* fix:data source uniquness at workspace level

* fix: update header component logic for path validation and improve version import handling

* chore: update server submodule to latest commit

* fixed folder modal changes

* fix:failed to create a query error inside apps

* feat: add branchId support for data source versioning in app import/export service

* fix: push & pull of tags and versions

* fix: update subproject commit reference in server/ee

* fix:removed gitSync logic from module rename

* fix:removed switchbranch modal & allowed renaming from masted module&workflow creation

* chore: Update server submodule hash

* fix: change stub button to edit

* refactor/git-sync-remove-modules-workflows

* fix:version name for module and workflo
w

* fix:templet app creation

* fix: add author details for branch

---------

Co-authored-by: gsmithun4 <gsmithun4@gmail.com>
Co-authored-by: Pratush <pratush@Pratushs-MBP.lan>
Co-authored-by: Shantanu Mane <maneshantanu.20@gmail.com>
Co-authored-by: parthy007 <parthadhikari1812@gmail.com>
Co-authored-by: Yukti Goyal <yuktigoyal02@gmail.com>
Co-authored-by: Muhsin Shah <muhsinshah21@gmail.com>
Co-authored-by: Adish M <44204658+adishM98@users.noreply.github.com>
Co-authored-by: gsmithun4 <3417097+gsmithun4@users.noreply.github.com>
Co-authored-by: Parth <108089718+parthy007@users.noreply.github.com>
2026-03-27 23:23:23 +05:30
gsmithun4
9e26b6b759 Merge branch 'main' into rebase/lts-main-11-mgs 2026-03-27 20:36:12 +05:30
Rudhra Deep Biswas
64c5120e6a
App Promote/Release Fix Migration (#15720)
* App Promote/Release Fix

* remove log

* improve set app migration
2026-03-27 20:28:53 +05:30
Kavin Venkatachalam
2a7b1a8272
Perf: Optimizes component backfill migration (#15713)
* Added Hover Background option for button, button group, modal trigger btn, popover menu button

* Added FontSize style property to Button, Button group, Popover menu, Modal Trigger btn. Adjusted line height and icon size accordingly

* Added FontWeight to Button, Button Group, Popover Menu, Modal Trigger Button

* Added Content Alignment for Button, Popover menu and Modal Trigger btn

* Added Hover Toggle for Button , Button Group, Popover menu and Modal Trigger Btn

* Reverted changes to button group legacy

* Added the properties to the new Button Group

* Resolved copilot comments

* Removed Content Alignment from Button group and changed the accordian for hover bg

* Created the migration and the import-export service

* perf: Replace placeholder text color migration with optimized version using cursor pagination

* fix: use result[1] for affected row count in batch DELETE

entityManager.query() returns [rows, rowCount] for DELETE/UPDATE
statements, not a QueryResult object. result.rowCount is undefined,
causing the cleanup loop to exit after the first batch.

* update: bump subproject commits for frontend and server components

* fix: include NULL styles rows in placeholder text color backfill

NOT (styles::jsonb ? 'key') yields NULL when styles IS NULL, so those
rows were silently skipped. Added explicit OR styles IS NULL to catch them.

* chore: use @helpers path alias for migration.helper import

* fix: implement two-pass delete for app history to avoid FK violations

* Revert "Reverted placeholder color changes (#15659)"

This reverts commit 8a458cfcbd.

* refactor: remove unused migration for backfilling placeholder text color

* refactor: button style migration and added the progess

---------

Co-authored-by: Rahul <rahulrnc03@gmail.com>
Co-authored-by: Shaurya Sharma <shaurya064@gmail.com>
Co-authored-by: Johnson Cherian <johnsonc.dev@gmail.com>
2026-03-27 15:54:50 +05:30