@lovrabet/rabetbase-cli 2.5.2-beta.3 → 2.5.2-beta.5
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/README.md +1 -1
- package/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -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/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/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/auto-sync.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/deployment/sync.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- 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.d.ts +0 -8
- 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.d.ts +4 -0
- 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.d.ts +5 -1
- package/lib/config/project-domain-routing.js +1 -1
- 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.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.d.ts +0 -26
- 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/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- 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.d.ts +43 -0
- 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/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/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.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.d.ts +6 -5
- package/lib/utils/platform.js +1 -1
- package/lib/utils/sleep.js +1 -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 +2 -1
- package/skills/rabetbase/SKILL.md +5 -5
- package/skills/rabetbase/guides/custom-page-workflow.md +35 -17
- package/skills/rabetbase/guides/page-development-workflow.md +1 -1
- package/skills/rabetbase/knowledge/components.md +292 -0
- package/skills/rabetbase/knowledge/custom-page/generation-standards.md +74 -4
- package/skills/rabetbase/knowledge/custom-page/page-templates.md +68 -0
- package/skills/rabetbase/references/rabetbase-page-create.md +21 -9
- package/skills/rabetbase/references/rabetbase-page-custom-detail.md +1 -1
- package/skills/rabetbase/references/rabetbase-page-custom-update.md +13 -9
- package/skills/rabetbase/references/rabetbase-project-create.md +5 -2
- package/skills/rabetbase/references/rabetbase-project-domain-routing-sync.md +2 -2
- package/skills/rabetbase/references/rabetbase-run.md +1 -0
- package/skills/rabetbase.manifest.json +5 -4
- package/templates/README.md +10 -4
- package/templates/custom-pages/blank.json +5 -0
- package/templates/custom-pages/dashboard.json +5 -0
- package/templates/custom-pages/onepage.json +5 -0
- package/templates/generate-api/api.ts.tpl +1 -1
- package/lib/commands/page/custom/template.d.ts +0 -8
- package/lib/commands/page/custom/template.js +0 -1
- package/skills/rabetbase/knowledge/custom-page/components.md +0 -225
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x16c3d6,_0x33799a){const _0x27c32d=a49_0x4520,_0x4d047c=_0x16c3d6();while(!![]){try{const _0x14ce44=parseInt(_0x27c32d(0x74))/0x1+-parseInt(_0x27c32d(0x7a))/0x2*(parseInt(_0x27c32d(0x7d))/0x3)+-parseInt(_0x27c32d(0x72))/0x4*(parseInt(_0x27c32d(0x7e))/0x5)+-parseInt(_0x27c32d(0x71))/0x6+-parseInt(_0x27c32d(0x76))/0x7*(parseInt(_0x27c32d(0x7f))/0x8)+parseInt(_0x27c32d(0x78))/0x9+parseInt(_0x27c32d(0x77))/0xa*(parseInt(_0x27c32d(0x70))/0xb);if(_0x14ce44===_0x33799a)break;else _0x4d047c['push'](_0x4d047c['shift']());}catch(_0x161827){_0x4d047c['push'](_0x4d047c['shift']());}}}(a49_0x1242,0xb5438));import{existsSync,statSync}from'node:fs';import{CliErrors}from'../../errors.js';const BYTES_PER_MB=0x400*0x400;export const DEVELOPMENT_UPLOAD_MAX_BYTES=0x32*BYTES_PER_MB;function a49_0x4520(_0x36e3fe,_0x2b18b9){_0x36e3fe=_0x36e3fe-0x6f;const _0x12427a=a49_0x1242();let _0x452019=_0x12427a[_0x36e3fe];return _0x452019;}function a49_0x1242(){const _0x241dc8=['File\x20not\x20found:\x20','1855blFnFX','170OPgMxQ','3353040GxYxdN','validation','967512UaiTle','File\x20exceeds\x20the\x20development\x20upload\x20limit\x20of\x2050\x20MB:\x20','size','3bRgofV','5RMQmeO','17192jHWVht','isFile','File\x20is\x20not\x20a\x20regular\x20file:\x20','\x20path\x20is\x20required.','1788831WQWRNT','4857906qenjYi','4909612MKshgZ','\x20MB','695634lWLrRr'];a49_0x1242=function(){return _0x241dc8;};return a49_0x1242();}function formatBytes(_0x22f294){const _0x32dc01=a49_0x4520;if(_0x22f294>=BYTES_PER_MB){const _0xc7601d=Math['ceil'](_0x22f294/BYTES_PER_MB*0x64)/0x64;return _0xc7601d['toFixed'](0x2)+_0x32dc01(0x73);}return _0x22f294+'\x20B';}export function requireDevelopmentUploadFile(_0xeb8a,_0x5290fb){const _0xd8c23=a49_0x4520,_0x2f34d7=_0xeb8a['trim']();if(!_0x2f34d7)throw CliErrors[_0xd8c23(0x79)](_0x5290fb+_0xd8c23(0x6f));if(!existsSync(_0x2f34d7))throw CliErrors[_0xd8c23(0x79)](_0xd8c23(0x75)+_0x2f34d7);const _0x2d2a67=statSync(_0x2f34d7);if(!_0x2d2a67[_0xd8c23(0x80)]())throw CliErrors[_0xd8c23(0x79)](_0xd8c23(0x81)+_0x2f34d7);if(_0x2d2a67[_0xd8c23(0x7c)]>DEVELOPMENT_UPLOAD_MAX_BYTES)throw CliErrors[_0xd8c23(0x79)](_0xd8c23(0x7b)+_0x2f34d7+'\x20('+formatBytes(_0x2d2a67[_0xd8c23(0x7c)])+')');return{'path':_0x2f34d7,'size':_0x2d2a67[_0xd8c23(0x7c)]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x41640c,_0x389c72){const _0xce30fe=a50_0x5c4a,_0x2a145e=_0x41640c();while(!![]){try{const _0x4a1b2b=parseInt(_0xce30fe(0x15c))/0x1+parseInt(_0xce30fe(0x15f))/0x2*(-parseInt(_0xce30fe(0x162))/0x3)+-parseInt(_0xce30fe(0x160))/0x4+parseInt(_0xce30fe(0x161))/0x5*(parseInt(_0xce30fe(0x164))/0x6)+parseInt(_0xce30fe(0x15a))/0x7*(parseInt(_0xce30fe(0x15e))/0x8)+-parseInt(_0xce30fe(0x163))/0x9+parseInt(_0xce30fe(0x159))/0xa;if(_0x4a1b2b===_0x389c72)break;else _0x2a145e['push'](_0x2a145e['shift']());}catch(_0x6f6473){_0x2a145e['push'](_0x2a145e['shift']());}}}(a50_0xc204,0xe498d));function a50_0x5c4a(_0x5e9d82,_0x1c29fe){_0x5e9d82=_0x5e9d82-0x159;const _0xc20478=a50_0xc204();let _0x5c4ab3=_0xc20478[_0x5e9d82];return _0x5c4ab3;}export function validateAppcode(_0x19b461){const _0x15d34c=a50_0x5c4a,_0x3c5b93=_0x19b461[_0x15d34c(0x165)]();if(!_0x3c5b93)return{'valid':![],'message':'App\x20Code\x20cannot\x20be\x20empty'};if(_0x3c5b93['length']>0x64)return{'valid':![],'message':_0x15d34c(0x15b)};if(!/^[A-Za-z0-9_-]+$/[_0x15d34c(0x15d)](_0x3c5b93))return{'valid':![],'message':'Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed'};return{'valid':!![]};}function a50_0xc204(){const _0x1f2bee=['1086236iMsLwh','test','6320bUebrv','30lYMDrs','5893868UFwtCm','322925YsDEYn','82722edMMWo','4173939BaiqAs','78EZqtCS','trim','1020800jaKUbz','11158VnXWPQ','App\x20Code\x20cannot\x20exceed\x20100\x20characters'];a50_0xc204=function(){return _0x1f2bee;};return a50_0xc204();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a51_0x4926bb=a51_0x434f;(function(_0x3e4bcd,_0x4d25f2){const _0xb183cd=a51_0x434f,_0x4cd2cb=_0x3e4bcd();while(!![]){try{const _0x42f045=parseInt(_0xb183cd(0x8b))/0x1+parseInt(_0xb183cd(0x89))/0x2+parseInt(_0xb183cd(0x93))/0x3*(parseInt(_0xb183cd(0x95))/0x4)+parseInt(_0xb183cd(0xa5))/0x5*(parseInt(_0xb183cd(0x85))/0x6)+-parseInt(_0xb183cd(0x8e))/0x7+-parseInt(_0xb183cd(0xa3))/0x8+parseInt(_0xb183cd(0x8f))/0x9;if(_0x42f045===_0x4d25f2)break;else _0x4cd2cb['push'](_0x4cd2cb['shift']());}catch(_0x1fd57b){_0x4cd2cb['push'](_0x4cd2cb['shift']());}}}(a51_0xbd79,0x642d2));function a51_0xbd79(){const _0x34fca3=['Project','Delete\x20a\x20config\x20value\x20from\x20one\x20scope','3BDZaPL','trim','1949396IVHiMd','args','Usage:\x20','hasOwnProperty','\x20deleted','Top-level\x20key\x20\x22','routing','has','Top-level\x20config\x20key;\x20legacy\x20inherit\x20is\x20accepted\x20for\x20migration','prototype','global','config','\x22\x20is\x20not\x20deletable.','defaultApp','4254176elDDbB','Delete\x20from\x20global\x20config\x20(~/.rabetbase.json)','397655iItIgc','write','Use\x20workspace\x20commands\x20to\x20modify\x20apps\x20and\x20their\x20default\x20selection.','6yvmSnT','validation','\x20config\x20delete\x20<key>\x20[--global]','inherit','158234mWiyoo','key','47662yQAhaV','call','Global','1338134yxTvVY','3956373dTvEBT','boolean'];a51_0xbd79=function(){return _0x34fca3;};return a51_0xbd79();}import{CliErrors}from'../../errors.js';function a51_0x434f(_0xe94f04,_0x19a781){_0xe94f04=_0xe94f04-0x85;const _0xbd7972=a51_0xbd79();let _0x434fed=_0xbd7972[_0xe94f04];return _0x434fed;}import{CLI_BIN_NAME,isTopLevelConfigKey,readScopedConfig,resolveWriteScope,writeScopedConfig}from'../../commands/config/shared.js';const LEGACY_DELETABLE_KEYS=new Set([a51_0x4926bb(0x88)]),EXTRA_DELETABLE_KEYS=new Set([a51_0x4926bb(0xa2),a51_0x4926bb(0x9b)]);async function execute(_0x1b4e60){const _0x530a00=a51_0x4926bb,_0x2a9002=_0x1b4e60[_0x530a00(0x96)][0x0]?.[_0x530a00(0x94)]();if(!_0x2a9002)throw CliErrors[_0x530a00(0x86)]('Missing\x20key\x20argument.',_0x530a00(0x97)+CLI_BIN_NAME+_0x530a00(0x87));if(_0x2a9002==='riskLevel')throw CliErrors['validation']('\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.');if(!isTopLevelConfigKey(_0x2a9002)&&!EXTRA_DELETABLE_KEYS[_0x530a00(0x9c)](_0x2a9002)&&!LEGACY_DELETABLE_KEYS[_0x530a00(0x9c)](_0x2a9002))throw CliErrors[_0x530a00(0x86)](_0x530a00(0x9a)+_0x2a9002+_0x530a00(0xa1),_0x530a00(0xa7));const _0x1f8007=resolveWriteScope({'global':_0x1b4e60['bool'](_0x530a00(0x9f))}),_0x15780c=readScopedConfig(_0x1f8007),_0x4935d6=Object[_0x530a00(0x9e)][_0x530a00(0x98)][_0x530a00(0x8c)](_0x15780c,_0x2a9002);_0x4935d6&&(delete _0x15780c[_0x2a9002],writeScopedConfig(_0x15780c,_0x1f8007));const _0xf73c26=_0x1f8007===_0x530a00(0x9f)?_0x530a00(0x8d):_0x530a00(0x91);return{'ok':!![],'message':_0x4935d6?'✓\x20'+_0xf73c26+'\x20'+_0x2a9002+_0x530a00(0x99):'✓\x20'+_0xf73c26+'\x20'+_0x2a9002+'\x20already\x20absent','data':{'key':_0x2a9002,'scope':_0x1f8007,'changed':_0x4935d6}};}export const configDeleteDefinition={'service':a51_0x4926bb(0xa0),'command':'delete','description':a51_0x4926bb(0x92),'risk':a51_0x4926bb(0xa6),'requiresAuth':![],'requiresAppCode':![],'args':[{'name':a51_0x4926bb(0x8a),'description':a51_0x4926bb(0x9d),'required':!![]}],'flags':[{'name':a51_0x4926bb(0x9f),'type':a51_0x4926bb(0x90),'description':a51_0x4926bb(0xa4),'default':![]}],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a52_0x477ba9=a52_0x4924;function a52_0x4924(_0x376d38,_0x248b37){_0x376d38=_0x376d38-0x1c0;const _0x56b700=a52_0x56b7();let _0x4924e0=_0x56b700[_0x376d38];return _0x4924e0;}(function(_0x522279,_0x3c15f6){const _0x165303=a52_0x4924,_0x1e3e6c=_0x522279();while(!![]){try{const _0x5acbc2=parseInt(_0x165303(0x1cd))/0x1*(parseInt(_0x165303(0x1d2))/0x2)+-parseInt(_0x165303(0x1d4))/0x3*(parseInt(_0x165303(0x1d3))/0x4)+-parseInt(_0x165303(0x1d6))/0x5+parseInt(_0x165303(0x1ce))/0x6+parseInt(_0x165303(0x1c6))/0x7*(parseInt(_0x165303(0x1d1))/0x8)+-parseInt(_0x165303(0x1c9))/0x9+-parseInt(_0x165303(0x1d5))/0xa;if(_0x5acbc2===_0x3c15f6)break;else _0x1e3e6c['push'](_0x1e3e6c['shift']());}catch(_0x420758){_0x1e3e6c['push'](_0x1e3e6c['shift']());}}}(a52_0x56b7,0x8812e));import{CliErrors}from'../../errors.js';import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';async function execute(_0x31f3ca){const _0x348390=a52_0x4924,_0x452bfe=_0x31f3ca[_0x348390(0x1c2)]('key');if(!_0x452bfe)throw CliErrors[_0x348390(0x1c1)](_0x348390(0x1c4),'Usage:\x20'+CLI_BIN_NAME+_0x348390(0x1ca));const _0x5f4283=readConfig(),_0x142a9d=_0x452bfe===_0x348390(0x1c7)?_0x348390(0x1c8):_0x452bfe,_0x40339f=_0x5f4283[_0x142a9d];if(_0x40339f===undefined)throw CliErrors[_0x348390(0x1c1)](_0x348390(0x1c5)+_0x452bfe);return{'ok':!![],'data':typeof _0x40339f===_0x348390(0x1c3)?_0x40339f:{[_0x142a9d]:_0x40339f},'message':typeof _0x40339f===_0x348390(0x1c3)?undefined:String(_0x40339f)};}export const configGetDefinition={'service':'config','command':a52_0x477ba9(0x1c0),'description':a52_0x477ba9(0x1cc),'risk':a52_0x477ba9(0x1d0),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a52_0x477ba9(0x1cf),'type':a52_0x477ba9(0x1cb),'description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};function a52_0x56b7(){const _0x4e0925=['Get\x20a\x20config\x20value\x20by\x20key','229703YKKSWw','5642802DAOXCa','key','read','6603064ocPcIX','8bQAhdi','34644DBoIwJ','144xhvxTu','7804270QdpUxH','921500VwvFaa','get','validation','str','object','Missing\x20key.','Key\x20not\x20found:\x20','7PJlkZQ','app','appcode','6721641qEmbOu','\x20config\x20get\x20--key\x20<key>','string'];a52_0x56b7=function(){return _0x4e0925;};return a52_0x56b7();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x471e,_0x1e0256){const _0x4844a4=a53_0x439f,_0x3358bf=_0x471e();while(!![]){try{const _0x165ab2=-parseInt(_0x4844a4(0x138))/0x1+parseInt(_0x4844a4(0x13a))/0x2+parseInt(_0x4844a4(0x135))/0x3+-parseInt(_0x4844a4(0x132))/0x4+parseInt(_0x4844a4(0x139))/0x5*(parseInt(_0x4844a4(0x136))/0x6)+-parseInt(_0x4844a4(0x134))/0x7*(parseInt(_0x4844a4(0x133))/0x8)+-parseInt(_0x4844a4(0x137))/0x9;if(_0x165ab2===_0x1e0256)break;else _0x3358bf['push'](_0x3358bf['shift']());}catch(_0x29fe01){_0x3358bf['push'](_0x3358bf['shift']());}}}(a53_0x2386,0x953dc));function a53_0x439f(_0x254519,_0x5d8689){_0x254519=_0x254519-0x132;const _0x2386f9=a53_0x2386();let _0x439f00=_0x2386f9[_0x254519];return _0x439f00;}import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';function a53_0x2386(){const _0x2a73e3=['2048076DOFRYM','136jmhpQp','194684MXRbGI','3602217nqxDNZ','30YfGjxy','11472273OMCqyc','168610AyetuL','1166710GyHdul','1343946iQTtyV'];a53_0x2386=function(){return _0x2a73e3;};return a53_0x2386();}import{configSetDefinition}from'../../commands/config/set.js';import{configDeleteDefinition}from'../../commands/config/delete.js';import{configInitDefinition}from'../../commands/config/init.js';export const configDefinitions=[configInitDefinition,configListDefinition,configGetDefinition,configSetDefinition,configDeleteDefinition];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a54_0x46fb2a=a54_0x2b4f;(function(_0x7e1185,_0x3a3725){const _0x4d706b=a54_0x2b4f,_0x58f0ba=_0x7e1185();while(!![]){try{const _0xd27b7f=parseInt(_0x4d706b(0x201))/0x1+-parseInt(_0x4d706b(0x212))/0x2+-parseInt(_0x4d706b(0x21d))/0x3+-parseInt(_0x4d706b(0x20e))/0x4+parseInt(_0x4d706b(0x1ff))/0x5+parseInt(_0x4d706b(0x1fe))/0x6*(-parseInt(_0x4d706b(0x204))/0x7)+parseInt(_0x4d706b(0x1f2))/0x8;if(_0xd27b7f===_0x3a3725)break;else _0x58f0ba['push'](_0x58f0ba['shift']());}catch(_0x130810){_0x58f0ba['push'](_0x58f0ba['shift']());}}}(a54_0x5bea,0x74675));import{select}from'@inquirer/prompts';import{CliErrors}from'../../errors.js';import{readScopedConfig,writeScopedConfig}from'../../commands/config/shared.js';import{DOMAIN_CONFIG_FIELDS,LEGACY_DOMAIN_CONFIG_FIELDS,resolveDomainConfigInput}from'../../config/domain-config.js';import{ENTERPRISE_ROUTING_KIND,ENTERPRISE_ROUTING_PROTOCOL}from'../../generated/routing-contract.js';import{DEFAULT_LOVRABET_REGION,ENABLED_LOVRABET_REGION_VALUES,isEnabledLovrabetRegion}from'../../constant/region.js';import{getOfficialRoutingProfile}from'../../constant/routing-profile.js';function a54_0x2b4f(_0x3fedc2,_0x3ead20){_0x3fedc2=_0x3fedc2-0x1ef;const _0x5bea9a=a54_0x5bea();let _0x2b4fff=_0x5bea9a[_0x3fedc2];return _0x2b4fff;}import{GLOBAL_SCOPE_FLAG}from'../../commands/common/flags.js';function a54_0x5bea(){const _0x136938=['length','583018HIzMeh','runtime-domain','global','init','local-domain','join','Rabetbase\x20connection\x20configured\x20for\x20region:\x20','manifestDomains','write','routing','assign','2520393mCAIkZ','Choose\x20either\x20an\x20official\x20region\x20or\x20independent-deployment\x20Domains,\x20not\x20both.','api-domain','Initialize\x20the\x20Lovrabet\x20region\x20or\x20independent-deployment\x20Domains','domains','Region\x20\x22','str','app-domain','7362336objBrK','region','cdn','Independent\x20deployment\x20requires\x20--local-domain\x20and\x20--certificate-domain\x20together.','validation','domain-config','name','\x22\x20is\x20not\x20currently\x20available.','Independent-deployment\x20Domain\x20JSON\x20file','Official\x20Lovrabet\x20region:\x20','certificateDomain','Updates\x20the\x20selected\x20Rabetbase\x20region\x20or\x20independent-deployment\x20Domain\x20configuration.\x20Cookie,\x20output\x20format,\x20and\x20app\x20bindings\x20stay\x20unchanged.','1674qradAc','4582565WgJRLQ','map','790355NPGpEO','Rabetbase\x20connection\x20configured\x20for\x20independent\x20deployment.\x20Domains:\x20','certificate-domain','12257RwvZZV','project','official','cancelled','localDomain','keys','string','mode','enterprise-v1','independent','2120808gBzreP','Custom\x20Runtime\x20HTTPS\x20origin','Available\x20regions:\x20'];a54_0x5bea=function(){return _0x136938;};return a54_0x5bea();}export const configInitFlags=[GLOBAL_SCOPE_FLAG,{'name':a54_0x46fb2a(0x1f3),'type':a54_0x46fb2a(0x20a),'description':a54_0x46fb2a(0x1fb)+ENABLED_LOVRABET_REGION_VALUES['join'](',\x20'),'enum':[...ENABLED_LOVRABET_REGION_VALUES]},{'name':a54_0x46fb2a(0x1f7),'type':a54_0x46fb2a(0x20a),'description':a54_0x46fb2a(0x1fa)},{'name':'user-domain','type':a54_0x46fb2a(0x20a),'description':'Custom\x20User\x20HTTPS\x20origin'},{'name':a54_0x46fb2a(0x21f),'type':a54_0x46fb2a(0x20a),'description':'Custom\x20platform\x20API\x20HTTPS\x20origin'},{'name':a54_0x46fb2a(0x213),'type':'string','description':a54_0x46fb2a(0x20f)},{'name':'skill-domain','type':a54_0x46fb2a(0x20a),'description':'Custom\x20SkillHub\x20HTTPS\x20origin'},{'name':'kb-domain','type':a54_0x46fb2a(0x20a),'description':'Custom\x20knowledge-base\x20HTTPS\x20origin'},{'name':a54_0x46fb2a(0x1f1),'type':'string','description':'Custom\x20Lovrabet\x20workspace\x20HTTPS\x20origin'},{'name':a54_0x46fb2a(0x216),'type':a54_0x46fb2a(0x20a),'description':'Custom\x20local\x20callback\x20HTTPS\x20origin'},{'name':a54_0x46fb2a(0x203),'type':'string','description':'Custom\x20certificate\x20service\x20HTTPS\x20origin'}];async function resolveRegion(_0x381489){const _0x3f245d=a54_0x46fb2a,_0x113dff=_0x381489[_0x3f245d(0x1f0)]('region');if(_0x113dff){if(!isEnabledLovrabetRegion(_0x113dff))throw CliErrors[_0x3f245d(0x1f6)](_0x3f245d(0x1ef)+_0x113dff+_0x3f245d(0x1f9),_0x3f245d(0x210)+ENABLED_LOVRABET_REGION_VALUES[_0x3f245d(0x217)](',\x20'));return _0x113dff;}if(_0x381489['nonInteractive'])return DEFAULT_LOVRABET_REGION;try{return await select({'message':'Select\x20Lovrabet\x20region','default':DEFAULT_LOVRABET_REGION,'choices':ENABLED_LOVRABET_REGION_VALUES[_0x3f245d(0x200)](_0x4cbe7d=>({'name':getOfficialRoutingProfile(_0x4cbe7d)['label']+'\x20('+_0x4cbe7d+')','value':_0x4cbe7d}))});}catch(_0x30b01c){if(_0x30b01c?.[_0x3f245d(0x1f8)]==='ExitPromptError')throw CliErrors[_0x3f245d(0x207)]();throw _0x30b01c;}}export async function executeConfigInit(_0x550b11){const _0x527c08=a54_0x46fb2a,_0x267072=resolveDomainConfigInput(_0x550b11),_0xe89b90=_0x267072[_0x527c08(0x221)],_0x453dd5=Object[_0x527c08(0x209)](_0xe89b90)[_0x527c08(0x211)]>0x0;if(_0x453dd5&&_0x550b11[_0x527c08(0x1f0)](_0x527c08(0x1f3)))throw CliErrors[_0x527c08(0x1f6)](_0x527c08(0x21e));if(!!_0xe89b90[_0x527c08(0x208)]!==!!_0xe89b90[_0x527c08(0x1fc)])throw CliErrors[_0x527c08(0x1f6)](_0x527c08(0x1f5));const _0x93161b=_0x550b11['bool'](_0x527c08(0x214))?_0x527c08(0x214):_0x527c08(0x205),_0x56cf50=readScopedConfig(_0x93161b);for(const _0x44cb7d of DOMAIN_CONFIG_FIELDS)delete _0x56cf50[_0x44cb7d];for(const _0x3442cb of LEGACY_DOMAIN_CONFIG_FIELDS)delete _0x56cf50[_0x3442cb];delete _0x56cf50[_0x527c08(0x21b)];let _0x44a711=null;if(_0x453dd5)delete _0x56cf50[_0x527c08(0x1f3)],_0x267072[_0x527c08(0x20b)]===_0x527c08(0x20c)?_0x56cf50[_0x527c08(0x21b)]={'protocol':ENTERPRISE_ROUTING_PROTOCOL,'kind':ENTERPRISE_ROUTING_KIND,'domains':_0x267072[_0x527c08(0x219)],'cdn':_0x267072[_0x527c08(0x1f4)]}:Object[_0x527c08(0x21c)](_0x56cf50,_0xe89b90);else{_0x44a711=await resolveRegion(_0x550b11);if(_0x44a711===DEFAULT_LOVRABET_REGION)delete _0x56cf50[_0x527c08(0x1f3)];else _0x56cf50['region']=_0x44a711;}return writeScopedConfig(_0x56cf50,_0x93161b),{'ok':!![],'message':_0x453dd5?_0x527c08(0x202)+Object[_0x527c08(0x209)](_0x267072[_0x527c08(0x20b)]==='enterprise-v1'?_0x267072[_0x527c08(0x219)]:_0xe89b90)[_0x527c08(0x217)](',\x20')+'.':_0x527c08(0x218)+_0x44a711+'.','data':{'mode':_0x453dd5?_0x527c08(0x20d):_0x527c08(0x206),'protocol':_0x267072[_0x527c08(0x20b)]===_0x527c08(0x20c)?ENTERPRISE_ROUTING_PROTOCOL:undefined,'region':_0x44a711,'domains':_0xe89b90,'cdn':_0x267072[_0x527c08(0x20b)]===_0x527c08(0x20c)?_0x267072[_0x527c08(0x1f4)]:undefined}};}export const configInitDefinition={'service':'config','command':a54_0x46fb2a(0x215),'description':a54_0x46fb2a(0x220),'risk':a54_0x46fb2a(0x21a),'confirmationDescription':a54_0x46fb2a(0x1fd),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':configInitFlags,'execute':executeConfigInit};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a55_0x138896=a55_0x3344;(function(_0x3b6f93,_0x301660){const _0x3d3c5a=a55_0x3344,_0x2a9e47=_0x3b6f93();while(!![]){try{const _0x52579e=-parseInt(_0x3d3c5a(0x1a1))/0x1*(parseInt(_0x3d3c5a(0x198))/0x2)+parseInt(_0x3d3c5a(0x195))/0x3+parseInt(_0x3d3c5a(0x19a))/0x4*(parseInt(_0x3d3c5a(0x19e))/0x5)+-parseInt(_0x3d3c5a(0x19b))/0x6*(-parseInt(_0x3d3c5a(0x1a0))/0x7)+parseInt(_0x3d3c5a(0x199))/0x8+-parseInt(_0x3d3c5a(0x192))/0x9*(parseInt(_0x3d3c5a(0x197))/0xa)+-parseInt(_0x3d3c5a(0x1a3))/0xb*(parseInt(_0x3d3c5a(0x196))/0xc);if(_0x52579e===_0x301660)break;else _0x2a9e47['push'](_0x2a9e47['shift']());}catch(_0x2bca47){_0x2a9e47['push'](_0x2a9e47['shift']());}}}(a55_0x1ba8,0x86ba4));import{readScopedConfig}from'../../commands/config/shared.js';function a55_0x1ba8(){const _0x5251f1=['global','48059ItqzLY','1206xRRFYk','config','list','2332152qlKMWl','2316DXDlJF','10120VnkRBc','2awjtwI','2095872BHvnfh','4oCjapV','6zsmrTC','boolean','bool','2867365iKBBdV','Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','1470231NZQcNA','292205ktJwkL'];a55_0x1ba8=function(){return _0x5251f1;};return a55_0x1ba8();}import{readConfig}from'../../utils/config.js';async function execute(_0x1736ee){const _0x45f77b=a55_0x3344,_0x830bf7=_0x1736ee[_0x45f77b(0x19d)](_0x45f77b(0x1a2))?readScopedConfig(_0x45f77b(0x1a2)):readConfig();return{'ok':!![],'data':_0x830bf7};}function a55_0x3344(_0x59144b,_0x5a6429){_0x59144b=_0x59144b-0x192;const _0x1ba8f6=a55_0x1ba8();let _0x334407=_0x1ba8f6[_0x59144b];return _0x334407;}export const configListDefinition={'service':a55_0x138896(0x193),'command':a55_0x138896(0x194),'description':'List\x20all\x20config\x20values','risk':'read','requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a55_0x138896(0x1a2),'type':a55_0x138896(0x19c),'description':a55_0x138896(0x19f),'default':![]}],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a56_0x5f1d(){const _0x1d163e=['object','global','30McbZbU','\x22\x20is\x20not\x20settable.','write','Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US','Missing\x20key.','355728XwnkMA','key','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','Project','validation','string','str','Usage:\x20','length','app','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','bool','3465120APbWEM','locale','Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','includes','820202DoJRLo','apps','Set\x20a\x20config\x20value','join','Global','set','`,\x20`','\x20workspace\x20add\x20<name>\x20--appcode\x20','\x22.\x20Allowed:\x20','Missing\x20value.','riskLevel','5547486tDArib','value','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','317497rJlQvd','appcode','\x20appcode\x20set\x20to:\x20','1850464hVwFxu','keys','192990WvwhdG','env'];a56_0x5f1d=function(){return _0x1d163e;};return a56_0x5f1d();}const a56_0x30d21c=a56_0x382b;(function(_0x1029a8,_0x2df062){const _0x1ec922=a56_0x382b,_0xd7137d=_0x1029a8();while(!![]){try{const _0x5bd1ee=-parseInt(_0x1ec922(0x1c7))/0x1+parseInt(_0x1ec922(0x1b9))/0x2+-parseInt(_0x1ec922(0x1cc))/0x3+-parseInt(_0x1ec922(0x1d5))/0x4*(parseInt(_0x1ec922(0x1d0))/0x5)+parseInt(_0x1ec922(0x1c4))/0x6+-parseInt(_0x1ec922(0x1ca))/0x7+parseInt(_0x1ec922(0x1b5))/0x8;if(_0x5bd1ee===_0x2df062)break;else _0xd7137d['push'](_0xd7137d['shift']());}catch(_0x327400){_0xd7137d['push'](_0xd7137d['shift']());}}}(a56_0x5f1d,0x8f913));import{CliErrors}from'../../errors.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';import{CLI_BIN_NAME,CONFIG_ENUM_VALUES,getConfigCommandKeyDescription,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale,resolveWriteScope,readScopedConfig,writeScopedConfig}from'../../commands/config/shared.js';import{normalizeEnv,isProduction,isDaily}from'../../constant/env.js';import{DOMAIN_CONFIG_FIELDS,normalizeDomainOrigin}from'../../config/domain-config.js';function a56_0x382b(_0x3ee8bb,_0x55a413){_0x3ee8bb=_0x3ee8bb-0x1b3;const _0x5f1de5=a56_0x5f1d();let _0x382bcc=_0x5f1de5[_0x3ee8bb];return _0x382bcc;}async function execute(_0x4f7fed){const _0x334530=a56_0x382b,_0x4cf815=_0x4f7fed[_0x334530(0x1db)](_0x334530(0x1d6)),_0x58e505=_0x4f7fed[_0x334530(0x1db)](_0x334530(0x1c5));if(!_0x4cf815)throw CliErrors[_0x334530(0x1d9)](_0x334530(0x1d4),'Usage:\x20'+CLI_BIN_NAME+_0x334530(0x1b3));if(_0x58e505===undefined||_0x58e505==='')throw CliErrors[_0x334530(0x1d9)](_0x334530(0x1c2),_0x334530(0x1dc)+CLI_BIN_NAME+_0x334530(0x1b3));let _0x2b79b2=_0x4cf815,_0x279354=_0x58e505;if(_0x58e505[_0x334530(0x1dd)]>0x1f4)throw CliErrors[_0x334530(0x1d9)]('Config\x20value\x20is\x20invalid\x20or\x20too\x20long.');if(_0x4cf815===_0x334530(0x1c3))throw CliErrors[_0x334530(0x1d9)](_0x334530(0x1c6));if(!isTopLevelConfigKey(_0x4cf815))throw CliErrors[_0x334530(0x1d9)]('Top-level\x20key\x20\x22'+_0x4cf815+_0x334530(0x1d1),'Settable\x20top-level\x20keys:\x20'+getTopLevelConfigKeySummary());if(CONFIG_ENUM_VALUES[_0x4cf815]&&!CONFIG_ENUM_VALUES[_0x4cf815][_0x334530(0x1b8)](_0x58e505))throw CliErrors[_0x334530(0x1d9)]('Invalid\x20value\x20for\x20\x22'+_0x4cf815+_0x334530(0x1c1)+CONFIG_ENUM_VALUES[_0x4cf815][_0x334530(0x1bc)](',\x20'));if(_0x4cf815==='locale'&&!normalizeLocale(_0x58e505))throw CliErrors['validation']('Invalid\x20locale\x20value.',_0x334530(0x1d3));DOMAIN_CONFIG_FIELDS[_0x334530(0x1b8)](_0x4cf815)&&(_0x279354=normalizeDomainOrigin(_0x4cf815,_0x58e505));const _0x3af0f2={'global':_0x4f7fed[_0x334530(0x1b4)](_0x334530(0x1cf))},_0x527df1=resolveWriteScope(_0x3af0f2),_0x3378e4=readScopedConfig(_0x527df1);_0x4cf815===_0x334530(0x1de)&&(_0x2b79b2=_0x334530(0x1c8),delete _0x3378e4[_0x334530(0x1de)]);_0x4cf815===_0x334530(0x1b6)&&(_0x279354=normalizeLocale(_0x58e505));if(_0x4cf815===_0x334530(0x1cd)){_0x279354=normalizeEnv(_0x58e505);if(!isProduction(_0x279354)&&!isDaily(_0x279354))throw CliErrors[_0x334530(0x1d9)](_0x334530(0x1d7),'Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.');}if(_0x4cf815===_0x334530(0x1c8)){const _0x3c3ed1=_0x3378e4[_0x334530(0x1ba)]&&typeof _0x3378e4[_0x334530(0x1ba)]===_0x334530(0x1ce)?Object[_0x334530(0x1cb)](_0x3378e4[_0x334530(0x1ba)]):[];if(_0x3c3ed1[_0x334530(0x1dd)]>0x0)throw CliErrors['validation']('Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.','Use\x20`'+CLI_BIN_NAME+_0x334530(0x1c0)+_0x279354+_0x334530(0x1bf)+CLI_BIN_NAME+'\x20workspace\x20use\x20--app\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.');const _0x4d3d0c=buildCanonicalProjectConfig({..._0x3378e4},{'appCodes':[_0x279354],'env':typeof _0x3378e4[_0x334530(0x1cd)]===_0x334530(0x1da)?_0x3378e4['env']:undefined});writeScopedConfig(_0x4d3d0c,_0x527df1);const _0x1ce75f=_0x527df1==='global'?'Global':_0x334530(0x1d8);return{'ok':!![],'message':'✓\x20'+_0x1ce75f+_0x334530(0x1c9)+_0x279354+'\x20(stored\x20as\x20a\x20single\x20app\x20profile)'};}_0x3378e4[_0x2b79b2]=_0x279354,writeScopedConfig(_0x3378e4,_0x527df1);const _0xbb5b2c=_0x527df1===_0x334530(0x1cf)?_0x334530(0x1bd):_0x334530(0x1d8);return{'ok':!![],'message':'✓\x20'+_0xbb5b2c+'\x20'+_0x2b79b2+'\x20set\x20to:\x20'+_0x279354};}export const configSetDefinition={'service':'config','command':a56_0x30d21c(0x1be),'description':a56_0x30d21c(0x1bb),'risk':a56_0x30d21c(0x1d2),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':a56_0x30d21c(0x1da),'description':getConfigCommandKeyDescription(),'required':!![]},{'name':a56_0x30d21c(0x1c5),'type':a56_0x30d21c(0x1da),'description':'Config\x20value','required':!![]},{'name':'global','type':'boolean','description':a56_0x30d21c(0x1b7),'default':![]}],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x22bebe,_0x2b2576){var _0x493334=a57_0x30a7,_0xd36a2=_0x22bebe();while(!![]){try{var _0x2ac66a=-parseInt(_0x493334(0x128))/0x1*(-parseInt(_0x493334(0x135))/0x2)+-parseInt(_0x493334(0x132))/0x3*(-parseInt(_0x493334(0x130))/0x4)+parseInt(_0x493334(0x129))/0x5*(parseInt(_0x493334(0x12a))/0x6)+-parseInt(_0x493334(0x12c))/0x7+parseInt(_0x493334(0x126))/0x8*(-parseInt(_0x493334(0x127))/0x9)+-parseInt(_0x493334(0x12f))/0xa+parseInt(_0x493334(0x131))/0xb*(-parseInt(_0x493334(0x12e))/0xc);if(_0x2ac66a===_0x2b2576)break;else _0xd36a2['push'](_0xd36a2['shift']());}catch(_0x559a5c){_0xd36a2['push'](_0xd36a2['shift']());}}}(a57_0x8b0b,0x450c3));import{CLI_BIN_NAME}from'../../constant/cli.js';function a57_0x30a7(_0x4e2b86,_0xeb1d61){_0x4e2b86=_0x4e2b86-0x126;var _0x8b0b75=a57_0x8b0b();var _0x30a762=_0x8b0b75[_0x4e2b86];return _0x30a762;}import{isInProject,resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../../context.js';function a57_0x8b0b(){var _0x303b25=['15QFHNTr','32916ozINbF','Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','2357019RNoOPP','validation','12OYIhAN','773410yJNDXt','230524VxEUFU','1963467AWMrhS','24sayOKC','Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).','global','2Dlmsge','6712DtnTQz','171QHciAa','413809EQTkhz'];a57_0x8b0b=function(){return _0x303b25;};return a57_0x8b0b();}import{CliErrors}from'../../errors.js';import{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale}from'../../config/schema.js';export{CLI_BIN_NAME};export{normalizeLocale};export{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey};export function resolveWriteScope(_0x4f05ef){var _0xb0b2f1=a57_0x30a7;if(_0x4f05ef[_0xb0b2f1(0x134)])return _0xb0b2f1(0x134);if(!isInProject())throw CliErrors[_0xb0b2f1(0x12d)](_0xb0b2f1(0x133),_0xb0b2f1(0x12b)+CLI_BIN_NAME+'\x20workspace\x20init\x20--appcode\x20<code>`\x20first.');return'project';}export function readScopedConfig(_0xd7a06a){return readConfigFile(resolveWriteConfigPath(_0xd7a06a));}export function writeScopedConfig(_0x2b21b0,_0x3f08c6){writeConfigFile(resolveWriteConfigPath(_0x3f08c6),_0x2b21b0);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a58_0x1aeca2=a58_0x405d;(function(_0x19fe7f,_0x1bebdb){const _0x290639=a58_0x405d,_0x4b9f9d=_0x19fe7f();while(!![]){try{const _0x2702fa=parseInt(_0x290639(0x146))/0x1+-parseInt(_0x290639(0x17b))/0x2+-parseInt(_0x290639(0x15e))/0x3+parseInt(_0x290639(0x17c))/0x4+-parseInt(_0x290639(0x158))/0x5+parseInt(_0x290639(0x157))/0x6+-parseInt(_0x290639(0x151))/0x7;if(_0x2702fa===_0x1bebdb)break;else _0x4b9f9d['push'](_0x4b9f9d['shift']());}catch(_0xee5870){_0x4b9f9d['push'](_0x4b9f9d['shift']());}}}(a58_0x243d,0xa740b));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateDbTableBusinessGroup,updateErBusinessGroup}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a58_0x243d(){const _0x42d2d1=['method','datasetName','length','Expectation\x20mismatch\x20at\x20businessGroup','apiError','name','update','Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20','Business\x20scenario\x20group\x20(not\x20technical):\x20use\x20<scenario>,\x20<domain>---<scenario>\x20when\x20needed;\x20METADATA\x20accepts\x20ungrouped\x20to\x20clear\x20it','tableName','expect-business-group','source','matched','prototype','373694TBHvkW','4397272YTLSKL','datasetCode','keys','data','Expected\x20current\x20business\x20scenario\x20group;\x20use\x20ungrouped\x20to\x20expect\x20no\x20group;\x20mismatch\x20aborts\x20without\x20writing','dbtableConfig','Run\x20dataset\x20detail\x20and\x20complete\x20database\x20analysis\x20before\x20updating\x20the\x20business\x20group.','Clearing\x20business\x20scenario\x20groups\x20is\x20not\x20supported\x20for\x20DB_TABLE\x20datasets.','--business-group\x20must\x20not\x20be\x20blank','backend','modelId','METADATA','sourceType','db-table','code','message','Expected\x20','write','value','path','businessGroup','646878ieYqFO','dbLinkId','business-group-update',',\x20actual\x20','appCode','dbId','expectBusinessGroup','ungrouped','POST','kind','business-group','4982194xWdBjH','Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20','dbTableSelector','--code\x20is\x20required','trim','extend','5760954tWRRnM','2057880RQejSR','Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.','/smartapi/question/er-config/business-group/edit','string','DB_TABLE','validation','2133369ciVaMP','isFinite','payload','object','stringify','Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.','parse','found','str','Update\x20business\x20scenario\x20group','modelCode','DB_TABLE\x20dataset\x20requires\x20dbtableConfig.dbId\x20and\x20tableName.','dataset','toUpperCase','datasetId'];a58_0x243d=function(){return _0x42d2d1;};return a58_0x243d();}const DB_TABLE_BACKEND_PATH='/smartapi/dblink/updateTableBusinessGroup',METADATA_BACKEND_PATH=a58_0x1aeca2(0x15a),UNGROUPED_BUSINESS_GROUP=a58_0x1aeca2(0x14d);function a58_0x405d(_0xd2d47a,_0x33249e){_0xd2d47a=_0xd2d47a-0x13c;const _0x243d7f=a58_0x243d();let _0x405da9=_0x243d7f[_0xd2d47a];return _0x405da9;}export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x225a2d,input:_0x3f6e52,dryRun:_0x19f825}){const _0x2e84f6=a58_0x1aeca2;validateInput(_0x3f6e52);const _0x2fb426=normalizeBusinessGroupArgument(_0x3f6e52[_0x2e84f6(0x145)]),_0x3ac5a7=await getDatasetDetail(_0x3f6e52[_0x2e84f6(0x13f)]),_0x17d469=resolveBusinessGroupDataset(_0x3ac5a7,_0x3f6e52['code']);assertBusinessGroupUpdateSupported(_0x17d469,_0x2fb426);const _0x475016=loadCurrentBusinessGroup(_0x3ac5a7,_0x17d469);assertExpectedBusinessGroup(_0x475016,_0x3f6e52[_0x2e84f6(0x14c)]);const _0x2ca3e6=buildBackendPlan(_0x225a2d,_0x17d469,_0x2fb426),_0x4867b4=_0x475016!==_0x2fb426;let _0xfea397;if(_0x4867b4&&!_0x19f825){_0x2ca3e6[_0x2e84f6(0x14f)]===_0x2e84f6(0x13e)?await updateDbTableBusinessGroup(_0x2ca3e6[_0x2e84f6(0x160)]):await updateErBusinessGroup(_0x2ca3e6[_0x2e84f6(0x160)]);const _0x1230d3=await getDatasetDetail(_0x17d469[_0x2e84f6(0x13f)]),_0x1a8227=resolveBusinessGroupDataset(_0x1230d3,_0x17d469[_0x2e84f6(0x13f)]),_0x38665c=loadCurrentBusinessGroup(_0x1230d3,_0x1a8227);if(_0x38665c!==_0x2fb426)throw CliErrors[_0x2e84f6(0x171)](_0x2e84f6(0x163),'Expected\x20'+JSON[_0x2e84f6(0x162)](displayBusinessGroup(_0x2fb426))+_0x2e84f6(0x149)+JSON[_0x2e84f6(0x162)](displayBusinessGroup(_0x38665c))+'.');_0xfea397={'verified':!![],'status':_0x2e84f6(0x179),'afterReadback':{'businessGroup':displayBusinessGroup(_0x38665c)}};}else!_0x4867b4&&(_0xfea397={'verified':!![],'status':'unchanged','afterReadback':{'businessGroup':displayBusinessGroup(_0x475016)}});const _0x3cdbfb={'operation':_0x2e84f6(0x173),'appCode':_0x225a2d,'selector':{'code':_0x17d469[_0x2e84f6(0x13f)]},'dataset':{'id':_0x17d469['id'],'code':_0x17d469[_0x2e84f6(0x13f)],'name':_0x17d469['name'],'sourceType':_0x17d469[_0x2e84f6(0x13d)]},'before':{'businessGroup':displayBusinessGroup(_0x475016)},'after':{'businessGroup':displayBusinessGroup(_0x2fb426)},'changed':_0x4867b4,'dryRun':_0x19f825,'submitted':_0x4867b4&&!_0x19f825,'backend':{'method':_0x2ca3e6['method'],'path':_0x2ca3e6[_0x2e84f6(0x144)],'payload':_0x2ca3e6[_0x2e84f6(0x160)]},..._0xfea397?{'verification':_0xfea397}:{},'warnings':[]};return{'ok':!![],'data':_0x3cdbfb,'message':_0x4867b4?_0x19f825?_0x2e84f6(0x174)+_0x17d469[_0x2e84f6(0x13f)]:_0x2e84f6(0x152)+_0x17d469['code']:'No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20'+_0x17d469[_0x2e84f6(0x13f)]};}export const datasetBusinessGroupUpdate={'service':a58_0x1aeca2(0x16a),'command':a58_0x1aeca2(0x148),'description':a58_0x1aeca2(0x167),'risk':a58_0x1aeca2(0x142),'flags':[CODE_FLAG,{'name':a58_0x1aeca2(0x150),'type':a58_0x1aeca2(0x15b),'required':!![],'description':a58_0x1aeca2(0x175)},{'name':a58_0x1aeca2(0x177),'type':a58_0x1aeca2(0x15b),'required':![],'description':a58_0x1aeca2(0x180)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x394398){validateInput(readBusinessGroupUpdateInput(_0x394398));},async 'dryRun'(_0x56caee){const _0x4b1dab=a58_0x1aeca2,_0x4f44c7=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x56caee[_0x4b1dab(0x14a)],'input':readBusinessGroupUpdateInput(_0x56caee),'dryRun':!![]});return{'method':_0x4f44c7[_0x4b1dab(0x17f)][_0x4b1dab(0x185)][_0x4b1dab(0x16d)],'url':_0x4f44c7['data'][_0x4b1dab(0x185)]['path'],'body':_0x4f44c7['data'][_0x4b1dab(0x185)]['payload'],'description':_0x4f44c7[_0x4b1dab(0x140)],..._0x4f44c7[_0x4b1dab(0x17f)]};},async 'execute'(_0x1da9ee){const _0x3d0e06=a58_0x1aeca2;return buildDatasetBusinessGroupUpdateResult({'appCode':_0x1da9ee[_0x3d0e06(0x14a)],'input':readBusinessGroupUpdateInput(_0x1da9ee),'dryRun':![]});}};function readBusinessGroupUpdateInput(_0x3b2890){const _0x4533=a58_0x1aeca2,_0x227f78=_0x3b2890[_0x4533(0x166)](_0x4533(0x177));return{'code':trim(_0x3b2890[_0x4533(0x166)](_0x4533(0x13f))),'businessGroup':_0x3b2890['str'](_0x4533(0x150)),'expectBusinessGroup':_0x227f78===undefined||_0x227f78===''?undefined:_0x227f78};}function validateInput(_0x528b0f){const _0xb371a1=a58_0x1aeca2;if(!trim(_0x528b0f[_0xb371a1(0x13f)]))throw CliErrors[_0xb371a1(0x15d)](_0xb371a1(0x154));if(_0x528b0f[_0xb371a1(0x145)]===undefined)throw CliErrors[_0xb371a1(0x15d)]('--business-group\x20is\x20required');if(!trim(_0x528b0f[_0xb371a1(0x145)]))throw CliErrors[_0xb371a1(0x15d)](_0xb371a1(0x184));}function assertBusinessGroupUpdateSupported(_0x5e6c79,_0x367b07){const _0x130879=a58_0x1aeca2;if(_0x5e6c79[_0x130879(0x13d)]===_0x130879(0x15c)&&!_0x367b07)throw CliErrors[_0x130879(0x15d)](_0x130879(0x183));}function resolveBusinessGroupDataset(_0x12b6e8,_0x5eb6a2){const _0x32bacf=a58_0x1aeca2,_0x1a3416=asPlainObject(_0x12b6e8[_0x32bacf(0x16a)]),_0x3888be=asPlainObject(_0x12b6e8[_0x32bacf(0x181)]),_0x14b40f=resolveSourceType(_0x12b6e8,_0x1a3416,_0x3888be),_0xd44d55=firstString(_0x12b6e8[_0x32bacf(0x168)],_0x12b6e8[_0x32bacf(0x13f)],_0x1a3416[_0x32bacf(0x17d)],_0x5eb6a2)||_0x5eb6a2;return{'id':firstNumber(_0x12b6e8['modelId'],_0x12b6e8['id'],_0x1a3416['datasetId'])??firstString(_0x12b6e8[_0x32bacf(0x186)],_0x12b6e8['id'],_0x1a3416[_0x32bacf(0x16c)])??null,'code':_0xd44d55,'name':firstString(_0x12b6e8[_0x32bacf(0x172)],_0x1a3416[_0x32bacf(0x16e)],_0x1a3416[_0x32bacf(0x172)])||null,'sourceType':_0x14b40f,'dbTableSelector':_0x14b40f==='DB_TABLE'?{'dbLinkId':firstNumber(_0x3888be[_0x32bacf(0x14b)]),'tableName':firstString(_0x3888be['tableName'])||null}:null};}function resolveSourceType(_0x2741df,_0x4c69cc,_0x559a03){const _0xeb85ec=a58_0x1aeca2,_0x48e24a=firstString(_0x2741df[_0xeb85ec(0x178)],_0x2741df['sourceType'],_0x4c69cc[_0xeb85ec(0x178)],_0x4c69cc[_0xeb85ec(0x13d)])?.['trim']()[_0xeb85ec(0x16b)]();if(_0x48e24a===_0xeb85ec(0x15c)||_0x48e24a===_0xeb85ec(0x13c))return _0x48e24a;if(Object[_0xeb85ec(0x17e)](_0x559a03)[_0xeb85ec(0x16f)]>0x0)return _0xeb85ec(0x15c);throw CliErrors['validation'](_0xeb85ec(0x159));}function loadCurrentBusinessGroup(_0xb457eb,_0x184910){const _0x307019=a58_0x1aeca2,_0x5a9bd9=readBusinessGroupFromDatasetDetail(_0xb457eb,_0x184910['sourceType']);if(_0x5a9bd9[_0x307019(0x165)])return normalizeBusinessGroup(_0x5a9bd9[_0x307019(0x143)]);return'';}function readBusinessGroupFromDatasetDetail(_0x3bf210,_0x236bf8){const _0x40e9fe=a58_0x1aeca2,_0x4aa55f=asPlainObject(_0x3bf210[_0x40e9fe(0x16a)]),_0x3602e6=firstPresent(_0x3bf210[_0x40e9fe(0x145)]);if(_0x3602e6[_0x40e9fe(0x165)])return _0x3602e6;const _0x4c7218=firstPresent(_0x4aa55f[_0x40e9fe(0x145)]);if(_0x4c7218[_0x40e9fe(0x165)])return _0x4c7218;if(_0x236bf8===_0x40e9fe(0x15c))return{'found':![]};const _0x429d45=readBusinessGroupFromExtend(_0x3bf210[_0x40e9fe(0x156)]);if(_0x429d45['found'])return _0x429d45;return readBusinessGroupFromExtend(_0x4aa55f[_0x40e9fe(0x156)]);}function readBusinessGroupFromExtend(_0x551b84){const _0xdb6b4c=a58_0x1aeca2;if(_0x551b84===undefined||_0x551b84===null||_0x551b84==='')return{'found':![]};if(typeof _0x551b84==='string')try{const _0xb0f3f6=JSON[_0xdb6b4c(0x164)](_0x551b84);return readBusinessGroupFromExtend(_0xb0f3f6);}catch{return{'found':![]};}const _0x586b30=asPlainObject(_0x551b84);if(Object[_0xdb6b4c(0x17a)]['hasOwnProperty']['call'](_0x586b30,_0xdb6b4c(0x145)))return{'found':!![],'value':_0x586b30[_0xdb6b4c(0x145)]};return{'found':![]};}function firstPresent(..._0x156bbc){for(const _0x4a9ddf of _0x156bbc){if(_0x4a9ddf!==undefined&&_0x4a9ddf!==null)return{'found':!![],'value':_0x4a9ddf};}return{'found':![]};}function assertExpectedBusinessGroup(_0x531d66,_0x45ffc9){const _0x6e708b=a58_0x1aeca2;if(_0x45ffc9===undefined)return;const _0x40ab62=normalizeBusinessGroupArgument(_0x45ffc9);if(_0x531d66!==_0x40ab62)throw CliErrors[_0x6e708b(0x15d)](_0x6e708b(0x170),_0x6e708b(0x141)+JSON['stringify'](_0x40ab62)+_0x6e708b(0x149)+JSON[_0x6e708b(0x162)](_0x531d66));}function buildBackendPlan(_0x2daa31,_0x99b8ac,_0x12b87a){const _0x2d4e4b=a58_0x1aeca2;if(_0x99b8ac[_0x2d4e4b(0x13d)]===_0x2d4e4b(0x15c)){if(!_0x99b8ac[_0x2d4e4b(0x153)]||_0x99b8ac['dbTableSelector']['dbLinkId']===null||!_0x99b8ac[_0x2d4e4b(0x153)]['tableName'])throw CliErrors[_0x2d4e4b(0x15d)](_0x2d4e4b(0x169),_0x2d4e4b(0x182));return{'kind':_0x2d4e4b(0x13e),'method':_0x2d4e4b(0x14e),'path':DB_TABLE_BACKEND_PATH,'payload':{'dbLinkId':_0x99b8ac[_0x2d4e4b(0x153)][_0x2d4e4b(0x147)],'tableName':_0x99b8ac[_0x2d4e4b(0x153)][_0x2d4e4b(0x176)],'businessGroup':_0x12b87a}};}return{'kind':'metadata','method':_0x2d4e4b(0x14e),'path':METADATA_BACKEND_PATH,'payload':{'appCode':_0x2daa31,'datasetCode':_0x99b8ac['code'],'businessGroup':_0x12b87a}};}function normalizeBusinessGroup(_0x262460){const _0x517d8a=a58_0x1aeca2;if(_0x262460===undefined||_0x262460===null)return'';return String(_0x262460)[_0x517d8a(0x155)]();}function normalizeBusinessGroupArgument(_0x10e5f7){const _0x41f86b=normalizeBusinessGroup(_0x10e5f7);return _0x41f86b===UNGROUPED_BUSINESS_GROUP?'':_0x41f86b;}function displayBusinessGroup(_0x8cd28b){return _0x8cd28b||UNGROUPED_BUSINESS_GROUP;}function asPlainObject(_0x529eca){const _0x2eb34d=a58_0x1aeca2;if(!_0x529eca||typeof _0x529eca!==_0x2eb34d(0x161)||Array['isArray'](_0x529eca))return{};return _0x529eca;}function firstString(..._0x34876a){const _0x4c8bcf=a58_0x1aeca2;for(const _0x43d72a of _0x34876a){if(typeof _0x43d72a===_0x4c8bcf(0x15b)&&_0x43d72a[_0x4c8bcf(0x155)]())return _0x43d72a[_0x4c8bcf(0x155)]();if(typeof _0x43d72a==='number'&&Number[_0x4c8bcf(0x15f)](_0x43d72a))return String(_0x43d72a);}return undefined;}function firstNumber(..._0x3d17fb){const _0x58a819=a58_0x1aeca2;for(const _0x2fb17f of _0x3d17fb){if(typeof _0x2fb17f==='number'&&Number[_0x58a819(0x15f)](_0x2fb17f))return _0x2fb17f;if(typeof _0x2fb17f===_0x58a819(0x15b)&&_0x2fb17f['trim']()&&Number['isFinite'](Number(_0x2fb17f)))return Number(_0x2fb17f);}return null;}function trim(_0x21dcfb){const _0x4edab8=a58_0x1aeca2;return String(_0x21dcfb||'')[_0x4edab8(0x155)]();}
|
|
1
|
+
const a58_0x5239a5=a58_0x2c41;(function(_0x290733,_0x3e0f2a){const _0x2e47fb=a58_0x2c41,_0x35b394=_0x290733();while(!![]){try{const _0x3aa1a9=parseInt(_0x2e47fb(0xfa))/0x1*(parseInt(_0x2e47fb(0xef))/0x2)+-parseInt(_0x2e47fb(0xd2))/0x3+parseInt(_0x2e47fb(0xeb))/0x4*(-parseInt(_0x2e47fb(0xb5))/0x5)+parseInt(_0x2e47fb(0xd6))/0x6*(parseInt(_0x2e47fb(0xc1))/0x7)+parseInt(_0x2e47fb(0xe9))/0x8+parseInt(_0x2e47fb(0xc0))/0x9*(-parseInt(_0x2e47fb(0xb4))/0xa)+-parseInt(_0x2e47fb(0xcb))/0xb*(-parseInt(_0x2e47fb(0xed))/0xc);if(_0x3aa1a9===_0x3e0f2a)break;else _0x35b394['push'](_0x35b394['shift']());}catch(_0x5a7b6a){_0x35b394['push'](_0x35b394['shift']());}}}(a58_0x1149,0x8dc36));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateDbTableBusinessGroup,updateErBusinessGroup}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const DB_TABLE_BACKEND_PATH=a58_0x5239a5(0xd7),METADATA_BACKEND_PATH='/smartapi/question/er-config/business-group/edit',UNGROUPED_BUSINESS_GROUP=a58_0x5239a5(0xde);export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x232496,input:_0x591884,dryRun:_0x2d579f}){const _0x1317aa=a58_0x5239a5;validateInput(_0x591884);const _0x1a8843=normalizeBusinessGroupArgument(_0x591884[_0x1317aa(0xfb)]),_0x118872=await getDatasetDetail(_0x591884[_0x1317aa(0xbe)]),_0x4375ed=resolveBusinessGroupDataset(_0x118872,_0x591884['code']);assertBusinessGroupUpdateSupported(_0x4375ed,_0x1a8843);const _0xec95de=loadCurrentBusinessGroup(_0x118872,_0x4375ed);assertExpectedBusinessGroup(_0xec95de,_0x591884[_0x1317aa(0xd0)]);const _0x3d7b56=buildBackendPlan(_0x232496,_0x4375ed,_0x1a8843),_0x2017b5=_0xec95de!==_0x1a8843;let _0x88db9;if(_0x2017b5&&!_0x2d579f){_0x3d7b56[_0x1317aa(0xf6)]===_0x1317aa(0xc9)?await updateDbTableBusinessGroup(_0x3d7b56[_0x1317aa(0xe3)]):await updateErBusinessGroup(_0x3d7b56['payload']);const _0x883cf3=await getDatasetDetail(_0x4375ed[_0x1317aa(0xbe)]),_0x38371b=resolveBusinessGroupDataset(_0x883cf3,_0x4375ed[_0x1317aa(0xbe)]),_0x3b1f33=loadCurrentBusinessGroup(_0x883cf3,_0x38371b);if(_0x3b1f33!==_0x1a8843)throw CliErrors[_0x1317aa(0xb6)]('Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.','Expected\x20'+JSON[_0x1317aa(0xbd)](displayBusinessGroup(_0x1a8843))+_0x1317aa(0xf4)+JSON['stringify'](displayBusinessGroup(_0x3b1f33))+'.');_0x88db9={'verified':!![],'status':'matched','afterReadback':{'businessGroup':displayBusinessGroup(_0x3b1f33)}};}else!_0x2017b5&&(_0x88db9={'verified':!![],'status':_0x1317aa(0xe7),'afterReadback':{'businessGroup':displayBusinessGroup(_0xec95de)}});const _0x3b01b8={'operation':'update','appCode':_0x232496,'selector':{'code':_0x4375ed[_0x1317aa(0xbe)]},'dataset':{'id':_0x4375ed['id'],'code':_0x4375ed['code'],'name':_0x4375ed[_0x1317aa(0xd5)],'sourceType':_0x4375ed[_0x1317aa(0xf7)]},'before':{'businessGroup':displayBusinessGroup(_0xec95de)},'after':{'businessGroup':displayBusinessGroup(_0x1a8843)},'changed':_0x2017b5,'dryRun':_0x2d579f,'submitted':_0x2017b5&&!_0x2d579f,'backend':{'method':_0x3d7b56['method'],'path':_0x3d7b56['path'],'payload':_0x3d7b56['payload']},..._0x88db9?{'verification':_0x88db9}:{},'warnings':[]};return{'ok':!![],'data':_0x3b01b8,'message':_0x2017b5?_0x2d579f?_0x1317aa(0xb1)+_0x4375ed[_0x1317aa(0xbe)]:_0x1317aa(0xf9)+_0x4375ed[_0x1317aa(0xbe)]:_0x1317aa(0xdd)+_0x4375ed[_0x1317aa(0xbe)]};}export const datasetBusinessGroupUpdate={'service':a58_0x5239a5(0xea),'command':a58_0x5239a5(0xcf),'description':'Update\x20business\x20scenario\x20group','risk':'write','flags':[CODE_FLAG,{'name':a58_0x5239a5(0xda),'type':'string','required':!![],'description':'Business\x20scenario\x20group\x20(not\x20technical):\x20use\x20<scenario>,\x20<domain>---<scenario>\x20when\x20needed;\x20METADATA\x20accepts\x20ungrouped\x20to\x20clear\x20it'},{'name':'expect-business-group','type':'string','required':![],'description':a58_0x5239a5(0xe5)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x2023b7){validateInput(readBusinessGroupUpdateInput(_0x2023b7));},async 'dryRun'(_0x5376cf){const _0x302fd4=a58_0x5239a5,_0x1cd231=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x5376cf[_0x302fd4(0xc2)],'input':readBusinessGroupUpdateInput(_0x5376cf),'dryRun':!![]});return{'method':_0x1cd231[_0x302fd4(0xe0)][_0x302fd4(0xe2)]['method'],'url':_0x1cd231[_0x302fd4(0xe0)][_0x302fd4(0xe2)][_0x302fd4(0xcd)],'body':_0x1cd231[_0x302fd4(0xe0)]['backend'][_0x302fd4(0xe3)],'description':_0x1cd231[_0x302fd4(0xdc)],..._0x1cd231['data']};},async 'execute'(_0x44da53){const _0x43ac96=a58_0x5239a5;return buildDatasetBusinessGroupUpdateResult({'appCode':_0x44da53[_0x43ac96(0xc2)],'input':readBusinessGroupUpdateInput(_0x44da53),'dryRun':![]});}};function readBusinessGroupUpdateInput(_0xf61df5){const _0x25c235=a58_0x5239a5,_0x2d427f=_0xf61df5[_0x25c235(0xc4)](_0x25c235(0xf1));return{'code':trim(_0xf61df5[_0x25c235(0xc4)](_0x25c235(0xbe))),'businessGroup':_0xf61df5['str'](_0x25c235(0xda)),'expectBusinessGroup':_0x2d427f===undefined||_0x2d427f===''?undefined:_0x2d427f};}function validateInput(_0x5441bf){const _0x74b3d4=a58_0x5239a5;if(!trim(_0x5441bf['code']))throw CliErrors['validation'](_0x74b3d4(0xec));if(_0x5441bf['businessGroup']===undefined)throw CliErrors[_0x74b3d4(0xf0)]('--business-group\x20is\x20required');if(!trim(_0x5441bf[_0x74b3d4(0xfb)]))throw CliErrors['validation'](_0x74b3d4(0xd8));}function assertBusinessGroupUpdateSupported(_0x4ff213,_0x5dc1c1){const _0x585b9b=a58_0x5239a5;if(_0x4ff213[_0x585b9b(0xf7)]===_0x585b9b(0xe1)&&!_0x5dc1c1)throw CliErrors['validation'](_0x585b9b(0xce));}function resolveBusinessGroupDataset(_0x346b73,_0x1e345a){const _0x561b31=a58_0x5239a5,_0x5773a1=asPlainObject(_0x346b73[_0x561b31(0xea)]),_0x24e896=asPlainObject(_0x346b73['dbtableConfig']),_0xfb4cf2=resolveSourceType(_0x346b73,_0x5773a1,_0x24e896),_0x338cdf=firstString(_0x346b73[_0x561b31(0xbb)],_0x346b73[_0x561b31(0xbe)],_0x5773a1[_0x561b31(0xc6)],_0x1e345a)||_0x1e345a;return{'id':firstNumber(_0x346b73[_0x561b31(0xc8)],_0x346b73['id'],_0x5773a1['datasetId'])??firstString(_0x346b73[_0x561b31(0xc8)],_0x346b73['id'],_0x5773a1[_0x561b31(0xb3)])??null,'code':_0x338cdf,'name':firstString(_0x346b73[_0x561b31(0xd5)],_0x5773a1[_0x561b31(0xe4)],_0x5773a1['name'])||null,'sourceType':_0xfb4cf2,'dbTableSelector':_0xfb4cf2===_0x561b31(0xe1)?{'dbLinkId':firstNumber(_0x24e896[_0x561b31(0xba)]),'tableName':firstString(_0x24e896[_0x561b31(0xc7)])||null}:null};}function resolveSourceType(_0x5ae8e4,_0x164a50,_0xb25024){const _0x5a0942=a58_0x5239a5,_0x3b48cd=firstString(_0x5ae8e4['source'],_0x5ae8e4[_0x5a0942(0xf7)],_0x164a50['source'],_0x164a50[_0x5a0942(0xf7)])?.[_0x5a0942(0xbc)]()[_0x5a0942(0xdb)]();if(_0x3b48cd===_0x5a0942(0xe1)||_0x3b48cd===_0x5a0942(0xf2))return _0x3b48cd;if(Object[_0x5a0942(0xf3)](_0xb25024)[_0x5a0942(0xd4)]>0x0)return'DB_TABLE';throw CliErrors[_0x5a0942(0xf0)](_0x5a0942(0xb2));}function loadCurrentBusinessGroup(_0xe070df,_0x11b403){const _0x526427=a58_0x5239a5,_0x248aa9=readBusinessGroupFromDatasetDetail(_0xe070df,_0x11b403[_0x526427(0xf7)]);if(_0x248aa9[_0x526427(0xc5)])return normalizeBusinessGroup(_0x248aa9['value']);return'';}function readBusinessGroupFromDatasetDetail(_0x52456f,_0x294c24){const _0x348681=a58_0x5239a5,_0x3abf6d=asPlainObject(_0x52456f[_0x348681(0xea)]),_0x5ab22f=firstPresent(_0x52456f['businessGroup']);if(_0x5ab22f[_0x348681(0xc5)])return _0x5ab22f;const _0x79e770=firstPresent(_0x3abf6d[_0x348681(0xfb)]);if(_0x79e770[_0x348681(0xc5)])return _0x79e770;if(_0x294c24===_0x348681(0xe1))return{'found':![]};const _0x1e360d=readBusinessGroupFromExtend(_0x52456f[_0x348681(0xd3)]);if(_0x1e360d[_0x348681(0xc5)])return _0x1e360d;return readBusinessGroupFromExtend(_0x3abf6d[_0x348681(0xd3)]);}function readBusinessGroupFromExtend(_0x416cc8){const _0x547f99=a58_0x5239a5;if(_0x416cc8===undefined||_0x416cc8===null||_0x416cc8==='')return{'found':![]};if(typeof _0x416cc8===_0x547f99(0xb8))try{const _0x3da4ea=JSON[_0x547f99(0xf8)](_0x416cc8);return readBusinessGroupFromExtend(_0x3da4ea);}catch{return{'found':![]};}const _0x237b75=asPlainObject(_0x416cc8);if(Object[_0x547f99(0xe6)][_0x547f99(0xcc)][_0x547f99(0xd1)](_0x237b75,_0x547f99(0xfb)))return{'found':!![],'value':_0x237b75[_0x547f99(0xfb)]};return{'found':![]};}function firstPresent(..._0x41a9df){for(const _0x389131 of _0x41a9df){if(_0x389131!==undefined&&_0x389131!==null)return{'found':!![],'value':_0x389131};}return{'found':![]};}function assertExpectedBusinessGroup(_0x42e1a7,_0x40c3ed){const _0x33c7f1=a58_0x5239a5;if(_0x40c3ed===undefined)return;const _0x540d3d=normalizeBusinessGroupArgument(_0x40c3ed);if(_0x42e1a7!==_0x540d3d)throw CliErrors[_0x33c7f1(0xf0)](_0x33c7f1(0xe8),_0x33c7f1(0xdf)+JSON[_0x33c7f1(0xbd)](_0x540d3d)+_0x33c7f1(0xf4)+JSON[_0x33c7f1(0xbd)](_0x42e1a7));}function a58_0x1149(){const _0x4a0776=['extend','length','name','6rGJEFv','/smartapi/dblink/updateTableBusinessGroup','--business-group\x20must\x20not\x20be\x20blank','metadata','business-group','toUpperCase','message','No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20','ungrouped','Expected\x20','data','DB_TABLE','backend','payload','datasetName','Expected\x20current\x20business\x20scenario\x20group;\x20use\x20ungrouped\x20to\x20expect\x20no\x20group;\x20mismatch\x20aborts\x20without\x20writing','prototype','unchanged','Expectation\x20mismatch\x20at\x20businessGroup','1152656PIQPwn','dataset','4xTnbvx','--code\x20is\x20required','101964eQggIu','isFinite','1070074vfWsWJ','validation','expect-business-group','METADATA','keys',',\x20actual\x20','dbTableSelector','kind','sourceType','parse','Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20','1PYJTuY','businessGroup','Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20','Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.','datasetId','220fQwxSv','4848315cmIbQh','apiError','DB_TABLE\x20dataset\x20requires\x20dbtableConfig.dbId\x20and\x20tableName.','string','number','dbId','modelCode','trim','stringify','code','isArray','427383OFjvrB','1498798VJOYoU','appCode','dbLinkId','str','found','datasetCode','tableName','modelId','db-table','object','2827dcCSFd','hasOwnProperty','path','Clearing\x20business\x20scenario\x20groups\x20is\x20not\x20supported\x20for\x20DB_TABLE\x20datasets.','business-group-update','expectBusinessGroup','call','1445769qZLXcx'];a58_0x1149=function(){return _0x4a0776;};return a58_0x1149();}function buildBackendPlan(_0x1b185f,_0x2c63ee,_0x1ba3e8){const _0x340fbf=a58_0x5239a5;if(_0x2c63ee[_0x340fbf(0xf7)]===_0x340fbf(0xe1)){if(!_0x2c63ee['dbTableSelector']||_0x2c63ee[_0x340fbf(0xf5)]['dbLinkId']===null||!_0x2c63ee[_0x340fbf(0xf5)][_0x340fbf(0xc7)])throw CliErrors[_0x340fbf(0xf0)](_0x340fbf(0xb7),'Run\x20dataset\x20detail\x20and\x20complete\x20database\x20analysis\x20before\x20updating\x20the\x20business\x20group.');return{'kind':_0x340fbf(0xc9),'method':'POST','path':DB_TABLE_BACKEND_PATH,'payload':{'dbLinkId':_0x2c63ee[_0x340fbf(0xf5)][_0x340fbf(0xc3)],'tableName':_0x2c63ee['dbTableSelector'][_0x340fbf(0xc7)],'businessGroup':_0x1ba3e8}};}return{'kind':_0x340fbf(0xd9),'method':'POST','path':METADATA_BACKEND_PATH,'payload':{'appCode':_0x1b185f,'datasetCode':_0x2c63ee[_0x340fbf(0xbe)],'businessGroup':_0x1ba3e8}};}function normalizeBusinessGroup(_0x1a47aa){const _0x3261be=a58_0x5239a5;if(_0x1a47aa===undefined||_0x1a47aa===null)return'';return String(_0x1a47aa)[_0x3261be(0xbc)]();}function normalizeBusinessGroupArgument(_0x37b9c0){const _0x574262=normalizeBusinessGroup(_0x37b9c0);return _0x574262===UNGROUPED_BUSINESS_GROUP?'':_0x574262;}function displayBusinessGroup(_0x3be721){return _0x3be721||UNGROUPED_BUSINESS_GROUP;}function a58_0x2c41(_0x3f77cf,_0x19b87b){_0x3f77cf=_0x3f77cf-0xb1;const _0x114904=a58_0x1149();let _0x2c419f=_0x114904[_0x3f77cf];return _0x2c419f;}function asPlainObject(_0x74415b){const _0x2c9d26=a58_0x5239a5;if(!_0x74415b||typeof _0x74415b!==_0x2c9d26(0xca)||Array[_0x2c9d26(0xbf)](_0x74415b))return{};return _0x74415b;}function firstString(..._0x5ac43c){const _0xe8f6a3=a58_0x5239a5;for(const _0x4a2b2d of _0x5ac43c){if(typeof _0x4a2b2d==='string'&&_0x4a2b2d[_0xe8f6a3(0xbc)]())return _0x4a2b2d[_0xe8f6a3(0xbc)]();if(typeof _0x4a2b2d==='number'&&Number[_0xe8f6a3(0xee)](_0x4a2b2d))return String(_0x4a2b2d);}return undefined;}function firstNumber(..._0x467628){const _0x2937c2=a58_0x5239a5;for(const _0x29832b of _0x467628){if(typeof _0x29832b===_0x2937c2(0xb9)&&Number['isFinite'](_0x29832b))return _0x29832b;if(typeof _0x29832b===_0x2937c2(0xb8)&&_0x29832b[_0x2937c2(0xbc)]()&&Number[_0x2937c2(0xee)](Number(_0x29832b)))return Number(_0x29832b);}return null;}function trim(_0x2f5e50){const _0x422fdd=a58_0x5239a5;return String(_0x2f5e50||'')[_0x422fdd(0xbc)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a59_0x4967e7=a59_0xe232;(function(_0x2abbbd,_0x3a3daf){const _0x20d89a=a59_0xe232,_0x1bb1a6=_0x2abbbd();while(!![]){try{const _0x5a9078=-parseInt(_0x20d89a(0x7b))/0x1*(parseInt(_0x20d89a(0x81))/0x2)+parseInt(_0x20d89a(0x7e))/0x3*(-parseInt(_0x20d89a(0x7d))/0x4)+-parseInt(_0x20d89a(0x85))/0x5*(-parseInt(_0x20d89a(0x75))/0x6)+parseInt(_0x20d89a(0x78))/0x7*(-parseInt(_0x20d89a(0x8c))/0x8)+parseInt(_0x20d89a(0x7c))/0x9*(parseInt(_0x20d89a(0x8a))/0xa)+-parseInt(_0x20d89a(0x83))/0xb+parseInt(_0x20d89a(0x77))/0xc;if(_0x5a9078===_0x3a3daf)break;else _0x1bb1a6['push'](_0x1bb1a6['shift']());}catch(_0x40cee4){_0x1bb1a6['push'](_0x1bb1a6['shift']());}}}(a59_0x4cca,0x978a7));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getErBusinessGroupSummary}from'../../core/api-client.js';function a59_0xe232(_0x20e0a7,_0x453494){_0x20e0a7=_0x20e0a7-0x75;const _0x4cca6e=a59_0x4cca();let _0xe232e5=_0x4cca6e[_0x20e0a7];return _0xe232e5;}function a59_0x4cca(){const _0x298873=['18HEYibA','16LGgcUb','32166EMBwrp','dbid','business-groups','154cjhDtl','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','1663519fQhfsj','businessGroup','12945ZGhmlL','trim','List\x20DB_TABLE\x20dataset\x20business\x20groups\x20for\x20a\x20database\x20connection;\x20does\x20not\x20include\x20METADATA','Found\x20','map','1495510FoUzqp','dataset','2752zCVLLy','1542ScKPEU','groups','17086200bhBAqQ','10990aVvMmi','DB_TABLE','number','13421sNafiA'];a59_0x4cca=function(){return _0x298873;};return a59_0x4cca();}export const datasetBusinessGroups={'service':a59_0x4967e7(0x8b),'command':a59_0x4967e7(0x80),'description':a59_0x4967e7(0x87),'risk':'read','flags':[{'name':a59_0x4967e7(0x7f),'type':a59_0x4967e7(0x7a),'required':!![],'description':a59_0x4967e7(0x82)},APPCODE_FLAG_OPTIONAL],async 'execute'(_0x50971d){const _0x4718b0=a59_0x4967e7,_0x4bc162=_0x50971d['num'](_0x4718b0(0x7f)),_0x12cde3=await getErBusinessGroupSummary(_0x50971d['appCode'],_0x4bc162),_0x2afb82=_0x12cde3[_0x4718b0(0x76)][_0x4718b0(0x89)](_0x434b26=>({..._0x434b26,'businessGroup':_0x434b26[_0x4718b0(0x84)][_0x4718b0(0x86)]()||'ungrouped'}));return{'ok':!![],'data':{..._0x12cde3,'groups':_0x2afb82,'scope':_0x4718b0(0x79)},'message':_0x4718b0(0x88)+_0x2afb82['length']+'\x20business\x20group(s)\x20for\x20database\x20connection\x20'+_0x4bc162};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a60_0x56730d=a60_0x55d8;(function(_0x23da0d,_0x4f4b86){const _0x575a87=a60_0x55d8,_0x13c327=_0x23da0d();while(!![]){try{const _0x523305=-parseInt(_0x575a87(0x154))/0x1*(parseInt(_0x575a87(0x164))/0x2)+-parseInt(_0x575a87(0x151))/0x3*(parseInt(_0x575a87(0x156))/0x4)+-parseInt(_0x575a87(0x144))/0x5+-parseInt(_0x575a87(0x15f))/0x6+parseInt(_0x575a87(0x168))/0x7+parseInt(_0x575a87(0x157))/0x8+parseInt(_0x575a87(0x161))/0x9*(parseInt(_0x575a87(0x14d))/0xa);if(_0x523305===_0x4f4b86)break;else _0x13c327['push'](_0x13c327['shift']());}catch(_0x246a75){_0x13c327['push'](_0x13c327['shift']());}}}(a60_0x15b9,0xd7816));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':'lovrabet','filter':a60_0x56730d(0x14b),'getOne':a60_0x56730d(0x163)};export const RUNTIME_DATA_ACCESS_SUMMARY=a60_0x56730d(0x145);function a60_0x15b9(){const _0x4e2828=['Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.','dbId','\x20and\x20has\x20no\x20DB_TABLE\x20data-source\x20context\x20for\x20','filter','getOne','dbtableConfig','lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','\x20is\x20','477510sBLydT','length','UNKNOWN','validation','6279VSSMRH','datasetName','modelCode','94OwaNFu','To\x20inspect\x20real\x20runtime\x20rows,\x20switch\x20to\x20lovrabet\x20CLI:\x20','44ETuyVh','6123152LbSrIo','Reason:\x20schema\x20introspection\x20and\x20custom\x20SQL\x20require\x20source=DB_TABLE,\x20dbtableConfig.dbId,\x20dbtableConfig.tableName,\x20and\x20a\x20database\x20connection\x20context.','tableName','object','dataset','toUpperCase','Upgrade\x20or\x20migrate\x20this\x20dataset\x20to\x20a\x20DB_TABLE\x20dataset,\x20then\x20continue\x20with\x20the\x20new\x20dataset\x20code.','source','2370282EMXYgm','trim','540ilZcgH','SQL\x20schema\x20validation','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress','37318nDhfCH','dbtable','join','name','7042784KkLcoN','datasetCode','METADATA','7909200DWRuIN'];a60_0x15b9=function(){return _0x4e2828;};return a60_0x15b9();}function valueToString(_0x404895){const _0x5f4e1d=a60_0x56730d;return _0x404895==null?'':String(_0x404895)[_0x5f4e1d(0x160)]();}function getDatasetCode(_0x478003){const _0x5119b8=a60_0x56730d;return valueToString(_0x478003['code']??_0x478003[_0x5119b8(0x153)]??_0x478003[_0x5119b8(0x15b)]?.[_0x5119b8(0x169)]);}function getDatasetName(_0x2538fd){const _0x3a031f=a60_0x56730d;return valueToString(_0x2538fd[_0x3a031f(0x167)]??_0x2538fd[_0x3a031f(0x15b)]?.[_0x3a031f(0x152)])||'unknown';}function getDatasetSource(_0x38fa36){const _0x9c0900=a60_0x56730d;return valueToString(_0x38fa36[_0x9c0900(0x15e)]??_0x38fa36[_0x9c0900(0x15b)]?.['sourceType'])[_0x9c0900(0x15c)]();}function a60_0x55d8(_0xdb2af1,_0x354891){_0xdb2af1=_0xdb2af1-0x143;const _0x15b9ed=a60_0x15b9();let _0x55d85a=_0x15b9ed[_0xdb2af1];return _0x55d85a;}function getDbtableConfig(_0x5350b9){const _0x243041=a60_0x56730d,_0x152805=_0x5350b9[_0x243041(0x14a)]??_0x5350b9[_0x243041(0x165)];return _0x152805&&typeof _0x152805===_0x243041(0x15a)?_0x152805:{};}export function isDbTableBackedDataset(_0x177b9e){const _0x4784c1=a60_0x56730d,_0x17fb72=getDatasetSource(_0x177b9e);if(_0x17fb72===_0x4784c1(0x143))return![];const _0x264147=getDbtableConfig(_0x177b9e),_0x12ad80=_0x264147[_0x4784c1(0x146)]??_0x264147['id'],_0x26b4a7=valueToString(_0x264147[_0x4784c1(0x159)]??_0x177b9e[_0x4784c1(0x159)]??_0x177b9e[_0x4784c1(0x15b)]?.[_0x4784c1(0x159)]);return _0x12ad80!==undefined&&_0x12ad80!==null&&_0x26b4a7[_0x4784c1(0x14e)]>0x0;}export function filterDbTableBackedDatasets(_0x5c8c6f){const _0x169494=a60_0x56730d;return _0x5c8c6f[_0x169494(0x148)](_0x35bd20=>isDbTableBackedDataset(_0x35bd20));}export function buildDbTableBackedRequirementMessage(_0x558dea,_0x35c878=a60_0x56730d(0x162)){const _0xb0e7a6=a60_0x56730d,_0x7f4a3f=getDatasetSource(_0x558dea)||_0xb0e7a6(0x14f),_0x105fa7=getDatasetName(_0x558dea),_0x14a36b=getDatasetCode(_0x558dea),_0x52ac1b=_0x14a36b?'\x20('+_0x14a36b+')':'';return['The\x20current\x20dataset\x20\x22'+_0x105fa7+'\x22'+_0x52ac1b+_0xb0e7a6(0x14c)+_0x7f4a3f+_0xb0e7a6(0x147)+_0x35c878+'.',_0xb0e7a6(0x158),_0xb0e7a6(0x15d),_0xb0e7a6(0x155)+RUNTIME_DATA_ACCESS_COMMANDS[_0xb0e7a6(0x148)]+';\x20'+RUNTIME_DATA_ACCESS_COMMANDS[_0xb0e7a6(0x149)]+'.'][_0xb0e7a6(0x166)]('\x20');}export function assertDatasetIsDbTableBacked(_0x5f1cf6,_0x38a658){const _0x2f582f=a60_0x56730d;if(!isDbTableBackedDataset(_0x5f1cf6))throw CliErrors[_0x2f582f(0x150)](buildDbTableBackedRequirementMessage(_0x5f1cf6,_0x38a658));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a61_0x2d86db=a61_0x40a3;(function(_0x34b89f,_0x1aa050){const _0x50b45e=a61_0x40a3,_0x20c719=_0x34b89f();while(!![]){try{const _0x4e2642=-parseInt(_0x50b45e(0xa9))/0x1*(parseInt(_0x50b45e(0xb8))/0x2)+parseInt(_0x50b45e(0xac))/0x3*(parseInt(_0x50b45e(0xa4))/0x4)+-parseInt(_0x50b45e(0x83))/0x5*(parseInt(_0x50b45e(0x9e))/0x6)+parseInt(_0x50b45e(0x92))/0x7+-parseInt(_0x50b45e(0xa8))/0x8+parseInt(_0x50b45e(0x94))/0x9*(parseInt(_0x50b45e(0x8a))/0xa)+parseInt(_0x50b45e(0x8c))/0xb;if(_0x4e2642===_0x1aa050)break;else _0x20c719['push'](_0x20c719['shift']());}catch(_0x459079){_0x20c719['push'](_0x20c719['shift']());}}}(a61_0x4cb2,0x99939));import{deleteDataset,getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL,CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a61_0x40a3(_0x3435b3,_0x20d5b2){_0x3435b3=_0x3435b3-0x81;const _0x4cb22c=a61_0x4cb2();let _0x40a30b=_0x4cb22c[_0x3435b3];return _0x40a30b;}const DATASET_ID_FLAG={'name':'id','type':a61_0x2d86db(0xb4),'description':a61_0x2d86db(0x84)},DBID_FLAG={'name':a61_0x2d86db(0x81),'type':a61_0x2d86db(0xb4),'description':a61_0x2d86db(0xb7)},CONFIRM_FLAG={'name':a61_0x2d86db(0xbb),'type':a61_0x2d86db(0x9f),'description':'Required\x20to\x20execute\x20dataset\x20deletion'},CASCADE_FLAG={'name':a61_0x2d86db(0xb0),'type':a61_0x2d86db(0x9f),'description':a61_0x2d86db(0xbd)},EXPECTED_COUNT_FLAG={'name':a61_0x2d86db(0xab),'type':a61_0x2d86db(0xb4),'description':a61_0x2d86db(0xbf)};function a61_0x4cb2(){const _0x196e4e=['2635fkXhiM','Dataset\x20id','id=','description','\x20--appcode\x20','title','isArray','12325370HwhwYI','dbtableConfig','3646511udoigl','appCode','Would\x20delete\x20','num','Deleted\x20','\x20dataset(s)\x20and\x20their\x20listed\x20related\x20pages/menus.\x20Restore\x20each\x20Dataset\x20first,\x20then\x20restore\x20pages\x20explicitly\x20when\x20needed.','5641279GjqLTv','dataset','9vIPMef','delete','message','Use\x20only\x20one\x20of\x20--id,\x20--code,\x20or\x20--dbid.','length','push','bool','deleted','type','POST','12234WhnCVj','boolean','source','One\x20of\x20--id,\x20--code,\x20or\x20--dbid\x20is\x20required.','false','--confirm\x20is\x20required\x20to\x20delete\x20datasets.','24bjLsRT','\x20dataset(s);\x20','object','relatedPageInfoList','4729088oNNUDg','1oqKKPx','name','expected-count','97932tysjtr','No\x20undeleted\x20dataset\x20found\x20for\x20','filter','map','cascade','isInteger','Matched\x20','Delete\x20dataset\x20metadata\x20by\x20id/code\x20or\x20all\x20datasets\x20under\x20a\x20db\x20id','number','\x20failed','dbId','Delete\x20all\x20datasets\x20under\x20this\x20database\x20connection\x20id','542122FQIkXr','code','validation','confirm','/smartapi/dataset/delete?cascade=','Also\x20delete\x20related\x20pages\x20and\x20menus;\x20requires\x20explicit\x20--confirm','\x20dataset(s),\x20but\x20--expected-count\x20is\x20','Abort\x20unless\x20the\x20matched\x20dataset\x20count\x20equals\x20this\x20value','dbid','true'];a61_0x4cb2=function(){return _0x196e4e;};return a61_0x4cb2();}export const datasetDelete={'service':a61_0x2d86db(0x93),'command':a61_0x2d86db(0x95),'description':a61_0x2d86db(0xb3),'risk':'high-risk-write','flags':[DATASET_ID_FLAG,CODE_FLAG_OPTIONAL,DBID_FLAG,CASCADE_FLAG,CONFIRM_FLAG,EXPECTED_COUNT_FLAG,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x4e26ce){const _0xf9c0d3=a61_0x2d86db,_0x3c6dd7=_0x4e26ce[_0xf9c0d3(0x8f)]('id'),_0x16e8b8=_0x4e26ce['str'](_0xf9c0d3(0xb9)),_0x1d8c26=_0x4e26ce['num'](_0xf9c0d3(0x81)),_0x3eab1e=[_0x3c6dd7>0x0,Boolean(_0x16e8b8),_0x1d8c26>0x0][_0xf9c0d3(0xae)](Boolean);if(_0x3eab1e[_0xf9c0d3(0x98)]===0x0)throw CliErrors['validation'](_0xf9c0d3(0xa1));if(_0x3eab1e['length']>0x1)throw CliErrors['validation'](_0xf9c0d3(0x97));},async 'dryRun'(_0x25d65e){const _0x2b4fe1=a61_0x2d86db,_0x371a84=await resolveTargets(_0x25d65e),_0x872001=_0x25d65e['bool']('cascade');return{'method':_0x2b4fe1(0x9d),'url':_0x2b4fe1(0xbc)+(_0x872001?_0x2b4fe1(0x82):_0x2b4fe1(0xa2)),'body':{'count':_0x371a84[_0x2b4fe1(0x98)],'cascade':_0x872001,'datasets':_0x371a84},'description':_0x872001?_0x2b4fe1(0x8e)+_0x371a84[_0x2b4fe1(0x98)]+_0x2b4fe1(0x91):'Would\x20safely\x20delete\x20'+_0x371a84['length']+'\x20dataset(s)\x20without\x20cascading\x20to\x20pages.\x20The\x20server\x20blocks\x20a\x20Dataset\x20that\x20still\x20has\x20related\x20pages.'};},async 'execute'(_0x3c35ce){const _0x1a260f=a61_0x2d86db;if(!_0x3c35ce[_0x1a260f(0x9a)]('confirm'))throw CliErrors[_0x1a260f(0xba)](_0x1a260f(0xa3),'Run\x20with\x20--dry-run\x20first,\x20then\x20add\x20--confirm\x20when\x20the\x20target\x20list\x20is\x20correct.');const _0x6eb9b4=await resolveTargets(_0x3c35ce),_0x252395=_0x3c35ce['bool'](_0x1a260f(0xb0)),_0x3f0cdd=[],_0x413e1e=[];for(const _0x2ddbfe of _0x6eb9b4){try{await deleteDataset(_0x2ddbfe['id'],_0x252395),_0x3f0cdd['push'](_0x2ddbfe);}catch(_0x23af19){_0x413e1e[_0x1a260f(0x99)]({..._0x2ddbfe,'error':_0x23af19 instanceof Error?_0x23af19[_0x1a260f(0x96)]:String(_0x23af19)});}}if(_0x413e1e[_0x1a260f(0x98)]>0x0){const _0x16ebae=buildPageRestoreCommands(_0x3c35ce['appCode'],_0x252395?_0x3f0cdd:[]);return{'ok':![],'data':{'requested':_0x6eb9b4[_0x1a260f(0x98)],'cascade':_0x252395,'deletedCount':_0x3f0cdd[_0x1a260f(0x98)],'failedCount':_0x413e1e[_0x1a260f(0x98)],'deleted':_0x3f0cdd,'failed':_0x413e1e,'pageRestoreCommands':_0x16ebae},'message':_0x1a260f(0x90)+_0x3f0cdd[_0x1a260f(0x98)]+'/'+_0x6eb9b4[_0x1a260f(0x98)]+_0x1a260f(0xa5)+_0x413e1e[_0x1a260f(0x98)]+_0x1a260f(0xb5)};}return{'ok':!![],'data':{'requested':_0x6eb9b4[_0x1a260f(0x98)],'cascade':_0x252395,'deletedCount':_0x3f0cdd[_0x1a260f(0x98)],'deleted':_0x3f0cdd,'pageRestoreCommands':buildPageRestoreCommands(_0x3c35ce[_0x1a260f(0x8d)],_0x252395?_0x3f0cdd:[])},'message':_0x1a260f(0x90)+_0x3f0cdd['length']+'\x20dataset(s)'};}};async function resolveTargets(_0x9212f1){const _0x10b30e=a61_0x2d86db,_0xce1518=_0x9212f1[_0x10b30e(0x8f)]('id'),_0x391537=_0x9212f1['str'](_0x10b30e(0xb9)),_0x4ba154=_0x9212f1['num'](_0x10b30e(0x81));let _0x1e0594;_0x391537?(_0x1e0594=await listDatasets(_0x9212f1[_0x10b30e(0x8d)],{'code':_0x391537}),_0x1e0594=_0x1e0594[_0x10b30e(0xae)](_0x4d4f41=>_0x4d4f41[_0x10b30e(0xb9)]===_0x391537)):(_0x1e0594=await listDatasets(_0x9212f1[_0x10b30e(0x8d)]),_0xce1518>0x0&&(_0x1e0594=_0x1e0594[_0x10b30e(0xae)](_0x4ebc76=>_0x4ebc76['id']===_0xce1518)),_0x4ba154>0x0&&(_0x1e0594=_0x1e0594['filter'](_0xab219e=>_0xab219e[_0x10b30e(0x8b)]?.['dbId']===_0x4ba154)));const _0x5859ec=[];for(const _0x3e46ec of _0x1e0594){const _0x2a5771=await getDatasetDetail(_0x3e46ec[_0x10b30e(0xb9)]),_0x307df0=Array[_0x10b30e(0x89)](_0x2a5771[_0x10b30e(0xa7)])?_0x2a5771[_0x10b30e(0xa7)][_0x10b30e(0xae)](_0x2f4259=>_0x2f4259!=null&&typeof _0x2f4259===_0x10b30e(0xa6)&&_0x2f4259[_0x10b30e(0x9b)]!==!![]):[];_0x5859ec[_0x10b30e(0x99)](normalizeTarget(_0x3e46ec,_0x307df0));}if(_0x5859ec[_0x10b30e(0x98)]===0x0){const _0x389cce=_0x391537||(_0xce1518>0x0?_0x10b30e(0x85)+_0xce1518:'dbid='+_0x4ba154);throw CliErrors['validation'](_0x10b30e(0xad)+_0x389cce+'.');}const _0x42f020=_0x9212f1['num'](_0x10b30e(0xab));if(_0x42f020>0x0&&_0x5859ec[_0x10b30e(0x98)]!==_0x42f020)throw CliErrors[_0x10b30e(0xba)](_0x10b30e(0xb2)+_0x5859ec['length']+_0x10b30e(0xbe)+_0x42f020+'.');return _0x5859ec;}function normalizeTarget(_0x20255a,_0x4f9329){const _0xa12968=a61_0x2d86db,_0x4eb036=_0x20255a['dbtableConfig']??{},_0x7ea84=_0x4f9329[_0xa12968(0xaf)](_0x52be84=>{const _0x5282c9=_0xa12968;if(_0x52be84==null||typeof _0x52be84!=='object')return null;const _0x4a57bc=_0x52be84,_0x234184=Number(_0x4a57bc['id']);if(!Number[_0x5282c9(0xb1)](_0x234184)||_0x234184<=0x0)return null;const _0x24f457=_0x4a57bc[_0x5282c9(0x88)]??_0x4a57bc[_0x5282c9(0xaa)];return{'id':_0x234184,..._0x24f457?{'name':String(_0x24f457)}:{},..._0x4a57bc[_0x5282c9(0x9c)]?{'type':String(_0x4a57bc['type'])}:{}};})[_0xa12968(0xae)](_0x1772a0=>_0x1772a0!==null);return{'id':_0x20255a['id'],'code':_0x20255a[_0xa12968(0xb9)],'name':_0x20255a[_0xa12968(0xaa)],'description':_0x20255a[_0xa12968(0x86)],'source':_0x20255a[_0xa12968(0xa0)],'dbId':_0x4eb036[_0xa12968(0xb6)],'dbName':_0x4eb036['dbName'],'tableName':_0x4eb036['tableName'],'relatedPageCount':_0x7ea84[_0xa12968(0x98)],'relatedPages':_0x7ea84};}function buildPageRestoreCommands(_0x3faa6a,_0x5ac699){const _0x3a0d3e=a61_0x2d86db,_0x170320=new Set();for(const _0x33ae76 of _0x5ac699){for(const _0x1da813 of _0x33ae76['relatedPages'])_0x170320['add'](_0x1da813['id']);}return[..._0x170320][_0x3a0d3e(0xaf)](_0x17470f=>'rabetbase\x20page\x20restore\x20--id\x20'+_0x17470f+_0x3a0d3e(0x87)+_0x3faa6a);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a62_0x1acca6=a62_0x1ea2;(function(_0x2aba47,_0x390129){const _0x28f1b4=a62_0x1ea2,_0x856d6e=_0x2aba47();while(!![]){try{const _0x221723=parseInt(_0x28f1b4(0xf0))/0x1+-parseInt(_0x28f1b4(0x10a))/0x2+parseInt(_0x28f1b4(0x111))/0x3*(-parseInt(_0x28f1b4(0x109))/0x4)+parseInt(_0x28f1b4(0x101))/0x5+-parseInt(_0x28f1b4(0x126))/0x6+-parseInt(_0x28f1b4(0x11e))/0x7*(parseInt(_0x28f1b4(0x122))/0x8)+-parseInt(_0x28f1b4(0xd7))/0x9*(-parseInt(_0x28f1b4(0xf4))/0xa);if(_0x221723===_0x390129)break;else _0x856d6e['push'](_0x856d6e['shift']());}catch(_0x17339a){_0x856d6e['push'](_0x856d6e['shift']());}}}(a62_0x4038,0x70d2f));import{getDatasetDetail}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function normalizeField(_0xb59f4e){const _0x1297e5=a62_0x1ea2;if(_0xb59f4e[_0x1297e5(0xff)])return null;const _0x426f8a=Boolean(_0xb59f4e[_0x1297e5(0x108)]!==undefined||_0xb59f4e[_0x1297e5(0xdc)]!==undefined);let _0x256aff={};if(!_0x426f8a&&typeof _0xb59f4e[_0x1297e5(0xd8)]===_0x1297e5(0xe0))try{_0x256aff=JSON[_0x1297e5(0x10d)](_0xb59f4e[_0x1297e5(0xd8)]);}catch{}const _0x511993=_0x426f8a?_0xb59f4e[_0x1297e5(0x103)]:_0xb59f4e['code'],_0x69a507=_0x426f8a?_0xb59f4e[_0x1297e5(0x108)]:_0xb59f4e['name'],_0x519446=_0x426f8a?_0xb59f4e['doType']:_0xb59f4e[_0x1297e5(0x123)]||_0xb59f4e['dataType'],_0xa246de=_0x426f8a?_0xb59f4e['pkField']===!![]:_0x256aff[_0x1297e5(0x107)]===!![],_0x3fa03e=_0x426f8a?_0xb59f4e[_0x1297e5(0x118)]===!![]:_0x256aff['required']===!![],_0x31415e=_0x426f8a?_0xb59f4e[_0x1297e5(0xd6)]??null:_0x256aff[_0x1297e5(0xd6)]??null,_0xe27085={'name':_0x511993,'displayName':_0x69a507||_0x511993,'type':_0x519446,'dbType':_0xb59f4e[_0x1297e5(0x106)],'pk':_0xa246de,'required':_0x3fa03e,'deprecated':_0xb59f4e[_0x1297e5(0x121)]===!![],'description':_0xb59f4e[_0x1297e5(0xd5)]||undefined};return Array[_0x1297e5(0x119)](_0x31415e)&&_0x31415e[_0x1297e5(0x11b)]>0x0&&(_0xe27085[_0x1297e5(0xd6)]=_0x31415e),_0xe27085;}function parseJsonMaybe(_0x2d02e4){const _0x5b1397=a62_0x1ea2;if(typeof _0x2d02e4!==_0x5b1397(0xe0))return _0x2d02e4;try{return JSON['parse'](_0x2d02e4);}catch{return _0x2d02e4;}}function normalizeOperationEntry(_0x135cd3,_0x1565a5){const _0x4ae31f=a62_0x1ea2;if(!_0x1565a5||typeof _0x1565a5!==_0x4ae31f(0xd4))return null;if(!_0x1565a5['method']||!_0x1565a5['path'])return null;const _0x13bfc8={'name':_0x135cd3,'method':_0x1565a5[_0x4ae31f(0x110)],'path':_0x1565a5[_0x4ae31f(0xe9)]};if(_0x1565a5[_0x4ae31f(0xe3)])_0x13bfc8[_0x4ae31f(0xe3)]=_0x1565a5[_0x4ae31f(0xe3)];if(_0x1565a5[_0x4ae31f(0x114)]!=null){const _0x29c927=parseJsonMaybe(_0x1565a5['requestBody']);_0x13bfc8[_0x4ae31f(0x114)]=_0x29c927;}if(_0x1565a5[_0x4ae31f(0x10b)]!=null){const _0x4089f5=parseJsonMaybe(_0x1565a5['responseBody']);_0x13bfc8[_0x4ae31f(0x10b)]=_0x4089f5;}if(_0x1565a5['beforeScriptId']!=null)_0x13bfc8[_0x4ae31f(0x11a)]=_0x1565a5['beforeScriptId'];if(_0x1565a5[_0x4ae31f(0xe2)]!=null)_0x13bfc8[_0x4ae31f(0xe2)]=_0x1565a5[_0x4ae31f(0xe2)];if(Array['isArray'](_0x1565a5[_0x4ae31f(0xe4)]))_0x13bfc8[_0x4ae31f(0xe4)]=_0x1565a5[_0x4ae31f(0xe4)];if(Array[_0x4ae31f(0x119)](_0x1565a5['responseFields']))_0x13bfc8[_0x4ae31f(0xf2)]=_0x1565a5[_0x4ae31f(0xf2)];return _0x13bfc8;}function summarizeDbtable(_0x4fbf1e){const _0x5e214c=a62_0x1ea2,_0x2fed65={},_0x370d2e=['dbId',_0x5e214c(0xf9),_0x5e214c(0xd9),_0x5e214c(0xeb),_0x5e214c(0x107),'allFields',_0x5e214c(0xe7),'createTimeField',_0x5e214c(0xec),_0x5e214c(0xf1),_0x5e214c(0x10f),_0x5e214c(0x112),_0x5e214c(0xee),_0x5e214c(0x11d),_0x5e214c(0xef)];for(const _0x1ebc95 of _0x370d2e){if(_0x4fbf1e[_0x1ebc95]!==undefined)_0x2fed65[_0x1ebc95]=_0x4fbf1e[_0x1ebc95];}return typeof _0x2fed65[_0x5e214c(0x11f)]===_0x5e214c(0xe0)&&_0x2fed65[_0x5e214c(0x11f)][_0x5e214c(0x11b)]>0x0&&(_0x2fed65[_0x5e214c(0xda)]=_0x2fed65[_0x5e214c(0x11f)][_0x5e214c(0x11c)](',')[_0x5e214c(0xf3)](_0x456eec=>_0x456eec[_0x5e214c(0x102)]())[_0x5e214c(0x10c)](Boolean)),_0x2fed65;}function a62_0x4038(){const _0x281b45=['dbName','toTableName','read','dbId','formatRules','relationId','deleted','code','2686385ArVlcC','trim','name','toFieldLabel','dbtableConfig','dbType','pkField','displayName','532SioTrN','350404DhXLZo','responseBody','filter','parse','dataset','creatorNameField','method','18885RZtdtO','modifierIdField','indexes','requestBody','toDatasetCode','detail','validateRules','required','isArray','beforeScriptId','length','split','labelField','28217AhiZuU','allFields','fromField','deprecated','1544TlfeQT','type','modelId','str','4909416pciexU','object','description','options','2937249BcxlNi','extend','tableName','allFieldNames','operations','doType','toDatasetName','sourceType','bizRelationType','string','properties','afterScriptId','host','requestFields','fields','columnCodeListWithDeleted','logicField','modelCode','path','doVersion','datasetKey','updateTimeField','source','modifierNameField','dblinkInfoDTO','901701dcXgao','creatorIdField','responseFields','map','50EQezny','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','push','tableComment','entries'];a62_0x4038=function(){return _0x281b45;};return a62_0x4038();}function normalizeRelatedPages(_0x4d9e8a){const _0x523493=a62_0x1ea2;if(!Array[_0x523493(0x119)](_0x4d9e8a))return[];return _0x4d9e8a[_0x523493(0x10c)](_0x2073fc=>_0x2073fc&&typeof _0x2073fc===_0x523493(0xd4))[_0x523493(0xf3)](_0x77ceec=>({'id':_0x77ceec['id'],'type':_0x77ceec['type'],'code':_0x77ceec[_0x523493(0x100)],'title':_0x77ceec['title'],'deleted':_0x77ceec['deleted']===!![]}));}function a62_0x1ea2(_0x4ea985,_0x1cee7b){_0x4ea985=_0x4ea985-0xd4;const _0x403836=a62_0x4038();let _0x1ea208=_0x403836[_0x4ea985];return _0x1ea208;}export const datasetDetail={'service':a62_0x1acca6(0x10e),'command':a62_0x1acca6(0x116),'description':'Get\x20dataset\x20detail\x20including\x20fields\x20and\x20operations','risk':a62_0x1acca6(0xfb),'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':'alias','type':a62_0x1acca6(0xe0),'description':a62_0x1acca6(0xf5)}],async 'execute'(_0x19a706){const _0x16e17b=a62_0x1acca6,_0x2d0e73=await getDatasetDetail(_0x19a706[_0x16e17b(0x125)](_0x16e17b(0x100))),_0x14a487=Array[_0x16e17b(0x119)](_0x2d0e73[_0x16e17b(0xe5)])?_0x2d0e73[_0x16e17b(0xe5)]:Array['isArray'](_0x2d0e73[_0x16e17b(0xe1)])?_0x2d0e73[_0x16e17b(0xe1)]:[],_0x4e13c0=_0x14a487[_0x16e17b(0xf3)](_0x321cc4=>normalizeField(_0x321cc4))[_0x16e17b(0x10c)](_0x5df0d3=>_0x5df0d3!==null),_0x2b332a=_0x2d0e73[_0x16e17b(0xdb)]??{},_0x36bc52=[];for(const [_0x16a8e6,_0x932758]of Object[_0x16e17b(0xf8)](_0x2b332a)){const _0x521523=normalizeOperationEntry(_0x16a8e6,_0x932758);if(_0x521523)_0x36bc52[_0x16e17b(0xf6)](_0x521523);}const _0x32394f=_0x2d0e73[_0x16e17b(0x105)]??{},_0x3ffccc=_0x2d0e73[_0x16e17b(0x10e)]??{},_0x4a91cb=_0x32394f['dbId']!=null?{'id':_0x32394f[_0x16e17b(0xfc)],'name':_0x32394f[_0x16e17b(0xf9)]??null}:undefined;let _0x1e9a38;return typeof _0x2d0e73[_0x16e17b(0xd8)]===_0x16e17b(0xe0)&&(_0x1e9a38=parseJsonMaybe(_0x2d0e73[_0x16e17b(0xd8)])),{'ok':!![],'data':{'id':_0x2d0e73[_0x16e17b(0x124)]??_0x2d0e73['id'],'name':_0x2d0e73[_0x16e17b(0x103)],'code':_0x2d0e73[_0x16e17b(0xe8)]||_0x2d0e73[_0x16e17b(0x100)],'doVersion':_0x2d0e73[_0x16e17b(0xea)],'description':_0x2d0e73[_0x16e17b(0xd5)]||_0x3ffccc[_0x16e17b(0xf7)]||undefined,'source':_0x2d0e73[_0x16e17b(0xed)]||_0x3ffccc[_0x16e17b(0xde)],'table':_0x32394f['tableName']||_0x3ffccc[_0x16e17b(0xd9)],'datasetKey':_0x32394f['datasetKey'],'pk':_0x32394f[_0x16e17b(0x107)],'db':_0x4a91cb,'dbtable':summarizeDbtable(_0x32394f),'fields':_0x4e13c0,'operations':_0x36bc52,'indexes':Array[_0x16e17b(0x119)](_0x3ffccc[_0x16e17b(0x113)])?_0x3ffccc[_0x16e17b(0x113)]:[],'relations':Array['isArray'](_0x2d0e73['relations'])?_0x2d0e73['relations'][_0x16e17b(0xf3)](_0x470fb6=>({..._0x470fb6[_0x16e17b(0xfe)]!=null?{'relationId':_0x470fb6[_0x16e17b(0xfe)]}:{},'fromDataset':_0x2d0e73[_0x16e17b(0x103)],'fromCode':_0x2d0e73['modelCode']||_0x2d0e73[_0x16e17b(0x100)],'fromTable':_0x32394f[_0x16e17b(0xd9)]||_0x3ffccc[_0x16e17b(0xd9)],'fromField':_0x470fb6[_0x16e17b(0x120)],'toDataset':_0x470fb6[_0x16e17b(0xdd)],'toCode':_0x470fb6[_0x16e17b(0x115)],'toTable':_0x470fb6[_0x16e17b(0xfa)],'toField':_0x470fb6['toField'],'labelField':_0x470fb6[_0x16e17b(0x104)]||undefined,'cardinality':_0x470fb6['cardinality']||undefined,'bizRelationType':_0x470fb6[_0x16e17b(0xdf)]==='main_sub'?'main_sub':null})):[],'relatedPages':normalizeRelatedPages(_0x2d0e73['relatedPageInfoList']),...Array[_0x16e17b(0x119)](_0x2d0e73[_0x16e17b(0xe6)])?{'columnCodeListWithDeleted':_0x2d0e73['columnCodeListWithDeleted']}:{},'formatRules':Array['isArray'](_0x2d0e73[_0x16e17b(0xfd)])?_0x2d0e73[_0x16e17b(0xfd)]:[],'validateRules':Array['isArray'](_0x2d0e73[_0x16e17b(0x117)])?_0x2d0e73[_0x16e17b(0x117)]:[],..._0x1e9a38!==undefined?{'extend':_0x1e9a38}:{},'stats':{'fieldCount':_0x4e13c0[_0x16e17b(0x11b)],'operationCount':_0x36bc52[_0x16e17b(0x11b)]}}};}};
|