@lovrabet/rabetbase-cli 2.5.0-beta.2 → 2.5.0-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/generate-sdk-config-file.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/delete.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-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/table-diff-shared.d.ts +13 -0
- package/lib/commands/db/table-diff-shared.js +1 -0
- 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/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/domain-config.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/paths.js +1 -1
- package/lib/constant/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/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 -7
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/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/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/rabetbase/SKILL.md +6 -6
- package/skills/rabetbase/guides/custom-page-workflow.md +1 -1
- package/skills/rabetbase/guides/database-connection-workflow.md +9 -9
- package/skills/rabetbase/references/rabetbase-config.md +2 -3
- package/skills/rabetbase/references/rabetbase-db-analyze.md +2 -2
- package/skills/rabetbase/references/rabetbase-db-diff-refresh.md +4 -3
- package/skills/rabetbase/references/rabetbase-db-diff.md +7 -22
- package/skills/rabetbase/references/rabetbase-db-tables.md +14 -2
- package/skills/rabetbase/references/rabetbase-page-custom-list.md +5 -2
- package/skills/rabetbase.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const a140_0x44f68b=a140_0x49a1;(function(_0x4d0292,_0x4203df){const _0xc808c8=a140_0x49a1,_0x380491=_0x4d0292();while(!![]){try{const _0x37025c=-parseInt(_0xc808c8(0x196))/0x1+parseInt(_0xc808c8(0x1d8))/0x2+parseInt(_0xc808c8(0x200))/0x3*(-parseInt(_0xc808c8(0x19c))/0x4)+-parseInt(_0xc808c8(0x1a6))/0x5+parseInt(_0xc808c8(0x1fd))/0x6+parseInt(_0xc808c8(0x193))/0x7*(-parseInt(_0xc808c8(0x1bf))/0x8)+parseInt(_0xc808c8(0x1c7))/0x9*(parseInt(_0xc808c8(0x1e5))/0xa);if(_0x37025c===_0x4203df)break;else _0x380491['push'](_0x380491['shift']());}catch(_0x13d8eb){_0x380491['push'](_0x380491['shift']());}}}(a140_0x5f46,0xdd11b));import{readFile}from'node:fs/promises';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getNotificationChannelConfig}from'../../core/api-client.js';import{CliError,CliErrors}from'../../errors.js';function a140_0x49a1(_0x31e9d3,_0x292937){_0x31e9d3=_0x31e9d3-0x193;const _0x5f46bc=a140_0x5f46();let _0x49a18a=_0x5f46bc[_0x31e9d3];return _0x49a18a;}export const NOTIFICATION_CHANNEL_TYPES=[a140_0x44f68b(0x1be),a140_0x44f68b(0x1b1),a140_0x44f68b(0x1c5),a140_0x44f68b(0x202),a140_0x44f68b(0x1b7)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a140_0x44f68b(0x19d),'channelType',a140_0x44f68b(0x19e),a140_0x44f68b(0x1c9),a140_0x44f68b(0x20b),a140_0x44f68b(0x1eb),a140_0x44f68b(0x1e7)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a140_0x44f68b(0x1cf),a140_0x44f68b(0x19a),a140_0x44f68b(0x1c1)]),EMAIL_RECIPIENT_FIELDS=new Set([a140_0x44f68b(0x1f8),a140_0x44f68b(0x199),a140_0x44f68b(0x1dc),a140_0x44f68b(0x1b8),'replyTo',a140_0x44f68b(0x212),a140_0x44f68b(0x1b9),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':a140_0x44f68b(0x208),'type':'string','required':![],'description':a140_0x44f68b(0x1ba)},{'name':a140_0x44f68b(0x1e8),'type':a140_0x44f68b(0x1c0),'required':![],'default':![],'description':a140_0x44f68b(0x1cd)},{'name':a140_0x44f68b(0x20d),'type':'string','required':![],'description':a140_0x44f68b(0x1c3)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a140_0x44f68b(0x1c2),'required':!![],'description':a140_0x44f68b(0x1a4)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x4fb839,_0x2329a5,_0x2b0e0a){return new CliError(_0x4fb839,0x1,_0x2329a5,_0x2b0e0a);}export function readNotificationId(_0x344b66){const _0x2f0b50=a140_0x44f68b,_0x1f05be=_0x344b66['num']('id');if(!Number[_0x2f0b50(0x1d4)](_0x1f05be)||_0x1f05be<=0x0)throw notificationError(_0x2f0b50(0x1c8),_0x2f0b50(0x213));return _0x1f05be;}export function requireNotificationExplicitYes(_0x5bd2f3){const _0x5a67dc=a140_0x44f68b;if(_0x5bd2f3[_0x5a67dc(0x1a5)](_0x5a67dc(0x1d5))||_0x5bd2f3[_0x5a67dc(0x1a5)](_0x5a67dc(0x1e4)))return;throw notificationError(_0x5a67dc(0x1bc),_0x5a67dc(0x19f),'Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.');}export function readNotificationChannelType(_0x5a439b,_0x513557='type',_0x184ac5=a140_0x44f68b(0x1be)){const _0x24d7a8=a140_0x44f68b,_0x4854ff=_0x5a439b[_0x24d7a8(0x1de)](_0x513557)['trim']()||_0x184ac5;if(!NOTIFICATION_CHANNEL_TYPES[_0x24d7a8(0x197)](_0x4854ff))throw CliErrors[_0x24d7a8(0x217)](_0x24d7a8(0x1e6)+_0x513557+':\x20'+_0x4854ff,_0x24d7a8(0x1b3)+NOTIFICATION_CHANNEL_TYPES[_0x24d7a8(0x195)](',\x20')+'.');return _0x4854ff;}function a140_0x5f46(){const _0x31ecb8=['str','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','preflight','failed','updateTime','notification_config_source_unavailable','yes','4160mQShXN','Invalid\x20--','readTimeout','stdin','notification_config_update_empty','channelType','connectTimeout','notification_config_json_invalid','string','isArray','name','Notification\x20JSON\x20from\x20','endpointUrl:null','\x20characters.','path','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','every','\x20has\x20an\x20invalid\x20channelType.','emailTargets','\x22\x20must\x20be\x20a\x20non-empty\x20string.','prototype','\x20has\x20an\x20unsupported\x20channelType.','\x22\x20is\x20forbidden.','2904150IUCdKP','Notification\x20JSON\x20source\x20is\x20ambiguous.','\x22configName\x22.','22668UPiOZD','\x20--type\x20','WECOM','some','Notification\x20JSON\x20channelConfig\x20field\x20\x22','object','notification_config_field_invalid','keys','file','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','messageTemplate','description','a\x20JSON\x20object','from-env','\x20failed.','\x20has\x20an\x20invalid\x20id.','kind','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','subjectPrefix','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','a\x20non-empty\x20string','length','Unknown\x20notification\x20JSON\x20field\x20\x22','validation','createTime','3409tXWTNk','Notification\x20JSON\x20field\x20\x22','join','289886IVGxVK','includes','environment\x20variable\x20','recipients','configCode','setEncoding','544wJRODN','configName','endpointUrl','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','\x20has\x20an\x20invalid\x20appCode.','push','utf8','Notification\x20config\x20','Application-level\x20notification\x20config\x20ID','bool','3038535GFRjMB','has','notification_config_field_unknown','\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','notification_config_response_invalid','Create\x20JSON\x20requires\x20field\x20','update','_unavailable','trim','entries','env','FEISHU','channelConfigRaw','Allowed\x20values:\x20','apiError','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','notification_config_','WEBHOOK','bccList','fromName','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','notification_config_field_required','notification_config_confirmation_required','\x22channelType\x22.','EMAIL','26792WBouhO','boolean','channelCode','number','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','DINGTALK','file\x20','85383VfxbkC','notification_config_id_invalid','channelConfig','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','Missing\x20notification\x20JSON\x20source.','endpointUrlRaw','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','Notification\x20config\x20list\x20item\x20','appCode','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','hasOwnProperty','a\x20string\x20or\x20null','Invalid\x20notification\x20config\x20response.','isSafeInteger','dry-run','\x20is\x20missing\x20required\x20field\x20\x22','\x22\x20cannot\x20exceed\x20','62108HAZkAK','notification_config_field_forbidden','a\x20JSON\x20object\x20or\x20null','\x20has\x20invalid\x20field\x20\x22','ccList','parse'];a140_0x5f46=function(){return _0x31ecb8;};return a140_0x5f46();}export function assertSingleNotificationSource(_0xed34a7){const _0x3e9861=a140_0x44f68b,_0x530957=[],_0x4018e2=_0xed34a7[_0x3e9861(0x1de)](_0x3e9861(0x208))[_0x3e9861(0x1ae)]();if(_0x4018e2)_0x530957[_0x3e9861(0x1a1)]({'kind':'file','path':_0x4018e2});if(_0xed34a7[_0x3e9861(0x1a5)](_0x3e9861(0x1e8)))_0x530957[_0x3e9861(0x1a1)]({'kind':_0x3e9861(0x1e8)});const _0x4c72ef=_0xed34a7['str'](_0x3e9861(0x20d))[_0x3e9861(0x1ae)]();if(_0x4c72ef)_0x530957[_0x3e9861(0x1a1)]({'kind':_0x3e9861(0x1b0),'name':_0x4c72ef});if(_0x530957['length']===0x0)throw CliErrors[_0x3e9861(0x217)](_0x3e9861(0x1cb),'Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.');if(_0x530957[_0x3e9861(0x215)]>0x1)throw CliErrors[_0x3e9861(0x217)](_0x3e9861(0x1fe),_0x3e9861(0x1b5));return _0x530957[0x0];}export async function readNotificationDocument(_0x1cc23c,_0x5c2167){const _0x20b60a=a140_0x44f68b,_0x226e06=assertSingleNotificationSource(_0x1cc23c),_0xc1c038=_0x226e06['kind']===_0x20b60a(0x208)?_0x20b60a(0x1c6)+_0x226e06[_0x20b60a(0x1f3)]:_0x226e06[_0x20b60a(0x210)]===_0x20b60a(0x1b0)?_0x20b60a(0x198)+_0x226e06['name']:_0x20b60a(0x1e8);let _0x53b199;try{if(_0x226e06[_0x20b60a(0x210)]===_0x20b60a(0x208))_0x53b199=await readFile(_0x226e06[_0x20b60a(0x1f3)],_0x20b60a(0x1a2));else{if(_0x226e06[_0x20b60a(0x210)]===_0x20b60a(0x1b0)){if(!(_0x226e06[_0x20b60a(0x1ef)]in process.env))throw notificationError(_0x20b60a(0x1e3),_0x20b60a(0x209)+_0x226e06['name']);_0x53b199=process.env[_0x226e06.name]??'';}else _0x53b199=await readStdin();}}catch(_0x59bf7e){if(_0x59bf7e instanceof CliError)throw _0x59bf7e;throw notificationError(_0x20b60a(0x1e3),_0x20b60a(0x1f5)+_0xc1c038+'.');}let _0x265acb;try{_0x265acb=JSON[_0x20b60a(0x1dd)](_0x53b199);}catch{throw notificationError(_0x20b60a(0x1ec),_0x20b60a(0x1f0)+_0xc1c038+'\x20is\x20invalid.',_0x20b60a(0x1d0));}if(!isJsonObject(_0x265acb))throw notificationError(_0x20b60a(0x1ec),_0x20b60a(0x1f0)+_0xc1c038+'\x20must\x20be\x20an\x20object.');return validateNotificationDocument(_0x265acb,_0x5c2167);}export function projectNotificationListConfig(_0x197cc4,_0x37aea4){const _0x11c78d=a140_0x44f68b;return{'id':typeof _0x197cc4['id']===_0x11c78d(0x1c2)?_0x197cc4['id']:null,'configCode':requireResponseString(_0x197cc4[_0x11c78d(0x19a)],'configCode',_0x37aea4),'configName':requireResponseString(_0x197cc4[_0x11c78d(0x19d)],_0x11c78d(0x19d),_0x37aea4),'channelType':requireResponseString(_0x197cc4[_0x11c78d(0x1ea)],_0x11c78d(0x1ea),_0x37aea4),'description':normalizeNullableString(_0x197cc4[_0x11c78d(0x20b)]),'createTime':normalizeNullableString(_0x197cc4[_0x11c78d(0x218)]),'updateTime':normalizeNullableString(_0x197cc4[_0x11c78d(0x1e2)])};}export function normalizeExactNotificationConfig(_0x121367,_0x546d71,_0x2951c0){const _0x5c6f3a=a140_0x44f68b;if(!Number[_0x5c6f3a(0x1d4)](_0x121367['id'])||_0x121367['id']!==_0x546d71)throw notificationError(_0x5c6f3a(0x1aa),_0x5c6f3a(0x211)+_0x546d71+'.');if(_0x121367[_0x5c6f3a(0x1cf)]!==_0x2951c0)throw notificationError(_0x5c6f3a(0x1aa),_0x5c6f3a(0x1a3)+_0x546d71+'\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.');const _0x524c22=requireExactString(_0x121367[_0x5c6f3a(0x19d)],_0x5c6f3a(0x19d),_0x546d71),_0x1b86d6=requireExactString(_0x121367['configCode'],_0x5c6f3a(0x19a),_0x546d71),_0x313d66=requireExactString(_0x121367[_0x5c6f3a(0x1ea)],'channelType',_0x546d71);if(!NOTIFICATION_CHANNEL_TYPES[_0x5c6f3a(0x197)](_0x313d66))throw notificationError(_0x5c6f3a(0x1aa),_0x5c6f3a(0x1a3)+_0x546d71+_0x5c6f3a(0x1fb));const _0x1d725c=responseNullableString(_0x121367[_0x5c6f3a(0x19e)],_0x5c6f3a(0x19e),_0x546d71),_0x25d7f8=responseNullableString(_0x121367['channelConfig'],_0x5c6f3a(0x1c9),_0x546d71),_0x10d214=responseNullableString(_0x121367[_0x5c6f3a(0x20b)],'description',_0x546d71),_0x379427=responseNullableTimeout(_0x121367['connectTimeout'],_0x5c6f3a(0x1eb),_0x546d71),_0x7941d9=responseNullableTimeout(_0x121367[_0x5c6f3a(0x1e7)],'readTimeout',_0x546d71);return{'id':_0x546d71,'appCode':_0x2951c0,'configCode':_0x1b86d6,'configName':_0x524c22,'channelType':_0x313d66,'endpointUrl':redactSensitive(_0x1d725c),'channelConfig':redactSensitive(_0x25d7f8),'description':_0x10d214,'connectTimeout':_0x379427,'readTimeout':_0x7941d9,'endpointUrlRaw':_0x1d725c,'channelConfigRaw':_0x25d7f8};}export async function requireExactNotificationConfig(_0x725001,_0x5b8e0d,_0x17a880){const _0x19a6cd=a140_0x44f68b;let _0x233e58;try{_0x233e58=await getNotificationChannelConfig(_0x5b8e0d,_0x725001);}catch{throw safeApiFailure(_0x17a880,_0x19a6cd(0x1e0),_0x19a6cd(0x1df)+_0x725001+_0x19a6cd(0x1ca));}return normalizeExactNotificationConfig(_0x233e58,_0x5b8e0d,_0x725001);}export function projectNotificationConfig(_0x41be3f){const _0x56f654=a140_0x44f68b;return{'id':_0x41be3f['id']??null,'appCode':_0x41be3f[_0x56f654(0x1cf)],'configCode':_0x41be3f[_0x56f654(0x19a)]??null,'configName':_0x41be3f[_0x56f654(0x19d)],'channelType':_0x41be3f[_0x56f654(0x1ea)],'endpointUrl':redactSensitive(_0x41be3f[_0x56f654(0x19e)]),'channelConfig':redactSensitive(_0x41be3f[_0x56f654(0x1c9)]),'description':_0x41be3f[_0x56f654(0x20b)]??null,'connectTimeout':_0x41be3f['connectTimeout']??null,'readTimeout':_0x41be3f[_0x56f654(0x1e7)]??null};}export function notificationSelector(_0x276c2c){const _0x2806cb=a140_0x44f68b;return{'appCode':_0x276c2c['appCode'],'id':_0x276c2c['id'],'configCode':_0x276c2c[_0x2806cb(0x19a)],'configName':_0x276c2c[_0x2806cb(0x19d)],'channelType':_0x276c2c['channelType']};}export function createMutationInput(_0x289c4a,_0xc74100){const _0x257d4a=a140_0x44f68b;return{'appCode':_0x289c4a,'configName':_0xc74100[_0x257d4a(0x19d)],'channelType':_0xc74100[_0x257d4a(0x1ea)],...hasOwn(_0xc74100,'endpointUrl')?{'endpointUrl':_0xc74100[_0x257d4a(0x19e)]}:{},...hasOwn(_0xc74100,_0x257d4a(0x1c9))?{'channelConfig':serializeChannelConfig(_0xc74100[_0x257d4a(0x1c9)])}:{},...hasOwn(_0xc74100,_0x257d4a(0x20b))?{'description':_0xc74100['description']}:{},...hasOwn(_0xc74100,_0x257d4a(0x1eb))?{'connectTimeout':_0xc74100['connectTimeout']}:{},...hasOwn(_0xc74100,_0x257d4a(0x1e7))?{'readTimeout':_0xc74100['readTimeout']}:{}};}export function mergeUpdateInput(_0x3c4d77,_0x7372cc){const _0xfb4f8e=a140_0x44f68b;return{'id':_0x3c4d77['id'],'appCode':_0x3c4d77[_0xfb4f8e(0x1cf)],'configName':_0x7372cc[_0xfb4f8e(0x19d)]??_0x3c4d77['configName'],'channelType':_0x7372cc[_0xfb4f8e(0x1ea)]??_0x3c4d77[_0xfb4f8e(0x1ea)],'endpointUrl':hasOwn(_0x7372cc,_0xfb4f8e(0x19e))?_0x7372cc[_0xfb4f8e(0x19e)]:_0x3c4d77[_0xfb4f8e(0x1cc)],'channelConfig':hasOwn(_0x7372cc,_0xfb4f8e(0x1c9))?serializeChannelConfig(_0x7372cc[_0xfb4f8e(0x1c9)]):_0x3c4d77[_0xfb4f8e(0x1b2)],'description':hasOwn(_0x7372cc,'description')?_0x7372cc[_0xfb4f8e(0x20b)]:_0x3c4d77[_0xfb4f8e(0x20b)],'connectTimeout':hasOwn(_0x7372cc,_0xfb4f8e(0x1eb))?_0x7372cc[_0xfb4f8e(0x1eb)]:_0x3c4d77[_0xfb4f8e(0x1eb)],'readTimeout':hasOwn(_0x7372cc,_0xfb4f8e(0x1e7))?_0x7372cc[_0xfb4f8e(0x1e7)]:_0x3c4d77[_0xfb4f8e(0x1e7)]};}export function plannedUpdateProjection(_0x227d22,_0x4a7157){const _0x193341=a140_0x44f68b;return projectNotificationConfig({'id':_0x227d22['id'],'appCode':_0x227d22['appCode'],'configCode':_0x227d22['configCode'],'configName':_0x4a7157[_0x193341(0x19d)]??_0x227d22[_0x193341(0x19d)],'channelType':_0x4a7157['channelType']??_0x227d22[_0x193341(0x1ea)],'endpointUrl':hasOwn(_0x4a7157,_0x193341(0x19e))?_0x4a7157[_0x193341(0x19e)]:_0x227d22[_0x193341(0x1cc)],'channelConfig':hasOwn(_0x4a7157,_0x193341(0x1c9))?_0x4a7157[_0x193341(0x1c9)]:_0x227d22['channelConfigRaw'],'description':hasOwn(_0x4a7157,_0x193341(0x20b))?_0x4a7157[_0x193341(0x20b)]:_0x227d22[_0x193341(0x20b)],'connectTimeout':hasOwn(_0x4a7157,_0x193341(0x1eb))?_0x4a7157[_0x193341(0x1eb)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x227d22[_0x193341(0x1eb)],'readTimeout':hasOwn(_0x4a7157,_0x193341(0x1e7))?_0x4a7157[_0x193341(0x1e7)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x227d22[_0x193341(0x1e7)]});}export function requestedSafeFieldsMatch(_0x4ec6d6,_0x11a844,_0x8abafe){const _0x251781=a140_0x44f68b,_0x5dbf13=[],_0xe656fb=[],_0x400ca1=[];for(const _0x1b901c of[_0x251781(0x19d),'channelType',_0x251781(0x20b)]){if(!hasOwn(_0x8abafe,_0x1b901c))continue;_0x400ca1[_0x251781(0x1a1)](_0x1b901c),_0x5dbf13[_0x251781(0x1a1)](_0x11a844[_0x1b901c]===_0x8abafe[_0x1b901c]),_0xe656fb[_0x251781(0x1a1)](_0x4ec6d6[_0x1b901c]!==_0x8abafe[_0x1b901c]&&_0x11a844[_0x1b901c]===_0x8abafe[_0x1b901c]);}for(const _0x549d37 of[_0x251781(0x1eb),_0x251781(0x1e7)]){if(!hasOwn(_0x8abafe,_0x549d37))continue;const _0x4fc70f=_0x8abafe[_0x549d37]??(_0x549d37===_0x251781(0x1eb)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x400ca1['push'](_0x549d37),_0x5dbf13[_0x251781(0x1a1)](_0x11a844[_0x549d37]===_0x4fc70f),_0xe656fb[_0x251781(0x1a1)](_0x4ec6d6[_0x549d37]!==_0x4fc70f&&_0x11a844[_0x549d37]===_0x4fc70f);}return hasOwn(_0x8abafe,_0x251781(0x19e))&&_0x8abafe[_0x251781(0x19e)]===null&&(_0x400ca1[_0x251781(0x1a1)](_0x251781(0x1f1)),_0x5dbf13['push'](_0x11a844['endpointUrlRaw']===null||_0x11a844[_0x251781(0x1cc)]===''),_0xe656fb[_0x251781(0x1a1)](_0x4ec6d6[_0x251781(0x1cc)]!==null&&_0x4ec6d6['endpointUrlRaw']!==''&&(_0x11a844[_0x251781(0x1cc)]===null||_0x11a844['endpointUrlRaw']===''))),{'allMatch':_0x5dbf13[_0x251781(0x1f6)](Boolean),'provesChange':_0xe656fb[_0x251781(0x203)](Boolean),'verifiedFields':_0x400ca1};}export function validateNotificationDeleteReadback(_0x5db92b,_0x5a8cbb,_0x15b108){const _0x3753a1=a140_0x44f68b;for(const [_0x17d30c,_0x2d2ca1]of _0x5db92b[_0x3753a1(0x1af)]()){if(!Number['isSafeInteger'](_0x2d2ca1['id'])||_0x2d2ca1['id']<=0x0)throw notificationError(_0x3753a1(0x1aa),_0x3753a1(0x1ce)+(_0x17d30c+0x1)+_0x3753a1(0x20f));if(_0x2d2ca1[_0x3753a1(0x1cf)]!==_0x5a8cbb)throw notificationError(_0x3753a1(0x1aa),_0x3753a1(0x1ce)+(_0x17d30c+0x1)+_0x3753a1(0x1a0));if(_0x2d2ca1[_0x3753a1(0x1ea)]!==_0x15b108)throw notificationError(_0x3753a1(0x1aa),'Notification\x20config\x20list\x20item\x20'+(_0x17d30c+0x1)+_0x3753a1(0x1f7));}}export function safeApiFailure(_0x53286e,_0x26178b,_0x4886eb){const _0x15e3ca=a140_0x44f68b;return notificationError(_0x15e3ca(0x1b6)+_0x53286e+'_'+(_0x26178b==='mutation'?_0x15e3ca(0x1e1):_0x26178b+_0x15e3ca(0x1ad)),_0x15e3ca(0x1a3)+_0x53286e+'\x20'+_0x26178b+_0x15e3ca(0x20e),_0x4886eb);}export function notificationLookupCommand(_0x1c5ca9,_0x1b2d81){const _0x31d6ce=a140_0x44f68b;return'rabetbase\x20notification\x20config-list\x20--appcode\x20'+_0x1c5ca9+_0x31d6ce(0x201)+_0x1b2d81+'\x20--format\x20compress';}function validateNotificationDocument(_0x13766b,_0xafc204){const _0x7e0f8b=a140_0x44f68b;for(const _0x4342a3 of Object[_0x7e0f8b(0x207)](_0x13766b)){if(FORBIDDEN_IDENTITY_FIELDS[_0x7e0f8b(0x1a7)](_0x4342a3))throw notificationError(_0x7e0f8b(0x1d9),_0x7e0f8b(0x194)+_0x4342a3+_0x7e0f8b(0x1a9));if(!ALLOWED_INPUT_FIELDS[_0x7e0f8b(0x1a7)](_0x4342a3))throw notificationError(_0x7e0f8b(0x1a8),_0x7e0f8b(0x216)+_0x4342a3+'\x22.');}if(_0xafc204===_0x7e0f8b(0x1ac)&&Object[_0x7e0f8b(0x207)](_0x13766b)[_0x7e0f8b(0x215)]===0x0)throw notificationError(_0x7e0f8b(0x1e9),_0x7e0f8b(0x1f4));const _0x1eb247={};if(hasOwn(_0x13766b,_0x7e0f8b(0x19d)))_0x1eb247[_0x7e0f8b(0x19d)]=validateRequiredString(_0x13766b['configName'],'configName',0x80);else{if(_0xafc204==='create')throw notificationError(_0x7e0f8b(0x1bb),'Create\x20JSON\x20requires\x20field\x20'+_0x7e0f8b(0x1ff));}if(hasOwn(_0x13766b,'channelType')){if(typeof _0x13766b[_0x7e0f8b(0x1ea)]!==_0x7e0f8b(0x1ed))throw invalidFieldType(_0x7e0f8b(0x1ea),'a\x20supported\x20string');const _0x2a1d4b=_0x13766b[_0x7e0f8b(0x1ea)][_0x7e0f8b(0x1ae)]();if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x2a1d4b))throw notificationError('notification_config_field_invalid',_0x7e0f8b(0x1c4),_0x7e0f8b(0x1b3)+NOTIFICATION_CHANNEL_TYPES[_0x7e0f8b(0x195)](',\x20')+'.');_0x1eb247[_0x7e0f8b(0x1ea)]=_0x2a1d4b;}else{if(_0xafc204==='create')throw notificationError(_0x7e0f8b(0x1bb),_0x7e0f8b(0x1ab)+_0x7e0f8b(0x1bd));}for(const [_0x4d59df,_0x4c764c]of[[_0x7e0f8b(0x19e),0x200],[_0x7e0f8b(0x20b),0x100]]){if(!hasOwn(_0x13766b,_0x4d59df))continue;const _0x30f782=_0x13766b[_0x4d59df];if(_0x30f782!==null&&typeof _0x30f782!==_0x7e0f8b(0x1ed))throw invalidFieldType(_0x4d59df,_0x7e0f8b(0x1d2));if(typeof _0x30f782==='string'&&_0x30f782[_0x7e0f8b(0x215)]>_0x4c764c)throw notificationError(_0x7e0f8b(0x206),_0x7e0f8b(0x194)+_0x4d59df+_0x7e0f8b(0x1d7)+_0x4c764c+_0x7e0f8b(0x1f2));_0x1eb247[_0x4d59df]=_0x30f782;}if(hasOwn(_0x13766b,_0x7e0f8b(0x1c9))){const _0xbc2670=_0x13766b[_0x7e0f8b(0x1c9)];if(_0xbc2670===null&&_0xafc204==='create')throw invalidFieldType(_0x7e0f8b(0x1c9),_0x7e0f8b(0x20c));if(_0xbc2670!==null&&!isJsonObject(_0xbc2670))throw invalidFieldType(_0x7e0f8b(0x1c9),_0xafc204===_0x7e0f8b(0x1ac)?_0x7e0f8b(0x1da):_0x7e0f8b(0x20c));_0xbc2670!==null&&validateChannelConfigFields(_0x1eb247['channelType'],_0xbc2670),_0x1eb247['channelConfig']=_0xbc2670;}for(const _0x398caf of[_0x7e0f8b(0x1eb),'readTimeout']){if(!hasOwn(_0x13766b,_0x398caf))continue;const _0x5bcb76=_0x13766b[_0x398caf];if(_0x5bcb76!==null&&(!Number[_0x7e0f8b(0x1d4)](_0x5bcb76)||_0x5bcb76<0x0))throw notificationError('notification_config_field_invalid',_0x7e0f8b(0x194)+_0x398caf+'\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.');_0x1eb247[_0x398caf]=_0x5bcb76;}return _0x1eb247;}function validateRequiredString(_0x30b755,_0x8e6df4,_0x560c2f){const _0x459737=a140_0x44f68b;if(typeof _0x30b755!=='string')throw invalidFieldType(_0x8e6df4,_0x459737(0x214));const _0x5cc003=_0x30b755[_0x459737(0x1ae)]();if(!_0x5cc003)throw notificationError(_0x459737(0x206),_0x459737(0x194)+_0x8e6df4+_0x459737(0x1f9));if(_0x5cc003[_0x459737(0x215)]>_0x560c2f)throw notificationError('notification_config_field_invalid',_0x459737(0x194)+_0x8e6df4+_0x459737(0x1d7)+_0x560c2f+_0x459737(0x1f2));return _0x5cc003;}function validateChannelConfigFields(_0x1faa68,_0x1bd492){const _0x425849=a140_0x44f68b;if(hasOwn(_0x1bd492,_0x425849(0x20a)))throw forbiddenChannelConfigField(_0x425849(0x20a));if(_0x1faa68===_0x425849(0x1be))for(const _0x4ae7b6 of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x1bd492,_0x4ae7b6))throw forbiddenChannelConfigField(_0x4ae7b6);}}function forbiddenChannelConfigField(_0x418709){const _0x1b1eac=a140_0x44f68b;return notificationError('notification_config_channel_field_forbidden',_0x1b1eac(0x204)+_0x418709+_0x1b1eac(0x1fc));}function invalidFieldType(_0x5d0a87,_0x5e8bcf){return notificationError('notification_config_field_invalid','Notification\x20JSON\x20field\x20\x22'+_0x5d0a87+'\x22\x20must\x20be\x20'+_0x5e8bcf+'.');}function serializeChannelConfig(_0x4f29e3){return _0x4f29e3===null||_0x4f29e3===undefined?null:JSON['stringify'](_0x4f29e3);}function redactSensitive(_0x563e99){return _0x563e99===null||_0x563e99===undefined||_0x563e99===''?null:'<redacted>';}function requireResponseString(_0x150572,_0x2e6b3a,_0x407725){const _0x455c6a=a140_0x44f68b;if(typeof _0x150572!==_0x455c6a(0x1ed)||_0x150572[_0x455c6a(0x1ae)]()==='')throw CliErrors[_0x455c6a(0x1b4)](_0x455c6a(0x1d3),'Item\x20'+(_0x407725+0x1)+_0x455c6a(0x1d6)+_0x2e6b3a+'\x22.');return _0x150572[_0x455c6a(0x1ae)]();}function requireExactString(_0x3c2528,_0x11d0d6,_0x2fd26e){const _0x31094a=a140_0x44f68b;if(typeof _0x3c2528!==_0x31094a(0x1ed)||_0x3c2528[_0x31094a(0x1ae)]()==='')throw notificationError('notification_config_response_invalid','Notification\x20config\x20'+_0x2fd26e+'\x20is\x20missing\x20required\x20field\x20\x22'+_0x11d0d6+'\x22.');return _0x3c2528[_0x31094a(0x1ae)]();}function responseNullableString(_0x377842,_0x2bda90,_0x3ec668){const _0x3fea37=a140_0x44f68b;if(_0x377842===undefined||_0x377842===null)return null;if(typeof _0x377842!==_0x3fea37(0x1ed))throw notificationError('notification_config_response_invalid',_0x3fea37(0x1a3)+_0x3ec668+_0x3fea37(0x1db)+_0x2bda90+'\x22.');return _0x377842;}function responseNullableTimeout(_0x27ae9e,_0x5d4c9b,_0x2a5b02){const _0x1c4e88=a140_0x44f68b;if(_0x27ae9e===undefined||_0x27ae9e===null)return null;if(!Number['isSafeInteger'](_0x27ae9e)||_0x27ae9e<0x0)throw notificationError(_0x1c4e88(0x1aa),_0x1c4e88(0x1a3)+_0x2a5b02+_0x1c4e88(0x1db)+_0x5d4c9b+'\x22.');return _0x27ae9e;}function normalizeNullableString(_0x2af64){const _0x490a86=a140_0x44f68b;return typeof _0x2af64===_0x490a86(0x1ed)?_0x2af64:null;}function isJsonObject(_0x279a6b){const _0x1f6026=a140_0x44f68b;return _0x279a6b!==null&&typeof _0x279a6b===_0x1f6026(0x205)&&!Array[_0x1f6026(0x1ee)](_0x279a6b);}function hasOwn(_0xb870b5,_0x2407ab){const _0x4f9aae=a140_0x44f68b;return Object[_0x4f9aae(0x1fa)][_0x4f9aae(0x1d1)]['call'](_0xb870b5,_0x2407ab);}async function readStdin(){const _0x126e98=a140_0x44f68b;let _0x2e50e6='';process[_0x126e98(0x1e8)][_0x126e98(0x19b)](_0x126e98(0x1a2));for await(const _0x5a5aec of process[_0x126e98(0x1e8)])_0x2e50e6+=_0x5a5aec;return _0x2e50e6;}
|
|
1
|
+
const a141_0x2db6f7=a141_0x4b17;(function(_0x58c8a1,_0x498288){const _0x23d892=a141_0x4b17,_0x3f8f57=_0x58c8a1();while(!![]){try{const _0x3708f3=parseInt(_0x23d892(0x84))/0x1*(parseInt(_0x23d892(0xc0))/0x2)+-parseInt(_0x23d892(0xf6))/0x3+-parseInt(_0x23d892(0xd1))/0x4+-parseInt(_0x23d892(0xe7))/0x5+-parseInt(_0x23d892(0xff))/0x6+parseInt(_0x23d892(0x95))/0x7*(-parseInt(_0x23d892(0x9b))/0x8)+-parseInt(_0x23d892(0xed))/0x9*(-parseInt(_0x23d892(0xb7))/0xa);if(_0x3708f3===_0x498288)break;else _0x3f8f57['push'](_0x3f8f57['shift']());}catch(_0x18bb11){_0x3f8f57['push'](_0x3f8f57['shift']());}}}(a141_0x216a,0xd6485));import{readFile}from'node:fs/promises';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getNotificationChannelConfig}from'../../core/api-client.js';import{CliError,CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=[a141_0x2db6f7(0x92),a141_0x2db6f7(0xe9),a141_0x2db6f7(0xd6),a141_0x2db6f7(0x93),a141_0x2db6f7(0xfb)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set(['configName','channelType',a141_0x2db6f7(0xb2),a141_0x2db6f7(0x90),a141_0x2db6f7(0xd9),a141_0x2db6f7(0xe5),a141_0x2db6f7(0xaf)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id','appCode',a141_0x2db6f7(0xe6),a141_0x2db6f7(0x8a)]),EMAIL_RECIPIENT_FIELDS=new Set([a141_0x2db6f7(0x9d),a141_0x2db6f7(0x97),a141_0x2db6f7(0xac),a141_0x2db6f7(0xbb),a141_0x2db6f7(0x7d),'subjectPrefix',a141_0x2db6f7(0x7f),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':'file','type':'string','required':![],'description':a141_0x2db6f7(0x9f)},{'name':a141_0x2db6f7(0x8c),'type':a141_0x2db6f7(0x86),'required':![],'default':![],'description':a141_0x2db6f7(0xa4)},{'name':a141_0x2db6f7(0xfd),'type':a141_0x2db6f7(0xe0),'required':![],'description':a141_0x2db6f7(0xd2)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':'number','required':!![],'description':a141_0x2db6f7(0xee)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x38d2ee,_0x200b2b,_0x9fcd81){return new CliError(_0x38d2ee,0x1,_0x200b2b,_0x9fcd81);}export function readNotificationId(_0x1e29dd){const _0x39a049=a141_0x2db6f7,_0x10e579=_0x1e29dd[_0x39a049(0xbd)]('id');if(!Number[_0x39a049(0xde)](_0x10e579)||_0x10e579<=0x0)throw notificationError(_0x39a049(0x8d),_0x39a049(0x94));return _0x10e579;}export function requireNotificationExplicitYes(_0x3c85fb){const _0x3e0e38=a141_0x2db6f7;if(_0x3c85fb[_0x3e0e38(0xf5)](_0x3e0e38(0xa7))||_0x3c85fb[_0x3e0e38(0xf5)](_0x3e0e38(0x8f)))return;throw notificationError(_0x3e0e38(0xfe),_0x3e0e38(0x96),'Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.');}export function readNotificationChannelType(_0x2ea3de,_0x4ea921=a141_0x2db6f7(0xcc),_0x49d165=a141_0x2db6f7(0x92)){const _0x4a6c06=a141_0x2db6f7,_0x5469ab=_0x2ea3de['str'](_0x4ea921)[_0x4a6c06(0x103)]()||_0x49d165;if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x5469ab))throw CliErrors[_0x4a6c06(0xa6)](_0x4a6c06(0x99)+_0x4ea921+':\x20'+_0x5469ab,'Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0x4a6c06(0x8b)](',\x20')+'.');return _0x5469ab;}export function assertSingleNotificationSource(_0x44c58c){const _0x2def33=a141_0x2db6f7,_0x547816=[],_0x1f2e01=_0x44c58c[_0x2def33(0xcb)]('file')[_0x2def33(0x103)]();if(_0x1f2e01)_0x547816['push']({'kind':_0x2def33(0xeb),'path':_0x1f2e01});if(_0x44c58c['bool'](_0x2def33(0x8c)))_0x547816[_0x2def33(0xc7)]({'kind':_0x2def33(0x8c)});const _0x1c38a8=_0x44c58c['str']('from-env')['trim']();if(_0x1c38a8)_0x547816[_0x2def33(0xc7)]({'kind':_0x2def33(0x104),'name':_0x1c38a8});if(_0x547816['length']===0x0)throw CliErrors['validation']('Missing\x20notification\x20JSON\x20source.',_0x2def33(0xce));if(_0x547816[_0x2def33(0x9e)]>0x1)throw CliErrors[_0x2def33(0xa6)](_0x2def33(0xfc),_0x2def33(0xce));return _0x547816[0x0];}export async function readNotificationDocument(_0x4fcfce,_0x20c762){const _0x462b41=a141_0x2db6f7,_0x431ea9=assertSingleNotificationSource(_0x4fcfce),_0x956951=_0x431ea9['kind']==='file'?_0x462b41(0xad)+_0x431ea9[_0x462b41(0xdc)]:_0x431ea9[_0x462b41(0xf0)]===_0x462b41(0x104)?_0x462b41(0xab)+_0x431ea9[_0x462b41(0xda)]:_0x462b41(0x8c);let _0x15f3b9;try{if(_0x431ea9[_0x462b41(0xf0)]===_0x462b41(0xeb))_0x15f3b9=await readFile(_0x431ea9[_0x462b41(0xdc)],_0x462b41(0xa2));else{if(_0x431ea9[_0x462b41(0xf0)]===_0x462b41(0x104)){if(!(_0x431ea9[_0x462b41(0xda)]in process.env))throw notificationError(_0x462b41(0xd3),_0x462b41(0xca)+_0x431ea9[_0x462b41(0xda)]);_0x15f3b9=process.env[_0x431ea9.name]??'';}else _0x15f3b9=await readStdin();}}catch(_0x4ed895){if(_0x4ed895 instanceof CliError)throw _0x4ed895;throw notificationError('notification_config_source_unavailable',_0x462b41(0xdd)+_0x956951+'.');}let _0x81d3c4;try{_0x81d3c4=JSON[_0x462b41(0xb1)](_0x15f3b9);}catch{throw notificationError(_0x462b41(0x9a),_0x462b41(0xbc)+_0x956951+'\x20is\x20invalid.',_0x462b41(0xc9));}if(!isJsonObject(_0x81d3c4))throw notificationError('notification_config_json_invalid',_0x462b41(0xbc)+_0x956951+'\x20must\x20be\x20an\x20object.');return validateNotificationDocument(_0x81d3c4,_0x20c762);}export function projectNotificationListConfig(_0x56c2aa,_0x42f4dd){const _0x76ef09=a141_0x2db6f7;return{'id':typeof _0x56c2aa['id']===_0x76ef09(0xea)?_0x56c2aa['id']:null,'configCode':requireResponseString(_0x56c2aa[_0x76ef09(0xe6)],_0x76ef09(0xe6),_0x42f4dd),'configName':requireResponseString(_0x56c2aa[_0x76ef09(0xae)],_0x76ef09(0xae),_0x42f4dd),'channelType':requireResponseString(_0x56c2aa['channelType'],_0x76ef09(0xb3),_0x42f4dd),'description':normalizeNullableString(_0x56c2aa['description']),'createTime':normalizeNullableString(_0x56c2aa[_0x76ef09(0xb8)]),'updateTime':normalizeNullableString(_0x56c2aa[_0x76ef09(0xe3)])};}export function normalizeExactNotificationConfig(_0x545ad3,_0x23e8f6,_0x4ba6f1){const _0x4c687f=a141_0x2db6f7;if(!Number[_0x4c687f(0xde)](_0x545ad3['id'])||_0x545ad3['id']!==_0x23e8f6)throw notificationError(_0x4c687f(0xdf),_0x4c687f(0xf1)+_0x23e8f6+'.');if(_0x545ad3[_0x4c687f(0xa8)]!==_0x4ba6f1)throw notificationError(_0x4c687f(0xdf),'Notification\x20config\x20'+_0x23e8f6+'\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.');const _0x35d489=requireExactString(_0x545ad3['configName'],_0x4c687f(0xae),_0x23e8f6),_0x5d9e0f=requireExactString(_0x545ad3[_0x4c687f(0xe6)],_0x4c687f(0xe6),_0x23e8f6),_0x50a170=requireExactString(_0x545ad3[_0x4c687f(0xb3)],_0x4c687f(0xb3),_0x23e8f6);if(!NOTIFICATION_CHANNEL_TYPES[_0x4c687f(0x88)](_0x50a170))throw notificationError(_0x4c687f(0xdf),'Notification\x20config\x20'+_0x23e8f6+'\x20has\x20an\x20unsupported\x20channelType.');const _0x27a4b7=responseNullableString(_0x545ad3[_0x4c687f(0xb2)],_0x4c687f(0xb2),_0x23e8f6),_0x218266=responseNullableString(_0x545ad3[_0x4c687f(0x90)],_0x4c687f(0x90),_0x23e8f6),_0x1fbc9a=responseNullableString(_0x545ad3['description'],_0x4c687f(0xd9),_0x23e8f6),_0x587562=responseNullableTimeout(_0x545ad3[_0x4c687f(0xe5)],_0x4c687f(0xe5),_0x23e8f6),_0x56c515=responseNullableTimeout(_0x545ad3[_0x4c687f(0xaf)],_0x4c687f(0xaf),_0x23e8f6);return{'id':_0x23e8f6,'appCode':_0x4ba6f1,'configCode':_0x5d9e0f,'configName':_0x35d489,'channelType':_0x50a170,'endpointUrl':redactSensitive(_0x27a4b7),'channelConfig':redactSensitive(_0x218266),'description':_0x1fbc9a,'connectTimeout':_0x587562,'readTimeout':_0x56c515,'endpointUrlRaw':_0x27a4b7,'channelConfigRaw':_0x218266};}function a141_0x4b17(_0x5a138a,_0x3da13b){_0x5a138a=_0x5a138a-0x7d;const _0x216a93=a141_0x216a();let _0x4b17b6=_0x216a93[_0x5a138a];return _0x4b17b6;}export async function requireExactNotificationConfig(_0x4f096a,_0x34c3b9,_0x1683d2){const _0x45e194=a141_0x2db6f7;let _0x135f31;try{_0x135f31=await getNotificationChannelConfig(_0x34c3b9,_0x4f096a);}catch{throw safeApiFailure(_0x1683d2,_0x45e194(0xd5),_0x45e194(0xd7)+_0x4f096a+'\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.');}return normalizeExactNotificationConfig(_0x135f31,_0x34c3b9,_0x4f096a);}export function projectNotificationConfig(_0x1127e6){const _0x76aa1d=a141_0x2db6f7;return{'id':_0x1127e6['id']??null,'appCode':_0x1127e6[_0x76aa1d(0xa8)],'configCode':_0x1127e6[_0x76aa1d(0xe6)]??null,'configName':_0x1127e6['configName'],'channelType':_0x1127e6[_0x76aa1d(0xb3)],'endpointUrl':redactSensitive(_0x1127e6[_0x76aa1d(0xb2)]),'channelConfig':redactSensitive(_0x1127e6[_0x76aa1d(0x90)]),'description':_0x1127e6['description']??null,'connectTimeout':_0x1127e6[_0x76aa1d(0xe5)]??null,'readTimeout':_0x1127e6['readTimeout']??null};}export function notificationSelector(_0x5f55e3){const _0x28a0b3=a141_0x2db6f7;return{'appCode':_0x5f55e3[_0x28a0b3(0xa8)],'id':_0x5f55e3['id'],'configCode':_0x5f55e3[_0x28a0b3(0xe6)],'configName':_0x5f55e3[_0x28a0b3(0xae)],'channelType':_0x5f55e3[_0x28a0b3(0xb3)]};}export function createMutationInput(_0x472737,_0x44fccc){const _0x1f4df1=a141_0x2db6f7;return{'appCode':_0x472737,'configName':_0x44fccc[_0x1f4df1(0xae)],'channelType':_0x44fccc[_0x1f4df1(0xb3)],...hasOwn(_0x44fccc,_0x1f4df1(0xb2))?{'endpointUrl':_0x44fccc['endpointUrl']}:{},...hasOwn(_0x44fccc,_0x1f4df1(0x90))?{'channelConfig':serializeChannelConfig(_0x44fccc[_0x1f4df1(0x90)])}:{},...hasOwn(_0x44fccc,_0x1f4df1(0xd9))?{'description':_0x44fccc['description']}:{},...hasOwn(_0x44fccc,_0x1f4df1(0xe5))?{'connectTimeout':_0x44fccc[_0x1f4df1(0xe5)]}:{},...hasOwn(_0x44fccc,_0x1f4df1(0xaf))?{'readTimeout':_0x44fccc['readTimeout']}:{}};}function a141_0x216a(){const _0x235096=['endpointUrlRaw','WEBHOOK','Notification\x20JSON\x20source\x20is\x20ambiguous.','from-env','notification_config_confirmation_required','1690218bWzLrY','notification_config_update_empty','notification_config_channel_field_forbidden','\x20is\x20missing\x20required\x20field\x20\x22','trim','env','replyTo','call','fromName','Unknown\x20notification\x20JSON\x20field\x20\x22','\x20has\x20an\x20invalid\x20channelType.','Notification\x20config\x20list\x20item\x20','\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','1CpogQM','\x20failed.','boolean','a\x20non-empty\x20string','includes','\x22channelType\x22.','channelCode','join','stdin','notification_config_id_invalid','\x22\x20must\x20be\x20a\x20non-empty\x20string.','yes','channelConfig','\x20--type\x20','EMAIL','WECOM','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','5876087BGPJYg','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','recipients','\x22\x20cannot\x20exceed\x20','Invalid\x20--','notification_config_json_invalid','8kjqSNa','keys','emailTargets','length','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','Notification\x20JSON\x20field\x20\x22','Allowed\x20values:\x20','utf8','rabetbase\x20notification\x20config-list\x20--appcode\x20','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','update','validation','dry-run','appCode','stringify','has','environment\x20variable\x20','ccList','file\x20','configName','readTimeout','notification_config_field_forbidden','parse','endpointUrl','channelType','failed','prototype','_unavailable','34818530sjfPLj','createTime','Create\x20JSON\x20requires\x20field\x20','Item\x20','bccList','Notification\x20JSON\x20from\x20','num','messageTemplate','some','2173526KKtIcz','notification_config_field_unknown','notification_config_','channelConfigRaw','a\x20supported\x20string','\x22configName\x22.','mutation','push','\x20has\x20invalid\x20field\x20\x22','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','str','type','\x20--format\x20compress','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','a\x20JSON\x20object','<redacted>','2832108LDDrJN','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','notification_config_source_unavailable','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','preflight','DINGTALK','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','notification_config_field_required','description','name','endpointUrl:null','path','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','isSafeInteger','notification_config_response_invalid','string','every','isArray','updateTime','Notification\x20config\x20','connectTimeout','configCode','813565VmYcMN','apiError','FEISHU','number','file','\x22\x20is\x20forbidden.','9tiCECb','Application-level\x20notification\x20config\x20ID','\x22\x20must\x20be\x20','kind','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','Notification\x20JSON\x20channelConfig\x20field\x20\x22','Invalid\x20notification\x20config\x20response.','notification_config_field_invalid','bool','5097093NtEdDu','setEncoding','create','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.'];a141_0x216a=function(){return _0x235096;};return a141_0x216a();}export function mergeUpdateInput(_0x2b2eca,_0x4efd8f){const _0x316fcf=a141_0x2db6f7;return{'id':_0x2b2eca['id'],'appCode':_0x2b2eca['appCode'],'configName':_0x4efd8f[_0x316fcf(0xae)]??_0x2b2eca[_0x316fcf(0xae)],'channelType':_0x4efd8f[_0x316fcf(0xb3)]??_0x2b2eca['channelType'],'endpointUrl':hasOwn(_0x4efd8f,_0x316fcf(0xb2))?_0x4efd8f['endpointUrl']:_0x2b2eca['endpointUrlRaw'],'channelConfig':hasOwn(_0x4efd8f,_0x316fcf(0x90))?serializeChannelConfig(_0x4efd8f['channelConfig']):_0x2b2eca[_0x316fcf(0xc3)],'description':hasOwn(_0x4efd8f,_0x316fcf(0xd9))?_0x4efd8f[_0x316fcf(0xd9)]:_0x2b2eca[_0x316fcf(0xd9)],'connectTimeout':hasOwn(_0x4efd8f,_0x316fcf(0xe5))?_0x4efd8f[_0x316fcf(0xe5)]:_0x2b2eca[_0x316fcf(0xe5)],'readTimeout':hasOwn(_0x4efd8f,_0x316fcf(0xaf))?_0x4efd8f[_0x316fcf(0xaf)]:_0x2b2eca[_0x316fcf(0xaf)]};}export function plannedUpdateProjection(_0x1f0608,_0x25800d){const _0x3ccfd9=a141_0x2db6f7;return projectNotificationConfig({'id':_0x1f0608['id'],'appCode':_0x1f0608['appCode'],'configCode':_0x1f0608[_0x3ccfd9(0xe6)],'configName':_0x25800d[_0x3ccfd9(0xae)]??_0x1f0608['configName'],'channelType':_0x25800d[_0x3ccfd9(0xb3)]??_0x1f0608[_0x3ccfd9(0xb3)],'endpointUrl':hasOwn(_0x25800d,'endpointUrl')?_0x25800d['endpointUrl']:_0x1f0608[_0x3ccfd9(0xfa)],'channelConfig':hasOwn(_0x25800d,_0x3ccfd9(0x90))?_0x25800d[_0x3ccfd9(0x90)]:_0x1f0608[_0x3ccfd9(0xc3)],'description':hasOwn(_0x25800d,_0x3ccfd9(0xd9))?_0x25800d['description']:_0x1f0608['description'],'connectTimeout':hasOwn(_0x25800d,'connectTimeout')?_0x25800d['connectTimeout']??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x1f0608['connectTimeout'],'readTimeout':hasOwn(_0x25800d,_0x3ccfd9(0xaf))?_0x25800d[_0x3ccfd9(0xaf)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x1f0608[_0x3ccfd9(0xaf)]});}export function requestedSafeFieldsMatch(_0x69dd01,_0x11560d,_0x1e2f4f){const _0x2196f9=a141_0x2db6f7,_0x3edf24=[],_0x5766b2=[],_0x553365=[];for(const _0x3ea93f of['configName',_0x2196f9(0xb3),'description']){if(!hasOwn(_0x1e2f4f,_0x3ea93f))continue;_0x553365['push'](_0x3ea93f),_0x3edf24[_0x2196f9(0xc7)](_0x11560d[_0x3ea93f]===_0x1e2f4f[_0x3ea93f]),_0x5766b2[_0x2196f9(0xc7)](_0x69dd01[_0x3ea93f]!==_0x1e2f4f[_0x3ea93f]&&_0x11560d[_0x3ea93f]===_0x1e2f4f[_0x3ea93f]);}for(const _0x2e0151 of[_0x2196f9(0xe5),_0x2196f9(0xaf)]){if(!hasOwn(_0x1e2f4f,_0x2e0151))continue;const _0x527540=_0x1e2f4f[_0x2e0151]??(_0x2e0151===_0x2196f9(0xe5)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x553365[_0x2196f9(0xc7)](_0x2e0151),_0x3edf24['push'](_0x11560d[_0x2e0151]===_0x527540),_0x5766b2[_0x2196f9(0xc7)](_0x69dd01[_0x2e0151]!==_0x527540&&_0x11560d[_0x2e0151]===_0x527540);}return hasOwn(_0x1e2f4f,_0x2196f9(0xb2))&&_0x1e2f4f[_0x2196f9(0xb2)]===null&&(_0x553365[_0x2196f9(0xc7)](_0x2196f9(0xdb)),_0x3edf24[_0x2196f9(0xc7)](_0x11560d[_0x2196f9(0xfa)]===null||_0x11560d[_0x2196f9(0xfa)]===''),_0x5766b2[_0x2196f9(0xc7)](_0x69dd01['endpointUrlRaw']!==null&&_0x69dd01[_0x2196f9(0xfa)]!==''&&(_0x11560d[_0x2196f9(0xfa)]===null||_0x11560d[_0x2196f9(0xfa)]===''))),{'allMatch':_0x3edf24[_0x2196f9(0xe1)](Boolean),'provesChange':_0x5766b2[_0x2196f9(0xbf)](Boolean),'verifiedFields':_0x553365};}export function validateNotificationDeleteReadback(_0x372a47,_0x28ffa5,_0x6c602c){const _0x2b1aac=a141_0x2db6f7;for(const [_0x2dd131,_0x15abcf]of _0x372a47['entries']()){if(!Number[_0x2b1aac(0xde)](_0x15abcf['id'])||_0x15abcf['id']<=0x0)throw notificationError(_0x2b1aac(0xdf),'Notification\x20config\x20list\x20item\x20'+(_0x2dd131+0x1)+'\x20has\x20an\x20invalid\x20id.');if(_0x15abcf[_0x2b1aac(0xa8)]!==_0x28ffa5)throw notificationError('notification_config_response_invalid',_0x2b1aac(0x82)+(_0x2dd131+0x1)+'\x20has\x20an\x20invalid\x20appCode.');if(_0x15abcf[_0x2b1aac(0xb3)]!==_0x6c602c)throw notificationError(_0x2b1aac(0xdf),'Notification\x20config\x20list\x20item\x20'+(_0x2dd131+0x1)+_0x2b1aac(0x81));}}export function safeApiFailure(_0x986a91,_0x41dcd8,_0x5b3c8d){const _0x27574d=a141_0x2db6f7;return notificationError(_0x27574d(0xc2)+_0x986a91+'_'+(_0x41dcd8===_0x27574d(0xc6)?_0x27574d(0xb4):_0x41dcd8+_0x27574d(0xb6)),_0x27574d(0xe4)+_0x986a91+'\x20'+_0x41dcd8+_0x27574d(0x85),_0x5b3c8d);}export function notificationLookupCommand(_0x4b7aa6,_0x1198e9){const _0x1daac1=a141_0x2db6f7;return _0x1daac1(0xa3)+_0x4b7aa6+_0x1daac1(0x91)+_0x1198e9+_0x1daac1(0xcd);}function validateNotificationDocument(_0xf0d45f,_0x1190ba){const _0x4ec8e9=a141_0x2db6f7;for(const _0x37db26 of Object[_0x4ec8e9(0x9c)](_0xf0d45f)){if(FORBIDDEN_IDENTITY_FIELDS['has'](_0x37db26))throw notificationError(_0x4ec8e9(0xb0),_0x4ec8e9(0xa0)+_0x37db26+_0x4ec8e9(0x83));if(!ALLOWED_INPUT_FIELDS[_0x4ec8e9(0xaa)](_0x37db26))throw notificationError(_0x4ec8e9(0xc1),_0x4ec8e9(0x80)+_0x37db26+'\x22.');}if(_0x1190ba===_0x4ec8e9(0xa5)&&Object['keys'](_0xf0d45f)[_0x4ec8e9(0x9e)]===0x0)throw notificationError(_0x4ec8e9(0x100),'Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.');const _0xcbd9fe={};if(hasOwn(_0xf0d45f,'configName'))_0xcbd9fe['configName']=validateRequiredString(_0xf0d45f[_0x4ec8e9(0xae)],_0x4ec8e9(0xae),0x80);else{if(_0x1190ba==='create')throw notificationError(_0x4ec8e9(0xd8),_0x4ec8e9(0xb9)+_0x4ec8e9(0xc5));}if(hasOwn(_0xf0d45f,_0x4ec8e9(0xb3))){if(typeof _0xf0d45f[_0x4ec8e9(0xb3)]!=='string')throw invalidFieldType(_0x4ec8e9(0xb3),_0x4ec8e9(0xc4));const _0xa18884=_0xf0d45f[_0x4ec8e9(0xb3)]['trim']();if(!NOTIFICATION_CHANNEL_TYPES[_0x4ec8e9(0x88)](_0xa18884))throw notificationError('notification_config_field_invalid',_0x4ec8e9(0xd4),_0x4ec8e9(0xa1)+NOTIFICATION_CHANNEL_TYPES[_0x4ec8e9(0x8b)](',\x20')+'.');_0xcbd9fe[_0x4ec8e9(0xb3)]=_0xa18884;}else{if(_0x1190ba===_0x4ec8e9(0xf8))throw notificationError(_0x4ec8e9(0xd8),'Create\x20JSON\x20requires\x20field\x20'+_0x4ec8e9(0x89));}for(const [_0x1665ff,_0xe0509d]of[[_0x4ec8e9(0xb2),0x200],[_0x4ec8e9(0xd9),0x100]]){if(!hasOwn(_0xf0d45f,_0x1665ff))continue;const _0x34051b=_0xf0d45f[_0x1665ff];if(_0x34051b!==null&&typeof _0x34051b!=='string')throw invalidFieldType(_0x1665ff,'a\x20string\x20or\x20null');if(typeof _0x34051b===_0x4ec8e9(0xe0)&&_0x34051b[_0x4ec8e9(0x9e)]>_0xe0509d)throw notificationError(_0x4ec8e9(0xf4),_0x4ec8e9(0xa0)+_0x1665ff+_0x4ec8e9(0x98)+_0xe0509d+'\x20characters.');_0xcbd9fe[_0x1665ff]=_0x34051b;}if(hasOwn(_0xf0d45f,_0x4ec8e9(0x90))){const _0x1a78ec=_0xf0d45f[_0x4ec8e9(0x90)];if(_0x1a78ec===null&&_0x1190ba===_0x4ec8e9(0xf8))throw invalidFieldType(_0x4ec8e9(0x90),_0x4ec8e9(0xcf));if(_0x1a78ec!==null&&!isJsonObject(_0x1a78ec))throw invalidFieldType(_0x4ec8e9(0x90),_0x1190ba===_0x4ec8e9(0xa5)?'a\x20JSON\x20object\x20or\x20null':_0x4ec8e9(0xcf));_0x1a78ec!==null&&validateChannelConfigFields(_0xcbd9fe[_0x4ec8e9(0xb3)],_0x1a78ec),_0xcbd9fe[_0x4ec8e9(0x90)]=_0x1a78ec;}for(const _0x1ce868 of[_0x4ec8e9(0xe5),_0x4ec8e9(0xaf)]){if(!hasOwn(_0xf0d45f,_0x1ce868))continue;const _0x20640c=_0xf0d45f[_0x1ce868];if(_0x20640c!==null&&(!Number['isSafeInteger'](_0x20640c)||_0x20640c<0x0))throw notificationError(_0x4ec8e9(0xf4),_0x4ec8e9(0xa0)+_0x1ce868+_0x4ec8e9(0xf9));_0xcbd9fe[_0x1ce868]=_0x20640c;}return _0xcbd9fe;}function validateRequiredString(_0x402334,_0x42b223,_0x30e5e6){const _0x3c4e70=a141_0x2db6f7;if(typeof _0x402334!==_0x3c4e70(0xe0))throw invalidFieldType(_0x42b223,_0x3c4e70(0x87));const _0x14e602=_0x402334[_0x3c4e70(0x103)]();if(!_0x14e602)throw notificationError('notification_config_field_invalid',_0x3c4e70(0xa0)+_0x42b223+_0x3c4e70(0x8e));if(_0x14e602[_0x3c4e70(0x9e)]>_0x30e5e6)throw notificationError(_0x3c4e70(0xf4),_0x3c4e70(0xa0)+_0x42b223+'\x22\x20cannot\x20exceed\x20'+_0x30e5e6+'\x20characters.');return _0x14e602;}function validateChannelConfigFields(_0x1d77ce,_0x27476a){const _0x3f3aaf=a141_0x2db6f7;if(hasOwn(_0x27476a,_0x3f3aaf(0xbe)))throw forbiddenChannelConfigField(_0x3f3aaf(0xbe));if(_0x1d77ce===_0x3f3aaf(0x92))for(const _0x681505 of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x27476a,_0x681505))throw forbiddenChannelConfigField(_0x681505);}}function forbiddenChannelConfigField(_0x4fe6c9){const _0x8e896=a141_0x2db6f7;return notificationError(_0x8e896(0x101),_0x8e896(0xf2)+_0x4fe6c9+_0x8e896(0xec));}function invalidFieldType(_0x3d20a1,_0xab94de){const _0x20b158=a141_0x2db6f7;return notificationError(_0x20b158(0xf4),'Notification\x20JSON\x20field\x20\x22'+_0x3d20a1+_0x20b158(0xef)+_0xab94de+'.');}function serializeChannelConfig(_0x57561a){const _0x37f62a=a141_0x2db6f7;return _0x57561a===null||_0x57561a===undefined?null:JSON[_0x37f62a(0xa9)](_0x57561a);}function redactSensitive(_0x5a3870){const _0xe8e6ee=a141_0x2db6f7;return _0x5a3870===null||_0x5a3870===undefined||_0x5a3870===''?null:_0xe8e6ee(0xd0);}function requireResponseString(_0x54a538,_0x35518a,_0x22ac42){const _0xc4318f=a141_0x2db6f7;if(typeof _0x54a538!==_0xc4318f(0xe0)||_0x54a538['trim']()==='')throw CliErrors[_0xc4318f(0xe8)](_0xc4318f(0xf3),_0xc4318f(0xba)+(_0x22ac42+0x1)+_0xc4318f(0x102)+_0x35518a+'\x22.');return _0x54a538[_0xc4318f(0x103)]();}function requireExactString(_0x101546,_0x177c37,_0x3135c2){const _0xfffc7c=a141_0x2db6f7;if(typeof _0x101546!==_0xfffc7c(0xe0)||_0x101546['trim']()==='')throw notificationError(_0xfffc7c(0xdf),_0xfffc7c(0xe4)+_0x3135c2+'\x20is\x20missing\x20required\x20field\x20\x22'+_0x177c37+'\x22.');return _0x101546['trim']();}function responseNullableString(_0x3ac2d8,_0xcfc0ac,_0xa4b1cb){const _0x33570b=a141_0x2db6f7;if(_0x3ac2d8===undefined||_0x3ac2d8===null)return null;if(typeof _0x3ac2d8!==_0x33570b(0xe0))throw notificationError(_0x33570b(0xdf),_0x33570b(0xe4)+_0xa4b1cb+'\x20has\x20invalid\x20field\x20\x22'+_0xcfc0ac+'\x22.');return _0x3ac2d8;}function responseNullableTimeout(_0x202ac4,_0x119d71,_0x1a9877){const _0x34fa5c=a141_0x2db6f7;if(_0x202ac4===undefined||_0x202ac4===null)return null;if(!Number[_0x34fa5c(0xde)](_0x202ac4)||_0x202ac4<0x0)throw notificationError('notification_config_response_invalid','Notification\x20config\x20'+_0x1a9877+_0x34fa5c(0xc8)+_0x119d71+'\x22.');return _0x202ac4;}function normalizeNullableString(_0x3b95b5){const _0x52ca22=a141_0x2db6f7;return typeof _0x3b95b5===_0x52ca22(0xe0)?_0x3b95b5:null;}function isJsonObject(_0x3cd365){const _0x153329=a141_0x2db6f7;return _0x3cd365!==null&&typeof _0x3cd365==='object'&&!Array[_0x153329(0xe2)](_0x3cd365);}function hasOwn(_0x462156,_0x3563c0){const _0x19e3df=a141_0x2db6f7;return Object[_0x19e3df(0xb5)]['hasOwnProperty'][_0x19e3df(0x7e)](_0x462156,_0x3563c0);}async function readStdin(){const _0x43976d=a141_0x2db6f7;let _0x1e6681='';process[_0x43976d(0x8c)][_0x43976d(0xf7)](_0x43976d(0xa2));for await(const _0x2c3f42 of process['stdin'])_0x1e6681+=_0x2c3f42;return _0x1e6681;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a142_0x29b121=a142_0x3eb7;(function(_0x1985da,_0x34657b){const _0x3e7fcc=a142_0x3eb7,_0x54a7b8=_0x1985da();while(!![]){try{const _0x176bdb=parseInt(_0x3e7fcc(0x96))/0x1*(-parseInt(_0x3e7fcc(0x9f))/0x2)+parseInt(_0x3e7fcc(0xa4))/0x3+-parseInt(_0x3e7fcc(0x7e))/0x4*(parseInt(_0x3e7fcc(0x7c))/0x5)+-parseInt(_0x3e7fcc(0x90))/0x6+-parseInt(_0x3e7fcc(0x76))/0x7*(-parseInt(_0x3e7fcc(0x80))/0x8)+-parseInt(_0x3e7fcc(0xa5))/0x9+parseInt(_0x3e7fcc(0x95))/0xa*(parseInt(_0x3e7fcc(0x6d))/0xb);if(_0x176bdb===_0x34657b)break;else _0x54a7b8['push'](_0x54a7b8['shift']());}catch(_0x27ea0c){_0x54a7b8['push'](_0x54a7b8['shift']());}}}(a142_0x21b4,0x5e207));import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';function a142_0x3eb7(_0x54525f,_0x15c5e3){_0x54525f=_0x54525f-0x6d;const _0x21b4f1=a142_0x21b4();let _0x3eb76c=_0x21b4f1[_0x54525f];return _0x3eb76c;}import{queryDevelopmentFileUrl,recognizeDevelopmentOcr,uploadDevelopmentFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const SUPPORTED_SCENES=[a142_0x29b121(0x84),'general',a142_0x29b121(0xa6),a142_0x29b121(0x9a)],SCENE_TO_LEGACY_TYPE={'invoice':a142_0x29b121(0x7f),'general':a142_0x29b121(0x71),'form':'Table','idCard':a142_0x29b121(0x8b)},SCENE_FLAG={'name':a142_0x29b121(0x6e),'type':a142_0x29b121(0x7b),'required':!![],'enum':[...SUPPORTED_SCENES],'description':a142_0x29b121(0xa0)},IMAGE_FILE_FLAG={'name':a142_0x29b121(0x85),'type':'string','description':a142_0x29b121(0x74)},IMAGE_URL_FLAG={'name':a142_0x29b121(0x88),'type':a142_0x29b121(0x7b),'description':a142_0x29b121(0x8d)};function normalizeScene(_0x3c3dd7){const _0x288330=a142_0x29b121,_0x3b8947=_0x3c3dd7['trim']()['toLowerCase']();if(_0x3b8947===_0x288330(0x7a))return _0x288330(0x9a);if(_0x3b8947===_0x288330(0x84)||_0x3b8947===_0x288330(0x92)||_0x3b8947==='form')return _0x3b8947;throw CliErrors[_0x288330(0x86)](_0x288330(0x89)+_0x3c3dd7+_0x288330(0x8f)+SUPPORTED_SCENES[_0x288330(0x77)](',\x20'));}function a142_0x21b4(){const _0x32c592=['127681QxICvW','str','fileName','trim','idCard','appCode','toString','/smartapi/common/queryFileUrl','path','2kPROLd','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','ocr','imageFile','/smartapi/common/uploadFile','149397zvaoKo','411714gUwVYW','form','4061893ezQUrm','scene','filter','Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','General','fileUrl','<fileUrl\x20returned\x20by\x20/smartapi/common/queryFileUrl>','Local\x20image\x20or\x20PDF\x20file;\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','\x20OCR','7ymiNKl','join','POST','GET','idcard','string','5825zRZGmW','imageUrl','1244AUOsLA','Invoice','1920784oRNHEg','filePath','<filePath\x20returned\x20by\x20/smartapi/common/uploadFile>','/smartapi/ocr/recognize-text?','invoice','image-file','validation','read','image-url','Unsupported\x20OCR\x20scene:\x20','File\x20URL\x20response\x20missing\x20fileUrl.','IdCard','apiError','Publicly\x20accessible\x20image\x20or\x20file\x20URL','length','.\x20Supported\x20scenes:\x20','2858406lescSR','count','general','File\x20upload\x20response\x20missing\x20filePath.','/smartapi/ocr/recognize-text','30RvRRhQ'];a142_0x21b4=function(){return _0x32c592;};return a142_0x21b4();}function selectedInputs(_0xe18a72){const _0x467646=a142_0x29b121,_0x32bcd1=_0xe18a72[_0x467646(0x97)]('image-file')[_0x467646(0x99)](),_0x83f0a5=_0xe18a72[_0x467646(0x97)]('image-url')[_0x467646(0x99)]();return{'imageFile':_0x32bcd1,'imageUrl':_0x83f0a5,'count':[_0x32bcd1,_0x83f0a5][_0x467646(0x6f)](Boolean)[_0x467646(0x8e)]};}function validateInputSelection(_0x54a721){const _0x2c592c=a142_0x29b121,_0x37b95f=selectedInputs(_0x54a721);if(_0x37b95f[_0x2c592c(0x91)]!==0x1)throw CliErrors['validation']('Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.');return _0x37b95f;}function withScene(_0x2026f1,_0x245dc9,_0x2a62b9){const _0xd6a6d=a142_0x29b121;return{..._0x2026f1,'scene':_0x245dc9,..._0x2a62b9?{'sourceFile':{'fileName':_0x2a62b9[_0xd6a6d(0x98)],'filePath':_0x2a62b9[_0xd6a6d(0x81)]}}:{}};}const ocrRecognize={'service':a142_0x29b121(0xa1),'command':'recognize','description':a142_0x29b121(0x70),'risk':a142_0x29b121(0x87),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x2b0726){const _0x248d9c=a142_0x29b121,_0x125164=normalizeScene(_0x2b0726[_0x248d9c(0x97)](_0x248d9c(0x6e))),_0xfe3136=SCENE_TO_LEGACY_TYPE[_0x125164],_0x42e0f3=validateInputSelection(_0x2b0726);if(_0x42e0f3[_0x248d9c(0x7d)]){const _0x13f825=new URLSearchParams({'url':_0x42e0f3[_0x248d9c(0x7d)],'type':_0xfe3136,'appCode':_0x2b0726[_0x248d9c(0x9b)]});return{'method':_0x248d9c(0x79),'url':_0x248d9c(0x83)+_0x13f825[_0x248d9c(0x9c)](),'description':'Preview:\x20recognize\x20'+_0x125164+'\x20OCR\x20from\x20URL'};}const _0x4c8ab4=requireDevelopmentUploadFile(_0x42e0f3[_0x248d9c(0xa2)],_0x248d9c(0x85));return{'method':_0x248d9c(0x78),'url':'/smartapi/common/uploadFile','body':{'steps':[{'method':_0x248d9c(0x78),'url':_0x248d9c(0xa3),'body':{'appCode':_0x2b0726[_0x248d9c(0x9b)],'multipart':{'file':_0x4c8ab4}}},{'method':_0x248d9c(0x78),'url':_0x248d9c(0x9d),'body':{'filePath':_0x248d9c(0x82),'downloadFlag':![]}},{'method':_0x248d9c(0x79),'url':_0x248d9c(0x94),'query':{'appCode':_0x2b0726[_0x248d9c(0x9b)],'url':_0x248d9c(0x73),'type':_0xfe3136}}]},'description':'Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20'+_0x125164+_0x248d9c(0x75)};},async 'execute'(_0x4f215a){const _0x58cf3d=a142_0x29b121,_0x234187=normalizeScene(_0x4f215a[_0x58cf3d(0x97)]('scene')),_0x58f29d=SCENE_TO_LEGACY_TYPE[_0x234187],_0x2776e2=validateInputSelection(_0x4f215a);if(_0x2776e2['imageUrl']){const _0x1a5abc=await recognizeDevelopmentOcr(_0x4f215a[_0x58cf3d(0x9b)],{'url':_0x2776e2[_0x58cf3d(0x7d)],'type':_0x58f29d});return{'ok':!![],'data':withScene(_0x1a5abc,_0x234187)};}const _0x549ece=requireDevelopmentUploadFile(_0x2776e2['imageFile'],_0x58cf3d(0x85)),_0x4a5e14=await uploadDevelopmentFile(_0x4f215a[_0x58cf3d(0x9b)],_0x549ece[_0x58cf3d(0x9e)]);if(!_0x4a5e14[_0x58cf3d(0x81)])throw CliErrors[_0x58cf3d(0x8c)](_0x58cf3d(0x93));const _0x228c67=await queryDevelopmentFileUrl(_0x4a5e14[_0x58cf3d(0x81)],{'download':![]});if(!_0x228c67[_0x58cf3d(0x72)])throw CliErrors['apiError'](_0x58cf3d(0x8a));const _0x4e01d8=await recognizeDevelopmentOcr(_0x4f215a[_0x58cf3d(0x9b)],{'url':_0x228c67[_0x58cf3d(0x72)],'type':_0x58f29d});return{'ok':!![],'data':withScene(_0x4e01d8,_0x234187,_0x4a5e14)};}};export const ocrDefinitions=[ocrRecognize];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a143_0x3b575c=a143_0x8448;(function(_0x4c5a88,_0x11cb73){const _0x21ed8f=a143_0x8448,_0x344f26=_0x4c5a88();while(!![]){try{const _0x271ff2=-parseInt(_0x21ed8f(0x1aa))/0x1*(-parseInt(_0x21ed8f(0x19a))/0x2)+-parseInt(_0x21ed8f(0x1b3))/0x3*(-parseInt(_0x21ed8f(0x1ba))/0x4)+parseInt(_0x21ed8f(0x197))/0x5+parseInt(_0x21ed8f(0x1a0))/0x6+parseInt(_0x21ed8f(0x188))/0x7*(parseInt(_0x21ed8f(0x190))/0x8)+-parseInt(_0x21ed8f(0x18e))/0x9+-parseInt(_0x21ed8f(0x1ac))/0xa*(parseInt(_0x21ed8f(0x1a5))/0xb);if(_0x271ff2===_0x11cb73)break;else _0x344f26['push'](_0x344f26['shift']());}catch(_0x5633a9){_0x344f26['push'](_0x344f26['shift']());}}}(a143_0xdf12,0xd769f));import{APPCODE_FLAG}from'../../commands/common/flags.js';import{buildInitialFiles}from'../../commands/page/custom/template.js';import{createCustomPage,getI18nInfo}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a143_0x8448(_0x5543c1,_0x4d965c){_0x5543c1=_0x5543c1-0x183;const _0xdf121e=a143_0xdf12();let _0x84488c=_0xdf121e[_0x5543c1];return _0x84488c;}import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,parseCustomPageContent,validateCustomPageContent}from'./custom/shared.js';const DEFAULT_CUSTOM_PAGE_LANGUAGES=['zh-CN',a143_0x3b575c(0x199)];function a143_0xdf12(){const _0x5b2ba0=['Custom\x20Page\x20creation\x20did\x20not\x20return\x20a\x20valid\x20pageId.','10WTRQUf','Created\x20Custom\x20Page\x20','Complete\x20page\x20files\x20as\x20JSON\x20(conflicts\x20with\x20--page-pattern)','warnings','version','pageName\x20cannot\x20exceed\x20100\x20characters.','pageName','12849dtHXuK','/smartapi/webcode/page/create','This\x20command\x20always\x20creates\x20a\x20CUSTOM\x20JSX\x20page;\x20use\x20--page-pattern\x20BLANK\x20or\x20--page-content.','appCode','Custom\x20Page\x20was\x20created,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','Would\x20create\x20Custom\x20Page\x20','isInteger','1476xYecrO','--parent-menu-id\x20must\x20be\x20a\x20positive\x20integer.','pagePattern','length','--page-pattern\x20currently\x20supports\x20only\x20BLANK.','Provide\x20--page-pattern\x20BLANK\x20or\x20--page-content.','menuPath','string','enableI18n','77SphXXD','Custom_page_','--page-pattern\x20and\x20--page-content\x20cannot\x20be\x20used\x20together.','str','validation','number','15021765KQNGZv','page-content','1416CbbYRr','name','CUSTOM','pageId','POST','menuId','num','7049930rkEOux','trim','en-US','245528NJyAcz','Optional\x20Custom\x20Page\x20name\x20(1-100\x20characters)','Custom\x20Page\x20pattern\x20(currently\x20BLANK;\x20conflicts\x20with\x20--page-content)','input','langs','create','8100438GbEbKU','page\x20create\x20does\x20not\x20accept\x20--page-type.','parentMenuId','now','parent-menu-id','23752355IhYMZn','files','BLANK','page-pattern','write','3SpMGXR'];a143_0xdf12=function(){return _0x5b2ba0;};return a143_0xdf12();}export const pageCreate={'service':'page','command':a143_0x3b575c(0x19f),'description':'Create\x20a\x20JSX\x20Custom\x20Page\x20from\x20a\x20released\x20pattern\x20or\x20complete\x20files','risk':a143_0x3b575c(0x1a9),'defaultOutputFormat':'compress','structuredErrors':!![],'rejectedFlags':[{'name':'page-type','message':a143_0x3b575c(0x1a1),'hint':a143_0x3b575c(0x1b5)}],'flags':[{'name':'name','type':a143_0x3b575c(0x186),'description':a143_0x3b575c(0x19b)},{'name':a143_0x3b575c(0x1a4),'type':a143_0x3b575c(0x18d),'description':'Optional\x20parent\x20menu\x20id\x20when\x20creating\x20a\x20menu\x20entry'},{'name':'page-pattern','type':a143_0x3b575c(0x186),'description':a143_0x3b575c(0x19c),'enum':['BLANK']},{'name':a143_0x3b575c(0x18f),'type':a143_0x3b575c(0x186),'description':a143_0x3b575c(0x1ae)},APPCODE_FLAG],async 'validate'(_0xae0021){const _0x3c6f4a=a143_0x3b575c,_0x52b666=readPagePattern(_0xae0021);await validateCustomPageContent(readInput(_0xae0021,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x52b666)[_0x3c6f4a(0x1a6)]);},async 'dryRun'(_0x459b49){const _0x41f8f8=a143_0x3b575c,{input:_0xd8efae}=await prepare(_0x459b49);return{'method':_0x41f8f8(0x194),'url':_0x41f8f8(0x1b4),'body':{'appCode':_0xd8efae[_0x41f8f8(0x1b6)],'pageName':_0xd8efae['pageName'],..._0xd8efae[_0x41f8f8(0x1a2)]!=null?{'parentMenuId':_0xd8efae[_0x41f8f8(0x1a2)]}:{},'createMenu':_0xd8efae['createMenu'],'codeContent':_0xd8efae[_0x41f8f8(0x1a6)]},'description':_0x41f8f8(0x1b8)+JSON['stringify'](_0xd8efae[_0x41f8f8(0x1b2)])+'\x20and\x20its\x20menu\x20entry.'};},async 'execute'(_0x137010){const _0x332467=a143_0x3b575c,_0x2a85a1=await prepare(_0x137010),_0x314751=await createCustomPage(_0x2a85a1[_0x332467(0x19d)]);if(!Number[_0x332467(0x1b9)](_0x314751[_0x332467(0x193)])||_0x314751[_0x332467(0x193)]<=0x0)throw CliErrors['apiError'](_0x332467(0x1ab));return{'ok':!![],'data':buildMutationData(_0x2a85a1,_0x314751),'message':_0x332467(0x1ad)+_0x314751['pageId']+'.'};}};async function prepare(_0x2614c5){const _0x18fdd9=a143_0x3b575c,_0x16701d=readPagePattern(_0x2614c5);if(_0x16701d===null)return{'input':readInput(_0x2614c5,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x16701d),'warnings':[],'pagePattern':_0x16701d};let _0x4fa7f3=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x20e33e=[];try{const _0x1babf7=await getI18nInfo(_0x2614c5[_0x18fdd9(0x1b6)]);_0x1babf7[_0x18fdd9(0x187)]&&_0x1babf7[_0x18fdd9(0x19e)]?.['length']&&(_0x4fa7f3=_0x1babf7[_0x18fdd9(0x19e)]);}catch{_0x20e33e=['Application\x20language\x20settings\x20could\x20not\x20be\x20read;\x20default\x20Chinese\x20and\x20English\x20language\x20files\x20were\x20generated.'];}return{'input':readInput(_0x2614c5,_0x4fa7f3,_0x16701d),'warnings':_0x20e33e,'pagePattern':_0x16701d};}function readPagePattern(_0x2127e0){const _0x4ad954=a143_0x3b575c,_0x1339b2=_0x2127e0[_0x4ad954(0x18b)](_0x4ad954(0x1a8))[_0x4ad954(0x198)](),_0x45c46f=_0x2127e0[_0x4ad954(0x18b)]('page-content')[_0x4ad954(0x198)]()[_0x4ad954(0x1bd)]>0x0;if(_0x1339b2&&_0x45c46f)throw CliErrors[_0x4ad954(0x18c)](_0x4ad954(0x18a));if(_0x45c46f)return null;if(!_0x1339b2)throw CliErrors['validation'](_0x4ad954(0x184));if(_0x1339b2!==_0x4ad954(0x1a7))throw CliErrors[_0x4ad954(0x18c)](_0x4ad954(0x183));return _0x1339b2;}function readInput(_0x28ad5e,_0xe823b6=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x2f2981=readPagePattern(_0x28ad5e)){const _0x9cd81c=a143_0x3b575c,_0x2de609=_0x28ad5e['str'](_0x9cd81c(0x191))['trim']()||_0x9cd81c(0x189)+Date[_0x9cd81c(0x1a3)]();if(_0x2de609['length']>0x64)throw CliErrors[_0x9cd81c(0x18c)](_0x9cd81c(0x1b1));const _0x41ff97=_0x28ad5e[_0x9cd81c(0x196)](_0x9cd81c(0x1a4),NaN),_0x33e8b4=!Number['isNaN'](_0x41ff97);if(_0x33e8b4&&(!Number[_0x9cd81c(0x1b9)](_0x41ff97)||_0x41ff97<=0x0))throw CliErrors[_0x9cd81c(0x18c)](_0x9cd81c(0x1bb));return{'appCode':_0x28ad5e[_0x9cd81c(0x1b6)],'pageName':_0x2de609,..._0x33e8b4?{'parentMenuId':_0x41ff97}:{},'createMenu':!![],'files':_0x2f2981===null?parseCustomPageContent(_0x28ad5e[_0x9cd81c(0x18b)](_0x9cd81c(0x18f))):buildInitialFiles(_0x2de609,_0xe823b6)};}function buildMutationData(_0x1dbc7d,_0x39408f){const _0x269556=a143_0x3b575c,{input:_0x545b18}=_0x1dbc7d,_0x118f9c=_0x39408f&&buildCustomPageDevelopmentUrl(_0x545b18[_0x269556(0x1b6)],_0x39408f['menuPath']),_0x4fa637=_0x39408f&&buildCustomPageEditUrl(_0x545b18[_0x269556(0x1b6)],_0x39408f[_0x269556(0x193)]);return{'operation':'page.create','pageType':_0x269556(0x192),'pagePattern':_0x1dbc7d[_0x269556(0x1bc)],'selector':{'appCode':_0x545b18[_0x269556(0x1b6)],'pageName':_0x545b18[_0x269556(0x1b2)]},'before':null,'after':{'pageId':_0x39408f?.[_0x269556(0x193)]??null,'pageName':_0x39408f?.[_0x269556(0x1b2)]??_0x545b18[_0x269556(0x1b2)],'appCode':_0x39408f?.[_0x269556(0x1b6)]??_0x545b18[_0x269556(0x1b6)],'version':_0x39408f?.[_0x269556(0x1b0)]??null,'menuId':_0x39408f?.[_0x269556(0x195)]??null,'menuPath':_0x39408f?.[_0x269556(0x185)]??null,'files':_0x39408f?.[_0x269556(0x1a6)]??Object['keys'](_0x545b18[_0x269556(0x1a6)])},'dryRun':_0x39408f===undefined,'request':_0x545b18,..._0x118f9c?{'pageUrl':_0x118f9c}:{},..._0x4fa637?{'editPageUrl':_0x4fa637}:{},'warnings':[..._0x1dbc7d[_0x269556(0x1af)],..._0x39408f&&!_0x118f9c?[_0x269556(0x1b7)]:[]]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a144_0x45989e=a144_0x1466;(function(_0x3e8ea5,_0x30f294){const _0x15e231=a144_0x1466,_0x56da7d=_0x3e8ea5();while(!![]){try{const _0x5b6d03=-parseInt(_0x15e231(0x194))/0x1*(-parseInt(_0x15e231(0x198))/0x2)+parseInt(_0x15e231(0x192))/0x3*(parseInt(_0x15e231(0x19b))/0x4)+-parseInt(_0x15e231(0x19a))/0x5+parseInt(_0x15e231(0x1a2))/0x6+-parseInt(_0x15e231(0x1a1))/0x7*(-parseInt(_0x15e231(0x193))/0x8)+-parseInt(_0x15e231(0x1a3))/0x9+-parseInt(_0x15e231(0x196))/0xa*(-parseInt(_0x15e231(0x191))/0xb);if(_0x5b6d03===_0x30f294)break;else _0x56da7d['push'](_0x56da7d['shift']());}catch(_0x1f8268){_0x56da7d['push'](_0x56da7d['shift']());}}}(a144_0x5357,0x4c977));import{getCustomPageSource}from'../../../core/api-client.js';function a144_0x1466(_0x534481,_0xee5afc){_0x534481=_0x534481-0x18a;const _0x535740=a144_0x5357();let _0x14662f=_0x535740[_0x534481];return _0x14662f;}import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,resolveCustomPageDevelopmentUrl}from'./shared.js';function a144_0x5357(){const _0x5b3141=['appcode','join','page','getMonth','number','appCode','getFullYear','str','trim','compress','37730itSGin','3rGPLtU','8wEnVGg','100731DvdaIC','getHours','220JGeMkT','Show\x20a\x20Custom\x20Page\x20and\x20all\x20of\x20its\x20files','2MqCOXr','getTime','2101620hkxjiM','662356QnnGPM','getSeconds','getDate','Custom\x20Page\x20ID','Retrieved\x20Custom\x20Page\x20','padStart','1983093Gholqt','934038ddWtMA','420381geTZji'];a144_0x5357=function(){return _0x5b3141;};return a144_0x5357();}export const pageCustomDetail={'service':a144_0x45989e(0x1a6),'command':'custom-detail','description':a144_0x45989e(0x197),'risk':'read','defaultOutputFormat':a144_0x45989e(0x190),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a144_0x45989e(0x18b),'required':!![],'description':a144_0x45989e(0x19e)},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x2ce75f){readCustomPageId(_0x2ce75f);},async 'execute'(_0x54a608){const _0xd0f637=a144_0x45989e,_0x845ff4=readCustomPageId(_0x54a608),_0x4a8730=await getCustomPageSource(_0x845ff4),{bundle:_0x5f1bb9,createTime:_0x249e4b,updateTime:_0x2147ae,..._0x4c494d}=_0x4a8730,_0x1bff4e=_0x4a8730['id']??_0x845ff4,_0x47b34a=_0x4a8730[_0xd0f637(0x18c)]?.[_0xd0f637(0x18f)]()||_0x54a608[_0xd0f637(0x18e)](_0xd0f637(0x1a4))[_0xd0f637(0x18f)](),_0x466d66=buildCustomPageRuntimeUrl(_0x47b34a,_0x4a8730['pageCode']),_0x5bb538=buildCustomPageEditUrl(_0x47b34a,_0x1bff4e),_0x1eedb0=await resolveCustomPageDevelopmentUrl(_0x47b34a,_0x1bff4e,_0x54a608['cookie']);return{'ok':!![],'data':{..._0x4c494d,..._0x466d66?{'runtimePageUrl':_0x466d66}:{},..._0x1eedb0?{'pageUrl':_0x1eedb0}:{},..._0x5bb538?{'editPageUrl':_0x5bb538}:{},..._0x249e4b==null?{}:{'createTime':formatTime(_0x249e4b)},..._0x2147ae==null?{}:{'updateTime':formatTime(_0x2147ae)}},'message':_0xd0f637(0x19f)+_0x845ff4+'.'};}};function formatTime(_0x2b0b88){const _0x166a3f=a144_0x45989e,_0x5b1cf8=new Date(_0x2b0b88);if(Number['isNaN'](_0x5b1cf8[_0x166a3f(0x199)]()))return String(_0x2b0b88);const _0x556565=[_0x5b1cf8[_0x166a3f(0x18d)](),String(_0x5b1cf8[_0x166a3f(0x18a)]()+0x1)[_0x166a3f(0x1a0)](0x2,'0'),String(_0x5b1cf8[_0x166a3f(0x19d)]())['padStart'](0x2,'0')][_0x166a3f(0x1a5)]('-'),_0x5b9d3b=[String(_0x5b1cf8[_0x166a3f(0x195)]())[_0x166a3f(0x1a0)](0x2,'0'),String(_0x5b1cf8['getMinutes']())[_0x166a3f(0x1a0)](0x2,'0'),String(_0x5b1cf8[_0x166a3f(0x19c)]())[_0x166a3f(0x1a0)](0x2,'0')]['join'](':');return _0x556565+'\x20'+_0x5b9d3b;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a145_0xe00f(_0x13766a,_0x295adb){_0x13766a=_0x13766a-0x1ad;const _0x3dab22=a145_0x3dab();let _0xe00f77=_0x3dab22[_0x13766a];return _0xe00f77;}const a145_0x2e9c1c=a145_0xe00f;(function(_0x313ed1,_0x1f08b1){const _0x45e227=a145_0xe00f,_0x52affe=_0x313ed1();while(!![]){try{const _0x3f1ddf=parseInt(_0x45e227(0x1be))/0x1+-parseInt(_0x45e227(0x1b9))/0x2+parseInt(_0x45e227(0x1bc))/0x3*(parseInt(_0x45e227(0x1ba))/0x4)+-parseInt(_0x45e227(0x1c5))/0x5*(parseInt(_0x45e227(0x1b8))/0x6)+parseInt(_0x45e227(0x1b3))/0x7*(parseInt(_0x45e227(0x1c3))/0x8)+parseInt(_0x45e227(0x1b4))/0x9+parseInt(_0x45e227(0x1b0))/0xa*(-parseInt(_0x45e227(0x1b7))/0xb);if(_0x3f1ddf===_0x1f08b1)break;else _0x52affe['push'](_0x52affe['shift']());}catch(_0xa92eb5){_0x52affe['push'](_0x52affe['shift']());}}}(a145_0x3dab,0xe2541));import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl}from'./shared.js';export const pageCustomList={'service':'page','command':a145_0x2e9c1c(0x1bd),'description':a145_0x2e9c1c(0x1c0),'risk':a145_0x2e9c1c(0x1b6),'defaultOutputFormat':a145_0x2e9c1c(0x1b5),'structuredErrors':!![],'flags':[APPCODE_FLAG_OPTIONAL],async 'execute'(_0x4e73e7){const _0x30c42a=a145_0x2e9c1c,_0x432d77=(await fetchMenuSnapshot(_0x4e73e7['appCode'],_0x4e73e7[_0x30c42a(0x1bf)]))[_0x30c42a(0x1ae)][_0x30c42a(0x1bb)](_0x2dc082=>{const _0x2ed98e=_0x30c42a;if(_0x2dc082[_0x2ed98e(0x1b1)]!==_0x2ed98e(0x1c4)||_0x2dc082['pageId']==null)return[];const _0x3238f2=buildCustomPageDevelopmentUrl(_0x4e73e7[_0x2ed98e(0x1af)],_0x2dc082[_0x2ed98e(0x1c2)]),_0x11ad1f=buildCustomPageEditUrl(_0x4e73e7[_0x2ed98e(0x1af)],_0x2dc082[_0x2ed98e(0x1b2)]);return[{'pageId':_0x2dc082[_0x2ed98e(0x1b2)],'label':_0x2dc082['label'],..._0x3238f2?{'pageUrl':_0x3238f2}:{},..._0x11ad1f?{'editPageUrl':_0x11ad1f}:{}}];});return{'ok':!![],'data':{'pages':_0x432d77},'message':_0x432d77[_0x30c42a(0x1c1)]===0x0?_0x30c42a(0x1ad):'Found\x20'+_0x432d77[_0x30c42a(0x1c1)]+_0x30c42a(0x1c6)};}};function a145_0x3dab(){const _0x5b4ca1=['1662626pZSflI','4CUNdlD','flatMap','4197609SOvGvG','custom-list','106267rFbeSU','cookie','List\x20Custom\x20Pages\x20in\x20the\x20current\x20app','length','path','96gKtheZ','react','10EEAxms','\x20Custom\x20Page(s).','No\x20Custom\x20Pages\x20found.','menus','appCode','4727270UQGeIj','type','pageId','369369TzDyqu','7994367vExKuY','compress','read','11NJckHB','2387568xqzkyc'];a145_0x3dab=function(){return _0x5b4ca1;};return a145_0x3dab();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a146_0x4fa4(_0x155aa5,_0x49e895){_0x155aa5=_0x155aa5-0xd0;const _0x55e67f=a146_0x55e6();let _0x4fa455=_0x55e67f[_0x155aa5];return _0x4fa455;}const a146_0x4e006a=a146_0x4fa4;(function(_0x3d5962,_0x295736){const _0x14eba7=a146_0x4fa4,_0x62ceb3=_0x3d5962();while(!![]){try{const _0x58486c=parseInt(_0x14eba7(0xd4))/0x1+parseInt(_0x14eba7(0xdf))/0x2*(parseInt(_0x14eba7(0xdc))/0x3)+-parseInt(_0x14eba7(0xd5))/0x4+parseInt(_0x14eba7(0xe2))/0x5*(-parseInt(_0x14eba7(0xd1))/0x6)+parseInt(_0x14eba7(0xe6))/0x7*(-parseInt(_0x14eba7(0xef))/0x8)+-parseInt(_0x14eba7(0xe0))/0x9*(parseInt(_0x14eba7(0xe5))/0xa)+parseInt(_0x14eba7(0xd8))/0xb;if(_0x58486c===_0x295736)break;else _0x62ceb3['push'](_0x62ceb3['shift']());}catch(_0x5408bd){_0x62ceb3['push'](_0x62ceb3['shift']());}}}(a146_0x55e6,0xbd0fd));import{getCustomPageSource,publishCustomPage}from'../../../core/api-client.js';import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,resolveCustomPageDevelopmentUrl}from'./shared.js';function a146_0x55e6(){const _0x47cc8a=['4257076JgHfxO','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','apiError','12677984YbKTxG','number','custom-publish','page.custom-publish','210714cNvRHk','FORMAL','Custom\x20Page\x20publish\x20did\x20not\x20return\x20the\x20expected\x20page\x20ID.','44XmnYHQ','66789jVDXCB','pageId','75760RLOePp','unknown','trim','370FRHEsp','339766AKOiCI','remark','push','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20published\x20page\x20could\x20not\x20be\x20generated.','str','appCode','status','Optional\x20publish\x20remark','cookie','16sSXVqw','Publish\x20the\x20latest\x20saved\x20content\x20of\x20a\x20Custom\x20Page','294GAEQev','warnings','Custom\x20Page\x20ID','254987HtdLAA'];a146_0x55e6=function(){return _0x47cc8a;};return a146_0x55e6();}export const pageCustomPublish={'service':'page','command':a146_0x4e006a(0xda),'description':a146_0x4e006a(0xd0),'risk':'write','defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a146_0x4e006a(0xd9),'required':!![],'description':a146_0x4e006a(0xd3)},{'name':a146_0x4e006a(0xe7),'type':'string','description':a146_0x4e006a(0xed)}],async 'validate'(_0x35da50){readCustomPageId(_0x35da50);},async 'dryRun'(_0x548c18){const _0xc2f527=a146_0x4e006a,_0x53178e=readInput(_0x548c18);return{'method':'POST','url':'/smartapi/webcode/file/publish','body':{'id':_0x53178e[_0xc2f527(0xe1)],..._0x53178e['remark']?{'remark':_0x53178e[_0xc2f527(0xe7)]}:{}},'description':'Would\x20publish\x20Custom\x20Page\x20'+_0x53178e[_0xc2f527(0xe1)]+'.'};},async 'execute'(_0xfd3c53){const _0x29f766=a146_0x4e006a,_0x46b336=readInput(_0xfd3c53);await getCustomPageSource(_0x46b336[_0x29f766(0xe1)]);const _0x51c979=await publishCustomPage(_0x46b336);if(!Number['isInteger'](_0x51c979)||_0x51c979!==_0x46b336[_0x29f766(0xe1)])throw CliErrors['apiError'](_0x29f766(0xde));const _0x302919=await getCustomPageSource(_0x46b336[_0x29f766(0xe1)]);if(_0x302919[_0x29f766(0xec)]!==_0x29f766(0xdd))throw CliErrors[_0x29f766(0xd7)]('Custom\x20Page\x20publish\x20did\x20not\x20reach\x20published\x20status:\x20'+(_0x302919[_0x29f766(0xec)]??_0x29f766(0xe3))+'.');const _0x422a7b=_0x302919[_0x29f766(0xeb)]?.[_0x29f766(0xe4)](),_0x16cc35=buildCustomPageEditUrl(_0x422a7b,_0x46b336[_0x29f766(0xe1)]),_0xed772e=await resolveCustomPageDevelopmentUrl(_0x422a7b,_0x46b336[_0x29f766(0xe1)],_0xfd3c53[_0x29f766(0xee)]),_0x690fb6=buildMutationData(_0x46b336,!![],_0xed772e,_0x16cc35);_0x422a7b&&!_0xed772e&&_0x690fb6[_0x29f766(0xd2)]['push'](_0x29f766(0xd6));const _0x1cdc94=buildCustomPageRuntimeUrl(_0x302919[_0x29f766(0xeb)],_0x302919['pageCode']);return _0x1cdc94?_0x690fb6['runtimePageUrl']=_0x1cdc94:_0x690fb6[_0x29f766(0xd2)][_0x29f766(0xe8)](_0x29f766(0xe9)),{'ok':!![],'data':_0x690fb6,'message':'Published\x20Custom\x20Page\x20'+_0x46b336[_0x29f766(0xe1)]+'.'};}};function readInput(_0x241762){const _0x14484e=a146_0x4e006a,_0x226bc3=readCustomPageId(_0x241762),_0x5a29f9=_0x241762[_0x14484e(0xea)]('remark')[_0x14484e(0xe4)]();return{'pageId':_0x226bc3,..._0x5a29f9?{'remark':_0x5a29f9}:{}};}function buildMutationData(_0x14ce4b,_0x423ea0=![],_0x3cb508,_0x363018){const _0x16239a=a146_0x4e006a;return{'operation':_0x16239a(0xdb),'selector':{'pageId':_0x14ce4b[_0x16239a(0xe1)]},'before':null,'after':{'pageId':_0x14ce4b[_0x16239a(0xe1)],'status':_0x16239a(0xdd)},'dryRun':!_0x423ea0,'request':_0x14ce4b,..._0x3cb508?{'pageUrl':_0x3cb508}:{},..._0x363018?{'editPageUrl':_0x363018}:{},'warnings':[]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a147_0x15cfae=a147_0x76ff;(function(_0x189c78,_0x559baa){const _0x151e77=a147_0x76ff,_0x726e21=_0x189c78();while(!![]){try{const _0x5a2c97=-parseInt(_0x151e77(0x84))/0x1+parseInt(_0x151e77(0x6d))/0x2*(-parseInt(_0x151e77(0x6e))/0x3)+parseInt(_0x151e77(0x7a))/0x4*(-parseInt(_0x151e77(0x86))/0x5)+-parseInt(_0x151e77(0x88))/0x6+parseInt(_0x151e77(0x6f))/0x7*(-parseInt(_0x151e77(0x77))/0x8)+parseInt(_0x151e77(0x7f))/0x9*(-parseInt(_0x151e77(0x78))/0xa)+parseInt(_0x151e77(0x7b))/0xb;if(_0x5a2c97===_0x559baa)break;else _0x726e21['push'](_0x726e21['shift']());}catch(_0x1254cf){_0x726e21['push'](_0x726e21['shift']());}}}(a147_0x3dc2,0x24ed9));function a147_0x76ff(_0x187650,_0x42d40c){_0x187650=_0x187650-0x69;const _0x3dc252=a147_0x3dc2();let _0x76ffe6=_0x3dc252[_0x187650];return _0x76ffe6;}import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{getAppBaseUrl,getPublishedAppDomain}from'../../../constant/domain.js';function a147_0x3dc2(){const _0x2b2bf1=['17814fnYMZP','join','Invalid\x20Custom\x20Page\x20content:\x20','page-content','validation','values','Optional\x20app\x20code\x20resolved\x20from\x20page\x20ID\x20when\x20omitted','react','length','200lrUvRi','1869DMWqZe','16317ocYVoo','file','isInteger','pageId','trim','parse','num','string','768PohnGL','10pKvJjl','map','8LlRpSO','12650011MvCTeC','flagMissing','path','--page-content\x20must\x20be\x20a\x20JSON\x20object\x20whose\x20values\x20are\x20file\x20content\x20strings.','2053575AxEMEO','find','/pages/','object','message','208492lPknfq','/ide/','682580McnoAb','--id\x20must\x20be\x20a\x20positive\x20integer.'];a147_0x3dc2=function(){return _0x2b2bf1;};return a147_0x3dc2();}import{CliErrors}from'../../../errors.js';import{validateCustomPageSourceFiles}from'./syntax.js';export const CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL={...APPCODE_FLAG_OPTIONAL,'description':a147_0x15cfae(0x6a)};function trimOptional(_0x2d034d){const _0x29ea41=a147_0x15cfae;return _0x2d034d?.[_0x29ea41(0x73)]()||undefined;}export function buildCustomPageRuntimeUrl(_0xd75956,_0x21e262){const _0x59edc4=trimOptional(_0xd75956),_0x1dacd1=trimOptional(_0x21e262);if(!_0x59edc4||!_0x1dacd1)return undefined;return getPublishedAppDomain(_0x59edc4)+'/'+encodeURIComponent(_0x1dacd1);}export function buildCustomPageDevelopmentUrl(_0x21a2b7,_0x112d5f){const _0x1e5430=a147_0x15cfae,_0x465fbf=trimOptional(_0x21a2b7),_0x350e97=trimOptional(_0x112d5f);if(!_0x465fbf||!_0x350e97)return undefined;return getAppBaseUrl(_0x465fbf)+_0x1e5430(0x81)+encodeURIComponent(_0x350e97);}export async function resolveCustomPageDevelopmentUrl(_0x125769,_0x208c9e,_0x45cd8e){const _0xc1db90=a147_0x15cfae,_0x2e82b0=trimOptional(_0x125769);if(!_0x2e82b0)return undefined;try{const _0x47a2a4=(await fetchMenuSnapshot(_0x2e82b0,_0x45cd8e))['menus'][_0xc1db90(0x80)](_0x39ab62=>_0x39ab62['type']===_0xc1db90(0x6b)&&_0x39ab62[_0xc1db90(0x72)]===_0x208c9e);return buildCustomPageDevelopmentUrl(_0x2e82b0,_0x47a2a4?.[_0xc1db90(0x7d)]);}catch{return undefined;}}export function buildCustomPageEditUrl(_0x34fbfe,_0x43c34d){const _0x4d0f79=a147_0x15cfae,_0x54712a=trimOptional(_0x34fbfe);if(!_0x54712a)return;const _0x32d61f=trimOptional(_0x43c34d==null?undefined:String(_0x43c34d));if(!_0x32d61f)return;return getAppBaseUrl(_0x54712a)+_0x4d0f79(0x85)+encodeURIComponent(_0x32d61f);}export function parseCustomPageContent(_0x597554){const _0x13fd43=a147_0x15cfae;if(!_0x597554[_0x13fd43(0x73)]())throw CliErrors[_0x13fd43(0x7c)](_0x13fd43(0x8b));let _0x21d516;try{_0x21d516=JSON[_0x13fd43(0x74)](_0x597554);}catch{throw CliErrors[_0x13fd43(0x8c)]('--page-content\x20must\x20be\x20valid\x20JSON.');}if(typeof _0x21d516!==_0x13fd43(0x82)||_0x21d516===null||Array['isArray'](_0x21d516)||Object[_0x13fd43(0x69)](_0x21d516)['some'](_0x3e93c9=>typeof _0x3e93c9!==_0x13fd43(0x76)))throw CliErrors[_0x13fd43(0x8c)](_0x13fd43(0x7e));return _0x21d516;}export async function validateCustomPageContent(_0x55a707){const _0x4889c4=a147_0x15cfae,_0x16c8b2=await validateCustomPageSourceFiles(_0x55a707);if(_0x16c8b2[_0x4889c4(0x6c)]>0x0)throw CliErrors['validation'](_0x4889c4(0x8a)+_0x16c8b2[_0x4889c4(0x79)](_0x63679a=>_0x63679a[_0x4889c4(0x70)]+':\x20'+_0x63679a[_0x4889c4(0x83)])[_0x4889c4(0x89)](';\x20'));}export function readCustomPageId(_0x4ce1a7){const _0x49aa33=a147_0x15cfae,_0xd533e7=_0x4ce1a7[_0x49aa33(0x75)]('id');if(!Number[_0x49aa33(0x71)](_0xd533e7)||_0xd533e7<=0x0)throw CliErrors['validation'](_0x49aa33(0x87));return _0xd533e7;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a148_0x181ee3=a148_0x25e6;(function(_0x194493,_0x5c9936){const _0x2324bd=a148_0x25e6,_0xa3e8b3=_0x194493();while(!![]){try{const _0x5ebfd2=-parseInt(_0x2324bd(0x17e))/0x1*(-parseInt(_0x2324bd(0x17b))/0x2)+-parseInt(_0x2324bd(0x17f))/0x3*(-parseInt(_0x2324bd(0x176))/0x4)+parseInt(_0x2324bd(0x175))/0x5+parseInt(_0x2324bd(0x174))/0x6+parseInt(_0x2324bd(0x184))/0x7+-parseInt(_0x2324bd(0x179))/0x8+-parseInt(_0x2324bd(0x177))/0x9;if(_0x5ebfd2===_0x5c9936)break;else _0xa3e8b3['push'](_0xa3e8b3['shift']());}catch(_0x56c7b9){_0xa3e8b3['push'](_0xa3e8b3['shift']());}}}(a148_0x415a,0xb415a));function a148_0x25e6(_0x4d70fc,_0x14119c){_0x4d70fc=_0x4d70fc-0x173;const _0x415a84=a148_0x415a();let _0x25e607=_0x415a84[_0x4d70fc];return _0x25e607;}import{format}from'prettier';const SOURCE_PARSERS={'.js':a148_0x181ee3(0x173),'.jsx':a148_0x181ee3(0x173),'.ts':a148_0x181ee3(0x186),'.tsx':a148_0x181ee3(0x186)},CUSTOM_PAGE_EXTENSIONS=[a148_0x181ee3(0x17a),'.tsx'];export async function validateCustomPageSourceFiles(_0x405c4d){const _0x13cf4e=a148_0x181ee3,_0x340c72=Object[_0x13cf4e(0x178)](_0x405c4d)[_0x13cf4e(0x17c)](([_0x24ebae])=>getParser(_0x24ebae));if(!_0x340c72['some'](([_0x5e5266])=>isReactSourceFile(_0x5e5266)))return[{'file':_0x13cf4e(0x181),'message':'Missing\x20React\x20source\x20file\x20with\x20extension\x20.jsx\x20or\x20.tsx'}];const _0x124bed=await Promise['all'](_0x340c72['map'](async([_0x3bf393,_0x464581])=>{try{return await format(_0x464581,{'parser':getParser(_0x3bf393)}),undefined;}catch(_0x402cc1){return{'file':_0x3bf393,'message':_0x402cc1 instanceof Error?_0x402cc1['message']:String(_0x402cc1)};}}));return _0x124bed[_0x13cf4e(0x17c)](_0x3979d0=>_0x3979d0!==undefined);}function getParser(_0x25c22f){const _0x4afc9c=a148_0x181ee3,_0x1fbc9d=_0x25c22f[_0x4afc9c(0x185)]()[_0x4afc9c(0x17d)]();return Object[_0x4afc9c(0x178)](SOURCE_PARSERS)[_0x4afc9c(0x183)](([_0x4e7550])=>_0x1fbc9d[_0x4afc9c(0x182)](_0x4e7550))?.[0x1];}function a148_0x415a(){const _0x4e7c0d=['babel','707070qHyLxZ','3126600gSAjXi','4335772JbjbrJ','11687220fNLUNE','entries','10525496QTxyEw','.jsx','60524GygntA','filter','toLowerCase','39yMVXjq','3nMnGvd','some','page-content','endsWith','find','2411969aKOJfH','trim','typescript'];a148_0x415a=function(){return _0x4e7c0d;};return a148_0x415a();}function isReactSourceFile(_0x4fbb4a){const _0x1e1854=a148_0x181ee3,_0x33df9d=_0x4fbb4a[_0x1e1854(0x185)]()[_0x1e1854(0x17d)]();return CUSTOM_PAGE_EXTENSIONS[_0x1e1854(0x180)](_0x2d8561=>_0x33df9d[_0x1e1854(0x182)](_0x2d8561));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x371b18,_0x4f7a23){const _0x375c57=a149_0x46d1,_0x365612=_0x371b18();while(!![]){try{const _0x5d76e4=parseInt(_0x375c57(0x16c))/0x1+parseInt(_0x375c57(0x177))/0x2+parseInt(_0x375c57(0x165))/0x3*(-parseInt(_0x375c57(0x176))/0x4)+-parseInt(_0x375c57(0x175))/0x5*(parseInt(_0x375c57(0x17a))/0x6)+parseInt(_0x375c57(0x164))/0x7*(-parseInt(_0x375c57(0x169))/0x8)+parseInt(_0x375c57(0x178))/0x9+-parseInt(_0x375c57(0x168))/0xa;if(_0x5d76e4===_0x4f7a23)break;else _0x365612['push'](_0x365612['shift']());}catch(_0x4b469c){_0x365612['push'](_0x365612['shift']());}}}(a149_0x2385,0xe053b));function buildIndexFile(_0x47d754){const _0x372147=a149_0x46d1;return _0x372147(0x16a)+JSON[_0x372147(0x16b)](_0x47d754)+_0x372147(0x167);}function buildStyleFile(){const _0x4d0ee3=a149_0x46d1;return _0x4d0ee3(0x179);}function buildLocalesFile(_0x36ad9f){const _0x3496e0=a149_0x46d1,_0x4e5892=_0x36ad9f[_0x3496e0(0x170)](_0x2e98e7=>{const _0x625f94=_0x3496e0;let _0x4145ab='';switch(_0x2e98e7){case _0x625f94(0x171):_0x4145ab='这是一个基础页面模板,你可以在此基础上进行开发。';break;case _0x625f94(0x163):_0x4145ab='This\x20is\x20a\x20basic\x20page\x20template,\x20you\x20can\x20develop\x20based\x20on\x20it.';break;case'ja-JP':_0x4145ab=_0x625f94(0x173);break;case'tr-TR':_0x4145ab=_0x625f94(0x172);break;case'id-ID':_0x4145ab=_0x625f94(0x16f);break;default:_0x4145ab=_0x625f94(0x16e);}return'\x20\x20'+JSON[_0x625f94(0x16b)](_0x2e98e7)+':\x20{\x0a\x20\x20\x20\x20'+JSON[_0x625f94(0x16b)]('pageDescription')+':\x20'+JSON['stringify'](_0x4145ab)+',\x0a\x20\x20}';})[_0x3496e0(0x174)](',\x0a');return _0x3496e0(0x16d)+_0x4e5892+_0x3496e0(0x166);}function a149_0x2385(){const _0x2980c1=['618507YwVrdP','\x0a};\x0a','}</Typography.Title>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<Typography.Paragraph>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{$i18n.t(\x27pageDescription\x27,\x20\x27这是一个基础页面模板,你可以在此基础上进行开发。\x27)}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</Typography.Paragraph>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</Typography>\x0a\x20\x20\x20\x20\x20\x20</Card>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20);\x0a};\x0a\x0aexport\x20default\x20App;\x0a','8069740tvtyVK','48YZxpkz','import\x20React\x20from\x20\x27react\x27;\x0aimport\x20{\x20Card,\x20Typography\x20}\x20from\x20\x27antd\x27;\x0aimport\x20{\x20useSdkClient,\x20useI18n,\x20useNavigate,\x20useLocation\x20}\x20from\x20\x22@/context/app-context\x22;\x0aimport\x20{\x20locales\x20}\x20from\x20\x27../locales\x27;\x0aimport\x20\x27./index.css\x27;\x0a\x0aconst\x20App\x20=\x20()\x20=>\x20{\x0a\x20\x20const\x20client\x20=\x20useSdkClient();\x20//\x20client\x20可以用于获取其他数据集的数据\x0a\x20\x20const\x20$i18n\x20=\x20useI18n();\x20//\x20国际化多语言\x20i18n\x20实例\x0a\x20\x20const\x20navigate\x20=\x20useNavigate();\x20//\x20react-router\x20navigate\x20导航实例\x0a\x20\x20const\x20location\x20=\x20useLocation();\x20//\x20浏览器\x20location\x20实例\x0a\x0a\x20\x20$i18n.addLocale(locales);\x20//\x20添加多语言词包\x0a\x0a\x20\x20return\x20(\x0a\x20\x20\x20\x20<div\x20className=\x22page-container\x22>\x0a\x20\x20\x20\x20\x20\x20<Card>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<Typography>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<Typography.Title\x20level={2}>{','stringify','952252RDcsUh','export\x20const\x20locales\x20=\x20{\x0a','This\x20is\x20a\x20basic\x20page\x20template,\x20you\x20can\x20develop\x20based\x20on\x20it.','Ini\x20adalah\x20sebuah\x20halaman\x20dasar.\x20Anda\x20dapat\x20mengembangkan\x20ini.','map','zh-CN','Bu\x20bir\x20temel\x20sayfa\x20şablonudur.\x20Bu\x20temaplana\x20dayanarak\x20geliştirilebilir.','これは基本ページテンプレートです。あなたは、これに基づいて開発できます。','join','30QlkKLp','24coOYjj','3188824IfCJCX','11177739LmFvrU','.page-container\x20{\x0a\x20\x20padding:\x2024px;\x0a\x20\x20background:\x20#f0f2f5;\x0a\x20\x20min-height:\x20100vh;\x0a}\x0a','791412czIXgL','en-US','40124jqpVqX'];a149_0x2385=function(){return _0x2980c1;};return a149_0x2385();}function a149_0x46d1(_0x40abc2,_0x530e35){_0x40abc2=_0x40abc2-0x163;const _0x2385be=a149_0x2385();let _0x46d13d=_0x2385be[_0x40abc2];return _0x46d13d;}export function buildInitialFiles(_0x5182fa,_0x415536){return{'src/app/index.jsx':buildIndexFile(_0x5182fa),'src/app/index.css':buildStyleFile(),'src/locales/index.js':buildLocalesFile(_0x415536)};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a150_0x3557c9=a150_0x26e1;function a150_0x26e1(_0xe5760d,_0x19afc6){_0xe5760d=_0xe5760d-0x1ec;const _0x42bdbc=a150_0x42bd();let _0x26e111=_0x42bdbc[_0xe5760d];return _0x26e111;}(function(_0x436caa,_0x5688ba){const _0x30b1b1=a150_0x26e1,_0xaa7590=_0x436caa();while(!![]){try{const _0x45a9e9=parseInt(_0x30b1b1(0x20e))/0x1*(parseInt(_0x30b1b1(0x208))/0x2)+parseInt(_0x30b1b1(0x20f))/0x3+-parseInt(_0x30b1b1(0x1fa))/0x4*(parseInt(_0x30b1b1(0x1f7))/0x5)+-parseInt(_0x30b1b1(0x211))/0x6*(parseInt(_0x30b1b1(0x20a))/0x7)+parseInt(_0x30b1b1(0x1fd))/0x8*(-parseInt(_0x30b1b1(0x1ed))/0x9)+-parseInt(_0x30b1b1(0x203))/0xa*(parseInt(_0x30b1b1(0x205))/0xb)+parseInt(_0x30b1b1(0x201))/0xc*(parseInt(_0x30b1b1(0x1fb))/0xd);if(_0x45a9e9===_0x5688ba)break;else _0xaa7590['push'](_0xaa7590['shift']());}catch(_0x53dd0b){_0xaa7590['push'](_0xaa7590['shift']());}}}(a150_0x42bd,0xc75b9));import{getCustomPageSource,updateCustomPageContent}from'../../../core/api-client.js';import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,parseCustomPageContent,resolveCustomPageDevelopmentUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,validateCustomPageContent}from'./shared.js';export const pageCustomUpdate={'service':a150_0x3557c9(0x206),'command':'custom-update','description':a150_0x3557c9(0x1ff),'risk':a150_0x3557c9(0x200),'defaultOutputFormat':a150_0x3557c9(0x1fe),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a150_0x3557c9(0x1f9),'required':!![],'description':a150_0x3557c9(0x20d)},{'name':a150_0x3557c9(0x1fc),'type':a150_0x3557c9(0x1ef),'required':!![],'description':'Complete\x20page\x20files\x20as\x20JSON'},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x582bca){const _0xc603f6=a150_0x3557c9;readCustomPageId(_0x582bca),await validateCustomPageContent(parseCustomPageContent(_0x582bca[_0xc603f6(0x1ec)](_0xc603f6(0x1fc))));},async 'dryRun'(_0x24cd31){const _0x58094e=a150_0x3557c9,_0x133ffc=await readInput(_0x24cd31);return{'method':_0x58094e(0x202),'url':_0x58094e(0x1f2),'body':{'id':_0x133ffc[_0x58094e(0x1f5)],'codeContent':_0x133ffc[_0x58094e(0x20c)]},'description':_0x58094e(0x207)+_0x133ffc['pageId']+'.'};},async 'execute'(_0x202c73){const _0x340ca2=a150_0x3557c9,_0x429651=await readInput(_0x202c73),_0x356aa3=await updateCustomPageContent({'pageId':_0x429651[_0x340ca2(0x1f5)],'pageContent':_0x429651[_0x340ca2(0x20c)]});if(!Number[_0x340ca2(0x204)](_0x356aa3['newVersion'])||_0x356aa3['newVersion']<=0x0)throw CliErrors[_0x340ca2(0x1f0)]('Custom\x20Page\x20update\x20did\x20not\x20create\x20a\x20new\x20version.');const _0x40fa8d=buildCustomPageEditUrl(_0x429651['appCode'],_0x429651[_0x340ca2(0x1f5)]),_0x358538=await resolveCustomPageDevelopmentUrl(_0x429651[_0x340ca2(0x1f8)],_0x429651[_0x340ca2(0x1f5)],_0x202c73['cookie']);return{'ok':!![],'data':buildMutationData(_0x429651,_0x356aa3,_0x358538,_0x40fa8d,_0x358538?[]:[_0x340ca2(0x1f1)]),'message':_0x340ca2(0x210)+_0x429651[_0x340ca2(0x1f5)]+'.'};}};function a150_0x42bd(){const _0x45126e=['POST','200yqQPBx','isInteger','594649rbrAFs','page','Would\x20save\x20all\x20files\x20of\x20Custom\x20Page\x20','47746UPfhvH','appcode','9975NvqlHH','Cannot\x20determine\x20the\x20appCode\x20for\x20Custom\x20Page\x20','pageContent','Custom\x20Page\x20ID','6DBAJPl','2103519YmeiCp','Updated\x20Custom\x20Page\x20','354fuJbfW','str','54RHCcQc','newVersion','string','apiError','Custom\x20Page\x20was\x20updated,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','/smartapi/webcode/page/update/content','validation','trim','pageId','page.custom-update','10360pukLbc','appCode','number','1544ByGqmx','22373xthfoj','page-content','1402896mfzSQY','compress','Save\x20all\x20files\x20of\x20a\x20Custom\x20Page','write','20844DWiAaC'];a150_0x42bd=function(){return _0x45126e;};return a150_0x42bd();}async function readInput(_0x244c33){const _0x160510=a150_0x3557c9,_0x29f2b5=readCustomPageId(_0x244c33),_0x54fece=_0x244c33[_0x160510(0x1ec)](_0x160510(0x209))[_0x160510(0x1f4)]()||(await getCustomPageSource(_0x29f2b5))[_0x160510(0x1f8)]?.['trim']();if(!_0x54fece)throw CliErrors[_0x160510(0x1f3)](_0x160510(0x20b)+_0x29f2b5+'.');return{'appCode':_0x54fece,'pageId':_0x29f2b5,'pageContent':parseCustomPageContent(_0x244c33[_0x160510(0x1ec)]('page-content'))};}function buildMutationData(_0x1ef033,_0x85a69d,_0x3325a,_0x115a38,_0x43efe2=[]){const _0x2b9a06=a150_0x3557c9;return{'operation':_0x2b9a06(0x1f6),'selector':{'appCode':_0x1ef033['appCode'],'pageId':_0x1ef033['pageId']},'before':null,'after':{'pageId':_0x85a69d?.['pageId']??_0x1ef033[_0x2b9a06(0x1f5)],'version':_0x85a69d?.[_0x2b9a06(0x1ee)]??null,'pageContent':_0x1ef033['pageContent']},'dryRun':_0x85a69d===undefined,'request':_0x1ef033,..._0x3325a?{'pageUrl':_0x3325a}:{},..._0x115a38?{'editPageUrl':_0x115a38}:{},'warnings':_0x43efe2};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a151_0x2f83d9=a151_0x4479;(function(_0x5991f3,_0x403fd5){const _0x505106=a151_0x4479,_0x577e72=_0x5991f3();while(!![]){try{const _0x54ba8f=parseInt(_0x505106(0x200))/0x1*(parseInt(_0x505106(0x1f1))/0x2)+-parseInt(_0x505106(0x1ed))/0x3*(parseInt(_0x505106(0x205))/0x4)+-parseInt(_0x505106(0x207))/0x5*(parseInt(_0x505106(0x1f0))/0x6)+-parseInt(_0x505106(0x1f6))/0x7*(-parseInt(_0x505106(0x1fb))/0x8)+parseInt(_0x505106(0x1f4))/0x9*(parseInt(_0x505106(0x1ee))/0xa)+-parseInt(_0x505106(0x1ec))/0xb+parseInt(_0x505106(0x1eb))/0xc*(parseInt(_0x505106(0x204))/0xd);if(_0x54ba8f===_0x403fd5)break;else _0x577e72['push'](_0x577e72['shift']());}catch(_0x1616f2){_0x577e72['push'](_0x577e72['shift']());}}}(a151_0x4390,0x39695));function a151_0x4479(_0x3ada20,_0x40fe8a){_0x3ada20=_0x3ada20-0x1eb;const _0x43900d=a151_0x4390();let _0x447956=_0x43900d[_0x3ada20];return _0x447956;}import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a151_0x4390(){const _0x34f3f4=['30ASEyaJ','124ivqEkZ','/standard-page-status?appCode=','/smartapi/lovrabet/dataset/','9HlHvxG','GET','52346ledrrw','Query\x20Data\x20List\x20Page\x20facts\x20for\x20a\x20dataset','string','code','source','248WmsYaV','compress','relatedPages','status','length','1132mNyASv','alias','read','Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','10933GoaSCe','28rdBHDd','page','360380aLletB','6132mCjdtP','4406105qAZZzN','13134yMNKWP','2949850xKsppm','name'];a151_0x4390=function(){return _0x34f3f4;};return a151_0x4390();}import{assessDataListPageState,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';export const pageDataListStatus={'service':a151_0x2f83d9(0x206),'command':'data-list-status','description':a151_0x2f83d9(0x1f7),'risk':a151_0x2f83d9(0x202),'defaultOutputFormat':a151_0x2f83d9(0x1fc),'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a151_0x2f83d9(0x201),'type':a151_0x2f83d9(0x1f8),'description':a151_0x2f83d9(0x203)}],async 'validate'(_0x8999ba){validateDatasetSelector(_0x8999ba);},async 'dryRun'(_0x9145e){const _0x5643b1=a151_0x2f83d9,_0x3f465b=await loadDatasetDetailForPage(_0x9145e);return{'method':_0x5643b1(0x1f5),'url':_0x5643b1(0x1f3)+_0x3f465b[_0x5643b1(0x1f9)]+_0x5643b1(0x1f2)+encodeURIComponent(_0x9145e['appCode']),'description':serializeDryRunDescription({'dataset':{'id':_0x3f465b['id'],'code':_0x3f465b[_0x5643b1(0x1f9)],'name':_0x3f465b[_0x5643b1(0x1ef)]},'action':'query-data-list-status'})};},async 'execute'(_0x6f8090){const _0x24593b=a151_0x2f83d9,_0xd14f3c=await loadDatasetDetailForPage(_0x6f8090),_0x1ea094=await loadDataListPageStatusForGenerate(_0x6f8090,_0xd14f3c[_0x24593b(0x1f9)]),_0x3968b4=getUndeletedRelatedPages(_0xd14f3c),_0x1cdb16=assessDataListPageState(_0xd14f3c['code'],_0x1ea094,{'fallbackUndeletedPages':_0x3968b4});return{'ok':!![],'data':{'datasetCode':_0xd14f3c[_0x24593b(0x1f9)],'precheckSource':_0x1ea094?.[_0x24593b(0x1fa)]??'related-pages-fallback','status':_0x1cdb16[_0x24593b(0x1fe)],'manualResolutionRequired':_0x1cdb16['manualResolutionRequired'],'nextAction':_0x1cdb16['nextAction'],'dataListPageStatus':_0x1ea094,'relatedPages':{'total':_0xd14f3c[_0x24593b(0x1fd)][_0x24593b(0x1ff)],'undeletedCount':_0x3968b4[_0x24593b(0x1ff)]}}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a152_0x54f7(){const _0x5e5c18=['Submitted\x20a\x20generate\x20task','precheck','1638012unbCJh','2AkLOZW','dataset','/smartapi/lovrabet/dataset/','currentStep','Start\x20async\x20Data\x20List\x20Page\x20generation\x20from\x20a\x20dataset','appCode','Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','message','dryRun','related-pages-fallback','9853104ytZSmU','CRUD_PAGE_SET','allowGenerate','number','930253OdZyPp','fieldCount','boolean','nextAction','alias','status','name','taskId','clientOperationId','5839771ysHUPo','code','31186872BATIEy','SUCCESS','2244415rMqziB','PARTIAL_SUCCESS','manualResolutionRequired','source','apply','/generate-standard-pages/start','4147086oqjeCu','bool','DATA_LIST','POST','Dry-run\x20preview\x20(pass\x20--apply\x20to\x20execute\x20the\x20generation)','operationId','string','Actually\x20execute\x20the\x20generation.\x20Without\x20this\x20flag,\x20only\x20a\x20dry-run\x20preview\x20is\x20shown.','reused','Reusing\x20an\x20existing\x20generate\x20task','progressRate','page-pattern','generate-start','page\x20generate-start\x20does\x20not\x20accept\x20--page-pattern.','DATA_LIST\x20currently\x20has\x20one\x20fixed\x20pattern:\x20CRUD_PAGE_SET.','page\x20generate-start\x20does\x20not\x20accept\x20--page-type.','6MufZOT','write','dataListPageStatus'];a152_0x54f7=function(){return _0x5e5c18;};return a152_0x54f7();}const a152_0x111321=a152_0x26c4;(function(_0x414929,_0x19997f){const _0x4f16a2=a152_0x26c4,_0x11d562=_0x414929();while(!![]){try{const _0x5e04b1=-parseInt(_0x4f16a2(0x87))/0x1*(parseInt(_0x4f16a2(0x79))/0x2)+-parseInt(_0x4f16a2(0x9a))/0x3+parseInt(_0x4f16a2(0x78))/0x4+-parseInt(_0x4f16a2(0x94))/0x5+-parseInt(_0x4f16a2(0xaa))/0x6*(-parseInt(_0x4f16a2(0x90))/0x7)+-parseInt(_0x4f16a2(0x83))/0x8+parseInt(_0x4f16a2(0x92))/0x9;if(_0x5e04b1===_0x19997f)break;else _0x11d562['push'](_0x11d562['shift']());}catch(_0x9ed609){_0x11d562['push'](_0x11d562['shift']());}}}(a152_0x54f7,0xaec34));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a152_0x26c4(_0x2684e8,_0x52977b){_0x2684e8=_0x2684e8-0x75;const _0x54f703=a152_0x54f7();let _0x26c49f=_0x54f703[_0x2684e8];return _0x26c49f;}import{assessGenerateOperationState,assessDataListPageState,buildPageGenerateOperationStatusQueryCommand,buildDataListPageStatusQueryCommand,createPageGenerateClientOperationId,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';import{startGenerateDataListPages}from'../../core/api-client.js';export const pageGenerateStart={'service':'page','command':a152_0x111321(0xa6),'description':a152_0x111321(0x7d),'risk':a152_0x111321(0xab),'defaultOutputFormat':'compress','rejectedFlags':[{'name':'page-type','message':a152_0x111321(0xa9),'hint':'This\x20command\x20always\x20generates\x20a\x20DATA_LIST\x20page\x20from\x20a\x20dataset.'},{'name':a152_0x111321(0xa5),'message':a152_0x111321(0xa7),'hint':a152_0x111321(0xa8)}],'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a152_0x111321(0x8b),'type':a152_0x111321(0xa0),'description':a152_0x111321(0x7f)},{'name':a152_0x111321(0x98),'type':a152_0x111321(0x89),'description':a152_0x111321(0xa1)}],async 'validate'(_0xffcb73){validateDatasetSelector(_0xffcb73);},async 'dryRun'(_0x2729ce){const _0x17b316=a152_0x111321,_0x2cfae6=await prepare(_0x2729ce);return{'method':_0x17b316(0x9d),'url':_0x17b316(0x7b)+_0x2cfae6[_0x17b316(0x7a)][_0x17b316(0x91)]+_0x17b316(0x99),'body':{'appCode':_0x2729ce[_0x17b316(0x7e)],'clientOperationId':_0x2cfae6[_0x17b316(0x8f)]},'description':serializeDryRunDescription({'dataset':{'id':_0x2cfae6[_0x17b316(0x7a)]['id'],'code':_0x2cfae6[_0x17b316(0x7a)][_0x17b316(0x91)],'name':_0x2cfae6[_0x17b316(0x7a)][_0x17b316(0x8d)],'fieldCount':_0x2cfae6[_0x17b316(0x7a)][_0x17b316(0x88)]},'precheckSource':_0x2cfae6[_0x17b316(0x75)]?.[_0x17b316(0x97)]??_0x17b316(0x82),'action':_0x17b316(0xa6),'clientOperationId':_0x2cfae6['clientOperationId'],'plannedStatus':_0x2cfae6['precheck'][_0x17b316(0x8c)],'reason':_0x2cfae6[_0x17b316(0x77)][_0x17b316(0x80)]})};},async 'execute'(_0x5da0e4){const _0x24926c=a152_0x111321;if(!_0x5da0e4[_0x24926c(0x9b)]('apply')){const _0x312440=await pageGenerateStart[_0x24926c(0x81)](_0x5da0e4);return{'ok':!![],'message':_0x24926c(0x9e),'data':_0x312440};}const _0x55b471=await prepare(_0x5da0e4);if(!_0x55b471[_0x24926c(0x77)][_0x24926c(0x85)])return{'ok':![],'message':_0x55b471[_0x24926c(0x77)][_0x24926c(0x80)],'data':{'datasetCode':_0x55b471['dataset'][_0x24926c(0x91)],'pageType':_0x24926c(0x9c),'pagePattern':_0x24926c(0x84),'clientOperationId':_0x55b471[_0x24926c(0x8f)],'precheckSource':_0x55b471['dataListPageStatus']?.['source']??_0x24926c(0x82),'status':_0x55b471[_0x24926c(0x77)][_0x24926c(0x8c)],'manualResolutionRequired':_0x55b471[_0x24926c(0x77)][_0x24926c(0x96)],'nextAction':_0x55b471[_0x24926c(0x77)][_0x24926c(0x8a)],'query':{'command':buildDataListPageStatusQueryCommand(_0x55b471[_0x24926c(0x7a)][_0x24926c(0x91)],_0x5da0e4[_0x24926c(0x7e)])},'dataListPageStatus':_0x55b471['dataListPageStatus']}};const _0x4f38b3=await startGenerateDataListPages(_0x5da0e4[_0x24926c(0x7e)],_0x55b471['dataset']['code'],{'clientOperationId':_0x55b471[_0x24926c(0x8f)]}),_0x5da2b9=_0x4f38b3[_0x24926c(0x8c)]===_0x24926c(0x93)||_0x4f38b3[_0x24926c(0x8c)]===_0x24926c(0x95)?await loadDataListPageStatusForGenerate(_0x5da0e4,_0x55b471[_0x24926c(0x7a)]['code']):null,_0x46488d=assessGenerateOperationState(_0x55b471[_0x24926c(0x7a)][_0x24926c(0x91)],_0x4f38b3[_0x24926c(0x8c)],_0x5da2b9);return{'ok':!![],'message':_0x4f38b3[_0x24926c(0xa2)]?_0x24926c(0xa3):_0x24926c(0x76),'data':{'datasetCode':_0x55b471[_0x24926c(0x7a)][_0x24926c(0x91)],'appCode':_0x5da0e4[_0x24926c(0x7e)],'pageType':_0x24926c(0x9c),'pagePattern':_0x24926c(0x84),'taskId':_0x4f38b3[_0x24926c(0x8e)]??null,'operationId':_0x4f38b3[_0x24926c(0x9f)]??null,'clientOperationId':_0x55b471[_0x24926c(0x8f)],'jobStatus':_0x4f38b3['status']??null,'progressRate':typeof _0x4f38b3['progressRate']===_0x24926c(0x86)?_0x4f38b3[_0x24926c(0xa4)]:null,'currentStep':_0x4f38b3[_0x24926c(0x7c)]??null,'reused':_0x4f38b3[_0x24926c(0xa2)]===!![],'status':_0x46488d[_0x24926c(0x8c)],'manualResolutionRequired':_0x46488d['manualResolutionRequired'],'nextAction':_0x46488d[_0x24926c(0x8a)],'query':{'command':buildPageGenerateOperationStatusQueryCommand(_0x55b471[_0x24926c(0x7a)][_0x24926c(0x91)],{'appCode':_0x5da0e4[_0x24926c(0x7e)],'taskId':_0x4f38b3[_0x24926c(0x8e)],'operationId':_0x4f38b3[_0x24926c(0x9f)],'clientOperationId':_0x55b471[_0x24926c(0x8f)]})},'dataListPageStatus':_0x5da2b9}};}};async function prepare(_0x351eab){const _0x93bf23=a152_0x111321,_0x596cb8=await loadDatasetDetailForPage(_0x351eab),_0x496a11=await loadDataListPageStatusForGenerate(_0x351eab,_0x596cb8['code']),_0x11eded=getUndeletedRelatedPages(_0x596cb8);return{'dataset':_0x596cb8,'dataListPageStatus':_0x496a11,'clientOperationId':createPageGenerateClientOperationId(),'precheck':assessDataListPageState(_0x596cb8[_0x93bf23(0x91)],_0x496a11,{'fallbackUndeletedPages':_0x11eded})};}
|