@lovrabet/rabetbase-cli 2.4.7-beta.1 → 2.4.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- 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 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/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/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-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.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/search.js +1 -1
- package/lib/commands/kb/shared.js +1 -1
- package/lib/commands/kb/update.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/mutations.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/visibility-update.js +1 -1
- package/lib/commands/notification/config-create.js +1 -1
- package/lib/commands/notification/config-delete.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/config-update.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/create.js +1 -1
- package/lib/commands/page/custom/detail.js +1 -1
- package/lib/commands/page/custom/list.js +1 -1
- package/lib/commands/page/custom/publish.js +1 -1
- package/lib/commands/page/custom/shared.js +1 -1
- package/lib/commands/page/custom/syntax.js +1 -1
- package/lib/commands/page/custom/template.js +1 -1
- package/lib/commands/page/custom/update.js +1 -1
- package/lib/commands/page/data-list-status.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/materialize-project-template.js +1 -1
- package/lib/commands/project/create/project-name.js +1 -1
- package/lib/commands/project/create/project-template-archive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/role/user-resolve.js +1 -1
- package/lib/commands/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 +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.d.ts +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.d.ts +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.d.ts +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.d.ts +2 -2
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/types.d.ts +1 -1
- package/lib/core/bff/utils.d.ts +2 -2
- 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 +2 -2
- package/sidecar/flags.json +1 -1
- package/skills/rabetbase/SKILL.md +28 -28
- package/skills/rabetbase/guides/backend-function.md +30 -30
- package/skills/rabetbase/guides/best-practices.md +8 -8
- package/skills/rabetbase/guides/bff-creation-workflow.md +16 -16
- package/skills/rabetbase/guides/conflict-detection.md +3 -3
- package/skills/rabetbase/guides/custom-page-workflow.md +8 -8
- package/skills/rabetbase/guides/data-api-guidelines.md +6 -6
- package/skills/rabetbase/guides/legacy-application-blueprint-workflow.md +8 -8
- package/skills/rabetbase/guides/sql-creation-workflow.md +2 -2
- package/skills/rabetbase/guides/troubleshooting.md +6 -6
- package/skills/rabetbase/guides/typescript-sdk.md +10 -10
- package/skills/rabetbase/knowledge/page-schema/LrSmartTable.md +1 -1
- package/skills/rabetbase/knowledge/page-schema/external-resources-usage.md +10 -10
- package/skills/rabetbase/references/rabetbase-app-config.md +2 -2
- package/skills/rabetbase/references/rabetbase-bff-create.md +3 -3
- package/skills/rabetbase/references/rabetbase-bff-delete.md +1 -1
- package/skills/rabetbase/references/rabetbase-bff-detail.md +4 -4
- package/skills/rabetbase/references/rabetbase-bff-list.md +8 -8
- package/skills/rabetbase/references/rabetbase-bff-pull.md +1 -1
- package/skills/rabetbase/references/rabetbase-bff-push.md +3 -3
- package/skills/rabetbase/references/rabetbase-bff-status.md +1 -1
- package/skills/rabetbase/references/rabetbase-codegen-sql.md +3 -3
- package/skills/rabetbase/references/rabetbase-dataset-detail.md +1 -1
- package/skills/rabetbase/references/rabetbase-notification-config-list.md +3 -3
- package/skills/rabetbase.manifest.json +3 -3
- package/templates/rules/lovrabet_rules.mdc.tpl +7 -7
- package/templates/skill/SKILL.md.tpl +12 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a49_0x1b96(){const _0x206b8b=['7538968qXMQuY','5996RlnnNU','3015444vKWKnc','test','trim','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','476uPGCvS','1699882yRbFID','87276wsSMjr','947179ybKmhW','34183152fSpWrE','1550oDNvLA'];a49_0x1b96=function(){return _0x206b8b;};return a49_0x1b96();}(function(_0x2f1ae3,_0x46a84d){const _0x154446=a49_0x173d,_0x161616=_0x2f1ae3();while(!![]){try{const _0x4c6924=-parseInt(_0x154446(0x155))/0x1+-parseInt(_0x154446(0x153))/0x2+parseInt(_0x154446(0x14e))/0x3+-parseInt(_0x154446(0x14d))/0x4*(parseInt(_0x154446(0x157))/0x5)+-parseInt(_0x154446(0x154))/0x6*(parseInt(_0x154446(0x152))/0x7)+-parseInt(_0x154446(0x14c))/0x8+parseInt(_0x154446(0x156))/0x9;if(_0x4c6924===_0x46a84d)break;else _0x161616['push'](_0x161616['shift']());}catch(_0x1111f7){_0x161616['push'](_0x161616['shift']());}}}(a49_0x1b96,0x94eaf));function a49_0x173d(_0x15cae1,_0x3a550e){_0x15cae1=_0x15cae1-0x14c;const _0x1b9652=a49_0x1b96();let _0x173dc4=_0x1b9652[_0x15cae1];return _0x173dc4;}export function validateAppcode(_0x26a5b6){const _0x4e0c58=a49_0x173d,_0x450d5a=_0x26a5b6[_0x4e0c58(0x150)]();if(!_0x450d5a)return{'valid':![],'message':'App\x20Code\x20cannot\x20be\x20empty'};if(_0x450d5a['length']>0x64)return{'valid':![],'message':'App\x20Code\x20cannot\x20exceed\x20100\x20characters'};if(!/^[A-Za-z0-9_-]+$/[_0x4e0c58(0x14f)](_0x450d5a))return{'valid':![],'message':_0x4e0c58(0x151)};return{'valid':!![]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a50_0x5a48b1=a50_0x2c28;(function(_0x332fc8,_0x1d46a1){const _0x5d9a42=a50_0x2c28,_0xec725c=_0x332fc8();while(!![]){try{const _0x147605=parseInt(_0x5d9a42(0x11e))/0x1*(-parseInt(_0x5d9a42(0x119))/0x2)+parseInt(_0x5d9a42(0x114))/0x3+-parseInt(_0x5d9a42(0x111))/0x4+parseInt(_0x5d9a42(0x11a))/0x5*(parseInt(_0x5d9a42(0x11b))/0x6)+parseInt(_0x5d9a42(0x10e))/0x7+parseInt(_0x5d9a42(0x116))/0x8+parseInt(_0x5d9a42(0x117))/0x9*(parseInt(_0x5d9a42(0x10d))/0xa);if(_0x147605===_0x1d46a1)break;else _0xec725c['push'](_0xec725c['shift']());}catch(_0x1ea797){_0xec725c['push'](_0xec725c['shift']());}}}(a50_0x5962,0xc906f));function a50_0x2c28(_0x3e608f,_0x27a132){_0x3e608f=_0x3e608f-0x10c;const _0x59623d=a50_0x5962();let _0x2c2842=_0x59623d[_0x3e608f];return _0x2c2842;}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';function a50_0x5962(){const _0x4d51b6=['key','9866MRPupd','str','1230XrJKFd','7893711vkkDoY','appcode','config','4759644qIehJU','app','object','67539oqaAze','Missing\x20key.','1710816trHLky','48051RePAch','validation','262AuPvDJ','713905oUcsbH','54EzRJwk','read'];a50_0x5962=function(){return _0x4d51b6;};return a50_0x5962();}async function execute(_0x5ea4ab){const _0x4fcb82=a50_0x2c28,_0x561cca=_0x5ea4ab[_0x4fcb82(0x10c)](_0x4fcb82(0x11d));if(!_0x561cca)throw CliErrors[_0x4fcb82(0x118)](_0x4fcb82(0x115),'Usage:\x20'+CLI_BIN_NAME+'\x20config\x20get\x20--key\x20<key>');const _0x40e231=readConfig(),_0x5b1f96=_0x561cca===_0x4fcb82(0x112)?_0x4fcb82(0x10f):_0x561cca,_0x14b390=_0x40e231[_0x5b1f96];if(_0x14b390===undefined)throw CliErrors[_0x4fcb82(0x118)]('Key\x20not\x20found:\x20'+_0x561cca);return{'ok':!![],'data':typeof _0x14b390===_0x4fcb82(0x113)?_0x14b390:{[_0x5b1f96]:_0x14b390},'message':typeof _0x14b390===_0x4fcb82(0x113)?undefined:String(_0x14b390)};}export const configGetDefinition={'service':a50_0x5a48b1(0x110),'command':'get','description':'Get\x20a\x20config\x20value\x20by\x20key','risk':a50_0x5a48b1(0x11c),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':'string','description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x154330,_0x17eb25){const _0x1ff90f=a51_0x2373,_0x26b295=_0x154330();while(!![]){try{const _0x1ea29f=-parseInt(_0x1ff90f(0xb9))/0x1+parseInt(_0x1ff90f(0xbf))/0x2*(-parseInt(_0x1ff90f(0xb7))/0x3)+-parseInt(_0x1ff90f(0xba))/0x4+parseInt(_0x1ff90f(0xb6))/0x5*(parseInt(_0x1ff90f(0xbc))/0x6)+-parseInt(_0x1ff90f(0xbd))/0x7*(parseInt(_0x1ff90f(0xb5))/0x8)+-parseInt(_0x1ff90f(0xc0))/0x9*(-parseInt(_0x1ff90f(0xbe))/0xa)+-parseInt(_0x1ff90f(0xbb))/0xb*(-parseInt(_0x1ff90f(0xb8))/0xc);if(_0x1ea29f===_0x17eb25)break;else _0x26b295['push'](_0x26b295['shift']());}catch(_0x17f336){_0x26b295['push'](_0x26b295['shift']());}}}(a51_0x20db,0xd7aa4));function a51_0x20db(){const _0x3ec4a7=['35026893PXEsBn','71028iDgoad','14EAIemO','82580bLKStt','2330LdhSZe','1530mNTqKt','2436072GTeEkH','215vybckm','4308YhzxUz','12OQugtj','1056915pavwJU','3499680VnIvOr'];a51_0x20db=function(){return _0x3ec4a7;};return a51_0x20db();}import{configListDefinition}from'../../commands/config/list.js';function a51_0x2373(_0x10efa5,_0x30b4f7){_0x10efa5=_0x10efa5-0xb5;const _0x20db36=a51_0x20db();let _0x237306=_0x20db36[_0x10efa5];return _0x237306;}import{configGetDefinition}from'../../commands/config/get.js';import{configSetDefinition}from'../../commands/config/set.js';export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a52_0x58989f=a52_0x5724;function a52_0x5724(_0x2eb93f,_0x1e4618){_0x2eb93f=_0x2eb93f-0x178;const _0x436b1d=a52_0x436b();let _0x572443=_0x436b1d[_0x2eb93f];return _0x572443;}(function(_0x25ec0d,_0x21f0b6){const _0x30efd0=a52_0x5724,_0x552a23=_0x25ec0d();while(!![]){try{const _0x513a18=parseInt(_0x30efd0(0x186))/0x1+-parseInt(_0x30efd0(0x187))/0x2*(-parseInt(_0x30efd0(0x188))/0x3)+-parseInt(_0x30efd0(0x17d))/0x4*(-parseInt(_0x30efd0(0x183))/0x5)+parseInt(_0x30efd0(0x181))/0x6+parseInt(_0x30efd0(0x17e))/0x7*(parseInt(_0x30efd0(0x178))/0x8)+-parseInt(_0x30efd0(0x184))/0x9*(parseInt(_0x30efd0(0x17a))/0xa)+-parseInt(_0x30efd0(0x182))/0xb;if(_0x513a18===_0x21f0b6)break;else _0x552a23['push'](_0x552a23['shift']());}catch(_0x376bb7){_0x552a23['push'](_0x552a23['shift']());}}}(a52_0x436b,0x2150b));import{readScopedConfig}from'../../commands/config/shared.js';import{readConfig}from'../../utils/config.js';async function execute(_0x5b9975){const _0x3acc75=a52_0x5724,_0x261772=_0x5b9975[_0x3acc75(0x180)](_0x3acc75(0x185))?readScopedConfig('global'):readConfig();return{'ok':!![],'data':_0x261772};}function a52_0x436b(){const _0x46997f=['List\x20all\x20config\x20values','bool','1569324hpcLnu','5523287jGrITN','9745XPeOtQ','11727ZDESwk','global','163014KAbrsy','395972FMMksS','3YHkgZg','296uiaEng','config','820bWUrsd','list','read','40uXQdLm','19558WooOgK'];a52_0x436b=function(){return _0x46997f;};return a52_0x436b();}export const configListDefinition={'service':a52_0x58989f(0x179),'command':a52_0x58989f(0x17b),'description':a52_0x58989f(0x17f),'risk':a52_0x58989f(0x17c),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a52_0x58989f(0x185),'type':'boolean','description':'Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','default':![]}],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a53_0x344903=a53_0x47dd;(function(_0x40a08e,_0x5d0946){const _0x26a672=a53_0x47dd,_0x2f5cdc=_0x40a08e();while(!![]){try{const _0x33c270=parseInt(_0x26a672(0xb6))/0x1*(parseInt(_0x26a672(0xb3))/0x2)+parseInt(_0x26a672(0xaa))/0x3+parseInt(_0x26a672(0xad))/0x4*(parseInt(_0x26a672(0xd3))/0x5)+-parseInt(_0x26a672(0xb4))/0x6*(-parseInt(_0x26a672(0xce))/0x7)+-parseInt(_0x26a672(0xb7))/0x8*(-parseInt(_0x26a672(0xa5))/0x9)+-parseInt(_0x26a672(0xa4))/0xa*(-parseInt(_0x26a672(0xca))/0xb)+-parseInt(_0x26a672(0xa7))/0xc*(parseInt(_0x26a672(0xab))/0xd);if(_0x33c270===_0x5d0946)break;else _0x2f5cdc['push'](_0x2f5cdc['shift']());}catch(_0x5d709b){_0x2f5cdc['push'](_0x2f5cdc['shift']());}}}(a53_0x5810,0xaccbd));import{CliErrors}from'../../errors.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';function a53_0x47dd(_0x4b061b,_0x5b30a1){_0x4b061b=_0x4b061b-0xa3;const _0x58105f=a53_0x5810();let _0x47dd95=_0x58105f[_0x4b061b];return _0x47dd95;}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(_0x27c3c5){const _0x5e7dec=a53_0x47dd,_0x4bc78f=_0x27c3c5[_0x5e7dec(0xcd)]('key'),_0x23d364=_0x27c3c5[_0x5e7dec(0xcd)]('value');if(!_0x4bc78f)throw CliErrors[_0x5e7dec(0xb9)](_0x5e7dec(0xaf),_0x5e7dec(0xcf)+CLI_BIN_NAME+_0x5e7dec(0xcc));if(_0x23d364===undefined||_0x23d364==='')throw CliErrors[_0x5e7dec(0xb9)]('Missing\x20value.',_0x5e7dec(0xcf)+CLI_BIN_NAME+_0x5e7dec(0xcc));if(_0x23d364[_0x5e7dec(0xb5)]>0x1f4)throw CliErrors['validation'](_0x5e7dec(0xb0));if(!isTopLevelConfigKey(_0x4bc78f))throw CliErrors[_0x5e7dec(0xb9)](_0x5e7dec(0xbd)+_0x4bc78f+_0x5e7dec(0xbe),'Settable\x20top-level\x20keys:\x20'+getTopLevelConfigKeySummary());if(_0x4bc78f==='riskLevel')throw CliErrors[_0x5e7dec(0xb9)](_0x5e7dec(0xa8));if(CONFIG_ENUM_VALUES[_0x4bc78f]&&!CONFIG_ENUM_VALUES[_0x4bc78f][_0x5e7dec(0xc3)](_0x23d364))throw CliErrors[_0x5e7dec(0xb9)](_0x5e7dec(0xac)+_0x4bc78f+'\x22.\x20Allowed:\x20'+CONFIG_ENUM_VALUES[_0x4bc78f][_0x5e7dec(0xa6)](',\x20'));if(_0x4bc78f===_0x5e7dec(0xd2)&&!normalizeLocale(_0x23d364))throw CliErrors[_0x5e7dec(0xb9)](_0x5e7dec(0xd1),_0x5e7dec(0xba));const _0x486983={'global':_0x27c3c5['bool'](_0x5e7dec(0xc1))},_0xb89dcd=resolveWriteScope(_0x486983),_0x29771f=readScopedConfig(_0xb89dcd);let _0x1bae08=_0x4bc78f,_0x7ff5e8=_0x23d364;_0x4bc78f==='app'&&(_0x1bae08=_0x5e7dec(0xc2),delete _0x29771f[_0x5e7dec(0xcb)]);_0x4bc78f===_0x5e7dec(0xd2)&&(_0x7ff5e8=normalizeLocale(_0x23d364));if(_0x4bc78f==='env'){_0x7ff5e8=normalizeEnv(_0x23d364);if(!isProduction(_0x7ff5e8)&&!isDaily(_0x7ff5e8))throw CliErrors[_0x5e7dec(0xb9)]('Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.');}if(_0x4bc78f===_0x5e7dec(0xc2)){const _0x35458a=_0x29771f[_0x5e7dec(0xd6)]&&typeof _0x29771f[_0x5e7dec(0xd6)]===_0x5e7dec(0xbf)?Object[_0x5e7dec(0xb8)](_0x29771f[_0x5e7dec(0xd6)]):[];if(_0x35458a['length']>0x0)throw CliErrors[_0x5e7dec(0xb9)](_0x5e7dec(0xbc),_0x5e7dec(0xc0)+CLI_BIN_NAME+_0x5e7dec(0xc6)+_0x7ff5e8+_0x5e7dec(0xc5)+CLI_BIN_NAME+'\x20workspace\x20use\x20--app\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.');const _0x93ef25=buildCanonicalProjectConfig({..._0x29771f},{'appCodes':[_0x7ff5e8],'env':typeof _0x29771f[_0x5e7dec(0xc9)]==='string'?_0x29771f['env']:undefined});writeScopedConfig(_0x93ef25,_0xb89dcd);const _0x48d3d1=_0xb89dcd===_0x5e7dec(0xc1)?_0x5e7dec(0xc8):_0x5e7dec(0xa9);return{'ok':!![],'message':'✓\x20'+_0x48d3d1+_0x5e7dec(0xae)+_0x7ff5e8+_0x5e7dec(0xc7)};}_0x29771f[_0x1bae08]=_0x7ff5e8,writeScopedConfig(_0x29771f,_0xb89dcd);const _0x38c12b=_0xb89dcd===_0x5e7dec(0xc1)?_0x5e7dec(0xc8):'Project';return{'ok':!![],'message':'✓\x20'+_0x38c12b+'\x20'+_0x1bae08+_0x5e7dec(0xd5)+_0x7ff5e8};}export const configSetDefinition={'service':a53_0x344903(0xd4),'command':'set','description':a53_0x344903(0xb1),'risk':'write','requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a53_0x344903(0xa3),'type':a53_0x344903(0xc4),'description':getConfigCommandKeyDescription(),'required':!![]},{'name':a53_0x344903(0xb2),'type':a53_0x344903(0xc4),'description':a53_0x344903(0xd0),'required':!![]},{'name':a53_0x344903(0xc1),'type':a53_0x344903(0xbb),'description':'Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','default':![]}],'execute':execute};function a53_0x5810(){const _0x5d74e5=['\x20workspace\x20add\x20<name>\x20--appcode\x20','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','Global','env','77zPwJpK','app','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','str','14QmeQRE','Usage:\x20','Config\x20value','Invalid\x20locale\x20value.','locale','24740Oixlwm','config','\x20set\x20to:\x20','apps','key','630350CkbNMR','1163286tXybnr','join','24NBnptL','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','Project','1587882QzWFvo','22755811iNXZUO','Invalid\x20value\x20for\x20\x22','1136XhjXAB','\x20appcode\x20set\x20to:\x20','Missing\x20key.','Config\x20value\x20is\x20invalid\x20or\x20too\x20long.','Set\x20a\x20config\x20value','value','166EPpISE','2436846ApIhpC','length','9182xfYkzi','16xGThZM','keys','validation','Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US','boolean','Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.','Top-level\x20key\x20\x22','\x22\x20is\x20not\x20settable.','object','Use\x20`','global','appcode','includes','string','`,\x20`'];a53_0x5810=function(){return _0x5d74e5;};return a53_0x5810();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1f63e6,_0x4e3cfe){var _0x1758fc=a54_0x5c7d,_0x2a4a3e=_0x1f63e6();while(!![]){try{var _0x1d9215=parseInt(_0x1758fc(0x101))/0x1+parseInt(_0x1758fc(0xfe))/0x2+parseInt(_0x1758fc(0xfa))/0x3*(parseInt(_0x1758fc(0xf9))/0x4)+-parseInt(_0x1758fc(0xfc))/0x5+parseInt(_0x1758fc(0xf5))/0x6+parseInt(_0x1758fc(0xf6))/0x7*(parseInt(_0x1758fc(0x102))/0x8)+-parseInt(_0x1758fc(0x100))/0x9*(parseInt(_0x1758fc(0xfd))/0xa);if(_0x1d9215===_0x4e3cfe)break;else _0x2a4a3e['push'](_0x2a4a3e['shift']());}catch(_0x2c6a36){_0x2a4a3e['push'](_0x2a4a3e['shift']());}}}(a54_0x3c1f,0xeb0d2));import{CLI_BIN_NAME}from'../../constant/cli.js';import{isInProject,resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../../context.js';import{CliErrors}from'../../errors.js';function a54_0x3c1f(){var _0x457a97=['4855408yloMkA','Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','\x20init`\x20first.','3461286cGlIJA','7VSqsvO','validation','global','4TgdPic','1565913ypuRWs','project','7206175kswVoR','10FElDRr','786596DZCtzg','Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).','800910FTBdBi','393919rzrIiT'];a54_0x3c1f=function(){return _0x457a97;};return a54_0x3c1f();}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(_0x4a4481){var _0x3546c7=a54_0x5c7d;if(_0x4a4481[_0x3546c7(0xf8)])return _0x3546c7(0xf8);if(!isInProject())throw CliErrors[_0x3546c7(0xf7)](_0x3546c7(0xff),_0x3546c7(0x103)+CLI_BIN_NAME+_0x3546c7(0x104));return _0x3546c7(0xfb);}export function readScopedConfig(_0x45a448){return readConfigFile(resolveWriteConfigPath(_0x45a448));}function a54_0x5c7d(_0x3a6808,_0x3c92de){_0x3a6808=_0x3a6808-0xf5;var _0x3c1fd0=a54_0x3c1f();var _0x5c7d6d=_0x3c1fd0[_0x3a6808];return _0x5c7d6d;}export function writeScopedConfig(_0x17f013,_0x4016fa){writeConfigFile(resolveWriteConfigPath(_0x4016fa),_0x17f013);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a55_0x248709=a55_0x5305;function a55_0x5305(_0x59fd62,_0x49d43e){_0x59fd62=_0x59fd62-0xc5;const _0x28e392=a55_0x28e3();let _0x530552=_0x28e392[_0x59fd62];return _0x530552;}function a55_0x28e3(){const _0x1a57cd=['\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page','4312759YLHsgZ','Filter\x20dataset\x20records\x20with\x20query\x20conditions','50jXarLC','1115718lUiOTC','190143bgShrX','1069094MZAhps','join','3GEFQAT','filter','70316xHZOHO','\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','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','7ZEumPP','\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]','341945MLvDzM','2004184pnZsuT','32xgUHYq','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)'];a55_0x28e3=function(){return _0x1a57cd;};return a55_0x28e3();}(function(_0x91eef0,_0x2acac3){const _0x4ad2aa=a55_0x5305,_0x48aa67=_0x91eef0();while(!![]){try{const _0x1e1c28=-parseInt(_0x4ad2aa(0xd1))/0x1+parseInt(_0x4ad2aa(0xcd))/0x2*(-parseInt(_0x4ad2aa(0xcf))/0x3)+-parseInt(_0x4ad2aa(0xc5))/0x4*(-parseInt(_0x4ad2aa(0xd7))/0x5)+-parseInt(_0x4ad2aa(0xcb))/0x6*(parseInt(_0x4ad2aa(0xd5))/0x7)+parseInt(_0x4ad2aa(0xd8))/0x8+-parseInt(_0x4ad2aa(0xcc))/0x9*(parseInt(_0x4ad2aa(0xca))/0xa)+parseInt(_0x4ad2aa(0xc8))/0xb;if(_0x1e1c28===_0x2acac3)break;else _0x48aa67['push'](_0x48aa67['shift']());}catch(_0x27a40e){_0x48aa67['push'](_0x48aa67['shift']());}}}(a55_0x28e3,0x47985));import{buildDataCommand}from'../../commands/data/shared.js';export const dataFilter=buildDataCommand({'command':a55_0x248709(0xd0),'operation':a55_0x248709(0xd0),'description':a55_0x248709(0xc9),'paramsRequired':![],'paramsHint':a55_0x248709(0xd4),'helpExtra':[a55_0x248709(0xc6),a55_0x248709(0xd3),a55_0x248709(0xd6),'\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_0x248709(0xd2),a55_0x248709(0xc7)][a55_0x248709(0xce)]('\x0a')});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a56_0x2792(){const _0x5e5e83=['597258yVVUDb','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','1508090tcUvqz','3994278zXeXhM','40pwTkXf','2712108fQnMMF','633965TEvBgL','633622GElsls','32TxCcXD','1702882LBtljk','7cAYuIv'];a56_0x2792=function(){return _0x5e5e83;};return a56_0x2792();}const a56_0x438f81=a56_0x3525;(function(_0x70dbc,_0x2142ca){const _0x9d6262=a56_0x3525,_0x3e4ad6=_0x70dbc();while(!![]){try{const _0x533d05=parseInt(_0x9d6262(0x1a9))/0x1+parseInt(_0x9d6262(0x1ab))/0x2+parseInt(_0x9d6262(0x1a7))/0x3+-parseInt(_0x9d6262(0x1aa))/0x4*(parseInt(_0x9d6262(0x1a8))/0x5)+-parseInt(_0x9d6262(0x1a5))/0x6*(parseInt(_0x9d6262(0x1a1))/0x7)+parseInt(_0x9d6262(0x1a6))/0x8*(-parseInt(_0x9d6262(0x1a2))/0x9)+parseInt(_0x9d6262(0x1a4))/0xa;if(_0x533d05===_0x2142ca)break;else _0x3e4ad6['push'](_0x3e4ad6['shift']());}catch(_0x8e4982){_0x3e4ad6['push'](_0x3e4ad6['shift']());}}}(a56_0x2792,0x80ea9));function a56_0x3525(_0x59fdbe,_0x29a6cb){_0x59fdbe=_0x59fdbe-0x1a1;const _0x2792ac=a56_0x2792();let _0x35256a=_0x2792ac[_0x59fdbe];return _0x35256a;}import{buildDataCommand}from'../../commands/data/shared.js';export const dataGetOne=buildDataCommand({'command':'getOne','operation':'getOne','description':'Get\x20a\x20single\x20record\x20by\x20ID','paramsRequired':!![],'paramsHint':a56_0x438f81(0x1a3)});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a57_0x33ea(){const _0xffffa=['27VIKEwn','740244LQPqcx','1943780GuHFqW','6407422snoHaX','938383NRAySm','1751072EDzESL','2381478IbNErG','78984HYsenO','6eCDQWK'];a57_0x33ea=function(){return _0xffffa;};return a57_0x33ea();}(function(_0x31402e,_0x10c3fa){const _0x538eca=a57_0x3ee1,_0x54f2d7=_0x31402e();while(!![]){try{const _0x3abde3=parseInt(_0x538eca(0x15b))/0x1+-parseInt(_0x538eca(0x15d))/0x2+-parseInt(_0x538eca(0x156))/0x3*(parseInt(_0x538eca(0x15e))/0x4)+-parseInt(_0x538eca(0x159))/0x5+-parseInt(_0x538eca(0x158))/0x6+parseInt(_0x538eca(0x15a))/0x7+parseInt(_0x538eca(0x15c))/0x8*(parseInt(_0x538eca(0x157))/0x9);if(_0x3abde3===_0x10c3fa)break;else _0x54f2d7['push'](_0x54f2d7['shift']());}catch(_0xfaed8f){_0x54f2d7['push'](_0x54f2d7['shift']());}}}(a57_0x33ea,0xbb814));import{dataFilter}from'../../commands/data/filter.js';import{dataGetOne}from'../../commands/data/getOne.js';function a57_0x3ee1(_0x1911c7,_0x4e98bb){_0x1911c7=_0x1911c7-0x156;const _0x33ea5f=a57_0x33ea();let _0x3ee108=_0x33ea5f[_0x1911c7];return _0x3ee108;}export const dataDefinitions=[dataFilter,dataGetOne];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1dc8ea,_0x7b2ecf){const _0x5e25e7=a58_0x3454,_0xeca77b=_0x1dc8ea();while(!![]){try{const _0x1c6a39=parseInt(_0x5e25e7(0x1b1))/0x1+parseInt(_0x5e25e7(0x19a))/0x2+-parseInt(_0x5e25e7(0x199))/0x3+-parseInt(_0x5e25e7(0x1a2))/0x4*(-parseInt(_0x5e25e7(0x193))/0x5)+-parseInt(_0x5e25e7(0x1a6))/0x6*(-parseInt(_0x5e25e7(0x1b3))/0x7)+parseInt(_0x5e25e7(0x1b0))/0x8+parseInt(_0x5e25e7(0x1ac))/0x9*(-parseInt(_0x5e25e7(0x196))/0xa);if(_0x1c6a39===_0x7b2ecf)break;else _0xeca77b['push'](_0xeca77b['shift']());}catch(_0x28aa58){_0xeca77b['push'](_0xeca77b['shift']());}}}(a58_0x15c6,0x59d2d));import{executeDatasetDataOperation}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';function a58_0x15c6(){const _0x5479dc=['read','2724UlTthe','paramsRequired','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','operation','appCode','data','14286141NWiyAn','data\x20','code','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','633688TUervB','431393jGaLpT','data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params','4739iRPUmQ','10dzjWRa','description','flagMissing','10TrNFop','command','string','371724GoNkAb','1274972qVTYcR','getOne','compress','\x20completed\x20in\x20','str','helpExtra','params','now','1247452TNetUy','paramsHint','alias'];a58_0x15c6=function(){return _0x5479dc;};return a58_0x15c6();}import{parseJsonParams}from'../../utils/params.js';function assertGetOneId(_0x339009){const _0x14c7b8=a58_0x3454;if(!_0x339009)throw CliErrors[_0x14c7b8(0x195)](_0x14c7b8(0x1a0),'Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.');const _0x3f37e3=_0x339009['id'];if(_0x3f37e3===undefined||_0x3f37e3===null||_0x3f37e3==='')throw CliErrors['validation'](_0x14c7b8(0x1b2),_0x14c7b8(0x1a8));}function a58_0x3454(_0x45b313,_0x52148a){_0x45b313=_0x45b313-0x193;const _0x15c607=a58_0x15c6();let _0x34540c=_0x15c607[_0x45b313];return _0x34540c;}function parseCommandParams(_0x3465af){return parseJsonParams(_0x3465af)??{};}export function buildDataCommand(_0x28658d){const _0xfe322c=a58_0x3454,_0x186b7b=_0xfe322c(0x1af);return{'service':_0xfe322c(0x1ab),'command':_0x28658d[_0xfe322c(0x197)],'description':_0x28658d[_0xfe322c(0x194)],'risk':_0xfe322c(0x1a5),'defaultOutputFormat':_0xfe322c(0x19c),'helpExtra':_0x28658d[_0xfe322c(0x19f)],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0xfe322c(0x1a4),'type':_0xfe322c(0x198),'description':_0x186b7b},{'name':_0xfe322c(0x1a0),'type':_0xfe322c(0x198),'description':_0x28658d[_0xfe322c(0x1a3)]}],async 'validate'(_0x1dc63d){const _0x286bb7=_0xfe322c,_0x450543=_0x1dc63d[_0x286bb7(0x19e)](_0x286bb7(0x1a0));if(_0x28658d[_0x286bb7(0x1a7)]&&!_0x450543)throw CliErrors[_0x286bb7(0x195)](_0x286bb7(0x1a0),_0x28658d[_0x286bb7(0x1a3)]);const _0x586a00=parseJsonParams(_0x450543);_0x28658d[_0x286bb7(0x1a9)]===_0x286bb7(0x19b)&&assertGetOneId(_0x586a00);},async 'execute'(_0x5c5c73){const _0x28caae=_0xfe322c,_0x4d2602=parseCommandParams(_0x5c5c73['str'](_0x28caae(0x1a0))),_0x59a9e4=Date[_0x28caae(0x1a1)](),_0xb8c492=await executeDatasetDataOperation(_0x5c5c73[_0x28caae(0x1aa)],_0x5c5c73[_0x28caae(0x19e)](_0x28caae(0x1ae)),_0x28658d['operation'],_0x4d2602),_0x358b38=Date[_0x28caae(0x1a1)]()-_0x59a9e4;return{'ok':!![],'data':{'result':_0xb8c492,'elapsed':_0x358b38},'message':_0x28caae(0x1ad)+_0x28658d['command']+_0x28caae(0x19d)+_0x358b38+'ms'};}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a59_0x218fa2=a59_0x35f2;(function(_0x214ac5,_0xbc3b5a){const _0x5e4c43=a59_0x35f2,_0x1c7d21=_0x214ac5();while(!![]){try{const _0xb8eda0=-parseInt(_0x5e4c43(0x135))/0x1*(parseInt(_0x5e4c43(0x130))/0x2)+parseInt(_0x5e4c43(0x120))/0x3+parseInt(_0x5e4c43(0x113))/0x4*(parseInt(_0x5e4c43(0x124))/0x5)+-parseInt(_0x5e4c43(0x12b))/0x6+-parseInt(_0x5e4c43(0x108))/0x7+parseInt(_0x5e4c43(0xfd))/0x8*(parseInt(_0x5e4c43(0x11f))/0x9)+parseInt(_0x5e4c43(0x132))/0xa;if(_0xb8eda0===_0xbc3b5a)break;else _0x1c7d21['push'](_0x1c7d21['shift']());}catch(_0x53caab){_0x1c7d21['push'](_0x1c7d21['shift']());}}}(a59_0x559d,0xa720f));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='/smartapi/question/er-config/business-group/edit';export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x42e045,input:_0x5a947d,dryRun:_0x3498f3}){const _0x51c900=a59_0x35f2;validateInput(_0x5a947d);const _0x248fe3=normalizeBusinessGroup(_0x5a947d[_0x51c900(0x122)]),_0x37ec5b=await getDatasetDetail(_0x5a947d[_0x51c900(0x125)]),_0x2ad6d6=resolveBusinessGroupDataset(_0x37ec5b,_0x5a947d['code']),_0x2b7c0e=loadCurrentBusinessGroup(_0x37ec5b,_0x2ad6d6);assertExpectedBusinessGroup(_0x2b7c0e,_0x5a947d['expectBusinessGroup']);const _0x36ad98=buildBackendPayload(_0x42e045,_0x2ad6d6,_0x248fe3),_0x186cf4=_0x2b7c0e!==_0x248fe3;let _0x393453;if(_0x186cf4&&!_0x3498f3){await updateErBusinessGroup(_0x36ad98);const _0x411f01=await getDatasetDetail(_0x2ad6d6['code']),_0x307a75=resolveBusinessGroupDataset(_0x411f01,_0x2ad6d6[_0x51c900(0x125)]),_0x5eeda5=loadCurrentBusinessGroup(_0x411f01,_0x307a75);if(_0x5eeda5!==_0x248fe3)throw CliErrors['apiError']('Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.',_0x51c900(0x126)+JSON[_0x51c900(0x112)](_0x248fe3)+',\x20actual\x20'+JSON[_0x51c900(0x112)](_0x5eeda5)+'.');_0x393453={'verified':!![],'status':_0x51c900(0x11c),'afterReadback':{'businessGroup':_0x5eeda5}};}else!_0x186cf4&&(_0x393453={'verified':!![],'status':_0x51c900(0x133),'afterReadback':{'businessGroup':_0x2b7c0e}});const _0x2df0d7={'operation':_0x51c900(0x10d),'appCode':_0x42e045,'selector':{'code':_0x2ad6d6['code']},'dataset':_0x2ad6d6,'before':{'businessGroup':_0x2b7c0e},'after':{'businessGroup':_0x248fe3},'changed':_0x186cf4,'dryRun':_0x3498f3,'submitted':_0x186cf4&&!_0x3498f3,'backend':{'method':_0x51c900(0xff),'path':BACKEND_PATH,'payload':_0x36ad98},..._0x393453?{'verification':_0x393453}:{},'warnings':[]};return{'ok':!![],'data':_0x2df0d7,'message':_0x186cf4?_0x3498f3?_0x51c900(0x12c)+_0x2ad6d6[_0x51c900(0x125)]:'Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20'+_0x2ad6d6[_0x51c900(0x125)]:_0x51c900(0x11d)+_0x2ad6d6[_0x51c900(0x125)]};}export const datasetBusinessGroupUpdate={'service':a59_0x218fa2(0x106),'command':a59_0x218fa2(0xfe),'description':a59_0x218fa2(0x12e),'risk':a59_0x218fa2(0x103),'flags':[CODE_FLAG,{'name':a59_0x218fa2(0x100),'type':a59_0x218fa2(0x117),'required':!![],'description':a59_0x218fa2(0x10b)},{'name':a59_0x218fa2(0x11b),'type':a59_0x218fa2(0x117),'required':![],'description':'Expected\x20current\x20business\x20scenario\x20group;\x20mismatch\x20aborts\x20without\x20writing'},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x1cba5f){validateInput(readBusinessGroupUpdateInput(_0x1cba5f));},async 'dryRun'(_0x2a6317){const _0x2d0ae4=a59_0x218fa2,_0x3cf108=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x2a6317[_0x2d0ae4(0x119)],'input':readBusinessGroupUpdateInput(_0x2a6317),'dryRun':!![]});return{'method':_0x2d0ae4(0xff),'url':BACKEND_PATH,'body':_0x3cf108[_0x2d0ae4(0xfa)][_0x2d0ae4(0x107)]['payload'],'description':_0x3cf108[_0x2d0ae4(0x121)],..._0x3cf108[_0x2d0ae4(0xfa)]};},async 'execute'(_0x32c2e3){const _0x135d0b=a59_0x218fa2;return buildDatasetBusinessGroupUpdateResult({'appCode':_0x32c2e3[_0x135d0b(0x119)],'input':readBusinessGroupUpdateInput(_0x32c2e3),'dryRun':![]});}};function a59_0x559d(){const _0x23f9b8=['expect-business-group','matched','No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20','modelCode','5402610jCZpAP','2619585Ukqgby','message','businessGroup','length','35CJOrZg','code','Expected\x20','isFinite','parse','sourceType','object','3614052qhOIBW','Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20','source','Update\x20business\x20scenario\x20group','prototype','5290yhdckQ','name','16373150pJsXMS','unchanged','keys','237TWPExI','datasetId','data','extend','toUpperCase','8SnwJeM','business-group-update','POST','business-group','trim','found','write','modelId','validation','dataset','backend','9281475TwSrnq','Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.','isArray','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','str','update','--code\x20is\x20required','DB_TABLE','number',',\x20actual\x20','stringify','73652UEKgOu','METADATA','Expectation\x20mismatch\x20at\x20businessGroup','value','string','hasOwnProperty','appCode','--business-group\x20is\x20required'];a59_0x559d=function(){return _0x23f9b8;};return a59_0x559d();}function readBusinessGroupUpdateInput(_0x1559af){const _0x13d97a=a59_0x218fa2,_0x31e3ea=_0x1559af[_0x13d97a(0x10c)](_0x13d97a(0x11b));return{'code':trim(_0x1559af['str'](_0x13d97a(0x125))),'businessGroup':_0x1559af['str'](_0x13d97a(0x100)),'expectBusinessGroup':_0x31e3ea===undefined||_0x31e3ea===''?undefined:_0x31e3ea};}function validateInput(_0x3e7b87){const _0xb3e6e=a59_0x218fa2;if(!trim(_0x3e7b87['code']))throw CliErrors[_0xb3e6e(0x105)](_0xb3e6e(0x10e));if(_0x3e7b87['businessGroup']===undefined)throw CliErrors[_0xb3e6e(0x105)](_0xb3e6e(0x11a));}function resolveBusinessGroupDataset(_0x1ac4a1,_0x1ba937){const _0x583d3c=a59_0x218fa2,_0x37c1a2=asPlainObject(_0x1ac4a1[_0x583d3c(0x106)]),_0x1ffed6=asPlainObject(_0x1ac4a1['dbtableConfig']),_0x4850f5=resolveSourceType(_0x1ac4a1,_0x37c1a2,_0x1ffed6),_0x3c40fa=firstString(_0x1ac4a1[_0x583d3c(0x11e)],_0x1ac4a1['code'],_0x37c1a2['datasetCode'],_0x1ba937)||_0x1ba937;return{'id':firstNumber(_0x1ac4a1[_0x583d3c(0x104)],_0x1ac4a1['id'],_0x37c1a2[_0x583d3c(0xf9)])??firstString(_0x1ac4a1['modelId'],_0x1ac4a1['id'],_0x37c1a2[_0x583d3c(0xf9)])??null,'code':_0x3c40fa,'name':firstString(_0x1ac4a1[_0x583d3c(0x131)],_0x37c1a2['datasetName'],_0x37c1a2[_0x583d3c(0x131)])||null,'sourceType':_0x4850f5};}function resolveSourceType(_0x53b3d4,_0x38dcba,_0x555ba6){const _0x14a265=a59_0x218fa2,_0x441a08=firstString(_0x53b3d4['source'],_0x53b3d4[_0x14a265(0x129)],_0x38dcba[_0x14a265(0x12d)],_0x38dcba[_0x14a265(0x129)])?.[_0x14a265(0x101)]()[_0x14a265(0xfc)]();if(_0x441a08==='DB_TABLE'||_0x441a08==='METADATA')return _0x441a08;if(Object[_0x14a265(0x134)](_0x555ba6)[_0x14a265(0x123)]>0x0)return _0x14a265(0x10f);throw CliErrors[_0x14a265(0x105)](_0x14a265(0x109));}function loadCurrentBusinessGroup(_0xbb6145,_0x534503){const _0x530b04=a59_0x218fa2,_0x56ab55=readBusinessGroupFromDatasetDetail(_0xbb6145,_0x534503['sourceType']);if(_0x56ab55[_0x530b04(0x102)])return normalizeBusinessGroup(_0x56ab55[_0x530b04(0x116)]);if(_0x534503[_0x530b04(0x129)]===_0x530b04(0x114))return'';throw CliErrors[_0x530b04(0x105)]('Dataset\x20detail\x20does\x20not\x20expose\x20businessGroup.','Business\x20scenario\x20group\x20readback\x20must\x20be\x20available\x20by\x20datasetCode;\x20upgrade\x20the\x20backend\x20read\x20contract\x20instead\x20of\x20using\x20dblinkId/tableName.');}function readBusinessGroupFromDatasetDetail(_0x24e854,_0x1bcbcf){const _0x37038f=a59_0x218fa2,_0x522ec5=asPlainObject(_0x24e854[_0x37038f(0x106)]),_0x5e1e6c=firstPresent(_0x24e854[_0x37038f(0x122)]);if(_0x5e1e6c[_0x37038f(0x102)])return _0x5e1e6c;const _0x157781=firstPresent(_0x522ec5[_0x37038f(0x122)]);if(_0x157781['found'])return _0x157781;if(_0x1bcbcf===_0x37038f(0x10f))return{'found':![]};const _0x5e5b9c=readBusinessGroupFromExtend(_0x24e854[_0x37038f(0xfb)]);if(_0x5e5b9c[_0x37038f(0x102)])return _0x5e5b9c;return readBusinessGroupFromExtend(_0x522ec5[_0x37038f(0xfb)]);}function readBusinessGroupFromExtend(_0x2d1031){const _0x2984eb=a59_0x218fa2;if(_0x2d1031===undefined||_0x2d1031===null||_0x2d1031==='')return{'found':![]};if(typeof _0x2d1031===_0x2984eb(0x117))try{const _0x100e98=JSON[_0x2984eb(0x128)](_0x2d1031);return readBusinessGroupFromExtend(_0x100e98);}catch{return{'found':![]};}const _0x32ed30=asPlainObject(_0x2d1031);if(Object[_0x2984eb(0x12f)][_0x2984eb(0x118)]['call'](_0x32ed30,'businessGroup'))return{'found':!![],'value':_0x32ed30[_0x2984eb(0x122)]};return{'found':![]};}function firstPresent(..._0x30c8e3){for(const _0x25ce35 of _0x30c8e3){if(_0x25ce35!==undefined&&_0x25ce35!==null)return{'found':!![],'value':_0x25ce35};}return{'found':![]};}function a59_0x35f2(_0x58c1f9,_0x2bc76c){_0x58c1f9=_0x58c1f9-0xf9;const _0x559d5f=a59_0x559d();let _0x35f209=_0x559d5f[_0x58c1f9];return _0x35f209;}function assertExpectedBusinessGroup(_0x112a1b,_0x28d5b1){const _0x5e15af=a59_0x218fa2;if(_0x28d5b1===undefined)return;const _0x11d9d1=normalizeBusinessGroup(_0x28d5b1);if(_0x112a1b!==_0x11d9d1)throw CliErrors[_0x5e15af(0x105)](_0x5e15af(0x115),'Expected\x20'+JSON[_0x5e15af(0x112)](_0x11d9d1)+_0x5e15af(0x111)+JSON[_0x5e15af(0x112)](_0x112a1b));}function buildBackendPayload(_0x1615cf,_0x11235,_0x131e6c){const _0x4af0fc=a59_0x218fa2;return{'appCode':_0x1615cf,'datasetCode':_0x11235[_0x4af0fc(0x125)],'businessGroup':_0x131e6c};}function normalizeBusinessGroup(_0x4a1cd6){const _0x25c3a3=a59_0x218fa2;if(_0x4a1cd6===undefined||_0x4a1cd6===null)return'';return String(_0x4a1cd6)[_0x25c3a3(0x101)]();}function asPlainObject(_0x2a032c){const _0xe5ba0f=a59_0x218fa2;if(!_0x2a032c||typeof _0x2a032c!==_0xe5ba0f(0x12a)||Array[_0xe5ba0f(0x10a)](_0x2a032c))return{};return _0x2a032c;}function firstString(..._0x30bad0){const _0xe09902=a59_0x218fa2;for(const _0x85bf22 of _0x30bad0){if(typeof _0x85bf22===_0xe09902(0x117)&&_0x85bf22['trim']())return _0x85bf22[_0xe09902(0x101)]();if(typeof _0x85bf22===_0xe09902(0x110)&&Number[_0xe09902(0x127)](_0x85bf22))return String(_0x85bf22);}return undefined;}function firstNumber(..._0x927fdd){const _0x4f5a0e=a59_0x218fa2;for(const _0x3bd1fd of _0x927fdd){if(typeof _0x3bd1fd===_0x4f5a0e(0x110)&&Number[_0x4f5a0e(0x127)](_0x3bd1fd))return _0x3bd1fd;if(typeof _0x3bd1fd==='string'&&_0x3bd1fd['trim']()&&Number[_0x4f5a0e(0x127)](Number(_0x3bd1fd)))return Number(_0x3bd1fd);}return null;}function trim(_0x20d9c8){const _0x2430b5=a59_0x218fa2;return String(_0x20d9c8||'')[_0x2430b5(0x101)]();}
|
|
1
|
+
const a59_0x296f38=a59_0x3da9;(function(_0x33b2c6,_0xbf6302){const _0x5730a3=a59_0x3da9,_0x4c84fc=_0x33b2c6();while(!![]){try{const _0x426fe0=parseInt(_0x5730a3(0xb8))/0x1*(-parseInt(_0x5730a3(0x91))/0x2)+-parseInt(_0x5730a3(0x88))/0x3+parseInt(_0x5730a3(0xad))/0x4*(-parseInt(_0x5730a3(0xb3))/0x5)+-parseInt(_0x5730a3(0xb1))/0x6*(-parseInt(_0x5730a3(0x87))/0x7)+parseInt(_0x5730a3(0x8a))/0x8+-parseInt(_0x5730a3(0x86))/0x9+parseInt(_0x5730a3(0xab))/0xa;if(_0x426fe0===_0xbf6302)break;else _0x4c84fc['push'](_0x4c84fc['shift']());}catch(_0x1b2580){_0x4c84fc['push'](_0x4c84fc['shift']());}}}(a59_0x2715,0x83a8d));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_0x296f38(0xaf);function a59_0x3da9(_0x35b484,_0x6da3a3){_0x35b484=_0x35b484-0x83;const _0x2715b7=a59_0x2715();let _0x3da985=_0x2715b7[_0x35b484];return _0x3da985;}export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x1ea386,input:_0x3c7e8f,dryRun:_0xa49763}){const _0x40bf38=a59_0x296f38;validateInput(_0x3c7e8f);const _0x30be59=normalizeBusinessGroup(_0x3c7e8f['businessGroup']),_0x4b5686=await getDatasetDetail(_0x3c7e8f[_0x40bf38(0x9e)]),_0x49a8bb=resolveBusinessGroupDataset(_0x4b5686,_0x3c7e8f[_0x40bf38(0x9e)]),_0x61bccb=loadCurrentBusinessGroup(_0x4b5686,_0x49a8bb);assertExpectedBusinessGroup(_0x61bccb,_0x3c7e8f[_0x40bf38(0x89)]);const _0x216cbe=buildBackendPayload(_0x1ea386,_0x49a8bb,_0x30be59),_0x4ca0b6=_0x61bccb!==_0x30be59;let _0x14e173;if(_0x4ca0b6&&!_0xa49763){await updateErBusinessGroup(_0x216cbe);const _0x2fd053=await getDatasetDetail(_0x49a8bb['code']),_0x810d19=resolveBusinessGroupDataset(_0x2fd053,_0x49a8bb[_0x40bf38(0x9e)]),_0x44504c=loadCurrentBusinessGroup(_0x2fd053,_0x810d19);if(_0x44504c!==_0x30be59)throw CliErrors[_0x40bf38(0xb2)](_0x40bf38(0x94),_0x40bf38(0x9a)+JSON[_0x40bf38(0xb6)](_0x30be59)+_0x40bf38(0xb4)+JSON[_0x40bf38(0xb6)](_0x44504c)+'.');_0x14e173={'verified':!![],'status':_0x40bf38(0x9c),'afterReadback':{'businessGroup':_0x44504c}};}else!_0x4ca0b6&&(_0x14e173={'verified':!![],'status':_0x40bf38(0x9f),'afterReadback':{'businessGroup':_0x61bccb}});const _0x5d9f33={'operation':'update','appCode':_0x1ea386,'selector':{'code':_0x49a8bb[_0x40bf38(0x9e)]},'dataset':_0x49a8bb,'before':{'businessGroup':_0x61bccb},'after':{'businessGroup':_0x30be59},'changed':_0x4ca0b6,'dryRun':_0xa49763,'submitted':_0x4ca0b6&&!_0xa49763,'backend':{'method':_0x40bf38(0xa6),'path':BACKEND_PATH,'payload':_0x216cbe},..._0x14e173?{'verification':_0x14e173}:{},'warnings':[]};return{'ok':!![],'data':_0x5d9f33,'message':_0x4ca0b6?_0xa49763?_0x40bf38(0xa2)+_0x49a8bb[_0x40bf38(0x9e)]:_0x40bf38(0x96)+_0x49a8bb[_0x40bf38(0x9e)]:_0x40bf38(0xb7)+_0x49a8bb[_0x40bf38(0x9e)]};}export const datasetBusinessGroupUpdate={'service':a59_0x296f38(0x85),'command':'business-group-update','description':a59_0x296f38(0x8d),'risk':a59_0x296f38(0x90),'flags':[CODE_FLAG,{'name':a59_0x296f38(0xb9),'type':a59_0x296f38(0xc0),'required':!![],'description':a59_0x296f38(0x8c)},{'name':'expect-business-group','type':a59_0x296f38(0xc0),'required':![],'description':'Expected\x20current\x20business\x20scenario\x20group;\x20mismatch\x20aborts\x20without\x20writing'},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x45e369){validateInput(readBusinessGroupUpdateInput(_0x45e369));},async 'dryRun'(_0x3af9ee){const _0xd2b1e6=a59_0x296f38,_0x4a5212=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x3af9ee[_0xd2b1e6(0x8b)],'input':readBusinessGroupUpdateInput(_0x3af9ee),'dryRun':!![]});return{'method':_0xd2b1e6(0xa6),'url':BACKEND_PATH,'body':_0x4a5212[_0xd2b1e6(0xbc)][_0xd2b1e6(0xb0)][_0xd2b1e6(0x97)],'description':_0x4a5212['message'],..._0x4a5212[_0xd2b1e6(0xbc)]};},async 'execute'(_0x5c9b99){const _0x2b23bb=a59_0x296f38;return buildDatasetBusinessGroupUpdateResult({'appCode':_0x5c9b99[_0x2b23bb(0x8b)],'input':readBusinessGroupUpdateInput(_0x5c9b99),'dryRun':![]});}};function readBusinessGroupUpdateInput(_0x574a73){const _0x3118f9=a59_0x296f38,_0x4bf807=_0x574a73['str'](_0x3118f9(0xa0));return{'code':trim(_0x574a73[_0x3118f9(0xa7)]('code')),'businessGroup':_0x574a73['str'](_0x3118f9(0xb9)),'expectBusinessGroup':_0x4bf807===undefined||_0x4bf807===''?undefined:_0x4bf807};}function validateInput(_0x4a97ce){const _0x7320a2=a59_0x296f38;if(!trim(_0x4a97ce[_0x7320a2(0x9e)]))throw CliErrors[_0x7320a2(0xa5)]('--code\x20is\x20required');if(_0x4a97ce['businessGroup']===undefined)throw CliErrors[_0x7320a2(0xa5)]('--business-group\x20is\x20required');}function resolveBusinessGroupDataset(_0x1bb8d4,_0x1561e1){const _0xec4889=a59_0x296f38,_0x368091=asPlainObject(_0x1bb8d4[_0xec4889(0x85)]),_0x7dd222=asPlainObject(_0x1bb8d4[_0xec4889(0xb5)]),_0xfa3141=resolveSourceType(_0x1bb8d4,_0x368091,_0x7dd222),_0x4befbb=firstString(_0x1bb8d4[_0xec4889(0xbd)],_0x1bb8d4[_0xec4889(0x9e)],_0x368091[_0xec4889(0xa4)],_0x1561e1)||_0x1561e1;return{'id':firstNumber(_0x1bb8d4[_0xec4889(0x9d)],_0x1bb8d4['id'],_0x368091[_0xec4889(0x84)])??firstString(_0x1bb8d4[_0xec4889(0x9d)],_0x1bb8d4['id'],_0x368091[_0xec4889(0x84)])??null,'code':_0x4befbb,'name':firstString(_0x1bb8d4[_0xec4889(0x92)],_0x368091['datasetName'],_0x368091['name'])||null,'sourceType':_0xfa3141};}function resolveSourceType(_0x2f5966,_0x110971,_0x5ddfc2){const _0x391844=a59_0x296f38,_0xff419f=firstString(_0x2f5966[_0x391844(0xba)],_0x2f5966[_0x391844(0x8e)],_0x110971[_0x391844(0xba)],_0x110971[_0x391844(0x8e)])?.[_0x391844(0x99)]()[_0x391844(0xa1)]();if(_0xff419f==='DB_TABLE'||_0xff419f===_0x391844(0xbe))return _0xff419f;if(Object[_0x391844(0x93)](_0x5ddfc2)[_0x391844(0xac)]>0x0)return _0x391844(0xae);throw CliErrors[_0x391844(0xa5)]('Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.');}function loadCurrentBusinessGroup(_0x46f1fe,_0x490fdf){const _0x3ae9ff=a59_0x296f38,_0x3e4f79=readBusinessGroupFromDatasetDetail(_0x46f1fe,_0x490fdf['sourceType']);if(_0x3e4f79[_0x3ae9ff(0xa8)])return normalizeBusinessGroup(_0x3e4f79[_0x3ae9ff(0xa3)]);if(_0x490fdf[_0x3ae9ff(0x8e)]===_0x3ae9ff(0xbe))return'';throw CliErrors[_0x3ae9ff(0xa5)]('Dataset\x20detail\x20does\x20not\x20expose\x20businessGroup.','Business\x20scenario\x20group\x20readback\x20must\x20be\x20available\x20by\x20datasetCode;\x20upgrade\x20the\x20backend\x20read\x20contract\x20instead\x20of\x20using\x20dblinkId/tableName.');}function readBusinessGroupFromDatasetDetail(_0x251c01,_0x356521){const _0x3ca290=a59_0x296f38,_0xcfb668=asPlainObject(_0x251c01[_0x3ca290(0x85)]),_0x4fb367=firstPresent(_0x251c01[_0x3ca290(0x83)]);if(_0x4fb367['found'])return _0x4fb367;const _0x6031f=firstPresent(_0xcfb668[_0x3ca290(0x83)]);if(_0x6031f[_0x3ca290(0xa8)])return _0x6031f;if(_0x356521===_0x3ca290(0xae))return{'found':![]};const _0x30f57e=readBusinessGroupFromExtend(_0x251c01[_0x3ca290(0x8f)]);if(_0x30f57e[_0x3ca290(0xa8)])return _0x30f57e;return readBusinessGroupFromExtend(_0xcfb668[_0x3ca290(0x8f)]);}function readBusinessGroupFromExtend(_0xf0cdfe){const _0x5ec3aa=a59_0x296f38;if(_0xf0cdfe===undefined||_0xf0cdfe===null||_0xf0cdfe==='')return{'found':![]};if(typeof _0xf0cdfe===_0x5ec3aa(0xc0))try{const _0x2c3c0f=JSON[_0x5ec3aa(0xa9)](_0xf0cdfe);return readBusinessGroupFromExtend(_0x2c3c0f);}catch{return{'found':![]};}const _0x131d9a=asPlainObject(_0xf0cdfe);if(Object['prototype'][_0x5ec3aa(0xaa)]['call'](_0x131d9a,_0x5ec3aa(0x83)))return{'found':!![],'value':_0x131d9a[_0x5ec3aa(0x83)]};return{'found':![]};}function firstPresent(..._0x34cbab){for(const _0x35319f of _0x34cbab){if(_0x35319f!==undefined&&_0x35319f!==null)return{'found':!![],'value':_0x35319f};}return{'found':![]};}function assertExpectedBusinessGroup(_0x49a460,_0x27fb9c){const _0x160f37=a59_0x296f38;if(_0x27fb9c===undefined)return;const _0x79746e=normalizeBusinessGroup(_0x27fb9c);if(_0x49a460!==_0x79746e)throw CliErrors[_0x160f37(0xa5)](_0x160f37(0x98),_0x160f37(0x9a)+JSON['stringify'](_0x79746e)+_0x160f37(0xb4)+JSON[_0x160f37(0xb6)](_0x49a460));}function buildBackendPayload(_0x1ed4d0,_0x2d624a,_0xf88ab3){const _0xd19137=a59_0x296f38;return{'appCode':_0x1ed4d0,'datasetCode':_0x2d624a[_0xd19137(0x9e)],'businessGroup':_0xf88ab3};}function normalizeBusinessGroup(_0x587317){const _0x5dd0e7=a59_0x296f38;if(_0x587317===undefined||_0x587317===null)return'';return String(_0x587317)[_0x5dd0e7(0x99)]();}function asPlainObject(_0x849fec){const _0x116c20=a59_0x296f38;if(!_0x849fec||typeof _0x849fec!==_0x116c20(0xbf)||Array[_0x116c20(0x9b)](_0x849fec))return{};return _0x849fec;}function firstString(..._0x51bdd0){const _0x41f083=a59_0x296f38;for(const _0x269cc7 of _0x51bdd0){if(typeof _0x269cc7===_0x41f083(0xc0)&&_0x269cc7['trim']())return _0x269cc7[_0x41f083(0x99)]();if(typeof _0x269cc7==='number'&&Number[_0x41f083(0x95)](_0x269cc7))return String(_0x269cc7);}return undefined;}function firstNumber(..._0x36868d){const _0x425ca5=a59_0x296f38;for(const _0x287bfe of _0x36868d){if(typeof _0x287bfe===_0x425ca5(0xbb)&&Number[_0x425ca5(0x95)](_0x287bfe))return _0x287bfe;if(typeof _0x287bfe==='string'&&_0x287bfe[_0x425ca5(0x99)]()&&Number['isFinite'](Number(_0x287bfe)))return Number(_0x287bfe);}return null;}function a59_0x2715(){const _0x184af8=['/smartapi/question/er-config/business-group/edit','backend','6bDnAex','apiError','1145tVgwKZ',',\x20actual\x20','dbtableConfig','stringify','No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20','437739fOESjQ','business-group','source','number','data','modelCode','METADATA','object','string','businessGroup','datasetId','dataset','5549751ftSqis','6511225jCjFGC','1465095dEQgVB','expectBusinessGroup','5046016BnMtBA','appCode','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','Update\x20business\x20scenario\x20group','sourceType','extend','write','2Jydany','name','keys','Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.','isFinite','Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20','payload','Expectation\x20mismatch\x20at\x20businessGroup','trim','Expected\x20','isArray','matched','modelId','code','unchanged','expect-business-group','toUpperCase','Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20','value','datasetCode','validation','POST','str','found','parse','hasOwnProperty','13184710hPLGSM','length','13928PZuUNw','DB_TABLE'];a59_0x2715=function(){return _0x184af8;};return a59_0x2715();}function trim(_0x42ee48){const _0x18ea8e=a59_0x296f38;return String(_0x42ee48||'')[_0x18ea8e(0x99)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a60_0x4a9520=a60_0x5dc3;(function(_0x576397,_0x1591f2){const _0x24bf4b=a60_0x5dc3,_0x587717=_0x576397();while(!![]){try{const _0x523b4c=-parseInt(_0x24bf4b(0x1c4))/0x1+parseInt(_0x24bf4b(0x1bb))/0x2*(-parseInt(_0x24bf4b(0x1c3))/0x3)+parseInt(_0x24bf4b(0x1bc))/0x4*(-parseInt(_0x24bf4b(0x1ca))/0x5)+-parseInt(_0x24bf4b(0x1c1))/0x6*(-parseInt(_0x24bf4b(0x1c5))/0x7)+-parseInt(_0x24bf4b(0x1cc))/0x8+parseInt(_0x24bf4b(0x1c6))/0x9*(-parseInt(_0x24bf4b(0x1b8))/0xa)+parseInt(_0x24bf4b(0x1ba))/0xb*(parseInt(_0x24bf4b(0x1c8))/0xc);if(_0x523b4c===_0x1591f2)break;else _0x587717['push'](_0x587717['shift']());}catch(_0x2d9fb4){_0x587717['push'](_0x587717['shift']());}}}(a60_0x3b42,0x33d65));function a60_0x5dc3(_0x14fbb1,_0x14f7ef){_0x14fbb1=_0x14fbb1-0x1b7;const _0x3b42af=a60_0x3b42();let _0x5dc3c8=_0x3b42af[_0x14fbb1];return _0x5dc3c8;}import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getErBusinessGroupSummary}from'../../core/api-client.js';function a60_0x3b42(){const _0x4aa18e=['length','750KBKTNu','128774kqIIgH','7jbsoRc','54SnQCsE','\x20business\x20group(s)\x20for\x20database\x20connection\x20','108FSQAhc','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','5risFcg','num','762400bQiApX','dbid','364790JCLCUj','Found\x20','1019909dCfRma','1300HlvobO','1254868jhIBmF','number','appCode','groups','dataset','1782114YBPxsl'];a60_0x3b42=function(){return _0x4aa18e;};return a60_0x3b42();}export const datasetBusinessGroups={'service':a60_0x4a9520(0x1c0),'command':'business-groups','description':'List\x20DB_TABLE\x20dataset\x20business\x20groups\x20for\x20a\x20database\x20connection;\x20does\x20not\x20include\x20METADATA','risk':'read','flags':[{'name':'dbid','type':a60_0x4a9520(0x1bd),'required':!![],'description':a60_0x4a9520(0x1c9)},APPCODE_FLAG_OPTIONAL],async 'execute'(_0x1e81eb){const _0x561d1b=a60_0x4a9520,_0x2caed3=_0x1e81eb[_0x561d1b(0x1cb)](_0x561d1b(0x1b7)),_0x4b6165=await getErBusinessGroupSummary(_0x1e81eb[_0x561d1b(0x1be)],_0x2caed3);return{'ok':!![],'data':{..._0x4b6165,'scope':'DB_TABLE'},'message':_0x561d1b(0x1b9)+_0x4b6165[_0x561d1b(0x1bf)][_0x561d1b(0x1c2)]+_0x561d1b(0x1c7)+_0x2caed3};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a61_0xd7509d=a61_0x3573;(function(_0x2658e4,_0x51ebfd){const _0x4065d3=a61_0x3573,_0x532413=_0x2658e4();while(!![]){try{const _0x205a30=parseInt(_0x4065d3(0x1f7))/0x1+-parseInt(_0x4065d3(0x1e7))/0x2+parseInt(_0x4065d3(0x1e5))/0x3+parseInt(_0x4065d3(0x1fa))/0x4*(parseInt(_0x4065d3(0x1f2))/0x5)+parseInt(_0x4065d3(0x1fe))/0x6*(parseInt(_0x4065d3(0x202))/0x7)+parseInt(_0x4065d3(0x1ff))/0x8+parseInt(_0x4065d3(0x207))/0x9*(-parseInt(_0x4065d3(0x1fb))/0xa);if(_0x205a30===_0x51ebfd)break;else _0x532413['push'](_0x532413['shift']());}catch(_0x4e0d3b){_0x532413['push'](_0x532413['shift']());}}}(a61_0x374d,0x596e3));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':a61_0xd7509d(0x1fd),'filter':'lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','getOne':'lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress'};export const RUNTIME_DATA_ACCESS_SUMMARY='Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.';function valueToString(_0xf2eec5){return _0xf2eec5==null?'':String(_0xf2eec5)['trim']();}function getDatasetCode(_0x3bd3a3){const _0x35e079=a61_0xd7509d;return valueToString(_0x3bd3a3[_0x35e079(0x205)]??_0x3bd3a3[_0x35e079(0x1f5)]??_0x3bd3a3['dataset']?.[_0x35e079(0x200)]);}function getDatasetName(_0x2f3f89){const _0x50bd5c=a61_0xd7509d;return valueToString(_0x2f3f89[_0x50bd5c(0x1f8)]??_0x2f3f89[_0x50bd5c(0x1ec)]?.[_0x50bd5c(0x1f4)])||_0x50bd5c(0x1f0);}function getDatasetSource(_0x207db7){const _0x4e3cfe=a61_0xd7509d;return valueToString(_0x207db7[_0x4e3cfe(0x1f6)]??_0x207db7['dataset']?.[_0x4e3cfe(0x1e9)])[_0x4e3cfe(0x1f3)]();}function getDbtableConfig(_0x2352e3){const _0x2973e0=a61_0xd7509d,_0x125954=_0x2352e3['dbtableConfig']??_0x2352e3[_0x2973e0(0x203)];return _0x125954&&typeof _0x125954==='object'?_0x125954:{};}function a61_0x3573(_0x25342c,_0xe18b8e){_0x25342c=_0x25342c-0x1e5;const _0x374da0=a61_0x374d();let _0x35738a=_0x374da0[_0x25342c];return _0x35738a;}export function isDbTableBackedDataset(_0x316f52){const _0x52c850=a61_0xd7509d,_0x3e5b3e=getDatasetSource(_0x316f52);if(_0x3e5b3e===_0x52c850(0x201))return![];const _0x352035=getDbtableConfig(_0x316f52),_0x4fbc39=_0x352035[_0x52c850(0x1e8)]??_0x352035['id'],_0x22adfc=valueToString(_0x352035[_0x52c850(0x1f1)]??_0x316f52[_0x52c850(0x1f1)]??_0x316f52[_0x52c850(0x1ec)]?.[_0x52c850(0x1f1)]);return _0x4fbc39!==undefined&&_0x4fbc39!==null&&_0x22adfc[_0x52c850(0x1f9)]>0x0;}function a61_0x374d(){const _0x399cf7=['datasetCode','METADATA','7ZLeioY','dbtable','当前数据集\x20\x22','code','\x20是\x20','2650131dklYuO','1308789dmeAlL','filter','340434wGVGUR','dbId','sourceType','\x20类型,没有可用于\x20','UNKNOWN','dataset','join','原因:schema\x20introspection\x20与\x20custom\x20SQL\x20需要\x20source=DB_TABLE、dbtableConfig.dbId、dbtableConfig.tableName\x20与数据库连接上下文。','validation','unknown','tableName','25405FVFIgr','toUpperCase','datasetName','modelCode','source','493135VvXeYH','name','length','60ngOfYL','50XJkPzI','getOne','lovrabet','3666354eZysuP','3137176nVkOss'];a61_0x374d=function(){return _0x399cf7;};return a61_0x374d();}export function filterDbTableBackedDatasets(_0x31a589){return _0x31a589['filter'](_0x26485d=>isDbTableBackedDataset(_0x26485d));}export function buildDbTableBackedRequirementMessage(_0x9803ac,_0x2e199b='SQL\x20schema\x20validation'){const _0x47e7e7=a61_0xd7509d,_0xe6d9e8=getDatasetSource(_0x9803ac)||_0x47e7e7(0x1eb),_0x3b852b=getDatasetName(_0x9803ac),_0x4117bd=getDatasetCode(_0x9803ac),_0x4344db=_0x4117bd?'\x20('+_0x4117bd+')':'';return[_0x47e7e7(0x204)+_0x3b852b+'\x22'+_0x4344db+_0x47e7e7(0x206)+_0xe6d9e8+_0x47e7e7(0x1ea)+_0x2e199b+'\x20的\x20DB_TABLE\x20数据源上下文。',_0x47e7e7(0x1ee),'请先将该数据集升级/迁移为\x20DB_TABLE\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:'+RUNTIME_DATA_ACCESS_COMMANDS[_0x47e7e7(0x1e6)]+';'+RUNTIME_DATA_ACCESS_COMMANDS[_0x47e7e7(0x1fc)]+'。'][_0x47e7e7(0x1ed)]('\x20');}export function assertDatasetIsDbTableBacked(_0x54e351,_0x5dcf45){const _0xae174a=a61_0xd7509d;if(!isDbTableBackedDataset(_0x54e351))throw CliErrors[_0xae174a(0x1ef)](buildDbTableBackedRequirementMessage(_0x54e351,_0x5dcf45));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a62_0x2efd5d=a62_0x3eb5;(function(_0x174b34,_0x47c7eb){const _0x16b60f=a62_0x3eb5,_0x1ccb05=_0x174b34();while(!![]){try{const _0x1768ec=parseInt(_0x16b60f(0x1ed))/0x1+-parseInt(_0x16b60f(0x1cd))/0x2*(-parseInt(_0x16b60f(0x202))/0x3)+parseInt(_0x16b60f(0x1fb))/0x4+-parseInt(_0x16b60f(0x1d4))/0x5+-parseInt(_0x16b60f(0x1d7))/0x6*(parseInt(_0x16b60f(0x1c4))/0x7)+-parseInt(_0x16b60f(0x1ce))/0x8+parseInt(_0x16b60f(0x1ca))/0x9*(parseInt(_0x16b60f(0x1f2))/0xa);if(_0x1768ec===_0x47c7eb)break;else _0x1ccb05['push'](_0x1ccb05['shift']());}catch(_0x2eeb25){_0x1ccb05['push'](_0x1ccb05['shift']());}}}(a62_0x580c,0xd46cf));import{deleteDataset,getDatasetDetail,listDatasets}from'../../core/api-client.js';function a62_0x3eb5(_0x7d4f6b,_0x37a4b9){_0x7d4f6b=_0x7d4f6b-0x1c4;const _0x580ce7=a62_0x580c();let _0x3eb5ba=_0x580ce7[_0x7d4f6b];return _0x3eb5ba;}function a62_0x580c(){const _0x429db0=['map','Would\x20delete\x20','1300074hQcDYb','Also\x20delete\x20related\x20pages\x20and\x20menus;\x20requires\x20explicit\x20--confirm','dbid','\x20dataset(s)','source','Matched\x20','filter','number','Use\x20only\x20one\x20of\x20--id,\x20--code,\x20or\x20--dbid.','str','\x20failed','false','deleted','dbtableConfig','add','name','object','num','relatedPages','Run\x20with\x20--dry-run\x20first,\x20then\x20add\x20--confirm\x20when\x20the\x20target\x20list\x20is\x20correct.','type','dbId','53108gvgsYB','Deleted\x20','Required\x20to\x20execute\x20dataset\x20deletion','Abort\x20unless\x20the\x20matched\x20dataset\x20count\x20equals\x20this\x20value','delete','7247370aHLWlw','\x20dataset(s),\x20but\x20--expected-count\x20is\x20','\x20dataset(s)\x20without\x20cascading\x20to\x20pages.\x20The\x20server\x20blocks\x20a\x20Dataset\x20that\x20still\x20has\x20related\x20pages.','true','length','boolean','isInteger','expected-count','relatedPageInfoList','4788128lQvqFz','title','Delete\x20dataset\x20metadata\x20by\x20id/code\x20or\x20all\x20datasets\x20under\x20a\x20db\x20id','description','bool','--confirm\x20is\x20required\x20to\x20delete\x20datasets.','\x20dataset(s);\x20','165QNXvKj','Would\x20safely\x20delete\x20','message','56OcGUIp','tableName','validation','code','cascade','high-risk-write','18FltJtt','appCode','rabetbase\x20page\x20restore\x20--id\x20','30176hoVYML','5736344UUIfbB','POST','dataset','push','isArray','Delete\x20all\x20datasets\x20under\x20this\x20database\x20connection\x20id','1044420mdtmyC'];a62_0x580c=function(){return _0x429db0;};return a62_0x580c();}import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL,CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';const DATASET_ID_FLAG={'name':'id','type':a62_0x2efd5d(0x1de),'description':'Dataset\x20id'},DBID_FLAG={'name':'dbid','type':a62_0x2efd5d(0x1de),'description':a62_0x2efd5d(0x1d3)},CONFIRM_FLAG={'name':'confirm','type':'boolean','description':a62_0x2efd5d(0x1ef)},CASCADE_FLAG={'name':'cascade','type':a62_0x2efd5d(0x1f7),'description':a62_0x2efd5d(0x1d8)},EXPECTED_COUNT_FLAG={'name':a62_0x2efd5d(0x1f9),'type':a62_0x2efd5d(0x1de),'description':a62_0x2efd5d(0x1f0)};export const datasetDelete={'service':a62_0x2efd5d(0x1d0),'command':a62_0x2efd5d(0x1f1),'description':a62_0x2efd5d(0x1fd),'risk':a62_0x2efd5d(0x1c9),'flags':[DATASET_ID_FLAG,CODE_FLAG_OPTIONAL,DBID_FLAG,CASCADE_FLAG,CONFIRM_FLAG,EXPECTED_COUNT_FLAG,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x45b17b){const _0x263350=a62_0x2efd5d,_0x32ff2d=_0x45b17b[_0x263350(0x1e8)]('id'),_0x473417=_0x45b17b[_0x263350(0x1e0)](_0x263350(0x1c7)),_0x558de9=_0x45b17b[_0x263350(0x1e8)](_0x263350(0x1d9)),_0x5182a9=[_0x32ff2d>0x0,Boolean(_0x473417),_0x558de9>0x0]['filter'](Boolean);if(_0x5182a9[_0x263350(0x1f6)]===0x0)throw CliErrors[_0x263350(0x1c6)]('One\x20of\x20--id,\x20--code,\x20or\x20--dbid\x20is\x20required.');if(_0x5182a9[_0x263350(0x1f6)]>0x1)throw CliErrors[_0x263350(0x1c6)](_0x263350(0x1df));},async 'dryRun'(_0x1969a9){const _0x1088da=a62_0x2efd5d,_0x5c159a=await resolveTargets(_0x1969a9),_0x311940=_0x1969a9[_0x1088da(0x1ff)](_0x1088da(0x1c8));return{'method':_0x1088da(0x1cf),'url':'/smartapi/dataset/delete?cascade='+(_0x311940?_0x1088da(0x1f5):_0x1088da(0x1e2)),'body':{'count':_0x5c159a[_0x1088da(0x1f6)],'cascade':_0x311940,'datasets':_0x5c159a},'description':_0x311940?_0x1088da(0x1d6)+_0x5c159a[_0x1088da(0x1f6)]+'\x20dataset(s)\x20and\x20their\x20listed\x20related\x20pages/menus.\x20Restore\x20each\x20Dataset\x20first,\x20then\x20restore\x20pages\x20explicitly\x20when\x20needed.':_0x1088da(0x203)+_0x5c159a[_0x1088da(0x1f6)]+_0x1088da(0x1f4)};},async 'execute'(_0x1256fb){const _0x493118=a62_0x2efd5d;if(!_0x1256fb[_0x493118(0x1ff)]('confirm'))throw CliErrors[_0x493118(0x1c6)](_0x493118(0x200),_0x493118(0x1ea));const _0x2522b9=await resolveTargets(_0x1256fb),_0x32dd26=_0x1256fb[_0x493118(0x1ff)](_0x493118(0x1c8)),_0xdd1281=[],_0x2f7f87=[];for(const _0xd53ed6 of _0x2522b9){try{await deleteDataset(_0xd53ed6['id'],_0x32dd26),_0xdd1281[_0x493118(0x1d1)](_0xd53ed6);}catch(_0x5582f9){_0x2f7f87['push']({..._0xd53ed6,'error':_0x5582f9 instanceof Error?_0x5582f9[_0x493118(0x204)]:String(_0x5582f9)});}}if(_0x2f7f87[_0x493118(0x1f6)]>0x0){const _0x3f29db=buildPageRestoreCommands(_0x1256fb[_0x493118(0x1cb)],_0x32dd26?_0xdd1281:[]);return{'ok':![],'data':{'requested':_0x2522b9['length'],'cascade':_0x32dd26,'deletedCount':_0xdd1281['length'],'failedCount':_0x2f7f87['length'],'deleted':_0xdd1281,'failed':_0x2f7f87,'pageRestoreCommands':_0x3f29db},'message':_0x493118(0x1ee)+_0xdd1281[_0x493118(0x1f6)]+'/'+_0x2522b9['length']+_0x493118(0x201)+_0x2f7f87[_0x493118(0x1f6)]+_0x493118(0x1e1)};}return{'ok':!![],'data':{'requested':_0x2522b9[_0x493118(0x1f6)],'cascade':_0x32dd26,'deletedCount':_0xdd1281['length'],'deleted':_0xdd1281,'pageRestoreCommands':buildPageRestoreCommands(_0x1256fb[_0x493118(0x1cb)],_0x32dd26?_0xdd1281:[])},'message':_0x493118(0x1ee)+_0xdd1281['length']+_0x493118(0x1da)};}};async function resolveTargets(_0x1fd04b){const _0x4da90e=a62_0x2efd5d,_0x44dbf5=_0x1fd04b[_0x4da90e(0x1e8)]('id'),_0x4757a6=_0x1fd04b[_0x4da90e(0x1e0)](_0x4da90e(0x1c7)),_0x2b9e0d=_0x1fd04b[_0x4da90e(0x1e8)](_0x4da90e(0x1d9));let _0x3bfcb8;_0x4757a6?(_0x3bfcb8=await listDatasets(_0x1fd04b[_0x4da90e(0x1cb)],{'code':_0x4757a6}),_0x3bfcb8=_0x3bfcb8['filter'](_0x3af0c7=>_0x3af0c7[_0x4da90e(0x1c7)]===_0x4757a6)):(_0x3bfcb8=await listDatasets(_0x1fd04b['appCode']),_0x44dbf5>0x0&&(_0x3bfcb8=_0x3bfcb8[_0x4da90e(0x1dd)](_0x2f9932=>_0x2f9932['id']===_0x44dbf5)),_0x2b9e0d>0x0&&(_0x3bfcb8=_0x3bfcb8[_0x4da90e(0x1dd)](_0x4fca7d=>_0x4fca7d[_0x4da90e(0x1e4)]?.[_0x4da90e(0x1ec)]===_0x2b9e0d)));const _0x6b2eb=[];for(const _0x358eb1 of _0x3bfcb8){const _0x3adda6=await getDatasetDetail(_0x358eb1[_0x4da90e(0x1c7)]),_0x2b9754=Array[_0x4da90e(0x1d2)](_0x3adda6[_0x4da90e(0x1fa)])?_0x3adda6[_0x4da90e(0x1fa)]['filter'](_0x50c40e=>_0x50c40e!=null&&typeof _0x50c40e===_0x4da90e(0x1e7)&&_0x50c40e[_0x4da90e(0x1e3)]!==!![]):[];_0x6b2eb['push'](normalizeTarget(_0x358eb1,_0x2b9754));}if(_0x6b2eb[_0x4da90e(0x1f6)]===0x0){const _0x49993a=_0x4757a6||(_0x44dbf5>0x0?'id='+_0x44dbf5:'dbid='+_0x2b9e0d);throw CliErrors[_0x4da90e(0x1c6)]('No\x20undeleted\x20dataset\x20found\x20for\x20'+_0x49993a+'.');}const _0x243489=_0x1fd04b[_0x4da90e(0x1e8)](_0x4da90e(0x1f9));if(_0x243489>0x0&&_0x6b2eb[_0x4da90e(0x1f6)]!==_0x243489)throw CliErrors['validation'](_0x4da90e(0x1dc)+_0x6b2eb[_0x4da90e(0x1f6)]+_0x4da90e(0x1f3)+_0x243489+'.');return _0x6b2eb;}function normalizeTarget(_0xeb990e,_0x57bcb9){const _0x3a795a=a62_0x2efd5d,_0x5422d8=_0xeb990e[_0x3a795a(0x1e4)]??{},_0x8ed700=_0x57bcb9[_0x3a795a(0x1d5)](_0x4036af=>{const _0x43e04b=_0x3a795a;if(_0x4036af==null||typeof _0x4036af!==_0x43e04b(0x1e7))return null;const _0x47bb41=_0x4036af,_0x21b76e=Number(_0x47bb41['id']);if(!Number[_0x43e04b(0x1f8)](_0x21b76e)||_0x21b76e<=0x0)return null;const _0x5a382b=_0x47bb41[_0x43e04b(0x1fc)]??_0x47bb41[_0x43e04b(0x1e6)];return{'id':_0x21b76e,..._0x5a382b?{'name':String(_0x5a382b)}:{},..._0x47bb41[_0x43e04b(0x1eb)]?{'type':String(_0x47bb41[_0x43e04b(0x1eb)])}:{}};})[_0x3a795a(0x1dd)](_0x55871c=>_0x55871c!==null);return{'id':_0xeb990e['id'],'code':_0xeb990e[_0x3a795a(0x1c7)],'name':_0xeb990e[_0x3a795a(0x1e6)],'description':_0xeb990e[_0x3a795a(0x1fe)],'source':_0xeb990e[_0x3a795a(0x1db)],'dbId':_0x5422d8['dbId'],'dbName':_0x5422d8['dbName'],'tableName':_0x5422d8[_0x3a795a(0x1c5)],'relatedPageCount':_0x8ed700[_0x3a795a(0x1f6)],'relatedPages':_0x8ed700};}function buildPageRestoreCommands(_0x79a15b,_0x4ef9ff){const _0x15bfa4=a62_0x2efd5d,_0x231f4b=new Set();for(const _0x12dc1f of _0x4ef9ff){for(const _0x4d6ba2 of _0x12dc1f[_0x15bfa4(0x1e9)])_0x231f4b[_0x15bfa4(0x1e5)](_0x4d6ba2['id']);}return[..._0x231f4b][_0x15bfa4(0x1d5)](_0x62eb48=>_0x15bfa4(0x1cc)+_0x62eb48+'\x20--appcode\x20'+_0x79a15b);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a63_0x2756b3=a63_0x3a4b;(function(_0x1cfa9f,_0x579910){const _0x19d2ba=a63_0x3a4b,_0x27c654=_0x1cfa9f();while(!![]){try{const _0x13171b=-parseInt(_0x19d2ba(0x17e))/0x1+parseInt(_0x19d2ba(0x17b))/0x2*(parseInt(_0x19d2ba(0x1ad))/0x3)+-parseInt(_0x19d2ba(0x169))/0x4*(-parseInt(_0x19d2ba(0x17a))/0x5)+parseInt(_0x19d2ba(0x1ac))/0x6*(-parseInt(_0x19d2ba(0x1a8))/0x7)+-parseInt(_0x19d2ba(0x1a0))/0x8+-parseInt(_0x19d2ba(0x1b5))/0x9+parseInt(_0x19d2ba(0x1ae))/0xa;if(_0x13171b===_0x579910)break;else _0x27c654['push'](_0x27c654['shift']());}catch(_0x24a0ae){_0x27c654['push'](_0x27c654['shift']());}}}(a63_0x3e5b,0x22d25));import{getDatasetDetail}from'../../core/api-client.js';function a63_0x3e5b(){const _0x49ce22=['3SScGab','4697280yfqhbD','description','logicField','dbType','creatorNameField','displayName','toFieldLabel','991800fxPgqJ','columnCodeListWithDeleted','responseFields','formatRules','filter','source','fromField','toTableName','dataType','type','dbName','4KwWBwh','tableName','parse','deleted','afterScriptId','title','trim','allFields','updateTimeField','map','required','object','str','deprecated','host','name','createTimeField','1240705KrcEUJ','500522WcWFEm','detail','isArray','282155UKTXhM','relatedPageInfoList','relationId','toDatasetName','bizRelationType','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','modelCode','alias','datasetKey','read','main_sub','doVersion','string','allFieldNames','method','requestFields','code','push','indexes','beforeScriptId','pkField','responseBody','requestBody','modelId','cardinality','sourceType','labelField','Get\x20dataset\x20detail\x20including\x20fields\x20and\x20operations','path','dbId','validateRules','dbtableConfig','toField','dataset','1966816tHCteP','dblinkInfoDTO','extend','toDatasetCode','length','options','doType','properties','7VDBYNl','relations','modifierNameField','split','1123764sQNcOv'];a63_0x3e5b=function(){return _0x49ce22;};return a63_0x3e5b();}import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function normalizeField(_0x43711d){const _0x2a234d=a63_0x3a4b;if(_0x43711d[_0x2a234d(0x16c)])return null;const _0x5d914a=Boolean(_0x43711d[_0x2a234d(0x1b3)]!==undefined||_0x43711d[_0x2a234d(0x1a6)]!==undefined);let _0x4a7db8={};if(!_0x5d914a&&typeof _0x43711d[_0x2a234d(0x1a2)]===_0x2a234d(0x18a))try{_0x4a7db8=JSON[_0x2a234d(0x16b)](_0x43711d[_0x2a234d(0x1a2)]);}catch{}const _0x5454cb=_0x5d914a?_0x43711d[_0x2a234d(0x178)]:_0x43711d['code'],_0x31f57e=_0x5d914a?_0x43711d[_0x2a234d(0x1b3)]:_0x43711d[_0x2a234d(0x178)],_0x3f454e=_0x5d914a?_0x43711d[_0x2a234d(0x1a6)]:_0x43711d[_0x2a234d(0x167)]||_0x43711d[_0x2a234d(0x1bd)],_0x36a575=_0x5d914a?_0x43711d[_0x2a234d(0x192)]===!![]:_0x4a7db8['pkField']===!![],_0x5645f9=_0x5d914a?_0x43711d[_0x2a234d(0x173)]===!![]:_0x4a7db8['required']===!![],_0xa67dbb=_0x5d914a?_0x43711d['options']??null:_0x4a7db8['options']??null,_0x2286bd={'name':_0x5454cb,'displayName':_0x31f57e||_0x5454cb,'type':_0x3f454e,'dbType':_0x43711d[_0x2a234d(0x1b1)],'pk':_0x36a575,'required':_0x5645f9,'deprecated':_0x43711d[_0x2a234d(0x176)]===!![],'description':_0x43711d[_0x2a234d(0x1af)]||undefined};return Array['isArray'](_0xa67dbb)&&_0xa67dbb['length']>0x0&&(_0x2286bd[_0x2a234d(0x1a5)]=_0xa67dbb),_0x2286bd;}function parseJsonMaybe(_0x473128){const _0x275005=a63_0x3a4b;if(typeof _0x473128!==_0x275005(0x18a))return _0x473128;try{return JSON[_0x275005(0x16b)](_0x473128);}catch{return _0x473128;}}function a63_0x3a4b(_0x54f9c3,_0x3350d9){_0x54f9c3=_0x54f9c3-0x167;const _0x3e5b1c=a63_0x3e5b();let _0x3a4b6f=_0x3e5b1c[_0x54f9c3];return _0x3a4b6f;}function normalizeOperationEntry(_0x826c26,_0x1d1df6){const _0x52a865=a63_0x3a4b;if(!_0x1d1df6||typeof _0x1d1df6!=='object')return null;if(!_0x1d1df6[_0x52a865(0x18c)]||!_0x1d1df6[_0x52a865(0x19a)])return null;const _0x366d0c={'name':_0x826c26,'method':_0x1d1df6['method'],'path':_0x1d1df6[_0x52a865(0x19a)]};if(_0x1d1df6[_0x52a865(0x177)])_0x366d0c[_0x52a865(0x177)]=_0x1d1df6[_0x52a865(0x177)];if(_0x1d1df6[_0x52a865(0x194)]!=null){const _0x3b9e8a=parseJsonMaybe(_0x1d1df6[_0x52a865(0x194)]);_0x366d0c[_0x52a865(0x194)]=_0x3b9e8a;}if(_0x1d1df6['responseBody']!=null){const _0x46a714=parseJsonMaybe(_0x1d1df6[_0x52a865(0x193)]);_0x366d0c[_0x52a865(0x193)]=_0x46a714;}if(_0x1d1df6[_0x52a865(0x191)]!=null)_0x366d0c['beforeScriptId']=_0x1d1df6[_0x52a865(0x191)];if(_0x1d1df6['afterScriptId']!=null)_0x366d0c[_0x52a865(0x16d)]=_0x1d1df6[_0x52a865(0x16d)];if(Array['isArray'](_0x1d1df6['requestFields']))_0x366d0c[_0x52a865(0x18d)]=_0x1d1df6['requestFields'];if(Array[_0x52a865(0x17d)](_0x1d1df6[_0x52a865(0x1b7)]))_0x366d0c[_0x52a865(0x1b7)]=_0x1d1df6[_0x52a865(0x1b7)];return _0x366d0c;}function summarizeDbtable(_0x4e0188){const _0x445c04=a63_0x3a4b,_0x322670={},_0xacfcd7=[_0x445c04(0x19b),_0x445c04(0x168),'tableName',_0x445c04(0x186),'pkField','allFields',_0x445c04(0x1b0),_0x445c04(0x179),_0x445c04(0x171),'creatorIdField',_0x445c04(0x1b2),'modifierIdField',_0x445c04(0x1aa),_0x445c04(0x198),_0x445c04(0x1a1)];for(const _0x51ff94 of _0xacfcd7){if(_0x4e0188[_0x51ff94]!==undefined)_0x322670[_0x51ff94]=_0x4e0188[_0x51ff94];}return typeof _0x322670[_0x445c04(0x170)]===_0x445c04(0x18a)&&_0x322670[_0x445c04(0x170)][_0x445c04(0x1a4)]>0x0&&(_0x322670[_0x445c04(0x18b)]=_0x322670[_0x445c04(0x170)][_0x445c04(0x1ab)](',')[_0x445c04(0x172)](_0x268bba=>_0x268bba[_0x445c04(0x16f)]())[_0x445c04(0x1b9)](Boolean)),_0x322670;}function normalizeRelatedPages(_0x2bffa1){const _0x3af655=a63_0x3a4b;if(!Array['isArray'](_0x2bffa1))return[];return _0x2bffa1[_0x3af655(0x1b9)](_0x1e42a1=>_0x1e42a1&&typeof _0x1e42a1===_0x3af655(0x174))['map'](_0x57ddff=>({'id':_0x57ddff['id'],'type':_0x57ddff[_0x3af655(0x167)],'code':_0x57ddff[_0x3af655(0x18e)],'title':_0x57ddff[_0x3af655(0x16e)],'deleted':_0x57ddff[_0x3af655(0x16c)]===!![]}));}export const datasetDetail={'service':a63_0x2756b3(0x19f),'command':a63_0x2756b3(0x17c),'description':a63_0x2756b3(0x199),'risk':a63_0x2756b3(0x187),'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':a63_0x2756b3(0x185),'type':'string','description':a63_0x2756b3(0x183)}],async 'execute'(_0x176e5f){const _0x412622=a63_0x2756b3,_0x5d22bd=await getDatasetDetail(_0x176e5f[_0x412622(0x175)](_0x412622(0x18e))),_0x581e8e=Array[_0x412622(0x17d)](_0x5d22bd['fields'])?_0x5d22bd['fields']:Array[_0x412622(0x17d)](_0x5d22bd[_0x412622(0x1a7)])?_0x5d22bd[_0x412622(0x1a7)]:[],_0x3052a5=_0x581e8e[_0x412622(0x172)](_0x4f69ba=>normalizeField(_0x4f69ba))[_0x412622(0x1b9)](_0x33699f=>_0x33699f!==null),_0x478b52=_0x5d22bd['operations']??{},_0x3e5b7c=[];for(const [_0xcb2cd2,_0x10437a]of Object['entries'](_0x478b52)){const _0x34fb1e=normalizeOperationEntry(_0xcb2cd2,_0x10437a);if(_0x34fb1e)_0x3e5b7c[_0x412622(0x18f)](_0x34fb1e);}const _0x48a9b2=_0x5d22bd[_0x412622(0x19d)]??{},_0x2f1054=_0x5d22bd[_0x412622(0x19f)]??{},_0x589108=_0x48a9b2[_0x412622(0x19b)]!=null?{'id':_0x48a9b2[_0x412622(0x19b)],'name':_0x48a9b2['dbName']??null}:undefined;let _0x5383fc;return typeof _0x5d22bd['extend']===_0x412622(0x18a)&&(_0x5383fc=parseJsonMaybe(_0x5d22bd[_0x412622(0x1a2)])),{'ok':!![],'data':{'id':_0x5d22bd[_0x412622(0x195)]??_0x5d22bd['id'],'name':_0x5d22bd[_0x412622(0x178)],'code':_0x5d22bd[_0x412622(0x184)]||_0x5d22bd[_0x412622(0x18e)],'doVersion':_0x5d22bd[_0x412622(0x189)],'description':_0x5d22bd[_0x412622(0x1af)]||_0x2f1054['tableComment']||undefined,'source':_0x5d22bd[_0x412622(0x1ba)]||_0x2f1054[_0x412622(0x197)],'table':_0x48a9b2[_0x412622(0x16a)]||_0x2f1054[_0x412622(0x16a)],'datasetKey':_0x48a9b2[_0x412622(0x186)],'pk':_0x48a9b2[_0x412622(0x192)],'db':_0x589108,'dbtable':summarizeDbtable(_0x48a9b2),'fields':_0x3052a5,'operations':_0x3e5b7c,'indexes':Array[_0x412622(0x17d)](_0x2f1054['indexes'])?_0x2f1054[_0x412622(0x190)]:[],'relations':Array[_0x412622(0x17d)](_0x5d22bd['relations'])?_0x5d22bd[_0x412622(0x1a9)]['map'](_0x2a71a6=>({..._0x2a71a6[_0x412622(0x180)]!=null?{'relationId':_0x2a71a6[_0x412622(0x180)]}:{},'fromDataset':_0x5d22bd[_0x412622(0x178)],'fromCode':_0x5d22bd[_0x412622(0x184)]||_0x5d22bd['code'],'fromTable':_0x48a9b2[_0x412622(0x16a)]||_0x2f1054[_0x412622(0x16a)],'fromField':_0x2a71a6[_0x412622(0x1bb)],'toDataset':_0x2a71a6[_0x412622(0x181)],'toCode':_0x2a71a6[_0x412622(0x1a3)],'toTable':_0x2a71a6[_0x412622(0x1bc)],'toField':_0x2a71a6[_0x412622(0x19e)],'labelField':_0x2a71a6[_0x412622(0x1b4)]||undefined,'cardinality':_0x2a71a6[_0x412622(0x196)]||undefined,'bizRelationType':_0x2a71a6[_0x412622(0x182)]===_0x412622(0x188)?_0x412622(0x188):null})):[],'relatedPages':normalizeRelatedPages(_0x5d22bd[_0x412622(0x17f)]),...Array['isArray'](_0x5d22bd[_0x412622(0x1b6)])?{'columnCodeListWithDeleted':_0x5d22bd[_0x412622(0x1b6)]}:{},'formatRules':Array[_0x412622(0x17d)](_0x5d22bd[_0x412622(0x1b8)])?_0x5d22bd[_0x412622(0x1b8)]:[],'validateRules':Array[_0x412622(0x17d)](_0x5d22bd[_0x412622(0x19c)])?_0x5d22bd[_0x412622(0x19c)]:[],..._0x5383fc!==undefined?{'extend':_0x5383fc}:{},'stats':{'fieldCount':_0x3052a5[_0x412622(0x1a4)],'operationCount':_0x3e5b7c['length']}}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a64_0x59b2f9=a64_0x4037;(function(_0x2b05b4,_0x23ca44){const _0x527a34=a64_0x4037,_0x5c4699=_0x2b05b4();while(!![]){try{const _0x210261=-parseInt(_0x527a34(0x104))/0x1+parseInt(_0x527a34(0xe8))/0x2*(parseInt(_0x527a34(0xfe))/0x3)+parseInt(_0x527a34(0xe3))/0x4+-parseInt(_0x527a34(0x10a))/0x5*(parseInt(_0x527a34(0x112))/0x6)+parseInt(_0x527a34(0xf1))/0x7+parseInt(_0x527a34(0x103))/0x8*(-parseInt(_0x527a34(0xe6))/0x9)+-parseInt(_0x527a34(0xf0))/0xa;if(_0x210261===_0x23ca44)break;else _0x5c4699['push'](_0x5c4699['shift']());}catch(_0x3b7614){_0x5c4699['push'](_0x5c4699['shift']());}}}(a64_0x2c5e,0x662aa));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([['businessGroup',{'message':'dataset\x20extend-update\x20does\x20not\x20support\x20businessGroup;\x20use\x20dataset\x20business-group-update','hint':a64_0x59b2f9(0xe1)}]]);function a64_0x4037(_0x209e46,_0x5990ee){_0x209e46=_0x209e46-0xdf;const _0x2c5e02=a64_0x2c5e();let _0x403729=_0x2c5e02[_0x209e46];return _0x403729;}export function parseJsonObjectFlag(_0xce2758,_0x4f5043){const _0x9a4709=a64_0x59b2f9;if(!_0xce2758)return undefined;let _0x1780dc;try{_0x1780dc=JSON[_0x9a4709(0x10e)](_0xce2758);}catch(_0x146857){const _0x5dab18=_0x146857 instanceof Error?_0x146857[_0x9a4709(0x101)]:String(_0x146857);throw CliErrors[_0x9a4709(0x10c)](_0x4f5043+'\x20must\x20be\x20valid\x20JSON\x20object:\x20'+_0x5dab18);}if(!isPlainObject(_0x1780dc)||Array[_0x9a4709(0x10b)](_0x1780dc))throw CliErrors['validation'](_0x4f5043+_0x9a4709(0x114));return _0x1780dc;}export function validateExtendPatchKeys(_0x7456d8){const _0x33528a=a64_0x59b2f9,_0x4ed429=Object[_0x33528a(0xfb)](_0x7456d8);if(_0x4ed429[_0x33528a(0xf7)]===0x0)throw CliErrors['validation'](_0x33528a(0xec));for(const _0x265db9 of _0x4ed429){const _0x8f6aaf=EXTEND_PATCH_REDIRECTS[_0x33528a(0x110)](_0x265db9);if(_0x8f6aaf)throw CliErrors[_0x33528a(0x10c)](_0x8f6aaf[_0x33528a(0x101)],_0x8f6aaf[_0x33528a(0xfc)]);if(!MUTABLE_EXTEND_KEYS[_0x33528a(0x117)](_0x265db9))throw CliErrors[_0x33528a(0x10c)](_0x33528a(0xfa)+_0x265db9,describeMutableExtendKeys());}}function describeMutableExtendKeys(){const _0x24388f=a64_0x59b2f9,_0xe847=Array[_0x24388f(0xe7)](MUTABLE_EXTEND_KEYS)[_0x24388f(0x105)]();return _0xe847[_0x24388f(0xf7)]>0x0?'Allowed\x20keys:\x20'+_0xe847[_0x24388f(0xe4)](',\x20'):_0x24388f(0xee);}export function applyExtendPatch(_0x297ec9,_0x1ae30a){const _0x4b5b4f=a64_0x59b2f9;validateExtendPatchKeys(_0x1ae30a);const _0x30f3b3=deepClone(_0x297ec9),_0x1d03f6=[];for(const [_0x2cd726,_0x5630c9]of Object[_0x4b5b4f(0x100)](_0x1ae30a)){const _0x28bb48=_0x30f3b3[_0x2cd726],_0x1c84de=deepClone(_0x5630c9);!deepEqual(_0x28bb48,_0x1c84de)&&(_0x30f3b3[_0x2cd726]=_0x1c84de,_0x1d03f6[_0x4b5b4f(0xeb)](_0x4b5b4f(0x119)+_0x2cd726));}return _0x1d03f6[_0x4b5b4f(0x105)](),{'after':_0x30f3b3,'changedPaths':_0x1d03f6,'changed':_0x1d03f6['length']>0x0};}export function assertExpectation(_0x54279f,_0x4da124){const _0x690ae=a64_0x59b2f9;if(!_0x4da124)return;for(const [_0x1ac07c,_0x2a42aa]of Object[_0x690ae(0x100)](_0x4da124)){const _0x2537cf=_0x54279f[_0x1ac07c];if(!deepEqual(_0x2537cf,_0x2a42aa))throw CliErrors[_0x690ae(0x10c)](_0x690ae(0x118)+_0x1ac07c,_0x690ae(0x111)+JSON[_0x690ae(0x107)](_0x2a42aa)+',\x20actual\x20'+JSON[_0x690ae(0x107)](_0x2537cf));}}export async function buildDatasetExtendUpdateResult({appCode:_0x11ae31,input:_0x13b44b,dryRun:_0x5aeb16}){const _0x2faa00=a64_0x59b2f9;validateInput(_0x13b44b);const _0x3f83ea=await getDatasetDetail(_0x13b44b[_0x2faa00(0x11a)]),_0x4bafd5=parseDatasetExtend(_0x3f83ea[_0x2faa00(0x116)]),_0x7a243f=deepClone(_0x4bafd5[_0x2faa00(0x106)]);assertExpectation(_0x7a243f,_0x13b44b['expect']);const {after:_0x5db069,changedPaths:_0x43f993,changed:_0x2a87f0}=applyExtendPatch(_0x7a243f,_0x13b44b[_0x2faa00(0x109)]),_0x2a8bcf=summarizeDataset(_0x3f83ea,_0x13b44b['code']);return _0x2a87f0&&!_0x5aeb16&&(_0x3f83ea[_0x2faa00(0x116)]=serializeDatasetExtend(_0x5db069,_0x4bafd5[_0x2faa00(0x102)]),await updateDrivenData(_0x3f83ea)),{'ok':!![],'data':{'appCode':_0x11ae31,'selector':{'code':_0x13b44b['code']},'dataset':_0x2a8bcf,'dryRun':_0x5aeb16,'changed':_0x2a87f0,'changedPaths':_0x43f993,'before':{'extend':_0x7a243f},'after':{'extend':_0x5db069},'submitted':_0x2a87f0&&!_0x5aeb16},'message':_0x2a87f0?_0x5aeb16?_0x2faa00(0xea)+_0x43f993[_0x2faa00(0xe4)](',\x20')+')':_0x2faa00(0x10f)+_0x43f993[_0x2faa00(0xe4)](',\x20')+')':'No\x20changes\x20for\x20dataset\x20extend'};}export const datasetExtendUpdate={'service':'dataset','command':'extend-update','description':a64_0x59b2f9(0x10d),'risk':'write','flags':[CODE_FLAG,{'name':a64_0x59b2f9(0xe9),'type':a64_0x59b2f9(0xf3),'required':!![],'description':'JSON\x20object\x20patch\x20for\x20dataset\x20top-level\x20extend;\x20current\x20allowlist\x20is\x20empty'},{'name':a64_0x59b2f9(0xf9),'type':a64_0x59b2f9(0xf3),'required':![],'description':a64_0x59b2f9(0xe2)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x245acf){validateInput(readExtendUpdateInput(_0x245acf));},async 'dryRun'(_0x32efad){const _0x500355=a64_0x59b2f9,_0x25b6ff=await buildDatasetExtendUpdateResult({'appCode':_0x32efad['appCode'],'input':readExtendUpdateInput(_0x32efad),'dryRun':!![]});return{'method':_0x500355(0xf4),'url':_0x500355(0xdf),'body':_0x25b6ff['data'],'description':_0x25b6ff[_0x500355(0x101)]};},async 'execute'(_0x42bd42){return buildDatasetExtendUpdateResult({'appCode':_0x42bd42['appCode'],'input':readExtendUpdateInput(_0x42bd42),'dryRun':![]});}};function readExtendUpdateInput(_0x23f7ac){const _0x499947=a64_0x59b2f9,_0x316a20=trim(_0x23f7ac[_0x499947(0x115)]('code')),_0x24a66d=parseJsonObjectFlag(_0x23f7ac[_0x499947(0x115)]('patch-json'),'--patch-json'),_0x54017a=parseJsonObjectFlag(_0x23f7ac['str'](_0x499947(0xf9)),_0x499947(0xff));return{'code':_0x316a20,'patch':_0x24a66d||{},'expect':_0x54017a};}function validateInput(_0x5021fb){const _0x39db4d=a64_0x59b2f9;if(!_0x5021fb[_0x39db4d(0x11a)])throw CliErrors['validation'](_0x39db4d(0xef));validateExtendPatchKeys(_0x5021fb['patch']);}function parseDatasetExtend(_0x15d31e){const _0x2744a3=a64_0x59b2f9;if(typeof _0x15d31e===_0x2744a3(0xf3)){const _0x1a08c1=_0x15d31e[_0x2744a3(0xe0)]();if(!_0x1a08c1)return{'value':{},'shape':_0x2744a3(0xf3)};let _0x3f04da;try{_0x3f04da=JSON[_0x2744a3(0x10e)](_0x1a08c1);}catch(_0x364cbc){const _0x2aa81c=_0x364cbc instanceof Error?_0x364cbc[_0x2744a3(0x101)]:String(_0x364cbc);throw CliErrors[_0x2744a3(0x10c)]('Dataset\x20extend\x20must\x20be\x20valid\x20JSON\x20object:\x20'+_0x2aa81c);}if(!isPlainObject(_0x3f04da)||Array[_0x2744a3(0x10b)](_0x3f04da))throw CliErrors[_0x2744a3(0x10c)](_0x2744a3(0x11b));return{'value':_0x3f04da,'shape':_0x2744a3(0xf3)};}if(_0x15d31e===undefined||_0x15d31e===null)return{'value':{},'shape':'string'};if(!isPlainObject(_0x15d31e)||Array[_0x2744a3(0x10b)](_0x15d31e))throw CliErrors['validation'](_0x2744a3(0x11b));return{'value':_0x15d31e,'shape':'object'};}function serializeDatasetExtend(_0x497cb7,_0x36e568){const _0x341fa3=a64_0x59b2f9;return _0x36e568===_0x341fa3(0xf3)?JSON[_0x341fa3(0x107)](_0x497cb7):_0x497cb7;}function summarizeDataset(_0xf8b12,_0x4c799e){const _0x4de2fe=a64_0x59b2f9,_0x5e6121=isPlainObject(_0xf8b12[_0x4de2fe(0xf5)])?_0xf8b12[_0x4de2fe(0xf5)]:{},_0x322f75=isPlainObject(_0xf8b12[_0x4de2fe(0xf6)])?_0xf8b12[_0x4de2fe(0xf6)]:{};return{'id':_0xf8b12['modelId']??_0xf8b12['id']??_0x5e6121[_0x4de2fe(0xf8)]??null,'code':_0xf8b12[_0x4de2fe(0x113)]??_0xf8b12[_0x4de2fe(0x11a)]??_0x5e6121[_0x4de2fe(0xf2)]??_0x4c799e,'name':_0xf8b12[_0x4de2fe(0xe5)]??_0x5e6121[_0x4de2fe(0x11c)]??null,'table':_0x322f75[_0x4de2fe(0xfd)]??_0x5e6121['tableName']??null,'db':_0x322f75['dbName']??_0x322f75[_0x4de2fe(0xed)]??null};}function a64_0x2c5e(){const _0xcd2601=['Expectation\x20mismatch\x20at\x20extend.','extend.','code','Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object','datasetName','/smartapi/dataset/update-driven-data','trim','Use\x20`rabetbase\x20dataset\x20business-group-update`\x20to\x20update\x20business\x20model\x20groups.','JSON\x20object\x20of\x20expected\x20current\x20extend\x20values;\x20mismatch\x20aborts\x20without\x20writing','2344744AiGSor','join','name','270027bTGPFI','from','2HUfYVI','patch-json','Dry-run:\x20dataset\x20extend\x20would\x20change\x20(','push','--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key','dbId','No\x20dataset\x20extend\x20patch\x20keys\x20are\x20currently\x20supported.','--code\x20is\x20required','1654930tILfWK','2778860yMrbIq','datasetCode','string','POST','dataset','dbtableConfig','length','datasetId','expect-json','Unsupported\x20patch\x20key:\x20','keys','hint','tableName','1010535gPRIuE','--expect-json','entries','message','shape','104tGmEIe','296053xuNadK','sort','value','stringify','object','patch','17840eBFfKo','isArray','validation','Patch\x20dataset\x20top-level\x20extend\x20safely','parse','Updated\x20dataset\x20extend\x20(','get','Expected\x20','84MAPnAq','modelCode','\x20must\x20be\x20a\x20JSON\x20object','str','extend','has'];a64_0x2c5e=function(){return _0xcd2601;};return a64_0x2c5e();}function deepClone(_0x42fecf){const _0x511ebd=a64_0x59b2f9;if(_0x42fecf===undefined)return _0x42fecf;return JSON[_0x511ebd(0x10e)](JSON[_0x511ebd(0x107)](_0x42fecf));}function deepEqual(_0x54219a,_0x366e58){const _0xc74608=a64_0x59b2f9;return JSON['stringify'](_0x54219a)===JSON[_0xc74608(0x107)](_0x366e58);}function isPlainObject(_0x5c86e8){const _0x11bc02=a64_0x59b2f9;return Boolean(_0x5c86e8)&&typeof _0x5c86e8===_0x11bc02(0x108)&&!Array[_0x11bc02(0x10b)](_0x5c86e8);}function trim(_0x508fe2){const _0x152271=a64_0x59b2f9,_0xbcb071=String(_0x508fe2||'')[_0x152271(0xe0)]();return _0xbcb071;}
|
|
1
|
+
const a64_0x3b4c4e=a64_0x53f9;(function(_0x39b948,_0x4aadc3){const _0x2aec8f=a64_0x53f9,_0x29f8ad=_0x39b948();while(!![]){try{const _0xd14e06=-parseInt(_0x2aec8f(0x111))/0x1*(-parseInt(_0x2aec8f(0xdd))/0x2)+-parseInt(_0x2aec8f(0x105))/0x3*(parseInt(_0x2aec8f(0xfb))/0x4)+-parseInt(_0x2aec8f(0x103))/0x5*(parseInt(_0x2aec8f(0xff))/0x6)+-parseInt(_0x2aec8f(0xfe))/0x7*(-parseInt(_0x2aec8f(0xe3))/0x8)+parseInt(_0x2aec8f(0xe2))/0x9*(parseInt(_0x2aec8f(0xe8))/0xa)+-parseInt(_0x2aec8f(0x10c))/0xb+parseInt(_0x2aec8f(0x113))/0xc;if(_0xd14e06===_0x4aadc3)break;else _0x29f8ad['push'](_0x29f8ad['shift']());}catch(_0x5aea1a){_0x29f8ad['push'](_0x29f8ad['shift']());}}}(a64_0x28c8,0x5380e));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_0x3b4c4e(0x115),{'message':a64_0x3b4c4e(0xdf),'hint':a64_0x3b4c4e(0xf5)}]]);export function parseJsonObjectFlag(_0x2b2b92,_0x44a44b){const _0x561e6f=a64_0x3b4c4e;if(!_0x2b2b92)return undefined;let _0x1cd2e7;try{_0x1cd2e7=JSON[_0x561e6f(0x11a)](_0x2b2b92);}catch(_0x4ae9b6){const _0x37fe5d=_0x4ae9b6 instanceof Error?_0x4ae9b6['message']:String(_0x4ae9b6);throw CliErrors[_0x561e6f(0xea)](_0x44a44b+_0x561e6f(0x100)+_0x37fe5d);}if(!isPlainObject(_0x1cd2e7)||Array[_0x561e6f(0xfa)](_0x1cd2e7))throw CliErrors[_0x561e6f(0xea)](_0x44a44b+_0x561e6f(0xe5));return _0x1cd2e7;}export function validateExtendPatchKeys(_0x34ed1f){const _0x3d674b=a64_0x3b4c4e,_0x5f426f=Object['keys'](_0x34ed1f);if(_0x5f426f['length']===0x0)throw CliErrors[_0x3d674b(0xea)](_0x3d674b(0x122));for(const _0x41a400 of _0x5f426f){const _0x22adf1=EXTEND_PATCH_REDIRECTS['get'](_0x41a400);if(_0x22adf1)throw CliErrors['validation'](_0x22adf1['message'],_0x22adf1[_0x3d674b(0x114)]);if(!MUTABLE_EXTEND_KEYS[_0x3d674b(0xec)](_0x41a400))throw CliErrors['validation'](_0x3d674b(0x110)+_0x41a400,describeMutableExtendKeys());}}function a64_0x53f9(_0x3ce523,_0x346cb9){_0x3ce523=_0x3ce523-0xd9;const _0x28c859=a64_0x28c8();let _0x53f967=_0x28c859[_0x3ce523];return _0x53f967;}function describeMutableExtendKeys(){const _0x1b7777=a64_0x3b4c4e,_0x29ffcf=Array[_0x1b7777(0xf3)](MUTABLE_EXTEND_KEYS)[_0x1b7777(0x106)]();return _0x29ffcf[_0x1b7777(0xfc)]>0x0?_0x1b7777(0xeb)+_0x29ffcf[_0x1b7777(0xf1)](',\x20'):_0x1b7777(0x104);}export function applyExtendPatch(_0x5be801,_0xa02762){const _0xbe55d2=a64_0x3b4c4e;validateExtendPatchKeys(_0xa02762);const _0xe28120=deepClone(_0x5be801),_0x2ea9e4=[];for(const [_0x17c621,_0x78544f]of Object[_0xbe55d2(0xdb)](_0xa02762)){const _0x3a0d70=_0xe28120[_0x17c621],_0x1ff917=deepClone(_0x78544f);!deepEqual(_0x3a0d70,_0x1ff917)&&(_0xe28120[_0x17c621]=_0x1ff917,_0x2ea9e4[_0xbe55d2(0xf6)](_0xbe55d2(0x109)+_0x17c621));}return _0x2ea9e4['sort'](),{'after':_0xe28120,'changedPaths':_0x2ea9e4,'changed':_0x2ea9e4[_0xbe55d2(0xfc)]>0x0};}export function assertExpectation(_0x5baddb,_0x3fcce0){const _0x2ff0c7=a64_0x3b4c4e;if(!_0x3fcce0)return;for(const [_0x52d965,_0xa6cf28]of Object[_0x2ff0c7(0xdb)](_0x3fcce0)){const _0x16f999=_0x5baddb[_0x52d965];if(!deepEqual(_0x16f999,_0xa6cf28))throw CliErrors[_0x2ff0c7(0xea)](_0x2ff0c7(0x117)+_0x52d965,_0x2ff0c7(0xf4)+JSON[_0x2ff0c7(0x120)](_0xa6cf28)+_0x2ff0c7(0x10a)+JSON[_0x2ff0c7(0x120)](_0x16f999));}}export async function buildDatasetExtendUpdateResult({appCode:_0x49ece8,input:_0x374308,dryRun:_0x28bf84}){const _0x4a41fb=a64_0x3b4c4e;validateInput(_0x374308);const _0x406e2b=await getDatasetDetail(_0x374308[_0x4a41fb(0x11f)]),_0x3c164c=parseDatasetExtend(_0x406e2b['extend']),_0xa3da6a=deepClone(_0x3c164c[_0x4a41fb(0x10f)]);assertExpectation(_0xa3da6a,_0x374308[_0x4a41fb(0xee)]);const {after:_0x500f3f,changedPaths:_0x4baafe,changed:_0x1755b1}=applyExtendPatch(_0xa3da6a,_0x374308[_0x4a41fb(0xf0)]),_0x1e2974=summarizeDataset(_0x406e2b,_0x374308[_0x4a41fb(0x11f)]);return _0x1755b1&&!_0x28bf84&&(_0x406e2b['extend']=serializeDatasetExtend(_0x500f3f,_0x3c164c[_0x4a41fb(0x102)]),await updateDrivenData(_0x406e2b)),{'ok':!![],'data':{'appCode':_0x49ece8,'selector':{'code':_0x374308['code']},'dataset':_0x1e2974,'dryRun':_0x28bf84,'changed':_0x1755b1,'changedPaths':_0x4baafe,'before':{'extend':_0xa3da6a},'after':{'extend':_0x500f3f},'submitted':_0x1755b1&&!_0x28bf84},'message':_0x1755b1?_0x28bf84?_0x4a41fb(0x11d)+_0x4baafe[_0x4a41fb(0xf1)](',\x20')+')':'Updated\x20dataset\x20extend\x20('+_0x4baafe[_0x4a41fb(0xf1)](',\x20')+')':_0x4a41fb(0xf9)};}export const datasetExtendUpdate={'service':a64_0x3b4c4e(0xf2),'command':a64_0x3b4c4e(0xe4),'description':a64_0x3b4c4e(0xde),'risk':a64_0x3b4c4e(0x118),'flags':[CODE_FLAG,{'name':a64_0x3b4c4e(0xda),'type':a64_0x3b4c4e(0xf8),'required':!![],'description':a64_0x3b4c4e(0xed)},{'name':a64_0x3b4c4e(0x10d),'type':'string','required':![],'description':a64_0x3b4c4e(0x107)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x122ea0){validateInput(readExtendUpdateInput(_0x122ea0));},async 'dryRun'(_0x32c44e){const _0x4480f1=a64_0x3b4c4e,_0x1a64d8=await buildDatasetExtendUpdateResult({'appCode':_0x32c44e[_0x4480f1(0x108)],'input':readExtendUpdateInput(_0x32c44e),'dryRun':!![]});return{'method':'POST','url':_0x4480f1(0x116),'body':_0x1a64d8[_0x4480f1(0x10b)],'description':_0x1a64d8[_0x4480f1(0xdc)]};},async 'execute'(_0x219d37){const _0x24cc77=a64_0x3b4c4e;return buildDatasetExtendUpdateResult({'appCode':_0x219d37[_0x24cc77(0x108)],'input':readExtendUpdateInput(_0x219d37),'dryRun':![]});}};function readExtendUpdateInput(_0x4899c5){const _0x7cdb8d=a64_0x3b4c4e,_0x20a900=trim(_0x4899c5['str']('code')),_0x200c4e=parseJsonObjectFlag(_0x4899c5[_0x7cdb8d(0xef)]('patch-json'),_0x7cdb8d(0x11e)),_0x17d515=parseJsonObjectFlag(_0x4899c5[_0x7cdb8d(0xef)](_0x7cdb8d(0x10d)),'--expect-json');return{'code':_0x20a900,'patch':_0x200c4e||{},'expect':_0x17d515};}function validateInput(_0xa68269){const _0x5b9c80=a64_0x3b4c4e;if(!_0xa68269['code'])throw CliErrors[_0x5b9c80(0xea)](_0x5b9c80(0x11c));validateExtendPatchKeys(_0xa68269[_0x5b9c80(0xf0)]);}function parseDatasetExtend(_0x38c931){const _0xd4b487=a64_0x3b4c4e;if(typeof _0x38c931===_0xd4b487(0xf8)){const _0x172891=_0x38c931[_0xd4b487(0xe9)]();if(!_0x172891)return{'value':{},'shape':_0xd4b487(0xf8)};let _0x3e4c96;try{_0x3e4c96=JSON[_0xd4b487(0x11a)](_0x172891);}catch(_0x4b382e){const _0x4e793f=_0x4b382e instanceof Error?_0x4b382e[_0xd4b487(0xdc)]:String(_0x4b382e);throw CliErrors[_0xd4b487(0xea)](_0xd4b487(0x119)+_0x4e793f);}if(!isPlainObject(_0x3e4c96)||Array[_0xd4b487(0xfa)](_0x3e4c96))throw CliErrors['validation']('Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object');return{'value':_0x3e4c96,'shape':_0xd4b487(0xf8)};}if(_0x38c931===undefined||_0x38c931===null)return{'value':{},'shape':_0xd4b487(0xf8)};if(!isPlainObject(_0x38c931)||Array[_0xd4b487(0xfa)](_0x38c931))throw CliErrors[_0xd4b487(0xea)](_0xd4b487(0xf7));return{'value':_0x38c931,'shape':_0xd4b487(0x11b)};}function a64_0x28c8(){const _0x49c4b6=['str','patch','join','dataset','from','Expected\x20','Use\x20`rabetbase\x20dataset\x20business-group-update`\x20to\x20update\x20business\x20model\x20groups.','push','Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object','string','No\x20changes\x20for\x20dataset\x20extend','isArray','100DYkjCv','length','datasetId','7uEBYQZ','216756HfTpUj','\x20must\x20be\x20valid\x20JSON\x20object:\x20','modelCode','shape','85WeQrPf','No\x20dataset\x20extend\x20patch\x20keys\x20are\x20currently\x20supported.','24639zXCVRS','sort','JSON\x20object\x20of\x20expected\x20current\x20extend\x20values;\x20mismatch\x20aborts\x20without\x20writing','appCode','extend.',',\x20actual\x20','data','7049273FyWkZs','expect-json','tableName','value','Unsupported\x20patch\x20key:\x20','64OGwYuP','modelId','14389608novjZP','hint','businessGroup','/smartapi/dataset/update-driven-data','Expectation\x20mismatch\x20at\x20extend.','write','Dataset\x20extend\x20must\x20be\x20valid\x20JSON\x20object:\x20','parse','object','--code\x20is\x20required','Dry-run:\x20dataset\x20extend\x20would\x20change\x20(','--patch-json','code','stringify','dbId','--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key','dbName','patch-json','entries','message','13332qilCnN','Patch\x20dataset\x20top-level\x20extend\x20safely','dataset\x20extend-update\x20does\x20not\x20support\x20businessGroup;\x20use\x20dataset\x20business-group-update','datasetCode','name','351dVuVax','1067896eBNknp','extend-update','\x20must\x20be\x20a\x20JSON\x20object','datasetName','dbtableConfig','11050zgOMGz','trim','validation','Allowed\x20keys:\x20','has','JSON\x20object\x20patch\x20for\x20dataset\x20top-level\x20extend;\x20current\x20allowlist\x20is\x20empty','expect'];a64_0x28c8=function(){return _0x49c4b6;};return a64_0x28c8();}function serializeDatasetExtend(_0x35290e,_0x4abfab){return _0x4abfab==='string'?JSON['stringify'](_0x35290e):_0x35290e;}function summarizeDataset(_0x265ab0,_0x5bbc81){const _0x5243ad=a64_0x3b4c4e,_0xe02026=isPlainObject(_0x265ab0[_0x5243ad(0xf2)])?_0x265ab0[_0x5243ad(0xf2)]:{},_0x2c0191=isPlainObject(_0x265ab0['dbtableConfig'])?_0x265ab0[_0x5243ad(0xe7)]:{};return{'id':_0x265ab0[_0x5243ad(0x112)]??_0x265ab0['id']??_0xe02026[_0x5243ad(0xfd)]??null,'code':_0x265ab0[_0x5243ad(0x101)]??_0x265ab0[_0x5243ad(0x11f)]??_0xe02026[_0x5243ad(0xe0)]??_0x5bbc81,'name':_0x265ab0[_0x5243ad(0xe1)]??_0xe02026[_0x5243ad(0xe6)]??null,'table':_0x2c0191[_0x5243ad(0x10e)]??_0xe02026['tableName']??null,'db':_0x2c0191[_0x5243ad(0xd9)]??_0x2c0191[_0x5243ad(0x121)]??null};}function deepClone(_0x52dd6b){const _0x3b64f5=a64_0x3b4c4e;if(_0x52dd6b===undefined)return _0x52dd6b;return JSON[_0x3b64f5(0x11a)](JSON[_0x3b64f5(0x120)](_0x52dd6b));}function deepEqual(_0x19bbea,_0x17d8b9){const _0x493ca6=a64_0x3b4c4e;return JSON[_0x493ca6(0x120)](_0x19bbea)===JSON['stringify'](_0x17d8b9);}function isPlainObject(_0x5763df){const _0x2c2ee6=a64_0x3b4c4e;return Boolean(_0x5763df)&&typeof _0x5763df===_0x2c2ee6(0x11b)&&!Array[_0x2c2ee6(0xfa)](_0x5763df);}function trim(_0x209999){const _0x2ddbf5=a64_0x3b4c4e,_0x4e0ea2=String(_0x209999||'')[_0x2ddbf5(0xe9)]();return _0x4e0ea2;}
|