@lovrabet/rabetbase-cli 2.4.4 → 2.4.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/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/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.d.ts +1 -0
- 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/get.js +1 -1
- package/lib/commands/config/index.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/data/filter.js +1 -1
- package/lib/commands/data/getOne.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/data/shared.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/{permit/index.d.ts → dataset/business-groups.d.ts} +1 -1
- package/lib/commands/dataset/business-groups.js +1 -0
- 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-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/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.d.ts +15 -1
- package/lib/commands/db/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/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/init/index.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/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/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/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/react/create.js +1 -1
- package/lib/commands/page/react/detail.js +1 -1
- package/lib/commands/page/react/list.js +1 -1
- package/lib/commands/page/react/publish.js +1 -1
- package/lib/commands/page/react/shared.js +1 -1
- package/lib/commands/page/react/syntax.js +1 -1
- package/lib/commands/page/react/template.js +1 -1
- package/lib/commands/page/react/update.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/standard-page-status.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/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.d.ts +15 -17
- 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/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/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/risk.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 +70 -79
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.d.ts +1 -0
- 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/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/types.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.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.js +1 -1
- package/lib/utils/rules-cdn.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 +1 -1
- package/skills/rabetbase/SKILL.md +18 -24
- package/skills/rabetbase/guides/database-connection-workflow.md +6 -2
- package/skills/rabetbase/references/rabetbase-dataset-business-groups.md +28 -0
- package/skills/rabetbase/references/rabetbase-dataset-delete.md +7 -5
- package/skills/rabetbase/references/rabetbase-dataset-list.md +6 -6
- package/skills/rabetbase/references/rabetbase-dataset-restore.md +5 -5
- package/skills/rabetbase/references/rabetbase-db-create.md +3 -0
- package/skills/rabetbase/references/rabetbase-db-delete.md +10 -2
- package/skills/rabetbase/references/rabetbase-db-detail.md +2 -0
- package/skills/rabetbase/references/rabetbase-db-list.md +3 -2
- package/skills/rabetbase/references/rabetbase-db-update.md +4 -2
- package/skills/rabetbase/references/rabetbase-role-list.md +9 -17
- package/skills/rabetbase/references/rabetbase-role-user-add.md +44 -16
- package/skills/rabetbase/references/rabetbase-role-user-resolve.md +2 -2
- package/skills/rabetbase.manifest.json +4 -7
- package/lib/commands/permit/index.js +0 -1
- package/lib/commands/permit/page-get.d.ts +0 -2
- package/lib/commands/permit/page-get.js +0 -1
- package/lib/commands/permit/page-set.d.ts +0 -2
- package/lib/commands/permit/page-set.js +0 -1
- package/lib/commands/permit/role-apis-set.d.ts +0 -2
- package/lib/commands/permit/role-apis-set.js +0 -1
- package/lib/commands/permit/role-menus-set.d.ts +0 -2
- package/lib/commands/permit/role-menus-set.js +0 -1
- package/lib/commands/permit/role-menus.d.ts +0 -2
- package/lib/commands/permit/role-menus.js +0 -1
- package/lib/commands/permit/shared.d.ts +0 -74
- package/lib/commands/permit/shared.js +0 -1
- package/lib/commands/role/create.d.ts +0 -2
- package/lib/commands/role/create.js +0 -1
- package/skills/rabetbase/guides/role-permit-workflow.md +0 -127
- package/skills/rabetbase/references/rabetbase-permit-page-set.md +0 -69
- package/skills/rabetbase/references/rabetbase-permit-role-apis-set.md +0 -53
- package/skills/rabetbase/references/rabetbase-permit-role-menus-set.md +0 -57
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a49_0x46c0(){const _0x35d8be=['App\x20Code\x20cannot\x20be\x20empty','trim','6138711rOQzbp','278YXZQoa','3381890tJnwFx','48ZyGOzX','433488KYMzqd','3280872mPVzcs','App\x20Code\x20cannot\x20exceed\x20100\x20characters','2553hIWFwF','143073mbJaAD','10OhQVNd','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','test','913281DdKDSb'];a49_0x46c0=function(){return _0x35d8be;};return a49_0x46c0();}(function(_0x12dd5d,_0x35ec82){const _0x571093=a49_0x5f11,_0x123c7f=_0x12dd5d();while(!![]){try{const _0x1a6c29=-parseInt(_0x571093(0x1ac))/0x1*(parseInt(_0x571093(0x1b5))/0x2)+-parseInt(_0x571093(0x1b1))/0x3+parseInt(_0x571093(0x1b8))/0x4+parseInt(_0x571093(0x1b6))/0x5+-parseInt(_0x571093(0x1aa))/0x6+-parseInt(_0x571093(0x1ad))/0x7*(-parseInt(_0x571093(0x1b7))/0x8)+parseInt(_0x571093(0x1b4))/0x9*(parseInt(_0x571093(0x1ae))/0xa);if(_0x1a6c29===_0x35ec82)break;else _0x123c7f['push'](_0x123c7f['shift']());}catch(_0x18000c){_0x123c7f['push'](_0x123c7f['shift']());}}}(a49_0x46c0,0x5d97d));function a49_0x5f11(_0x38911c,_0x161824){_0x38911c=_0x38911c-0x1aa;const _0x46c0ef=a49_0x46c0();let _0x5f11e5=_0x46c0ef[_0x38911c];return _0x5f11e5;}export function validateAppcode(_0x51a76d){const _0x45a896=a49_0x5f11,_0xc47f73=_0x51a76d[_0x45a896(0x1b3)]();if(!_0xc47f73)return{'valid':![],'message':_0x45a896(0x1b2)};if(_0xc47f73['length']>0x64)return{'valid':![],'message':_0x45a896(0x1ab)};if(!/^[A-Za-z0-9_-]+$/[_0x45a896(0x1b0)](_0xc47f73))return{'valid':![],'message':_0x45a896(0x1af)};return{'valid':!![]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a50_0x1d04eb=a50_0x30b4;(function(_0x492ac8,_0x2605c4){const _0x5ee244=a50_0x30b4,_0x1a3ccb=_0x492ac8();while(!![]){try{const _0x4c90e4=parseInt(_0x5ee244(0x6d))/0x1+-parseInt(_0x5ee244(0x74))/0x2*(parseInt(_0x5ee244(0x83))/0x3)+-parseInt(_0x5ee244(0x76))/0x4+-parseInt(_0x5ee244(0x6e))/0x5*(-parseInt(_0x5ee244(0x79))/0x6)+parseInt(_0x5ee244(0x6f))/0x7*(-parseInt(_0x5ee244(0x77))/0x8)+-parseInt(_0x5ee244(0x7a))/0x9*(-parseInt(_0x5ee244(0x80))/0xa)+parseInt(_0x5ee244(0x82))/0xb;if(_0x4c90e4===_0x2605c4)break;else _0x1a3ccb['push'](_0x1a3ccb['shift']());}catch(_0x36e90c){_0x1a3ccb['push'](_0x1a3ccb['shift']());}}}(a50_0x160f,0x6a44c));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(_0x48d80c){const _0xbd0c38=a50_0x30b4,_0x40580a=_0x48d80c[_0xbd0c38(0x7d)](_0xbd0c38(0x7b));if(!_0x40580a)throw CliErrors[_0xbd0c38(0x72)]('Missing\x20key.','Usage:\x20'+CLI_BIN_NAME+_0xbd0c38(0x7e));const _0x5397b9=readConfig(),_0x35564f=_0x40580a===_0xbd0c38(0x78)?_0xbd0c38(0x73):_0x40580a,_0x5cc015=_0x5397b9[_0x35564f];if(_0x5cc015===undefined)throw CliErrors[_0xbd0c38(0x72)](_0xbd0c38(0x71)+_0x40580a);return{'ok':!![],'data':typeof _0x5cc015===_0xbd0c38(0x75)?_0x5cc015:{[_0x35564f]:_0x5cc015},'message':typeof _0x5cc015==='object'?undefined:String(_0x5cc015)};}export const configGetDefinition={'service':a50_0x1d04eb(0x7f),'command':a50_0x1d04eb(0x7c),'description':a50_0x1d04eb(0x70),'risk':a50_0x1d04eb(0x81),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':'string','description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};function a50_0x30b4(_0x45b9e0,_0x1eb99b){_0x45b9e0=_0x45b9e0-0x6d;const _0x160faf=a50_0x160f();let _0x30b4eb=_0x160faf[_0x45b9e0];return _0x30b4eb;}function a50_0x160f(){const _0x3215bc=['appcode','376Cfoxkc','object','1795356ONYnIW','8xtAfwm','app','899982OsffiP','57879yqZlNB','key','get','str','\x20config\x20get\x20--key\x20<key>','config','170lkFfIa','read','11510213eGTiMj','7611JZlada','105211eoJinX','20GnxgIY','3498866tfysYM','Get\x20a\x20config\x20value\x20by\x20key','Key\x20not\x20found:\x20','validation'];a50_0x160f=function(){return _0x3215bc;};return a50_0x160f();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1863d2,_0x302f38){const _0x3b4c6f=a51_0x5ea3,_0x4692d4=_0x1863d2();while(!![]){try{const _0x895035=-parseInt(_0x3b4c6f(0x196))/0x1+-parseInt(_0x3b4c6f(0x197))/0x2*(parseInt(_0x3b4c6f(0x19b))/0x3)+parseInt(_0x3b4c6f(0x19d))/0x4+-parseInt(_0x3b4c6f(0x198))/0x5*(parseInt(_0x3b4c6f(0x19c))/0x6)+-parseInt(_0x3b4c6f(0x19e))/0x7+-parseInt(_0x3b4c6f(0x19f))/0x8*(parseInt(_0x3b4c6f(0x199))/0x9)+parseInt(_0x3b4c6f(0x19a))/0xa;if(_0x895035===_0x302f38)break;else _0x4692d4['push'](_0x4692d4['shift']());}catch(_0x23f147){_0x4692d4['push'](_0x4692d4['shift']());}}}(a51_0x5bd2,0xa8190));function a51_0x5bd2(){const _0x4f7f4c=['26908670bGFPJr','18309hJhDXy','76134VZtrIT','4882100Wfgath','5168611TDrmTJ','6192536aNzNQT','147704nNwsyX','404GzdIHe','130IvokAV','9MBdACS'];a51_0x5bd2=function(){return _0x4f7f4c;};return a51_0x5bd2();}import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';import{configSetDefinition}from'../../commands/config/set.js';function a51_0x5ea3(_0x13ac2c,_0x3bf3af){_0x13ac2c=_0x13ac2c-0x196;const _0x5bd2f2=a51_0x5bd2();let _0x5ea30c=_0x5bd2f2[_0x13ac2c];return _0x5ea30c;}export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a52_0x318950=a52_0x4525;(function(_0x2f3fa6,_0x1847f8){const _0x5318ad=a52_0x4525,_0x38a1ac=_0x2f3fa6();while(!![]){try{const _0xcc6f1=parseInt(_0x5318ad(0x1ae))/0x1+-parseInt(_0x5318ad(0x1b2))/0x2+parseInt(_0x5318ad(0x1b3))/0x3+-parseInt(_0x5318ad(0x1b6))/0x4*(parseInt(_0x5318ad(0x1ac))/0x5)+parseInt(_0x5318ad(0x1b4))/0x6+-parseInt(_0x5318ad(0x1b5))/0x7*(-parseInt(_0x5318ad(0x1b0))/0x8)+-parseInt(_0x5318ad(0x1a8))/0x9;if(_0xcc6f1===_0x1847f8)break;else _0x38a1ac['push'](_0x38a1ac['shift']());}catch(_0x5abf89){_0x38a1ac['push'](_0x38a1ac['shift']());}}}(a52_0x59c6,0x9a4fb));import{readScopedConfig}from'../../commands/config/shared.js';import{readConfig}from'../../utils/config.js';function a52_0x4525(_0x37fc9b,_0x4c7713){_0x37fc9b=_0x37fc9b-0x1a8;const _0x59c616=a52_0x59c6();let _0x45250d=_0x59c616[_0x37fc9b];return _0x45250d;}async function execute(_0x23b48c){const _0x5f1188=a52_0x4525,_0x288f24=_0x23b48c[_0x5f1188(0x1b1)](_0x5f1188(0x1af))?readScopedConfig(_0x5f1188(0x1af)):readConfig();return{'ok':!![],'data':_0x288f24};}function a52_0x59c6(){const _0x2740cf=['140560yGCWDj','bool','2408100wUiqGj','887277UfGuoV','5421162TymUrs','343HfXlwf','628QJRrUj','3773421psrbQP','read','config','boolean','6485CvtXNZ','List\x20all\x20config\x20values','398791WFZzJo','global'];a52_0x59c6=function(){return _0x2740cf;};return a52_0x59c6();}export const configListDefinition={'service':a52_0x318950(0x1aa),'command':'list','description':a52_0x318950(0x1ad),'risk':a52_0x318950(0x1a9),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a52_0x318950(0x1af),'type':a52_0x318950(0x1ab),'description':'Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','default':![]}],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a53_0x5d5e(){const _0x1cf952=['Invalid\x20locale\x20value.','\x20workspace\x20add\x20<name>\x20--appcode\x20','keys','join','includes','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','`,\x20`','Usage:\x20','set','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','key','length','object','Top-level\x20key\x20\x22','Settable\x20top-level\x20keys:\x20','\x20workspace\x20use\x20--app\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.','Missing\x20key.','Use\x20`','config','appcode','boolean','1264644uhaNtz','16OXcGyg','\x22.\x20Allowed:\x20','2285536jFUETq','Global','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','bool','app','Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.','6720553EBZlIM','global','3974058FxTumQ','6SioZSR','str','\x20appcode\x20set\x20to:\x20','3594kkMPQp','Project','8813880QAnqiC','apps','string','locale','Config\x20value','Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.','validation','Config\x20value\x20is\x20invalid\x20or\x20too\x20long.','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','Invalid\x20value\x20for\x20\x22','73OJXmUv','Missing\x20value.','816685hHETju','env'];a53_0x5d5e=function(){return _0x1cf952;};return a53_0x5d5e();}const a53_0x6ff83e=a53_0x3bb1;(function(_0x1a1042,_0x414e72){const _0x5a039a=a53_0x3bb1,_0x52207a=_0x1a1042();while(!![]){try{const _0x57b009=parseInt(_0x5a039a(0x1b2))/0x1*(-parseInt(_0x5a039a(0x1a6))/0x2)+parseInt(_0x5a039a(0x196))/0x3+-parseInt(_0x5a039a(0x199))/0x4+parseInt(_0x5a039a(0x1b4))/0x5*(-parseInt(_0x5a039a(0x1a3))/0x6)+parseInt(_0x5a039a(0x1a0))/0x7+parseInt(_0x5a039a(0x197))/0x8*(-parseInt(_0x5a039a(0x1a2))/0x9)+parseInt(_0x5a039a(0x1a8))/0xa;if(_0x57b009===_0x414e72)break;else _0x52207a['push'](_0x52207a['shift']());}catch(_0x46848b){_0x52207a['push'](_0x52207a['shift']());}}}(a53_0x5d5e,0x7d7c5));import{CliErrors}from'../../errors.js';function a53_0x3bb1(_0x1953ba,_0x565f8f){_0x1953ba=_0x1953ba-0x190;const _0x5d5e9b=a53_0x5d5e();let _0x3bb1ee=_0x5d5e9b[_0x1953ba];return _0x3bb1ee;}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';async function execute(_0x592708){const _0x42f1df=a53_0x3bb1,_0x4879aa=_0x592708['str'](_0x42f1df(0x1c0)),_0x4fadf3=_0x592708[_0x42f1df(0x1a4)]('value');if(!_0x4879aa)throw CliErrors['validation'](_0x42f1df(0x191),_0x42f1df(0x1bd)+CLI_BIN_NAME+_0x42f1df(0x1bb));if(_0x4fadf3===undefined||_0x4fadf3==='')throw CliErrors[_0x42f1df(0x1ae)](_0x42f1df(0x1b3),_0x42f1df(0x1bd)+CLI_BIN_NAME+_0x42f1df(0x1bb));if(_0x4fadf3['length']>0x1f4)throw CliErrors['validation'](_0x42f1df(0x1af));if(!isTopLevelConfigKey(_0x4879aa))throw CliErrors[_0x42f1df(0x1ae)](_0x42f1df(0x1c3)+_0x4879aa+'\x22\x20is\x20not\x20settable.',_0x42f1df(0x1c4)+getTopLevelConfigKeySummary());if(_0x4879aa==='riskLevel')throw CliErrors['validation'](_0x42f1df(0x1bf));if(CONFIG_ENUM_VALUES[_0x4879aa]&&!CONFIG_ENUM_VALUES[_0x4879aa][_0x42f1df(0x1ba)](_0x4fadf3))throw CliErrors[_0x42f1df(0x1ae)](_0x42f1df(0x1b1)+_0x4879aa+_0x42f1df(0x198)+CONFIG_ENUM_VALUES[_0x4879aa][_0x42f1df(0x1b9)](',\x20'));if(_0x4879aa===_0x42f1df(0x1ab)&&!normalizeLocale(_0x4fadf3))throw CliErrors[_0x42f1df(0x1ae)](_0x42f1df(0x1b6),'Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US');const _0x538626={'global':_0x592708[_0x42f1df(0x19c)]('global')},_0x58dcf4=resolveWriteScope(_0x538626),_0x154d9d=readScopedConfig(_0x58dcf4);let _0x66294e=_0x4879aa,_0x588d93=_0x4fadf3;_0x4879aa===_0x42f1df(0x19d)&&(_0x66294e=_0x42f1df(0x194),delete _0x154d9d[_0x42f1df(0x19d)]);_0x4879aa===_0x42f1df(0x1ab)&&(_0x588d93=normalizeLocale(_0x4fadf3));if(_0x4879aa===_0x42f1df(0x1b5)){_0x588d93=normalizeEnv(_0x4fadf3);if(!isProduction(_0x588d93)&&!isDaily(_0x588d93))throw CliErrors[_0x42f1df(0x1ae)](_0x42f1df(0x19b),_0x42f1df(0x1ad));}if(_0x4879aa===_0x42f1df(0x194)){const _0x316007=_0x154d9d['apps']&&typeof _0x154d9d[_0x42f1df(0x1a9)]===_0x42f1df(0x1c2)?Object[_0x42f1df(0x1b8)](_0x154d9d[_0x42f1df(0x1a9)]):[];if(_0x316007[_0x42f1df(0x1c1)]>0x0)throw CliErrors['validation'](_0x42f1df(0x19f),_0x42f1df(0x192)+CLI_BIN_NAME+_0x42f1df(0x1b7)+_0x588d93+_0x42f1df(0x1bc)+CLI_BIN_NAME+_0x42f1df(0x190));const _0x36c9e1=buildCanonicalProjectConfig({..._0x154d9d},{'appCodes':[_0x588d93],'env':typeof _0x154d9d[_0x42f1df(0x1b5)]===_0x42f1df(0x1aa)?_0x154d9d['env']:undefined});writeScopedConfig(_0x36c9e1,_0x58dcf4);const _0x196b5a=_0x58dcf4===_0x42f1df(0x1a1)?_0x42f1df(0x19a):_0x42f1df(0x1a7);return{'ok':!![],'message':'✓\x20'+_0x196b5a+_0x42f1df(0x1a5)+_0x588d93+_0x42f1df(0x1b0)};}_0x154d9d[_0x66294e]=_0x588d93,writeScopedConfig(_0x154d9d,_0x58dcf4);const _0x371986=_0x58dcf4===_0x42f1df(0x1a1)?_0x42f1df(0x19a):_0x42f1df(0x1a7);return{'ok':!![],'message':'✓\x20'+_0x371986+'\x20'+_0x66294e+'\x20set\x20to:\x20'+_0x588d93};}export const configSetDefinition={'service':a53_0x6ff83e(0x193),'command':a53_0x6ff83e(0x1be),'description':'Set\x20a\x20config\x20value','risk':'write','requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a53_0x6ff83e(0x1c0),'type':a53_0x6ff83e(0x1aa),'description':getConfigCommandKeyDescription(),'required':!![]},{'name':'value','type':a53_0x6ff83e(0x1aa),'description':a53_0x6ff83e(0x1ac),'required':!![]},{'name':a53_0x6ff83e(0x1a1),'type':a53_0x6ff83e(0x195),'description':a53_0x6ff83e(0x19e),'default':![]}],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2e48d8,_0x1ddb15){var _0x44e25d=a54_0x4817,_0x4cbffd=_0x2e48d8();while(!![]){try{var _0x8e47c8=parseInt(_0x44e25d(0x12e))/0x1*(parseInt(_0x44e25d(0x12f))/0x2)+parseInt(_0x44e25d(0x13e))/0x3*(-parseInt(_0x44e25d(0x13a))/0x4)+parseInt(_0x44e25d(0x139))/0x5*(-parseInt(_0x44e25d(0x12d))/0x6)+parseInt(_0x44e25d(0x131))/0x7*(-parseInt(_0x44e25d(0x130))/0x8)+-parseInt(_0x44e25d(0x13b))/0x9+-parseInt(_0x44e25d(0x134))/0xa*(-parseInt(_0x44e25d(0x136))/0xb)+parseInt(_0x44e25d(0x137))/0xc*(parseInt(_0x44e25d(0x138))/0xd);if(_0x8e47c8===_0x1ddb15)break;else _0x4cbffd['push'](_0x4cbffd['shift']());}catch(_0x58c62f){_0x4cbffd['push'](_0x4cbffd['shift']());}}}(a54_0x5194,0x4e559));import{CLI_BIN_NAME}from'../../constant/cli.js';import{isInProject,resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../../context.js';import{CliErrors}from'../../errors.js';function a54_0x5194(){var _0xd2ea99=['150Yfayyi','1oukKAo','728254LlUjxo','8EujXWu','786933PNgTiX','global','Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','20tBDULv','\x20init`\x20first.','1461845VxiKPz','10862364DmnOci','13TBiSdB','42745tDljkE','78308kmVjvi','4821543UdgUdf','Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).','validation','54WkPOcl','project'];a54_0x5194=function(){return _0xd2ea99;};return a54_0x5194();}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(_0x2bc1ef){var _0x2b3fe6=a54_0x4817;if(_0x2bc1ef['global'])return _0x2b3fe6(0x132);if(!isInProject())throw CliErrors[_0x2b3fe6(0x13d)](_0x2b3fe6(0x13c),_0x2b3fe6(0x133)+CLI_BIN_NAME+_0x2b3fe6(0x135));return _0x2b3fe6(0x13f);}export function readScopedConfig(_0x4c8e56){return readConfigFile(resolveWriteConfigPath(_0x4c8e56));}function a54_0x4817(_0x2e237a,_0x373d7b){_0x2e237a=_0x2e237a-0x12d;var _0x519429=a54_0x5194();var _0x48171a=_0x519429[_0x2e237a];return _0x48171a;}export function writeScopedConfig(_0x27426a,_0x481af2){writeConfigFile(resolveWriteConfigPath(_0x481af2),_0x27426a);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a55_0x111e87=a55_0x5ec2;function a55_0x5ec2(_0x2167ab,_0x3cb2ed){_0x2167ab=_0x2167ab-0x169;const _0x190a72=a55_0x190a();let _0x5ec2d1=_0x190a72[_0x2167ab];return _0x5ec2d1;}(function(_0x9b92e4,_0x516c83){const _0xcaaaa5=a55_0x5ec2,_0x9b30ac=_0x9b92e4();while(!![]){try{const _0x15b296=parseInt(_0xcaaaa5(0x170))/0x1*(-parseInt(_0xcaaaa5(0x174))/0x2)+parseInt(_0xcaaaa5(0x169))/0x3+parseInt(_0xcaaaa5(0x171))/0x4*(-parseInt(_0xcaaaa5(0x178))/0x5)+parseInt(_0xcaaaa5(0x172))/0x6*(-parseInt(_0xcaaaa5(0x17b))/0x7)+-parseInt(_0xcaaaa5(0x16c))/0x8+parseInt(_0xcaaaa5(0x176))/0x9*(-parseInt(_0xcaaaa5(0x16f))/0xa)+-parseInt(_0xcaaaa5(0x16b))/0xb*(-parseInt(_0xcaaaa5(0x173))/0xc);if(_0x15b296===_0x516c83)break;else _0x9b30ac['push'](_0x9b30ac['shift']());}catch(_0x4019cb){_0x9b30ac['push'](_0x9b30ac['shift']());}}}(a55_0x190a,0xac7c0));function a55_0x190a(){const _0x1b5e93=['54DVoSlT','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','1996025geAfPg','\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','28OODxRv','86412qSwhoB','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','22FSbKph','5759032AFiltB','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page','filter','2288560RLpmNa','168cYnRtF','12JmpdHr','525048mQynzg','26330460Zdhrva','834pAQqSB','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]'];a55_0x190a=function(){return _0x1b5e93;};return a55_0x190a();}import{buildDataCommand}from'../../commands/data/shared.js';export const dataFilter=buildDataCommand({'command':a55_0x111e87(0x16e),'operation':'filter','description':'Filter\x20dataset\x20records\x20with\x20query\x20conditions','paramsRequired':![],'paramsHint':a55_0x111e87(0x177),'helpExtra':[a55_0x111e87(0x17a),a55_0x111e87(0x16a),a55_0x111e87(0x175),'\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]',a55_0x111e87(0x179),a55_0x111e87(0x16d)]['join']('\x0a')});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a56_0x186b13=a56_0x393d;(function(_0x47caa3,_0x1176e8){const _0x113506=a56_0x393d,_0x2a48c8=_0x47caa3();while(!![]){try{const _0x3f66d2=parseInt(_0x113506(0x87))/0x1+-parseInt(_0x113506(0x8e))/0x2*(parseInt(_0x113506(0x8c))/0x3)+parseInt(_0x113506(0x84))/0x4+-parseInt(_0x113506(0x8f))/0x5*(-parseInt(_0x113506(0x8b))/0x6)+-parseInt(_0x113506(0x88))/0x7+-parseInt(_0x113506(0x89))/0x8*(parseInt(_0x113506(0x83))/0x9)+-parseInt(_0x113506(0x85))/0xa*(-parseInt(_0x113506(0x8d))/0xb);if(_0x3f66d2===_0x1176e8)break;else _0x2a48c8['push'](_0x2a48c8['shift']());}catch(_0x20a071){_0x2a48c8['push'](_0x2a48c8['shift']());}}}(a56_0x5776,0xdc7c0));import{buildDataCommand}from'../../commands/data/shared.js';export const dataGetOne=buildDataCommand({'command':a56_0x186b13(0x8a),'operation':a56_0x186b13(0x8a),'description':a56_0x186b13(0x86),'paramsRequired':!![],'paramsHint':a56_0x186b13(0x82)});function a56_0x393d(_0x2bcb21,_0x2ff3fd){_0x2bcb21=_0x2bcb21-0x82;const _0x57761e=a56_0x5776();let _0x393d61=_0x57761e[_0x2bcb21];return _0x393d61;}function a56_0x5776(){const _0x48db98=['110VBYjjZ','Get\x20a\x20single\x20record\x20by\x20ID','1301870cXGNas','1549632sWslRc','504SOeeMw','getOne','6kxNpkQ','3975WeEPRi','334444HHAKbF','1690qCjnOs','2206485ZbBWzj','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','90702gxWZWX','3205632MASagp'];a56_0x5776=function(){return _0x48db98;};return a56_0x5776();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x51f619,_0x59d41b){const _0x29fe1c=a57_0x35e7,_0x26ed31=_0x51f619();while(!![]){try{const _0x42dbd8=-parseInt(_0x29fe1c(0x1bc))/0x1*(-parseInt(_0x29fe1c(0x1b9))/0x2)+parseInt(_0x29fe1c(0x1b5))/0x3*(parseInt(_0x29fe1c(0x1b8))/0x4)+-parseInt(_0x29fe1c(0x1b6))/0x5+-parseInt(_0x29fe1c(0x1be))/0x6*(-parseInt(_0x29fe1c(0x1bb))/0x7)+-parseInt(_0x29fe1c(0x1ba))/0x8*(parseInt(_0x29fe1c(0x1bd))/0x9)+-parseInt(_0x29fe1c(0x1b7))/0xa+parseInt(_0x29fe1c(0x1b4))/0xb;if(_0x42dbd8===_0x59d41b)break;else _0x26ed31['push'](_0x26ed31['shift']());}catch(_0x1d1f81){_0x26ed31['push'](_0x26ed31['shift']());}}}(a57_0x1a99,0xc147b));function a57_0x1a99(){const _0x9c1e7a=['6750950ehsUtm','11195130SIavnw','116ehsUjO','8ijApsX','5584SDBAcR','5767167rkUhWJ','311247uaQeKd','20151zauMgL','6mcQQWv','23165593povLWv','67176vcsKZV'];a57_0x1a99=function(){return _0x9c1e7a;};return a57_0x1a99();}import{dataFilter}from'../../commands/data/filter.js';function a57_0x35e7(_0x1a0962,_0x4f0346){_0x1a0962=_0x1a0962-0x1b4;const _0x1a99ee=a57_0x1a99();let _0x35e7b9=_0x1a99ee[_0x1a0962];return _0x35e7b9;}import{dataGetOne}from'../../commands/data/getOne.js';export const dataDefinitions=[dataFilter,dataGetOne];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a58_0x5816(_0x58f753,_0x197ce8){_0x58f753=_0x58f753-0x160;const _0x5ecc89=a58_0x5ecc();let _0x581602=_0x5ecc89[_0x58f753];return _0x581602;}(function(_0x59e2d9,_0x2edb6d){const _0x210bcf=a58_0x5816,_0x12ab04=_0x59e2d9();while(!![]){try{const _0x459a0d=-parseInt(_0x210bcf(0x160))/0x1*(parseInt(_0x210bcf(0x174))/0x2)+parseInt(_0x210bcf(0x165))/0x3*(-parseInt(_0x210bcf(0x16d))/0x4)+-parseInt(_0x210bcf(0x16e))/0x5+-parseInt(_0x210bcf(0x171))/0x6*(parseInt(_0x210bcf(0x161))/0x7)+-parseInt(_0x210bcf(0x177))/0x8+-parseInt(_0x210bcf(0x163))/0x9+parseInt(_0x210bcf(0x175))/0xa;if(_0x459a0d===_0x2edb6d)break;else _0x12ab04['push'](_0x12ab04['shift']());}catch(_0x5f50fa){_0x12ab04['push'](_0x12ab04['shift']());}}}(a58_0x5ecc,0x1b396));import{executeDatasetDataOperation}from'../../core/api-client.js';function a58_0x5ecc(){const _0xd19aea=['239988UzJjmH','code','351954oDJwBI','appCode','6xPvQox','\x20completed\x20in\x20','data','str','Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.','flagMissing','alias','paramsHint','35428dkNTNy','524875docWNx','command','read','24zkAZNG','now','compress','178122qugApt','5946910GAfZFn','helpExtra','761512EseekG','params','operation','string','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','1FBfgBj'];a58_0x5ecc=function(){return _0xd19aea;};return a58_0x5ecc();}import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{parseJsonParams}from'../../utils/params.js';function assertGetOneId(_0x50d27d){const _0x4f48e4=a58_0x5816;if(!_0x50d27d)throw CliErrors[_0x4f48e4(0x16a)]('params',_0x4f48e4(0x169));const _0x304cd7=_0x50d27d['id'];if(_0x304cd7===undefined||_0x304cd7===null||_0x304cd7==='')throw CliErrors['validation']('data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params',_0x4f48e4(0x17b));}function parseCommandParams(_0x24c9eb){return parseJsonParams(_0x24c9eb)??{};}export function buildDataCommand(_0x47059a){const _0x1f6e80=a58_0x5816,_0x38da24='Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically';return{'service':_0x1f6e80(0x167),'command':_0x47059a[_0x1f6e80(0x16f)],'description':_0x47059a['description'],'risk':_0x1f6e80(0x170),'defaultOutputFormat':_0x1f6e80(0x173),'helpExtra':_0x47059a[_0x1f6e80(0x176)],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0x1f6e80(0x16b),'type':_0x1f6e80(0x17a),'description':_0x38da24},{'name':_0x1f6e80(0x178),'type':_0x1f6e80(0x17a),'description':_0x47059a[_0x1f6e80(0x16c)]}],async 'validate'(_0x45f154){const _0x47d4aa=_0x1f6e80,_0x54b1b9=_0x45f154[_0x47d4aa(0x168)](_0x47d4aa(0x178));if(_0x47059a['paramsRequired']&&!_0x54b1b9)throw CliErrors['flagMissing'](_0x47d4aa(0x178),_0x47059a[_0x47d4aa(0x16c)]);const _0x490177=parseJsonParams(_0x54b1b9);_0x47059a[_0x47d4aa(0x179)]==='getOne'&&assertGetOneId(_0x490177);},async 'execute'(_0x137bed){const _0x57fea7=_0x1f6e80,_0x559f2b=parseCommandParams(_0x137bed[_0x57fea7(0x168)]('params')),_0x325a01=Date['now'](),_0x1b205f=await executeDatasetDataOperation(_0x137bed[_0x57fea7(0x164)],_0x137bed[_0x57fea7(0x168)](_0x57fea7(0x162)),_0x47059a['operation'],_0x559f2b),_0x34f61a=Date[_0x57fea7(0x172)]()-_0x325a01;return{'ok':!![],'data':{'result':_0x1b205f,'elapsed':_0x34f61a},'message':'data\x20'+_0x47059a['command']+_0x57fea7(0x166)+_0x34f61a+'ms'};}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a59_0x573762=a59_0x51e6;(function(_0x1e4adb,_0x3166c8){const _0x2ce986=a59_0x51e6,_0xbb917c=_0x1e4adb();while(!![]){try{const _0x33044f=parseInt(_0x2ce986(0x183))/0x1*(-parseInt(_0x2ce986(0x19b))/0x2)+parseInt(_0x2ce986(0x189))/0x3+-parseInt(_0x2ce986(0x193))/0x4*(-parseInt(_0x2ce986(0x1a8))/0x5)+parseInt(_0x2ce986(0x1a0))/0x6+parseInt(_0x2ce986(0x19a))/0x7*(parseInt(_0x2ce986(0x17d))/0x8)+parseInt(_0x2ce986(0x191))/0x9*(parseInt(_0x2ce986(0x19c))/0xa)+parseInt(_0x2ce986(0x198))/0xb*(-parseInt(_0x2ce986(0x195))/0xc);if(_0x33044f===_0x3166c8)break;else _0xbb917c['push'](_0xbb917c['shift']());}catch(_0x554fa9){_0xbb917c['push'](_0xbb917c['shift']());}}}(a59_0x1520,0x3897f));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateErBusinessGroup}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const BACKEND_PATH=a59_0x573762(0x1a1);export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x13ad91,input:_0x52e7f4,dryRun:_0x4cfdec}){const _0x2c4e96=a59_0x573762;validateInput(_0x52e7f4);const _0x58711e=normalizeBusinessGroup(_0x52e7f4[_0x2c4e96(0x178)]),_0x781a41=await getDatasetDetail(_0x52e7f4[_0x2c4e96(0x187)]),_0x49ff75=resolveBusinessGroupDataset(_0x781a41,_0x52e7f4[_0x2c4e96(0x187)]),_0x13d53a=loadCurrentBusinessGroup(_0x781a41,_0x49ff75);assertExpectedBusinessGroup(_0x13d53a,_0x52e7f4[_0x2c4e96(0x17e)]);const _0x44f754=buildBackendPayload(_0x13ad91,_0x49ff75,_0x58711e),_0x5519d9=_0x13d53a!==_0x58711e;let _0x5ccb48;if(_0x5519d9&&!_0x4cfdec){await updateErBusinessGroup(_0x44f754);const _0x295214=await getDatasetDetail(_0x49ff75[_0x2c4e96(0x187)]),_0x263e90=resolveBusinessGroupDataset(_0x295214,_0x49ff75[_0x2c4e96(0x187)]),_0x3e319f=loadCurrentBusinessGroup(_0x295214,_0x263e90);if(_0x3e319f!==_0x58711e)throw CliErrors[_0x2c4e96(0x1aa)](_0x2c4e96(0x17c),_0x2c4e96(0x185)+JSON[_0x2c4e96(0x1b5)](_0x58711e)+_0x2c4e96(0x18c)+JSON['stringify'](_0x3e319f)+'.');_0x5ccb48={'verified':!![],'status':_0x2c4e96(0x1b6),'afterReadback':{'businessGroup':_0x3e319f}};}else!_0x5519d9&&(_0x5ccb48={'verified':!![],'status':_0x2c4e96(0x1b0),'afterReadback':{'businessGroup':_0x13d53a}});const _0x5b7397={'operation':_0x2c4e96(0x194),'appCode':_0x13ad91,'selector':{'code':_0x49ff75[_0x2c4e96(0x187)]},'dataset':_0x49ff75,'before':{'businessGroup':_0x13d53a},'after':{'businessGroup':_0x58711e},'changed':_0x5519d9,'dryRun':_0x4cfdec,'submitted':_0x5519d9&&!_0x4cfdec,'backend':{'method':'POST','path':BACKEND_PATH,'payload':_0x44f754},..._0x5ccb48?{'verification':_0x5ccb48}:{},'warnings':[]};return{'ok':!![],'data':_0x5b7397,'message':_0x5519d9?_0x4cfdec?_0x2c4e96(0x1ac)+_0x49ff75[_0x2c4e96(0x187)]:_0x2c4e96(0x18b)+_0x49ff75[_0x2c4e96(0x187)]:'No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20'+_0x49ff75[_0x2c4e96(0x187)]};}export const datasetBusinessGroupUpdate={'service':a59_0x573762(0x177),'command':a59_0x573762(0x1a7),'description':'Update\x20business\x20scenario\x20group','risk':a59_0x573762(0x192),'flags':[CODE_FLAG,{'name':'business-group','type':a59_0x573762(0x1b8),'required':!![],'description':a59_0x573762(0x1a3)},{'name':a59_0x573762(0x199),'type':a59_0x573762(0x1b8),'required':![],'description':a59_0x573762(0x1a9)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x562ff0){validateInput(readBusinessGroupUpdateInput(_0x562ff0));},async 'dryRun'(_0x11f3d6){const _0x1dcba6=a59_0x573762,_0x27394b=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x11f3d6[_0x1dcba6(0x1b7)],'input':readBusinessGroupUpdateInput(_0x11f3d6),'dryRun':!![]});return{'method':'POST','url':BACKEND_PATH,'body':_0x27394b[_0x1dcba6(0x1b4)][_0x1dcba6(0x180)]['payload'],'description':_0x27394b['message'],..._0x27394b[_0x1dcba6(0x1b4)]};},async 'execute'(_0x3209ba){return buildDatasetBusinessGroupUpdateResult({'appCode':_0x3209ba['appCode'],'input':readBusinessGroupUpdateInput(_0x3209ba),'dryRun':![]});}};function readBusinessGroupUpdateInput(_0x1efd5e){const _0x13be2c=a59_0x573762,_0x89f73a=_0x1efd5e[_0x13be2c(0x1ab)](_0x13be2c(0x199));return{'code':trim(_0x1efd5e['str'](_0x13be2c(0x187))),'businessGroup':_0x1efd5e[_0x13be2c(0x1ab)](_0x13be2c(0x17a)),'expectBusinessGroup':_0x89f73a===undefined||_0x89f73a===''?undefined:_0x89f73a};}function validateInput(_0x40384a){const _0x2c613a=a59_0x573762;if(!trim(_0x40384a[_0x2c613a(0x187)]))throw CliErrors[_0x2c613a(0x190)](_0x2c613a(0x19e));if(_0x40384a[_0x2c613a(0x178)]===undefined)throw CliErrors[_0x2c613a(0x190)](_0x2c613a(0x17f));}function resolveBusinessGroupDataset(_0xc0668a,_0x316150){const _0x5f0096=a59_0x573762,_0x59a517=asPlainObject(_0xc0668a[_0x5f0096(0x177)]),_0x487ea0=asPlainObject(_0xc0668a[_0x5f0096(0x1ae)]),_0x278b4a=resolveSourceType(_0xc0668a,_0x59a517,_0x487ea0),_0x5b701f=firstString(_0xc0668a[_0x5f0096(0x17b)],_0xc0668a['code'],_0x59a517['datasetCode'],_0x316150)||_0x316150;return{'id':firstNumber(_0xc0668a[_0x5f0096(0x19d)],_0xc0668a['id'],_0x59a517['datasetId'])??firstString(_0xc0668a[_0x5f0096(0x19d)],_0xc0668a['id'],_0x59a517[_0x5f0096(0x1b3)])??null,'code':_0x5b701f,'name':firstString(_0xc0668a['name'],_0x59a517[_0x5f0096(0x1b1)],_0x59a517[_0x5f0096(0x197)])||null,'sourceType':_0x278b4a};}function resolveSourceType(_0x4d4d4c,_0x2dcc4c,_0xc81496){const _0x1abfea=a59_0x573762,_0x1b6069=firstString(_0x4d4d4c['source'],_0x4d4d4c[_0x1abfea(0x188)],_0x2dcc4c[_0x1abfea(0x18d)],_0x2dcc4c[_0x1abfea(0x188)])?.[_0x1abfea(0x18a)]()[_0x1abfea(0x196)]();if(_0x1b6069===_0x1abfea(0x1b2)||_0x1b6069===_0x1abfea(0x1af))return _0x1b6069;if(Object['keys'](_0xc81496)[_0x1abfea(0x1a5)]>0x0)return _0x1abfea(0x1b2);throw CliErrors[_0x1abfea(0x190)](_0x1abfea(0x18f));}function loadCurrentBusinessGroup(_0xd40356,_0x59907f){const _0x1acfbc=a59_0x573762,_0x1e721b=readBusinessGroupFromDatasetDetail(_0xd40356,_0x59907f['sourceType']);if(_0x1e721b['found'])return normalizeBusinessGroup(_0x1e721b[_0x1acfbc(0x1b9)]);if(_0x59907f['sourceType']===_0x1acfbc(0x1af))return'';throw CliErrors['validation'](_0x1acfbc(0x19f),_0x1acfbc(0x184));}function readBusinessGroupFromDatasetDetail(_0x34b7f5,_0x40f9d2){const _0x26306f=a59_0x573762,_0x312e0c=asPlainObject(_0x34b7f5[_0x26306f(0x177)]),_0x521366=firstPresent(_0x34b7f5[_0x26306f(0x178)]);if(_0x521366[_0x26306f(0x1a6)])return _0x521366;const _0x3e281e=firstPresent(_0x312e0c[_0x26306f(0x178)]);if(_0x3e281e[_0x26306f(0x1a6)])return _0x3e281e;if(_0x40f9d2===_0x26306f(0x1b2))return{'found':![]};const _0x2cedf0=readBusinessGroupFromExtend(_0x34b7f5[_0x26306f(0x182)]);if(_0x2cedf0[_0x26306f(0x1a6)])return _0x2cedf0;return readBusinessGroupFromExtend(_0x312e0c[_0x26306f(0x182)]);}function readBusinessGroupFromExtend(_0x2a0eb8){const _0x5f3505=a59_0x573762;if(_0x2a0eb8===undefined||_0x2a0eb8===null||_0x2a0eb8==='')return{'found':![]};if(typeof _0x2a0eb8==='string')try{const _0x5d97e6=JSON[_0x5f3505(0x1a4)](_0x2a0eb8);return readBusinessGroupFromExtend(_0x5d97e6);}catch{return{'found':![]};}const _0x1f5149=asPlainObject(_0x2a0eb8);if(Object[_0x5f3505(0x18e)][_0x5f3505(0x1a2)]['call'](_0x1f5149,_0x5f3505(0x178)))return{'found':!![],'value':_0x1f5149['businessGroup']};return{'found':![]};}function firstPresent(..._0x390277){for(const _0x2ab294 of _0x390277){if(_0x2ab294!==undefined&&_0x2ab294!==null)return{'found':!![],'value':_0x2ab294};}return{'found':![]};}function a59_0x51e6(_0x517def,_0x12aece){_0x517def=_0x517def-0x177;const _0x152010=a59_0x1520();let _0x51e6a7=_0x152010[_0x517def];return _0x51e6a7;}function assertExpectedBusinessGroup(_0x510371,_0x4a2fe8){const _0x458db5=a59_0x573762;if(_0x4a2fe8===undefined)return;const _0x3babda=normalizeBusinessGroup(_0x4a2fe8);if(_0x510371!==_0x3babda)throw CliErrors[_0x458db5(0x190)](_0x458db5(0x181),_0x458db5(0x185)+JSON[_0x458db5(0x1b5)](_0x3babda)+_0x458db5(0x18c)+JSON[_0x458db5(0x1b5)](_0x510371));}function buildBackendPayload(_0xbc4da2,_0x3d05e9,_0x1931c2){return{'appCode':_0xbc4da2,'datasetCode':_0x3d05e9['code'],'businessGroup':_0x1931c2};}function normalizeBusinessGroup(_0x2eb097){const _0xb3f69d=a59_0x573762;if(_0x2eb097===undefined||_0x2eb097===null)return'';return String(_0x2eb097)[_0xb3f69d(0x18a)]();}function a59_0x1520(){const _0x5c041d=['name','22jSHQpa','expect-business-group','14PVqwxp','522iSYPSJ','10qxUGkq','modelId','--code\x20is\x20required','Dataset\x20detail\x20does\x20not\x20expose\x20businessGroup.','1532664gWXjgJ','/smartapi/question/er-config/business-group/edit','hasOwnProperty','Business\x20scenario\x20group\x20(not\x20technical):\x20use\x20<scenario>,\x20or\x20<domain>---<scenario>\x20when\x20needed\x20for\x20disambiguation\x20or\x20an\x20existing\x20hierarchy;\x20empty\x20string\x20clears\x20it','parse','length','found','business-group-update','3155sIqXHX','Expected\x20current\x20business\x20scenario\x20group;\x20mismatch\x20aborts\x20without\x20writing','apiError','str','Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20','isArray','dbtableConfig','METADATA','unchanged','datasetName','DB_TABLE','datasetId','data','stringify','matched','appCode','string','value','dataset','businessGroup','number','business-group','modelCode','Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.','1348912XrJijW','expectBusinessGroup','--business-group\x20is\x20required','backend','Expectation\x20mismatch\x20at\x20businessGroup','extend','374BPNgaX','Business\x20scenario\x20group\x20readback\x20must\x20be\x20available\x20by\x20datasetCode;\x20upgrade\x20the\x20backend\x20read\x20contract\x20instead\x20of\x20using\x20dblinkId/tableName.','Expected\x20','object','code','sourceType','32745ArHCKP','trim','Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20',',\x20actual\x20','source','prototype','Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.','validation','108855HXZQCK','write','2572VXFuJD','update','4151964peujRg','toUpperCase'];a59_0x1520=function(){return _0x5c041d;};return a59_0x1520();}function asPlainObject(_0x44e1a6){const _0x1bd6dc=a59_0x573762;if(!_0x44e1a6||typeof _0x44e1a6!==_0x1bd6dc(0x186)||Array[_0x1bd6dc(0x1ad)](_0x44e1a6))return{};return _0x44e1a6;}function firstString(..._0x1e632d){const _0x5bcb36=a59_0x573762;for(const _0x20f21a of _0x1e632d){if(typeof _0x20f21a==='string'&&_0x20f21a['trim']())return _0x20f21a[_0x5bcb36(0x18a)]();if(typeof _0x20f21a==='number'&&Number['isFinite'](_0x20f21a))return String(_0x20f21a);}return undefined;}function firstNumber(..._0x45efa4){const _0x47b882=a59_0x573762;for(const _0x3d9689 of _0x45efa4){if(typeof _0x3d9689===_0x47b882(0x179)&&Number['isFinite'](_0x3d9689))return _0x3d9689;if(typeof _0x3d9689===_0x47b882(0x1b8)&&_0x3d9689[_0x47b882(0x18a)]()&&Number['isFinite'](Number(_0x3d9689)))return Number(_0x3d9689);}return null;}function trim(_0x512892){const _0x51ad70=a59_0x573762;return String(_0x512892||'')[_0x51ad70(0x18a)]();}
|
|
1
|
+
const a59_0x39643a=a59_0x1fd8;(function(_0x17b023,_0x342f66){const _0x295936=a59_0x1fd8,_0x2d67d0=_0x17b023();while(!![]){try{const _0x54ccb7=-parseInt(_0x295936(0x14b))/0x1+parseInt(_0x295936(0x15f))/0x2+parseInt(_0x295936(0x165))/0x3*(parseInt(_0x295936(0x13e))/0x4)+parseInt(_0x295936(0x143))/0x5*(parseInt(_0x295936(0x14d))/0x6)+parseInt(_0x295936(0x13c))/0x7*(parseInt(_0x295936(0x173))/0x8)+parseInt(_0x295936(0x159))/0x9+-parseInt(_0x295936(0x15e))/0xa;if(_0x54ccb7===_0x342f66)break;else _0x2d67d0['push'](_0x2d67d0['shift']());}catch(_0x379802){_0x2d67d0['push'](_0x2d67d0['shift']());}}}(a59_0x170e,0x3172f));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateErBusinessGroup}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const BACKEND_PATH=a59_0x39643a(0x13b);function a59_0x170e(){const _0x536039=['name','source','trim','expect-business-group','business-group','string','Expected\x20','toUpperCase','write','3295836wsObAg','payload','found','backend','code','8789280YXzJIR','409674yzvopx','stringify','prototype','call','--code\x20is\x20required','expectBusinessGroup','9LsRWdQ',',\x20actual\x20','length','extend','keys','apiError','DB_TABLE','businessGroup','value','data','Business\x20scenario\x20group\x20readback\x20must\x20be\x20available\x20by\x20datasetCode;\x20upgrade\x20the\x20backend\x20read\x20contract\x20instead\x20of\x20using\x20dblinkId/tableName.','unchanged','Expectation\x20mismatch\x20at\x20businessGroup','hasOwnProperty','16bHlQUO','Update\x20business\x20scenario\x20group','dataset','str','message','validation','isArray','object','number','dbtableConfig','/smartapi/question/er-config/business-group/edit','1113063JUinEA','No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20','530164UaGKXL','POST','appCode','datasetName','Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.','4885MXsrSO','isFinite','sourceType','datasetId','update','datasetCode','METADATA','Dataset\x20detail\x20does\x20not\x20expose\x20businessGroup.','384979FpKVCx','Expected\x20current\x20business\x20scenario\x20group;\x20mismatch\x20aborts\x20without\x20writing','1104lgxWfz','--business-group\x20is\x20required','parse'];a59_0x170e=function(){return _0x536039;};return a59_0x170e();}export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x467c79,input:_0x40f3f9,dryRun:_0x14b242}){const _0x59ada7=a59_0x39643a;validateInput(_0x40f3f9);const _0x5cb50c=normalizeBusinessGroup(_0x40f3f9[_0x59ada7(0x16c)]),_0x2cbee1=await getDatasetDetail(_0x40f3f9[_0x59ada7(0x15d)]),_0x407c4a=resolveBusinessGroupDataset(_0x2cbee1,_0x40f3f9['code']),_0x125bbc=loadCurrentBusinessGroup(_0x2cbee1,_0x407c4a);assertExpectedBusinessGroup(_0x125bbc,_0x40f3f9[_0x59ada7(0x164)]);const _0x5b49c8=buildBackendPayload(_0x467c79,_0x407c4a,_0x5cb50c),_0x9e4770=_0x125bbc!==_0x5cb50c;let _0x1e1180;if(_0x9e4770&&!_0x14b242){await updateErBusinessGroup(_0x5b49c8);const _0x401c2a=await getDatasetDetail(_0x407c4a['code']),_0x5c9f3e=resolveBusinessGroupDataset(_0x401c2a,_0x407c4a[_0x59ada7(0x15d)]),_0x12fb88=loadCurrentBusinessGroup(_0x401c2a,_0x5c9f3e);if(_0x12fb88!==_0x5cb50c)throw CliErrors[_0x59ada7(0x16a)](_0x59ada7(0x142),_0x59ada7(0x156)+JSON[_0x59ada7(0x160)](_0x5cb50c)+',\x20actual\x20'+JSON[_0x59ada7(0x160)](_0x12fb88)+'.');_0x1e1180={'verified':!![],'status':'matched','afterReadback':{'businessGroup':_0x12fb88}};}else!_0x9e4770&&(_0x1e1180={'verified':!![],'status':_0x59ada7(0x170),'afterReadback':{'businessGroup':_0x125bbc}});const _0x1b06c2={'operation':_0x59ada7(0x147),'appCode':_0x467c79,'selector':{'code':_0x407c4a[_0x59ada7(0x15d)]},'dataset':_0x407c4a,'before':{'businessGroup':_0x125bbc},'after':{'businessGroup':_0x5cb50c},'changed':_0x9e4770,'dryRun':_0x14b242,'submitted':_0x9e4770&&!_0x14b242,'backend':{'method':_0x59ada7(0x13f),'path':BACKEND_PATH,'payload':_0x5b49c8},..._0x1e1180?{'verification':_0x1e1180}:{},'warnings':[]};return{'ok':!![],'data':_0x1b06c2,'message':_0x9e4770?_0x14b242?'Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20'+_0x407c4a[_0x59ada7(0x15d)]:'Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20'+_0x407c4a[_0x59ada7(0x15d)]:_0x59ada7(0x13d)+_0x407c4a[_0x59ada7(0x15d)]};}export const datasetBusinessGroupUpdate={'service':a59_0x39643a(0x175),'command':'business-group-update','description':a59_0x39643a(0x174),'risk':a59_0x39643a(0x158),'flags':[CODE_FLAG,{'name':a59_0x39643a(0x154),'type':'string','required':!![],'description':'Business\x20scenario\x20group\x20(not\x20technical):\x20use\x20<scenario>,\x20or\x20<domain>---<scenario>\x20when\x20needed\x20for\x20disambiguation\x20or\x20an\x20existing\x20hierarchy;\x20empty\x20string\x20clears\x20it'},{'name':a59_0x39643a(0x153),'type':a59_0x39643a(0x155),'required':![],'description':a59_0x39643a(0x14c)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x530732){validateInput(readBusinessGroupUpdateInput(_0x530732));},async 'dryRun'(_0x2f5b7d){const _0x378825=a59_0x39643a,_0x5b0756=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x2f5b7d[_0x378825(0x140)],'input':readBusinessGroupUpdateInput(_0x2f5b7d),'dryRun':!![]});return{'method':_0x378825(0x13f),'url':BACKEND_PATH,'body':_0x5b0756[_0x378825(0x16e)][_0x378825(0x15c)][_0x378825(0x15a)],'description':_0x5b0756[_0x378825(0x135)],..._0x5b0756[_0x378825(0x16e)]};},async 'execute'(_0xa7ff1d){const _0x2e5b3f=a59_0x39643a;return buildDatasetBusinessGroupUpdateResult({'appCode':_0xa7ff1d[_0x2e5b3f(0x140)],'input':readBusinessGroupUpdateInput(_0xa7ff1d),'dryRun':![]});}};function a59_0x1fd8(_0x509daf,_0x4552cd){_0x509daf=_0x509daf-0x134;const _0x170e54=a59_0x170e();let _0x1fd8a1=_0x170e54[_0x509daf];return _0x1fd8a1;}function readBusinessGroupUpdateInput(_0x2320ff){const _0x15efdc=a59_0x39643a,_0x460eab=_0x2320ff[_0x15efdc(0x134)]('expect-business-group');return{'code':trim(_0x2320ff[_0x15efdc(0x134)](_0x15efdc(0x15d))),'businessGroup':_0x2320ff[_0x15efdc(0x134)](_0x15efdc(0x154)),'expectBusinessGroup':_0x460eab===undefined||_0x460eab===''?undefined:_0x460eab};}function validateInput(_0x59999b){const _0x3452e4=a59_0x39643a;if(!trim(_0x59999b[_0x3452e4(0x15d)]))throw CliErrors['validation'](_0x3452e4(0x163));if(_0x59999b[_0x3452e4(0x16c)]===undefined)throw CliErrors[_0x3452e4(0x136)](_0x3452e4(0x14e));}function resolveBusinessGroupDataset(_0x38b600,_0x2d9626){const _0x5bb7dd=a59_0x39643a,_0x1e2584=asPlainObject(_0x38b600['dataset']),_0x5bc57c=asPlainObject(_0x38b600[_0x5bb7dd(0x13a)]),_0x152b96=resolveSourceType(_0x38b600,_0x1e2584,_0x5bc57c),_0x3c1ae7=firstString(_0x38b600['modelCode'],_0x38b600['code'],_0x1e2584[_0x5bb7dd(0x148)],_0x2d9626)||_0x2d9626;return{'id':firstNumber(_0x38b600['modelId'],_0x38b600['id'],_0x1e2584[_0x5bb7dd(0x146)])??firstString(_0x38b600['modelId'],_0x38b600['id'],_0x1e2584[_0x5bb7dd(0x146)])??null,'code':_0x3c1ae7,'name':firstString(_0x38b600[_0x5bb7dd(0x150)],_0x1e2584[_0x5bb7dd(0x141)],_0x1e2584[_0x5bb7dd(0x150)])||null,'sourceType':_0x152b96};}function resolveSourceType(_0x35431c,_0x36d5af,_0x10eb44){const _0x303b59=a59_0x39643a,_0x30fb99=firstString(_0x35431c['source'],_0x35431c[_0x303b59(0x145)],_0x36d5af[_0x303b59(0x151)],_0x36d5af['sourceType'])?.[_0x303b59(0x152)]()[_0x303b59(0x157)]();if(_0x30fb99===_0x303b59(0x16b)||_0x30fb99===_0x303b59(0x149))return _0x30fb99;if(Object[_0x303b59(0x169)](_0x10eb44)[_0x303b59(0x167)]>0x0)return _0x303b59(0x16b);throw CliErrors[_0x303b59(0x136)]('Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.');}function loadCurrentBusinessGroup(_0x1049cb,_0xe1df94){const _0x49a2dd=a59_0x39643a,_0x48a3c0=readBusinessGroupFromDatasetDetail(_0x1049cb,_0xe1df94[_0x49a2dd(0x145)]);if(_0x48a3c0[_0x49a2dd(0x15b)])return normalizeBusinessGroup(_0x48a3c0[_0x49a2dd(0x16d)]);if(_0xe1df94['sourceType']==='METADATA')return'';throw CliErrors[_0x49a2dd(0x136)](_0x49a2dd(0x14a),_0x49a2dd(0x16f));}function readBusinessGroupFromDatasetDetail(_0x4fc9cc,_0x422f71){const _0xb4ef4e=a59_0x39643a,_0x30d867=asPlainObject(_0x4fc9cc[_0xb4ef4e(0x175)]),_0x4aff6f=firstPresent(_0x4fc9cc[_0xb4ef4e(0x16c)]);if(_0x4aff6f[_0xb4ef4e(0x15b)])return _0x4aff6f;const _0x28555d=firstPresent(_0x30d867[_0xb4ef4e(0x16c)]);if(_0x28555d[_0xb4ef4e(0x15b)])return _0x28555d;if(_0x422f71===_0xb4ef4e(0x16b))return{'found':![]};const _0x480651=readBusinessGroupFromExtend(_0x4fc9cc['extend']);if(_0x480651[_0xb4ef4e(0x15b)])return _0x480651;return readBusinessGroupFromExtend(_0x30d867[_0xb4ef4e(0x168)]);}function readBusinessGroupFromExtend(_0xf49f43){const _0x541e19=a59_0x39643a;if(_0xf49f43===undefined||_0xf49f43===null||_0xf49f43==='')return{'found':![]};if(typeof _0xf49f43===_0x541e19(0x155))try{const _0x52a3fa=JSON[_0x541e19(0x14f)](_0xf49f43);return readBusinessGroupFromExtend(_0x52a3fa);}catch{return{'found':![]};}const _0x1f727c=asPlainObject(_0xf49f43);if(Object[_0x541e19(0x161)][_0x541e19(0x172)][_0x541e19(0x162)](_0x1f727c,_0x541e19(0x16c)))return{'found':!![],'value':_0x1f727c[_0x541e19(0x16c)]};return{'found':![]};}function firstPresent(..._0x171824){for(const _0x1dfa23 of _0x171824){if(_0x1dfa23!==undefined&&_0x1dfa23!==null)return{'found':!![],'value':_0x1dfa23};}return{'found':![]};}function assertExpectedBusinessGroup(_0x521f1f,_0x4b79de){const _0x57b652=a59_0x39643a;if(_0x4b79de===undefined)return;const _0x435d66=normalizeBusinessGroup(_0x4b79de);if(_0x521f1f!==_0x435d66)throw CliErrors[_0x57b652(0x136)](_0x57b652(0x171),_0x57b652(0x156)+JSON[_0x57b652(0x160)](_0x435d66)+_0x57b652(0x166)+JSON[_0x57b652(0x160)](_0x521f1f));}function buildBackendPayload(_0x236edb,_0x4b6cb9,_0x356dfc){const _0x3df8c1=a59_0x39643a;return{'appCode':_0x236edb,'datasetCode':_0x4b6cb9[_0x3df8c1(0x15d)],'businessGroup':_0x356dfc};}function normalizeBusinessGroup(_0x2dc8b2){const _0x4e9108=a59_0x39643a;if(_0x2dc8b2===undefined||_0x2dc8b2===null)return'';return String(_0x2dc8b2)[_0x4e9108(0x152)]();}function asPlainObject(_0x1fefbd){const _0x2a3197=a59_0x39643a;if(!_0x1fefbd||typeof _0x1fefbd!==_0x2a3197(0x138)||Array[_0x2a3197(0x137)](_0x1fefbd))return{};return _0x1fefbd;}function firstString(..._0x3657ae){const _0x2aa45b=a59_0x39643a;for(const _0x54c988 of _0x3657ae){if(typeof _0x54c988===_0x2aa45b(0x155)&&_0x54c988[_0x2aa45b(0x152)]())return _0x54c988[_0x2aa45b(0x152)]();if(typeof _0x54c988===_0x2aa45b(0x139)&&Number[_0x2aa45b(0x144)](_0x54c988))return String(_0x54c988);}return undefined;}function firstNumber(..._0x2c0a60){const _0x4652e3=a59_0x39643a;for(const _0x1da574 of _0x2c0a60){if(typeof _0x1da574==='number'&&Number['isFinite'](_0x1da574))return _0x1da574;if(typeof _0x1da574===_0x4652e3(0x155)&&_0x1da574[_0x4652e3(0x152)]()&&Number[_0x4652e3(0x144)](Number(_0x1da574)))return Number(_0x1da574);}return null;}function trim(_0x22bd63){const _0xf7b664=a59_0x39643a;return String(_0x22bd63||'')[_0xf7b664(0x152)]();}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { CommandDefinition } from "../../framework/types.js";
|
|
2
|
-
export declare const
|
|
2
|
+
export declare const datasetBusinessGroups: CommandDefinition;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a60_0x54cbec=a60_0xda28;(function(_0x14804a,_0x53d1f6){const _0x3b3e2b=a60_0xda28,_0x3c6672=_0x14804a();while(!![]){try{const _0x19f9b5=parseInt(_0x3b3e2b(0x181))/0x1+-parseInt(_0x3b3e2b(0x185))/0x2*(-parseInt(_0x3b3e2b(0x184))/0x3)+parseInt(_0x3b3e2b(0x195))/0x4*(parseInt(_0x3b3e2b(0x18a))/0x5)+parseInt(_0x3b3e2b(0x18b))/0x6*(parseInt(_0x3b3e2b(0x193))/0x7)+parseInt(_0x3b3e2b(0x190))/0x8+parseInt(_0x3b3e2b(0x18f))/0x9+-parseInt(_0x3b3e2b(0x191))/0xa*(parseInt(_0x3b3e2b(0x183))/0xb);if(_0x19f9b5===_0x53d1f6)break;else _0x3c6672['push'](_0x3c6672['shift']());}catch(_0x4fda41){_0x3c6672['push'](_0x3c6672['shift']());}}}(a60_0x5199,0x7d382));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getErBusinessGroupSummary}from'../../core/api-client.js';export const datasetBusinessGroups={'service':a60_0x54cbec(0x192),'command':a60_0x54cbec(0x189),'description':a60_0x54cbec(0x182),'risk':a60_0x54cbec(0x18e),'flags':[{'name':a60_0x54cbec(0x194),'type':a60_0x54cbec(0x187),'required':!![],'description':a60_0x54cbec(0x186)},APPCODE_FLAG_OPTIONAL],async 'execute'(_0x4fe889){const _0x1e5077=a60_0x54cbec,_0x13c97d=_0x4fe889['num'](_0x1e5077(0x194)),_0x223b83=await getErBusinessGroupSummary(_0x4fe889[_0x1e5077(0x196)],_0x13c97d);return{'ok':!![],'data':{..._0x223b83,'scope':'DB_TABLE'},'message':_0x1e5077(0x18c)+_0x223b83[_0x1e5077(0x18d)]['length']+_0x1e5077(0x188)+_0x13c97d};}};function a60_0xda28(_0x2f494f,_0x4846ab){_0x2f494f=_0x2f494f-0x181;const _0x51995a=a60_0x5199();let _0xda281e=_0x51995a[_0x2f494f];return _0xda281e;}function a60_0x5199(){const _0x4ab9ba=['\x20business\x20group(s)\x20for\x20database\x20connection\x20','business-groups','621755OCwXnz','186hWwpID','Found\x20','groups','read','1003806CbeiFj','4139760zhQlRT','80WAGAzp','dataset','80171kzspkc','dbid','24hqLVeS','appCode','66959ETWris','List\x20DB_TABLE\x20dataset\x20business\x20groups\x20for\x20a\x20database\x20connection;\x20does\x20not\x20include\x20METADATA','2228512TpiSav','9HbjQgs','224348yWQxhj','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','number'];a60_0x5199=function(){return _0x4ab9ba;};return a60_0x5199();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a61_0x2f22b4=a61_0x4b21;(function(_0x57028b,_0xfe8bc0){const _0x54b4cb=a61_0x4b21,_0x39c243=_0x57028b();while(!![]){try{const _0x59fc42=-parseInt(_0x54b4cb(0x150))/0x1+-parseInt(_0x54b4cb(0x16d))/0x2*(-parseInt(_0x54b4cb(0x15c))/0x3)+parseInt(_0x54b4cb(0x170))/0x4*(-parseInt(_0x54b4cb(0x171))/0x5)+parseInt(_0x54b4cb(0x159))/0x6*(parseInt(_0x54b4cb(0x162))/0x7)+-parseInt(_0x54b4cb(0x174))/0x8+parseInt(_0x54b4cb(0x151))/0x9+-parseInt(_0x54b4cb(0x156))/0xa*(-parseInt(_0x54b4cb(0x155))/0xb);if(_0x59fc42===_0xfe8bc0)break;else _0x39c243['push'](_0x39c243['shift']());}catch(_0x1cfdb7){_0x39c243['push'](_0x39c243['shift']());}}}(a61_0x22b7,0x9cfa2));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':'lovrabet','filter':a61_0x2f22b4(0x154),'getOne':a61_0x2f22b4(0x15f)};export const RUNTIME_DATA_ACCESS_SUMMARY='Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.';function valueToString(_0x4f7cf5){return _0x4f7cf5==null?'':String(_0x4f7cf5)['trim']();}function getDatasetCode(_0x4b042d){const _0x288952=a61_0x2f22b4;return valueToString(_0x4b042d['code']??_0x4b042d['modelCode']??_0x4b042d[_0x288952(0x157)]?.['datasetCode']);}function a61_0x4b21(_0x11138d,_0x323c64){_0x11138d=_0x11138d-0x150;const _0x22b716=a61_0x22b7();let _0x4b2178=_0x22b716[_0x11138d];return _0x4b2178;}function getDatasetName(_0x1d12cc){const _0x101e9e=a61_0x2f22b4;return valueToString(_0x1d12cc[_0x101e9e(0x15b)]??_0x1d12cc[_0x101e9e(0x157)]?.[_0x101e9e(0x16f)])||_0x101e9e(0x15a);}function getDatasetSource(_0x1aa842){const _0x140a1e=a61_0x2f22b4;return valueToString(_0x1aa842[_0x140a1e(0x164)]??_0x1aa842[_0x140a1e(0x157)]?.[_0x140a1e(0x167)])[_0x140a1e(0x168)]();}function getDbtableConfig(_0x388021){const _0x71be18=a61_0x2f22b4,_0xe4cc65=_0x388021[_0x71be18(0x169)]??_0x388021[_0x71be18(0x152)];return _0xe4cc65&&typeof _0xe4cc65===_0x71be18(0x153)?_0xe4cc65:{};}export function isDbTableBackedDataset(_0x3defd1){const _0x15bd2d=a61_0x2f22b4,_0x13da50=getDatasetSource(_0x3defd1);if(_0x13da50===_0x15bd2d(0x165))return![];const _0x24e5de=getDbtableConfig(_0x3defd1),_0x147deb=_0x24e5de[_0x15bd2d(0x16a)]??_0x24e5de['id'],_0x4b0a5d=valueToString(_0x24e5de[_0x15bd2d(0x166)]??_0x3defd1['tableName']??_0x3defd1[_0x15bd2d(0x157)]?.[_0x15bd2d(0x166)]);return _0x147deb!==undefined&&_0x147deb!==null&&_0x4b0a5d[_0x15bd2d(0x15e)]>0x0;}export function filterDbTableBackedDatasets(_0x5de7aa){const _0x386c54=a61_0x2f22b4;return _0x5de7aa[_0x386c54(0x172)](_0x31f114=>isDbTableBackedDataset(_0x31f114));}export function buildDbTableBackedRequirementMessage(_0x375899,_0x196e8e=a61_0x2f22b4(0x161)){const _0x5819ec=a61_0x2f22b4,_0x156c21=getDatasetSource(_0x375899)||_0x5819ec(0x163),_0x2016cc=getDatasetName(_0x375899),_0x1e76c9=getDatasetCode(_0x375899),_0x491445=_0x1e76c9?'\x20('+_0x1e76c9+')':'';return['当前数据集\x20\x22'+_0x2016cc+'\x22'+_0x491445+'\x20是\x20'+_0x156c21+_0x5819ec(0x160)+_0x196e8e+_0x5819ec(0x158),_0x5819ec(0x16c),_0x5819ec(0x173),'如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:'+RUNTIME_DATA_ACCESS_COMMANDS['filter']+';'+RUNTIME_DATA_ACCESS_COMMANDS[_0x5819ec(0x16e)]+'。'][_0x5819ec(0x16b)]('\x20');}export function assertDatasetIsDbTableBacked(_0x2162d2,_0x1d6f62){const _0x320e85=a61_0x2f22b4;if(!isDbTableBackedDataset(_0x2162d2))throw CliErrors[_0x320e85(0x15d)](buildDbTableBackedRequirementMessage(_0x2162d2,_0x1d6f62));}function a61_0x22b7(){const _0x174519=['dbId','join','原因:schema\x20introspection\x20与\x20custom\x20SQL\x20需要\x20source=DB_TABLE、dbtableConfig.dbId、dbtableConfig.tableName\x20与数据库连接上下文。','47932QdVRXO','getOne','datasetName','4rKqVzQ','2898605PAprqp','filter','请先将该数据集升级/迁移为\x20DB_TABLE\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','6216160BfRITY','977961gbqSFj','8989461HqUKIQ','dbtable','object','lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','689216hQYmwH','100WCSSjh','dataset','\x20的\x20DB_TABLE\x20数据源上下文。','642GMNmcb','unknown','name','123dyNpPH','validation','length','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress','\x20类型,没有可用于\x20','SQL\x20schema\x20validation','24185thWNoA','UNKNOWN','source','METADATA','tableName','sourceType','toUpperCase','dbtableConfig'];a61_0x22b7=function(){return _0x174519;};return a61_0x22b7();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a62_0x2d5e(_0x4a155e,_0x485295){_0x4a155e=_0x4a155e-0xf3;const _0x5cfd12=a62_0x5cfd();let _0x2d5e53=_0x5cfd12[_0x4a155e];return _0x2d5e53;}const a62_0x10c87a=a62_0x2d5e;(function(_0x432bc1,_0x2d5684){const _0x7d0b4f=a62_0x2d5e,_0x164f4d=_0x432bc1();while(!![]){try{const _0x581315=parseInt(_0x7d0b4f(0x11a))/0x1+parseInt(_0x7d0b4f(0x10b))/0x2*(parseInt(_0x7d0b4f(0x11b))/0x3)+-parseInt(_0x7d0b4f(0x132))/0x4+parseInt(_0x7d0b4f(0x131))/0x5+parseInt(_0x7d0b4f(0x103))/0x6*(-parseInt(_0x7d0b4f(0xf9))/0x7)+parseInt(_0x7d0b4f(0x100))/0x8*(-parseInt(_0x7d0b4f(0x105))/0x9)+parseInt(_0x7d0b4f(0x12a))/0xa*(parseInt(_0x7d0b4f(0xf3))/0xb);if(_0x581315===_0x2d5684)break;else _0x164f4d['push'](_0x164f4d['shift']());}catch(_0x44da46){_0x164f4d['push'](_0x164f4d['shift']());}}}(a62_0x5cfd,0xbad9a));import{deleteDataset,getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a62_0x5cfd(){const _0x359b61=['object','filter','relatedPages','2632406BIREiu','type','dbid=','high-risk-write','dbId','description','Delete\x20all\x20datasets\x20under\x20this\x20database\x20connection\x20id','280mAdfBV','\x20failed','map','18IIMRrN','Dataset\x20id','137169umKrja','\x20dataset(s)\x20and\x20their\x20listed\x20related\x20pages/menus.\x20Restore\x20each\x20Dataset\x20first,\x20then\x20restore\x20pages\x20explicitly\x20when\x20needed.','source','Delete\x20dataset\x20metadata\x20by\x20id/code\x20or\x20all\x20datasets\x20under\x20a\x20db\x20id','bool','\x20dataset(s),\x20but\x20--expected-count\x20is\x20','230TPvxiQ','relatedPageInfoList','cascade','code','expected-count','delete','\x20dataset(s);\x20','validation','dbid','One\x20of\x20--id,\x20--code,\x20or\x20--dbid\x20is\x20required.','Also\x20delete\x20related\x20pages\x20and\x20menus;\x20requires\x20explicit\x20--confirm','Deleted\x20','isInteger','boolean','add','754086jokUif','9612vSjabo','message','dataset','length','true','\x20--appcode\x20','Run\x20with\x20--dry-run\x20first,\x20then\x20add\x20--confirm\x20when\x20the\x20target\x20list\x20is\x20correct.','title','confirm','str','isArray','push','number','\x20dataset(s)','num','30qGVhXa','Would\x20delete\x20','\x20dataset(s)\x20without\x20cascading\x20to\x20pages.\x20The\x20server\x20blocks\x20a\x20Dataset\x20that\x20still\x20has\x20related\x20pages.','/smartapi/dataset/delete?cascade=','appCode','dbName','name','1012220TPtnjy','3594948RWzknb','Abort\x20unless\x20the\x20matched\x20dataset\x20count\x20equals\x20this\x20value','7335878XqeBKB','rabetbase\x20page\x20restore\x20--id\x20','dbtableConfig'];a62_0x5cfd=function(){return _0x359b61;};return a62_0x5cfd();}import{APPCODE_FLAG_OPTIONAL,CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';const DATASET_ID_FLAG={'name':'id','type':a62_0x10c87a(0x127),'description':a62_0x10c87a(0x104)},DBID_FLAG={'name':a62_0x10c87a(0x113),'type':a62_0x10c87a(0x127),'description':a62_0x10c87a(0xff)},CONFIRM_FLAG={'name':a62_0x10c87a(0x123),'type':a62_0x10c87a(0x118),'description':'Required\x20to\x20execute\x20dataset\x20deletion'},CASCADE_FLAG={'name':'cascade','type':a62_0x10c87a(0x118),'description':a62_0x10c87a(0x115)},EXPECTED_COUNT_FLAG={'name':a62_0x10c87a(0x10f),'type':a62_0x10c87a(0x127),'description':a62_0x10c87a(0x133)};export const datasetDelete={'service':a62_0x10c87a(0x11d),'command':a62_0x10c87a(0x110),'description':a62_0x10c87a(0x108),'risk':a62_0x10c87a(0xfc),'flags':[DATASET_ID_FLAG,CODE_FLAG_OPTIONAL,DBID_FLAG,CASCADE_FLAG,CONFIRM_FLAG,EXPECTED_COUNT_FLAG,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x14d4e3){const _0x398987=a62_0x10c87a,_0xe4a71=_0x14d4e3[_0x398987(0x129)]('id'),_0x2ca016=_0x14d4e3[_0x398987(0x124)](_0x398987(0x10e)),_0x11f18b=_0x14d4e3[_0x398987(0x129)](_0x398987(0x113)),_0x570a28=[_0xe4a71>0x0,Boolean(_0x2ca016),_0x11f18b>0x0][_0x398987(0xf7)](Boolean);if(_0x570a28[_0x398987(0x11e)]===0x0)throw CliErrors[_0x398987(0x112)](_0x398987(0x114));if(_0x570a28[_0x398987(0x11e)]>0x1)throw CliErrors[_0x398987(0x112)]('Use\x20only\x20one\x20of\x20--id,\x20--code,\x20or\x20--dbid.');},async 'dryRun'(_0x46f48a){const _0x4f35ec=a62_0x10c87a,_0x4e6458=await resolveTargets(_0x46f48a),_0x49dc68=_0x46f48a[_0x4f35ec(0x109)](_0x4f35ec(0x10d));return{'method':'POST','url':_0x4f35ec(0x12d)+(_0x49dc68?_0x4f35ec(0x11f):'false'),'body':{'count':_0x4e6458[_0x4f35ec(0x11e)],'cascade':_0x49dc68,'datasets':_0x4e6458},'description':_0x49dc68?_0x4f35ec(0x12b)+_0x4e6458[_0x4f35ec(0x11e)]+_0x4f35ec(0x106):'Would\x20safely\x20delete\x20'+_0x4e6458[_0x4f35ec(0x11e)]+_0x4f35ec(0x12c)};},async 'execute'(_0xba64a3){const _0x14204c=a62_0x10c87a;if(!_0xba64a3[_0x14204c(0x109)](_0x14204c(0x123)))throw CliErrors['validation']('--confirm\x20is\x20required\x20to\x20delete\x20datasets.',_0x14204c(0x121));const _0x3044fc=await resolveTargets(_0xba64a3),_0x4b356e=_0xba64a3[_0x14204c(0x109)]('cascade'),_0x137089=[],_0x261348=[];for(const _0x5113d8 of _0x3044fc){try{await deleteDataset(_0x5113d8['id'],_0x4b356e),_0x137089['push'](_0x5113d8);}catch(_0x34b0ef){_0x261348[_0x14204c(0x126)]({..._0x5113d8,'error':_0x34b0ef instanceof Error?_0x34b0ef[_0x14204c(0x11c)]:String(_0x34b0ef)});}}if(_0x261348[_0x14204c(0x11e)]>0x0){const _0x3d3410=buildPageRestoreCommands(_0xba64a3['appCode'],_0x4b356e?_0x137089:[]);return{'ok':![],'data':{'requested':_0x3044fc[_0x14204c(0x11e)],'cascade':_0x4b356e,'deletedCount':_0x137089[_0x14204c(0x11e)],'failedCount':_0x261348[_0x14204c(0x11e)],'deleted':_0x137089,'failed':_0x261348,'pageRestoreCommands':_0x3d3410},'message':_0x14204c(0x116)+_0x137089[_0x14204c(0x11e)]+'/'+_0x3044fc[_0x14204c(0x11e)]+_0x14204c(0x111)+_0x261348[_0x14204c(0x11e)]+_0x14204c(0x101)};}return{'ok':!![],'data':{'requested':_0x3044fc[_0x14204c(0x11e)],'cascade':_0x4b356e,'deletedCount':_0x137089[_0x14204c(0x11e)],'deleted':_0x137089,'pageRestoreCommands':buildPageRestoreCommands(_0xba64a3[_0x14204c(0x12e)],_0x4b356e?_0x137089:[])},'message':_0x14204c(0x116)+_0x137089[_0x14204c(0x11e)]+_0x14204c(0x128)};}};async function resolveTargets(_0x10149f){const _0x5363b2=a62_0x10c87a,_0x18764f=_0x10149f[_0x5363b2(0x129)]('id'),_0x96c9a3=_0x10149f[_0x5363b2(0x124)](_0x5363b2(0x10e)),_0x1b5f96=_0x10149f[_0x5363b2(0x129)](_0x5363b2(0x113));let _0x5179ca;_0x96c9a3?(_0x5179ca=await listDatasets(_0x10149f[_0x5363b2(0x12e)],{'code':_0x96c9a3}),_0x5179ca=_0x5179ca[_0x5363b2(0xf7)](_0x10bca9=>_0x10bca9['code']===_0x96c9a3)):(_0x5179ca=await listDatasets(_0x10149f[_0x5363b2(0x12e)]),_0x18764f>0x0&&(_0x5179ca=_0x5179ca[_0x5363b2(0xf7)](_0x2f07f0=>_0x2f07f0['id']===_0x18764f)),_0x1b5f96>0x0&&(_0x5179ca=_0x5179ca[_0x5363b2(0xf7)](_0x1bd38b=>_0x1bd38b[_0x5363b2(0xf5)]?.[_0x5363b2(0xfd)]===_0x1b5f96)));const _0x7080e6=[];for(const _0x324335 of _0x5179ca){const _0x7d0f26=await getDatasetDetail(_0x324335[_0x5363b2(0x10e)]),_0x22d76d=Array[_0x5363b2(0x125)](_0x7d0f26[_0x5363b2(0x10c)])?_0x7d0f26[_0x5363b2(0x10c)][_0x5363b2(0xf7)](_0x204a7c=>_0x204a7c!=null&&typeof _0x204a7c===_0x5363b2(0xf6)&&_0x204a7c['deleted']!==!![]):[];_0x7080e6[_0x5363b2(0x126)](normalizeTarget(_0x324335,_0x22d76d));}if(_0x7080e6[_0x5363b2(0x11e)]===0x0){const _0x3edf02=_0x96c9a3||(_0x18764f>0x0?'id='+_0x18764f:_0x5363b2(0xfb)+_0x1b5f96);throw CliErrors[_0x5363b2(0x112)]('No\x20undeleted\x20dataset\x20found\x20for\x20'+_0x3edf02+'.');}const _0x13f90b=_0x10149f['num'](_0x5363b2(0x10f));if(_0x13f90b>0x0&&_0x7080e6[_0x5363b2(0x11e)]!==_0x13f90b)throw CliErrors[_0x5363b2(0x112)]('Matched\x20'+_0x7080e6[_0x5363b2(0x11e)]+_0x5363b2(0x10a)+_0x13f90b+'.');return _0x7080e6;}function normalizeTarget(_0x5d8b67,_0x151e25){const _0x569dbb=a62_0x10c87a,_0x14ee20=_0x5d8b67[_0x569dbb(0xf5)]??{},_0x4966fc=_0x151e25[_0x569dbb(0x102)](_0x285d19=>{const _0x4de5b0=_0x569dbb;if(_0x285d19==null||typeof _0x285d19!==_0x4de5b0(0xf6))return null;const _0x385d84=_0x285d19,_0x2edefa=Number(_0x385d84['id']);if(!Number[_0x4de5b0(0x117)](_0x2edefa)||_0x2edefa<=0x0)return null;const _0x5cb030=_0x385d84[_0x4de5b0(0x122)]??_0x385d84['name'];return{'id':_0x2edefa,..._0x5cb030?{'name':String(_0x5cb030)}:{},..._0x385d84[_0x4de5b0(0xfa)]?{'type':String(_0x385d84[_0x4de5b0(0xfa)])}:{}};})[_0x569dbb(0xf7)](_0x343673=>_0x343673!==null);return{'id':_0x5d8b67['id'],'code':_0x5d8b67[_0x569dbb(0x10e)],'name':_0x5d8b67[_0x569dbb(0x130)],'description':_0x5d8b67[_0x569dbb(0xfe)],'source':_0x5d8b67[_0x569dbb(0x107)],'dbId':_0x14ee20[_0x569dbb(0xfd)],'dbName':_0x14ee20[_0x569dbb(0x12f)],'tableName':_0x14ee20['tableName'],'relatedPageCount':_0x4966fc[_0x569dbb(0x11e)],'relatedPages':_0x4966fc};}function buildPageRestoreCommands(_0x2761ef,_0x2b8977){const _0x48ab01=a62_0x10c87a,_0x748140=new Set();for(const _0xda55e9 of _0x2b8977){for(const _0x402f8f of _0xda55e9[_0x48ab01(0xf8)])_0x748140[_0x48ab01(0x119)](_0x402f8f['id']);}return[..._0x748140][_0x48ab01(0x102)](_0x3cab5a=>_0x48ab01(0xf4)+_0x3cab5a+_0x48ab01(0x120)+_0x2761ef);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a63_0x19a0e1=a63_0x256d;function a63_0x484a(){const _0x259a34=['requestFields','tableComment','allFields','method','deprecated','split','columnCodeListWithDeleted','2463200OsGDKp','modelCode','relationId','labelField','updateTimeField','dbtableConfig','indexes','length','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','400656BJbniw','extend','toDatasetCode','options','bizRelationType','toField','relatedPageInfoList','doVersion','modifierNameField','trim','687252TvgmRp','deleted','displayName','datasetKey','dbName','allFieldNames','createTimeField','read','entries','host','responseFields','properties','str','validateRules','string','6MEmQGE','code','name','Get\x20dataset\x20detail\x20including\x20fields\x20and\x20operations','required','formatRules','fromField','detail','9UpfsyQ','doType','dblinkInfoDTO','creatorIdField','main_sub','path','type','845112dxETIb','dbId','dbType','requestBody','modelId','responseBody','afterScriptId','sourceType','dataset','operations','1812895TtVeSV','tableName','fields','description','map','toFieldLabel','filter','pkField','beforeScriptId','cardinality','2988630EFwGnE','creatorNameField','isArray','374240DaTkmX','parse','object','source','dataType','alias'];a63_0x484a=function(){return _0x259a34;};return a63_0x484a();}(function(_0x5746a9,_0x6f56b2){const _0x10338b=a63_0x256d,_0x19adbc=_0x5746a9();while(!![]){try{const _0xd32324=parseInt(_0x10338b(0x9f))/0x1+parseInt(_0x10338b(0xb5))/0x2+-parseInt(_0x10338b(0xd6))/0x3*(parseInt(_0x10338b(0xbf))/0x4)+-parseInt(_0x10338b(0xac))/0x5+-parseInt(_0x10338b(0xce))/0x6*(-parseInt(_0x10338b(0x92))/0x7)+parseInt(_0x10338b(0xdd))/0x8+parseInt(_0x10338b(0x9c))/0x9;if(_0xd32324===_0x6f56b2)break;else _0x19adbc['push'](_0x19adbc['shift']());}catch(_0x332ac7){_0x19adbc['push'](_0x19adbc['shift']());}}}(a63_0x484a,0x4040f));import{getDatasetDetail}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function normalizeField(_0x3d877e){const _0x196be7=a63_0x256d;if(_0x3d877e[_0x196be7(0xc0)])return null;const _0x419131=Boolean(_0x3d877e['displayName']!==undefined||_0x3d877e['doType']!==undefined);let _0x355b86={};if(!_0x419131&&typeof _0x3d877e['extend']===_0x196be7(0xcd))try{_0x355b86=JSON[_0x196be7(0xa0)](_0x3d877e[_0x196be7(0xb6)]);}catch{}const _0x2ae6f6=_0x419131?_0x3d877e[_0x196be7(0xd0)]:_0x3d877e[_0x196be7(0xcf)],_0x5820ae=_0x419131?_0x3d877e[_0x196be7(0xc1)]:_0x3d877e[_0x196be7(0xd0)],_0x1b0de7=_0x419131?_0x3d877e[_0x196be7(0xd7)]:_0x3d877e['type']||_0x3d877e[_0x196be7(0xa3)],_0x172a7a=_0x419131?_0x3d877e[_0x196be7(0x99)]===!![]:_0x355b86[_0x196be7(0x99)]===!![],_0x4d6d5e=_0x419131?_0x3d877e[_0x196be7(0xd2)]===!![]:_0x355b86['required']===!![],_0x59e02c=_0x419131?_0x3d877e[_0x196be7(0xb8)]??null:_0x355b86['options']??null,_0x3b14d1={'name':_0x2ae6f6,'displayName':_0x5820ae||_0x2ae6f6,'type':_0x1b0de7,'dbType':_0x3d877e[_0x196be7(0x8a)],'pk':_0x172a7a,'required':_0x4d6d5e,'deprecated':_0x3d877e[_0x196be7(0xa9)]===!![],'description':_0x3d877e[_0x196be7(0x95)]||undefined};return Array[_0x196be7(0x9e)](_0x59e02c)&&_0x59e02c[_0x196be7(0xb3)]>0x0&&(_0x3b14d1['options']=_0x59e02c),_0x3b14d1;}function parseJsonMaybe(_0x3946fd){const _0x4045ca=a63_0x256d;if(typeof _0x3946fd!==_0x4045ca(0xcd))return _0x3946fd;try{return JSON[_0x4045ca(0xa0)](_0x3946fd);}catch{return _0x3946fd;}}function a63_0x256d(_0x3d7ec6,_0x18daad){_0x3d7ec6=_0x3d7ec6-0x8a;const _0x484af8=a63_0x484a();let _0x256d8a=_0x484af8[_0x3d7ec6];return _0x256d8a;}function normalizeOperationEntry(_0x2d9039,_0xeba8b5){const _0x41266f=a63_0x256d;if(!_0xeba8b5||typeof _0xeba8b5!==_0x41266f(0xa1))return null;if(!_0xeba8b5[_0x41266f(0xa8)]||!_0xeba8b5[_0x41266f(0xdb)])return null;const _0x1aff90={'name':_0x2d9039,'method':_0xeba8b5[_0x41266f(0xa8)],'path':_0xeba8b5[_0x41266f(0xdb)]};if(_0xeba8b5['host'])_0x1aff90[_0x41266f(0xc8)]=_0xeba8b5[_0x41266f(0xc8)];if(_0xeba8b5[_0x41266f(0x8b)]!=null){const _0x2a0510=parseJsonMaybe(_0xeba8b5[_0x41266f(0x8b)]);_0x1aff90[_0x41266f(0x8b)]=_0x2a0510;}if(_0xeba8b5[_0x41266f(0x8d)]!=null){const _0xf9fe33=parseJsonMaybe(_0xeba8b5['responseBody']);_0x1aff90['responseBody']=_0xf9fe33;}if(_0xeba8b5[_0x41266f(0x9a)]!=null)_0x1aff90[_0x41266f(0x9a)]=_0xeba8b5[_0x41266f(0x9a)];if(_0xeba8b5[_0x41266f(0x8e)]!=null)_0x1aff90[_0x41266f(0x8e)]=_0xeba8b5[_0x41266f(0x8e)];if(Array[_0x41266f(0x9e)](_0xeba8b5['requestFields']))_0x1aff90[_0x41266f(0xa5)]=_0xeba8b5[_0x41266f(0xa5)];if(Array[_0x41266f(0x9e)](_0xeba8b5[_0x41266f(0xc9)]))_0x1aff90[_0x41266f(0xc9)]=_0xeba8b5['responseFields'];return _0x1aff90;}function summarizeDbtable(_0x203b62){const _0x127e11=a63_0x256d,_0xd68141={},_0x551e26=[_0x127e11(0xde),_0x127e11(0xc3),_0x127e11(0x93),_0x127e11(0xc2),_0x127e11(0x99),_0x127e11(0xa7),'logicField',_0x127e11(0xc5),_0x127e11(0xb0),_0x127e11(0xd9),_0x127e11(0x9d),'modifierIdField',_0x127e11(0xbd),_0x127e11(0xaf),_0x127e11(0xd8)];for(const _0x5c86f9 of _0x551e26){if(_0x203b62[_0x5c86f9]!==undefined)_0xd68141[_0x5c86f9]=_0x203b62[_0x5c86f9];}return typeof _0xd68141[_0x127e11(0xa7)]===_0x127e11(0xcd)&&_0xd68141[_0x127e11(0xa7)][_0x127e11(0xb3)]>0x0&&(_0xd68141[_0x127e11(0xc4)]=_0xd68141[_0x127e11(0xa7)][_0x127e11(0xaa)](',')[_0x127e11(0x96)](_0x15c1ce=>_0x15c1ce[_0x127e11(0xbe)]())['filter'](Boolean)),_0xd68141;}function normalizeRelatedPages(_0x281c87){const _0x595a33=a63_0x256d;if(!Array[_0x595a33(0x9e)](_0x281c87))return[];return _0x281c87['filter'](_0x3fea17=>_0x3fea17&&typeof _0x3fea17===_0x595a33(0xa1))[_0x595a33(0x96)](_0x5cc42a=>({'id':_0x5cc42a['id'],'type':_0x5cc42a[_0x595a33(0xdc)],'code':_0x5cc42a[_0x595a33(0xcf)],'title':_0x5cc42a['title'],'deleted':_0x5cc42a[_0x595a33(0xc0)]===!![]}));}export const datasetDetail={'service':a63_0x19a0e1(0x90),'command':a63_0x19a0e1(0xd5),'description':a63_0x19a0e1(0xd1),'risk':a63_0x19a0e1(0xc6),'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':a63_0x19a0e1(0xa4),'type':a63_0x19a0e1(0xcd),'description':a63_0x19a0e1(0xb4)}],async 'execute'(_0x3f1666){const _0x3eaf74=a63_0x19a0e1,_0x424ac5=await getDatasetDetail(_0x3f1666[_0x3eaf74(0xcb)](_0x3eaf74(0xcf))),_0x4d5595=Array['isArray'](_0x424ac5[_0x3eaf74(0x94)])?_0x424ac5[_0x3eaf74(0x94)]:Array[_0x3eaf74(0x9e)](_0x424ac5[_0x3eaf74(0xca)])?_0x424ac5[_0x3eaf74(0xca)]:[],_0x325474=_0x4d5595['map'](_0x14e04f=>normalizeField(_0x14e04f))[_0x3eaf74(0x98)](_0x3140bd=>_0x3140bd!==null),_0x1c716c=_0x424ac5[_0x3eaf74(0x91)]??{},_0x482006=[];for(const [_0x3facad,_0x1c846e]of Object[_0x3eaf74(0xc7)](_0x1c716c)){const _0x62e927=normalizeOperationEntry(_0x3facad,_0x1c846e);if(_0x62e927)_0x482006['push'](_0x62e927);}const _0x4f667e=_0x424ac5[_0x3eaf74(0xb1)]??{},_0x247ca5=_0x424ac5[_0x3eaf74(0x90)]??{},_0x3bd051=_0x4f667e['dbId']!=null?{'id':_0x4f667e['dbId'],'name':_0x4f667e['dbName']??null}:undefined;let _0x5aa04e;return typeof _0x424ac5[_0x3eaf74(0xb6)]===_0x3eaf74(0xcd)&&(_0x5aa04e=parseJsonMaybe(_0x424ac5['extend'])),{'ok':!![],'data':{'id':_0x424ac5[_0x3eaf74(0x8c)]??_0x424ac5['id'],'name':_0x424ac5[_0x3eaf74(0xd0)],'code':_0x424ac5['modelCode']||_0x424ac5[_0x3eaf74(0xcf)],'doVersion':_0x424ac5[_0x3eaf74(0xbc)],'description':_0x424ac5[_0x3eaf74(0x95)]||_0x247ca5[_0x3eaf74(0xa6)]||undefined,'source':_0x424ac5[_0x3eaf74(0xa2)]||_0x247ca5[_0x3eaf74(0x8f)],'table':_0x4f667e['tableName']||_0x247ca5['tableName'],'datasetKey':_0x4f667e[_0x3eaf74(0xc2)],'pk':_0x4f667e[_0x3eaf74(0x99)],'db':_0x3bd051,'dbtable':summarizeDbtable(_0x4f667e),'fields':_0x325474,'operations':_0x482006,'indexes':Array[_0x3eaf74(0x9e)](_0x247ca5['indexes'])?_0x247ca5[_0x3eaf74(0xb2)]:[],'relations':Array['isArray'](_0x424ac5['relations'])?_0x424ac5['relations'][_0x3eaf74(0x96)](_0x4fe94f=>({..._0x4fe94f[_0x3eaf74(0xae)]!=null?{'relationId':_0x4fe94f[_0x3eaf74(0xae)]}:{},'fromDataset':_0x424ac5[_0x3eaf74(0xd0)],'fromCode':_0x424ac5[_0x3eaf74(0xad)]||_0x424ac5['code'],'fromTable':_0x4f667e['tableName']||_0x247ca5['tableName'],'fromField':_0x4fe94f[_0x3eaf74(0xd4)],'toDataset':_0x4fe94f['toDatasetName'],'toCode':_0x4fe94f[_0x3eaf74(0xb7)],'toTable':_0x4fe94f['toTableName'],'toField':_0x4fe94f[_0x3eaf74(0xba)],'labelField':_0x4fe94f[_0x3eaf74(0x97)]||undefined,'cardinality':_0x4fe94f[_0x3eaf74(0x9b)]||undefined,'bizRelationType':_0x4fe94f[_0x3eaf74(0xb9)]===_0x3eaf74(0xda)?'main_sub':null})):[],'relatedPages':normalizeRelatedPages(_0x424ac5[_0x3eaf74(0xbb)]),...Array[_0x3eaf74(0x9e)](_0x424ac5[_0x3eaf74(0xab)])?{'columnCodeListWithDeleted':_0x424ac5[_0x3eaf74(0xab)]}:{},'formatRules':Array['isArray'](_0x424ac5[_0x3eaf74(0xd3)])?_0x424ac5['formatRules']:[],'validateRules':Array['isArray'](_0x424ac5[_0x3eaf74(0xcc)])?_0x424ac5[_0x3eaf74(0xcc)]:[],..._0x5aa04e!==undefined?{'extend':_0x5aa04e}:{},'stats':{'fieldCount':_0x325474[_0x3eaf74(0xb3)],'operationCount':_0x482006[_0x3eaf74(0xb3)]}}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a63_0x1a1cac=a63_0x5aeb;(function(_0x185fe2,_0x2c97ee){const _0x1378a9=a63_0x5aeb,_0x2a222f=_0x185fe2();while(!![]){try{const _0x17db9a=parseInt(_0x1378a9(0x1cb))/0x1*(-parseInt(_0x1378a9(0x1cd))/0x2)+-parseInt(_0x1378a9(0x1c4))/0x3+-parseInt(_0x1378a9(0x1ae))/0x4*(-parseInt(_0x1378a9(0x1c8))/0x5)+-parseInt(_0x1378a9(0x1c1))/0x6*(parseInt(_0x1378a9(0x1cf))/0x7)+parseInt(_0x1378a9(0x1db))/0x8*(-parseInt(_0x1378a9(0x1c2))/0x9)+-parseInt(_0x1378a9(0x1ca))/0xa*(-parseInt(_0x1378a9(0x1d0))/0xb)+-parseInt(_0x1378a9(0x1bd))/0xc*(-parseInt(_0x1378a9(0x1b1))/0xd);if(_0x17db9a===_0x2c97ee)break;else _0x2a222f['push'](_0x2a222f['shift']());}catch(_0x49bcd5){_0x2a222f['push'](_0x2a222f['shift']());}}}(a63_0x4244,0x703de));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';function a63_0x4244(){const _0x467649=['JSON\x20object\x20of\x20expected\x20current\x20extend\x20values;\x20mismatch\x20aborts\x20without\x20writing','--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key','code','7056792dfmwkA','length','write','stringify','42tVLYPn','189DXuCBW','--expect-json','168165DVGoiu','sort','dataset','No\x20dataset\x20extend\x20patch\x20keys\x20are\x20currently\x20supported.','85585fKllZZ','appCode','1375800fcKEhk','1553wHoDWe','Dataset\x20extend\x20must\x20be\x20valid\x20JSON\x20object:\x20','274ZGSBNP','str','296366EKHKbv','11fZgcDB','message','No\x20changes\x20for\x20dataset\x20extend','tableName','parse','modelId','--code\x20is\x20required','Updated\x20dataset\x20extend\x20(','string','push','expect-json','123056VfBHlI','dbId','has','extend-update','datasetCode','entries','validation','businessGroup','get','isArray','dataset\x20extend-update\x20does\x20not\x20support\x20businessGroup;\x20use\x20dataset\x20business-group-update','Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object','from','patch','\x20must\x20be\x20valid\x20JSON\x20object:\x20','shape','JSON\x20object\x20patch\x20for\x20dataset\x20top-level\x20extend;\x20current\x20allowlist\x20is\x20empty','POST','join','keys','--patch-json','name','hint','dbtableConfig','8lgEZBp','Expected\x20','data','26onlVbQ','patch-json','trim','Allowed\x20keys:\x20','object','\x20must\x20be\x20a\x20JSON\x20object','value','extend',',\x20actual\x20'];a63_0x4244=function(){return _0x467649;};return a63_0x4244();}import{getDatasetDetail,updateDrivenData}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const MUTABLE_EXTEND_KEYS=new Set(),EXTEND_PATCH_REDIRECTS=new Map([[a63_0x1a1cac(0x1e2),{'message':a63_0x1a1cac(0x1e5),'hint':'Use\x20`rabetbase\x20dataset\x20business-group-update`\x20to\x20update\x20business\x20model\x20groups.'}]]);export function parseJsonObjectFlag(_0x1f3d49,_0x203ef7){const _0x1a0369=a63_0x1a1cac;if(!_0x1f3d49)return undefined;let _0x4ae831;try{_0x4ae831=JSON[_0x1a0369(0x1d4)](_0x1f3d49);}catch(_0x175a16){const _0x3a6e9f=_0x175a16 instanceof Error?_0x175a16[_0x1a0369(0x1d1)]:String(_0x175a16);throw CliErrors[_0x1a0369(0x1e1)](_0x203ef7+_0x1a0369(0x1a4)+_0x3a6e9f);}if(!isPlainObject(_0x4ae831)||Array[_0x1a0369(0x1e4)](_0x4ae831))throw CliErrors[_0x1a0369(0x1e1)](_0x203ef7+_0x1a0369(0x1b6));return _0x4ae831;}export function validateExtendPatchKeys(_0x3c6ddb){const _0x6a60f9=a63_0x1a1cac,_0x1e2f27=Object[_0x6a60f9(0x1a9)](_0x3c6ddb);if(_0x1e2f27[_0x6a60f9(0x1be)]===0x0)throw CliErrors['validation'](_0x6a60f9(0x1bb));for(const _0x3415f6 of _0x1e2f27){const _0xc1afb0=EXTEND_PATCH_REDIRECTS[_0x6a60f9(0x1e3)](_0x3415f6);if(_0xc1afb0)throw CliErrors[_0x6a60f9(0x1e1)](_0xc1afb0[_0x6a60f9(0x1d1)],_0xc1afb0[_0x6a60f9(0x1ac)]);if(!MUTABLE_EXTEND_KEYS[_0x6a60f9(0x1dd)](_0x3415f6))throw CliErrors['validation']('Unsupported\x20patch\x20key:\x20'+_0x3415f6,describeMutableExtendKeys());}}function describeMutableExtendKeys(){const _0x2d31d2=a63_0x1a1cac,_0x42cb35=Array[_0x2d31d2(0x1e7)](MUTABLE_EXTEND_KEYS)[_0x2d31d2(0x1c5)]();return _0x42cb35[_0x2d31d2(0x1be)]>0x0?_0x2d31d2(0x1b4)+_0x42cb35['join'](',\x20'):_0x2d31d2(0x1c7);}export function applyExtendPatch(_0x25c07c,_0x1ee799){const _0x3ec880=a63_0x1a1cac;validateExtendPatchKeys(_0x1ee799);const _0xe38109=deepClone(_0x25c07c),_0x44d6dd=[];for(const [_0x31c5fd,_0x6215eb]of Object[_0x3ec880(0x1e0)](_0x1ee799)){const _0x1c82fe=_0xe38109[_0x31c5fd],_0x381073=deepClone(_0x6215eb);!deepEqual(_0x1c82fe,_0x381073)&&(_0xe38109[_0x31c5fd]=_0x381073,_0x44d6dd[_0x3ec880(0x1d9)]('extend.'+_0x31c5fd));}return _0x44d6dd[_0x3ec880(0x1c5)](),{'after':_0xe38109,'changedPaths':_0x44d6dd,'changed':_0x44d6dd['length']>0x0};}export function assertExpectation(_0x581bb2,_0x2ea0ee){const _0x4c4f35=a63_0x1a1cac;if(!_0x2ea0ee)return;for(const [_0x2853e9,_0x5aad58]of Object[_0x4c4f35(0x1e0)](_0x2ea0ee)){const _0x2fad80=_0x581bb2[_0x2853e9];if(!deepEqual(_0x2fad80,_0x5aad58))throw CliErrors[_0x4c4f35(0x1e1)]('Expectation\x20mismatch\x20at\x20extend.'+_0x2853e9,_0x4c4f35(0x1af)+JSON['stringify'](_0x5aad58)+_0x4c4f35(0x1b9)+JSON[_0x4c4f35(0x1c0)](_0x2fad80));}}export async function buildDatasetExtendUpdateResult({appCode:_0x231a9d,input:_0x1118aa,dryRun:_0x29af4e}){const _0x59fc64=a63_0x1a1cac;validateInput(_0x1118aa);const _0x29416a=await getDatasetDetail(_0x1118aa[_0x59fc64(0x1bc)]),_0x2c1396=parseDatasetExtend(_0x29416a[_0x59fc64(0x1b8)]),_0x2aaa54=deepClone(_0x2c1396[_0x59fc64(0x1b7)]);assertExpectation(_0x2aaa54,_0x1118aa['expect']);const {after:_0x4b81e,changedPaths:_0x261865,changed:_0x3bb028}=applyExtendPatch(_0x2aaa54,_0x1118aa[_0x59fc64(0x1e8)]),_0xea27a1=summarizeDataset(_0x29416a,_0x1118aa['code']);return _0x3bb028&&!_0x29af4e&&(_0x29416a['extend']=serializeDatasetExtend(_0x4b81e,_0x2c1396[_0x59fc64(0x1a5)]),await updateDrivenData(_0x29416a)),{'ok':!![],'data':{'appCode':_0x231a9d,'selector':{'code':_0x1118aa[_0x59fc64(0x1bc)]},'dataset':_0xea27a1,'dryRun':_0x29af4e,'changed':_0x3bb028,'changedPaths':_0x261865,'before':{'extend':_0x2aaa54},'after':{'extend':_0x4b81e},'submitted':_0x3bb028&&!_0x29af4e},'message':_0x3bb028?_0x29af4e?'Dry-run:\x20dataset\x20extend\x20would\x20change\x20('+_0x261865[_0x59fc64(0x1a8)](',\x20')+')':_0x59fc64(0x1d7)+_0x261865[_0x59fc64(0x1a8)](',\x20')+')':_0x59fc64(0x1d2)};}export const datasetExtendUpdate={'service':'dataset','command':a63_0x1a1cac(0x1de),'description':'Patch\x20dataset\x20top-level\x20extend\x20safely','risk':a63_0x1a1cac(0x1bf),'flags':[CODE_FLAG,{'name':a63_0x1a1cac(0x1b2),'type':a63_0x1a1cac(0x1d8),'required':!![],'description':a63_0x1a1cac(0x1a6)},{'name':'expect-json','type':'string','required':![],'description':a63_0x1a1cac(0x1ba)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x1ffc1c){validateInput(readExtendUpdateInput(_0x1ffc1c));},async 'dryRun'(_0x1ad213){const _0x2793aa=a63_0x1a1cac,_0xb6b5ae=await buildDatasetExtendUpdateResult({'appCode':_0x1ad213[_0x2793aa(0x1c9)],'input':readExtendUpdateInput(_0x1ad213),'dryRun':!![]});return{'method':_0x2793aa(0x1a7),'url':'/smartapi/dataset/update-driven-data','body':_0xb6b5ae[_0x2793aa(0x1b0)],'description':_0xb6b5ae['message']};},async 'execute'(_0x18e766){return buildDatasetExtendUpdateResult({'appCode':_0x18e766['appCode'],'input':readExtendUpdateInput(_0x18e766),'dryRun':![]});}};function readExtendUpdateInput(_0x210bd2){const _0x55f018=a63_0x1a1cac,_0x938c0e=trim(_0x210bd2[_0x55f018(0x1ce)](_0x55f018(0x1bc))),_0x35a521=parseJsonObjectFlag(_0x210bd2[_0x55f018(0x1ce)](_0x55f018(0x1b2)),_0x55f018(0x1aa)),_0x17a5d3=parseJsonObjectFlag(_0x210bd2[_0x55f018(0x1ce)](_0x55f018(0x1da)),_0x55f018(0x1c3));return{'code':_0x938c0e,'patch':_0x35a521||{},'expect':_0x17a5d3};}function validateInput(_0x5021f4){const _0x338759=a63_0x1a1cac;if(!_0x5021f4[_0x338759(0x1bc)])throw CliErrors[_0x338759(0x1e1)](_0x338759(0x1d6));validateExtendPatchKeys(_0x5021f4['patch']);}function parseDatasetExtend(_0x145f2c){const _0x311cf5=a63_0x1a1cac;if(typeof _0x145f2c===_0x311cf5(0x1d8)){const _0x4dc08a=_0x145f2c[_0x311cf5(0x1b3)]();if(!_0x4dc08a)return{'value':{},'shape':'string'};let _0x271cd5;try{_0x271cd5=JSON[_0x311cf5(0x1d4)](_0x4dc08a);}catch(_0x1eb5a1){const _0x282be3=_0x1eb5a1 instanceof Error?_0x1eb5a1['message']:String(_0x1eb5a1);throw CliErrors[_0x311cf5(0x1e1)](_0x311cf5(0x1cc)+_0x282be3);}if(!isPlainObject(_0x271cd5)||Array[_0x311cf5(0x1e4)](_0x271cd5))throw CliErrors[_0x311cf5(0x1e1)](_0x311cf5(0x1e6));return{'value':_0x271cd5,'shape':_0x311cf5(0x1d8)};}if(_0x145f2c===undefined||_0x145f2c===null)return{'value':{},'shape':_0x311cf5(0x1d8)};if(!isPlainObject(_0x145f2c)||Array[_0x311cf5(0x1e4)](_0x145f2c))throw CliErrors[_0x311cf5(0x1e1)]('Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object');return{'value':_0x145f2c,'shape':_0x311cf5(0x1b5)};}function serializeDatasetExtend(_0x1e0a07,_0x2f6bbf){const _0x490620=a63_0x1a1cac;return _0x2f6bbf==='string'?JSON[_0x490620(0x1c0)](_0x1e0a07):_0x1e0a07;}function summarizeDataset(_0x3b0486,_0x4ceb6c){const _0x1294d8=a63_0x1a1cac,_0x18a3ff=isPlainObject(_0x3b0486[_0x1294d8(0x1c6)])?_0x3b0486[_0x1294d8(0x1c6)]:{},_0x436608=isPlainObject(_0x3b0486[_0x1294d8(0x1ad)])?_0x3b0486[_0x1294d8(0x1ad)]:{};return{'id':_0x3b0486[_0x1294d8(0x1d5)]??_0x3b0486['id']??_0x18a3ff['datasetId']??null,'code':_0x3b0486['modelCode']??_0x3b0486[_0x1294d8(0x1bc)]??_0x18a3ff[_0x1294d8(0x1df)]??_0x4ceb6c,'name':_0x3b0486[_0x1294d8(0x1ab)]??_0x18a3ff['datasetName']??null,'table':_0x436608[_0x1294d8(0x1d3)]??_0x18a3ff[_0x1294d8(0x1d3)]??null,'db':_0x436608['dbName']??_0x436608[_0x1294d8(0x1dc)]??null};}function a63_0x5aeb(_0x384102,_0x4c93e1){_0x384102=_0x384102-0x1a4;const _0x42446f=a63_0x4244();let _0x5aebdf=_0x42446f[_0x384102];return _0x5aebdf;}function deepClone(_0x2e1ad4){const _0x6d9130=a63_0x1a1cac;if(_0x2e1ad4===undefined)return _0x2e1ad4;return JSON[_0x6d9130(0x1d4)](JSON[_0x6d9130(0x1c0)](_0x2e1ad4));}function deepEqual(_0xf0ca13,_0x32ca3b){const _0x29e2ef=a63_0x1a1cac;return JSON['stringify'](_0xf0ca13)===JSON[_0x29e2ef(0x1c0)](_0x32ca3b);}function isPlainObject(_0x45525b){const _0x5a0698=a63_0x1a1cac;return Boolean(_0x45525b)&&typeof _0x45525b===_0x5a0698(0x1b5)&&!Array['isArray'](_0x45525b);}function trim(_0xcf4a16){const _0x33c221=a63_0x1a1cac,_0x4d5d72=String(_0xcf4a16||'')[_0x33c221(0x1b3)]();return _0x4d5d72;}
|
|
1
|
+
const a64_0x401d1b=a64_0x5e6b;(function(_0x5ff3fc,_0x23acd6){const _0x11ba5e=a64_0x5e6b,_0x3f9f3f=_0x5ff3fc();while(!![]){try{const _0x59f8fc=parseInt(_0x11ba5e(0xdd))/0x1*(-parseInt(_0x11ba5e(0xd2))/0x2)+parseInt(_0x11ba5e(0xdc))/0x3*(parseInt(_0x11ba5e(0x10c))/0x4)+parseInt(_0x11ba5e(0xde))/0x5+-parseInt(_0x11ba5e(0x113))/0x6+-parseInt(_0x11ba5e(0xe4))/0x7+parseInt(_0x11ba5e(0xfb))/0x8+-parseInt(_0x11ba5e(0xe6))/0x9*(-parseInt(_0x11ba5e(0x100))/0xa);if(_0x59f8fc===_0x23acd6)break;else _0x3f9f3f['push'](_0x3f9f3f['shift']());}catch(_0x183bb9){_0x3f9f3f['push'](_0x3f9f3f['shift']());}}}(a64_0x958b,0x26575));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateDrivenData}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const MUTABLE_EXTEND_KEYS=new Set(),EXTEND_PATCH_REDIRECTS=new Map([[a64_0x401d1b(0xd3),{'message':a64_0x401d1b(0xf8),'hint':a64_0x401d1b(0x10e)}]]);export function parseJsonObjectFlag(_0x25b434,_0x313bb0){const _0x289301=a64_0x401d1b;if(!_0x25b434)return undefined;let _0x496c57;try{_0x496c57=JSON[_0x289301(0xcf)](_0x25b434);}catch(_0x4a9323){const _0x5e98a6=_0x4a9323 instanceof Error?_0x4a9323['message']:String(_0x4a9323);throw CliErrors[_0x289301(0xd7)](_0x313bb0+_0x289301(0xd9)+_0x5e98a6);}if(!isPlainObject(_0x496c57)||Array[_0x289301(0x108)](_0x496c57))throw CliErrors[_0x289301(0xd7)](_0x313bb0+_0x289301(0xee));return _0x496c57;}export function validateExtendPatchKeys(_0x2a7a7e){const _0x118fcc=a64_0x401d1b,_0x33a929=Object[_0x118fcc(0xe8)](_0x2a7a7e);if(_0x33a929[_0x118fcc(0x105)]===0x0)throw CliErrors[_0x118fcc(0xd7)](_0x118fcc(0xda));for(const _0x341e28 of _0x33a929){const _0xa4f73b=EXTEND_PATCH_REDIRECTS['get'](_0x341e28);if(_0xa4f73b)throw CliErrors['validation'](_0xa4f73b[_0x118fcc(0xd5)],_0xa4f73b[_0x118fcc(0xd1)]);if(!MUTABLE_EXTEND_KEYS[_0x118fcc(0xfd)](_0x341e28))throw CliErrors[_0x118fcc(0xd7)](_0x118fcc(0x10a)+_0x341e28,describeMutableExtendKeys());}}function describeMutableExtendKeys(){const _0x1ef91b=a64_0x401d1b,_0x101fad=Array[_0x1ef91b(0x109)](MUTABLE_EXTEND_KEYS)['sort']();return _0x101fad['length']>0x0?_0x1ef91b(0xce)+_0x101fad[_0x1ef91b(0xdf)](',\x20'):_0x1ef91b(0x107);}export function applyExtendPatch(_0x2f4ce8,_0x432a0f){const _0x2ffb6f=a64_0x401d1b;validateExtendPatchKeys(_0x432a0f);const _0xdb31=deepClone(_0x2f4ce8),_0x77d6e4=[];for(const [_0x160042,_0x4b0682]of Object[_0x2ffb6f(0xe7)](_0x432a0f)){const _0x568b01=_0xdb31[_0x160042],_0x3e6c70=deepClone(_0x4b0682);!deepEqual(_0x568b01,_0x3e6c70)&&(_0xdb31[_0x160042]=_0x3e6c70,_0x77d6e4[_0x2ffb6f(0x10d)](_0x2ffb6f(0xfa)+_0x160042));}return _0x77d6e4[_0x2ffb6f(0xd6)](),{'after':_0xdb31,'changedPaths':_0x77d6e4,'changed':_0x77d6e4[_0x2ffb6f(0x105)]>0x0};}export function assertExpectation(_0x5cab65,_0x13e08e){const _0x1b739c=a64_0x401d1b;if(!_0x13e08e)return;for(const [_0x112105,_0x230cd4]of Object['entries'](_0x13e08e)){const _0x30b6ea=_0x5cab65[_0x112105];if(!deepEqual(_0x30b6ea,_0x230cd4))throw CliErrors['validation'](_0x1b739c(0x110)+_0x112105,'Expected\x20'+JSON[_0x1b739c(0xfe)](_0x230cd4)+',\x20actual\x20'+JSON[_0x1b739c(0xfe)](_0x30b6ea));}}export async function buildDatasetExtendUpdateResult({appCode:_0x13067e,input:_0x12c6af,dryRun:_0x33a10d}){const _0xf6b19b=a64_0x401d1b;validateInput(_0x12c6af);const _0x118c8d=await getDatasetDetail(_0x12c6af[_0xf6b19b(0xdb)]),_0x142a95=parseDatasetExtend(_0x118c8d[_0xf6b19b(0xf9)]),_0x4f1f69=deepClone(_0x142a95[_0xf6b19b(0x106)]);assertExpectation(_0x4f1f69,_0x12c6af[_0xf6b19b(0xe0)]);const {after:_0xf399c2,changedPaths:_0x4538fa,changed:_0x194a92}=applyExtendPatch(_0x4f1f69,_0x12c6af['patch']),_0x379439=summarizeDataset(_0x118c8d,_0x12c6af[_0xf6b19b(0xdb)]);return _0x194a92&&!_0x33a10d&&(_0x118c8d['extend']=serializeDatasetExtend(_0xf399c2,_0x142a95[_0xf6b19b(0xe5)]),await updateDrivenData(_0x118c8d)),{'ok':!![],'data':{'appCode':_0x13067e,'selector':{'code':_0x12c6af[_0xf6b19b(0xdb)]},'dataset':_0x379439,'dryRun':_0x33a10d,'changed':_0x194a92,'changedPaths':_0x4538fa,'before':{'extend':_0x4f1f69},'after':{'extend':_0xf399c2},'submitted':_0x194a92&&!_0x33a10d},'message':_0x194a92?_0x33a10d?_0xf6b19b(0xe3)+_0x4538fa['join'](',\x20')+')':'Updated\x20dataset\x20extend\x20('+_0x4538fa['join'](',\x20')+')':_0xf6b19b(0x10b)};}export const datasetExtendUpdate={'service':a64_0x401d1b(0xec),'command':a64_0x401d1b(0xff),'description':a64_0x401d1b(0x10f),'risk':'write','flags':[CODE_FLAG,{'name':a64_0x401d1b(0x103),'type':a64_0x401d1b(0x102),'required':!![],'description':a64_0x401d1b(0xe1)},{'name':'expect-json','type':a64_0x401d1b(0x102),'required':![],'description':a64_0x401d1b(0xef)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x306994){validateInput(readExtendUpdateInput(_0x306994));},async 'dryRun'(_0x1f40d5){const _0x134860=a64_0x401d1b,_0x2aa6ec=await buildDatasetExtendUpdateResult({'appCode':_0x1f40d5[_0x134860(0xf3)],'input':readExtendUpdateInput(_0x1f40d5),'dryRun':!![]});return{'method':_0x134860(0xf0),'url':_0x134860(0xed),'body':_0x2aa6ec[_0x134860(0xe2)],'description':_0x2aa6ec[_0x134860(0xd5)]};},async 'execute'(_0xd5e425){const _0x57126b=a64_0x401d1b;return buildDatasetExtendUpdateResult({'appCode':_0xd5e425[_0x57126b(0xf3)],'input':readExtendUpdateInput(_0xd5e425),'dryRun':![]});}};function readExtendUpdateInput(_0x489516){const _0x3d6850=a64_0x401d1b,_0x8ee9a7=trim(_0x489516[_0x3d6850(0xf7)]('code')),_0x4d8723=parseJsonObjectFlag(_0x489516[_0x3d6850(0xf7)](_0x3d6850(0x103)),_0x3d6850(0xd4)),_0x1229c2=parseJsonObjectFlag(_0x489516[_0x3d6850(0xf7)](_0x3d6850(0xd0)),'--expect-json');return{'code':_0x8ee9a7,'patch':_0x4d8723||{},'expect':_0x1229c2};}function validateInput(_0x235551){const _0x1714d2=a64_0x401d1b;if(!_0x235551[_0x1714d2(0xdb)])throw CliErrors[_0x1714d2(0xd7)]('--code\x20is\x20required');validateExtendPatchKeys(_0x235551[_0x1714d2(0xf5)]);}function parseDatasetExtend(_0x4a6f9b){const _0x10f837=a64_0x401d1b;if(typeof _0x4a6f9b==='string'){const _0x168a1b=_0x4a6f9b[_0x10f837(0xfc)]();if(!_0x168a1b)return{'value':{},'shape':_0x10f837(0x102)};let _0x41269f;try{_0x41269f=JSON[_0x10f837(0xcf)](_0x168a1b);}catch(_0x3d846b){const _0x239e8b=_0x3d846b instanceof Error?_0x3d846b['message']:String(_0x3d846b);throw CliErrors['validation'](_0x10f837(0xf2)+_0x239e8b);}if(!isPlainObject(_0x41269f)||Array[_0x10f837(0x108)](_0x41269f))throw CliErrors[_0x10f837(0xd7)](_0x10f837(0x104));return{'value':_0x41269f,'shape':_0x10f837(0x102)};}if(_0x4a6f9b===undefined||_0x4a6f9b===null)return{'value':{},'shape':'string'};if(!isPlainObject(_0x4a6f9b)||Array[_0x10f837(0x108)](_0x4a6f9b))throw CliErrors[_0x10f837(0xd7)](_0x10f837(0x104));return{'value':_0x4a6f9b,'shape':_0x10f837(0xe9)};}function serializeDatasetExtend(_0x1ab3c4,_0x390304){const _0x357661=a64_0x401d1b;return _0x390304===_0x357661(0x102)?JSON[_0x357661(0xfe)](_0x1ab3c4):_0x1ab3c4;}function summarizeDataset(_0x111b07,_0x2acdc3){const _0x273cdf=a64_0x401d1b,_0x248708=isPlainObject(_0x111b07[_0x273cdf(0xec)])?_0x111b07[_0x273cdf(0xec)]:{},_0x1d571e=isPlainObject(_0x111b07[_0x273cdf(0x101)])?_0x111b07[_0x273cdf(0x101)]:{};return{'id':_0x111b07['modelId']??_0x111b07['id']??_0x248708[_0x273cdf(0xd8)]??null,'code':_0x111b07[_0x273cdf(0xeb)]??_0x111b07[_0x273cdf(0xdb)]??_0x248708[_0x273cdf(0xf1)]??_0x2acdc3,'name':_0x111b07[_0x273cdf(0x111)]??_0x248708[_0x273cdf(0xea)]??null,'table':_0x1d571e[_0x273cdf(0xf6)]??_0x248708[_0x273cdf(0xf6)]??null,'db':_0x1d571e[_0x273cdf(0xf4)]??_0x1d571e[_0x273cdf(0x112)]??null};}function deepClone(_0xf2295c){const _0x56bc1b=a64_0x401d1b;if(_0xf2295c===undefined)return _0xf2295c;return JSON[_0x56bc1b(0xcf)](JSON[_0x56bc1b(0xfe)](_0xf2295c));}function a64_0x5e6b(_0x557b40,_0x3d13b4){_0x557b40=_0x557b40-0xce;const _0x958b5a=a64_0x958b();let _0x5e6bee=_0x958b5a[_0x557b40];return _0x5e6bee;}function deepEqual(_0x632d99,_0x12c08d){const _0x3f677c=a64_0x401d1b;return JSON[_0x3f677c(0xfe)](_0x632d99)===JSON[_0x3f677c(0xfe)](_0x12c08d);}function isPlainObject(_0x397607){const _0xd142c8=a64_0x401d1b;return Boolean(_0x397607)&&typeof _0x397607===_0xd142c8(0xe9)&&!Array['isArray'](_0x397607);}function trim(_0x524b9e){const _0xb22898=a64_0x401d1b,_0x483a76=String(_0x524b9e||'')[_0xb22898(0xfc)]();return _0x483a76;}function a64_0x958b(){const _0x1deea0=['312541mcegop','761345KljmIa','join','expect','JSON\x20object\x20patch\x20for\x20dataset\x20top-level\x20extend;\x20current\x20allowlist\x20is\x20empty','data','Dry-run:\x20dataset\x20extend\x20would\x20change\x20(','486577mWTsCJ','shape','9CIYCVf','entries','keys','object','datasetName','modelCode','dataset','/smartapi/dataset/update-driven-data','\x20must\x20be\x20a\x20JSON\x20object','JSON\x20object\x20of\x20expected\x20current\x20extend\x20values;\x20mismatch\x20aborts\x20without\x20writing','POST','datasetCode','Dataset\x20extend\x20must\x20be\x20valid\x20JSON\x20object:\x20','appCode','dbName','patch','tableName','str','dataset\x20extend-update\x20does\x20not\x20support\x20businessGroup;\x20use\x20dataset\x20business-group-update','extend','extend.','2384048nyCQGF','trim','has','stringify','extend-update','841400MSAriE','dbtableConfig','string','patch-json','Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object','length','value','No\x20dataset\x20extend\x20patch\x20keys\x20are\x20currently\x20supported.','isArray','from','Unsupported\x20patch\x20key:\x20','No\x20changes\x20for\x20dataset\x20extend','7572pnfZSY','push','Use\x20`rabetbase\x20dataset\x20business-group-update`\x20to\x20update\x20business\x20model\x20groups.','Patch\x20dataset\x20top-level\x20extend\x20safely','Expectation\x20mismatch\x20at\x20extend.','name','dbId','1187214AyGBSS','Allowed\x20keys:\x20','parse','expect-json','hint','2drQLAD','businessGroup','--patch-json','message','sort','validation','datasetId','\x20must\x20be\x20valid\x20JSON\x20object:\x20','--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key','code','321YiKlqo'];a64_0x958b=function(){return _0x1deea0;};return a64_0x958b();}
|