@lovrabet/rabetbase-cli 2.5.2 → 2.5.3-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.d.ts +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/generate-sdk-config-file.d.ts +2 -1
- package/lib/api/generate-sdk-config-file.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/logs.d.ts +7 -0
- package/lib/commands/bff/logs.js +1 -0
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/delete.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/batch-design.d.ts +21 -0
- package/lib/commands/dataset/batch-design.js +1 -0
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-restore.js +1 -1
- package/lib/commands/dataset/field-update.js +1 -1
- package/lib/commands/dataset/generate.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/dataset/relation-audit.js +1 -1
- package/lib/commands/dataset/relation-create.js +1 -1
- package/lib/commands/dataset/relation-delete.js +1 -1
- package/lib/commands/dataset/relation-shared.js +1 -1
- package/lib/commands/dataset/relation-update.js +1 -1
- package/lib/commands/dataset/relations.js +1 -1
- package/lib/commands/dataset/rename.js +1 -1
- package/lib/commands/dataset/restore.js +1 -1
- package/lib/commands/dataset/user-deleted-field-list.js +1 -1
- package/lib/commands/db/analysis-batching.js +1 -1
- package/lib/commands/db/analyze-batch-plan.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff-refresh-start.js +1 -1
- package/lib/commands/db/diff-refresh-status.js +1 -1
- package/lib/commands/db/diff.js +1 -1
- package/lib/commands/db/index.js +1 -1
- package/lib/commands/db/list.js +1 -1
- package/lib/commands/db/shared.js +1 -1
- package/lib/commands/db/table-diff-shared.js +1 -1
- package/lib/commands/db/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/deployment/index.js +1 -1
- package/lib/commands/deployment/sync-all.js +1 -1
- package/lib/commands/deployment/sync-jobs.js +1 -1
- package/lib/commands/deployment/sync-status.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/flow/create.d.ts +2 -0
- package/lib/commands/flow/create.js +1 -0
- package/lib/commands/flow/detail.d.ts +2 -0
- package/lib/commands/flow/detail.js +1 -0
- package/lib/commands/flow/index.d.ts +3 -0
- package/lib/commands/flow/index.js +1 -0
- package/lib/commands/flow/list.d.ts +2 -0
- package/lib/commands/flow/list.js +1 -0
- package/lib/commands/flow/publish.d.ts +2 -0
- package/lib/commands/flow/publish.js +1 -0
- package/lib/commands/flow/runtime-resources-shared.d.ts +40 -0
- package/lib/commands/flow/runtime-resources-shared.js +1 -0
- package/lib/commands/flow/runtime-role-list.d.ts +2 -0
- package/lib/commands/flow/runtime-role-list.js +1 -0
- package/lib/commands/flow/runtime-role-user-list.d.ts +2 -0
- package/lib/commands/flow/runtime-role-user-list.js +1 -0
- package/lib/commands/flow/runtime-user-search.d.ts +2 -0
- package/lib/commands/flow/runtime-user-search.js +1 -0
- package/lib/commands/flow/shared.d.ts +41 -0
- package/lib/commands/flow/shared.js +1 -0
- package/lib/commands/flow/update.d.ts +2 -0
- package/lib/commands/flow/update.js +1 -0
- package/lib/commands/flow/validate.d.ts +3 -0
- package/lib/commands/flow/validate.js +1 -0
- package/lib/commands/instant-api-policy/current.js +1 -1
- package/lib/commands/instant-api-policy/index.js +1 -1
- package/lib/commands/instant-api-policy/init.js +1 -1
- package/lib/commands/instant-api-policy/publish.js +1 -1
- package/lib/commands/instant-api-policy/pull.js +1 -1
- package/lib/commands/instant-api-policy/revision.js +1 -1
- package/lib/commands/instant-api-policy/revisions.js +1 -1
- package/lib/commands/instant-api-policy/rollback.js +1 -1
- package/lib/commands/instant-api-policy/shared.js +1 -1
- package/lib/commands/instant-api-policy/validate.js +1 -1
- package/lib/commands/issue/index.js +1 -1
- package/lib/commands/issue/nudge.js +1 -1
- package/lib/commands/issue/report.js +1 -1
- package/lib/commands/issue/shared.js +1 -1
- package/lib/commands/kb/create.js +1 -1
- package/lib/commands/kb/delete.js +1 -1
- package/lib/commands/kb/detail.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/kb/list.js +1 -1
- package/lib/commands/kb/search.js +1 -1
- package/lib/commands/kb/shared.js +1 -1
- package/lib/commands/kb/update.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/mutations.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/visibility-update.js +1 -1
- package/lib/commands/notification/config-create.js +1 -1
- package/lib/commands/notification/config-delete.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/config-update.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/create.js +1 -1
- package/lib/commands/page/custom/detail.js +1 -1
- package/lib/commands/page/custom/list.js +1 -1
- package/lib/commands/page/custom/publish.js +1 -1
- package/lib/commands/page/custom/shared.js +1 -1
- package/lib/commands/page/custom/syntax.js +1 -1
- package/lib/commands/page/custom/update.js +1 -1
- package/lib/commands/page/data-list-status.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/materialize-project-template.js +1 -1
- package/lib/commands/project/create/project-name.js +1 -1
- package/lib/commands/project/create/project-template-archive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/domain-routing-sync.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/role/user-resolve.js +1 -1
- package/lib/commands/rule/get.js +1 -1
- package/lib/commands/rule/index.js +1 -1
- package/lib/commands/rule/list.js +1 -1
- package/lib/commands/rule/set.js +1 -1
- package/lib/commands/rule/shared.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/sql/create.js +1 -1
- package/lib/commands/sql/delete.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/pull.js +1 -1
- package/lib/commands/sql/push.js +1 -1
- package/lib/commands/sql/shared.js +1 -1
- package/lib/commands/sql/status.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/commands/task/index.js +1 -1
- package/lib/commands/task/status.js +1 -1
- package/lib/commands/tenant/index.js +1 -1
- package/lib/commands/tenant/members-list.js +1 -1
- package/lib/commands/tenant/shared.js +1 -1
- package/lib/commands/user-account/dingding-sandbox-bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/add.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -1
- package/lib/config/domain-config.js +1 -1
- package/lib/config/project-domain-routing.js +1 -1
- package/lib/config/region-config.d.ts +23 -0
- package/lib/config/region-config.js +1 -0
- package/lib/config/schema.d.ts +15 -0
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/paths.js +1 -1
- package/lib/constant/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/routing-profile.js +1 -1
- package/lib/context/app-resolver.d.ts +6 -0
- package/lib/context/app-resolver.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.d.ts +13 -0
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.d.ts +172 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/hook-directory.d.ts +55 -0
- package/lib/core/bff/hook-directory.js +1 -0
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/types.d.ts +15 -0
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/flow-config.d.ts +628 -0
- package/lib/core/flow-config.js +1 -0
- package/lib/core/instant-api-policy/config.js +1 -1
- package/lib/core/kb-search-client.js +1 -1
- package/lib/core/page/file-system.js +1 -1
- package/lib/core/page/hash.js +1 -1
- package/lib/core/page/lock.js +1 -1
- package/lib/core/page/lr-smart-jsx.d.ts +6 -0
- package/lib/core/page/lr-smart-jsx.js +1 -0
- package/lib/core/sql-index-auditor.js +1 -1
- package/lib/core/sql-sync/config.js +1 -1
- package/lib/core/sql-sync/file-system.js +1 -1
- package/lib/core/sql-sync/hash.js +1 -1
- package/lib/core/sql-sync/lock.js +1 -1
- package/lib/core/sql-sync/utils.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/error-output.js +1 -1
- package/lib/framework/explicit-yes.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-alias.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/supported-flags.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/skill-presence.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
- package/lib/types/index.d.ts +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/config.d.ts +2 -8
- package/lib/utils/config.js +1 -1
- package/lib/utils/entity-with-id.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.d.ts +2 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/rabetbase/SKILL.md +27 -8
- package/skills/rabetbase/guides/approval-flow-development-workflow.md +137 -0
- package/skills/rabetbase/guides/backend-function.md +19 -9
- package/skills/rabetbase/guides/bff-creation-workflow.md +10 -1
- package/skills/rabetbase/guides/conflict-detection.md +2 -0
- package/skills/rabetbase/guides/page-development-workflow.md +3 -0
- package/skills/rabetbase/guides/sdk-client-generation.md +6 -5
- package/skills/rabetbase/knowledge/approval-flow/config-json-schema.md +290 -0
- package/skills/rabetbase/knowledge/page-schema/LrSmartJsx.md +11 -3
- package/skills/rabetbase/references/rabetbase-api-pull.md +5 -4
- package/skills/rabetbase/references/rabetbase-app-list.md +3 -0
- package/skills/rabetbase/references/rabetbase-bff-create.md +1 -1
- package/skills/rabetbase/references/rabetbase-bff-list.md +1 -1
- package/skills/rabetbase/references/rabetbase-bff-logs.md +47 -0
- package/skills/rabetbase/references/rabetbase-bff-pull.md +9 -3
- package/skills/rabetbase/references/rabetbase-bff-push.md +10 -2
- package/skills/rabetbase/references/rabetbase-bff-status.md +2 -0
- package/skills/rabetbase/references/rabetbase-config.md +10 -9
- package/skills/rabetbase/references/rabetbase-dataset-generate.md +52 -2
- package/skills/rabetbase/references/rabetbase-doctor.md +2 -2
- package/skills/rabetbase/references/rabetbase-flow-commands.md +86 -0
- package/skills/rabetbase/references/rabetbase-flow-resources.md +83 -0
- package/skills/rabetbase/references/rabetbase-flow-runtime-boundary.md +25 -0
- package/skills/rabetbase/references/rabetbase-instant-api-policy.md +103 -11
- package/skills/rabetbase/references/rabetbase-notification-config-list.md +17 -0
- package/skills/rabetbase/references/rabetbase-page-push.md +5 -1
- package/skills/rabetbase/references/rabetbase-workspace.md +4 -2
- package/skills/rabetbase.manifest.json +9 -3
- package/templates/generate-api/client.ts.tpl +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a269_0x1c57b2=a269_0x40e0;(function(_0x35e9c6,_0xfe5dc3){const _0x47dd27=a269_0x40e0,_0x3d2c22=_0x35e9c6();while(!![]){try{const _0x573c1b=-parseInt(_0x47dd27(0x222))/0x1*(parseInt(_0x47dd27(0x2cd))/0x2)+parseInt(_0x47dd27(0x182))/0x3+-parseInt(_0x47dd27(0x2ca))/0x4*(-parseInt(_0x47dd27(0x208))/0x5)+parseInt(_0x47dd27(0x237))/0x6*(-parseInt(_0x47dd27(0x2e5))/0x7)+parseInt(_0x47dd27(0x1dd))/0x8+parseInt(_0x47dd27(0x1f3))/0x9*(parseInt(_0x47dd27(0x1e6))/0xa)+-parseInt(_0x47dd27(0x2bf))/0xb*(parseInt(_0x47dd27(0x1c9))/0xc);if(_0x573c1b===_0xfe5dc3)break;else _0x3d2c22['push'](_0x3d2c22['shift']());}catch(_0x4a8232){_0x3d2c22['push'](_0x3d2c22['shift']());}}}(a269_0x5923,0xd3d2f));import{randomUUID}from'node:crypto';import{chmod,link,readFile,rename,stat,unlink,writeFile}from'node:fs/promises';import{resolve}from'node:path';export const FLOW_CONFIG_JSON_SCHEMA={'$schema':'https://json-schema.org/draft/2020-12/schema','$id':a269_0x1c57b2(0x181),'title':a269_0x1c57b2(0x25b),'type':a269_0x1c57b2(0x23f),'required':[a269_0x1c57b2(0x1a1),a269_0x1c57b2(0x261),a269_0x1c57b2(0x1e0)],'$defs':{'userId':{'anyOf':[{'type':a269_0x1c57b2(0x27d),'minLength':0x1},{'type':a269_0x1c57b2(0x28f),'minimum':0x1}]},'position':{'type':a269_0x1c57b2(0x23f),'required':['x','y'],'properties':{'x':{'type':'number','minimum':0x0},'y':{'type':a269_0x1c57b2(0x295),'minimum':0x0}},'additionalProperties':!![]},'timeAmount':{'type':a269_0x1c57b2(0x23f),'required':[a269_0x1c57b2(0x212),a269_0x1c57b2(0x1ad)],'properties':{'value':{'type':a269_0x1c57b2(0x28f),'minimum':0x1},'unit':{'enum':[a269_0x1c57b2(0x272),a269_0x1c57b2(0x203),'HOURS',a269_0x1c57b2(0x17a)]}},'additionalProperties':!![]},'flowNode':{'type':a269_0x1c57b2(0x23f),'required':['id',a269_0x1c57b2(0x174),a269_0x1c57b2(0x233),'position'],'properties':{'id':{'type':a269_0x1c57b2(0x27d),'pattern':a269_0x1c57b2(0x196)},'type':{'enum':[a269_0x1c57b2(0x19f),a269_0x1c57b2(0x290),'APPROVAL',a269_0x1c57b2(0x1e3),a269_0x1c57b2(0x1e2),a269_0x1c57b2(0x2da)]},'name':{'type':'string','minLength':0x1},'pageId':{'type':a269_0x1c57b2(0x28f),'minimum':0x1},'position':{'$ref':a269_0x1c57b2(0x287)},'approvalMode':{'enum':[a269_0x1c57b2(0x2d6),a269_0x1c57b2(0x23d),a269_0x1c57b2(0x298)]},'taskMode':{'enum':['APPROVAL',a269_0x1c57b2(0x263)]},'assignee':{'type':a269_0x1c57b2(0x23f),'required':[a269_0x1c57b2(0x229)],'properties':{'strategy':{'enum':[a269_0x1c57b2(0x256),'ROLE']},'userIds':{'type':a269_0x1c57b2(0x1e7),'minItems':0x1,'items':{'$ref':a269_0x1c57b2(0x1e8)}},'roleId':{'anyOf':[{'type':a269_0x1c57b2(0x28f),'minimum':0x1},{'type':a269_0x1c57b2(0x27d),'pattern':'^[1-9][0-9]*$'}]}},'additionalProperties':!![]},'transferCandidates':{'type':'object','required':[a269_0x1c57b2(0x229),'userIds'],'properties':{'strategy':{'const':a269_0x1c57b2(0x256)},'userIds':{'type':'array','minItems':0x1,'items':{'$ref':a269_0x1c57b2(0x1e8)}}},'additionalProperties':!![]},'sequential':{'type':a269_0x1c57b2(0x1af)},'result':{'enum':[a269_0x1c57b2(0x1f2),a269_0x1c57b2(0x180)]},'scriptName':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'resultVariable':{'type':a269_0x1c57b2(0x27d),'pattern':'^[A-Za-z_][A-Za-z0-9_]*$'},'async':{'type':a269_0x1c57b2(0x23f),'properties':{'enabled':{'type':a269_0x1c57b2(0x1af)},'retryCount':{'type':a269_0x1c57b2(0x28f),'minimum':0x1,'maximum':0xa},'retryInterval':{'$ref':'#/$defs/timeAmount'}},'additionalProperties':!![]},'timeout':{'type':a269_0x1c57b2(0x23f),'properties':{'enabled':{'type':a269_0x1c57b2(0x1af)},'duration':{'$ref':'#/$defs/timeAmount'},'action':{'enum':[a269_0x1c57b2(0x20f),a269_0x1c57b2(0x1c5),a269_0x1c57b2(0x266)]},'interrupting':{'type':a269_0x1c57b2(0x1af)},'scriptName':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'resultVariable':{'type':a269_0x1c57b2(0x27d),'pattern':a269_0x1c57b2(0x196)}},'additionalProperties':!![]},'cc':{'type':a269_0x1c57b2(0x23f),'required':[a269_0x1c57b2(0x251)],'properties':{'recipientUserIds':{'type':a269_0x1c57b2(0x1e7),'minItems':0x1,'maxItems':0x64,'uniqueItems':!![],'items':{'type':a269_0x1c57b2(0x27d),'minLength':0x1}},'visible':{'type':a269_0x1c57b2(0x1e7),'uniqueItems':!![],'items':{'type':'string','minLength':0x1}},'readSources':![]},'additionalProperties':!![]},'config':{'type':'object','required':[a269_0x1c57b2(0x2c0),a269_0x1c57b2(0x1b8)],'properties':{'version':{'enum':['v1']},'configCode':{'type':'string','minLength':0x1},'failurePolicy':{'enum':[a269_0x1c57b2(0x17e),a269_0x1c57b2(0x1c1)]},'template':{'type':a269_0x1c57b2(0x23f),'required':[a269_0x1c57b2(0x183),a269_0x1c57b2(0x241)],'properties':{'title':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'summary':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'detailMarkdown':{'type':a269_0x1c57b2(0x27d)},'facts':{'type':a269_0x1c57b2(0x1e7),'maxItems':0x8,'items':{'type':'object','required':[a269_0x1c57b2(0x284),a269_0x1c57b2(0x212)],'properties':{'label':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'value':{'type':a269_0x1c57b2(0x27d),'minLength':0x1}},'additionalProperties':!![]}},'actions':{'type':a269_0x1c57b2(0x1e7),'maxItems':0x2,'items':{'type':a269_0x1c57b2(0x23f),'required':[a269_0x1c57b2(0x2b3),a269_0x1c57b2(0x1ac)],'properties':{'text':{'type':'string','minLength':0x1},'url':{'type':a269_0x1c57b2(0x27d),'minLength':0x1}},'additionalProperties':!![]}}},'additionalProperties':!![]},'recipients':{'type':'array','items':{'type':'object','required':[a269_0x1c57b2(0x174),a269_0x1c57b2(0x212)],'properties':{'type':{'enum':['USER',a269_0x1c57b2(0x1b5),a269_0x1c57b2(0x2ad)]},'value':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'role':{'enum':['TO','CC','BCC']}},'additionalProperties':!![]}}},'additionalProperties':!![]},'form':![],'formPermission':![]},'additionalProperties':!![]},'flowEdge':{'type':a269_0x1c57b2(0x23f),'properties':{'id':{'type':a269_0x1c57b2(0x27d),'pattern':'^[A-Za-z_][A-Za-z0-9_]*$'},'source':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'target':{'type':'string','minLength':0x1},'sourceNodeId':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'targetNodeId':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'conditionType':{'enum':[a269_0x1c57b2(0x1a8),a269_0x1c57b2(0x1f2),a269_0x1c57b2(0x180),a269_0x1c57b2(0x277)]},'expression':{'type':'string'},'defaultFlow':{'type':a269_0x1c57b2(0x1af)},'name':{'type':a269_0x1c57b2(0x27d)},'waypoints':{'type':'array','items':{'$ref':a269_0x1c57b2(0x287)}}},'allOf':[{'anyOf':[{'required':[a269_0x1c57b2(0x259)]},{'required':[a269_0x1c57b2(0x201)]}]},{'anyOf':[{'required':[a269_0x1c57b2(0x1ae)]},{'required':[a269_0x1c57b2(0x22e)]}]}],'additionalProperties':!![]}},'properties':{'id':![],'appCode':![],'flowName':{'type':'string','minLength':0x1},'flowDesc':{'type':'string'},'flowType':{'enum':[a269_0x1c57b2(0x194),a269_0x1c57b2(0x22a)]},'datasetCode':{'type':a269_0x1c57b2(0x27d),'minLength':0x1},'pageId':{'type':a269_0x1c57b2(0x28f)},'templateName':![],'flowJson':{'type':a269_0x1c57b2(0x23f),'required':['nodes',a269_0x1c57b2(0x23a)],'properties':{'flowKey':![],'flowCode':![],'flowName':![],'bindDatasetCode':![],'datasetCode':![],'appCode':![],'pageId':![],'templateName':![],'schemaVersion':{'type':a269_0x1c57b2(0x27d),'const':a269_0x1c57b2(0x22c),'description':a269_0x1c57b2(0x25e)},'formSchema':![],'formDefinitions':![],'formPermissions':![],'pageMode':{'const':a269_0x1c57b2(0x218)},'startPageId':{'type':a269_0x1c57b2(0x28f),'minimum':0x1},'nodes':{'type':'array','minItems':0x1,'items':{'$ref':a269_0x1c57b2(0x209)}},'edges':{'type':a269_0x1c57b2(0x1e7),'minItems':0x1,'items':{'$ref':a269_0x1c57b2(0x1a6)}}},'additionalProperties':!![]}},'additionalProperties':!![]};const REMOVED_FLOW_JSON_FIELDS=[a269_0x1c57b2(0x2bd),a269_0x1c57b2(0x1df),a269_0x1c57b2(0x1a1),a269_0x1c57b2(0x24d),a269_0x1c57b2(0x2e3),a269_0x1c57b2(0x189),a269_0x1c57b2(0x207),a269_0x1c57b2(0x271)],REMOVED_ROOT_FIELDS=['id',a269_0x1c57b2(0x189),'templateName'],DEFAULT_FLOW_SCHEMA_VERSION=a269_0x1c57b2(0x22c),NODE_TYPES=new Set([a269_0x1c57b2(0x19f),a269_0x1c57b2(0x290),a269_0x1c57b2(0x179),'CONDITION',a269_0x1c57b2(0x1e2),a269_0x1c57b2(0x2da)]),CONDITION_TYPES=new Set(['ALWAYS',a269_0x1c57b2(0x1f2),a269_0x1c57b2(0x180),a269_0x1c57b2(0x277)]),APPROVAL_MODES=new Set([a269_0x1c57b2(0x2d6),a269_0x1c57b2(0x23d),a269_0x1c57b2(0x298)]),APPROVAL_TASK_MODES=new Set([a269_0x1c57b2(0x179),a269_0x1c57b2(0x263)]),FLOW_TIME_UNITS=new Set([a269_0x1c57b2(0x272),a269_0x1c57b2(0x203),'HOURS',a269_0x1c57b2(0x17a)]),APPROVAL_TIMEOUT_ACTIONS=new Set(['AUTO_APPROVE',a269_0x1c57b2(0x1c5),a269_0x1c57b2(0x266)]),FLOW_TYPES=new Set([a269_0x1c57b2(0x194),'INDEPENDENT_FLOW']),FLOW_PAGE_MODES=new Set(['CUSTOM_PAGE',a269_0x1c57b2(0x21d)]),BPMN_ID_PATTERN=/^[A-Za-z_][A-Za-z0-9_]*$/,VARIABLE_PATTERN=/^[A-Za-z_][A-Za-z0-9_]*$/,NOTIFICATION_PLACEHOLDER_PATTERN=/\$\{([^{}]+)\}/g,NOTIFICATION_ACTION_URL_PLACEHOLDER_PATTERN=/^\$\{(?:event|context|variables)\.[^{}]+\}$/,NOTIFICATION_FAILURE_POLICIES=new Set([a269_0x1c57b2(0x17e),a269_0x1c57b2(0x1c1)]),NOTIFICATION_RECIPIENT_TYPES=new Set([a269_0x1c57b2(0x1f1),a269_0x1c57b2(0x1b5),a269_0x1c57b2(0x2ad)]),NOTIFICATION_RECIPIENT_ROLES=new Set(['TO','CC',a269_0x1c57b2(0x1fa)]),MAX_NOTIFICATION_FACTS=0x8,MAX_NOTIFICATION_ACTIONS=0x2,MAX_ASYNC_RETRY_COUNT=0xa,MAX_CC_RECIPIENTS=0x64,DEFAULT_SCRIPT_RESULT_VARIABLE=a269_0x1c57b2(0x257),UNSUPPORTED_FORM_MESSAGE=a269_0x1c57b2(0x2a4),UNSUPPORTED_PLATFORM_FORM_MESSAGE=a269_0x1c57b2(0x187),RESERVED_RESULT_VARIABLES=new Set(['formData',a269_0x1c57b2(0x1be),a269_0x1c57b2(0x20b),a269_0x1c57b2(0x2bb),a269_0x1c57b2(0x1d6),'approval_sys_initiatorUsername',a269_0x1c57b2(0x18e),'approval_sys_pageId',a269_0x1c57b2(0x231),'approval_sys_dataId']);export function normalizeFlowConfig(_0x56da4c){const _0xc60646=a269_0x1c57b2;if(!isRecord(_0x56da4c))throw new TypeError('FlowConfig\x20must\x20be\x20a\x20JSON\x20object.');const _0x2fe3fe=cloneJsonValue(_0x56da4c),_0x142e7e=_0x2fe3fe['flowJson'],_0x54982=isRecord(_0x142e7e)?cloneJsonValue(_0x142e7e):{},_0x35e595=[],_0x51e078=[];for(const _0x5f23be of REMOVED_ROOT_FIELDS){if(!Object[_0xc60646(0x19c)][_0xc60646(0x242)][_0xc60646(0x2bc)](_0x2fe3fe,_0x5f23be))continue;delete _0x2fe3fe[_0x5f23be],_0x51e078[_0xc60646(0x24b)](_0x5f23be),_0x35e595['push']({'code':_0xc60646(0x1d1),'path':_0x5f23be,'message':_0x5f23be+_0xc60646(0x2d7)});}for(const _0x2f45c8 of REMOVED_FLOW_JSON_FIELDS){if(!Object[_0xc60646(0x19c)][_0xc60646(0x242)][_0xc60646(0x2bc)](_0x54982,_0x2f45c8))continue;const _0x275bd5=_0xc60646(0x17b)+_0x2f45c8;delete _0x54982[_0x2f45c8],_0x51e078[_0xc60646(0x24b)](_0x275bd5),_0x35e595[_0xc60646(0x24b)]({'code':_0xc60646(0x1d1),'path':_0x275bd5,'message':_0x275bd5+_0xc60646(0x2d7)});}if(Object[_0xc60646(0x19c)][_0xc60646(0x242)][_0xc60646(0x2bc)](_0x54982,'schemaVersion')){const _0x226e77=_0x54982[_0xc60646(0x2e6)],_0x64c80b=typeof _0x226e77===_0xc60646(0x27d)?_0x226e77[_0xc60646(0x2d3)]():_0x226e77;if(isEmptyJsonValue(_0x226e77)||_0x64c80b===DEFAULT_FLOW_SCHEMA_VERSION){const _0x260a82='flowJson.schemaVersion';delete _0x54982[_0xc60646(0x2e6)],_0x51e078[_0xc60646(0x24b)](_0x260a82),_0x35e595[_0xc60646(0x24b)]({'code':_0xc60646(0x1d1),'path':_0x260a82,'message':_0x260a82+_0xc60646(0x1cf)+DEFAULT_FLOW_SCHEMA_VERSION+'\x20value\x20and\x20was\x20removed\x20from\x20the\x20portable\x20FlowConfig.'});}}removeEmptyMetadata(_0x54982,_0xc60646(0x1e0),_0x35e595,_0x51e078);_0x2fe3fe['flowType']===_0xc60646(0x22a)&&!Object['prototype'][_0xc60646(0x242)]['call'](_0x54982,_0xc60646(0x265))&&(_0x54982[_0xc60646(0x265)]=_0xc60646(0x218));_0x2fe3fe[_0xc60646(0x1e0)]=_0x54982;if(typeof _0x2fe3fe[_0xc60646(0x1a1)]===_0xc60646(0x27d))_0x2fe3fe[_0xc60646(0x1a1)]=_0x2fe3fe[_0xc60646(0x1a1)][_0xc60646(0x2d3)]();return{'config':_0x2fe3fe,'warnings':_0x35e595,'removedPaths':_0x51e078};}export function validateFlowConfig(_0x52b913){const _0xba3904=a269_0x1c57b2;let _0x39d2f5;try{_0x39d2f5=normalizeFlowConfig(_0x52b913);}catch(_0xbc8440){const _0x15b808=_0xbc8440 instanceof Error?_0xbc8440[_0xba3904(0x23e)]:String(_0xbc8440),_0x47e1e0={'flowJson':{}};return{'valid':![],'errors':[{'path':'$','message':_0x15b808}],'warnings':[],'normalized':_0x47e1e0,'validationConfig':_0x47e1e0};}const _0x5b7c77=_0x39d2f5[_0xba3904(0x288)],_0x19552d=cloneJsonValue(_0x5b7c77),_0x2f026e=_0x19552d[_0xba3904(0x1e0)];_0x2f026e[_0xba3904(0x2bd)]=_0xba3904(0x175),_0x2f026e[_0xba3904(0x1a1)]=_0x5b7c77['flowName'];typeof _0x5b7c77[_0xba3904(0x2e3)]===_0xba3904(0x27d)&&_0x5b7c77[_0xba3904(0x2e3)][_0xba3904(0x2d3)]()&&(_0x2f026e[_0xba3904(0x24d)]=_0x5b7c77[_0xba3904(0x2e3)][_0xba3904(0x2d3)]());const _0x405358=[];return validateOuterMetadata(_0x5b7c77,_0x405358),validateFlowClassification(_0x5b7c77,_0x405358),validateGraph(_0x5b7c77[_0xba3904(0x1e0)],_0x405358),{'valid':_0x405358[_0xba3904(0x2cc)]===0x0,'errors':_0x405358,'warnings':_0x39d2f5[_0xba3904(0x1c3)],'normalized':_0x5b7c77,'validationConfig':_0x19552d};}function validateFlowClassification(_0x302ede,_0x45789d){const _0xa6e484=a269_0x1c57b2;if(!isRecord(_0x302ede[_0xa6e484(0x1e0)]))return;const _0x1f8202=_0x302ede[_0xa6e484(0x261)],_0x4ce3e6=_0x302ede[_0xa6e484(0x1e0)][_0xa6e484(0x265)];_0x4ce3e6!==undefined&&(typeof _0x4ce3e6!=='string'||!FLOW_PAGE_MODES['has'](_0x4ce3e6))&&_0x45789d[_0xa6e484(0x24b)]({'path':'flowJson.pageMode','message':_0xa6e484(0x2be)+String(_0x4ce3e6)+'.'});_0x1f8202===_0xa6e484(0x194)&&_0x4ce3e6!==undefined&&_0x45789d[_0xa6e484(0x24b)]({'path':_0xa6e484(0x245),'message':_0xa6e484(0x2e2)});_0x1f8202===_0xa6e484(0x22a)&&_0x4ce3e6===_0xa6e484(0x21d)&&_0x45789d[_0xa6e484(0x24b)]({'path':'flowJson.pageMode','message':UNSUPPORTED_PLATFORM_FORM_MESSAGE});(_0x1f8202===_0xa6e484(0x194)||_0x1f8202===_0xa6e484(0x22a))&&validateCustomPageNavigation(_0x302ede,_0x1f8202,_0x4ce3e6,_0x45789d);if(_0x1f8202!==_0xa6e484(0x194)||!Array['isArray'](_0x302ede[_0xa6e484(0x1e0)][_0xa6e484(0x214)]))return;_0x302ede[_0xa6e484(0x1e0)][_0xa6e484(0x214)][_0xa6e484(0x197)]((_0x426cc7,_0x1606dd)=>{const _0x3d0e02=_0xa6e484;isRecord(_0x426cc7)&&_0x426cc7[_0x3d0e02(0x174)]===_0x3d0e02(0x179)&&_0x426cc7[_0x3d0e02(0x279)]===_0x3d0e02(0x263)&&_0x45789d['push']({'path':'flowJson.nodes['+_0x1606dd+_0x3d0e02(0x269),'message':_0x3d0e02(0x27f)});});}function validateCustomPageNavigation(_0x158344,_0x12ad17,_0x4626d8,_0x24ea95){const _0x2c9699=a269_0x1c57b2,_0x5f5bf9=_0x158344['flowJson'][_0x2c9699(0x224)];_0x5f5bf9!==undefined&&(!Number[_0x2c9699(0x1ab)](_0x5f5bf9)||_0x5f5bf9<=0x0)&&_0x24ea95['push']({'path':_0x2c9699(0x27b),'message':'startPageId\x20must\x20be\x20a\x20positive\x20integer.'});const _0x2b3d1f=Array[_0x2c9699(0x230)](_0x158344['flowJson'][_0x2c9699(0x214)])?_0x158344[_0x2c9699(0x1e0)]['nodes'][_0x2c9699(0x1bb)]((_0x38dcf8,_0x4ef581)=>({'node':_0x38dcf8,'index':_0x4ef581}))[_0x2c9699(0x20c)](({node:_0x1beaa9})=>isRecord(_0x1beaa9)&&_0x1beaa9['pageId']!==undefined):[],_0x1cf3b2=_0x5f5bf9!==undefined||_0x2b3d1f['length']>0x0,_0xe3b227=_0x4626d8===undefined&&_0x12ad17===_0x2c9699(0x22a)?_0x2c9699(0x218):_0x4626d8;_0x1cf3b2&&(_0x12ad17!==_0x2c9699(0x22a)||_0xe3b227!=='CUSTOM_PAGE')&&(_0x5f5bf9!==undefined&&_0x24ea95[_0x2c9699(0x24b)]({'path':'flowJson.startPageId','message':_0x2c9699(0x27e)}),_0x2b3d1f[_0x2c9699(0x197)](({index:_0x4d93a5})=>{const _0x1e07a2=_0x2c9699;_0x24ea95['push']({'path':_0x1e07a2(0x217)+_0x4d93a5+_0x1e07a2(0x2af),'message':_0x1e07a2(0x226)});}));}export async function writeNormalizedFlowConfig(_0xaa7b56,_0x19a1bc,_0x402b79={}){const _0x1d6688=a269_0x1c57b2,_0x140306=resolve(_0xaa7b56),_0x26580f=_0x140306+'.'+process[_0x1d6688(0x280)]+'.'+randomUUID()+_0x1d6688(0x1bd),_0x510d93=JSON[_0x1d6688(0x293)](_0x19a1bc,null,0x2)+'\x0a';let _0x3e38d5;try{try{_0x3e38d5=(await stat(_0x140306))[_0x1d6688(0x1a5)]&0x1ff;}catch{_0x3e38d5=undefined;}await writeFile(_0x26580f,_0x510d93,{'encoding':'utf8','flag':'wx','mode':_0x3e38d5??0x1a4});if(_0x3e38d5!==undefined)await chmod(_0x26580f,_0x3e38d5);_0x402b79[_0x1d6688(0x1cb)]===![]?(await link(_0x26580f,_0x140306),await unlink(_0x26580f)):await rename(_0x26580f,_0x140306);}finally{await unlink(_0x26580f)[_0x1d6688(0x1b6)](()=>undefined);}}function validateOuterMetadata(_0x4c0f4d,_0x2ca220){const _0x31d82a=a269_0x1c57b2;(typeof _0x4c0f4d['flowName']!=='string'||_0x4c0f4d['flowName']['trim']()==='')&&_0x2ca220[_0x31d82a(0x24b)]({'path':_0x31d82a(0x1a1),'message':_0x31d82a(0x24c)});_0x4c0f4d[_0x31d82a(0x228)]!==undefined&&typeof _0x4c0f4d['flowDesc']!==_0x31d82a(0x27d)&&_0x2ca220['push']({'path':_0x31d82a(0x228),'message':'flowDesc\x20must\x20be\x20a\x20string.'});if(_0x4c0f4d[_0x31d82a(0x261)]===undefined||_0x4c0f4d['flowType']===null)_0x2ca220[_0x31d82a(0x24b)]({'path':_0x31d82a(0x261),'message':_0x31d82a(0x2d5)});else(typeof _0x4c0f4d['flowType']!==_0x31d82a(0x27d)||!FLOW_TYPES[_0x31d82a(0x29d)](_0x4c0f4d[_0x31d82a(0x261)]))&&_0x2ca220[_0x31d82a(0x24b)]({'path':_0x31d82a(0x261),'message':_0x31d82a(0x2a9)+String(_0x4c0f4d[_0x31d82a(0x261)])+'.'});_0x4c0f4d[_0x31d82a(0x2e3)]!==undefined&&typeof _0x4c0f4d[_0x31d82a(0x2e3)]!==_0x31d82a(0x27d)&&_0x2ca220[_0x31d82a(0x24b)]({'path':_0x31d82a(0x2e3),'message':_0x31d82a(0x291)}),_0x4c0f4d[_0x31d82a(0x207)]!==undefined&&(!Number['isInteger'](_0x4c0f4d[_0x31d82a(0x207)])||_0x4c0f4d[_0x31d82a(0x207)]<0x0)&&_0x2ca220[_0x31d82a(0x24b)]({'path':_0x31d82a(0x207),'message':'pageId\x20must\x20be\x20a\x20non-negative\x20integer.'}),_0x4c0f4d[_0x31d82a(0x261)]===_0x31d82a(0x22a)&&_0x4c0f4d['datasetCode']!==undefined&&_0x2ca220[_0x31d82a(0x24b)]({'path':_0x31d82a(0x2e3),'message':'INDEPENDENT_FLOW\x20cannot\x20bind\x20datasetCode.'}),_0x4c0f4d[_0x31d82a(0x261)]===_0x31d82a(0x22a)&&_0x4c0f4d[_0x31d82a(0x207)]!==undefined&&_0x2ca220[_0x31d82a(0x24b)]({'path':_0x31d82a(0x207),'message':_0x31d82a(0x221)});}function validateGraph(_0x441721,_0x81fa6e){const _0x28a70f=a269_0x1c57b2;if(!isRecord(_0x441721)){_0x81fa6e[_0x28a70f(0x24b)]({'path':_0x28a70f(0x1e0),'message':_0x28a70f(0x18a)});return;}!Array[_0x28a70f(0x230)](_0x441721[_0x28a70f(0x214)])&&_0x81fa6e[_0x28a70f(0x24b)]({'path':_0x28a70f(0x2a2),'message':'nodes\x20must\x20be\x20an\x20array.'});!Array['isArray'](_0x441721[_0x28a70f(0x23a)])&&_0x81fa6e['push']({'path':'flowJson.edges','message':_0x28a70f(0x2c7)});Object['prototype'][_0x28a70f(0x242)][_0x28a70f(0x2bc)](_0x441721,'schemaVersion')&&_0x81fa6e[_0x28a70f(0x24b)]({'path':'flowJson.schemaVersion','message':_0x28a70f(0x216)+String(_0x441721['schemaVersion'])+_0x28a70f(0x247)+DEFAULT_FLOW_SCHEMA_VERSION+'.'});for(const _0x5e726d of[_0x28a70f(0x2b1),_0x28a70f(0x188),_0x28a70f(0x2a8)]){Object[_0x28a70f(0x19c)][_0x28a70f(0x242)]['call'](_0x441721,_0x5e726d)&&_0x81fa6e[_0x28a70f(0x24b)]({'path':'flowJson.'+_0x5e726d,'message':UNSUPPORTED_FORM_MESSAGE});}if(!Array[_0x28a70f(0x230)](_0x441721['nodes'])||!Array[_0x28a70f(0x230)](_0x441721['edges']))return;const _0x3b2f97=new Map(),_0x5397ce=[],_0x547efe=[],_0x84de6e=new Map(),_0x566dd9=new Map(),_0x1569a7=new Set();let _0xdfc8c3=0x0;_0x441721[_0x28a70f(0x214)][_0x28a70f(0x197)]((_0x16432f,_0x38880c)=>{const _0xd0e0e1=_0x28a70f,_0x5ec72d=_0xd0e0e1(0x217)+_0x38880c+']';if(!isRecord(_0x16432f)){_0x81fa6e[_0xd0e0e1(0x24b)]({'path':_0x5ec72d,'message':_0xd0e0e1(0x2ba)});return;}const _0xacd034=_0x16432f;if(typeof _0xacd034['id']!==_0xd0e0e1(0x27d)||!BPMN_ID_PATTERN[_0xd0e0e1(0x2dc)](_0xacd034['id']))_0x81fa6e[_0xd0e0e1(0x24b)]({'path':_0x5ec72d+'.id','message':_0xd0e0e1(0x23b)});else _0x3b2f97[_0xd0e0e1(0x29d)](_0xacd034['id'])?_0x81fa6e[_0xd0e0e1(0x24b)]({'path':_0x5ec72d+_0xd0e0e1(0x1c7),'message':'Duplicate\x20node\x20id:\x20'+_0xacd034['id']+'.'}):(_0x3b2f97['set'](_0xacd034['id'],_0xacd034),_0x1569a7[_0xd0e0e1(0x26d)](_0xacd034['id']));if(!NODE_TYPES[_0xd0e0e1(0x29d)](_0xacd034['type']))_0x81fa6e[_0xd0e0e1(0x24b)]({'path':_0x5ec72d+_0xd0e0e1(0x268),'message':_0xd0e0e1(0x1dc)+String(_0xacd034[_0xd0e0e1(0x174)])+'.'});else{if(_0xacd034[_0xd0e0e1(0x174)]===_0xd0e0e1(0x19f))_0x5397ce['push'](_0xacd034['id']);else _0xacd034[_0xd0e0e1(0x174)]===_0xd0e0e1(0x290)&&_0x547efe[_0xd0e0e1(0x24b)](_0xacd034['id']);}_0xacd034[_0xd0e0e1(0x174)]===_0xd0e0e1(0x179)&&(_0xacd034['taskMode']===undefined||_0xacd034[_0xd0e0e1(0x279)]==='APPROVAL')&&(_0xdfc8c3+=0x1);validateNode(_0xacd034,_0x5ec72d,_0x81fa6e);if(_0xacd034[_0xd0e0e1(0x174)]==='SCRIPT'){const _0x1f61c1=resolveEffectiveResultVariable(_0xacd034[_0xd0e0e1(0x20d)],![]);_0x1f61c1&&(registerResultVariableOwner(_0x566dd9,_0x1f61c1,_0xacd034['id'],_0x81fa6e),!_0x84de6e['has'](_0x1f61c1)&&_0x84de6e['set'](_0x1f61c1,_0xacd034['id']));}if(_0xacd034['type']==='APPROVAL'&&isRecord(_0xacd034['timeout'])&&_0xacd034[_0xd0e0e1(0x2d0)][_0xd0e0e1(0x1b2)]===!![]&&_0xacd034[_0xd0e0e1(0x2d0)][_0xd0e0e1(0x29b)]==='EXECUTE_BFF'){const _0x5ab932=resolveEffectiveResultVariable(_0xacd034['timeout']['resultVariable'],!![]);_0x5ab932&®isterResultVariableOwner(_0x566dd9,_0x5ab932,_0xacd034['id']+_0xd0e0e1(0x192),_0x81fa6e);}});_0x5397ce['length']!==0x1&&_0x81fa6e[_0x28a70f(0x24b)]({'path':_0x28a70f(0x2a2),'message':_0x28a70f(0x193)});_0x547efe['length']===0x0&&_0x81fa6e[_0x28a70f(0x24b)]({'path':_0x28a70f(0x2a2),'message':_0x28a70f(0x278)});const _0xf76529=new Map(),_0x4141c=new Map(),_0x137dbf=new Map(),_0x2291ed=new Set();_0x441721[_0x28a70f(0x23a)][_0x28a70f(0x197)]((_0x4b343c,_0x256391)=>{const _0x409736=_0x28a70f,_0x297a6f=_0x409736(0x1f4)+_0x256391+']';if(!isRecord(_0x4b343c)){_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f,'message':_0x409736(0x1c8)});return;}const _0x398808=_0x4b343c;_0x137dbf[_0x409736(0x294)](_0x398808,_0x297a6f);const _0x402225=resolveEdgeEndpoint(_0x398808[_0x409736(0x259)],_0x398808['sourceNodeId']),_0x1ef0c3=resolveEdgeEndpoint(_0x398808['target'],_0x398808['targetNodeId']);if(!_0x402225)_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f+_0x409736(0x1b9),'message':_0x409736(0x213)});if(!_0x1ef0c3)_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f+_0x409736(0x1ee),'message':_0x409736(0x26f)});_0x402225&&!_0x3b2f97[_0x409736(0x29d)](_0x402225)&&_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f+_0x409736(0x1b9),'message':'Edge\x20source\x20node\x20not\x20found:\x20'+_0x402225+'.'});_0x1ef0c3&&!_0x3b2f97[_0x409736(0x29d)](_0x1ef0c3)&&_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f+_0x409736(0x1ee),'message':_0x409736(0x1ba)+_0x1ef0c3+'.'});if(_0x398808['id']!==undefined){if(typeof _0x398808['id']!==_0x409736(0x27d)||!BPMN_ID_PATTERN[_0x409736(0x2dc)](_0x398808['id']))_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f+'.id','message':_0x409736(0x273)});else{if(_0x1569a7[_0x409736(0x29d)](_0x398808['id']))_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f+_0x409736(0x1c7),'message':_0x409736(0x270)+_0x398808['id']+'.'});else!_0x1569a7[_0x409736(0x29d)](_0x398808['id'])&&_0x1569a7[_0x409736(0x26d)](_0x398808['id']);}}if(_0x402225&&_0x1ef0c3){const _0x354c44=_0x402225+'\x00'+_0x1ef0c3+'\x00'+(_0x398808[_0x409736(0x18c)]??_0x409736(0x1a8));_0x2291ed[_0x409736(0x29d)](_0x354c44)?_0x81fa6e[_0x409736(0x24b)]({'path':_0x297a6f,'message':_0x409736(0x1b4)+_0x402225+_0x409736(0x1cc)+_0x1ef0c3+'\x20('+(_0x398808[_0x409736(0x18c)]??_0x409736(0x1a8))+').'}):_0x2291ed[_0x409736(0x26d)](_0x354c44);}validateEdge(_0x398808,_0x297a6f,_0x81fa6e),_0x402225&&_0x1ef0c3&&(_0xf76529[_0x409736(0x28e)](_0x402225)?.['push'](_0x398808)??_0xf76529[_0x409736(0x294)](_0x402225,[_0x398808]),_0x4141c[_0x409736(0x28e)](_0x1ef0c3)?.['push'](_0x398808)??_0x4141c[_0x409736(0x294)](_0x1ef0c3,[_0x398808]));});if(_0x5397ce['length']!==0x1)return;validateGraphShape(_0x3b2f97,_0x5397ce[0x0],_0x547efe,_0xf76529,_0x4141c,_0x137dbf,_0x81fa6e),validateScriptResultReferences(_0x3b2f97,_0x5397ce[0x0],_0xf76529,_0x4141c,_0x137dbf,_0x84de6e,_0x81fa6e),validateApprovalResults(_0x3b2f97,_0xdfc8c3,_0x547efe,_0x81fa6e);}function validateNode(_0x23fd6c,_0x50ca2e,_0xfe53bb){const _0x242d1c=a269_0x1c57b2;for(const _0x248a29 of[_0x242d1c(0x276),_0x242d1c(0x2a6)]){Object[_0x242d1c(0x19c)][_0x242d1c(0x242)][_0x242d1c(0x2bc)](_0x23fd6c,_0x248a29)&&_0xfe53bb['push']({'path':_0x50ca2e+'.'+_0x248a29,'message':UNSUPPORTED_FORM_MESSAGE});}if(!NODE_TYPES[_0x242d1c(0x29d)](_0x23fd6c[_0x242d1c(0x174)]))return;(typeof _0x23fd6c['name']!==_0x242d1c(0x27d)||_0x23fd6c[_0x242d1c(0x233)][_0x242d1c(0x2d3)]()==='')&&_0xfe53bb['push']({'path':_0x50ca2e+_0x242d1c(0x2aa),'message':_0x242d1c(0x2b0)});if(_0x23fd6c[_0x242d1c(0x207)]!==undefined){if(!Number[_0x242d1c(0x1ab)](_0x23fd6c[_0x242d1c(0x207)])||_0x23fd6c[_0x242d1c(0x207)]<=0x0)_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x2df),'message':_0x242d1c(0x1b1)});else _0x23fd6c['type']!==_0x242d1c(0x179)&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+'.pageId','message':'node\x20pageId\x20is\x20supported\x20only\x20on\x20APPROVAL\x20user\x20tasks.'});}const _0x6b5cfe=_0x23fd6c[_0x242d1c(0x2c1)];if(!isRecord(_0x6b5cfe))_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x1aa),'message':_0x242d1c(0x27a)});else for(const _0x5a6240 of['x','y']){const _0x1d0237=_0x6b5cfe[_0x5a6240];(typeof _0x1d0237!==_0x242d1c(0x295)||!Number[_0x242d1c(0x28d)](_0x1d0237)||_0x1d0237<0x0)&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x186)+_0x5a6240,'message':_0x242d1c(0x235)+_0x5a6240+_0x242d1c(0x274)});}if(_0x23fd6c[_0x242d1c(0x174)]==='APPROVAL'){const _0x14ccca=_0x23fd6c[_0x242d1c(0x25d)]??'SINGLE',_0x3439b5=_0x23fd6c[_0x242d1c(0x279)]??_0x242d1c(0x179);!APPROVAL_TASK_MODES[_0x242d1c(0x29d)](_0x3439b5)&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x2e7),'message':'Unsupported\x20task\x20mode:\x20'+String(_0x3439b5)+'.'});!APPROVAL_MODES[_0x242d1c(0x29d)](_0x14ccca)&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x19d),'message':_0x242d1c(0x19e)+String(_0x14ccca)+'.'});if(!isRecord(_0x23fd6c[_0x242d1c(0x24f)]))_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x199),'message':_0x242d1c(0x2e0)});else{const _0x213e6d=_0x23fd6c[_0x242d1c(0x24f)][_0x242d1c(0x229)];_0x213e6d!==_0x242d1c(0x256)&&_0x213e6d!=='ROLE'&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x1e5),'message':_0x242d1c(0x21a)});if(_0x213e6d===_0x242d1c(0x256)){const _0x51e971=_0x23fd6c[_0x242d1c(0x24f)][_0x242d1c(0x249)];if(!Array[_0x242d1c(0x230)](_0x51e971)||_0x51e971[_0x242d1c(0x2cc)]===0x0)_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x2d8),'message':_0x242d1c(0x24a)});else{const _0x39819f=_0x51e971[_0x242d1c(0x21e)](_0x1eeff7=>!isValidUserId(_0x1eeff7));_0x39819f>=0x0&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x219)+_0x39819f+']','message':_0x242d1c(0x285)});const _0x1e296b=new Set(_0x51e971['filter'](isValidUserId)[_0x242d1c(0x1bb)](_0x53431d=>String(_0x53431d)[_0x242d1c(0x2d3)]()));_0x14ccca===_0x242d1c(0x2d6)&&_0x1e296b[_0x242d1c(0x27c)]>0x1&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x2d8),'message':_0x242d1c(0x2db)});}}if(_0x213e6d===_0x242d1c(0x1b5)){const _0x4b6b97=_0x23fd6c[_0x242d1c(0x24f)][_0x242d1c(0x1a7)],_0x14c26e=typeof _0x4b6b97===_0x242d1c(0x295)||typeof _0x4b6b97==='string'?Number(String(_0x4b6b97)[_0x242d1c(0x2d3)]()):Number[_0x242d1c(0x25a)];(!Number['isSafeInteger'](_0x14c26e)||_0x14c26e<=0x0)&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+'.assignee.roleId','message':_0x242d1c(0x236)});}}if(_0x23fd6c[_0x242d1c(0x255)]!==undefined){if(!isRecord(_0x23fd6c['transferCandidates']))_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x1f8),'message':_0x242d1c(0x2ce)});else{if(_0x23fd6c[_0x242d1c(0x255)][_0x242d1c(0x229)]!==_0x242d1c(0x256))_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x2a7),'message':_0x242d1c(0x264)});else{const _0x6d92ed=_0x23fd6c[_0x242d1c(0x255)][_0x242d1c(0x249)];if(!Array['isArray'](_0x6d92ed)||_0x6d92ed[_0x242d1c(0x2cc)]===0x0)_0xfe53bb['push']({'path':_0x50ca2e+_0x242d1c(0x2c8),'message':_0x242d1c(0x2c9)});else{const _0x1c4835=_0x6d92ed[_0x242d1c(0x21e)](_0x346841=>!isValidUserId(_0x346841));_0x1c4835>=0x0&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x1c2)+_0x1c4835+']','message':_0x242d1c(0x299)});}}}}}_0x23fd6c[_0x242d1c(0x26e)]!==undefined&&typeof _0x23fd6c['sequential']!==_0x242d1c(0x1af)&&_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+_0x242d1c(0x26b),'message':'sequential\x20must\x20be\x20a\x20boolean.'});if(_0x23fd6c[_0x242d1c(0x174)]===_0x242d1c(0x1e2)){(typeof _0x23fd6c[_0x242d1c(0x191)]!==_0x242d1c(0x27d)||_0x23fd6c['scriptName'][_0x242d1c(0x2d3)]()==='')&&_0xfe53bb['push']({'path':_0x50ca2e+_0x242d1c(0x211),'message':_0x242d1c(0x1ca)});if(_0x23fd6c['resultVariable']!==undefined){if(typeof _0x23fd6c[_0x242d1c(0x20d)]!==_0x242d1c(0x27d)||!VARIABLE_PATTERN[_0x242d1c(0x2dc)](_0x23fd6c[_0x242d1c(0x20d)]))_0xfe53bb[_0x242d1c(0x24b)]({'path':_0x50ca2e+'.resultVariable','message':_0x242d1c(0x1ea)});else(RESERVED_RESULT_VARIABLES[_0x242d1c(0x29d)](_0x23fd6c[_0x242d1c(0x20d)])||_0x23fd6c[_0x242d1c(0x20d)]['startsWith'](_0x242d1c(0x253)))&&_0xfe53bb['push']({'path':_0x50ca2e+'.resultVariable','message':_0x242d1c(0x18f)+_0x23fd6c['resultVariable']+'.'});}}validateAsyncExecution(_0x23fd6c,_0x50ca2e,_0xfe53bb),validateApprovalTimeout(_0x23fd6c,_0x50ca2e,_0xfe53bb),validateCcConfig(_0x23fd6c,_0x50ca2e,_0xfe53bb),_0x23fd6c[_0x242d1c(0x174)]===_0x242d1c(0x2da)&&validateNotificationConfig(_0x23fd6c[_0x242d1c(0x288)],_0x50ca2e+_0x242d1c(0x2ae),_0xfe53bb);}function validateAsyncExecution(_0x16306e,_0x591914,_0x351d07){const _0x32a796=a269_0x1c57b2;if(_0x16306e[_0x32a796(0x1d8)]===undefined)return;if(!isRecord(_0x16306e[_0x32a796(0x1d8)])){_0x351d07[_0x32a796(0x24b)]({'path':_0x591914+'.async','message':_0x32a796(0x21f)});return;}if(_0x16306e[_0x32a796(0x1d8)][_0x32a796(0x1b2)]!==undefined&&typeof _0x16306e[_0x32a796(0x1d8)][_0x32a796(0x1b2)]!==_0x32a796(0x1af)){_0x351d07[_0x32a796(0x24b)]({'path':_0x591914+_0x32a796(0x185),'message':'async.enabled\x20must\x20be\x20a\x20boolean.'});return;}if(_0x16306e[_0x32a796(0x1d8)][_0x32a796(0x1b2)]!==!![])return;_0x16306e[_0x32a796(0x174)]!==_0x32a796(0x1e2)&&_0x351d07[_0x32a796(0x24b)]({'path':_0x591914+_0x32a796(0x1e1),'message':_0x32a796(0x1c4)});const _0xe84fe7=_0x16306e[_0x32a796(0x1d8)][_0x32a796(0x1f0)]??0x3;(!Number[_0x32a796(0x1f6)](_0xe84fe7)||_0xe84fe7<0x1||_0xe84fe7>MAX_ASYNC_RETRY_COUNT)&&_0x351d07[_0x32a796(0x24b)]({'path':_0x591914+_0x32a796(0x19a),'message':'SCRIPT\x20async\x20retryCount\x20must\x20be\x20between\x201\x20and\x20'+MAX_ASYNC_RETRY_COUNT+'.'}),_0x16306e['async'][_0x32a796(0x29f)]!==undefined&&validateTimeAmount(_0x16306e[_0x32a796(0x1d8)]['retryInterval'],_0x591914+_0x32a796(0x1fe),_0x351d07);}function validateApprovalTimeout(_0x11b101,_0x2764c1,_0x3892d7){const _0x1a4375=a269_0x1c57b2;if(_0x11b101[_0x1a4375(0x2d0)]===undefined)return;if(!isRecord(_0x11b101[_0x1a4375(0x2d0)])){_0x3892d7[_0x1a4375(0x24b)]({'path':_0x2764c1+_0x1a4375(0x192),'message':_0x1a4375(0x2b8)});return;}if(_0x11b101['timeout'][_0x1a4375(0x1b2)]!==undefined&&typeof _0x11b101['timeout'][_0x1a4375(0x1b2)]!==_0x1a4375(0x1af)){_0x3892d7[_0x1a4375(0x24b)]({'path':_0x2764c1+_0x1a4375(0x238),'message':_0x1a4375(0x1e4)});return;}if(_0x11b101[_0x1a4375(0x2d0)][_0x1a4375(0x1b2)]!==!![])return;if(_0x11b101['timeout'][_0x1a4375(0x2ab)]!==undefined&&typeof _0x11b101[_0x1a4375(0x2d0)][_0x1a4375(0x2ab)]!==_0x1a4375(0x1af)){_0x3892d7[_0x1a4375(0x24b)]({'path':_0x2764c1+'.timeout.interrupting','message':'timeout.interrupting\x20must\x20be\x20a\x20boolean.'});return;}_0x11b101['type']!==_0x1a4375(0x179)&&_0x3892d7[_0x1a4375(0x24b)]({'path':_0x2764c1+'.timeout','message':_0x1a4375(0x202)});validateTimeAmount(_0x11b101[_0x1a4375(0x2d0)][_0x1a4375(0x1db)],_0x2764c1+_0x1a4375(0x204),_0x3892d7);const _0x59e688=_0x11b101['timeout'][_0x1a4375(0x29b)];if(!APPROVAL_TIMEOUT_ACTIONS[_0x1a4375(0x29d)](_0x59e688)){_0x3892d7[_0x1a4375(0x24b)]({'path':_0x2764c1+'.timeout.action','message':_0x1a4375(0x1c0)});return;}(_0x11b101[_0x1a4375(0x279)]??_0x1a4375(0x179))==='HANDLE'&&_0x59e688!==_0x1a4375(0x266)&&_0x3892d7['push']({'path':_0x2764c1+'.timeout.action','message':_0x1a4375(0x2d1)});const _0x3bd6b2=_0x11b101[_0x1a4375(0x2d0)]['interrupting']??_0x59e688!==_0x1a4375(0x266);if(_0x59e688===_0x1a4375(0x266))_0x3bd6b2&&_0x3892d7[_0x1a4375(0x24b)]({'path':_0x2764c1+_0x1a4375(0x1b7),'message':_0x1a4375(0x2b9)}),(typeof _0x11b101[_0x1a4375(0x2d0)][_0x1a4375(0x191)]!==_0x1a4375(0x27d)||_0x11b101[_0x1a4375(0x2d0)][_0x1a4375(0x191)][_0x1a4375(0x2d3)]()==='')&&_0x3892d7['push']({'path':_0x2764c1+'.timeout.scriptName','message':_0x1a4375(0x1ff)}),validateOptionalResultVariable(_0x11b101['timeout']['resultVariable'],_0x2764c1+_0x1a4375(0x29c),_0x3892d7);else!_0x3bd6b2&&_0x3892d7[_0x1a4375(0x24b)]({'path':_0x2764c1+_0x1a4375(0x1b7),'message':_0x59e688+_0x1a4375(0x2e8)});}function validateTimeAmount(_0x5350a9,_0x2ef3bd,_0x39c02f){const _0x4749c1=a269_0x1c57b2;if(!isRecord(_0x5350a9)){_0x39c02f[_0x4749c1(0x24b)]({'path':_0x2ef3bd,'message':'duration\x20requires\x20value\x20and\x20unit.'});return;}(!Number[_0x4749c1(0x1f6)](_0x5350a9[_0x4749c1(0x212)])||Number(_0x5350a9[_0x4749c1(0x212)])<=0x0)&&_0x39c02f[_0x4749c1(0x24b)]({'path':_0x2ef3bd+_0x4749c1(0x2a0),'message':_0x4749c1(0x267)}),!FLOW_TIME_UNITS[_0x4749c1(0x29d)](_0x5350a9[_0x4749c1(0x1ad)])&&_0x39c02f[_0x4749c1(0x24b)]({'path':_0x2ef3bd+_0x4749c1(0x2c6),'message':_0x4749c1(0x17c)});}function validateOptionalResultVariable(_0x107e60,_0x7e08e2,_0x4e156e){const _0x2f699e=a269_0x1c57b2;if(_0x107e60===undefined||_0x107e60===null||_0x107e60==='')return;if(typeof _0x107e60!=='string'||!VARIABLE_PATTERN[_0x2f699e(0x2dc)](_0x107e60))_0x4e156e[_0x2f699e(0x24b)]({'path':_0x7e08e2,'message':_0x2f699e(0x1ea)});else(RESERVED_RESULT_VARIABLES[_0x2f699e(0x29d)](_0x107e60)||_0x107e60[_0x2f699e(0x262)](_0x2f699e(0x253)))&&_0x4e156e['push']({'path':_0x7e08e2,'message':_0x2f699e(0x18f)+_0x107e60+'.'});}function validateCcConfig(_0xc39b0e,_0x1bf2fd,_0x10c9b9){const _0x5c173e=a269_0x1c57b2;if(_0xc39b0e['cc']===undefined)return;if(!isRecord(_0xc39b0e['cc'])){_0x10c9b9[_0x5c173e(0x24b)]({'path':_0x1bf2fd+_0x5c173e(0x292),'message':_0x5c173e(0x177)});return;}_0xc39b0e[_0x5c173e(0x174)]!==_0x5c173e(0x290)&&_0xc39b0e[_0x5c173e(0x174)]!==_0x5c173e(0x179)&&_0x10c9b9[_0x5c173e(0x24b)]({'path':_0x1bf2fd+'.cc','message':_0x5c173e(0x225)});Object['prototype'][_0x5c173e(0x242)][_0x5c173e(0x2bc)](_0xc39b0e['cc'],_0x5c173e(0x1d4))&&_0x10c9b9[_0x5c173e(0x24b)]({'path':_0x1bf2fd+_0x5c173e(0x28a),'message':UNSUPPORTED_FORM_MESSAGE});const _0x3700ef=_0xc39b0e['cc']['recipientUserIds'];if(!Array[_0x5c173e(0x230)](_0x3700ef)||_0x3700ef['length']===0x0)_0x10c9b9[_0x5c173e(0x24b)]({'path':_0x1bf2fd+_0x5c173e(0x2b5),'message':_0x5c173e(0x215)});else{_0x3700ef[_0x5c173e(0x2cc)]>MAX_CC_RECIPIENTS&&_0x10c9b9[_0x5c173e(0x24b)]({'path':_0x1bf2fd+_0x5c173e(0x2b5),'message':_0x5c173e(0x1a0)+MAX_CC_RECIPIENTS+'\x20users.'});const _0x50c5a4=new Set();_0x3700ef['forEach']((_0xf08839,_0x5ccd44)=>{const _0x5eefe2=_0x5c173e;if(typeof _0xf08839!==_0x5eefe2(0x27d)||_0xf08839[_0x5eefe2(0x2d3)]()==='')_0x10c9b9['push']({'path':_0x1bf2fd+_0x5eefe2(0x1f7)+_0x5ccd44+']','message':_0x5eefe2(0x1fb)});else _0x50c5a4['has'](_0xf08839[_0x5eefe2(0x2d3)]())?_0x10c9b9[_0x5eefe2(0x24b)]({'path':_0x1bf2fd+_0x5eefe2(0x1f7)+_0x5ccd44+']','message':_0x5eefe2(0x1d3)+_0xf08839['trim']()+'.'}):_0x50c5a4[_0x5eefe2(0x26d)](_0xf08839[_0x5eefe2(0x2d3)]());});}validateStringArray(_0xc39b0e['cc'][_0x5c173e(0x25c)],_0x1bf2fd+_0x5c173e(0x297),_0x10c9b9);}function a269_0x40e0(_0x55d8a4,_0x47a25e){_0x55d8a4=_0x55d8a4-0x172;const _0x592307=a269_0x5923();let _0x40e0af=_0x592307[_0x55d8a4];return _0x40e0af;}function validateStringArray(_0x7cc5aa,_0x1efc5a,_0x2c98c6){const _0x9fd95d=a269_0x1c57b2;if(_0x7cc5aa===undefined)return;if(!Array[_0x9fd95d(0x230)](_0x7cc5aa)){_0x2c98c6[_0x9fd95d(0x24b)]({'path':_0x1efc5a,'message':_0x9fd95d(0x29e)});return;}const _0x2292e3=new Set();_0x7cc5aa[_0x9fd95d(0x197)]((_0x2d2642,_0x1cba82)=>{const _0x37e32a=_0x9fd95d;if(typeof _0x2d2642!==_0x37e32a(0x27d)||_0x2d2642[_0x37e32a(0x2d3)]()==='')_0x2c98c6[_0x37e32a(0x24b)]({'path':_0x1efc5a+'['+_0x1cba82+']','message':'value\x20must\x20be\x20a\x20non-empty\x20string.'});else _0x2292e3[_0x37e32a(0x29d)](_0x2d2642[_0x37e32a(0x2d3)]())?_0x2c98c6[_0x37e32a(0x24b)]({'path':_0x1efc5a+'['+_0x1cba82+']','message':_0x37e32a(0x17f)+_0x2d2642[_0x37e32a(0x2d3)]()+'.'}):_0x2292e3[_0x37e32a(0x26d)](_0x2d2642['trim']());});}function validateNotificationConfig(_0x22c18d,_0x1fa62e,_0x2daa21){const _0x42bb99=a269_0x1c57b2;if(!isRecord(_0x22c18d)){_0x2daa21[_0x42bb99(0x24b)]({'path':_0x1fa62e,'message':_0x42bb99(0x1cd)});return;}if(_0x22c18d[_0x42bb99(0x1b0)]!==undefined&&_0x22c18d['version']!==null){if(typeof _0x22c18d[_0x42bb99(0x1b0)]!==_0x42bb99(0x27d))_0x2daa21['push']({'path':_0x1fa62e+'.version','message':'Notification\x20version\x20must\x20be\x20a\x20string.'});else _0x22c18d[_0x42bb99(0x1b0)][_0x42bb99(0x2d3)]()&&_0x22c18d['version'][_0x42bb99(0x2d3)]()!=='v1'&&_0x2daa21[_0x42bb99(0x24b)]({'path':_0x1fa62e+_0x42bb99(0x1d2),'message':_0x42bb99(0x1ed)+_0x22c18d[_0x42bb99(0x1b0)]+'.'});}const _0x2ebf06=requireNotificationString(_0x22c18d[_0x42bb99(0x2c0)],_0x1fa62e+_0x42bb99(0x2d4),_0x42bb99(0x289),_0x2daa21);_0x2ebf06?.[_0x42bb99(0x29a)]('${')&&_0x2daa21[_0x42bb99(0x24b)]({'path':_0x1fa62e+_0x42bb99(0x2d4),'message':_0x42bb99(0x260)});if(_0x22c18d[_0x42bb99(0x2d2)]!==undefined&&_0x22c18d['failurePolicy']!==null){if(typeof _0x22c18d[_0x42bb99(0x2d2)]!==_0x42bb99(0x27d))_0x2daa21[_0x42bb99(0x24b)]({'path':_0x1fa62e+_0x42bb99(0x22b),'message':'failurePolicy\x20must\x20be\x20a\x20string.'});else!NOTIFICATION_FAILURE_POLICIES[_0x42bb99(0x29d)](_0x22c18d['failurePolicy'][_0x42bb99(0x2d3)]()['toUpperCase']())&&_0x2daa21[_0x42bb99(0x24b)]({'path':_0x1fa62e+_0x42bb99(0x22b),'message':_0x42bb99(0x2d9)});}!isRecord(_0x22c18d[_0x42bb99(0x1b8)])?_0x2daa21[_0x42bb99(0x24b)]({'path':_0x1fa62e+_0x42bb99(0x1eb),'message':_0x42bb99(0x28c)}):validateNotificationTemplate(_0x22c18d[_0x42bb99(0x1b8)],_0x1fa62e+_0x42bb99(0x1eb),_0x2daa21),validateNotificationRecipients(_0x22c18d['recipients'],_0x1fa62e+'.recipients',_0x2daa21);}function validateNotificationTemplate(_0x195dd6,_0x158bda,_0x4c6fbe){const _0x46220e=a269_0x1c57b2;for(const _0x3e91db of['title','summary']){const _0x248fe8=requireNotificationString(_0x195dd6[_0x3e91db],_0x158bda+'.'+_0x3e91db,_0x46220e(0x2c3)+_0x3e91db+_0x46220e(0x18b),_0x4c6fbe);if(_0x248fe8)validateNotificationPlaceholders(_0x248fe8,_0x158bda+'.'+_0x3e91db,_0x4c6fbe);}_0x195dd6[_0x46220e(0x244)]!==undefined&&_0x195dd6[_0x46220e(0x244)]!==null&&(typeof _0x195dd6[_0x46220e(0x244)]!=='string'?_0x4c6fbe[_0x46220e(0x24b)]({'path':_0x158bda+_0x46220e(0x2b6),'message':'Notification\x20template.detailMarkdown\x20must\x20be\x20a\x20string.'}):validateNotificationPlaceholders(_0x195dd6[_0x46220e(0x244)],_0x158bda+'.detailMarkdown',_0x4c6fbe)),validateNotificationFacts(_0x195dd6[_0x46220e(0x190)],_0x158bda+_0x46220e(0x23c),_0x4c6fbe),validateNotificationActions(_0x195dd6[_0x46220e(0x200)],_0x158bda+_0x46220e(0x198),_0x4c6fbe);}function a269_0x5923(){const _0x227234=['targetNodeId','waypoint.','isArray','approval_sys_operationType','.url','name','(?![A-Za-z0-9_])','position.','ROLE\x20assignee\x20requires\x20a\x20positive\x20integer\x20roleId.','195606BYuADo','.timeout.enabled','CONDITION\x20node\x20requires\x20exactly\x20one\x20default\x20outgoing\x20edge.','edges','node\x20id\x20must\x20match\x20[A-Za-z_][A-Za-z0-9_]*.','.facts','ALL','message','object','Duplicate\x20resultVariable:\x20','summary','hasOwnProperty','.waypoints','detailMarkdown','flowJson.pageMode','APPROVAL\x20task\x20decision\x20edges\x20must\x20not\x20be\x20default\x20flows.','.\x20This\x20CLI\x20supports\x20only\x20','matchAll','userIds','FIXED\x20assignee\x20requires\x20userIds.','push','flowName\x20is\x20required.','bindDatasetCode','flowJson.nodes.','assignee','Notification\x20template.actions\x20must\x20be\x20an\x20array.','recipientUserIds','.role','approval_sys_','A\x20default\x20flow\x20must\x20use\x20conditionType\x20ALWAYS.','transferCandidates','FIXED','scriptResult','indexOf','source','NaN','Rabetbase\x20FlowConfig','visible','approvalMode','Accepted\x20as\x20legacy\x20input\x20and\x20removed\x20during\x20normalization;\x20other\x20versions\x20are\x20unsupported.','expression','Notification\x20configCode\x20must\x20be\x20a\x20fixed\x20value.','flowType','startsWith','HANDLE','transferCandidates\x20currently\x20supports\x20FIXED\x20only.','pageMode','EXECUTE_BFF','duration\x20value\x20must\x20be\x20a\x20positive\x20integer.','.type','].taskMode','result','.sequential','Notification\x20fact.','add','sequential','edge\x20target\x20is\x20required.','Duplicate\x20BPMN\x20element\x20id:\x20','templateName','SECONDS','edge\x20id\x20must\x20match\x20[A-Za-z_][A-Za-z0-9_]*.','\x20must\x20be\x20a\x20finite\x20number\x20greater\x20than\x20or\x20equal\x20to\x200.','CONDITION\x20non-default\x20edge\x20requires\x20a\x20non-empty\x20expression.','form','EXPRESSION','Flow\x20must\x20contain\x20at\x20least\x20one\x20END\x20node.','taskMode','Every\x20node\x20requires\x20position.x\x20and\x20position.y.','flowJson.startPageId','size','string','startPageId\x20applies\x20only\x20to\x20INDEPENDENT_FLOW\x20with\x20CUSTOM_PAGE.','FORM_FLOW\x20is\x20an\x20approval\x20flow\x20and\x20cannot\x20contain\x20HANDLE\x20tasks;\x20use\x20INDEPENDENT_FLOW\x20for\x20workflows.','pid','END\x20node\x20must\x20not\x20have\x20outgoing\x20edges.','slice',',\x20but\x20node\x20','label','fixed\x20assignee\x20userId\x20must\x20be\x20a\x20non-empty\x20string\x20or\x20positive\x20integer.','Notification\x20recipient.role\x20must\x20be\x20TO,\x20CC,\x20or\x20BCC.','#/$defs/position','config','Notification\x20configCode\x20is\x20required.','.cc.readSources','.conditionType','NOTIFICATION\x20node\x20requires\x20template.','isFinite','get','integer','END','datasetCode\x20must\x20be\x20a\x20string.','.cc','stringify','set','number','START\x20node\x20must\x20not\x20have\x20incoming\x20edges.','.cc.visible','ANY','transfer\x20candidate\x20userId\x20must\x20be\x20a\x20non-empty\x20string\x20or\x20positive\x20integer.','includes','action','.timeout.resultVariable','has','value\x20must\x20be\x20an\x20array.','retryInterval','.value','Node\x20has\x20no\x20incoming\x20edge.','flowJson.nodes','Node\x20cannot\x20reach\x20any\x20END.','Custom\x20form\x20configuration\x20is\x20not\x20supported\x20by\x20this\x20rabetbase\x20version;\x20use\x20a\x20business\x20custom\x20page\x20instead.','Unsupported\x20notification\x20placeholder:\x20','formPermission','.transferCandidates.strategy','formPermissions','Unsupported\x20flowType:\x20','.name','interrupting','metadata','EMAIL','.config','].pageId','Every\x20node\x20requires\x20a\x20non-empty\x20name.','formSchema','waypoints\x20must\x20be\x20an\x20array.','text','role','.cc.recipientUserIds','.detailMarkdown','replace','timeout\x20must\x20be\x20an\x20object.','EXECUTE_BFF\x20timeout\x20must\x20not\x20interrupt\x20the\x20approval\x20task.','node\x20must\x20be\x20an\x20object.','approval_sys_processInstanceId','call','flowKey','Unsupported\x20pageMode:\x20','3911413ZkqOpQ','configCode','position','\x20must\x20be\x20a\x20finite\x20number.','Notification\x20template.','\x20was\x20empty\x20and\x20was\x20removed.','Notification\x20template\x20supports\x20at\x20most\x20','.unit','edges\x20must\x20be\x20an\x20array.','.transferCandidates.userIds','FIXED\x20transferCandidates\x20requires\x20non-empty\x20userIds.','945492FJNsJh','Notification\x20action.url\x20is\x20required.','length','2ZWYFSA','transferCandidates\x20must\x20be\x20an\x20object.','Notification\x20text\x20contains\x20a\x20malformed\x20placeholder.','timeout','HANDLE\x20task\x20timeout\x20only\x20supports\x20EXECUTE_BFF.','failurePolicy','trim','.configCode','flowType\x20is\x20required.','SINGLE','\x20is\x20not\x20part\x20of\x20the\x20portable\x20FlowConfig\x20and\x20was\x20removed.','.assignee.userIds','failurePolicy\x20must\x20be\x20CONTINUE\x20or\x20FAIL.','NOTIFICATION','SINGLE\x20approval\x20supports\x20only\x20one\x20fixed\x20user.','test','toUpperCase','context','.pageId','APPROVAL\x20node\x20requires\x20assignee.','empty_metadata_removed','pageMode\x20applies\x20only\x20to\x20INDEPENDENT_FLOW.','datasetCode','Node\x20has\x20no\x20outgoing\x20edge.','147HrtKJb','schemaVersion','.taskMode','\x20timeout\x20must\x20interrupt\x20the\x20approval\x20task.','Explicit\x20notification\x20recipients\x20require\x20at\x20least\x20one\x20TO.','\x20actions.','type','__rabetbase_local_validation__','flowJson.edges','cc\x20must\x20be\x20an\x20object.','CONDITION\x20default\x20edge\x20must\x20use\x20conditionType\x20ALWAYS.','APPROVAL','DAYS','flowJson.','duration\x20unit\x20must\x20be\x20SECONDS,\x20MINUTES,\x20HOURS,\x20or\x20DAYS.','APPROVAL\x20node\x20requires\x20exactly\x20one\x20REJECTED\x20outgoing\x20edge.','CONTINUE','Duplicate\x20value:\x20','REJECTED','https://lovrabet.com/schema/rabetbase-flow-config.json','3782862MsUGYP','title','APPROVAL\x20node\x20outgoing\x20edges\x20must\x20use\x20APPROVED\x20or\x20REJECTED.','.async.enabled','.position.','PLATFORM_FORM\x20is\x20not\x20supported\x20by\x20this\x20rabetbase\x20version;\x20use\x20INDEPENDENT_FLOW\x20with\x20CUSTOM_PAGE.','formDefinitions','appCode','flowJson\x20must\x20be\x20an\x20object.','\x20is\x20required.','conditionType','Notification\x20recipient.value\x20is\x20required.','approval_sys_datasetCode','Reserved\x20resultVariable:\x20','facts','scriptName','.timeout','Flow\x20must\x20contain\x20exactly\x20one\x20START\x20node.','FORM_FLOW','waypoints','^[A-Za-z_][A-Za-z0-9_]*$','forEach','.actions','.assignee','.async.retryCount','.expression','prototype','.approvalMode','Unsupported\x20approval\x20mode:\x20','START','cc.recipientUserIds\x20supports\x20at\x20most\x20','flowName','.waypoints[','\x5c$&','Notification\x20fact\x20must\x20be\x20an\x20object.','mode','#/$defs/flowEdge','roleId','ALWAYS','Unsupported\x20condition\x20type:\x20','.position','isSafeInteger','url','unit','target','boolean','version','node\x20pageId\x20must\x20be\x20a\x20positive\x20integer.','enabled','waypoint\x20must\x20contain\x20numeric\x20x\x20and\x20y\x20coordinates.','Duplicate\x20edge\x20route:\x20','ROLE','catch','.timeout.interrupting','template','.source','Edge\x20target\x20node\x20not\x20found:\x20','map','some','.tmp','approved','Notification\x20action.url\x20must\x20use\x20http/https\x20or\x20a\x20complete\x20supported\x20placeholder.','timeout.action\x20must\x20be\x20AUTO_APPROVE,\x20AUTO_REJECT,\x20or\x20EXECUTE_BFF.','FAIL','.transferCandidates.userIds[','warnings','async\x20execution\x20is\x20only\x20supported\x20by\x20SCRIPT\x20node.','AUTO_REJECT','Approval\x20flow\x20requires\x20an\x20END\x20node\x20with\x20result\x20','.id','edge\x20must\x20be\x20an\x20object.','96HqgFKV','SCRIPT\x20node\x20requires\x20scriptName.','overwrite','\x20->\x20','NOTIFICATION\x20node\x20requires\x20config.','parse','\x20was\x20empty\x20or\x20used\x20the\x20default\x20','Expression\x20references\x20SCRIPT\x20resultVariable\x20','legacy_field_removed','.version','Duplicate\x20cc\x20recipient\x20userId:\x20','readSources','Node\x20is\x20not\x20reachable\x20from\x20START.','approval_sys_initiatorUserId','utf8','async','delete','every','duration','Unsupported\x20node\x20type:\x20','3593032oeLddZ','CONDITION\x20default\x20edge\x20must\x20not\x20define\x20expression.','flowCode','flowJson','.async','SCRIPT','CONDITION','timeout.enabled\x20must\x20be\x20a\x20boolean.','.assignee.strategy','40qqvWTU','array','#/$defs/userId','Notification\x20recipient.type\x20is\x20required.','resultVariable\x20must\x20match\x20[A-Za-z_][A-Za-z0-9_]*.','.template','HANDLE\x20task\x20requires\x20exactly\x20one\x20outgoing\x20edge.','Unsupported\x20notification\x20version:\x20','.target','(?<![A-Za-z0-9_])','retryCount','USER','APPROVED','3186873EUfcGi','flowJson.edges[','defaultFlow','isInteger','.cc.recipientUserIds[','.transferCandidates','\x20facts.','BCC','cc\x20recipient\x20userId\x20must\x20be\x20a\x20non-empty\x20string.','defaultFlow\x20must\x20be\x20a\x20boolean.','CONDITION\x20non-default\x20edge\x20must\x20use\x20conditionType\x20EXPRESSION.','.async.retryInterval','EXECUTE_BFF\x20timeout\x20requires\x20scriptName.','actions','sourceNodeId','timeout\x20is\x20only\x20supported\x20by\x20APPROVAL\x20node.','MINUTES','.timeout.duration','A\x20default\x20flow\x20must\x20not\x20have\x20an\x20expression.','Notification\x20recipients\x20must\x20be\x20an\x20array.','pageId','30KwLyWl','#/$defs/flowNode','Notification\x20recipient.type\x20must\x20be\x20USER,\x20ROLE,\x20or\x20EMAIL.','approval_sys_appCode','filter','resultVariable','.text','AUTO_APPROVE','variables','.scriptName','value','edge\x20source\x20is\x20required.','nodes','cc.recipientUserIds\x20must\x20be\x20a\x20non-empty\x20array.','Unsupported\x20schemaVersion:\x20','flowJson.nodes[','CUSTOM_PAGE','.assignee.userIds[','assignee.strategy\x20must\x20be\x20FIXED\x20or\x20ROLE.','edge\x20name\x20must\x20be\x20a\x20string.','Notification\x20recipient.role\x20must\x20be\x20a\x20string.','PLATFORM_FORM','findIndex','async\x20must\x20be\x20an\x20object.','keys','INDEPENDENT_FLOW\x20cannot\x20bind\x20pageId.','147793yBakAE','.defaultFlow','startPageId','Default\x20cc\x20is\x20only\x20supported\x20by\x20APPROVAL\x20or\x20END\x20node.','node\x20pageId\x20applies\x20only\x20to\x20INDEPENDENT_FLOW\x20with\x20CUSTOM_PAGE.','Notification\x20recipient\x20must\x20be\x20an\x20object.','flowDesc','strategy','INDEPENDENT_FLOW','.failurePolicy','approval.simple-flow.v1','No\x20END\x20node\x20is\x20reachable\x20from\x20START.'];a269_0x5923=function(){return _0x227234;};return a269_0x5923();}function validateNotificationFacts(_0x193d1e,_0x436896,_0x24bf57){const _0x1c34a5=a269_0x1c57b2;if(_0x193d1e===undefined||_0x193d1e===null)return;if(!Array[_0x1c34a5(0x230)](_0x193d1e)){_0x24bf57['push']({'path':_0x436896,'message':'Notification\x20template.facts\x20must\x20be\x20an\x20array.'});return;}_0x193d1e[_0x1c34a5(0x2cc)]>MAX_NOTIFICATION_FACTS&&_0x24bf57[_0x1c34a5(0x24b)]({'path':_0x436896,'message':'Notification\x20template\x20supports\x20at\x20most\x20'+MAX_NOTIFICATION_FACTS+_0x1c34a5(0x1f9)}),_0x193d1e[_0x1c34a5(0x197)]((_0x4239d0,_0x942ab0)=>{const _0x7b530a=_0x1c34a5,_0x135c73=_0x436896+'['+_0x942ab0+']';if(!isRecord(_0x4239d0)){_0x24bf57[_0x7b530a(0x24b)]({'path':_0x135c73,'message':_0x7b530a(0x1a4)});return;}for(const _0x387943 of[_0x7b530a(0x284),'value']){const _0x68426e=requireNotificationString(_0x4239d0[_0x387943],_0x135c73+'.'+_0x387943,_0x7b530a(0x26c)+_0x387943+'\x20is\x20required.',_0x24bf57);_0x68426e&&validateNotificationPlaceholders(_0x68426e,_0x135c73+'.'+_0x387943,_0x24bf57);}});}function validateNotificationActions(_0x28e8ef,_0x2d9bbb,_0x54a3ff){const _0x188794=a269_0x1c57b2;if(_0x28e8ef===undefined||_0x28e8ef===null)return;if(!Array['isArray'](_0x28e8ef)){_0x54a3ff[_0x188794(0x24b)]({'path':_0x2d9bbb,'message':_0x188794(0x250)});return;}_0x28e8ef['length']>MAX_NOTIFICATION_ACTIONS&&_0x54a3ff['push']({'path':_0x2d9bbb,'message':_0x188794(0x2c5)+MAX_NOTIFICATION_ACTIONS+_0x188794(0x173)}),_0x28e8ef[_0x188794(0x197)]((_0x394846,_0x36e0f4)=>{const _0x23b56d=_0x188794,_0x3a99b2=_0x2d9bbb+'['+_0x36e0f4+']';if(!isRecord(_0x394846)){_0x54a3ff[_0x23b56d(0x24b)]({'path':_0x3a99b2,'message':'Notification\x20action\x20must\x20be\x20an\x20object.'});return;}const _0x493a10=requireNotificationString(_0x394846[_0x23b56d(0x2b3)],_0x3a99b2+_0x23b56d(0x20e),'Notification\x20action.text\x20is\x20required.',_0x54a3ff);if(_0x493a10)validateNotificationPlaceholders(_0x493a10,_0x3a99b2+_0x23b56d(0x20e),_0x54a3ff);const _0x2f0f0a=requireNotificationString(_0x394846[_0x23b56d(0x1ac)],_0x3a99b2+_0x23b56d(0x232),_0x23b56d(0x2cb),_0x54a3ff);if(!_0x2f0f0a)return;validateNotificationPlaceholders(_0x2f0f0a,_0x3a99b2+_0x23b56d(0x232),_0x54a3ff),!/^https?:\/\//i['test'](_0x2f0f0a)&&!NOTIFICATION_ACTION_URL_PLACEHOLDER_PATTERN[_0x23b56d(0x2dc)](_0x2f0f0a)&&_0x54a3ff[_0x23b56d(0x24b)]({'path':_0x3a99b2+_0x23b56d(0x232),'message':_0x23b56d(0x1bf)});});}function validateNotificationRecipients(_0x1d716d,_0x3b01e2,_0x1bac25){const _0x5e21c0=a269_0x1c57b2;if(_0x1d716d===undefined||_0x1d716d===null)return;if(!Array[_0x5e21c0(0x230)](_0x1d716d)){_0x1bac25[_0x5e21c0(0x24b)]({'path':_0x3b01e2,'message':_0x5e21c0(0x206)});return;}let _0x33f0f6=![];_0x1d716d[_0x5e21c0(0x197)]((_0xd61705,_0xa94566)=>{const _0x13fadf=_0x5e21c0,_0x254aff=_0x3b01e2+'['+_0xa94566+']';if(!isRecord(_0xd61705)){_0x1bac25[_0x13fadf(0x24b)]({'path':_0x254aff,'message':_0x13fadf(0x227)});return;}const _0x50c5c2=requireNotificationString(_0xd61705[_0x13fadf(0x174)],_0x254aff+_0x13fadf(0x268),_0x13fadf(0x1e9),_0x1bac25);_0x50c5c2&&!NOTIFICATION_RECIPIENT_TYPES[_0x13fadf(0x29d)](_0x50c5c2[_0x13fadf(0x2dd)]())&&_0x1bac25[_0x13fadf(0x24b)]({'path':_0x254aff+_0x13fadf(0x268),'message':_0x13fadf(0x20a)});let _0x265288='TO';_0xd61705['role']!==undefined&&_0xd61705[_0x13fadf(0x2b4)]!==null&&(typeof _0xd61705[_0x13fadf(0x2b4)]!==_0x13fadf(0x27d)?(_0x1bac25[_0x13fadf(0x24b)]({'path':_0x254aff+_0x13fadf(0x252),'message':_0x13fadf(0x21c)}),_0x265288=''):(_0x265288=_0xd61705[_0x13fadf(0x2b4)]['trim']()[_0x13fadf(0x2dd)](),!NOTIFICATION_RECIPIENT_ROLES[_0x13fadf(0x29d)](_0x265288)&&_0x1bac25[_0x13fadf(0x24b)]({'path':_0x254aff+_0x13fadf(0x252),'message':_0x13fadf(0x286)})));if(_0x265288==='TO')_0x33f0f6=!![];const _0x5f22b8=requireNotificationString(_0xd61705[_0x13fadf(0x212)],_0x254aff+_0x13fadf(0x2a0),_0x13fadf(0x18d),_0x1bac25);_0x5f22b8&&validateNotificationPlaceholders(_0x5f22b8,_0x254aff+_0x13fadf(0x2a0),_0x1bac25);}),_0x1d716d[_0x5e21c0(0x2cc)]>0x0&&!_0x33f0f6&&_0x1bac25[_0x5e21c0(0x24b)]({'path':_0x3b01e2,'message':_0x5e21c0(0x172)});}function requireNotificationString(_0x3fac3a,_0x33aaba,_0x644aec,_0x1f29c5){const _0x1f86ba=a269_0x1c57b2;if(typeof _0x3fac3a!==_0x1f86ba(0x27d)||_0x3fac3a['trim']()==='')return _0x1f29c5[_0x1f86ba(0x24b)]({'path':_0x33aaba,'message':_0x644aec}),undefined;return _0x3fac3a[_0x1f86ba(0x2d3)]();}function validateNotificationPlaceholders(_0x390db3,_0x2adb53,_0x4d348c){const _0x32b36d=a269_0x1c57b2;for(const _0x1dce13 of _0x390db3[_0x32b36d(0x248)](NOTIFICATION_PLACEHOLDER_PATTERN)){const _0x434281=_0x1dce13[0x1]?.['trim']()??'',_0x3d5488=_0x434281[_0x32b36d(0x258)]('.'),_0x5e54b2=_0x3d5488>=0x0?_0x434281[_0x32b36d(0x282)](0x0,_0x3d5488):_0x434281,_0x21e2e7=_0x3d5488>=0x0?_0x434281[_0x32b36d(0x282)](_0x3d5488+0x1)[_0x32b36d(0x2d3)]():'';(!['event',_0x32b36d(0x2de),_0x32b36d(0x210)][_0x32b36d(0x29a)](_0x5e54b2)||_0x21e2e7==='')&&_0x4d348c['push']({'path':_0x2adb53,'message':_0x32b36d(0x2a5)+_0x1dce13[0x0]+'.'});}_0x390db3[_0x32b36d(0x2b7)](NOTIFICATION_PLACEHOLDER_PATTERN,'')[_0x32b36d(0x29a)]('${')&&_0x4d348c['push']({'path':_0x2adb53,'message':_0x32b36d(0x2cf)});}function validateEdge(_0x161b0c,_0x5067e8,_0x3b0508){const _0x22e370=a269_0x1c57b2;_0x161b0c[_0x22e370(0x233)]!==undefined&&typeof _0x161b0c[_0x22e370(0x233)]!==_0x22e370(0x27d)&&_0x3b0508[_0x22e370(0x24b)]({'path':_0x5067e8+'.name','message':_0x22e370(0x21b)}),_0x161b0c[_0x22e370(0x1f5)]!==undefined&&typeof _0x161b0c['defaultFlow']!==_0x22e370(0x1af)&&_0x3b0508[_0x22e370(0x24b)]({'path':_0x5067e8+'.defaultFlow','message':_0x22e370(0x1fc)}),_0x161b0c['waypoints']!==undefined&&(!Array[_0x22e370(0x230)](_0x161b0c[_0x22e370(0x195)])?_0x3b0508[_0x22e370(0x24b)]({'path':_0x5067e8+_0x22e370(0x243),'message':_0x22e370(0x2b2)}):_0x161b0c[_0x22e370(0x195)][_0x22e370(0x197)]((_0x54a93e,_0x179b90)=>{const _0x4afbfc=_0x22e370;if(!isRecord(_0x54a93e)){_0x3b0508['push']({'path':_0x5067e8+'.waypoints['+_0x179b90+']','message':_0x4afbfc(0x1b3)});return;}for(const _0x5f531f of['x','y']){const _0x502655=_0x54a93e[_0x5f531f];(typeof _0x502655!==_0x4afbfc(0x295)||!Number[_0x4afbfc(0x28d)](_0x502655))&&_0x3b0508['push']({'path':_0x5067e8+_0x4afbfc(0x1a2)+_0x179b90+'].'+_0x5f531f,'message':_0x4afbfc(0x22f)+_0x5f531f+_0x4afbfc(0x2c2)});}})),_0x161b0c[_0x22e370(0x18c)]!==undefined&&!CONDITION_TYPES[_0x22e370(0x29d)](_0x161b0c[_0x22e370(0x18c)])&&_0x3b0508[_0x22e370(0x24b)]({'path':_0x5067e8+'.conditionType','message':_0x22e370(0x1a9)+String(_0x161b0c['conditionType'])+'.'}),_0x161b0c[_0x22e370(0x18c)]===_0x22e370(0x277)&&(typeof _0x161b0c[_0x22e370(0x25f)]!==_0x22e370(0x27d)||_0x161b0c[_0x22e370(0x25f)]['trim']()==='')&&_0x3b0508[_0x22e370(0x24b)]({'path':_0x5067e8+_0x22e370(0x19b),'message':'EXPRESSION\x20edge\x20requires\x20expression.'}),_0x161b0c[_0x22e370(0x1f5)]===!![]&&_0x161b0c[_0x22e370(0x18c)]!==_0x22e370(0x1a8)&&_0x3b0508[_0x22e370(0x24b)]({'path':_0x5067e8+_0x22e370(0x223),'message':_0x22e370(0x254)}),_0x161b0c[_0x22e370(0x1f5)]===!![]&&typeof _0x161b0c[_0x22e370(0x25f)]===_0x22e370(0x27d)&&_0x161b0c[_0x22e370(0x25f)]['trim']()!==''&&_0x3b0508[_0x22e370(0x24b)]({'path':_0x5067e8+_0x22e370(0x19b),'message':_0x22e370(0x205)});}function validateGraphShape(_0x5acdec,_0x1eec3a,_0x50793b,_0x213d34,_0x5de0ae,_0x2b77c1,_0x4a272b){const _0x2412e2=a269_0x1c57b2;for(const [_0xfb24c1,_0x24a7b2]of _0x5acdec){const _0x18a559=_0x5de0ae[_0x2412e2(0x28e)](_0xfb24c1)??[],_0xdfeda3=_0x213d34['get'](_0xfb24c1)??[];_0x24a7b2[_0x2412e2(0x174)]!==_0x2412e2(0x19f)&&_0x18a559['length']===0x0&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2412e2(0x24e)+_0xfb24c1,'message':_0x2412e2(0x2a1)});_0x24a7b2['type']!=='END'&&_0xdfeda3['length']===0x0&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2412e2(0x24e)+_0xfb24c1,'message':_0x2412e2(0x2e4)});_0x24a7b2['type']===_0x2412e2(0x19f)&&_0x18a559[_0x2412e2(0x2cc)]>0x0&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2412e2(0x24e)+_0xfb24c1,'message':_0x2412e2(0x296)});_0x24a7b2[_0x2412e2(0x174)]==='END'&&_0xdfeda3['length']>0x0&&_0x4a272b['push']({'path':_0x2412e2(0x24e)+_0xfb24c1,'message':_0x2412e2(0x281)});if(_0x24a7b2[_0x2412e2(0x174)]===_0x2412e2(0x1e3)){_0xdfeda3[_0x2412e2(0x2cc)]<0x2&&_0x4a272b[_0x2412e2(0x24b)]({'path':'flowJson.nodes.'+_0xfb24c1,'message':'CONDITION\x20node\x20requires\x20at\x20least\x20two\x20outgoing\x20edges.'});const _0xad5e62=_0xdfeda3['filter'](_0x47d16d=>_0x47d16d[_0x2412e2(0x1f5)]===!![]);_0xad5e62[_0x2412e2(0x2cc)]!==0x1&&_0x4a272b[_0x2412e2(0x24b)]({'path':'flowJson.nodes.'+_0xfb24c1,'message':_0x2412e2(0x239)});if(_0xad5e62[_0x2412e2(0x2cc)]===0x1){const _0x838a10=_0xad5e62[0x0],_0x553b1d=_0x2b77c1[_0x2412e2(0x28e)](_0x838a10)??'flowJson.edges';_0x838a10[_0x2412e2(0x18c)]!==_0x2412e2(0x1a8)&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x553b1d+_0x2412e2(0x28b),'message':_0x2412e2(0x178)});_0x838a10['expression']!==undefined&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x553b1d+_0x2412e2(0x19b),'message':_0x2412e2(0x1de)});for(const _0x57aa05 of _0xdfeda3){if(_0x57aa05===_0x838a10)continue;const _0x123786=_0x2b77c1[_0x2412e2(0x28e)](_0x57aa05)??'flowJson.edges';if(_0x57aa05[_0x2412e2(0x18c)]!=='EXPRESSION')_0x4a272b[_0x2412e2(0x24b)]({'path':_0x123786+'.conditionType','message':_0x2412e2(0x1fd)});else(typeof _0x57aa05[_0x2412e2(0x25f)]!==_0x2412e2(0x27d)||_0x57aa05[_0x2412e2(0x25f)][_0x2412e2(0x2d3)]()==='')&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x123786+'.expression','message':_0x2412e2(0x275)});}}}if(_0x24a7b2[_0x2412e2(0x174)]===_0x2412e2(0x179)&&(_0x24a7b2['taskMode']??_0x2412e2(0x179))===_0x2412e2(0x263)){if(_0xdfeda3[_0x2412e2(0x2cc)]!==0x1)_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2412e2(0x24e)+_0xfb24c1,'message':_0x2412e2(0x1ec)});else{const _0x409820=_0xdfeda3[0x0];((_0x409820[_0x2412e2(0x18c)]??_0x2412e2(0x1a8))!==_0x2412e2(0x1a8)||_0x409820[_0x2412e2(0x1f5)]===!![]||typeof _0x409820[_0x2412e2(0x25f)]===_0x2412e2(0x27d)&&_0x409820[_0x2412e2(0x25f)][_0x2412e2(0x2d3)]()!=='')&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2b77c1[_0x2412e2(0x28e)](_0x409820)??'flowJson.edges','message':'HANDLE\x20task\x20outgoing\x20edge\x20must\x20use\x20ALWAYS\x20without\x20defaultFlow\x20or\x20expression.'});}}else{if(_0x24a7b2['type']==='APPROVAL'){const _0xf7b05a=_0xdfeda3[_0x2412e2(0x1bb)](_0x443087=>_0x443087['conditionType']??_0x2412e2(0x1a8)),_0x1bbde3=_0xf7b05a[_0x2412e2(0x20c)](_0x48d85f=>_0x48d85f!==_0x2412e2(0x1f2)&&_0x48d85f!==_0x2412e2(0x180));_0x1bbde3[_0x2412e2(0x2cc)]>0x0&&_0x4a272b['push']({'path':'flowJson.nodes.'+_0xfb24c1,'message':_0x2412e2(0x184)}),_0xf7b05a['filter'](_0x546bb2=>_0x546bb2===_0x2412e2(0x1f2))[_0x2412e2(0x2cc)]!==0x1&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2412e2(0x24e)+_0xfb24c1,'message':'APPROVAL\x20node\x20requires\x20exactly\x20one\x20APPROVED\x20outgoing\x20edge.'}),_0xf7b05a[_0x2412e2(0x20c)](_0x2e18ac=>_0x2e18ac===_0x2412e2(0x180))[_0x2412e2(0x2cc)]!==0x1&&_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2412e2(0x24e)+_0xfb24c1,'message':_0x2412e2(0x17d)}),_0xdfeda3['some'](_0x58e39a=>_0x58e39a[_0x2412e2(0x1f5)]===!![])&&_0x4a272b['push']({'path':'flowJson.nodes.'+_0xfb24c1,'message':_0x2412e2(0x246)});}}}const _0x64e4da=new Set(),_0x1ff0d6=_0x4acdc4=>{const _0x2c8a97=_0x2412e2;if(_0x64e4da[_0x2c8a97(0x29d)](_0x4acdc4))return;_0x64e4da['add'](_0x4acdc4);for(const _0x1f91d6 of _0x213d34[_0x2c8a97(0x28e)](_0x4acdc4)??[]){const _0x338b4c=resolveEdgeEndpoint(_0x1f91d6[_0x2c8a97(0x1ae)],_0x1f91d6[_0x2c8a97(0x22e)]);if(_0x338b4c&&_0x5acdec[_0x2c8a97(0x29d)](_0x338b4c))_0x1ff0d6(_0x338b4c);}};_0x1ff0d6(_0x1eec3a);for(const _0x4c5e1c of _0x5acdec[_0x2412e2(0x220)]()){!_0x64e4da['has'](_0x4c5e1c)&&_0x4a272b['push']({'path':_0x2412e2(0x24e)+_0x4c5e1c,'message':_0x2412e2(0x1d5)});}const _0x5be168=_0x50793b[_0x2412e2(0x1bc)](_0x3f587f=>_0x64e4da[_0x2412e2(0x29d)](_0x3f587f));if(!_0x5be168){_0x4a272b[_0x2412e2(0x24b)]({'path':_0x2412e2(0x176),'message':_0x2412e2(0x22d)});return;}const _0x2cbd29=new Set(),_0x2b5837=_0x57e996=>{const _0x29972e=_0x2412e2;if(_0x2cbd29[_0x29972e(0x29d)](_0x57e996))return;_0x2cbd29[_0x29972e(0x26d)](_0x57e996);for(const _0x1da578 of _0x5de0ae['get'](_0x57e996)??[]){const _0x25e328=resolveEdgeEndpoint(_0x1da578['source'],_0x1da578[_0x29972e(0x201)]);if(_0x25e328&&_0x5acdec[_0x29972e(0x29d)](_0x25e328))_0x2b5837(_0x25e328);}};for(const _0x17be6d of _0x50793b){if(_0x5acdec[_0x2412e2(0x29d)](_0x17be6d))_0x2b5837(_0x17be6d);}for(const _0x5100f7 of _0x64e4da){!_0x2cbd29[_0x2412e2(0x29d)](_0x5100f7)&&_0x4a272b['push']({'path':_0x2412e2(0x24e)+_0x5100f7,'message':_0x2412e2(0x2a3)});}}function validateApprovalResults(_0x272e45,_0xa56415,_0x5adb93,_0x11e2de){const _0xfe57f4=a269_0x1c57b2;if(_0xa56415===0x0)return;const _0xd1e671=new Set(_0x5adb93[_0xfe57f4(0x1bb)](_0x4c570d=>_0x272e45['get'](_0x4c570d)?.[_0xfe57f4(0x26a)])[_0xfe57f4(0x20c)](_0x1e6a66=>typeof _0x1e6a66===_0xfe57f4(0x27d)));for(const _0x31c5f0 of[_0xfe57f4(0x1f2),_0xfe57f4(0x180)]){!_0xd1e671[_0xfe57f4(0x29d)](_0x31c5f0)&&_0x11e2de['push']({'path':_0xfe57f4(0x2a2),'message':_0xfe57f4(0x1c6)+_0x31c5f0+'.'});}}function validateScriptResultReferences(_0x1a0a00,_0xb3b1db,_0x1148d9,_0x5a3336,_0x25f1b5,_0x8027d0,_0x27fe15){const _0x3b26ba=a269_0x1c57b2;if(_0x8027d0[_0x3b26ba(0x27c)]===0x0)return;const _0x1f71b7=new Set(),_0x13aa02=_0x57e2d2=>{const _0x3b6d7c=_0x3b26ba;if(!_0x1f71b7['has'](_0x57e2d2)&&_0x1a0a00[_0x3b6d7c(0x29d)](_0x57e2d2)){_0x1f71b7[_0x3b6d7c(0x26d)](_0x57e2d2);for(const _0x5d62ab of _0x1148d9[_0x3b6d7c(0x28e)](_0x57e2d2)??[]){const _0x3abf83=resolveEdgeEndpoint(_0x5d62ab[_0x3b6d7c(0x1ae)],_0x5d62ab[_0x3b6d7c(0x22e)]);if(_0x3abf83)_0x13aa02(_0x3abf83);}}};_0x13aa02(_0xb3b1db);const _0x49e5f4=new Map();for(const _0x3000fd of _0x1f71b7){_0x49e5f4[_0x3b26ba(0x294)](_0x3000fd,_0x3000fd===_0xb3b1db?new Set([_0xb3b1db]):new Set(_0x1f71b7));}let _0x3fa5ec=!![];while(_0x3fa5ec){_0x3fa5ec=![];for(const _0x1c4e02 of _0x1f71b7){if(_0x1c4e02===_0xb3b1db)continue;const _0x3bdcdd=(_0x5a3336[_0x3b26ba(0x28e)](_0x1c4e02)??[])['map'](_0x457635=>resolveEdgeEndpoint(_0x457635[_0x3b26ba(0x259)],_0x457635[_0x3b26ba(0x201)]))[_0x3b26ba(0x20c)](_0x533e9d=>Boolean(_0x533e9d&&_0x1f71b7[_0x3b26ba(0x29d)](_0x533e9d)));if(_0x3bdcdd[_0x3b26ba(0x2cc)]===0x0)continue;const _0x13020b=new Set(_0x49e5f4[_0x3b26ba(0x28e)](_0x3bdcdd[0x0])??[]);for(const _0x1cf6fb of _0x3bdcdd[_0x3b26ba(0x282)](0x1)){const _0x36fd72=_0x49e5f4[_0x3b26ba(0x28e)](_0x1cf6fb)??new Set();for(const _0x5d87aa of _0x13020b){if(!_0x36fd72[_0x3b26ba(0x29d)](_0x5d87aa))_0x13020b[_0x3b26ba(0x1d9)](_0x5d87aa);}}_0x13020b['add'](_0x1c4e02);const _0x4ca209=_0x49e5f4[_0x3b26ba(0x28e)](_0x1c4e02);!setsEqual(_0x4ca209,_0x13020b)&&(_0x49e5f4[_0x3b26ba(0x294)](_0x1c4e02,_0x13020b),_0x3fa5ec=!![]);}}for(const [_0x5490a3,_0x547943]of _0x1148d9){const _0x16e8a8=_0x49e5f4[_0x3b26ba(0x28e)](_0x5490a3);if(!_0x16e8a8)continue;for(const _0x211c63 of _0x547943){if(_0x211c63[_0x3b26ba(0x18c)]!==_0x3b26ba(0x277)||typeof _0x211c63[_0x3b26ba(0x25f)]!==_0x3b26ba(0x27d))continue;for(const [_0x4eefe3,_0x43e8db]of _0x8027d0){expressionReferencesVariable(_0x211c63[_0x3b26ba(0x25f)],_0x4eefe3)&&!_0x16e8a8[_0x3b26ba(0x29d)](_0x43e8db)&&_0x27fe15['push']({'path':(_0x25f1b5[_0x3b26ba(0x28e)](_0x211c63)??_0x3b26ba(0x176))+_0x3b26ba(0x19b),'message':_0x3b26ba(0x1d0)+_0x4eefe3+_0x3b26ba(0x283)+_0x43e8db+'\x20is\x20not\x20on\x20every\x20upstream\x20path\x20to\x20'+_0x5490a3+'.'});}}}}function expressionReferencesVariable(_0x15b614,_0x1404d1){const _0x2812bb=a269_0x1c57b2,_0x211b1c=_0x1404d1[_0x2812bb(0x2b7)](/[.*+?^${}()|[\]\\]/g,_0x2812bb(0x1a3));return new RegExp(_0x2812bb(0x1ef)+_0x211b1c+_0x2812bb(0x234))[_0x2812bb(0x2dc)](_0x15b614);}function resolveEffectiveResultVariable(_0x2f22e5,_0x294737){const _0x25a831=a269_0x1c57b2;if(_0x2f22e5===undefined||_0x2f22e5===null||_0x294737&&_0x2f22e5==='')return DEFAULT_SCRIPT_RESULT_VARIABLE;if(typeof _0x2f22e5!==_0x25a831(0x27d)||!VARIABLE_PATTERN[_0x25a831(0x2dc)](_0x2f22e5)||RESERVED_RESULT_VARIABLES[_0x25a831(0x29d)](_0x2f22e5)||_0x2f22e5['startsWith'](_0x25a831(0x253)))return undefined;return _0x2f22e5;}function registerResultVariableOwner(_0x18c643,_0x373c17,_0x2aa6c4,_0x523a40){const _0x4bb8d0=a269_0x1c57b2;if(_0x18c643[_0x4bb8d0(0x29d)](_0x373c17)){_0x523a40[_0x4bb8d0(0x24b)]({'path':'flowJson.nodes','message':_0x4bb8d0(0x240)+_0x373c17+'.'});return;}_0x18c643[_0x4bb8d0(0x294)](_0x373c17,_0x2aa6c4);}function setsEqual(_0x1d5e57,_0x80aefe){const _0x1187ce=a269_0x1c57b2;return _0x1d5e57[_0x1187ce(0x27c)]===_0x80aefe[_0x1187ce(0x27c)]&&[..._0x1d5e57][_0x1187ce(0x1da)](_0x2b357b=>_0x80aefe[_0x1187ce(0x29d)](_0x2b357b));}function isValidUserId(_0x3889ba){const _0x442fa2=a269_0x1c57b2;if(typeof _0x3889ba===_0x442fa2(0x27d))return _0x3889ba['trim']()[_0x442fa2(0x2cc)]>0x0;return Number[_0x442fa2(0x1ab)](_0x3889ba)&&Number(_0x3889ba)>0x0;}function resolveEdgeEndpoint(_0x14e724,_0x3ab808){const _0x46ede3=a269_0x1c57b2;if(typeof _0x14e724===_0x46ede3(0x27d)&&_0x14e724[_0x46ede3(0x2d3)]())return _0x14e724[_0x46ede3(0x2d3)]();if(typeof _0x3ab808==='string'&&_0x3ab808[_0x46ede3(0x2d3)]())return _0x3ab808[_0x46ede3(0x2d3)]();return undefined;}function removeEmptyMetadata(_0x3914c2,_0x30586a,_0x1a46e5,_0x5b97e4){const _0x3dcc45=a269_0x1c57b2;if(Array[_0x3dcc45(0x230)](_0x3914c2)){_0x3914c2[_0x3dcc45(0x197)]((_0x685ba,_0x5e32b9)=>removeEmptyMetadata(_0x685ba,_0x30586a+'['+_0x5e32b9+']',_0x1a46e5,_0x5b97e4));return;}if(!isRecord(_0x3914c2))return;for(const [_0x166a86,_0x353d24]of Object['entries'](_0x3914c2)){const _0x15d4e9=_0x30586a+'.'+_0x166a86;if(_0x166a86===_0x3dcc45(0x2ac)&&isEmptyJsonValue(_0x353d24)){delete _0x3914c2[_0x166a86],_0x5b97e4[_0x3dcc45(0x24b)](_0x15d4e9),_0x1a46e5[_0x3dcc45(0x24b)]({'code':_0x3dcc45(0x2e1),'path':_0x15d4e9,'message':_0x15d4e9+_0x3dcc45(0x2c4)});continue;}removeEmptyMetadata(_0x353d24,_0x15d4e9,_0x1a46e5,_0x5b97e4);}}function isEmptyJsonValue(_0x183ab0){const _0x306d2e=a269_0x1c57b2;if(_0x183ab0===null||_0x183ab0===undefined)return!![];if(typeof _0x183ab0===_0x306d2e(0x27d))return _0x183ab0[_0x306d2e(0x2d3)]()==='';if(Array[_0x306d2e(0x230)](_0x183ab0))return _0x183ab0['length']===0x0;return isRecord(_0x183ab0)&&Object[_0x306d2e(0x220)](_0x183ab0)[_0x306d2e(0x2cc)]===0x0;}function isRecord(_0x20e523){const _0x221c54=a269_0x1c57b2;return typeof _0x20e523===_0x221c54(0x23f)&&_0x20e523!==null&&!Array[_0x221c54(0x230)](_0x20e523);}function cloneJsonValue(_0x2f6335){const _0x3a74be=a269_0x1c57b2;return JSON[_0x3a74be(0x1ce)](JSON[_0x3a74be(0x293)](_0x2f6335));}export async function readFlowConfigFile(_0x18ef00){const _0x2b3c25=a269_0x1c57b2,_0x7a9706=await readFile(resolve(_0x18ef00),_0x2b3c25(0x1d7));return JSON['parse'](_0x7a9706);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a270_0x1f8aad=a270_0x5451;(function(_0x5cb298,_0x36e845){const _0x3dc9df=a270_0x5451,_0x1f0407=_0x5cb298();while(!![]){try{const _0x480d2c=parseInt(_0x3dc9df(0xb2))/0x1+parseInt(_0x3dc9df(0xb7))/0x2*(-parseInt(_0x3dc9df(0xb5))/0x3)+-parseInt(_0x3dc9df(0xc6))/0x4*(parseInt(_0x3dc9df(0xd6))/0x5)+parseInt(_0x3dc9df(0xb0))/0x6*(-parseInt(_0x3dc9df(0xde))/0x7)+-parseInt(_0x3dc9df(0xaf))/0x8+-parseInt(_0x3dc9df(0xd4))/0x9+parseInt(_0x3dc9df(0xe1))/0xa;if(_0x480d2c===_0x36e845)break;else _0x1f0407['push'](_0x1f0407['shift']());}catch(_0x1cb717){_0x1f0407['push'](_0x1f0407['shift']());}}}(a270_0x4101,0x476f6));import{randomUUID}from'node:crypto';import{mkdir,readFile,rename,stat,unlink,writeFile}from'node:fs/promises';import{dirname,resolve}from'node:path';import{TextDecoder}from'node:util';import{findProjectRootDirectory}from'../../context.js';function a270_0x4101(){const _0x12ed40=['decode','Cannot\x20read\x20Instant\x20API\x20policy\x20file:\x20','Run\x20`rabetbase\x20instant-api-policy\x20init`\x20or\x20`rabetbase\x20instant-api-policy\x20pull`\x20first.','instant_api_policy_version_invalid','instant_api_policy_file_exists','instant_api_policy_file_invalid','catch','string','Instant\x20API\x20policy\x20file\x20exceeds\x20the\x201\x20MiB\x20CLI\x20limit.','1218735voDxuK','rules','1950565EVxYVH','appCode','Instant\x20API\x20policy\x20file\x20was\x20created\x20concurrently:\x20','policyFilePath','object','Policy\x20rules\x20must\x20be\x20an\x20array\x20or\x20null.','byteLength','length','1071MpEKGU','pid','created','15188170WxRzfk','size','ENOENT','Review\x20local\x20changes,\x20then\x20rerun\x20with\x20--force\x20--yes\x20if\x20replacement\x20is\x20intended.','EEXIST','code','Instant\x20API\x20policy\x20file\x20is\x20not\x20valid\x20JSON:\x20','instant_api_policy_json_invalid','instant_api_policy_app_code_invalid','parse','3583104hLaWDd','4116Kwtdjv','Instant\x20API\x20policy\x20file\x20does\x20not\x20exist:\x20','386541UaDRfh','force','isArray','1603158xnXtNe','utf-8','2OtjsGh','.rabetbase/instant-api-policy','Policy\x20defaults.instantApi\x20is\x20required.','instant_api_policy_file_unreadable','Cannot\x20replace\x20Instant\x20API\x20policy\x20file:\x20','instant_api_policy_app_code_mismatch','stringify','version\x20is\x20the\x20JSON\x20schema\x20version;\x20published\x20history\x20uses\x20the\x20separate\x20revision\x20field.','instant_api_policy_defaults_invalid','.tmp','includes','instant_api_policy_file_missing','Instant\x20API\x20policy\x20file\x20is\x20not\x20valid\x20UTF-8:\x20','version','instant_api_policy_file_unwritable','4TmVbEZ','Cannot\x20write\x20Instant\x20API\x20policy\x20file:\x20','instant_api_policy_file_too_large','defaults','utf8'];a270_0x4101=function(){return _0x12ed40;};return a270_0x4101();}import{CliError}from'../../errors.js';export const INSTANT_API_POLICY_RELATIVE_ROOT=a270_0x1f8aad(0xb8);export const INSTANT_API_POLICY_FILE_NAME='policy.json';export const MAX_INSTANT_API_POLICY_BYTES=0x400*0x400;export function instantApiPolicyError(_0x299d7d,_0xadeb24,_0x44adc7){return new CliError(_0x299d7d,0x1,_0xadeb24,_0x44adc7);}export function loadInstantApiPolicyLocalConfig(_0x375869,_0x54f98a){assertSafeAppCode(_0x375869);const _0x41bf01=resolve(_0x54f98a??findProjectRootDirectory()),_0xa1fb48=INSTANT_API_POLICY_RELATIVE_ROOT+'/'+_0x375869+'/'+INSTANT_API_POLICY_FILE_NAME,_0x3c74aa=resolve(_0x41bf01,INSTANT_API_POLICY_RELATIVE_ROOT,_0x375869),_0x1698a0=resolve(_0x3c74aa,INSTANT_API_POLICY_FILE_NAME);return{'projectRoot':_0x41bf01,'appCode':_0x375869,'policyRoot':_0x3c74aa,'policyFilePath':_0x1698a0,'policyRelativePath':_0xa1fb48};}export function createDefaultInstantApiPolicyConfig(_0x164550,_0x56e808='allow'){return assertSafeAppCode(_0x164550),{'version':'2','appCode':_0x164550,'defaults':{'instantApi':_0x56e808},'rules':[]};}export async function readInstantApiPolicyConfigFile(_0x3befe3){const _0x5349de=a270_0x1f8aad;let _0x20c05f;try{_0x20c05f=await stat(_0x3befe3['policyFilePath']);}catch(_0x366837){throw instantApiPolicyError(_0x5349de(0xc2),_0x5349de(0xb1)+_0x3befe3['policyFilePath'],_0x5349de(0xcd));}if(!_0x20c05f['isFile']())throw instantApiPolicyError(_0x5349de(0xd0),'Instant\x20API\x20policy\x20path\x20is\x20not\x20a\x20regular\x20file:\x20'+_0x3befe3[_0x5349de(0xd9)]);if(_0x20c05f[_0x5349de(0xe2)]>MAX_INSTANT_API_POLICY_BYTES)throw instantApiPolicyError('instant_api_policy_file_too_large',_0x5349de(0xd3));let _0x26ad43;try{_0x26ad43=await readFile(_0x3befe3[_0x5349de(0xd9)]);}catch{throw instantApiPolicyError(_0x5349de(0xba),_0x5349de(0xcc)+_0x3befe3[_0x5349de(0xd9)]);}if(_0x26ad43[_0x5349de(0xdc)]>MAX_INSTANT_API_POLICY_BYTES)throw instantApiPolicyError(_0x5349de(0xc8),_0x5349de(0xd3));let _0x37df45;try{_0x37df45=new TextDecoder(_0x5349de(0xb6),{'fatal':!![],'ignoreBOM':!![]})[_0x5349de(0xcb)](_0x26ad43);}catch{throw instantApiPolicyError(_0x5349de(0xd0),_0x5349de(0xc3)+_0x3befe3['policyFilePath']);}let _0x474bee;try{_0x474bee=JSON[_0x5349de(0xae)](_0x37df45);}catch{throw instantApiPolicyError(_0x5349de(0xac),_0x5349de(0xe7)+_0x3befe3[_0x5349de(0xd9)]);}return assertLocalPolicyContract(_0x474bee,_0x3befe3[_0x5349de(0xd7)]);}export async function writeInstantApiPolicyConfigFile(_0x12379a,_0x3f7747,_0x277bb1={}){const _0x390dd8=a270_0x1f8aad,_0x5d7aaa=assertLocalPolicyContract(_0x3f7747,_0x12379a['appCode']),_0x35cb16=JSON[_0x390dd8(0xbd)](_0x5d7aaa,null,0x2)+'\x0a';if(Buffer['byteLength'](_0x35cb16,_0x390dd8(0xca))>MAX_INSTANT_API_POLICY_BYTES)throw instantApiPolicyError(_0x390dd8(0xc8),_0x390dd8(0xd3));await mkdir(_0x12379a['policyRoot'],{'recursive':!![]});let _0x36b22a;try{_0x36b22a=await readFile(_0x12379a[_0x390dd8(0xd9)],_0x390dd8(0xca));}catch(_0x1bab6a){if(!isMissingFile(_0x1bab6a))throw instantApiPolicyError(_0x390dd8(0xba),'Cannot\x20inspect\x20Instant\x20API\x20policy\x20file:\x20'+_0x12379a['policyFilePath']);}if(_0x36b22a===_0x35cb16)return{'action':'unchanged','filePath':_0x12379a[_0x390dd8(0xd9)]};if(_0x36b22a!==undefined&&!_0x277bb1[_0x390dd8(0xb3)])throw instantApiPolicyError(_0x390dd8(0xcf),'Instant\x20API\x20policy\x20file\x20already\x20exists:\x20'+_0x12379a[_0x390dd8(0xd9)],_0x390dd8(0xe4));if(_0x36b22a===undefined)try{return await writeFile(_0x12379a[_0x390dd8(0xd9)],_0x35cb16,{'encoding':_0x390dd8(0xca),'flag':'wx'}),{'action':_0x390dd8(0xe0),'filePath':_0x12379a[_0x390dd8(0xd9)]};}catch(_0x46bfdf){if(!isAlreadyExists(_0x46bfdf))throw instantApiPolicyError(_0x390dd8(0xc5),_0x390dd8(0xc7)+_0x12379a[_0x390dd8(0xd9)]);if(!_0x277bb1[_0x390dd8(0xb3)])throw instantApiPolicyError('instant_api_policy_file_exists',_0x390dd8(0xd8)+_0x12379a['policyFilePath'],'Review\x20the\x20file\x20before\x20retrying.');}const _0x22c4cf=resolve(dirname(_0x12379a[_0x390dd8(0xd9)]),'.'+INSTANT_API_POLICY_FILE_NAME+'.'+process[_0x390dd8(0xdf)]+'.'+randomUUID()+_0x390dd8(0xc0));try{await writeFile(_0x22c4cf,_0x35cb16,{'encoding':_0x390dd8(0xca),'flag':'wx'}),await rename(_0x22c4cf,_0x12379a[_0x390dd8(0xd9)]);}catch{await unlink(_0x22c4cf)[_0x390dd8(0xd1)](()=>undefined);throw instantApiPolicyError(_0x390dd8(0xc5),_0x390dd8(0xbb)+_0x12379a[_0x390dd8(0xd9)]);}return{'action':'overwritten','filePath':_0x12379a[_0x390dd8(0xd9)]};}function assertSafeAppCode(_0x2ded5c){const _0x1ee506=a270_0x1f8aad,_0x2c66f5=_0x2ded5c['trim']();if(!_0x2c66f5||_0x2c66f5!==_0x2ded5c||_0x2c66f5[_0x1ee506(0xdd)]>0x64||_0x2c66f5==='.'||_0x2c66f5==='..'||_0x2c66f5[_0x1ee506(0xc1)]('/')||_0x2c66f5[_0x1ee506(0xc1)]('\x5c')||_0x2c66f5[_0x1ee506(0xc1)]('\x00'))throw instantApiPolicyError(_0x1ee506(0xad),'appCode\x20cannot\x20be\x20used\x20as\x20the\x20fixed\x20Instant\x20API\x20policy\x20directory\x20name.');}function assertLocalPolicyContract(_0x5f1fc7,_0x12879a){const _0x464f7e=a270_0x1f8aad;if(!isObject(_0x5f1fc7))throw instantApiPolicyError(_0x464f7e(0xac),'Instant\x20API\x20policy\x20JSON\x20root\x20must\x20be\x20an\x20object.');if(_0x5f1fc7[_0x464f7e(0xc4)]!=='1'&&_0x5f1fc7[_0x464f7e(0xc4)]!=='2')throw instantApiPolicyError(_0x464f7e(0xce),'Instant\x20API\x20policy\x20version\x20must\x20be\x20\x221\x22\x20or\x20\x222\x22.',_0x464f7e(0xbe));if(_0x5f1fc7['appCode']!==_0x12879a)throw instantApiPolicyError(_0x464f7e(0xbc),'Policy\x20appCode\x20must\x20match\x20the\x20selected\x20application\x20'+_0x12879a+'.');if(!isObject(_0x5f1fc7['defaults'])||typeof _0x5f1fc7[_0x464f7e(0xc9)]['instantApi']!==_0x464f7e(0xd2))throw instantApiPolicyError(_0x464f7e(0xbf),_0x464f7e(0xb9));if(_0x5f1fc7[_0x464f7e(0xd5)]!==undefined&&_0x5f1fc7[_0x464f7e(0xd5)]!==null&&!Array[_0x464f7e(0xb4)](_0x5f1fc7[_0x464f7e(0xd5)]))throw instantApiPolicyError('instant_api_policy_rules_invalid',_0x464f7e(0xdb));return _0x5f1fc7;}function a270_0x5451(_0x3d66f2,_0x3e2c2e){_0x3d66f2=_0x3d66f2-0xac;const _0x4101a2=a270_0x4101();let _0x545187=_0x4101a2[_0x3d66f2];return _0x545187;}function isObject(_0x22e319){const _0x43a8d0=a270_0x1f8aad;return _0x22e319!==null&&typeof _0x22e319===_0x43a8d0(0xda)&&!Array[_0x43a8d0(0xb4)](_0x22e319);}function isMissingFile(_0x2cee5a){const _0xc1d957=a270_0x1f8aad;return Boolean(_0x2cee5a&&typeof _0x2cee5a===_0xc1d957(0xda)&&_0x2cee5a[_0xc1d957(0xe6)]===_0xc1d957(0xe3));}function isAlreadyExists(_0x163527){const _0x5b3025=a270_0x1f8aad;return Boolean(_0x163527&&typeof _0x163527===_0x5b3025(0xda)&&_0x163527[_0x5b3025(0xe6)]===_0x5b3025(0xe5));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a271_0x46bd27=a271_0x514d;(function(_0x4551a0,_0x2da9c4){const _0x414b74=a271_0x514d,_0x111f1b=_0x4551a0();while(!![]){try{const _0x13053f=parseInt(_0x414b74(0x183))/0x1+parseInt(_0x414b74(0x155))/0x2+-parseInt(_0x414b74(0x18d))/0x3*(-parseInt(_0x414b74(0x150))/0x4)+-parseInt(_0x414b74(0x156))/0x5*(parseInt(_0x414b74(0x17e))/0x6)+-parseInt(_0x414b74(0x170))/0x7*(-parseInt(_0x414b74(0x152))/0x8)+parseInt(_0x414b74(0x146))/0x9*(parseInt(_0x414b74(0x166))/0xa)+-parseInt(_0x414b74(0x16f))/0xb;if(_0x13053f===_0x2da9c4)break;else _0x111f1b['push'](_0x111f1b['shift']());}catch(_0x4186c2){_0x111f1b['push'](_0x111f1b['shift']());}}}(a271_0x4495,0xaa985));import{getKbDomain}from'../constant/domain.js';import{CliError,CliErrors}from'../errors.js';function a271_0x4495(){const _0x31f5c8=['topK','entries','rawScore','length','246QXoRHa','POST','headers','query','data','850099MjVGlj','stringify','toLowerCase','finalScore','success','trim','string','Knowledge\x20search\x20appCode\x20is\x20required.','Knowledge\x20search\x20topK\x20must\x20be\x20an\x20integer\x20from\x201\x20through\x2050.','no-store','39UYabWU','split','revision','name','signal','243BQeLvo','isArray','isSafeInteger','map','timingsMs','score','chunkId','test','isFinite','authRequired','171692CJoLMn','documentId','1802144sReryv','appCode','cache-control','45552ihZkVh','17735nbkzGm','development','scope','public','SmartCode\x20knowledge\x20search\x20request\x20failed.','hits[','strategyFingerprint','status','number','schemaVersion','content-type','rank','tags','get','scoreKind','apiError','39290GCYMCM','sort','SmartCode\x20knowledge\x20search\x20response\x20is\x20missing\x20Cache-Control:\x20no-store.','application/json','some','company','SmartCode\x20knowledge\x20search\x20returned\x20a\x20non-JSON\x20content\x20type.','SmartCode\x20knowledge\x20search\x20failed\x20(HTTP\x20','cookie','15054347mXrJvs','21NSSOKM','hits','Knowledge\x20search\x20query\x20is\x20required.','title','includes','profile','SmartCode\x20knowledge\x20search\x20failed.','text','validation','total'];a271_0x4495=function(){return _0x31f5c8;};return a271_0x4495();}const RESPONSE_KEYS=[a271_0x46bd27(0x15f),a271_0x46bd27(0x175),'total','hits','strategyFingerprint',a271_0x46bd27(0x14a)],HIT_KEYS=[a271_0x46bd27(0x151),a271_0x46bd27(0x18f),'chunkId','scope',a271_0x46bd27(0x173),a271_0x46bd27(0x177),a271_0x46bd27(0x162),a271_0x46bd27(0x161),'rawScore','finalScore',a271_0x46bd27(0x164)];export async function searchDevelopmentKnowledge(_0x13dafa){const _0x2de33d=a271_0x46bd27,_0x3f4f73=_0x13dafa[_0x2de33d(0x153)][_0x2de33d(0x188)](),_0x2bbf1e=_0x13dafa[_0x2de33d(0x181)]['trim']();if(!_0x3f4f73)throw CliErrors[_0x2de33d(0x178)](_0x2de33d(0x18a));if(!_0x13dafa[_0x2de33d(0x16e)][_0x2de33d(0x188)]())throw CliErrors['authRequired']();if(!_0x2bbf1e)throw CliErrors[_0x2de33d(0x178)](_0x2de33d(0x172));validateTopK(_0x13dafa[_0x2de33d(0x17a)]);const _0x599e6d=getKbDomain()+'/smartapi/knowledge/company-public/search';let _0x4afc24;try{_0x4afc24=await fetch(_0x599e6d,{'method':_0x2de33d(0x17f),'headers':{'Content-Type':_0x2de33d(0x169),'Cookie':_0x13dafa[_0x2de33d(0x16e)],'X-Invoke-Source':'cli:rabetbase'},'body':JSON[_0x2de33d(0x184)]({'appCode':_0x3f4f73,'query':_0x2bbf1e,..._0x13dafa[_0x2de33d(0x17a)]!==undefined?{'topK':_0x13dafa['topK']}:{}}),'signal':_0x13dafa[_0x2de33d(0x145)]});}catch(_0x2af111){if(_0x2af111 instanceof CliError)throw _0x2af111;if(_0x2af111 instanceof Error&&_0x2af111[_0x2de33d(0x190)]==='AbortError')throw _0x2af111;throw CliErrors['networkError'](_0x2de33d(0x15a));}if(!hasNoStore(_0x4afc24[_0x2de33d(0x180)]))throw CliErrors[_0x2de33d(0x165)](_0x2de33d(0x168));if(_0x4afc24[_0x2de33d(0x15d)]===0x191)throw CliErrors[_0x2de33d(0x14f)]();if(!_0x4afc24['ok'])throw CliErrors['apiError'](_0x2de33d(0x16d)+_0x4afc24[_0x2de33d(0x15d)]+').');if(!(_0x4afc24[_0x2de33d(0x180)][_0x2de33d(0x163)](_0x2de33d(0x160))??'')[_0x2de33d(0x185)]()[_0x2de33d(0x174)](_0x2de33d(0x169)))throw CliErrors[_0x2de33d(0x165)](_0x2de33d(0x16c));let _0x4fd160;try{_0x4fd160=await _0x4afc24['json']();}catch{throw CliErrors[_0x2de33d(0x165)]('SmartCode\x20knowledge\x20search\x20returned\x20invalid\x20JSON.');}return parseDevelopmentSearchResponse(readEnvelopeData(_0x4fd160),_0x13dafa[_0x2de33d(0x17a)]);}function readEnvelopeData(_0x17fab1){const _0x56e3af=a271_0x46bd27,_0x5a5031=requireRecord(_0x17fab1,'response\x20envelope');if(_0x5a5031[_0x56e3af(0x187)]===![])throw CliErrors[_0x56e3af(0x165)](_0x56e3af(0x176));if(!(_0x56e3af(0x182)in _0x5a5031))throw invalidContract('response\x20envelope');return _0x5a5031[_0x56e3af(0x182)];}function validateTopK(_0x3b548){const _0x1c2dcf=a271_0x46bd27;if(_0x3b548!==undefined&&(!Number[_0x1c2dcf(0x148)](_0x3b548)||_0x3b548<0x1||_0x3b548>0x32))throw CliErrors[_0x1c2dcf(0x178)](_0x1c2dcf(0x18b));}function hasNoStore(_0x5304c2){const _0x1eec1f=a271_0x46bd27;return(_0x5304c2['get'](_0x1eec1f(0x154))??'')[_0x1eec1f(0x18e)](',')[_0x1eec1f(0x16a)](_0x22d18f=>_0x22d18f[_0x1eec1f(0x188)]()[_0x1eec1f(0x185)]()===_0x1eec1f(0x18c));}function parseDevelopmentSearchResponse(_0x300241,_0x3b23d7){const _0x4f5195=a271_0x46bd27,_0x191328=requireExactRecord(_0x300241,RESPONSE_KEYS,'response');if(_0x191328[_0x4f5195(0x15f)]!==0x2||_0x191328['profile']!==_0x4f5195(0x157))throw invalidContract(_0x4f5195(0x175));if(!Array['isArray'](_0x191328[_0x4f5195(0x171)])||_0x191328[_0x4f5195(0x171)][_0x4f5195(0x17d)]>(_0x3b23d7??0x32))throw invalidContract('hits');if(typeof _0x191328['strategyFingerprint']!==_0x4f5195(0x189)||!/^sha256:[0-9a-f]{64}$/[_0x4f5195(0x14d)](_0x191328[_0x4f5195(0x15c)]))throw invalidContract('strategyFingerprint');const _0x353e43=requireRecord(_0x191328[_0x4f5195(0x14a)],_0x4f5195(0x14a)),_0xc46ebf={};for(const [_0x4dc512,_0xe47465]of Object[_0x4f5195(0x17b)](_0x353e43)){if(!/^[A-Za-z][A-Za-z0-9]*$/['test'](_0x4dc512)||typeof _0xe47465!==_0x4f5195(0x15e)||!Number[_0x4f5195(0x14e)](_0xe47465)||_0xe47465<0x0)throw invalidContract(_0x4f5195(0x14a));_0xc46ebf[_0x4dc512]=_0xe47465;}const _0x38dd5b=_0x191328['hits'][_0x4f5195(0x149)]((_0x11bb56,_0x5b34c3)=>parseHit(_0x11bb56,_0x5b34c3));if(!Number['isSafeInteger'](_0x191328['total'])||_0x191328[_0x4f5195(0x179)]!==_0x38dd5b['length'])throw invalidContract('total');return{'schemaVersion':_0x191328[_0x4f5195(0x15f)],'profile':_0x191328['profile'],'total':_0x191328[_0x4f5195(0x179)],'strategyFingerprint':_0x191328[_0x4f5195(0x15c)],'timingsMs':_0xc46ebf,'hits':_0x38dd5b};}function parseHit(_0x146075,_0x17d182){const _0x4fb114=a271_0x46bd27,_0x4b7525=requireExactRecord(_0x146075,HIT_KEYS,_0x4fb114(0x15b)+_0x17d182+']'),_0xf3c2c8=_0x19cf6f=>{const _0x515f2e=_0x4b7525[_0x19cf6f];if(typeof _0x515f2e!=='string'||!_0x515f2e)throw invalidContract(_0x19cf6f);return _0x515f2e;};if(!Number[_0x4fb114(0x148)](_0x4b7525[_0x4fb114(0x18f)])||_0x4b7525[_0x4fb114(0x18f)]<0x1)throw invalidContract(_0x4fb114(0x18f));if(_0x4b7525[_0x4fb114(0x158)]!==_0x4fb114(0x159)&&_0x4b7525[_0x4fb114(0x158)]!==_0x4fb114(0x16b))throw invalidContract(_0x4fb114(0x158));if(typeof _0x4b7525[_0x4fb114(0x173)]!==_0x4fb114(0x189)||typeof _0x4b7525[_0x4fb114(0x177)]!=='string')throw invalidContract(_0x4fb114(0x177));if(!Array[_0x4fb114(0x147)](_0x4b7525[_0x4fb114(0x162)])||_0x4b7525[_0x4fb114(0x162)][_0x4fb114(0x16a)](_0x10a29d=>typeof _0x10a29d!=='string'))throw invalidContract(_0x4fb114(0x162));if(!Number[_0x4fb114(0x148)](_0x4b7525[_0x4fb114(0x161)])||_0x4b7525[_0x4fb114(0x161)]!==_0x17d182+0x1)throw invalidContract(_0x4fb114(0x161));if(!isFiniteNumber(_0x4b7525[_0x4fb114(0x17c)])||!isFiniteNumber(_0x4b7525[_0x4fb114(0x186)]))throw invalidContract(_0x4fb114(0x14b));return{'documentId':_0xf3c2c8(_0x4fb114(0x151)),'revision':_0x4b7525['revision'],'chunkId':_0xf3c2c8(_0x4fb114(0x14c)),'scope':_0x4b7525[_0x4fb114(0x158)],'title':_0x4b7525[_0x4fb114(0x173)],'text':_0x4b7525[_0x4fb114(0x177)],'tags':[..._0x4b7525[_0x4fb114(0x162)]],'rank':_0x4b7525['rank'],'rawScore':_0x4b7525['rawScore'],'finalScore':_0x4b7525[_0x4fb114(0x186)],'scoreKind':_0xf3c2c8(_0x4fb114(0x164))};}function requireExactRecord(_0x3533b8,_0x2dcdcd,_0x3740df){const _0x1293bb=a271_0x46bd27,_0x43528e=requireRecord(_0x3533b8,_0x3740df),_0x5e1586=Object['keys'](_0x43528e)[_0x1293bb(0x167)](),_0x333cef=[..._0x2dcdcd]['sort']();if(_0x5e1586[_0x1293bb(0x17d)]!==_0x333cef['length']||_0x5e1586[_0x1293bb(0x16a)]((_0x173130,_0xfb8e13)=>_0x173130!==_0x333cef[_0xfb8e13]))throw invalidContract(_0x3740df);return _0x43528e;}function a271_0x514d(_0x29b086,_0x402ba2){_0x29b086=_0x29b086-0x145;const _0x44953=a271_0x4495();let _0x514d1b=_0x44953[_0x29b086];return _0x514d1b;}function requireRecord(_0x313a43,_0x566ad4){if(!_0x313a43||typeof _0x313a43!=='object'||Array['isArray'](_0x313a43))throw invalidContract(_0x566ad4);return _0x313a43;}function isFiniteNumber(_0x530f15){const _0x2f6d84=a271_0x46bd27;return typeof _0x530f15===_0x2f6d84(0x15e)&&Number[_0x2f6d84(0x14e)](_0x530f15);}function invalidContract(_0x513736){return CliErrors['apiError']('SmartCode\x20knowledge\x20search\x20returned\x20an\x20invalid\x20'+_0x513736+'\x20contract.');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a272_0x5416(){const _0x4000c8=['4130xFoeBJ','56106TJuVsY','isDirectory','split','6ZXDiSY','2635616iJDOVm','Page\x20directory\x20is\x20not\x20a\x20directory:\x20','.rabetbase','page-dir','4342765CwTaIb','8277512ClGkWi','page.lock.json','sort','name','F_OK','999034jnJNxA','appPagesDir','trim','2024049VCGsIe','join','validation','6338038DaQkgI','.json','4pXSWYy'];a272_0x5416=function(){return _0x4000c8;};return a272_0x5416();}(function(_0x21973f,_0x1148dc){const _0x1413bd=a272_0x4c9f,_0x5eaca3=_0x21973f();while(!![]){try{const _0x238f50=parseInt(_0x1413bd(0x1f4))/0x1+-parseInt(_0x1413bd(0x1fc))/0x2*(parseInt(_0x1413bd(0x1f7))/0x3)+-parseInt(_0x1413bd(0x1ea))/0x4+parseInt(_0x1413bd(0x1ee))/0x5*(-parseInt(_0x1413bd(0x201))/0x6)+-parseInt(_0x1413bd(0x1fa))/0x7+parseInt(_0x1413bd(0x1ef))/0x8+-parseInt(_0x1413bd(0x1fe))/0x9*(-parseInt(_0x1413bd(0x1fd))/0xa);if(_0x238f50===_0x1148dc)break;else _0x5eaca3['push'](_0x5eaca3['shift']());}catch(_0x48b1a5){_0x5eaca3['push'](_0x5eaca3['shift']());}}}(a272_0x5416,0xc9afc));import{constants}from'node:fs';import{access,lstat,mkdir,readFile,readdir}from'node:fs/promises';import{dirname,join,relative,resolve,sep}from'node:path';function a272_0x4c9f(_0x52f260,_0x25395d){_0x52f260=_0x52f260-0x1ea;const _0x5416d4=a272_0x5416();let _0x4c9f4f=_0x5416d4[_0x52f260];return _0x4c9f4f;}import{CliErrors}from'../../errors.js';export function loadPageProjectConfig(_0x358b8b,_0x312a2a=process['cwd']()){const _0x53b381=a272_0x4c9f,_0x588b64=resolve(_0x312a2a),_0xf30ece=join(_0x588b64,'.rabetbase','page');return{'projectRoot':_0x588b64,'pagesBaseDir':_0xf30ece,'appPagesDir':join(_0xf30ece,_0x358b8b),'lockFilePath':join(_0x588b64,_0x53b381(0x1ec),_0x53b381(0x1f0))};}export function buildPageFileName(_0x482748,_0x49c114){const _0x55825b=a272_0x4c9f;return _0x482748+'-'+_0x49c114['toUpperCase']()+_0x55825b(0x1fb);}export function resolvePageFilePath(_0x2a197f,_0x507c5b,_0x7e51e0){const _0x2ec33f=a272_0x4c9f;return join(_0x2a197f[_0x2ec33f(0x1f5)],buildPageFileName(_0x507c5b,_0x7e51e0));}export async function ensureParentDirectory(_0x550525){await mkdir(dirname(_0x550525),{'recursive':!![]});}export async function fileExists(_0x3cb1e8){const _0x4bdf5d=a272_0x4c9f;try{return await access(_0x3cb1e8,constants[_0x4bdf5d(0x1f3)]),!![];}catch{return![];}}export async function readCustomPageDirectory(_0x1ef5d3){const _0x11061e=a272_0x4c9f,_0x173d7f=_0x1ef5d3[_0x11061e(0x1f6)]();if(!_0x173d7f)throw CliErrors['flagMissing'](_0x11061e(0x1ed));const _0x472bec=resolve(_0x173d7f);let _0x1568f7;try{_0x1568f7=await lstat(_0x472bec);}catch{throw CliErrors[_0x11061e(0x1f9)]('Page\x20directory\x20not\x20found:\x20'+_0x173d7f);}if(!_0x1568f7[_0x11061e(0x1ff)]())throw CliErrors['validation'](_0x11061e(0x1eb)+_0x173d7f);const _0x2765bb={};return await readDirectory(_0x472bec,_0x472bec,_0x2765bb),_0x2765bb;}async function readDirectory(_0x363d5d,_0x44e602,_0xae1156){const _0x389ec5=a272_0x4c9f,_0x110468=await readdir(_0x44e602,{'withFileTypes':!![]});for(const _0x503894 of _0x110468[_0x389ec5(0x1f1)]((_0x50ff0d,_0x5abe40)=>_0x50ff0d[_0x389ec5(0x1f2)]['localeCompare'](_0x5abe40[_0x389ec5(0x1f2)]))){const _0x26e204=join(_0x44e602,_0x503894['name']);if(_0x503894[_0x389ec5(0x1ff)]()){await readDirectory(_0x363d5d,_0x26e204,_0xae1156);continue;}if(!_0x503894['isFile']())throw CliErrors['validation']('Unsupported\x20file\x20in\x20page\x20directory:\x20'+_0x26e204);_0xae1156[relative(_0x363d5d,_0x26e204)[_0x389ec5(0x200)](sep)[_0x389ec5(0x1f8)]('/')]=await readFile(_0x26e204,'utf8');}}
|
package/lib/core/page/hash.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x10a722,_0x488b64){const _0x182ff7=a273_0x1bfd,_0x515a1b=_0x10a722();while(!![]){try{const _0xfad90a=-parseInt(_0x182ff7(0xfa))/0x1+parseInt(_0x182ff7(0xf1))/0x2+parseInt(_0x182ff7(0xf3))/0x3+-parseInt(_0x182ff7(0xf8))/0x4*(-parseInt(_0x182ff7(0xed))/0x5)+parseInt(_0x182ff7(0xeb))/0x6*(-parseInt(_0x182ff7(0xf2))/0x7)+-parseInt(_0x182ff7(0xf7))/0x8+parseInt(_0x182ff7(0xf4))/0x9*(-parseInt(_0x182ff7(0xee))/0xa);if(_0xfad90a===_0x488b64)break;else _0x515a1b['push'](_0x515a1b['shift']());}catch(_0x31ad40){_0x515a1b['push'](_0x515a1b['shift']());}}}(a273_0xbea6,0xcdb65));import a273_0x1cc093 from'node:crypto';function a273_0xbea6(){const _0xfeb57b=['utf8','6336840axyOmw','2261108AEVgcC','stringify','615167zEKnpx','3876996CzoCud','md5','10GOGVtS','290zOqyrs','createHash','hex','2190422XiBfPU','7omgcBJ','2385171gloajV','38727dKMNAn','parse'];a273_0xbea6=function(){return _0xfeb57b;};return a273_0xbea6();}import{readFile}from'node:fs/promises';function a273_0x1bfd(_0x663881,_0x35316f){_0x663881=_0x663881-0xeb;const _0xbea657=a273_0xbea6();let _0x1bfd22=_0xbea657[_0x663881];return _0x1bfd22;}export function serializePageSchemaForFile(_0x1c99f1){const _0x27d47c=a273_0x1bfd;return JSON[_0x27d47c(0xf9)](JSON[_0x27d47c(0xf5)](_0x1c99f1),null,0x2)+'\x0a';}export function computePageContentHash(_0x213a28){const _0x2c20c1=a273_0x1bfd;return a273_0x1cc093[_0x2c20c1(0xef)](_0x2c20c1(0xec))['update'](_0x213a28)['digest'](_0x2c20c1(0xf0));}export function computeSerializedSchemaHash(_0x3c7029){return computePageContentHash(serializePageSchemaForFile(_0x3c7029));}export async function computePageFileHash(_0x520ade){const _0xa4f909=a273_0x1bfd,_0x52a540=await readFile(_0x520ade,_0xa4f909(0xf6));return computePageContentHash(_0x52a540);}
|
package/lib/core/page/lock.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3baeb9,_0x33aa72){const _0x2d026e=a274_0x51e3,_0x964890=_0x3baeb9();while(!![]){try{const _0x437bb4=parseInt(_0x2d026e(0x6b))/0x1*(-parseInt(_0x2d026e(0x73))/0x2)+parseInt(_0x2d026e(0x74))/0x3+-parseInt(_0x2d026e(0x69))/0x4*(-parseInt(_0x2d026e(0x72))/0x5)+-parseInt(_0x2d026e(0x71))/0x6*(parseInt(_0x2d026e(0x70))/0x7)+-parseInt(_0x2d026e(0x77))/0x8+parseInt(_0x2d026e(0x6d))/0x9+parseInt(_0x2d026e(0x79))/0xa;if(_0x437bb4===_0x33aa72)break;else _0x964890['push'](_0x964890['shift']());}catch(_0x554f88){_0x964890['push'](_0x964890['shift']());}}}(a274_0x1e4b,0x2d6cb));import{mkdir,readFile,writeFile}from'node:fs/promises';import{dirname}from'node:path';function a274_0x51e3(_0x3395d1,_0x5a4f4a){_0x3395d1=_0x3395d1-0x69;const _0x1e4b9b=a274_0x1e4b();let _0x51e3a1=_0x1e4b9b[_0x3395d1];return _0x51e3a1;}function a274_0x1e4b(){const _0x30fabc=['pages','code','lastSync','4hdnUVN','ENOENT','3431EKuGRU','parse','212607hiaBur','Failed\x20to\x20read\x20page\x20lock\x20file:\x20','object','2060233YuEfpR','6YKcVts','355595HGYGIe','38mXPfxN','467265EfUAFu','apps','stringify','1994584TOWXZx','utf8','5443930MVbash'];a274_0x1e4b=function(){return _0x30fabc;};return a274_0x1e4b();}export function createEmptyPageLock(){return{'apps':{}};}export function ensurePageLockScope(_0x180851,_0x4cb43d){const _0x44af60=a274_0x51e3,_0x2b0338={'apps':_0x180851[_0x44af60(0x75)]&&typeof _0x180851[_0x44af60(0x75)]===_0x44af60(0x6f)?_0x180851[_0x44af60(0x75)]:{}};let _0x466fcd=_0x2b0338[_0x44af60(0x75)][_0x4cb43d];if(!_0x466fcd)return _0x466fcd={'lastSync':'','pages':{}},_0x2b0338[_0x44af60(0x75)][_0x4cb43d]=_0x466fcd,{'lockData':_0x2b0338,'appLock':_0x466fcd};return!_0x466fcd['lastSync']&&(_0x466fcd[_0x44af60(0x7c)]=''),(!_0x466fcd['pages']||typeof _0x466fcd['pages']!==_0x44af60(0x6f))&&(_0x466fcd[_0x44af60(0x7a)]={}),{'lockData':_0x2b0338,'appLock':_0x466fcd};}export async function readPageLockFile(_0x6db58a){const _0x36e80e=a274_0x51e3;try{const _0x139a37=await readFile(_0x6db58a,_0x36e80e(0x78)),_0x233b79=JSON[_0x36e80e(0x6c)](_0x139a37);return{'apps':_0x233b79[_0x36e80e(0x75)]&&typeof _0x233b79[_0x36e80e(0x75)]===_0x36e80e(0x6f)?_0x233b79[_0x36e80e(0x75)]:{}};}catch(_0x513e59){if(_0x513e59[_0x36e80e(0x7b)]===_0x36e80e(0x6a))return null;throw new Error(_0x36e80e(0x6e)+String(_0x513e59));}}export async function writePageLockFile(_0x5dd4fa,_0x5a02ce){const _0x11b751=a274_0x51e3;await mkdir(dirname(_0x5dd4fa),{'recursive':!![]}),await writeFile(_0x5dd4fa,JSON[_0x11b751(0x76)](_0x5a02ce,null,0x2),_0x11b751(0x78));}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export interface PrepareLrSmartJsxResult {
|
|
2
|
+
content: string;
|
|
3
|
+
compiledNodes: number;
|
|
4
|
+
normalizedNodes: number;
|
|
5
|
+
}
|
|
6
|
+
export declare function prepareLrSmartJsxForPush(localContent: string, remoteContent: string, transpile: (source: string) => Promise<string>): Promise<PrepareLrSmartJsxResult>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(function(_0x3402f8,_0x2a8f6a){const _0x584675=a275_0x5471,_0x4d2d7d=_0x3402f8();while(!![]){try{const _0x1a6961=parseInt(_0x584675(0x194))/0x1+parseInt(_0x584675(0x18f))/0x2*(-parseInt(_0x584675(0x174))/0x3)+parseInt(_0x584675(0x19c))/0x4+-parseInt(_0x584675(0x17a))/0x5+parseInt(_0x584675(0x18d))/0x6+-parseInt(_0x584675(0x173))/0x7*(parseInt(_0x584675(0x18e))/0x8)+parseInt(_0x584675(0x195))/0x9;if(_0x1a6961===_0x2a8f6a)break;else _0x4d2d7d['push'](_0x4d2d7d['shift']());}catch(_0x5a7bcb){_0x4d2d7d['push'](_0x4d2d7d['shift']());}}}(a275_0x5e64,0x3e946));import{CliErrors}from'../../errors.js';function a275_0x5e64(){const _0x24cc69=['isArray','key','Edit\x20render.source\x20instead;\x20render.value\x20is\x20generated\x20during\x20page\x20push.','2257116PMdoNV','774496lFXEIt','2DJPliz','\x22\x20has\x20a\x20manually\x20changed\x20render.value.','Set\x20props\x20to\x20an\x20object\x20containing\x20a\x20render\x20object.','length','validation','444705wqXFJC','5377086aMcCSF','render','componentName','source','JSFunction','local','type','356156cAOvlf','label','props','\x22\x20is\x20missing\x20both\x20render.source\x20and\x20render.value.','35WejRqQ','1239195sdwEgZ','id:','trim','value','string','Set\x20props.render\x20to\x20an\x20object\x20containing\x20render.source\x20or\x20render.value.','1769665FoAjoc','Add\x20JSX\x20source\x20in\x20the\x20page\x20editor\x20or\x20remove\x20the\x20incomplete\x20component.','\x20page\x20schema.','_context','LrSmartJsx\x20node\x20\x22','stringify','apiError','forEach','this','JSExpression','\x22\x20has\x20missing\x20or\x20invalid\x20props.render.','get','LrSmartJsx','LrSmartJsx\x20compilation\x20returned\x20no\x20code\x20for\x20node\x20\x22','Invalid\x20JSON\x20in\x20','parse'];a275_0x5e64=function(){return _0x24cc69;};return a275_0x5e64();}export async function prepareLrSmartJsxForPush(_0xae8b47,_0x563d21,_0x38ac5c){const _0x84d2ad=a275_0x5471,_0x352f62=parseSchema(_0xae8b47,_0x84d2ad(0x19a)),_0x350ab8=parseSchema(_0x563d21,'remote'),_0x1b1d7a=collectLrSmartJsx(_0x352f62,!![]);if(_0x1b1d7a[_0x84d2ad(0x192)]===0x0)return{'content':_0xae8b47,'compiledNodes':0x0,'normalizedNodes':0x0};const _0x4fdc05=new Map(collectLrSmartJsx(_0x350ab8)['map'](_0x2ba620=>[_0x2ba620[_0x84d2ad(0x18b)],_0x2ba620]));let _0xd5888d=0x0,_0x47b3c7=0x0;for(const _0xffb62 of _0x1b1d7a){const _0x4219c=readNonEmptyString(_0xffb62['render'][_0x84d2ad(0x198)]),_0x1101a4=readNonEmptyString(_0xffb62[_0x84d2ad(0x196)][_0x84d2ad(0x177)]),_0x53ff28=_0x4fdc05[_0x84d2ad(0x185)](_0xffb62[_0x84d2ad(0x18b)]),_0x341ad8=readNonEmptyString(_0x53ff28?.[_0x84d2ad(0x196)][_0x84d2ad(0x198)]),_0xc36e9f=readNonEmptyString(_0x53ff28?.['render'][_0x84d2ad(0x177)]);let _0x972420=![];_0xffb62[_0x84d2ad(0x196)][_0x84d2ad(0x19b)]!==_0x84d2ad(0x199)&&(_0xffb62[_0x84d2ad(0x196)][_0x84d2ad(0x19b)]=_0x84d2ad(0x199),_0x972420=!![]);!isPageContextExpression(_0xffb62[_0x84d2ad(0x19e)][_0x84d2ad(0x17d)])&&(_0xffb62[_0x84d2ad(0x19e)]['_context']={'type':_0x84d2ad(0x183),'value':_0x84d2ad(0x182)},_0x972420=!![]);if(!_0x4219c){if(!_0x1101a4)throw CliErrors[_0x84d2ad(0x193)]('LrSmartJsx\x20node\x20\x22'+_0xffb62['label']+_0x84d2ad(0x172),_0x84d2ad(0x17b));if(_0x972420)_0x47b3c7+=0x1;continue;}const _0x4a5c9e=!_0x53ff28||_0x4219c!==_0x341ad8,_0x247d50=!_0x1101a4;if(!_0x4a5c9e&&_0x1101a4&&_0xc36e9f&&_0x1101a4!==_0xc36e9f)throw CliErrors[_0x84d2ad(0x193)](_0x84d2ad(0x17e)+_0xffb62[_0x84d2ad(0x19d)]+_0x84d2ad(0x190),_0x84d2ad(0x18c));if(_0x4a5c9e||_0x247d50||!_0xc36e9f){const _0x6de913=readNonEmptyString(await _0x38ac5c(_0x4219c));if(!_0x6de913)throw CliErrors[_0x84d2ad(0x180)](_0x84d2ad(0x187)+_0xffb62[_0x84d2ad(0x19d)]+'\x22.');_0xffb62[_0x84d2ad(0x196)][_0x84d2ad(0x177)]=_0x6de913,_0xd5888d+=0x1,_0x972420=!![];}if(_0x972420)_0x47b3c7+=0x1;}if(_0x47b3c7===0x0)return{'content':_0xae8b47,'compiledNodes':_0xd5888d,'normalizedNodes':_0x47b3c7};return{'content':JSON[_0x84d2ad(0x17f)](_0x352f62),'compiledNodes':_0xd5888d,'normalizedNodes':_0x47b3c7};}function parseSchema(_0x14c28e,_0x11fc1e){const _0x248164=a275_0x5471;try{return JSON[_0x248164(0x189)](_0x14c28e);}catch{throw CliErrors[_0x248164(0x193)](_0x248164(0x188)+_0x11fc1e+_0x248164(0x17c));}}function collectLrSmartJsx(_0x58120b,_0x56138c=![]){const _0x58e00f=[],_0x204ffb=(_0x50f709,_0x3e53be)=>{const _0xcc40c3=a275_0x5471;if(Array['isArray'](_0x50f709)){_0x50f709[_0xcc40c3(0x181)]((_0x3e726f,_0x2c2893)=>_0x204ffb(_0x3e726f,_0x3e53be+'['+_0x2c2893+']'));return;}if(!isObject(_0x50f709))return;if(_0x50f709[_0xcc40c3(0x197)]===_0xcc40c3(0x186)){const _0x144c36=readNonEmptyString(_0x50f709['id']),_0x302439=_0x144c36||_0x3e53be,_0x3011f8=isObject(_0x50f709['props'])?_0x50f709['props']:undefined;if(!_0x3011f8){if(_0x56138c)throw CliErrors['validation']('LrSmartJsx\x20node\x20\x22'+_0x302439+'\x22\x20has\x20missing\x20or\x20invalid\x20props.',_0xcc40c3(0x191));return;}const _0x443ce1=isObject(_0x3011f8[_0xcc40c3(0x196)])?_0x3011f8[_0xcc40c3(0x196)]:undefined;if(!_0x443ce1){if(_0x56138c)throw CliErrors[_0xcc40c3(0x193)](_0xcc40c3(0x17e)+_0x302439+_0xcc40c3(0x184),_0xcc40c3(0x179));return;}_0x58e00f['push']({'key':_0x144c36?_0xcc40c3(0x175)+_0x144c36:'path:'+_0x3e53be,'label':_0x302439,'props':_0x3011f8,'render':_0x443ce1});}for(const [_0x345505,_0x398cf2]of Object['entries'](_0x50f709)){if(_0x345505===_0xcc40c3(0x19e)&&_0x50f709[_0xcc40c3(0x197)]===_0xcc40c3(0x186))continue;_0x204ffb(_0x398cf2,_0x3e53be+'.'+_0x345505);}};return _0x204ffb(_0x58120b,'$'),_0x58e00f;}function a275_0x5471(_0x2773f3,_0x110fca){_0x2773f3=_0x2773f3-0x172;const _0x5e6494=a275_0x5e64();let _0x547142=_0x5e6494[_0x2773f3];return _0x547142;}function isObject(_0x3fb9a6){const _0x1b30fd=a275_0x5471;return Boolean(_0x3fb9a6)&&typeof _0x3fb9a6==='object'&&!Array[_0x1b30fd(0x18a)](_0x3fb9a6);}function readNonEmptyString(_0xdc2d8d){const _0x1b98c8=a275_0x5471;return typeof _0xdc2d8d===_0x1b98c8(0x178)&&_0xdc2d8d[_0x1b98c8(0x176)]()?_0xdc2d8d:undefined;}function isPageContextExpression(_0x1b3591){const _0x5bd757=a275_0x5471;return isObject(_0x1b3591)&&_0x1b3591[_0x5bd757(0x19b)]===_0x5bd757(0x183)&&_0x1b3591[_0x5bd757(0x177)]===_0x5bd757(0x182);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x13ec86,_0x14f77a){const _0xb9d34a=a259_0x1e48,_0xf4fb0d=_0x13ec86();while(!![]){try{const _0x26db69=-parseInt(_0xb9d34a(0x101))/0x1*(-parseInt(_0xb9d34a(0x118))/0x2)+-parseInt(_0xb9d34a(0x137))/0x3*(parseInt(_0xb9d34a(0x124))/0x4)+parseInt(_0xb9d34a(0xf8))/0x5+parseInt(_0xb9d34a(0x11a))/0x6+-parseInt(_0xb9d34a(0x130))/0x7*(-parseInt(_0xb9d34a(0x138))/0x8)+-parseInt(_0xb9d34a(0x10b))/0x9*(-parseInt(_0xb9d34a(0x117))/0xa)+-parseInt(_0xb9d34a(0x12a))/0xb;if(_0x26db69===_0x14f77a)break;else _0xf4fb0d['push'](_0xf4fb0d['shift']());}catch(_0x2229f9){_0xf4fb0d['push'](_0xf4fb0d['shift']());}}}(a259_0x5caa,0xa68e3));import{MYBATIS_DYNAMIC_END_MARKER,MYBATIS_DYNAMIC_START_MARKER,MYBATIS_INCLUDE_MARKER,normalizeSqlForStaticAnalysis}from'./sql-validator.js';export function auditSqlJoinIndexes(_0x5b857d,_0x1e390d){const _0x29216e=a259_0x1e48,_0x4cd640=[],_0x122f1b=normalizeSqlForStaticAnalysis(_0x5b857d),_0x558ba0=(_0x122f1b[_0x29216e(0xff)]?[]:extractJoinFacts(_0x122f1b[_0x29216e(0x10a)]))[_0x29216e(0x11d)](_0x7d9bb7=>{const _0x20a260=_0x29216e;if(_0x7d9bb7['unsupportedPredicate']||_0x7d9bb7['columns'][_0x20a260(0xfd)]===0x0)return _0x4cd640[_0x20a260(0x104)]({'code':'JOIN_PREDICATE_UNSUPPORTED','table':_0x7d9bb7[_0x20a260(0xf3)],'alias':_0x7d9bb7[_0x20a260(0x105)],'columns':_0x7d9bb7[_0x20a260(0x111)],'reason':_0x7d9bb7[_0x20a260(0x112)]??_0x20a260(0xf7)}),{'table':_0x7d9bb7[_0x20a260(0xf3)],'alias':_0x7d9bb7['alias'],'columns':_0x7d9bb7[_0x20a260(0x111)],'status':_0x20a260(0x126)};const _0x3055a0=resolveTableMetadata(_0x1e390d,_0x7d9bb7[_0x20a260(0xf3)]),_0x5c3de9=(_0x3055a0?.['indexes']??[])[_0x20a260(0x11d)](_0x4a226f=>({'index':_0x4a226f,'matchedPrefix':findEqualityPrefix(_0x4a226f[_0x20a260(0x111)],_0x7d9bb7['columns'])}))['filter'](_0x24a682=>_0x24a682['matchedPrefix'][_0x20a260(0xfd)]>0x0),_0x230d00=_0x5c3de9['reduce']((_0x4dc502,_0x323d80)=>!_0x4dc502||_0x323d80[_0x20a260(0xf4)][_0x20a260(0xfd)]>_0x4dc502[_0x20a260(0xf4)][_0x20a260(0xfd)]?_0x323d80:_0x4dc502,_0x5c3de9[0x0]);if(_0x230d00)return{'table':_0x7d9bb7['table'],'alias':_0x7d9bb7['alias'],'columns':_0x7d9bb7[_0x20a260(0x111)],'status':_0x20a260(0x123),'matchedIndex':{..._0x230d00[_0x20a260(0xfc)],'matchedPrefix':_0x230d00[_0x20a260(0xf4)]}};const _0x2b8883=_0x3055a0?.[_0x20a260(0xf9)][_0x20a260(0x129)](_0xfcdc62=>_0xfcdc62['columns'][_0x20a260(0x12d)](_0x18ac08=>_0x7d9bb7[_0x20a260(0x111)][_0x20a260(0x12d)](_0x355cd3=>columnNamesMatch(_0x18ac08,_0x355cd3))))??[];if(_0x2b8883[_0x20a260(0xfd)]>0x0)return _0x4cd640[_0x20a260(0x104)]({'code':_0x20a260(0x109),'table':_0x7d9bb7['table'],'alias':_0x7d9bb7['alias'],'columns':_0x7d9bb7[_0x20a260(0x111)],'reason':_0x20a260(0x133)}),{'table':_0x7d9bb7[_0x20a260(0xf3)],'alias':_0x7d9bb7['alias'],'columns':_0x7d9bb7[_0x20a260(0x111)],'status':_0x20a260(0x114),'candidateIndexes':_0x2b8883};if(_0x3055a0&&_0x3055a0['metadataAvailable']!==![]&&_0x3055a0[_0x20a260(0xf9)][_0x20a260(0xfd)]>0x0&&_0x7d9bb7[_0x20a260(0x111)][_0x20a260(0xfd)]>0x0)return _0x4cd640[_0x20a260(0x104)]({'code':_0x20a260(0x12b),'table':_0x7d9bb7['table'],'alias':_0x7d9bb7[_0x20a260(0x105)],'columns':_0x7d9bb7[_0x20a260(0x111)],'reason':_0x20a260(0xef)}),{'table':_0x7d9bb7['table'],'alias':_0x7d9bb7[_0x20a260(0x105)],'columns':_0x7d9bb7[_0x20a260(0x111)],'status':_0x20a260(0x114)};return _0x4cd640[_0x20a260(0x104)]({'code':_0x20a260(0xfa),'table':_0x7d9bb7[_0x20a260(0xf3)],'alias':_0x7d9bb7['alias'],'columns':_0x7d9bb7['columns'],'reason':_0x3055a0?_0x20a260(0xf2):_0x20a260(0x103)}),{'table':_0x7d9bb7['table'],'alias':_0x7d9bb7[_0x20a260(0x105)],'columns':_0x7d9bb7[_0x20a260(0x111)],'status':_0x20a260(0x126)};});return{'checked':_0x558ba0[_0x29216e(0xfd)]>0x0,'joins':_0x558ba0,'warnings':_0x4cd640};}function extractJoinFacts(_0x35b29b){const _0x378eec=a259_0x1e48,_0x412979=maskNestedQueries(stripSqlNoise(_0x35b29b)),_0x2f5192=maskQuotedIdentifiers(_0x412979),_0x4aec17=[],_0x195614=new Set(),_0x3d09dc=/\b(?:(INNER|LEFT|RIGHT|FULL)(?:\s+OUTER)?\s+)?JOIN\s+([`"\w$.]+)(?:\s+(?:AS\s+)?([`"\w$]+))?\s+ON\s+([\s\S]*?)(?=\s+(?:(?:(?:INNER|LEFT|RIGHT|FULL)(?:\s+OUTER)?\s+)?JOIN\b|(?:WHERE|GROUP\s+BY|ORDER\s+BY|HAVING|LIMIT|UNION)\b)|;|$)/gi;for(const _0x3f1781 of _0x412979[_0x378eec(0xec)](_0x3d09dc)){const _0x2ffa36=_0x3f1781[_0x378eec(0xfc)]??0x0,_0x5f5217=_0x3f1781[0x0][_0x378eec(0x10c)](/\bJOIN\b/i),_0x286708=_0x2ffa36+Math[_0x378eec(0x121)](0x0,_0x5f5217);if(!/^JOIN\b/i[_0x378eec(0xf6)](_0x2f5192['slice'](_0x286708)))continue;_0x195614[_0x378eec(0xf0)](_0x286708);const _0x92733c=normalizeIdentifier(_0x3f1781[0x1]||_0x378eec(0x10e)),_0x47429c=normalizeIdentifier(_0x3f1781[0x2]??''),_0x104ae8=normalizeIdentifier(_0x3f1781[0x3]||_0x47429c['split']('.')['at'](-0x1)||_0x47429c),_0x34697e=[],_0xc6ded8=_0x47429c===_0x378eec(0x136);let _0x147a5d=_0x92733c===_0x378eec(0x10f)||_0x92733c===_0x378eec(0xeb)||_0xc6ded8,_0x5ad6e0=_0x147a5d?_0xc6ded8?_0x378eec(0xed):_0x92733c[_0x378eec(0x119)]()+_0x378eec(0x12e):undefined;const _0xeef860=stripOuterParentheses(_0x3f1781[0x4]??''),_0x4194e1=_0xeef860[_0x378eec(0x12c)](MYBATIS_DYNAMIC_START_MARKER)||_0xeef860[_0x378eec(0x12c)](MYBATIS_DYNAMIC_END_MARKER),_0x3c0060=_0xeef860['includes'](MYBATIS_INCLUDE_MARKER);_0x4194e1&&(_0x147a5d=!![],_0x5ad6e0??=_0x378eec(0xf1));_0x3c0060&&(_0x147a5d=!![],_0x5ad6e0??=_0x378eec(0x132));const _0x3d94e2=_0xeef860['replaceAll'](MYBATIS_DYNAMIC_START_MARKER,'\x20')[_0x378eec(0x11b)](MYBATIS_DYNAMIC_END_MARKER,'\x20')['replaceAll'](MYBATIS_INCLUDE_MARKER,'\x20');hasTopLevelKeyword(_0x3d94e2,'OR')&&(_0x147a5d=!![],_0x5ad6e0??=_0x378eec(0x134));for(const _0x1562d4 of splitTopLevelAnd(_0x3d94e2)){const _0x43357f=stripOuterParentheses(_0x1562d4);if(hasTopLevelKeyword(_0x43357f,'OR')){_0x147a5d=!![],_0x5ad6e0??=_0x378eec(0x134);continue;}const _0x485d19=splitEquality(_0x43357f);if(!_0x485d19){containsColumnReference(_0x1562d4,_0x104ae8)&&(_0x147a5d=!![]);continue;}const _0x2e9195=parseDirectColumnReference(_0x485d19[0x0],_0x104ae8),_0x88303=parseDirectColumnReference(_0x485d19[0x1],_0x104ae8),_0x308e11=containsColumnReference(_0x485d19[0x0],_0x104ae8),_0x138090=containsColumnReference(_0x485d19[0x1],_0x104ae8),_0x3588b7=_0x2e9195&&!_0x138090?_0x2e9195:_0x88303&&!_0x308e11?_0x88303:null;if(_0x3588b7&&!_0x34697e[_0x378eec(0x12c)](_0x3588b7))_0x34697e[_0x378eec(0x104)](_0x3588b7);else!_0x3588b7&&containsColumnReference(_0x1562d4,_0x104ae8)&&(_0x147a5d=!![]);}_0x4aec17[_0x378eec(0x104)]({'table':_0x47429c,'alias':_0x104ae8,'columns':_0x34697e,'unsupportedPredicate':_0x147a5d,'unsupportedReason':_0x5ad6e0,'containsUnresolvedInclude':_0x3c0060,'position':_0x286708});}for(const _0x49e1ff of _0x2f5192[_0x378eec(0xec)](/\bJOIN\b/gi)){const _0x254876=_0x49e1ff[_0x378eec(0xfc)]??0x0;if(_0x195614[_0x378eec(0x108)](_0x254876))continue;const _0x4ad92e=/^\s+([`"\w$.]+)(?:\s+(?:AS\s+)?([`"\w$]+))?/['exec'](_0x412979[_0x378eec(0x102)](_0x254876+_0x49e1ff[0x0][_0x378eec(0xfd)])),_0x54ff34=normalizeIdentifier(_0x4ad92e?.[0x1]||_0x378eec(0x11e)),_0xec05fe=normalizeIdentifier(_0x4ad92e?.[0x2]||''),_0x123ee6=isSqlClauseKeyword(_0xec05fe)?_0x54ff34[_0x378eec(0x125)]('.')['at'](-0x1)||_0x54ff34:_0xec05fe||_0x54ff34[_0x378eec(0x125)]('.')['at'](-0x1)||_0x54ff34;_0x4aec17[_0x378eec(0x104)]({'table':_0x54ff34,'alias':_0x123ee6,'columns':[],'unsupportedPredicate':!![],'unsupportedReason':'Only\x20explicit\x20table\x20JOIN\x20clauses\x20with\x20an\x20ON\x20predicate\x20are\x20supported.','position':_0x254876});}const _0x20767f=_0x2f5192[_0x378eec(0x115)](MYBATIS_INCLUDE_MARKER);return _0x20767f>=0x0&&!_0x4aec17[_0x378eec(0x12d)](_0x2bb28e=>_0x2bb28e[_0x378eec(0x106)])&&_0x4aec17[_0x378eec(0x104)]({'table':_0x378eec(0x11e),'alias':_0x378eec(0x11e),'columns':[],'unsupportedPredicate':!![],'unsupportedReason':_0x378eec(0x131),'containsUnresolvedInclude':!![],'position':_0x20767f}),_0x4aec17['sort']((_0x42bdba,_0xdcdba6)=>_0x42bdba[_0x378eec(0x11c)]-_0xdcdba6[_0x378eec(0x11c)]);}function a259_0x1e48(_0x2471fe,_0x6636fc){_0x2471fe=_0x2471fe-0xea;const _0x5caa56=a259_0x5caa();let _0x1e4815=_0x5caa56[_0x2471fe];return _0x1e4815;}function stripSqlNoise(_0x51e47f){const _0x1eabdf=a259_0x1e48,_0x43a383=Array[_0x1eabdf(0x135)](_0x51e47f),_0x2dea8a=(_0x459e11,_0x4e483b)=>{for(let _0x6deb0d=_0x459e11;_0x6deb0d<_0x4e483b;_0x6deb0d+=0x1){_0x43a383[_0x6deb0d]!=='\x0a'&&_0x43a383[_0x6deb0d]!=='\x0d'&&(_0x43a383[_0x6deb0d]='\x20');}};for(let _0x44b55e=0x0;_0x44b55e<_0x43a383[_0x1eabdf(0xfd)];_0x44b55e+=0x1){const _0x55292e=_0x43a383[_0x44b55e],_0x294872=_0x43a383[_0x44b55e+0x1];if(_0x55292e==='\x27'||_0x55292e==='\x22'||_0x55292e==='`'){const _0x12efb1=_0x55292e,_0x45c561=_0x44b55e;_0x44b55e+=0x1;while(_0x44b55e<_0x43a383[_0x1eabdf(0xfd)]){if(_0x43a383[_0x44b55e]==='\x5c'&&_0x44b55e+0x1<_0x43a383[_0x1eabdf(0xfd)]){_0x44b55e+=0x2;continue;}if(_0x43a383[_0x44b55e]!==_0x12efb1){_0x44b55e+=0x1;continue;}if(_0x43a383[_0x44b55e+0x1]===_0x12efb1){_0x44b55e+=0x2;continue;}break;}if(_0x12efb1==='\x27')_0x2dea8a(_0x45c561,Math['min'](_0x44b55e+0x1,_0x43a383['length']));continue;}if(_0x55292e==='-'&&_0x294872==='-'){const _0x3d3e42=_0x44b55e;while(_0x44b55e<_0x43a383[_0x1eabdf(0xfd)]&&_0x43a383[_0x44b55e]!=='\x0a')_0x44b55e+=0x1;_0x2dea8a(_0x3d3e42,_0x44b55e);continue;}if(_0x55292e==='/'&&_0x294872==='*'){const _0x533771=_0x44b55e;_0x44b55e+=0x2;while(_0x44b55e<_0x43a383[_0x1eabdf(0xfd)]&&!(_0x43a383[_0x44b55e]==='*'&&_0x43a383[_0x44b55e+0x1]==='/')){_0x44b55e+=0x1;}_0x44b55e=Math[_0x1eabdf(0x12f)](_0x44b55e+0x1,_0x43a383[_0x1eabdf(0xfd)]-0x1),_0x2dea8a(_0x533771,_0x44b55e+0x1);continue;}if(_0x55292e==='#'&&_0x294872!=='{'){const _0xa03199=_0x44b55e;while(_0x44b55e<_0x43a383[_0x1eabdf(0xfd)]&&_0x43a383[_0x44b55e]!=='\x0a')_0x44b55e+=0x1;_0x2dea8a(_0xa03199,_0x44b55e);continue;}if((_0x55292e==='#'||_0x55292e==='$')&&_0x294872==='{'){const _0x5e1750=_0x44b55e;_0x44b55e+=0x2;while(_0x44b55e<_0x43a383[_0x1eabdf(0xfd)]&&_0x43a383[_0x44b55e]!=='}')_0x44b55e+=0x1;_0x2dea8a(_0x5e1750,Math[_0x1eabdf(0x12f)](_0x44b55e+0x1,_0x43a383[_0x1eabdf(0xfd)]));}}return _0x43a383[_0x1eabdf(0xfb)]('');}function maskQuotedIdentifiers(_0x2d1349){const _0x320195=a259_0x1e48,_0x3a67fc=Array[_0x320195(0x135)](_0x2d1349);for(let _0x5cc49c=0x0;_0x5cc49c<_0x3a67fc[_0x320195(0xfd)];_0x5cc49c+=0x1){const _0x370491=_0x3a67fc[_0x5cc49c];if(_0x370491!=='\x22'&&_0x370491!=='`')continue;_0x5cc49c+=0x1;while(_0x5cc49c<_0x3a67fc[_0x320195(0xfd)]){if(_0x3a67fc[_0x5cc49c]===_0x370491){if(_0x3a67fc[_0x5cc49c+0x1]===_0x370491){_0x3a67fc[_0x5cc49c]='\x20',_0x3a67fc[_0x5cc49c+0x1]='\x20',_0x5cc49c+=0x2;continue;}break;}_0x3a67fc[_0x5cc49c]='\x20',_0x5cc49c+=0x1;}}return _0x3a67fc[_0x320195(0xfb)]('');}function maskNestedQueries(_0xb62fc4){const _0x534b39=a259_0x1e48,_0xb90153=Array[_0x534b39(0x135)](_0xb62fc4);for(let _0x2bcaca=0x0;_0x2bcaca<_0xb90153[_0x534b39(0xfd)];_0x2bcaca+=0x1){if(_0xb90153[_0x2bcaca]!=='(')continue;const _0xb1225b=_0xb62fc4[_0x534b39(0x102)](_0x2bcaca+0x1);if(!/^\s*(?:SELECT|WITH)\b/i[_0x534b39(0xf6)](_0xb1225b))continue;let _0x33b36f=0x1,_0x314a6b=_0x2bcaca+0x1;for(;_0x314a6b<_0xb90153['length']&&_0x33b36f>0x0;_0x314a6b+=0x1){if(_0xb90153[_0x314a6b]==='(')_0x33b36f+=0x1;if(_0xb90153[_0x314a6b]===')')_0x33b36f-=0x1;}if(_0x33b36f!==0x0)continue;for(let _0x49f619=_0x2bcaca;_0x49f619<_0x314a6b;_0x49f619+=0x1){_0xb90153[_0x49f619]='\x20';}const _0x5b84ac=_0x534b39(0x136);for(let _0x4483d0=0x0;_0x4483d0<_0x5b84ac['length']&&_0x2bcaca+_0x4483d0<_0x314a6b;_0x4483d0+=0x1){_0xb90153[_0x2bcaca+_0x4483d0]=_0x5b84ac[_0x4483d0];}_0x2bcaca=_0x314a6b-0x1;}return _0xb90153['join']('');}function splitTopLevelAnd(_0x21d8ef){const _0x1dfeb5=a259_0x1e48,_0x20104b=[];let _0x1500e1=0x0,_0x3b6fe2=0x0;for(let _0x5ab60c=0x0;_0x5ab60c<_0x21d8ef[_0x1dfeb5(0xfd)];_0x5ab60c+=0x1){const _0x1b016c=_0x21d8ef[_0x5ab60c];if(_0x1b016c==='(')_0x1500e1+=0x1;if(_0x1b016c===')')_0x1500e1=Math[_0x1dfeb5(0x121)](0x0,_0x1500e1-0x1);_0x1500e1===0x0&&_0x21d8ef[_0x1dfeb5(0x102)](_0x5ab60c)[_0x1dfeb5(0x116)](/^AND\b/i)&&(_0x5ab60c===0x0||/\s/[_0x1dfeb5(0xf6)](_0x21d8ef[_0x5ab60c-0x1]??''))&&(_0x20104b[_0x1dfeb5(0x104)](_0x21d8ef[_0x1dfeb5(0x102)](_0x3b6fe2,_0x5ab60c)[_0x1dfeb5(0x100)]()),_0x5ab60c+=0x2,_0x3b6fe2=_0x5ab60c+0x1);}const _0x5a247e=_0x21d8ef[_0x1dfeb5(0x102)](_0x3b6fe2)[_0x1dfeb5(0x100)]();if(_0x5a247e)_0x20104b[_0x1dfeb5(0x104)](_0x5a247e);return _0x20104b;}function hasTopLevelKeyword(_0x3927b9,_0x4492e3){const _0xbafcd3=a259_0x1e48;let _0x114ac5=0x0;for(let _0x504718=0x0;_0x504718<_0x3927b9['length'];_0x504718+=0x1){const _0x4d934c=_0x3927b9[_0x504718];if(_0x4d934c==='(')_0x114ac5+=0x1;if(_0x4d934c===')')_0x114ac5=Math['max'](0x0,_0x114ac5-0x1);if(_0x114ac5!==0x0)continue;const _0x38ae8f=_0x3927b9['slice'](_0x504718,_0x504718+_0x4492e3['length']),_0x15d142=_0x3927b9[_0x504718-0x1]??'\x20',_0x1bc0e1=_0x3927b9[_0x504718+_0x4492e3[_0xbafcd3(0xfd)]]??'\x20';if(_0x38ae8f['toUpperCase']()===_0x4492e3['toUpperCase']()&&!/[\w$]/['test'](_0x15d142)&&!/[\w$]/[_0xbafcd3(0xf6)](_0x1bc0e1))return!![];}return![];}function splitEquality(_0xce940e){const _0x2fbb88=a259_0x1e48,_0x494859=stripOuterParentheses(_0xce940e);let _0x5a726a=0x0,_0x1f12dd;for(let _0xa38059=0x0;_0xa38059<_0x494859[_0x2fbb88(0xfd)];_0xa38059+=0x1){const _0x42a6d7=_0x494859[_0xa38059];if(_0x42a6d7==='(')_0x5a726a+=0x1;if(_0x42a6d7===')')_0x5a726a=Math['max'](0x0,_0x5a726a-0x1);const _0x4c9c92=_0x494859[_0xa38059-0x1]??'',_0x80aedc=_0x494859[_0xa38059+0x1]??'';if(_0x42a6d7==='='&&_0x5a726a===0x0&&!/[!<>=:]/[_0x2fbb88(0xf6)](_0x4c9c92)&&_0x80aedc!=='='){if(_0x1f12dd!==undefined)return null;_0x1f12dd=_0xa38059;}}return _0x1f12dd===undefined?null:[_0x494859[_0x2fbb88(0x102)](0x0,_0x1f12dd)[_0x2fbb88(0x100)](),_0x494859[_0x2fbb88(0x102)](_0x1f12dd+0x1)[_0x2fbb88(0x100)]()];}function parseDirectColumnReference(_0x15cf57,_0x48b6d0){const _0x495a0a=a259_0x1e48,_0x2bcc4f=/^([`"]?[\w$]+[`"]?)\s*\.\s*([`"]?[\w$]+[`"]?)$/[_0x495a0a(0x11f)](stripOuterParentheses(_0x15cf57));if(!_0x2bcc4f)return null;if(normalizeIdentifier(_0x2bcc4f[0x1]??'')!==normalizeIdentifier(_0x48b6d0))return null;return normalizeIdentifier(_0x2bcc4f[0x2]??'');}function a259_0x5caa(){const _0x5af95c=['1AJaONB','slice','No\x20dataset\x20metadata\x20matched\x20the\x20JOIN\x20table.','push','alias','containsUnresolvedInclude','(?:^|[^\x5cw$])','has','JOIN_INDEX_NOT_USABLE','sql','26559SdJHKI','search','where','INNER','right','cross','columns','unsupportedReason','using','warning','indexOf','match','830efskbl','465346VuGyVD','toUpperCase','2009130uvJifL','replaceAll','position','map','unknown','exec','toLowerCase','max','left','covered','68bfNymA','split','unavailable','natural','tableName','filter','6430237GMAoSK','JOIN_INDEX_MISSING','includes','some','\x20JOIN\x20direction\x20is\x20not\x20supported\x20by\x20static\x20index\x20auditing.','min','14bSyEIq','MyBatis\x20<include>\x20fragments\x20cannot\x20be\x20expanded\x20for\x20JOIN\x20auditing.','MyBatis\x20<include>\x20JOIN\x20fragments\x20cannot\x20be\x20expanded\x20statically.','Relevant\x20columns\x20do\x20not\x20form\x20a\x20complete\x20leftmost\x20index\x20prefix.','OR-connected\x20JOIN\x20predicates\x20are\x20not\x20supported.','from','__sq__','141438ksqZHr','4323216vyNaZH','startsWith','full','matchAll','Derived-table\x20JOIN\x20targets\x20are\x20not\x20supported.','replace','No\x20reported\x20index\x20contains\x20the\x20JOIN\x20access\x20columns.','add','MyBatis\x20dynamic\x20JOIN\x20predicates\x20cannot\x20be\x20audited\x20deterministically.','The\x20dataset\x20returned\x20no\x20distinguishable\x20index\x20metadata.','table','matchedPrefix','endsWith','test','Not\x20every\x20JOIN\x20target\x20predicate\x20could\x20be\x20audited\x20safely.','874975iqZAZJ','indexes','INDEX_METADATA_UNAVAILABLE','join','index','length','\x5cs*\x5c.\x5cs*[\x5cw$]+','error','trim'];a259_0x5caa=function(){return _0x5af95c;};return a259_0x5caa();}function containsColumnReference(_0x19ddd0,_0x45f269){const _0x13dbdd=a259_0x1e48,_0x5415cf=_0x19ddd0[_0x13dbdd(0xee)](/[`"]/g,''),_0x34cbe2=_0x45f269[_0x13dbdd(0xee)](/[.*+?^${}()|[\]\\]/g,'\x5c$&');return new RegExp(_0x13dbdd(0x107)+_0x34cbe2+_0x13dbdd(0xfe),'i')[_0x13dbdd(0xf6)](_0x5415cf);}function findEqualityPrefix(_0x1ae108,_0x18b2c5){const _0x17baad=a259_0x1e48,_0x31e1e4=new Set(_0x18b2c5[_0x17baad(0x11d)](normalizeIdentifier)),_0xabb20d=[];for(const _0x13574c of _0x1ae108){if(!_0x31e1e4['has'](normalizeIdentifier(_0x13574c)))break;_0xabb20d['push'](_0x13574c);}return _0xabb20d;}function resolveTableMetadata(_0x2ed4ab,_0x2f6dbf){const _0x4b240a=a259_0x1e48,_0x39cb41=normalizeIdentifier(_0x2f6dbf),_0x408f02=_0x2ed4ab[_0x4b240a(0x129)](_0x972bde=>normalizeIdentifier(_0x972bde[_0x4b240a(0x128)])===_0x39cb41);if(_0x408f02[_0x4b240a(0xfd)]===0x1)return _0x408f02[0x0];const _0x47908d=_0x39cb41[_0x4b240a(0x12c)]('.'),_0x1fb51a=_0x39cb41['split']('.')['at'](-0x1),_0x39bbc4=_0x2ed4ab[_0x4b240a(0x129)](_0x39c7e1=>{const _0x4dc33d=_0x4b240a,_0x404acf=normalizeIdentifier(_0x39c7e1['tableName']);if(_0x47908d&&_0x404acf[_0x4dc33d(0x12c)]('.'))return![];return _0x404acf['split']('.')['at'](-0x1)===_0x1fb51a;});return _0x39bbc4[_0x4b240a(0xfd)]===0x1?_0x39bbc4[0x0]:undefined;}function columnNamesMatch(_0x35e7c9,_0x1c9f4b){return normalizeIdentifier(_0x35e7c9)===normalizeIdentifier(_0x1c9f4b);}function normalizeIdentifier(_0xf828f1){const _0xa848c1=a259_0x1e48;return _0xf828f1[_0xa848c1(0xee)](/[`"]/g,'')['trim']()[_0xa848c1(0x120)]();}function isSqlClauseKeyword(_0x1e77b8){const _0x108dee=a259_0x1e48;return new Set(['on',_0x108dee(0x113),_0x108dee(0x10d),_0x108dee(0xfb),'inner',_0x108dee(0x122),_0x108dee(0x10f),_0x108dee(0xeb),_0x108dee(0x110),_0x108dee(0x127)])[_0x108dee(0x108)](_0x1e77b8);}function stripOuterParentheses(_0xe949c1){const _0x1d874e=a259_0x1e48;let _0xf98686=_0xe949c1[_0x1d874e(0x100)]();while(_0xf98686[_0x1d874e(0xea)]('(')&&_0xf98686[_0x1d874e(0xf5)](')')){let _0x8f180b=0x0,_0x4a35ae=!![];for(let _0x5282d1=0x0;_0x5282d1<_0xf98686[_0x1d874e(0xfd)];_0x5282d1+=0x1){if(_0xf98686[_0x5282d1]==='(')_0x8f180b+=0x1;if(_0xf98686[_0x5282d1]===')')_0x8f180b-=0x1;if(_0x8f180b===0x0&&_0x5282d1<_0xf98686['length']-0x1){_0x4a35ae=![];break;}}if(!_0x4a35ae||_0x8f180b!==0x0)break;_0xf98686=_0xf98686[_0x1d874e(0x102)](0x1,-0x1)[_0x1d874e(0x100)]();}return _0xf98686;}
|
|
1
|
+
(function(_0x3684c2,_0x1682d0){const _0x28636f=a277_0x4c14,_0x36d1cf=_0x3684c2();while(!![]){try{const _0x4b44ae=parseInt(_0x28636f(0x10e))/0x1*(-parseInt(_0x28636f(0x11c))/0x2)+parseInt(_0x28636f(0xfe))/0x3*(-parseInt(_0x28636f(0x139))/0x4)+parseInt(_0x28636f(0x111))/0x5*(-parseInt(_0x28636f(0x11f))/0x6)+parseInt(_0x28636f(0x13b))/0x7+-parseInt(_0x28636f(0x124))/0x8*(parseInt(_0x28636f(0x116))/0x9)+parseInt(_0x28636f(0x13c))/0xa+parseInt(_0x28636f(0x127))/0xb;if(_0x4b44ae===_0x1682d0)break;else _0x36d1cf['push'](_0x36d1cf['shift']());}catch(_0x1d0192){_0x36d1cf['push'](_0x36d1cf['shift']());}}}(a277_0x2483,0x6c298));function a277_0x2483(){const _0x3c1839=['natural','265040JuoFyI','filter','reduce','3409835IzXsiL','indexes','tableName','where','from','JOIN_INDEX_NOT_USABLE','metadataAvailable','length','columns','min','test','inner','warning','matchedPrefix','replaceAll','has','replace','MyBatis\x20<include>\x20fragments\x20cannot\x20be\x20expanded\x20for\x20JOIN\x20auditing.','548ChmkKq','No\x20dataset\x20metadata\x20matched\x20the\x20JOIN\x20table.','1646400skXWwZ','5240180BcxYIS','trim','matchAll','match','exec','left','slice','push','split','includes','Not\x20every\x20JOIN\x20target\x20predicate\x20could\x20be\x20audited\x20safely.','using','index','unsupportedReason','toLowerCase','Relevant\x20columns\x20do\x20not\x20form\x20a\x20complete\x20leftmost\x20index\x20prefix.','sql','4461swRLbr','endsWith','No\x20reported\x20index\x20contains\x20the\x20JOIN\x20access\x20columns.','\x5c$&','alias','\x20JOIN\x20direction\x20is\x20not\x20supported\x20by\x20static\x20index\x20auditing.','(?:^|[^\x5cw$])','position','unsupportedPredicate','startsWith','__sq__','\x5cs*\x5c.\x5cs*[\x5cw$]+','JOIN_INDEX_MISSING','OR-connected\x20JOIN\x20predicates\x20are\x20not\x20supported.','MyBatis\x20dynamic\x20JOIN\x20predicates\x20cannot\x20be\x20audited\x20deterministically.','table','1rmFTRK','sort','indexOf','105KXhmdR','join','some','INNER','max','18mQQRnZ','cross','Derived-table\x20JOIN\x20targets\x20are\x20not\x20supported.','containsUnresolvedInclude','toUpperCase','unknown','574582KVnDqh','error','map','19686sWTlFB','Only\x20explicit\x20table\x20JOIN\x20clauses\x20with\x20an\x20ON\x20predicate\x20are\x20supported.','unavailable','covered'];a277_0x2483=function(){return _0x3c1839;};return a277_0x2483();}import{MYBATIS_DYNAMIC_END_MARKER,MYBATIS_DYNAMIC_START_MARKER,MYBATIS_INCLUDE_MARKER,normalizeSqlForStaticAnalysis}from'./sql-validator.js';export function auditSqlJoinIndexes(_0x1d1687,_0x2f83cd){const _0x49236a=a277_0x4c14,_0x10b078=[],_0x28360f=normalizeSqlForStaticAnalysis(_0x1d1687),_0xeb7513=(_0x28360f[_0x49236a(0x11d)]?[]:extractJoinFacts(_0x28360f[_0x49236a(0xfd)]))[_0x49236a(0x11e)](_0x2f7051=>{const _0x49342c=_0x49236a;if(_0x2f7051[_0x49342c(0x106)]||_0x2f7051[_0x49342c(0x12f)][_0x49342c(0x12e)]===0x0)return _0x10b078[_0x49342c(0xf4)]({'code':'JOIN_PREDICATE_UNSUPPORTED','table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051['alias'],'columns':_0x2f7051[_0x49342c(0x12f)],'reason':_0x2f7051[_0x49342c(0xfa)]??_0x49342c(0xf7)}),{'table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051[_0x49342c(0x102)],'columns':_0x2f7051[_0x49342c(0x12f)],'status':_0x49342c(0x121)};const _0x3d061c=resolveTableMetadata(_0x2f83cd,_0x2f7051[_0x49342c(0x10d)]),_0x766797=(_0x3d061c?.[_0x49342c(0x128)]??[])['map'](_0x165c88=>({'index':_0x165c88,'matchedPrefix':findEqualityPrefix(_0x165c88['columns'],_0x2f7051[_0x49342c(0x12f)])}))[_0x49342c(0x125)](_0x5dcf6a=>_0x5dcf6a[_0x49342c(0x134)]['length']>0x0),_0x46b775=_0x766797[_0x49342c(0x126)]((_0x399ad3,_0x2597e7)=>!_0x399ad3||_0x2597e7[_0x49342c(0x134)][_0x49342c(0x12e)]>_0x399ad3['matchedPrefix'][_0x49342c(0x12e)]?_0x2597e7:_0x399ad3,_0x766797[0x0]);if(_0x46b775)return{'table':_0x2f7051['table'],'alias':_0x2f7051[_0x49342c(0x102)],'columns':_0x2f7051[_0x49342c(0x12f)],'status':_0x49342c(0x122),'matchedIndex':{..._0x46b775[_0x49342c(0xf9)],'matchedPrefix':_0x46b775[_0x49342c(0x134)]}};const _0x532ec0=_0x3d061c?.[_0x49342c(0x128)][_0x49342c(0x125)](_0x49d626=>_0x49d626[_0x49342c(0x12f)][_0x49342c(0x113)](_0x342249=>_0x2f7051[_0x49342c(0x12f)][_0x49342c(0x113)](_0x1c712a=>columnNamesMatch(_0x342249,_0x1c712a))))??[];if(_0x532ec0[_0x49342c(0x12e)]>0x0)return _0x10b078[_0x49342c(0xf4)]({'code':_0x49342c(0x12c),'table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051[_0x49342c(0x102)],'columns':_0x2f7051[_0x49342c(0x12f)],'reason':_0x49342c(0xfc)}),{'table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051[_0x49342c(0x102)],'columns':_0x2f7051['columns'],'status':_0x49342c(0x133),'candidateIndexes':_0x532ec0};if(_0x3d061c&&_0x3d061c[_0x49342c(0x12d)]!==![]&&_0x3d061c[_0x49342c(0x128)][_0x49342c(0x12e)]>0x0&&_0x2f7051[_0x49342c(0x12f)]['length']>0x0)return _0x10b078[_0x49342c(0xf4)]({'code':_0x49342c(0x10a),'table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051[_0x49342c(0x102)],'columns':_0x2f7051[_0x49342c(0x12f)],'reason':_0x49342c(0x100)}),{'table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051['alias'],'columns':_0x2f7051[_0x49342c(0x12f)],'status':_0x49342c(0x133)};return _0x10b078[_0x49342c(0xf4)]({'code':'INDEX_METADATA_UNAVAILABLE','table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051[_0x49342c(0x102)],'columns':_0x2f7051['columns'],'reason':_0x3d061c?'The\x20dataset\x20returned\x20no\x20distinguishable\x20index\x20metadata.':_0x49342c(0x13a)}),{'table':_0x2f7051[_0x49342c(0x10d)],'alias':_0x2f7051[_0x49342c(0x102)],'columns':_0x2f7051[_0x49342c(0x12f)],'status':_0x49342c(0x121)};});return{'checked':_0xeb7513[_0x49236a(0x12e)]>0x0,'joins':_0xeb7513,'warnings':_0x10b078};}function extractJoinFacts(_0x352946){const _0x2c1406=a277_0x4c14,_0x54a0ab=maskNestedQueries(stripSqlNoise(_0x352946)),_0xe5ebe6=maskQuotedIdentifiers(_0x54a0ab),_0x3f7532=[],_0x9ac62a=new Set(),_0x3ada5f=/\b(?:(INNER|LEFT|RIGHT|FULL)(?:\s+OUTER)?\s+)?JOIN\s+([`"\w$.]+)(?:\s+(?:AS\s+)?([`"\w$]+))?\s+ON\s+([\s\S]*?)(?=\s+(?:(?:(?:INNER|LEFT|RIGHT|FULL)(?:\s+OUTER)?\s+)?JOIN\b|(?:WHERE|GROUP\s+BY|ORDER\s+BY|HAVING|LIMIT|UNION)\b)|;|$)/gi;for(const _0x192fb8 of _0x54a0ab[_0x2c1406(0x13e)](_0x3ada5f)){const _0x1705b3=_0x192fb8[_0x2c1406(0xf9)]??0x0,_0x3e4c22=_0x192fb8[0x0]['search'](/\bJOIN\b/i),_0xaa5fa9=_0x1705b3+Math[_0x2c1406(0x115)](0x0,_0x3e4c22);if(!/^JOIN\b/i[_0x2c1406(0x131)](_0xe5ebe6[_0x2c1406(0xf3)](_0xaa5fa9)))continue;_0x9ac62a['add'](_0xaa5fa9);const _0x15cb31=normalizeIdentifier(_0x192fb8[0x1]||_0x2c1406(0x114)),_0x2a48a2=normalizeIdentifier(_0x192fb8[0x2]??''),_0x5719c9=normalizeIdentifier(_0x192fb8[0x3]||_0x2a48a2[_0x2c1406(0xf5)]('.')['at'](-0x1)||_0x2a48a2),_0x2d1aa9=[],_0x3cb12c=_0x2a48a2===_0x2c1406(0x108);let _0x3984d2=_0x15cb31==='right'||_0x15cb31==='full'||_0x3cb12c,_0x27e704=_0x3984d2?_0x3cb12c?_0x2c1406(0x118):_0x15cb31[_0x2c1406(0x11a)]()+_0x2c1406(0x103):undefined;const _0x198d43=stripOuterParentheses(_0x192fb8[0x4]??''),_0x2f0267=_0x198d43[_0x2c1406(0xf6)](MYBATIS_DYNAMIC_START_MARKER)||_0x198d43[_0x2c1406(0xf6)](MYBATIS_DYNAMIC_END_MARKER),_0x4929fc=_0x198d43[_0x2c1406(0xf6)](MYBATIS_INCLUDE_MARKER);_0x2f0267&&(_0x3984d2=!![],_0x27e704??=_0x2c1406(0x10c));_0x4929fc&&(_0x3984d2=!![],_0x27e704??='MyBatis\x20<include>\x20JOIN\x20fragments\x20cannot\x20be\x20expanded\x20statically.');const _0x4de730=_0x198d43[_0x2c1406(0x135)](MYBATIS_DYNAMIC_START_MARKER,'\x20')['replaceAll'](MYBATIS_DYNAMIC_END_MARKER,'\x20')[_0x2c1406(0x135)](MYBATIS_INCLUDE_MARKER,'\x20');hasTopLevelKeyword(_0x4de730,'OR')&&(_0x3984d2=!![],_0x27e704??=_0x2c1406(0x10b));for(const _0x4dcdb4 of splitTopLevelAnd(_0x4de730)){const _0x31bd05=stripOuterParentheses(_0x4dcdb4);if(hasTopLevelKeyword(_0x31bd05,'OR')){_0x3984d2=!![],_0x27e704??=_0x2c1406(0x10b);continue;}const _0x1c2ae8=splitEquality(_0x31bd05);if(!_0x1c2ae8){containsColumnReference(_0x4dcdb4,_0x5719c9)&&(_0x3984d2=!![]);continue;}const _0x108984=parseDirectColumnReference(_0x1c2ae8[0x0],_0x5719c9),_0x4c64df=parseDirectColumnReference(_0x1c2ae8[0x1],_0x5719c9),_0x598ccd=containsColumnReference(_0x1c2ae8[0x0],_0x5719c9),_0x3e1a79=containsColumnReference(_0x1c2ae8[0x1],_0x5719c9),_0x131318=_0x108984&&!_0x3e1a79?_0x108984:_0x4c64df&&!_0x598ccd?_0x4c64df:null;if(_0x131318&&!_0x2d1aa9[_0x2c1406(0xf6)](_0x131318))_0x2d1aa9[_0x2c1406(0xf4)](_0x131318);else!_0x131318&&containsColumnReference(_0x4dcdb4,_0x5719c9)&&(_0x3984d2=!![]);}_0x3f7532[_0x2c1406(0xf4)]({'table':_0x2a48a2,'alias':_0x5719c9,'columns':_0x2d1aa9,'unsupportedPredicate':_0x3984d2,'unsupportedReason':_0x27e704,'containsUnresolvedInclude':_0x4929fc,'position':_0xaa5fa9});}for(const _0x1068c4 of _0xe5ebe6[_0x2c1406(0x13e)](/\bJOIN\b/gi)){const _0x2f1cdb=_0x1068c4[_0x2c1406(0xf9)]??0x0;if(_0x9ac62a[_0x2c1406(0x136)](_0x2f1cdb))continue;const _0x1d6ead=/^\s+([`"\w$.]+)(?:\s+(?:AS\s+)?([`"\w$]+))?/[_0x2c1406(0xf1)](_0x54a0ab[_0x2c1406(0xf3)](_0x2f1cdb+_0x1068c4[0x0][_0x2c1406(0x12e)])),_0x3ae40b=normalizeIdentifier(_0x1d6ead?.[0x1]||_0x2c1406(0x11b)),_0x285157=normalizeIdentifier(_0x1d6ead?.[0x2]||''),_0x5ac1bd=isSqlClauseKeyword(_0x285157)?_0x3ae40b['split']('.')['at'](-0x1)||_0x3ae40b:_0x285157||_0x3ae40b[_0x2c1406(0xf5)]('.')['at'](-0x1)||_0x3ae40b;_0x3f7532[_0x2c1406(0xf4)]({'table':_0x3ae40b,'alias':_0x5ac1bd,'columns':[],'unsupportedPredicate':!![],'unsupportedReason':_0x2c1406(0x120),'position':_0x2f1cdb});}const _0x45db59=_0xe5ebe6[_0x2c1406(0x110)](MYBATIS_INCLUDE_MARKER);return _0x45db59>=0x0&&!_0x3f7532[_0x2c1406(0x113)](_0x33e27f=>_0x33e27f[_0x2c1406(0x119)])&&_0x3f7532['push']({'table':_0x2c1406(0x11b),'alias':_0x2c1406(0x11b),'columns':[],'unsupportedPredicate':!![],'unsupportedReason':_0x2c1406(0x138),'containsUnresolvedInclude':!![],'position':_0x45db59}),_0x3f7532[_0x2c1406(0x10f)]((_0x32c41c,_0x1afff3)=>_0x32c41c[_0x2c1406(0x105)]-_0x1afff3[_0x2c1406(0x105)]);}function stripSqlNoise(_0x2c7172){const _0x191a65=a277_0x4c14,_0x191cb1=Array['from'](_0x2c7172),_0x433212=(_0x1a726f,_0x2507fc)=>{for(let _0x2e1ad4=_0x1a726f;_0x2e1ad4<_0x2507fc;_0x2e1ad4+=0x1){_0x191cb1[_0x2e1ad4]!=='\x0a'&&_0x191cb1[_0x2e1ad4]!=='\x0d'&&(_0x191cb1[_0x2e1ad4]='\x20');}};for(let _0x48d696=0x0;_0x48d696<_0x191cb1[_0x191a65(0x12e)];_0x48d696+=0x1){const _0x4c9f14=_0x191cb1[_0x48d696],_0x141e62=_0x191cb1[_0x48d696+0x1];if(_0x4c9f14==='\x27'||_0x4c9f14==='\x22'||_0x4c9f14==='`'){const _0xdaf49f=_0x4c9f14,_0x480b87=_0x48d696;_0x48d696+=0x1;while(_0x48d696<_0x191cb1[_0x191a65(0x12e)]){if(_0x191cb1[_0x48d696]==='\x5c'&&_0x48d696+0x1<_0x191cb1['length']){_0x48d696+=0x2;continue;}if(_0x191cb1[_0x48d696]!==_0xdaf49f){_0x48d696+=0x1;continue;}if(_0x191cb1[_0x48d696+0x1]===_0xdaf49f){_0x48d696+=0x2;continue;}break;}if(_0xdaf49f==='\x27')_0x433212(_0x480b87,Math[_0x191a65(0x130)](_0x48d696+0x1,_0x191cb1['length']));continue;}if(_0x4c9f14==='-'&&_0x141e62==='-'){const _0x15fb12=_0x48d696;while(_0x48d696<_0x191cb1[_0x191a65(0x12e)]&&_0x191cb1[_0x48d696]!=='\x0a')_0x48d696+=0x1;_0x433212(_0x15fb12,_0x48d696);continue;}if(_0x4c9f14==='/'&&_0x141e62==='*'){const _0xcc9f20=_0x48d696;_0x48d696+=0x2;while(_0x48d696<_0x191cb1[_0x191a65(0x12e)]&&!(_0x191cb1[_0x48d696]==='*'&&_0x191cb1[_0x48d696+0x1]==='/')){_0x48d696+=0x1;}_0x48d696=Math[_0x191a65(0x130)](_0x48d696+0x1,_0x191cb1[_0x191a65(0x12e)]-0x1),_0x433212(_0xcc9f20,_0x48d696+0x1);continue;}if(_0x4c9f14==='#'&&_0x141e62!=='{'){const _0x47615e=_0x48d696;while(_0x48d696<_0x191cb1[_0x191a65(0x12e)]&&_0x191cb1[_0x48d696]!=='\x0a')_0x48d696+=0x1;_0x433212(_0x47615e,_0x48d696);continue;}if((_0x4c9f14==='#'||_0x4c9f14==='$')&&_0x141e62==='{'){const _0xd1144e=_0x48d696;_0x48d696+=0x2;while(_0x48d696<_0x191cb1[_0x191a65(0x12e)]&&_0x191cb1[_0x48d696]!=='}')_0x48d696+=0x1;_0x433212(_0xd1144e,Math[_0x191a65(0x130)](_0x48d696+0x1,_0x191cb1[_0x191a65(0x12e)]));}}return _0x191cb1[_0x191a65(0x112)]('');}function maskQuotedIdentifiers(_0x260016){const _0x2a48f4=a277_0x4c14,_0x5068d4=Array[_0x2a48f4(0x12b)](_0x260016);for(let _0x406b96=0x0;_0x406b96<_0x5068d4[_0x2a48f4(0x12e)];_0x406b96+=0x1){const _0x599f18=_0x5068d4[_0x406b96];if(_0x599f18!=='\x22'&&_0x599f18!=='`')continue;_0x406b96+=0x1;while(_0x406b96<_0x5068d4['length']){if(_0x5068d4[_0x406b96]===_0x599f18){if(_0x5068d4[_0x406b96+0x1]===_0x599f18){_0x5068d4[_0x406b96]='\x20',_0x5068d4[_0x406b96+0x1]='\x20',_0x406b96+=0x2;continue;}break;}_0x5068d4[_0x406b96]='\x20',_0x406b96+=0x1;}}return _0x5068d4[_0x2a48f4(0x112)]('');}function maskNestedQueries(_0x399857){const _0x37f0c8=a277_0x4c14,_0x1ad39b=Array[_0x37f0c8(0x12b)](_0x399857);for(let _0x453da9=0x0;_0x453da9<_0x1ad39b[_0x37f0c8(0x12e)];_0x453da9+=0x1){if(_0x1ad39b[_0x453da9]!=='(')continue;const _0x5160e7=_0x399857[_0x37f0c8(0xf3)](_0x453da9+0x1);if(!/^\s*(?:SELECT|WITH)\b/i['test'](_0x5160e7))continue;let _0x36fe88=0x1,_0x3997ab=_0x453da9+0x1;for(;_0x3997ab<_0x1ad39b['length']&&_0x36fe88>0x0;_0x3997ab+=0x1){if(_0x1ad39b[_0x3997ab]==='(')_0x36fe88+=0x1;if(_0x1ad39b[_0x3997ab]===')')_0x36fe88-=0x1;}if(_0x36fe88!==0x0)continue;for(let _0x57a47d=_0x453da9;_0x57a47d<_0x3997ab;_0x57a47d+=0x1){_0x1ad39b[_0x57a47d]='\x20';}const _0x4815e8=_0x37f0c8(0x108);for(let _0x49aeaf=0x0;_0x49aeaf<_0x4815e8[_0x37f0c8(0x12e)]&&_0x453da9+_0x49aeaf<_0x3997ab;_0x49aeaf+=0x1){_0x1ad39b[_0x453da9+_0x49aeaf]=_0x4815e8[_0x49aeaf];}_0x453da9=_0x3997ab-0x1;}return _0x1ad39b[_0x37f0c8(0x112)]('');}function splitTopLevelAnd(_0x347d47){const _0x2ec11f=a277_0x4c14,_0x21905b=[];let _0x83c4dd=0x0,_0x51e67e=0x0;for(let _0x2b90d3=0x0;_0x2b90d3<_0x347d47[_0x2ec11f(0x12e)];_0x2b90d3+=0x1){const _0x30123b=_0x347d47[_0x2b90d3];if(_0x30123b==='(')_0x83c4dd+=0x1;if(_0x30123b===')')_0x83c4dd=Math[_0x2ec11f(0x115)](0x0,_0x83c4dd-0x1);_0x83c4dd===0x0&&_0x347d47[_0x2ec11f(0xf3)](_0x2b90d3)[_0x2ec11f(0xf0)](/^AND\b/i)&&(_0x2b90d3===0x0||/\s/[_0x2ec11f(0x131)](_0x347d47[_0x2b90d3-0x1]??''))&&(_0x21905b[_0x2ec11f(0xf4)](_0x347d47[_0x2ec11f(0xf3)](_0x51e67e,_0x2b90d3)[_0x2ec11f(0x13d)]()),_0x2b90d3+=0x2,_0x51e67e=_0x2b90d3+0x1);}const _0x571315=_0x347d47['slice'](_0x51e67e)['trim']();if(_0x571315)_0x21905b['push'](_0x571315);return _0x21905b;}function hasTopLevelKeyword(_0x246017,_0x4ad2a5){const _0x2fbee6=a277_0x4c14;let _0x4ed1e2=0x0;for(let _0x34a804=0x0;_0x34a804<_0x246017[_0x2fbee6(0x12e)];_0x34a804+=0x1){const _0x3a3d18=_0x246017[_0x34a804];if(_0x3a3d18==='(')_0x4ed1e2+=0x1;if(_0x3a3d18===')')_0x4ed1e2=Math[_0x2fbee6(0x115)](0x0,_0x4ed1e2-0x1);if(_0x4ed1e2!==0x0)continue;const _0x104d41=_0x246017[_0x2fbee6(0xf3)](_0x34a804,_0x34a804+_0x4ad2a5['length']),_0x58b73b=_0x246017[_0x34a804-0x1]??'\x20',_0xa2a9e3=_0x246017[_0x34a804+_0x4ad2a5[_0x2fbee6(0x12e)]]??'\x20';if(_0x104d41['toUpperCase']()===_0x4ad2a5[_0x2fbee6(0x11a)]()&&!/[\w$]/[_0x2fbee6(0x131)](_0x58b73b)&&!/[\w$]/['test'](_0xa2a9e3))return!![];}return![];}function splitEquality(_0x38aa0c){const _0x427f4e=a277_0x4c14,_0x233bff=stripOuterParentheses(_0x38aa0c);let _0x2fcc08=0x0,_0x562429;for(let _0x175bba=0x0;_0x175bba<_0x233bff[_0x427f4e(0x12e)];_0x175bba+=0x1){const _0x2ea31f=_0x233bff[_0x175bba];if(_0x2ea31f==='(')_0x2fcc08+=0x1;if(_0x2ea31f===')')_0x2fcc08=Math[_0x427f4e(0x115)](0x0,_0x2fcc08-0x1);const _0x40223b=_0x233bff[_0x175bba-0x1]??'',_0x24be4c=_0x233bff[_0x175bba+0x1]??'';if(_0x2ea31f==='='&&_0x2fcc08===0x0&&!/[!<>=:]/[_0x427f4e(0x131)](_0x40223b)&&_0x24be4c!=='='){if(_0x562429!==undefined)return null;_0x562429=_0x175bba;}}return _0x562429===undefined?null:[_0x233bff[_0x427f4e(0xf3)](0x0,_0x562429)[_0x427f4e(0x13d)](),_0x233bff[_0x427f4e(0xf3)](_0x562429+0x1)[_0x427f4e(0x13d)]()];}function parseDirectColumnReference(_0x50dcda,_0x4a446c){const _0x353537=a277_0x4c14,_0x56de10=/^([`"]?[\w$]+[`"]?)\s*\.\s*([`"]?[\w$]+[`"]?)$/[_0x353537(0xf1)](stripOuterParentheses(_0x50dcda));if(!_0x56de10)return null;if(normalizeIdentifier(_0x56de10[0x1]??'')!==normalizeIdentifier(_0x4a446c))return null;return normalizeIdentifier(_0x56de10[0x2]??'');}function containsColumnReference(_0x23e1b6,_0x319e4e){const _0x159be7=a277_0x4c14,_0x332b4c=_0x23e1b6[_0x159be7(0x137)](/[`"]/g,''),_0x3a3c67=_0x319e4e[_0x159be7(0x137)](/[.*+?^${}()|[\]\\]/g,_0x159be7(0x101));return new RegExp(_0x159be7(0x104)+_0x3a3c67+_0x159be7(0x109),'i')[_0x159be7(0x131)](_0x332b4c);}function findEqualityPrefix(_0x19e6e8,_0x442276){const _0xb1f7e3=a277_0x4c14,_0xb0457d=new Set(_0x442276[_0xb1f7e3(0x11e)](normalizeIdentifier)),_0x345030=[];for(const _0x119aed of _0x19e6e8){if(!_0xb0457d[_0xb1f7e3(0x136)](normalizeIdentifier(_0x119aed)))break;_0x345030[_0xb1f7e3(0xf4)](_0x119aed);}return _0x345030;}function resolveTableMetadata(_0x37328f,_0x24e4d2){const _0xef07ca=a277_0x4c14,_0x55bde4=normalizeIdentifier(_0x24e4d2),_0x36a6db=_0x37328f[_0xef07ca(0x125)](_0x6b73f9=>normalizeIdentifier(_0x6b73f9[_0xef07ca(0x129)])===_0x55bde4);if(_0x36a6db[_0xef07ca(0x12e)]===0x1)return _0x36a6db[0x0];const _0x57189c=_0x55bde4[_0xef07ca(0xf6)]('.'),_0xd06536=_0x55bde4[_0xef07ca(0xf5)]('.')['at'](-0x1),_0x2bb7c7=_0x37328f[_0xef07ca(0x125)](_0x1accce=>{const _0x301cfa=_0xef07ca,_0x2066b5=normalizeIdentifier(_0x1accce[_0x301cfa(0x129)]);if(_0x57189c&&_0x2066b5['includes']('.'))return![];return _0x2066b5['split']('.')['at'](-0x1)===_0xd06536;});return _0x2bb7c7[_0xef07ca(0x12e)]===0x1?_0x2bb7c7[0x0]:undefined;}function columnNamesMatch(_0x29ed06,_0x41939b){return normalizeIdentifier(_0x29ed06)===normalizeIdentifier(_0x41939b);}function normalizeIdentifier(_0x4fb553){const _0x54c50a=a277_0x4c14;return _0x4fb553[_0x54c50a(0x137)](/[`"]/g,'')[_0x54c50a(0x13d)]()[_0x54c50a(0xfb)]();}function isSqlClauseKeyword(_0x129aa1){const _0x415438=a277_0x4c14;return new Set(['on',_0x415438(0xf8),_0x415438(0x12a),_0x415438(0x112),_0x415438(0x132),_0x415438(0xf2),'right','full',_0x415438(0x117),_0x415438(0x123)])[_0x415438(0x136)](_0x129aa1);}function a277_0x4c14(_0x18bff5,_0x5c6d41){_0x18bff5=_0x18bff5-0xf0;const _0x248321=a277_0x2483();let _0x4c14a3=_0x248321[_0x18bff5];return _0x4c14a3;}function stripOuterParentheses(_0x39e98a){const _0x4bcd16=a277_0x4c14;let _0x37a99c=_0x39e98a[_0x4bcd16(0x13d)]();while(_0x37a99c[_0x4bcd16(0x107)]('(')&&_0x37a99c[_0x4bcd16(0xff)](')')){let _0x12b388=0x0,_0x5aa64a=!![];for(let _0x129fd1=0x0;_0x129fd1<_0x37a99c['length'];_0x129fd1+=0x1){if(_0x37a99c[_0x129fd1]==='(')_0x12b388+=0x1;if(_0x37a99c[_0x129fd1]===')')_0x12b388-=0x1;if(_0x12b388===0x0&&_0x129fd1<_0x37a99c[_0x4bcd16(0x12e)]-0x1){_0x5aa64a=![];break;}}if(!_0x5aa64a||_0x12b388!==0x0)break;_0x37a99c=_0x37a99c[_0x4bcd16(0xf3)](0x1,-0x1)['trim']();}return _0x37a99c;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a278_0x6f3f7a=a278_0x5699;(function(_0x5db13f,_0xff304b){const _0x4b31ca=a278_0x5699,_0x2e0aec=_0x5db13f();while(!![]){try{const _0x260c53=parseInt(_0x4b31ca(0xa2))/0x1+parseInt(_0x4b31ca(0xab))/0x2*(-parseInt(_0x4b31ca(0xad))/0x3)+parseInt(_0x4b31ca(0xaf))/0x4*(parseInt(_0x4b31ca(0xa4))/0x5)+parseInt(_0x4b31ca(0xa5))/0x6+parseInt(_0x4b31ca(0xa8))/0x7*(parseInt(_0x4b31ca(0xaa))/0x8)+parseInt(_0x4b31ca(0xa7))/0x9*(parseInt(_0x4b31ca(0xa3))/0xa)+parseInt(_0x4b31ca(0xa9))/0xb*(-parseInt(_0x4b31ca(0xae))/0xc);if(_0x260c53===_0xff304b)break;else _0x2e0aec['push'](_0x2e0aec['shift']());}catch(_0xc98e6f){_0x2e0aec['push'](_0x2e0aec['shift']());}}}(a278_0x49c5,0x97afb));import{resolve}from'node:path';import{findProjectRootDirectory}from'../../context.js';function a278_0x5699(_0x3bd270,_0x47db74){_0x3bd270=_0x3bd270-0xa2;const _0x49c507=a278_0x49c5();let _0x56992c=_0x49c507[_0x3bd270];return _0x56992c;}function a278_0x49c5(){const _0x4f7085=['84326taweem','1176AhGKBP','88jZrsjf','sql','52278LjhbLU','996wFWiSQ','4dZcPkK','512103RBhdbu','10LrZSrT','678715CBpQrb','1563846JXWqXX','.rabetbase','9762102kTbQqY','1484NmPvkn'];a278_0x49c5=function(){return _0x4f7085;};return a278_0x49c5();}const DOT_DIR=a278_0x6f3f7a(0xa6),LOCK_FILE_NAME='sql.lock.json',TRASH_DIR_NAME='sql-trash';export function loadSqlProjectConfig(_0x5a3e2d,_0x43a49c){const _0x259abc=a278_0x6f3f7a,_0x2d026a=resolve(_0x43a49c??findProjectRootDirectory()),_0x259407=DOT_DIR+'/sql',_0x476e57=_0x259407+'/'+_0x5a3e2d;return{'projectRoot':_0x2d026a,'appCode':_0x5a3e2d,'sqlWorkspaceRoot':_0x259407,'sqlRoot':_0x476e57,'sqlRootDir':resolve(_0x2d026a,DOT_DIR,_0x259abc(0xac),_0x5a3e2d),'lockFilePath':resolve(_0x2d026a,DOT_DIR,LOCK_FILE_NAME),'trashDir':resolve(_0x2d026a,DOT_DIR,TRASH_DIR_NAME)};}
|