@lovrabet/rabetbase-cli 2.4.7-beta.2 → 2.4.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/filter.js +1 -1
- package/lib/commands/data/getOne.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/data/shared.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-update.js +1 -1
- package/lib/commands/dataset/generate.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/dataset/relation-audit.js +1 -1
- package/lib/commands/dataset/relation-create.js +1 -1
- package/lib/commands/dataset/relation-delete.js +1 -1
- package/lib/commands/dataset/relation-shared.js +1 -1
- package/lib/commands/dataset/relation-update.js +1 -1
- package/lib/commands/dataset/relations.js +1 -1
- package/lib/commands/dataset/rename.js +1 -1
- package/lib/commands/dataset/restore.js +1 -1
- package/lib/commands/db/analysis-batching.js +1 -1
- package/lib/commands/db/analyze-batch-plan.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff-refresh-start.js +1 -1
- package/lib/commands/db/diff-refresh-status.js +1 -1
- package/lib/commands/db/diff.js +1 -1
- package/lib/commands/db/index.js +1 -1
- package/lib/commands/db/list.js +1 -1
- package/lib/commands/db/shared.js +1 -1
- package/lib/commands/db/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/init/index.js +1 -1
- package/lib/commands/issue/index.js +1 -1
- package/lib/commands/issue/nudge.js +1 -1
- package/lib/commands/issue/report.js +1 -1
- package/lib/commands/issue/shared.js +1 -1
- package/lib/commands/kb/create.js +1 -1
- package/lib/commands/kb/delete.js +1 -1
- package/lib/commands/kb/detail.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/kb/list.js +1 -1
- package/lib/commands/kb/search.js +1 -1
- package/lib/commands/kb/shared.js +1 -1
- package/lib/commands/kb/update.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/mutations.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/visibility-update.js +1 -1
- package/lib/commands/notification/config-create.js +1 -1
- package/lib/commands/notification/config-delete.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/config-update.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/create.js +1 -1
- package/lib/commands/page/custom/detail.js +1 -1
- package/lib/commands/page/custom/list.js +1 -1
- package/lib/commands/page/custom/publish.js +1 -1
- package/lib/commands/page/custom/shared.js +1 -1
- package/lib/commands/page/custom/syntax.js +1 -1
- package/lib/commands/page/custom/template.js +1 -1
- package/lib/commands/page/custom/update.js +1 -1
- package/lib/commands/page/data-list-status.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/materialize-project-template.js +1 -1
- package/lib/commands/project/create/project-name.js +1 -1
- package/lib/commands/project/create/project-template-archive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/role/user-resolve.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/sql/create.js +1 -1
- package/lib/commands/sql/delete.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/pull.js +1 -1
- package/lib/commands/sql/push.js +1 -1
- package/lib/commands/sql/shared.js +1 -1
- package/lib/commands/sql/status.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/commands/task/index.js +1 -1
- package/lib/commands/task/status.js +1 -1
- package/lib/commands/tenant/index.js +1 -1
- package/lib/commands/tenant/members-list.js +1 -1
- package/lib/commands/tenant/shared.js +1 -1
- package/lib/commands/user-account/dingding-sandbox-bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/add.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/paths.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/context/app-resolver.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.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/rules-cdn.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/rabetbase/SKILL.md +1 -1
- package/skills/rabetbase.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const a142_0x2a45bb=a142_0x4318;(function(_0x29543d,_0x5f3f22){const _0x2752e8=a142_0x4318,_0x50d9fc=_0x29543d();while(!![]){try{const _0x2de38a=parseInt(_0x2752e8(0x16a))/0x1+-parseInt(_0x2752e8(0x163))/0x2+parseInt(_0x2752e8(0x14f))/0x3*(-parseInt(_0x2752e8(0x18f))/0x4)+parseInt(_0x2752e8(0x1b9))/0x5*(parseInt(_0x2752e8(0x1a8))/0x6)+-parseInt(_0x2752e8(0x196))/0x7+-parseInt(_0x2752e8(0x1a7))/0x8+parseInt(_0x2752e8(0x1b1))/0x9;if(_0x2de38a===_0x5f3f22)break;else _0x50d9fc['push'](_0x50d9fc['shift']());}catch(_0x18eef9){_0x50d9fc['push'](_0x50d9fc['shift']());}}}(a142_0x47c9,0x41374));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=[a142_0x2a45bb(0x1ac),'FEISHU',a142_0x2a45bb(0x1ad),a142_0x2a45bb(0x192),a142_0x2a45bb(0x19c)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a142_0x2a45bb(0x199),a142_0x2a45bb(0x161),'endpointUrl',a142_0x2a45bb(0x171),a142_0x2a45bb(0x17f),a142_0x2a45bb(0x184),'readTimeout']),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a142_0x2a45bb(0x188),a142_0x2a45bb(0x159),'channelCode']),EMAIL_RECIPIENT_FIELDS=new Set(['emailTargets',a142_0x2a45bb(0x153),a142_0x2a45bb(0x174),a142_0x2a45bb(0x187),'replyTo','subjectPrefix',a142_0x2a45bb(0x157),'to','cc']);function a142_0x4318(_0x4d58d0,_0x4d65b5){_0x4d58d0=_0x4d58d0-0x142;const _0x47c9e0=a142_0x47c9();let _0x431822=_0x47c9e0[_0x4d58d0];return _0x431822;}export const NOTIFICATION_INPUT_FLAGS=[{'name':a142_0x2a45bb(0x193),'type':'string','required':![],'description':'Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file'},{'name':'stdin','type':a142_0x2a45bb(0x1b2),'required':![],'default':![],'description':a142_0x2a45bb(0x198)},{'name':a142_0x2a45bb(0x149),'type':a142_0x2a45bb(0x178),'required':![],'description':a142_0x2a45bb(0x1bf)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':'number','required':!![],'description':'Application-level\x20notification\x20config\x20ID'};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x1e4e8a,_0x3fbae2,_0x3058aa){return new CliError(_0x1e4e8a,0x1,_0x3fbae2,_0x3058aa);}export function readNotificationId(_0x12b1c0){const _0xc323f0=a142_0x2a45bb,_0x484949=_0x12b1c0['num']('id');if(!Number['isSafeInteger'](_0x484949)||_0x484949<=0x0)throw notificationError('notification_config_id_invalid',_0xc323f0(0x14b));return _0x484949;}export function requireNotificationExplicitYes(_0x2cc0a6){const _0x333352=a142_0x2a45bb;if(_0x2cc0a6['bool']('dry-run')||_0x2cc0a6[_0x333352(0x1b0)](_0x333352(0x152)))return;throw notificationError(_0x333352(0x15a),_0x333352(0x15e),_0x333352(0x1a5));}export function readNotificationChannelType(_0x578925,_0x5f437a=a142_0x2a45bb(0x15f),_0x555fa8=a142_0x2a45bb(0x1ac)){const _0x419e99=a142_0x2a45bb,_0x246d65=_0x578925[_0x419e99(0x156)](_0x5f437a)[_0x419e99(0x189)]()||_0x555fa8;if(!NOTIFICATION_CHANNEL_TYPES[_0x419e99(0x19d)](_0x246d65))throw CliErrors[_0x419e99(0x1a4)](_0x419e99(0x1ba)+_0x5f437a+':\x20'+_0x246d65,_0x419e99(0x164)+NOTIFICATION_CHANNEL_TYPES[_0x419e99(0x1a2)](',\x20')+'.');return _0x246d65;}export function assertSingleNotificationSource(_0x4b144e){const _0x59924c=a142_0x2a45bb,_0xad188d=[],_0x16b4bd=_0x4b144e[_0x59924c(0x156)](_0x59924c(0x193))[_0x59924c(0x189)]();if(_0x16b4bd)_0xad188d[_0x59924c(0x1af)]({'kind':_0x59924c(0x193),'path':_0x16b4bd});if(_0x4b144e[_0x59924c(0x1b0)](_0x59924c(0x172)))_0xad188d[_0x59924c(0x1af)]({'kind':_0x59924c(0x172)});const _0x27a80b=_0x4b144e[_0x59924c(0x156)]('from-env')[_0x59924c(0x189)]();if(_0x27a80b)_0xad188d['push']({'kind':_0x59924c(0x191),'name':_0x27a80b});if(_0xad188d[_0x59924c(0x197)]===0x0)throw CliErrors[_0x59924c(0x1a4)](_0x59924c(0x180),_0x59924c(0x19a));if(_0xad188d[_0x59924c(0x197)]>0x1)throw CliErrors[_0x59924c(0x1a4)]('Notification\x20JSON\x20source\x20is\x20ambiguous.',_0x59924c(0x19a));return _0xad188d[0x0];}export async function readNotificationDocument(_0x300340,_0x4098a0){const _0x5a2a95=a142_0x2a45bb,_0x504ce5=assertSingleNotificationSource(_0x300340),_0x29f0ed=_0x504ce5['kind']===_0x5a2a95(0x193)?_0x5a2a95(0x158)+_0x504ce5[_0x5a2a95(0x150)]:_0x504ce5[_0x5a2a95(0x16e)]===_0x5a2a95(0x191)?_0x5a2a95(0x185)+_0x504ce5['name']:_0x5a2a95(0x172);let _0x54812e;try{if(_0x504ce5[_0x5a2a95(0x16e)]==='file')_0x54812e=await readFile(_0x504ce5['path'],_0x5a2a95(0x17d));else{if(_0x504ce5[_0x5a2a95(0x16e)]==='env'){if(!(_0x504ce5[_0x5a2a95(0x1bd)]in process.env))throw notificationError(_0x5a2a95(0x179),_0x5a2a95(0x1c0)+_0x504ce5[_0x5a2a95(0x1bd)]);_0x54812e=process.env[_0x504ce5.name]??'';}else _0x54812e=await readStdin();}}catch(_0x4d15bc){if(_0x4d15bc instanceof CliError)throw _0x4d15bc;throw notificationError('notification_config_source_unavailable',_0x5a2a95(0x1b7)+_0x29f0ed+'.');}let _0x533213;try{_0x533213=JSON[_0x5a2a95(0x194)](_0x54812e);}catch{throw notificationError(_0x5a2a95(0x175),_0x5a2a95(0x1bb)+_0x29f0ed+'\x20is\x20invalid.',_0x5a2a95(0x19f));}if(!isJsonObject(_0x533213))throw notificationError(_0x5a2a95(0x175),_0x5a2a95(0x1bb)+_0x29f0ed+_0x5a2a95(0x168));return validateNotificationDocument(_0x533213,_0x4098a0);}function a142_0x47c9(){const _0x4c9fa9=['Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','call','\x20characters.','Notification\x20JSON\x20channelConfig\x20field\x20\x22','endpointUrlRaw','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','\x20has\x20an\x20invalid\x20id.','notification_config_response_invalid','\x20has\x20an\x20unsupported\x20channelType.','from-env','stringify','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','a\x20non-empty\x20string','some','a\x20string\x20or\x20null','132PMCBQO','path','Notification\x20config\x20','yes','recipients','channelConfigRaw','\x22\x20must\x20be\x20','str','fromName','file\x20','configCode','notification_config_confirmation_required','Item\x20','notification_config_channel_field_forbidden','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','type','readTimeout','channelType','create','968078jrSKZT','Allowed\x20values:\x20','\x22\x20must\x20be\x20a\x20non-empty\x20string.','notification_config_update_empty','\x20is\x20missing\x20required\x20field\x20\x22','\x20must\x20be\x20an\x20object.','messageTemplate','92532DUcAoB','Invalid\x20notification\x20config\x20response.','rabetbase\x20notification\x20config-list\x20--appcode\x20','keys','kind','object','\x20has\x20invalid\x20field\x20\x22','channelConfig','stdin','prototype','ccList','notification_config_json_invalid','\x20has\x20an\x20invalid\x20channelType.','Create\x20JSON\x20requires\x20field\x20','string','notification_config_source_unavailable','every','<redacted>','\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','utf8','number','description','Missing\x20notification\x20JSON\x20source.','_unavailable','endpointUrl:null','a\x20JSON\x20object\x20or\x20null','connectTimeout','environment\x20variable\x20','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','bccList','appCode','trim','isSafeInteger','Unknown\x20notification\x20JSON\x20field\x20\x22','Notification\x20JSON\x20field\x20\x22','update','Notification\x20config\x20list\x20item\x20','9032GdKXrJ','\x22channelType\x22.','env','WECOM','file','parse','hasOwnProperty','3366720jqgtyj','length','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','configName','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','notification_config_field_invalid','WEBHOOK','includes','isArray','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','endpointUrl','a\x20supported\x20string','join','notification_config_field_unknown','validation','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','createTime','1837976HCYoKp','12eAaoBg','notification_config_','failed','mutation','EMAIL','DINGTALK','notification_config_field_required','push','bool','10492794vFDuLu','boolean','preflight','apiError','\x20--type\x20','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','a\x20JSON\x20object','757060RIctej','Invalid\x20--','Notification\x20JSON\x20from\x20','\x22configName\x22.','name','\x22\x20cannot\x20exceed\x20'];a142_0x47c9=function(){return _0x4c9fa9;};return a142_0x47c9();}export function projectNotificationListConfig(_0x11e24f,_0x5d204d){const _0x151428=a142_0x2a45bb;return{'id':typeof _0x11e24f['id']===_0x151428(0x17e)?_0x11e24f['id']:null,'configCode':requireResponseString(_0x11e24f[_0x151428(0x159)],'configCode',_0x5d204d),'configName':requireResponseString(_0x11e24f[_0x151428(0x199)],_0x151428(0x199),_0x5d204d),'channelType':requireResponseString(_0x11e24f[_0x151428(0x161)],_0x151428(0x161),_0x5d204d),'description':normalizeNullableString(_0x11e24f[_0x151428(0x17f)]),'createTime':normalizeNullableString(_0x11e24f[_0x151428(0x1a6)]),'updateTime':normalizeNullableString(_0x11e24f['updateTime'])};}export function normalizeExactNotificationConfig(_0x371279,_0x166435,_0x184f00){const _0x170399=a142_0x2a45bb;if(!Number[_0x170399(0x18a)](_0x371279['id'])||_0x371279['id']!==_0x166435)throw notificationError(_0x170399(0x147),_0x170399(0x145)+_0x166435+'.');if(_0x371279[_0x170399(0x188)]!==_0x184f00)throw notificationError(_0x170399(0x147),_0x170399(0x151)+_0x166435+_0x170399(0x15d));const _0x16d82a=requireExactString(_0x371279[_0x170399(0x199)],_0x170399(0x199),_0x166435),_0x40870e=requireExactString(_0x371279[_0x170399(0x159)],'configCode',_0x166435),_0x154276=requireExactString(_0x371279[_0x170399(0x161)],_0x170399(0x161),_0x166435);if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x154276))throw notificationError(_0x170399(0x147),_0x170399(0x151)+_0x166435+_0x170399(0x148));const _0x278ad3=responseNullableString(_0x371279['endpointUrl'],_0x170399(0x1a0),_0x166435),_0x3bf805=responseNullableString(_0x371279[_0x170399(0x171)],'channelConfig',_0x166435),_0x409d02=responseNullableString(_0x371279[_0x170399(0x17f)],'description',_0x166435),_0x201e65=responseNullableTimeout(_0x371279['connectTimeout'],'connectTimeout',_0x166435),_0x586c1a=responseNullableTimeout(_0x371279[_0x170399(0x160)],'readTimeout',_0x166435);return{'id':_0x166435,'appCode':_0x184f00,'configCode':_0x40870e,'configName':_0x16d82a,'channelType':_0x154276,'endpointUrl':redactSensitive(_0x278ad3),'channelConfig':redactSensitive(_0x3bf805),'description':_0x409d02,'connectTimeout':_0x201e65,'readTimeout':_0x586c1a,'endpointUrlRaw':_0x278ad3,'channelConfigRaw':_0x3bf805};}export async function requireExactNotificationConfig(_0x422f45,_0x110608,_0xff7945){const _0x222f16=a142_0x2a45bb;let _0x18fa82;try{_0x18fa82=await getNotificationChannelConfig(_0x110608,_0x422f45);}catch{throw safeApiFailure(_0xff7945,_0x222f16(0x1b3),'Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20'+_0x422f45+'\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.');}return normalizeExactNotificationConfig(_0x18fa82,_0x110608,_0x422f45);}export function projectNotificationConfig(_0x59e08b){const _0x7f6629=a142_0x2a45bb;return{'id':_0x59e08b['id']??null,'appCode':_0x59e08b[_0x7f6629(0x188)],'configCode':_0x59e08b[_0x7f6629(0x159)]??null,'configName':_0x59e08b[_0x7f6629(0x199)],'channelType':_0x59e08b[_0x7f6629(0x161)],'endpointUrl':redactSensitive(_0x59e08b[_0x7f6629(0x1a0)]),'channelConfig':redactSensitive(_0x59e08b[_0x7f6629(0x171)]),'description':_0x59e08b[_0x7f6629(0x17f)]??null,'connectTimeout':_0x59e08b[_0x7f6629(0x184)]??null,'readTimeout':_0x59e08b[_0x7f6629(0x160)]??null};}export function notificationSelector(_0x551b32){const _0x3c87f9=a142_0x2a45bb;return{'appCode':_0x551b32[_0x3c87f9(0x188)],'id':_0x551b32['id'],'configCode':_0x551b32[_0x3c87f9(0x159)],'configName':_0x551b32[_0x3c87f9(0x199)],'channelType':_0x551b32[_0x3c87f9(0x161)]};}export function createMutationInput(_0x374943,_0x2dd863){const _0xd89e15=a142_0x2a45bb;return{'appCode':_0x374943,'configName':_0x2dd863[_0xd89e15(0x199)],'channelType':_0x2dd863[_0xd89e15(0x161)],...hasOwn(_0x2dd863,_0xd89e15(0x1a0))?{'endpointUrl':_0x2dd863['endpointUrl']}:{},...hasOwn(_0x2dd863,_0xd89e15(0x171))?{'channelConfig':serializeChannelConfig(_0x2dd863[_0xd89e15(0x171)])}:{},...hasOwn(_0x2dd863,'description')?{'description':_0x2dd863[_0xd89e15(0x17f)]}:{},...hasOwn(_0x2dd863,'connectTimeout')?{'connectTimeout':_0x2dd863[_0xd89e15(0x184)]}:{},...hasOwn(_0x2dd863,_0xd89e15(0x160))?{'readTimeout':_0x2dd863[_0xd89e15(0x160)]}:{}};}export function mergeUpdateInput(_0x1db9ef,_0x7bbb6){const _0x492716=a142_0x2a45bb;return{'id':_0x1db9ef['id'],'appCode':_0x1db9ef[_0x492716(0x188)],'configName':_0x7bbb6['configName']??_0x1db9ef['configName'],'channelType':_0x7bbb6['channelType']??_0x1db9ef['channelType'],'endpointUrl':hasOwn(_0x7bbb6,_0x492716(0x1a0))?_0x7bbb6[_0x492716(0x1a0)]:_0x1db9ef[_0x492716(0x144)],'channelConfig':hasOwn(_0x7bbb6,_0x492716(0x171))?serializeChannelConfig(_0x7bbb6[_0x492716(0x171)]):_0x1db9ef[_0x492716(0x154)],'description':hasOwn(_0x7bbb6,_0x492716(0x17f))?_0x7bbb6[_0x492716(0x17f)]:_0x1db9ef[_0x492716(0x17f)],'connectTimeout':hasOwn(_0x7bbb6,'connectTimeout')?_0x7bbb6[_0x492716(0x184)]:_0x1db9ef[_0x492716(0x184)],'readTimeout':hasOwn(_0x7bbb6,_0x492716(0x160))?_0x7bbb6['readTimeout']:_0x1db9ef[_0x492716(0x160)]};}export function plannedUpdateProjection(_0xb1faac,_0x598f34){const _0x3bdca8=a142_0x2a45bb;return projectNotificationConfig({'id':_0xb1faac['id'],'appCode':_0xb1faac['appCode'],'configCode':_0xb1faac['configCode'],'configName':_0x598f34[_0x3bdca8(0x199)]??_0xb1faac[_0x3bdca8(0x199)],'channelType':_0x598f34[_0x3bdca8(0x161)]??_0xb1faac[_0x3bdca8(0x161)],'endpointUrl':hasOwn(_0x598f34,'endpointUrl')?_0x598f34[_0x3bdca8(0x1a0)]:_0xb1faac[_0x3bdca8(0x144)],'channelConfig':hasOwn(_0x598f34,'channelConfig')?_0x598f34[_0x3bdca8(0x171)]:_0xb1faac[_0x3bdca8(0x154)],'description':hasOwn(_0x598f34,'description')?_0x598f34[_0x3bdca8(0x17f)]:_0xb1faac[_0x3bdca8(0x17f)],'connectTimeout':hasOwn(_0x598f34,'connectTimeout')?_0x598f34[_0x3bdca8(0x184)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0xb1faac[_0x3bdca8(0x184)],'readTimeout':hasOwn(_0x598f34,'readTimeout')?_0x598f34[_0x3bdca8(0x160)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0xb1faac[_0x3bdca8(0x160)]});}export function requestedSafeFieldsMatch(_0x1d7480,_0x3cfe98,_0x9f8d00){const _0x25c255=a142_0x2a45bb,_0x2e9784=[],_0x82fae2=[],_0xdd0af2=[];for(const _0x13c08b of[_0x25c255(0x199),_0x25c255(0x161),'description']){if(!hasOwn(_0x9f8d00,_0x13c08b))continue;_0xdd0af2[_0x25c255(0x1af)](_0x13c08b),_0x2e9784[_0x25c255(0x1af)](_0x3cfe98[_0x13c08b]===_0x9f8d00[_0x13c08b]),_0x82fae2[_0x25c255(0x1af)](_0x1d7480[_0x13c08b]!==_0x9f8d00[_0x13c08b]&&_0x3cfe98[_0x13c08b]===_0x9f8d00[_0x13c08b]);}for(const _0x1fe187 of[_0x25c255(0x184),_0x25c255(0x160)]){if(!hasOwn(_0x9f8d00,_0x1fe187))continue;const _0xc4689b=_0x9f8d00[_0x1fe187]??(_0x1fe187===_0x25c255(0x184)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0xdd0af2[_0x25c255(0x1af)](_0x1fe187),_0x2e9784[_0x25c255(0x1af)](_0x3cfe98[_0x1fe187]===_0xc4689b),_0x82fae2[_0x25c255(0x1af)](_0x1d7480[_0x1fe187]!==_0xc4689b&&_0x3cfe98[_0x1fe187]===_0xc4689b);}return hasOwn(_0x9f8d00,'endpointUrl')&&_0x9f8d00[_0x25c255(0x1a0)]===null&&(_0xdd0af2[_0x25c255(0x1af)](_0x25c255(0x182)),_0x2e9784[_0x25c255(0x1af)](_0x3cfe98[_0x25c255(0x144)]===null||_0x3cfe98[_0x25c255(0x144)]===''),_0x82fae2[_0x25c255(0x1af)](_0x1d7480['endpointUrlRaw']!==null&&_0x1d7480[_0x25c255(0x144)]!==''&&(_0x3cfe98['endpointUrlRaw']===null||_0x3cfe98[_0x25c255(0x144)]===''))),{'allMatch':_0x2e9784[_0x25c255(0x17a)](Boolean),'provesChange':_0x82fae2[_0x25c255(0x14d)](Boolean),'verifiedFields':_0xdd0af2};}export function validateNotificationDeleteReadback(_0x378093,_0x3d0861,_0x1e7e11){const _0x47d2ec=a142_0x2a45bb;for(const [_0x30cf18,_0x33a83e]of _0x378093['entries']()){if(!Number[_0x47d2ec(0x18a)](_0x33a83e['id'])||_0x33a83e['id']<=0x0)throw notificationError('notification_config_response_invalid',_0x47d2ec(0x18e)+(_0x30cf18+0x1)+_0x47d2ec(0x146));if(_0x33a83e['appCode']!==_0x3d0861)throw notificationError(_0x47d2ec(0x147),_0x47d2ec(0x18e)+(_0x30cf18+0x1)+'\x20has\x20an\x20invalid\x20appCode.');if(_0x33a83e[_0x47d2ec(0x161)]!==_0x1e7e11)throw notificationError(_0x47d2ec(0x147),_0x47d2ec(0x18e)+(_0x30cf18+0x1)+_0x47d2ec(0x176));}}export function safeApiFailure(_0x3ac3c1,_0x38ae9f,_0x22c241){const _0x16e4e4=a142_0x2a45bb;return notificationError(_0x16e4e4(0x1a9)+_0x3ac3c1+'_'+(_0x38ae9f===_0x16e4e4(0x1ab)?_0x16e4e4(0x1aa):_0x38ae9f+_0x16e4e4(0x181)),'Notification\x20config\x20'+_0x3ac3c1+'\x20'+_0x38ae9f+'\x20failed.',_0x22c241);}export function notificationLookupCommand(_0x4815e1,_0x1ca072){const _0x34a3f4=a142_0x2a45bb;return _0x34a3f4(0x16c)+_0x4815e1+_0x34a3f4(0x1b5)+_0x1ca072+'\x20--format\x20compress';}function validateNotificationDocument(_0x5a63a5,_0x55faff){const _0xb0517e=a142_0x2a45bb;for(const _0x4d2cf9 of Object['keys'](_0x5a63a5)){if(FORBIDDEN_IDENTITY_FIELDS['has'](_0x4d2cf9))throw notificationError('notification_config_field_forbidden',_0xb0517e(0x18c)+_0x4d2cf9+_0xb0517e(0x17c));if(!ALLOWED_INPUT_FIELDS['has'](_0x4d2cf9))throw notificationError(_0xb0517e(0x1a3),_0xb0517e(0x18b)+_0x4d2cf9+'\x22.');}if(_0x55faff===_0xb0517e(0x18d)&&Object[_0xb0517e(0x16d)](_0x5a63a5)[_0xb0517e(0x197)]===0x0)throw notificationError(_0xb0517e(0x166),_0xb0517e(0x186));const _0xc80ff2={};if(hasOwn(_0x5a63a5,_0xb0517e(0x199)))_0xc80ff2[_0xb0517e(0x199)]=validateRequiredString(_0x5a63a5[_0xb0517e(0x199)],_0xb0517e(0x199),0x80);else{if(_0x55faff===_0xb0517e(0x162))throw notificationError(_0xb0517e(0x1ae),_0xb0517e(0x177)+_0xb0517e(0x1bc));}if(hasOwn(_0x5a63a5,_0xb0517e(0x161))){if(typeof _0x5a63a5[_0xb0517e(0x161)]!==_0xb0517e(0x178))throw invalidFieldType('channelType',_0xb0517e(0x1a1));const _0x455efb=_0x5a63a5['channelType'][_0xb0517e(0x189)]();if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x455efb))throw notificationError(_0xb0517e(0x19b),'Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0xb0517e(0x1a2)](',\x20')+'.');_0xc80ff2['channelType']=_0x455efb;}else{if(_0x55faff===_0xb0517e(0x162))throw notificationError('notification_config_field_required',_0xb0517e(0x177)+_0xb0517e(0x190));}for(const [_0x192642,_0x18d451]of[[_0xb0517e(0x1a0),0x200],['description',0x100]]){if(!hasOwn(_0x5a63a5,_0x192642))continue;const _0x22f6e1=_0x5a63a5[_0x192642];if(_0x22f6e1!==null&&typeof _0x22f6e1!==_0xb0517e(0x178))throw invalidFieldType(_0x192642,_0xb0517e(0x14e));if(typeof _0x22f6e1===_0xb0517e(0x178)&&_0x22f6e1['length']>_0x18d451)throw notificationError(_0xb0517e(0x19b),'Notification\x20JSON\x20field\x20\x22'+_0x192642+_0xb0517e(0x1be)+_0x18d451+_0xb0517e(0x142));_0xc80ff2[_0x192642]=_0x22f6e1;}if(hasOwn(_0x5a63a5,_0xb0517e(0x171))){const _0x3b4edb=_0x5a63a5['channelConfig'];if(_0x3b4edb===null&&_0x55faff===_0xb0517e(0x162))throw invalidFieldType(_0xb0517e(0x171),_0xb0517e(0x1b8));if(_0x3b4edb!==null&&!isJsonObject(_0x3b4edb))throw invalidFieldType(_0xb0517e(0x171),_0x55faff===_0xb0517e(0x18d)?_0xb0517e(0x183):_0xb0517e(0x1b8));_0x3b4edb!==null&&validateChannelConfigFields(_0xc80ff2[_0xb0517e(0x161)],_0x3b4edb),_0xc80ff2['channelConfig']=_0x3b4edb;}for(const _0x5420ab of[_0xb0517e(0x184),_0xb0517e(0x160)]){if(!hasOwn(_0x5a63a5,_0x5420ab))continue;const _0x18299b=_0x5a63a5[_0x5420ab];if(_0x18299b!==null&&(!Number[_0xb0517e(0x18a)](_0x18299b)||_0x18299b<0x0))throw notificationError(_0xb0517e(0x19b),'Notification\x20JSON\x20field\x20\x22'+_0x5420ab+_0xb0517e(0x1b6));_0xc80ff2[_0x5420ab]=_0x18299b;}return _0xc80ff2;}function validateRequiredString(_0x57c773,_0x2f3498,_0x345e7a){const _0x9bb856=a142_0x2a45bb;if(typeof _0x57c773!=='string')throw invalidFieldType(_0x2f3498,_0x9bb856(0x14c));const _0x597182=_0x57c773['trim']();if(!_0x597182)throw notificationError(_0x9bb856(0x19b),'Notification\x20JSON\x20field\x20\x22'+_0x2f3498+_0x9bb856(0x165));if(_0x597182[_0x9bb856(0x197)]>_0x345e7a)throw notificationError(_0x9bb856(0x19b),_0x9bb856(0x18c)+_0x2f3498+'\x22\x20cannot\x20exceed\x20'+_0x345e7a+_0x9bb856(0x142));return _0x597182;}function validateChannelConfigFields(_0x34c8f0,_0x3d1af4){const _0x221730=a142_0x2a45bb;if(hasOwn(_0x3d1af4,_0x221730(0x169)))throw forbiddenChannelConfigField('messageTemplate');if(_0x34c8f0===_0x221730(0x1ac))for(const _0x532bbe of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x3d1af4,_0x532bbe))throw forbiddenChannelConfigField(_0x532bbe);}}function forbiddenChannelConfigField(_0x32d7ca){const _0x3fb9b0=a142_0x2a45bb;return notificationError(_0x3fb9b0(0x15c),_0x3fb9b0(0x143)+_0x32d7ca+'\x22\x20is\x20forbidden.');}function invalidFieldType(_0x4031ba,_0x223699){const _0x1ac056=a142_0x2a45bb;return notificationError(_0x1ac056(0x19b),_0x1ac056(0x18c)+_0x4031ba+_0x1ac056(0x155)+_0x223699+'.');}function serializeChannelConfig(_0x159974){const _0x3a55e1=a142_0x2a45bb;return _0x159974===null||_0x159974===undefined?null:JSON[_0x3a55e1(0x14a)](_0x159974);}function redactSensitive(_0xb26577){const _0x58b43f=a142_0x2a45bb;return _0xb26577===null||_0xb26577===undefined||_0xb26577===''?null:_0x58b43f(0x17b);}function requireResponseString(_0x9a808f,_0x484099,_0x48d354){const _0x2b7d34=a142_0x2a45bb;if(typeof _0x9a808f!==_0x2b7d34(0x178)||_0x9a808f['trim']()==='')throw CliErrors[_0x2b7d34(0x1b4)](_0x2b7d34(0x16b),_0x2b7d34(0x15b)+(_0x48d354+0x1)+_0x2b7d34(0x167)+_0x484099+'\x22.');return _0x9a808f['trim']();}function requireExactString(_0x77f8e1,_0x3bfc22,_0x3c714f){const _0x278bd5=a142_0x2a45bb;if(typeof _0x77f8e1!==_0x278bd5(0x178)||_0x77f8e1[_0x278bd5(0x189)]()==='')throw notificationError('notification_config_response_invalid',_0x278bd5(0x151)+_0x3c714f+'\x20is\x20missing\x20required\x20field\x20\x22'+_0x3bfc22+'\x22.');return _0x77f8e1[_0x278bd5(0x189)]();}function responseNullableString(_0xa0629f,_0x345a04,_0x979cf0){const _0xeae1e0=a142_0x2a45bb;if(_0xa0629f===undefined||_0xa0629f===null)return null;if(typeof _0xa0629f!==_0xeae1e0(0x178))throw notificationError(_0xeae1e0(0x147),'Notification\x20config\x20'+_0x979cf0+_0xeae1e0(0x170)+_0x345a04+'\x22.');return _0xa0629f;}function responseNullableTimeout(_0x782c72,_0x134eb2,_0x2fb82f){const _0x355fe1=a142_0x2a45bb;if(_0x782c72===undefined||_0x782c72===null)return null;if(!Number[_0x355fe1(0x18a)](_0x782c72)||_0x782c72<0x0)throw notificationError(_0x355fe1(0x147),'Notification\x20config\x20'+_0x2fb82f+_0x355fe1(0x170)+_0x134eb2+'\x22.');return _0x782c72;}function normalizeNullableString(_0x3abb52){const _0x3219c6=a142_0x2a45bb;return typeof _0x3abb52===_0x3219c6(0x178)?_0x3abb52:null;}function isJsonObject(_0x1a8de4){const _0x16eea7=a142_0x2a45bb;return _0x1a8de4!==null&&typeof _0x1a8de4===_0x16eea7(0x16f)&&!Array[_0x16eea7(0x19e)](_0x1a8de4);}function hasOwn(_0x57667d,_0x2dda96){const _0x31da1b=a142_0x2a45bb;return Object[_0x31da1b(0x173)][_0x31da1b(0x195)][_0x31da1b(0x1c1)](_0x57667d,_0x2dda96);}async function readStdin(){const _0x3a1d06=a142_0x2a45bb;let _0x296db0='';process['stdin']['setEncoding']('utf8');for await(const _0x78b06f of process[_0x3a1d06(0x172)])_0x296db0+=_0x78b06f;return _0x296db0;}
|
|
1
|
+
const a142_0x280aff=a142_0x4298;(function(_0x135906,_0x3dc624){const _0x117af1=a142_0x4298,_0x3c41ce=_0x135906();while(!![]){try{const _0x30bf70=parseInt(_0x117af1(0x199))/0x1+parseInt(_0x117af1(0x1f2))/0x2+parseInt(_0x117af1(0x1eb))/0x3*(-parseInt(_0x117af1(0x1f4))/0x4)+parseInt(_0x117af1(0x1d8))/0x5+-parseInt(_0x117af1(0x20c))/0x6*(-parseInt(_0x117af1(0x1b1))/0x7)+parseInt(_0x117af1(0x1a1))/0x8*(parseInt(_0x117af1(0x215))/0x9)+-parseInt(_0x117af1(0x1d4))/0xa;if(_0x30bf70===_0x3dc624)break;else _0x3c41ce['push'](_0x3c41ce['shift']());}catch(_0x8cd43f){_0x3c41ce['push'](_0x3c41ce['shift']());}}}(a142_0x3a8b,0xd9fd1));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=[a142_0x280aff(0x1e2),a142_0x280aff(0x20e),a142_0x280aff(0x1ab),'WECOM',a142_0x280aff(0x1d7)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a142_0x280aff(0x209),a142_0x280aff(0x1d6),a142_0x280aff(0x1a4),a142_0x280aff(0x1af),a142_0x280aff(0x1cf),a142_0x280aff(0x204),'readTimeout']),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a142_0x280aff(0x1f5),a142_0x280aff(0x1bc),a142_0x280aff(0x1ce)]),EMAIL_RECIPIENT_FIELDS=new Set([a142_0x280aff(0x1e5),a142_0x280aff(0x1dd),a142_0x280aff(0x1bb),a142_0x280aff(0x1b0),a142_0x280aff(0x1ca),'subjectPrefix',a142_0x280aff(0x1b9),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':a142_0x280aff(0x20b),'type':'string','required':![],'description':a142_0x280aff(0x19b)},{'name':a142_0x280aff(0x1ee),'type':a142_0x280aff(0x211),'required':![],'default':![],'description':a142_0x280aff(0x208)},{'name':a142_0x280aff(0x1d2),'type':'string','required':![],'description':'Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable'}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a142_0x280aff(0x1a6),'required':!![],'description':a142_0x280aff(0x19e)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x53ae8e,_0x217888,_0x485b6e){return new CliError(_0x53ae8e,0x1,_0x217888,_0x485b6e);}export function readNotificationId(_0x23aa76){const _0x19ba21=a142_0x280aff,_0x1a87c0=_0x23aa76['num']('id');if(!Number[_0x19ba21(0x216)](_0x1a87c0)||_0x1a87c0<=0x0)throw notificationError(_0x19ba21(0x1dc),_0x19ba21(0x1b3));return _0x1a87c0;}export function requireNotificationExplicitYes(_0x5ee9fc){const _0x5777d7=a142_0x280aff;if(_0x5ee9fc[_0x5777d7(0x1a7)](_0x5777d7(0x19c))||_0x5ee9fc[_0x5777d7(0x1a7)](_0x5777d7(0x200)))return;throw notificationError(_0x5777d7(0x21a),_0x5777d7(0x1be),'Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.');}export function readNotificationChannelType(_0x5d11ea,_0x32227f=a142_0x280aff(0x1c3),_0x33b420=a142_0x280aff(0x1e2)){const _0x1e482e=a142_0x280aff,_0x7617fd=_0x5d11ea[_0x1e482e(0x1b8)](_0x32227f)[_0x1e482e(0x1cb)]()||_0x33b420;if(!NOTIFICATION_CHANNEL_TYPES[_0x1e482e(0x1b7)](_0x7617fd))throw CliErrors[_0x1e482e(0x218)](_0x1e482e(0x1cd)+_0x32227f+':\x20'+_0x7617fd,'Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0x1e482e(0x1ea)](',\x20')+'.');return _0x7617fd;}export function assertSingleNotificationSource(_0xe3d0d3){const _0x1f16c7=a142_0x280aff,_0x44e20e=[],_0x883250=_0xe3d0d3[_0x1f16c7(0x1b8)](_0x1f16c7(0x20b))[_0x1f16c7(0x1cb)]();if(_0x883250)_0x44e20e[_0x1f16c7(0x1db)]({'kind':'file','path':_0x883250});if(_0xe3d0d3[_0x1f16c7(0x1a7)](_0x1f16c7(0x1ee)))_0x44e20e[_0x1f16c7(0x1db)]({'kind':'stdin'});const _0x5eef20=_0xe3d0d3[_0x1f16c7(0x1b8)](_0x1f16c7(0x1d2))[_0x1f16c7(0x1cb)]();if(_0x5eef20)_0x44e20e[_0x1f16c7(0x1db)]({'kind':_0x1f16c7(0x1bf),'name':_0x5eef20});if(_0x44e20e[_0x1f16c7(0x1f9)]===0x0)throw CliErrors[_0x1f16c7(0x218)](_0x1f16c7(0x1fb),'Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.');if(_0x44e20e['length']>0x1)throw CliErrors[_0x1f16c7(0x218)](_0x1f16c7(0x1b5),_0x1f16c7(0x1e1));return _0x44e20e[0x0];}export async function readNotificationDocument(_0x582ce0,_0x512de9){const _0x463846=a142_0x280aff,_0xf5cf92=assertSingleNotificationSource(_0x582ce0),_0x19c6a6=_0xf5cf92[_0x463846(0x1e4)]===_0x463846(0x20b)?_0x463846(0x1cc)+_0xf5cf92[_0x463846(0x1d3)]:_0xf5cf92[_0x463846(0x1e4)]==='env'?'environment\x20variable\x20'+_0xf5cf92['name']:_0x463846(0x1ee);let _0x476b85;try{if(_0xf5cf92['kind']==='file')_0x476b85=await readFile(_0xf5cf92[_0x463846(0x1d3)],_0x463846(0x1c6));else{if(_0xf5cf92['kind']==='env'){if(!(_0xf5cf92[_0x463846(0x1f7)]in process.env))throw notificationError(_0x463846(0x1b6),_0x463846(0x20a)+_0xf5cf92['name']);_0x476b85=process.env[_0xf5cf92.name]??'';}else _0x476b85=await readStdin();}}catch(_0x54a902){if(_0x54a902 instanceof CliError)throw _0x54a902;throw notificationError(_0x463846(0x1b6),_0x463846(0x1fd)+_0x19c6a6+'.');}let _0x30d759;try{_0x30d759=JSON[_0x463846(0x21b)](_0x476b85);}catch{throw notificationError('notification_config_json_invalid',_0x463846(0x198)+_0x19c6a6+'\x20is\x20invalid.','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.');}if(!isJsonObject(_0x30d759))throw notificationError('notification_config_json_invalid',_0x463846(0x198)+_0x19c6a6+'\x20must\x20be\x20an\x20object.');return validateNotificationDocument(_0x30d759,_0x512de9);}export function projectNotificationListConfig(_0x3c8694,_0x1875a1){const _0x2fc144=a142_0x280aff;return{'id':typeof _0x3c8694['id']==='number'?_0x3c8694['id']:null,'configCode':requireResponseString(_0x3c8694['configCode'],_0x2fc144(0x1bc),_0x1875a1),'configName':requireResponseString(_0x3c8694['configName'],_0x2fc144(0x209),_0x1875a1),'channelType':requireResponseString(_0x3c8694[_0x2fc144(0x1d6)],'channelType',_0x1875a1),'description':normalizeNullableString(_0x3c8694[_0x2fc144(0x1cf)]),'createTime':normalizeNullableString(_0x3c8694[_0x2fc144(0x1d1)]),'updateTime':normalizeNullableString(_0x3c8694['updateTime'])};}export function normalizeExactNotificationConfig(_0x4d38ce,_0x123dca,_0x9cbff8){const _0x172983=a142_0x280aff;if(!Number['isSafeInteger'](_0x4d38ce['id'])||_0x4d38ce['id']!==_0x123dca)throw notificationError(_0x172983(0x213),_0x172983(0x1d5)+_0x123dca+'.');if(_0x4d38ce[_0x172983(0x1f5)]!==_0x9cbff8)throw notificationError(_0x172983(0x213),_0x172983(0x19a)+_0x123dca+_0x172983(0x210));const _0x422d84=requireExactString(_0x4d38ce[_0x172983(0x209)],'configName',_0x123dca),_0x3b1cae=requireExactString(_0x4d38ce[_0x172983(0x1bc)],_0x172983(0x1bc),_0x123dca),_0x5167ae=requireExactString(_0x4d38ce[_0x172983(0x1d6)],_0x172983(0x1d6),_0x123dca);if(!NOTIFICATION_CHANNEL_TYPES[_0x172983(0x1b7)](_0x5167ae))throw notificationError(_0x172983(0x213),'Notification\x20config\x20'+_0x123dca+_0x172983(0x1c9));const _0x16b04e=responseNullableString(_0x4d38ce[_0x172983(0x1a4)],_0x172983(0x1a4),_0x123dca),_0xd13e3a=responseNullableString(_0x4d38ce['channelConfig'],_0x172983(0x1af),_0x123dca),_0x5cc19b=responseNullableString(_0x4d38ce['description'],_0x172983(0x1cf),_0x123dca),_0x172b0c=responseNullableTimeout(_0x4d38ce[_0x172983(0x204)],_0x172983(0x204),_0x123dca),_0x4944ad=responseNullableTimeout(_0x4d38ce[_0x172983(0x1a5)],_0x172983(0x1a5),_0x123dca);return{'id':_0x123dca,'appCode':_0x9cbff8,'configCode':_0x3b1cae,'configName':_0x422d84,'channelType':_0x5167ae,'endpointUrl':redactSensitive(_0x16b04e),'channelConfig':redactSensitive(_0xd13e3a),'description':_0x5cc19b,'connectTimeout':_0x172b0c,'readTimeout':_0x4944ad,'endpointUrlRaw':_0x16b04e,'channelConfigRaw':_0xd13e3a};}export async function requireExactNotificationConfig(_0x511788,_0x260920,_0x8b81c5){const _0x2acf83=a142_0x280aff;let _0xa8efa6;try{_0xa8efa6=await getNotificationChannelConfig(_0x260920,_0x511788);}catch{throw safeApiFailure(_0x8b81c5,_0x2acf83(0x202),_0x2acf83(0x19f)+_0x511788+_0x2acf83(0x1f0));}return normalizeExactNotificationConfig(_0xa8efa6,_0x260920,_0x511788);}export function projectNotificationConfig(_0x127556){const _0x3364f3=a142_0x280aff;return{'id':_0x127556['id']??null,'appCode':_0x127556[_0x3364f3(0x1f5)],'configCode':_0x127556[_0x3364f3(0x1bc)]??null,'configName':_0x127556['configName'],'channelType':_0x127556[_0x3364f3(0x1d6)],'endpointUrl':redactSensitive(_0x127556['endpointUrl']),'channelConfig':redactSensitive(_0x127556[_0x3364f3(0x1af)]),'description':_0x127556[_0x3364f3(0x1cf)]??null,'connectTimeout':_0x127556[_0x3364f3(0x204)]??null,'readTimeout':_0x127556[_0x3364f3(0x1a5)]??null};}export function notificationSelector(_0x4da872){const _0x529982=a142_0x280aff;return{'appCode':_0x4da872[_0x529982(0x1f5)],'id':_0x4da872['id'],'configCode':_0x4da872['configCode'],'configName':_0x4da872[_0x529982(0x209)],'channelType':_0x4da872[_0x529982(0x1d6)]};}export function createMutationInput(_0x3bc1d3,_0x4a0b39){const _0x392b47=a142_0x280aff;return{'appCode':_0x3bc1d3,'configName':_0x4a0b39[_0x392b47(0x209)],'channelType':_0x4a0b39['channelType'],...hasOwn(_0x4a0b39,_0x392b47(0x1a4))?{'endpointUrl':_0x4a0b39[_0x392b47(0x1a4)]}:{},...hasOwn(_0x4a0b39,'channelConfig')?{'channelConfig':serializeChannelConfig(_0x4a0b39[_0x392b47(0x1af)])}:{},...hasOwn(_0x4a0b39,'description')?{'description':_0x4a0b39[_0x392b47(0x1cf)]}:{},...hasOwn(_0x4a0b39,_0x392b47(0x204))?{'connectTimeout':_0x4a0b39[_0x392b47(0x204)]}:{},...hasOwn(_0x4a0b39,_0x392b47(0x1a5))?{'readTimeout':_0x4a0b39[_0x392b47(0x1a5)]}:{}};}export function mergeUpdateInput(_0x165574,_0x5905c9){const _0x3f47d1=a142_0x280aff;return{'id':_0x165574['id'],'appCode':_0x165574[_0x3f47d1(0x1f5)],'configName':_0x5905c9[_0x3f47d1(0x209)]??_0x165574[_0x3f47d1(0x209)],'channelType':_0x5905c9[_0x3f47d1(0x1d6)]??_0x165574[_0x3f47d1(0x1d6)],'endpointUrl':hasOwn(_0x5905c9,'endpointUrl')?_0x5905c9['endpointUrl']:_0x165574[_0x3f47d1(0x1df)],'channelConfig':hasOwn(_0x5905c9,'channelConfig')?serializeChannelConfig(_0x5905c9[_0x3f47d1(0x1af)]):_0x165574['channelConfigRaw'],'description':hasOwn(_0x5905c9,'description')?_0x5905c9['description']:_0x165574[_0x3f47d1(0x1cf)],'connectTimeout':hasOwn(_0x5905c9,'connectTimeout')?_0x5905c9[_0x3f47d1(0x204)]:_0x165574[_0x3f47d1(0x204)],'readTimeout':hasOwn(_0x5905c9,'readTimeout')?_0x5905c9[_0x3f47d1(0x1a5)]:_0x165574[_0x3f47d1(0x1a5)]};}export function plannedUpdateProjection(_0x25d8e3,_0x1ba915){const _0x157b4b=a142_0x280aff;return projectNotificationConfig({'id':_0x25d8e3['id'],'appCode':_0x25d8e3[_0x157b4b(0x1f5)],'configCode':_0x25d8e3[_0x157b4b(0x1bc)],'configName':_0x1ba915[_0x157b4b(0x209)]??_0x25d8e3[_0x157b4b(0x209)],'channelType':_0x1ba915['channelType']??_0x25d8e3['channelType'],'endpointUrl':hasOwn(_0x1ba915,_0x157b4b(0x1a4))?_0x1ba915[_0x157b4b(0x1a4)]:_0x25d8e3[_0x157b4b(0x1df)],'channelConfig':hasOwn(_0x1ba915,_0x157b4b(0x1af))?_0x1ba915['channelConfig']:_0x25d8e3[_0x157b4b(0x1b4)],'description':hasOwn(_0x1ba915,_0x157b4b(0x1cf))?_0x1ba915[_0x157b4b(0x1cf)]:_0x25d8e3[_0x157b4b(0x1cf)],'connectTimeout':hasOwn(_0x1ba915,_0x157b4b(0x204))?_0x1ba915['connectTimeout']??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x25d8e3['connectTimeout'],'readTimeout':hasOwn(_0x1ba915,_0x157b4b(0x1a5))?_0x1ba915['readTimeout']??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x25d8e3[_0x157b4b(0x1a5)]});}export function requestedSafeFieldsMatch(_0x4ca2da,_0x1ffbd8,_0x331016){const _0x3c291f=a142_0x280aff,_0x23203e=[],_0x974a09=[],_0x4bd13d=[];for(const _0x113e44 of[_0x3c291f(0x209),'channelType','description']){if(!hasOwn(_0x331016,_0x113e44))continue;_0x4bd13d[_0x3c291f(0x1db)](_0x113e44),_0x23203e['push'](_0x1ffbd8[_0x113e44]===_0x331016[_0x113e44]),_0x974a09[_0x3c291f(0x1db)](_0x4ca2da[_0x113e44]!==_0x331016[_0x113e44]&&_0x1ffbd8[_0x113e44]===_0x331016[_0x113e44]);}for(const _0x215807 of[_0x3c291f(0x204),'readTimeout']){if(!hasOwn(_0x331016,_0x215807))continue;const _0x1babf6=_0x331016[_0x215807]??(_0x215807===_0x3c291f(0x204)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x4bd13d['push'](_0x215807),_0x23203e[_0x3c291f(0x1db)](_0x1ffbd8[_0x215807]===_0x1babf6),_0x974a09[_0x3c291f(0x1db)](_0x4ca2da[_0x215807]!==_0x1babf6&&_0x1ffbd8[_0x215807]===_0x1babf6);}return hasOwn(_0x331016,_0x3c291f(0x1a4))&&_0x331016[_0x3c291f(0x1a4)]===null&&(_0x4bd13d[_0x3c291f(0x1db)]('endpointUrl:null'),_0x23203e[_0x3c291f(0x1db)](_0x1ffbd8['endpointUrlRaw']===null||_0x1ffbd8[_0x3c291f(0x1df)]===''),_0x974a09[_0x3c291f(0x1db)](_0x4ca2da[_0x3c291f(0x1df)]!==null&&_0x4ca2da[_0x3c291f(0x1df)]!==''&&(_0x1ffbd8[_0x3c291f(0x1df)]===null||_0x1ffbd8[_0x3c291f(0x1df)]===''))),{'allMatch':_0x23203e[_0x3c291f(0x1c5)](Boolean),'provesChange':_0x974a09[_0x3c291f(0x1fc)](Boolean),'verifiedFields':_0x4bd13d};}export function validateNotificationDeleteReadback(_0x4931ce,_0x467d7c,_0x466adf){const _0x197509=a142_0x280aff;for(const [_0x56ba74,_0x270729]of _0x4931ce[_0x197509(0x1c2)]()){if(!Number[_0x197509(0x216)](_0x270729['id'])||_0x270729['id']<=0x0)throw notificationError(_0x197509(0x213),_0x197509(0x1ec)+(_0x56ba74+0x1)+_0x197509(0x1e9));if(_0x270729[_0x197509(0x1f5)]!==_0x467d7c)throw notificationError(_0x197509(0x213),_0x197509(0x1ec)+(_0x56ba74+0x1)+_0x197509(0x1a3));if(_0x270729[_0x197509(0x1d6)]!==_0x466adf)throw notificationError(_0x197509(0x213),_0x197509(0x1ec)+(_0x56ba74+0x1)+_0x197509(0x1c0));}}export function safeApiFailure(_0x3456cf,_0x342c9d,_0x1488b1){const _0xeedf2=a142_0x280aff;return notificationError(_0xeedf2(0x207)+_0x3456cf+'_'+(_0x342c9d===_0xeedf2(0x1e3)?'failed':_0x342c9d+'_unavailable'),_0xeedf2(0x19a)+_0x3456cf+'\x20'+_0x342c9d+_0xeedf2(0x1ba),_0x1488b1);}function a142_0x3a8b(){const _0xdcec66=['\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','every','utf8','\x22\x20cannot\x20exceed\x20','call','\x20has\x20an\x20unsupported\x20channelType.','replyTo','trim','file\x20','Invalid\x20--','channelCode','description','stringify','createTime','from-env','path','16713180ZvEAMI','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','channelType','WEBHOOK','4125095oEXYPn','hasOwnProperty','a\x20string\x20or\x20null','push','notification_config_id_invalid','recipients','notification_config_field_unknown','endpointUrlRaw','Notification\x20JSON\x20field\x20\x22','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','EMAIL','mutation','kind','emailTargets','string','notification_config_field_forbidden','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','\x20has\x20an\x20invalid\x20id.','join','1971489OpzcUq','Notification\x20config\x20list\x20item\x20','messageTemplate','stdin','\x20is\x20missing\x20required\x20field\x20\x22','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','a\x20supported\x20string','3157260LCOXqt','notification_config_update_empty','4lbSjgn','appCode','\x20characters.','name','Notification\x20JSON\x20channelConfig\x20field\x20\x22','length','a\x20JSON\x20object','Missing\x20notification\x20JSON\x20source.','some','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','has','Invalid\x20notification\x20config\x20response.','yes','object','preflight','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','connectTimeout','notification_config_channel_field_forbidden','\x22configName\x22.','notification_config_','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','configName','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','file','3472758BTWqQB','update','FEISHU','isArray','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','boolean','\x20has\x20invalid\x20field\x20\x22','notification_config_response_invalid','keys','99aZkYSk','isSafeInteger','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','validation','notification_config_field_required','notification_config_confirmation_required','parse','Notification\x20JSON\x20from\x20','86196kaNAWG','Notification\x20config\x20','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','dry-run','apiError','Application-level\x20notification\x20config\x20ID','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','a\x20non-empty\x20string','111072PEeSFK','<redacted>','\x20has\x20an\x20invalid\x20appCode.','endpointUrl','readTimeout','number','bool','rabetbase\x20notification\x20config-list\x20--appcode\x20','notification_config_field_invalid','\x20--format\x20compress','DINGTALK','\x22\x20is\x20forbidden.','create','Unknown\x20notification\x20JSON\x20field\x20\x22','channelConfig','bccList','7RbHrVo','Allowed\x20values:\x20','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','channelConfigRaw','Notification\x20JSON\x20source\x20is\x20ambiguous.','notification_config_source_unavailable','includes','str','fromName','\x20failed.','ccList','configCode','Create\x20JSON\x20requires\x20field\x20','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','env','\x20has\x20an\x20invalid\x20channelType.','\x22\x20must\x20be\x20a\x20non-empty\x20string.','entries','type'];a142_0x3a8b=function(){return _0xdcec66;};return a142_0x3a8b();}export function notificationLookupCommand(_0x23a016,_0x4d8e6f){const _0x408472=a142_0x280aff;return _0x408472(0x1a8)+_0x23a016+'\x20--type\x20'+_0x4d8e6f+_0x408472(0x1aa);}function validateNotificationDocument(_0x2aee17,_0x5f42c9){const _0x5bf2f4=a142_0x280aff;for(const _0x7750b2 of Object[_0x5bf2f4(0x214)](_0x2aee17)){if(FORBIDDEN_IDENTITY_FIELDS[_0x5bf2f4(0x1fe)](_0x7750b2))throw notificationError(_0x5bf2f4(0x1e7),_0x5bf2f4(0x1e0)+_0x7750b2+_0x5bf2f4(0x1c4));if(!ALLOWED_INPUT_FIELDS[_0x5bf2f4(0x1fe)](_0x7750b2))throw notificationError(_0x5bf2f4(0x1de),_0x5bf2f4(0x1ae)+_0x7750b2+'\x22.');}if(_0x5f42c9===_0x5bf2f4(0x20d)&&Object[_0x5bf2f4(0x214)](_0x2aee17)[_0x5bf2f4(0x1f9)]===0x0)throw notificationError(_0x5bf2f4(0x1f3),_0x5bf2f4(0x203));const _0x117e30={};if(hasOwn(_0x2aee17,_0x5bf2f4(0x209)))_0x117e30[_0x5bf2f4(0x209)]=validateRequiredString(_0x2aee17[_0x5bf2f4(0x209)],_0x5bf2f4(0x209),0x80);else{if(_0x5f42c9===_0x5bf2f4(0x1ad))throw notificationError(_0x5bf2f4(0x219),_0x5bf2f4(0x1bd)+_0x5bf2f4(0x206));}if(hasOwn(_0x2aee17,'channelType')){if(typeof _0x2aee17[_0x5bf2f4(0x1d6)]!==_0x5bf2f4(0x1e6))throw invalidFieldType(_0x5bf2f4(0x1d6),_0x5bf2f4(0x1f1));const _0x38a2d3=_0x2aee17[_0x5bf2f4(0x1d6)][_0x5bf2f4(0x1cb)]();if(!NOTIFICATION_CHANNEL_TYPES[_0x5bf2f4(0x1b7)](_0x38a2d3))throw notificationError('notification_config_field_invalid',_0x5bf2f4(0x1e8),_0x5bf2f4(0x1b2)+NOTIFICATION_CHANNEL_TYPES[_0x5bf2f4(0x1ea)](',\x20')+'.');_0x117e30[_0x5bf2f4(0x1d6)]=_0x38a2d3;}else{if(_0x5f42c9===_0x5bf2f4(0x1ad))throw notificationError('notification_config_field_required',_0x5bf2f4(0x1bd)+'\x22channelType\x22.');}for(const [_0x2fe74b,_0x2d8f13]of[['endpointUrl',0x200],[_0x5bf2f4(0x1cf),0x100]]){if(!hasOwn(_0x2aee17,_0x2fe74b))continue;const _0x5beabf=_0x2aee17[_0x2fe74b];if(_0x5beabf!==null&&typeof _0x5beabf!==_0x5bf2f4(0x1e6))throw invalidFieldType(_0x2fe74b,_0x5bf2f4(0x1da));if(typeof _0x5beabf===_0x5bf2f4(0x1e6)&&_0x5beabf['length']>_0x2d8f13)throw notificationError('notification_config_field_invalid',_0x5bf2f4(0x1e0)+_0x2fe74b+_0x5bf2f4(0x1c7)+_0x2d8f13+_0x5bf2f4(0x1f6));_0x117e30[_0x2fe74b]=_0x5beabf;}if(hasOwn(_0x2aee17,'channelConfig')){const _0x322741=_0x2aee17[_0x5bf2f4(0x1af)];if(_0x322741===null&&_0x5f42c9==='create')throw invalidFieldType(_0x5bf2f4(0x1af),_0x5bf2f4(0x1fa));if(_0x322741!==null&&!isJsonObject(_0x322741))throw invalidFieldType(_0x5bf2f4(0x1af),_0x5f42c9===_0x5bf2f4(0x20d)?'a\x20JSON\x20object\x20or\x20null':_0x5bf2f4(0x1fa));_0x322741!==null&&validateChannelConfigFields(_0x117e30[_0x5bf2f4(0x1d6)],_0x322741),_0x117e30[_0x5bf2f4(0x1af)]=_0x322741;}for(const _0x265755 of['connectTimeout',_0x5bf2f4(0x1a5)]){if(!hasOwn(_0x2aee17,_0x265755))continue;const _0x88d266=_0x2aee17[_0x265755];if(_0x88d266!==null&&(!Number[_0x5bf2f4(0x216)](_0x88d266)||_0x88d266<0x0))throw notificationError(_0x5bf2f4(0x1a9),_0x5bf2f4(0x1e0)+_0x265755+_0x5bf2f4(0x217));_0x117e30[_0x265755]=_0x88d266;}return _0x117e30;}function validateRequiredString(_0x295fe5,_0x28530e,_0x5e6fde){const _0x2c08c7=a142_0x280aff;if(typeof _0x295fe5!==_0x2c08c7(0x1e6))throw invalidFieldType(_0x28530e,_0x2c08c7(0x1a0));const _0x17446d=_0x295fe5[_0x2c08c7(0x1cb)]();if(!_0x17446d)throw notificationError(_0x2c08c7(0x1a9),'Notification\x20JSON\x20field\x20\x22'+_0x28530e+_0x2c08c7(0x1c1));if(_0x17446d[_0x2c08c7(0x1f9)]>_0x5e6fde)throw notificationError(_0x2c08c7(0x1a9),_0x2c08c7(0x1e0)+_0x28530e+_0x2c08c7(0x1c7)+_0x5e6fde+_0x2c08c7(0x1f6));return _0x17446d;}function a142_0x4298(_0x2e0838,_0x5a546a){_0x2e0838=_0x2e0838-0x198;const _0x3a8b53=a142_0x3a8b();let _0x4298c3=_0x3a8b53[_0x2e0838];return _0x4298c3;}function validateChannelConfigFields(_0x47a284,_0x5f211f){const _0x378014=a142_0x280aff;if(hasOwn(_0x5f211f,_0x378014(0x1ed)))throw forbiddenChannelConfigField('messageTemplate');if(_0x47a284==='EMAIL')for(const _0x4195a9 of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x5f211f,_0x4195a9))throw forbiddenChannelConfigField(_0x4195a9);}}function forbiddenChannelConfigField(_0x38731d){const _0x26a0e3=a142_0x280aff;return notificationError(_0x26a0e3(0x205),_0x26a0e3(0x1f8)+_0x38731d+_0x26a0e3(0x1ac));}function invalidFieldType(_0x17ee1b,_0xd9ecc){return notificationError('notification_config_field_invalid','Notification\x20JSON\x20field\x20\x22'+_0x17ee1b+'\x22\x20must\x20be\x20'+_0xd9ecc+'.');}function serializeChannelConfig(_0x13221b){const _0x362c39=a142_0x280aff;return _0x13221b===null||_0x13221b===undefined?null:JSON[_0x362c39(0x1d0)](_0x13221b);}function redactSensitive(_0xb8ca96){const _0xda2b1b=a142_0x280aff;return _0xb8ca96===null||_0xb8ca96===undefined||_0xb8ca96===''?null:_0xda2b1b(0x1a2);}function requireResponseString(_0x5e684a,_0x4d873d,_0x4cbf6b){const _0x82e5c8=a142_0x280aff;if(typeof _0x5e684a!=='string'||_0x5e684a['trim']()==='')throw CliErrors[_0x82e5c8(0x19d)](_0x82e5c8(0x1ff),'Item\x20'+(_0x4cbf6b+0x1)+_0x82e5c8(0x1ef)+_0x4d873d+'\x22.');return _0x5e684a[_0x82e5c8(0x1cb)]();}function requireExactString(_0x783fe7,_0x46e5c7,_0x1c3b01){const _0x3cff95=a142_0x280aff;if(typeof _0x783fe7!==_0x3cff95(0x1e6)||_0x783fe7[_0x3cff95(0x1cb)]()==='')throw notificationError(_0x3cff95(0x213),'Notification\x20config\x20'+_0x1c3b01+_0x3cff95(0x1ef)+_0x46e5c7+'\x22.');return _0x783fe7['trim']();}function responseNullableString(_0x1470c0,_0x403f01,_0x2758bf){const _0x1d1f59=a142_0x280aff;if(_0x1470c0===undefined||_0x1470c0===null)return null;if(typeof _0x1470c0!==_0x1d1f59(0x1e6))throw notificationError(_0x1d1f59(0x213),'Notification\x20config\x20'+_0x2758bf+'\x20has\x20invalid\x20field\x20\x22'+_0x403f01+'\x22.');return _0x1470c0;}function responseNullableTimeout(_0x10273b,_0x12f774,_0x3ba043){const _0x2c5525=a142_0x280aff;if(_0x10273b===undefined||_0x10273b===null)return null;if(!Number[_0x2c5525(0x216)](_0x10273b)||_0x10273b<0x0)throw notificationError(_0x2c5525(0x213),_0x2c5525(0x19a)+_0x3ba043+_0x2c5525(0x212)+_0x12f774+'\x22.');return _0x10273b;}function normalizeNullableString(_0x102d1b){const _0x1c3a04=a142_0x280aff;return typeof _0x102d1b===_0x1c3a04(0x1e6)?_0x102d1b:null;}function isJsonObject(_0x20816c){const _0x11b343=a142_0x280aff;return _0x20816c!==null&&typeof _0x20816c===_0x11b343(0x201)&&!Array[_0x11b343(0x20f)](_0x20816c);}function hasOwn(_0x3a8fa7,_0x413450){const _0x4657b=a142_0x280aff;return Object['prototype'][_0x4657b(0x1d9)][_0x4657b(0x1c8)](_0x3a8fa7,_0x413450);}async function readStdin(){const _0x318ea2=a142_0x280aff;let _0x2a7aca='';process[_0x318ea2(0x1ee)]['setEncoding'](_0x318ea2(0x1c6));for await(const _0x108bcb of process[_0x318ea2(0x1ee)])_0x2a7aca+=_0x108bcb;return _0x2a7aca;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a143_0x2619b5=a143_0x27ce;(function(_0x2de1b1,_0x53df2c){const _0x46b344=a143_0x27ce,_0x1592c8=_0x2de1b1();while(!![]){try{const _0x6f06d9=parseInt(_0x46b344(0x1b6))/0x1*(parseInt(_0x46b344(0x1ae))/0x2)+parseInt(_0x46b344(0x1b1))/0x3*(-parseInt(_0x46b344(0x1ad))/0x4)+parseInt(_0x46b344(0x1b0))/0x5+parseInt(_0x46b344(0x18e))/0x6+-parseInt(_0x46b344(0x1bb))/0x7*(-parseInt(_0x46b344(0x198))/0x8)+-parseInt(_0x46b344(0x19f))/0x9+-parseInt(_0x46b344(0x1a2))/0xa;if(_0x6f06d9===_0x53df2c)break;else _0x1592c8['push'](_0x1592c8['shift']());}catch(_0x45ce70){_0x1592c8['push'](_0x1592c8['shift']());}}}(a143_0x4410,0x8a7b4));function a143_0x27ce(_0x2c3ff0,_0x41aaac){_0x2c3ff0=_0x2c3ff0-0x18d;const _0x441042=a143_0x4410();let _0x27ce11=_0x441042[_0x2c3ff0];return _0x27ce11;}import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';import{queryDevelopmentFileUrl,recognizeDevelopmentOcr,uploadDevelopmentFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const SUPPORTED_SCENES=[a143_0x2619b5(0x1af),a143_0x2619b5(0x1bf),'form',a143_0x2619b5(0x1a0)],SCENE_TO_LEGACY_TYPE={'invoice':a143_0x2619b5(0x1c5),'general':a143_0x2619b5(0x1a8),'form':a143_0x2619b5(0x19d),'idCard':a143_0x2619b5(0x1a5)},SCENE_FLAG={'name':a143_0x2619b5(0x1c2),'type':a143_0x2619b5(0x1b8),'required':!![],'enum':[...SUPPORTED_SCENES],'description':a143_0x2619b5(0x1b4)},IMAGE_FILE_FLAG={'name':a143_0x2619b5(0x197),'type':a143_0x2619b5(0x1b8),'description':a143_0x2619b5(0x1bc)},IMAGE_URL_FLAG={'name':a143_0x2619b5(0x1bd),'type':a143_0x2619b5(0x1b8),'description':a143_0x2619b5(0x190)};function normalizeScene(_0x39204e){const _0x435d83=a143_0x2619b5,_0x2a6d3d=_0x39204e[_0x435d83(0x196)]()['toLowerCase']();if(_0x2a6d3d===_0x435d83(0x195))return'idCard';if(_0x2a6d3d===_0x435d83(0x1af)||_0x2a6d3d===_0x435d83(0x1bf)||_0x2a6d3d==='form')return _0x2a6d3d;throw CliErrors[_0x435d83(0x1c4)](_0x435d83(0x18f)+_0x39204e+_0x435d83(0x1c0)+SUPPORTED_SCENES['join'](',\x20'));}function selectedInputs(_0x4c78c6){const _0x54352d=a143_0x2619b5,_0x904437=_0x4c78c6[_0x54352d(0x1b7)](_0x54352d(0x197))[_0x54352d(0x196)](),_0x1e2c1d=_0x4c78c6['str'](_0x54352d(0x1bd))['trim']();return{'imageFile':_0x904437,'imageUrl':_0x1e2c1d,'count':[_0x904437,_0x1e2c1d][_0x54352d(0x18d)](Boolean)['length']};}function validateInputSelection(_0x2ce738){const _0x3bc014=a143_0x2619b5,_0x4acfc8=selectedInputs(_0x2ce738);if(_0x4acfc8[_0x3bc014(0x194)]!==0x1)throw CliErrors[_0x3bc014(0x1c4)](_0x3bc014(0x1a3));return _0x4acfc8;}function a143_0x4410(){const _0x3c48aa=['read','appCode','count','idcard','trim','image-file','7223976jyNksa','/smartapi/common/queryFileUrl','\x20OCR','Preview:\x20recognize\x20','提取票证类业务材料中的文字与结构化字段;不用于通用图片理解','Table','/smartapi/ocr/recognize-text?','2873142byvCRk','idCard','toString','5958520qhDTrC','Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.','/smartapi/ocr/recognize-text','IdCard','filePath','POST','General','Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20','GET','ocr','imageUrl','28356HInRKw','178Allaih','invoice','4099120UOgzHI','342bMWDNG','<fileUrl\x20returned\x20by\x20/smartapi/common/queryFileUrl>','apiError','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','<filePath\x20returned\x20by\x20/smartapi/common/uploadFile>','587MeljtA','str','string','path','fileName','7ZZehXw','Local\x20image\x20or\x20PDF\x20file;\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','image-url','File\x20URL\x20response\x20missing\x20fileUrl.','general','.\x20Supported\x20scenes:\x20','fileUrl','scene','/smartapi/common/uploadFile','validation','Invoice','imageFile','filter','3092352MhiUDF','Unsupported\x20OCR\x20scene:\x20','Publicly\x20accessible\x20image\x20or\x20file\x20URL','File\x20upload\x20response\x20missing\x20filePath.'];a143_0x4410=function(){return _0x3c48aa;};return a143_0x4410();}function withScene(_0x106da4,_0x461f0a,_0x3c4bf5){const _0x1c5117=a143_0x2619b5;return{..._0x106da4,'scene':_0x461f0a,..._0x3c4bf5?{'sourceFile':{'fileName':_0x3c4bf5[_0x1c5117(0x1ba)],'filePath':_0x3c4bf5[_0x1c5117(0x1a6)]}}:{}};}const ocrRecognize={'service':a143_0x2619b5(0x1ab),'command':'recognize','description':a143_0x2619b5(0x19c),'risk':a143_0x2619b5(0x192),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x182e98){const _0x1f89a2=a143_0x2619b5,_0x1b42fd=normalizeScene(_0x182e98[_0x1f89a2(0x1b7)](_0x1f89a2(0x1c2))),_0x4a7746=SCENE_TO_LEGACY_TYPE[_0x1b42fd],_0x511319=validateInputSelection(_0x182e98);if(_0x511319[_0x1f89a2(0x1ac)]){const _0x42f147=new URLSearchParams({'url':_0x511319['imageUrl'],'type':_0x4a7746,'appCode':_0x182e98[_0x1f89a2(0x193)]});return{'method':_0x1f89a2(0x1aa),'url':_0x1f89a2(0x19e)+_0x42f147[_0x1f89a2(0x1a1)](),'description':_0x1f89a2(0x19b)+_0x1b42fd+'\x20OCR\x20from\x20URL'};}const _0x43bff6=requireDevelopmentUploadFile(_0x511319[_0x1f89a2(0x1c6)],_0x1f89a2(0x197));return{'method':_0x1f89a2(0x1a7),'url':_0x1f89a2(0x1c3),'body':{'steps':[{'method':_0x1f89a2(0x1a7),'url':_0x1f89a2(0x1c3),'body':{'appCode':_0x182e98[_0x1f89a2(0x193)],'multipart':{'file':_0x43bff6}}},{'method':_0x1f89a2(0x1a7),'url':_0x1f89a2(0x199),'body':{'filePath':_0x1f89a2(0x1b5),'downloadFlag':![]}},{'method':_0x1f89a2(0x1aa),'url':_0x1f89a2(0x1a4),'query':{'appCode':_0x182e98[_0x1f89a2(0x193)],'url':_0x1f89a2(0x1b2),'type':_0x4a7746}}]},'description':_0x1f89a2(0x1a9)+_0x1b42fd+_0x1f89a2(0x19a)};},async 'execute'(_0x205a19){const _0x18b3eb=a143_0x2619b5,_0x1fabfd=normalizeScene(_0x205a19['str'](_0x18b3eb(0x1c2))),_0x1bd380=SCENE_TO_LEGACY_TYPE[_0x1fabfd],_0x25645b=validateInputSelection(_0x205a19);if(_0x25645b[_0x18b3eb(0x1ac)]){const _0x30b827=await recognizeDevelopmentOcr(_0x205a19[_0x18b3eb(0x193)],{'url':_0x25645b['imageUrl'],'type':_0x1bd380});return{'ok':!![],'data':withScene(_0x30b827,_0x1fabfd)};}const _0x2f876f=requireDevelopmentUploadFile(_0x25645b[_0x18b3eb(0x1c6)],_0x18b3eb(0x197)),_0x287d59=await uploadDevelopmentFile(_0x205a19['appCode'],_0x2f876f[_0x18b3eb(0x1b9)]);if(!_0x287d59['filePath'])throw CliErrors[_0x18b3eb(0x1b3)](_0x18b3eb(0x191));const _0x5b4679=await queryDevelopmentFileUrl(_0x287d59[_0x18b3eb(0x1a6)],{'download':![]});if(!_0x5b4679[_0x18b3eb(0x1c1)])throw CliErrors[_0x18b3eb(0x1b3)](_0x18b3eb(0x1be));const _0x21cb54=await recognizeDevelopmentOcr(_0x205a19[_0x18b3eb(0x193)],{'url':_0x5b4679['fileUrl'],'type':_0x1bd380});return{'ok':!![],'data':withScene(_0x21cb54,_0x1fabfd,_0x287d59)};}};export const ocrDefinitions=[ocrRecognize];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a144_0x2e8e1a=a144_0x4042;(function(_0x4239cd,_0x91ec62){const _0x54b986=a144_0x4042,_0x249ca6=_0x4239cd();while(!![]){try{const _0x9461c=-parseInt(_0x54b986(0x1d9))/0x1*(parseInt(_0x54b986(0x1db))/0x2)+-parseInt(_0x54b986(0x206))/0x3+-parseInt(_0x54b986(0x1f0))/0x4+-parseInt(_0x54b986(0x1f2))/0x5+parseInt(_0x54b986(0x1f4))/0x6*(parseInt(_0x54b986(0x1e3))/0x7)+parseInt(_0x54b986(0x1ee))/0x8*(-parseInt(_0x54b986(0x1df))/0x9)+parseInt(_0x54b986(0x202))/0xa;if(_0x9461c===_0x91ec62)break;else _0x249ca6['push'](_0x249ca6['shift']());}catch(_0x1878ca){_0x249ca6['push'](_0x249ca6['shift']());}}}(a144_0xa929,0xde99c));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';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,parseCustomPageContent,validateCustomPageContent}from'./custom/shared.js';const DEFAULT_CUSTOM_PAGE_LANGUAGES=[a144_0x2e8e1a(0x1ed),a144_0x2e8e1a(0x1f3)];export const pageCreate={'service':'page','command':a144_0x2e8e1a(0x205),'description':a144_0x2e8e1a(0x211),'risk':a144_0x2e8e1a(0x1ff),'defaultOutputFormat':'compress','structuredErrors':!![],'rejectedFlags':[{'name':a144_0x2e8e1a(0x1dd),'message':a144_0x2e8e1a(0x1da),'hint':a144_0x2e8e1a(0x20a)}],'flags':[{'name':a144_0x2e8e1a(0x1e6),'type':'string','description':a144_0x2e8e1a(0x1d8)},{'name':'parent-menu-id','type':a144_0x2e8e1a(0x20f),'description':a144_0x2e8e1a(0x1fb)},{'name':a144_0x2e8e1a(0x1e8),'type':a144_0x2e8e1a(0x207),'description':'Custom\x20Page\x20pattern\x20(currently\x20BLANK;\x20conflicts\x20with\x20--page-content)','enum':[a144_0x2e8e1a(0x1dc)]},{'name':a144_0x2e8e1a(0x1fc),'type':'string','description':a144_0x2e8e1a(0x204)},APPCODE_FLAG],async 'validate'(_0x4800f9){const _0x53600f=readPagePattern(_0x4800f9);await validateCustomPageContent(readInput(_0x4800f9,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x53600f)['files']);},async 'dryRun'(_0x7f1ced){const _0x2305c4=a144_0x2e8e1a,{input:_0x5ba9a2}=await prepare(_0x7f1ced);return{'method':'POST','url':'/smartapi/webcode/page/create','body':{'appCode':_0x5ba9a2[_0x2305c4(0x1e1)],'pageName':_0x5ba9a2[_0x2305c4(0x1fd)],..._0x5ba9a2[_0x2305c4(0x1fe)]!=null?{'parentMenuId':_0x5ba9a2[_0x2305c4(0x1fe)]}:{},'createMenu':_0x5ba9a2[_0x2305c4(0x1ea)],'codeContent':_0x5ba9a2['files']},'description':'Would\x20create\x20Custom\x20Page\x20'+JSON['stringify'](_0x5ba9a2[_0x2305c4(0x1fd)])+_0x2305c4(0x209)};},async 'execute'(_0x44f1d5){const _0x4f4ca1=a144_0x2e8e1a,_0x410c08=await prepare(_0x44f1d5),_0x563560=await createCustomPage(_0x410c08[_0x4f4ca1(0x1ec)]);if(!Number[_0x4f4ca1(0x1e5)](_0x563560[_0x4f4ca1(0x1e2)])||_0x563560[_0x4f4ca1(0x1e2)]<=0x0)throw CliErrors[_0x4f4ca1(0x20b)](_0x4f4ca1(0x1f7));return{'ok':!![],'data':buildMutationData(_0x410c08,_0x563560),'message':_0x4f4ca1(0x20e)+_0x563560[_0x4f4ca1(0x1e2)]+'.'};}};async function prepare(_0x5ddcb2){const _0x401ed8=a144_0x2e8e1a,_0x1a5e0f=readPagePattern(_0x5ddcb2);if(_0x1a5e0f===null)return{'input':readInput(_0x5ddcb2,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x1a5e0f),'warnings':[],'pagePattern':_0x1a5e0f};let _0x3c12b0=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x3ca211=[];try{const _0x566bb6=await getI18nInfo(_0x5ddcb2[_0x401ed8(0x1e1)]);_0x566bb6['enableI18n']&&_0x566bb6[_0x401ed8(0x1e9)]?.[_0x401ed8(0x20d)]&&(_0x3c12b0=_0x566bb6[_0x401ed8(0x1e9)]);}catch{_0x3ca211=['Application\x20language\x20settings\x20could\x20not\x20be\x20read;\x20default\x20Chinese\x20and\x20English\x20language\x20files\x20were\x20generated.'];}return{'input':readInput(_0x5ddcb2,_0x3c12b0,_0x1a5e0f),'warnings':_0x3ca211,'pagePattern':_0x1a5e0f};}function readPagePattern(_0x22ed42){const _0x3f91d2=a144_0x2e8e1a,_0x5597ce=_0x22ed42[_0x3f91d2(0x1e7)](_0x3f91d2(0x1e8))[_0x3f91d2(0x210)](),_0x1d017b=_0x22ed42[_0x3f91d2(0x1e7)]('page-content')[_0x3f91d2(0x210)]()[_0x3f91d2(0x20d)]>0x0;if(_0x5597ce&&_0x1d017b)throw CliErrors['validation'](_0x3f91d2(0x1f9));if(_0x1d017b)return null;if(!_0x5597ce)throw CliErrors[_0x3f91d2(0x1f6)](_0x3f91d2(0x20c));if(_0x5597ce!==_0x3f91d2(0x1dc))throw CliErrors[_0x3f91d2(0x1f6)]('--page-pattern\x20currently\x20supports\x20only\x20BLANK.');return _0x5597ce;}function a144_0xa929(){const _0x2f770b=['Custom\x20Page\x20was\x20created,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','2367608GSpVkl','menuId','7678200YltAAG','en-US','18UTApWC','menuPath','validation','Custom\x20Page\x20creation\x20did\x20not\x20return\x20a\x20valid\x20pageId.','自定义页面_','--page-pattern\x20and\x20--page-content\x20cannot\x20be\x20used\x20together.','CUSTOM','Optional\x20parent\x20menu\x20id\x20when\x20creating\x20a\x20menu\x20entry','page-content','pageName','parentMenuId','write','pagePattern','parent-menu-id','43335040KVmAdp','keys','Complete\x20page\x20files\x20as\x20JSON\x20(conflicts\x20with\x20--page-pattern)','create','2224953CHzGeM','string','--parent-menu-id\x20must\x20be\x20a\x20positive\x20integer.','\x20and\x20its\x20menu\x20entry.','This\x20command\x20always\x20creates\x20a\x20CUSTOM\x20JSX\x20page;\x20use\x20--page-pattern\x20BLANK\x20or\x20--page-content.','apiError','Provide\x20--page-pattern\x20BLANK\x20or\x20--page-content.','length','Created\x20Custom\x20Page\x20','number','trim','Create\x20a\x20JSX\x20Custom\x20Page\x20from\x20a\x20released\x20pattern\x20or\x20complete\x20files','Optional\x20Custom\x20Page\x20name\x20(1-100\x20characters)','2wcWUMG','page\x20create\x20does\x20not\x20accept\x20--page-type.','1059314rAmbiC','BLANK','page-type','num','27Ppwhdf','warnings','appCode','pageId','2430820qeAdhG','pageName\x20cannot\x20exceed\x20100\x20characters.','isInteger','name','str','page-pattern','langs','createMenu','files','input','zh-CN','1426680ajSLzp'];a144_0xa929=function(){return _0x2f770b;};return a144_0xa929();}function a144_0x4042(_0xc1da92,_0x295281){_0xc1da92=_0xc1da92-0x1d8;const _0xa9295f=a144_0xa929();let _0x404262=_0xa9295f[_0xc1da92];return _0x404262;}function readInput(_0x3c31ec,_0x4b3937=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x12aac7=readPagePattern(_0x3c31ec)){const _0x22711f=a144_0x2e8e1a,_0x2abbf7=_0x3c31ec[_0x22711f(0x1e7)](_0x22711f(0x1e6))[_0x22711f(0x210)]()||_0x22711f(0x1f8)+Date['now']();if(_0x2abbf7['length']>0x64)throw CliErrors[_0x22711f(0x1f6)](_0x22711f(0x1e4));const _0x2a8b22=_0x3c31ec[_0x22711f(0x1de)](_0x22711f(0x201),NaN),_0x22b277=!Number['isNaN'](_0x2a8b22);if(_0x22b277&&(!Number[_0x22711f(0x1e5)](_0x2a8b22)||_0x2a8b22<=0x0))throw CliErrors[_0x22711f(0x1f6)](_0x22711f(0x208));return{'appCode':_0x3c31ec[_0x22711f(0x1e1)],'pageName':_0x2abbf7,..._0x22b277?{'parentMenuId':_0x2a8b22}:{},'createMenu':!![],'files':_0x12aac7===null?parseCustomPageContent(_0x3c31ec[_0x22711f(0x1e7)](_0x22711f(0x1fc))):buildInitialFiles(_0x2abbf7,_0x4b3937)};}function buildMutationData(_0x474da6,_0x34d0b8){const _0x58cc7e=a144_0x2e8e1a,{input:_0x233caf}=_0x474da6,_0x210578=_0x34d0b8&&buildCustomPageDevelopmentUrl(_0x233caf['appCode'],_0x34d0b8[_0x58cc7e(0x1f5)]),_0x4f2d49=_0x34d0b8&&buildCustomPageEditUrl(_0x233caf[_0x58cc7e(0x1e1)],_0x34d0b8[_0x58cc7e(0x1e2)]);return{'operation':'page.create','pageType':_0x58cc7e(0x1fa),'pagePattern':_0x474da6[_0x58cc7e(0x200)],'selector':{'appCode':_0x233caf[_0x58cc7e(0x1e1)],'pageName':_0x233caf[_0x58cc7e(0x1fd)]},'before':null,'after':{'pageId':_0x34d0b8?.[_0x58cc7e(0x1e2)]??null,'pageName':_0x34d0b8?.['pageName']??_0x233caf[_0x58cc7e(0x1fd)],'appCode':_0x34d0b8?.[_0x58cc7e(0x1e1)]??_0x233caf['appCode'],'version':_0x34d0b8?.['version']??null,'menuId':_0x34d0b8?.[_0x58cc7e(0x1f1)]??null,'menuPath':_0x34d0b8?.[_0x58cc7e(0x1f5)]??null,'files':_0x34d0b8?.['files']??Object[_0x58cc7e(0x203)](_0x233caf[_0x58cc7e(0x1eb)])},'dryRun':_0x34d0b8===undefined,'request':_0x233caf,..._0x210578?{'pageUrl':_0x210578}:{},..._0x4f2d49?{'editPageUrl':_0x4f2d49}:{},'warnings':[..._0x474da6[_0x58cc7e(0x1e0)],..._0x34d0b8&&!_0x210578?[_0x58cc7e(0x1ef)]:[]]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a145_0x1f4426=a145_0x513d;(function(_0x91844b,_0x4c3e74){const _0x5c3cab=a145_0x513d,_0x5667d0=_0x91844b();while(!![]){try{const _0x19c370=parseInt(_0x5c3cab(0x1c0))/0x1+-parseInt(_0x5c3cab(0x1ab))/0x2+parseInt(_0x5c3cab(0x1b8))/0x3*(parseInt(_0x5c3cab(0x1be))/0x4)+-parseInt(_0x5c3cab(0x1aa))/0x5+parseInt(_0x5c3cab(0x1ac))/0x6*(parseInt(_0x5c3cab(0x1ad))/0x7)+parseInt(_0x5c3cab(0x1b6))/0x8*(-parseInt(_0x5c3cab(0x1bd))/0x9)+-parseInt(_0x5c3cab(0x1b5))/0xa*(-parseInt(_0x5c3cab(0x1bb))/0xb);if(_0x19c370===_0x4c3e74)break;else _0x5667d0['push'](_0x5667d0['shift']());}catch(_0x46a894){_0x5667d0['push'](_0x5667d0['shift']());}}}(a145_0x5a33,0x3f275));function a145_0x5a33(){const _0x325cbf=['395619WTCUhC','join','appcode','cookie','number','page','Custom\x20Page\x20ID','getTime','appCode','2225800PjRQGs','1020314yZtVod','6CcVuLn','2043762hCIRvN','pageCode','getMonth','padStart','getDate','getSeconds','isNaN','trim','12070OcBwGC','16FVkmfP','getFullYear','72915Bafryy','str','custom-detail','4609CXrtdh','Show\x20a\x20Custom\x20Page\x20and\x20all\x20of\x20its\x20files','1000683RNyjHV','40XlbpCn','compress'];a145_0x5a33=function(){return _0x325cbf;};return a145_0x5a33();}import{getCustomPageSource}from'../../../core/api-client.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,resolveCustomPageDevelopmentUrl}from'./shared.js';function a145_0x513d(_0x4ecbca,_0x32b2a7){_0x4ecbca=_0x4ecbca-0x1a7;const _0x5a33d2=a145_0x5a33();let _0x513d12=_0x5a33d2[_0x4ecbca];return _0x513d12;}export const pageCustomDetail={'service':a145_0x1f4426(0x1c5),'command':a145_0x1f4426(0x1ba),'description':a145_0x1f4426(0x1bc),'risk':'read','defaultOutputFormat':a145_0x1f4426(0x1bf),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a145_0x1f4426(0x1c4),'required':!![],'description':a145_0x1f4426(0x1a7)},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x5f4b73){readCustomPageId(_0x5f4b73);},async 'execute'(_0x57c7f6){const _0x186e23=a145_0x1f4426,_0x19080c=readCustomPageId(_0x57c7f6),_0x3ad8bc=await getCustomPageSource(_0x19080c),{bundle:_0x634d4a,createTime:_0x521c2c,updateTime:_0x14e34f,..._0x152ae6}=_0x3ad8bc,_0x4f4e0b=_0x3ad8bc['id']??_0x19080c,_0x2d7a6d=_0x3ad8bc[_0x186e23(0x1a9)]?.[_0x186e23(0x1b4)]()||_0x57c7f6[_0x186e23(0x1b9)](_0x186e23(0x1c2))[_0x186e23(0x1b4)](),_0x3fa117=buildCustomPageRuntimeUrl(_0x2d7a6d,_0x3ad8bc[_0x186e23(0x1ae)]),_0x1b89b9=buildCustomPageEditUrl(_0x2d7a6d,_0x4f4e0b),_0x5cbcc6=await resolveCustomPageDevelopmentUrl(_0x2d7a6d,_0x4f4e0b,_0x57c7f6[_0x186e23(0x1c3)]);return{'ok':!![],'data':{..._0x152ae6,..._0x3fa117?{'runtimePageUrl':_0x3fa117}:{},..._0x5cbcc6?{'pageUrl':_0x5cbcc6}:{},..._0x1b89b9?{'editPageUrl':_0x1b89b9}:{},..._0x521c2c==null?{}:{'createTime':formatTime(_0x521c2c)},..._0x14e34f==null?{}:{'updateTime':formatTime(_0x14e34f)}},'message':'Retrieved\x20Custom\x20Page\x20'+_0x19080c+'.'};}};function formatTime(_0x36b277){const _0x5e4e8a=a145_0x1f4426,_0x3cacfe=new Date(_0x36b277);if(Number[_0x5e4e8a(0x1b3)](_0x3cacfe[_0x5e4e8a(0x1a8)]()))return String(_0x36b277);const _0x42407d=[_0x3cacfe[_0x5e4e8a(0x1b7)](),String(_0x3cacfe[_0x5e4e8a(0x1af)]()+0x1)[_0x5e4e8a(0x1b0)](0x2,'0'),String(_0x3cacfe[_0x5e4e8a(0x1b1)]())[_0x5e4e8a(0x1b0)](0x2,'0')][_0x5e4e8a(0x1c1)]('-'),_0x360a7b=[String(_0x3cacfe['getHours']())[_0x5e4e8a(0x1b0)](0x2,'0'),String(_0x3cacfe['getMinutes']())[_0x5e4e8a(0x1b0)](0x2,'0'),String(_0x3cacfe[_0x5e4e8a(0x1b2)]())['padStart'](0x2,'0')][_0x5e4e8a(0x1c1)](':');return _0x42407d+'\x20'+_0x360a7b;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a146_0x597f(){const _0x9cd366=['List\x20Custom\x20Pages\x20in\x20the\x20current\x20app','read','No\x20Custom\x20Pages\x20found.','1084328zAGVwy','Found\x20','react','8lmPFZh','length','1163739pzKzLI','pageId','label','type','\x20Custom\x20Page(s).','flatMap','path','custom-list','1414lPHTgI','page','appCode','3509555HkDheD','42964nvTlVy','cookie','327844kdDbNA','3946182OUltGi'];a146_0x597f=function(){return _0x9cd366;};return a146_0x597f();}function a146_0x18fd(_0x21d594,_0xc7a8ee){_0x21d594=_0x21d594-0x1bb;const _0x597f2a=a146_0x597f();let _0x18fdf6=_0x597f2a[_0x21d594];return _0x18fdf6;}const a146_0x10447a=a146_0x18fd;(function(_0x5d5455,_0x2091b6){const _0x244ebf=a146_0x18fd,_0x17160f=_0x5d5455();while(!![]){try{const _0x29a929=parseInt(_0x244ebf(0x1c1))/0x1+parseInt(_0x244ebf(0x1c3))/0x2+parseInt(_0x244ebf(0x1cd))/0x3+-parseInt(_0x244ebf(0x1c8))/0x4+parseInt(_0x244ebf(0x1c0))/0x5+-parseInt(_0x244ebf(0x1c4))/0x6+-parseInt(_0x244ebf(0x1bd))/0x7*(parseInt(_0x244ebf(0x1cb))/0x8);if(_0x29a929===_0x2091b6)break;else _0x17160f['push'](_0x17160f['shift']());}catch(_0x4ca264){_0x17160f['push'](_0x17160f['shift']());}}}(a146_0x597f,0x59c71));import{APPCODE_FLAG}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl}from'./shared.js';export const pageCustomList={'service':a146_0x10447a(0x1be),'command':a146_0x10447a(0x1bc),'description':a146_0x10447a(0x1c5),'risk':a146_0x10447a(0x1c6),'defaultOutputFormat':'compress','structuredErrors':!![],'flags':[APPCODE_FLAG],async 'execute'(_0x441504){const _0x3d527c=a146_0x10447a,_0x2a155d=(await fetchMenuSnapshot(_0x441504[_0x3d527c(0x1bf)],_0x441504[_0x3d527c(0x1c2)]))['menus'][_0x3d527c(0x1d2)](_0x47dbe1=>{const _0x2a629d=_0x3d527c;if(_0x47dbe1[_0x2a629d(0x1d0)]!==_0x2a629d(0x1ca)||_0x47dbe1[_0x2a629d(0x1ce)]==null)return[];const _0x853cb1=buildCustomPageDevelopmentUrl(_0x441504['appCode'],_0x47dbe1[_0x2a629d(0x1bb)]),_0x5851ee=buildCustomPageEditUrl(_0x441504[_0x2a629d(0x1bf)],_0x47dbe1[_0x2a629d(0x1ce)]);return[{'pageId':_0x47dbe1[_0x2a629d(0x1ce)],'label':_0x47dbe1[_0x2a629d(0x1cf)],..._0x853cb1?{'pageUrl':_0x853cb1}:{},..._0x5851ee?{'editPageUrl':_0x5851ee}:{}}];});return{'ok':!![],'data':{'pages':_0x2a155d},'message':_0x2a155d['length']===0x0?_0x3d527c(0x1c7):_0x3d527c(0x1c9)+_0x2a155d[_0x3d527c(0x1cc)]+_0x3d527c(0x1d1)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a147_0x37a234=a147_0x37a0;function a147_0x37a0(_0x4ed7a3,_0x3f4f2d){_0x4ed7a3=_0x4ed7a3-0x13b;const _0x5ac869=a147_0x5ac8();let _0x37a0ef=_0x5ac869[_0x4ed7a3];return _0x37a0ef;}(function(_0x39e3a9,_0x3f862b){const _0x134e00=a147_0x37a0,_0x3cb794=_0x39e3a9();while(!![]){try{const _0x4c8ce9=parseInt(_0x134e00(0x157))/0x1*(parseInt(_0x134e00(0x14d))/0x2)+parseInt(_0x134e00(0x145))/0x3*(-parseInt(_0x134e00(0x148))/0x4)+-parseInt(_0x134e00(0x13d))/0x5+-parseInt(_0x134e00(0x14a))/0x6*(parseInt(_0x134e00(0x15f))/0x7)+parseInt(_0x134e00(0x163))/0x8+-parseInt(_0x134e00(0x13e))/0x9+-parseInt(_0x134e00(0x14b))/0xa*(-parseInt(_0x134e00(0x143))/0xb);if(_0x4c8ce9===_0x3f862b)break;else _0x3cb794['push'](_0x3cb794['shift']());}catch(_0x6fdc1){_0x3cb794['push'](_0x3cb794['shift']());}}}(a147_0x5ac8,0x37f1d));import{getCustomPageSource,publishCustomPage}from'../../../core/api-client.js';function a147_0x5ac8(){const _0x383fb8=['string','warnings','Custom\x20Page\x20publish\x20did\x20not\x20return\x20the\x20expected\x20page\x20ID.','836eSaCrB','runtimePageUrl','81702ZPmZOl','custom-publish','POST','36pyDQpE','push','138XtzwNt','133850sszKxv','pageId','1306EDNteJ','trim','page.custom-publish','remark','Published\x20Custom\x20Page\x20','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','cookie','status','Would\x20publish\x20Custom\x20Page\x20','page','499KvsYBt','Publish\x20the\x20latest\x20saved\x20content\x20of\x20a\x20Custom\x20Page','apiError','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20published\x20page\x20could\x20not\x20be\x20generated.','compress','isInteger','str','Custom\x20Page\x20ID','71953vNPvNi','Custom\x20Page\x20publish\x20did\x20not\x20reach\x20published\x20status:\x20','number','unknown','41808cdwPWz','appCode','FORMAL','964625fmEbAc','4002624qZneha','/smartapi/webcode/file/publish'];a147_0x5ac8=function(){return _0x383fb8;};return a147_0x5ac8();}import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,resolveCustomPageDevelopmentUrl}from'./shared.js';export const pageCustomPublish={'service':a147_0x37a234(0x156),'command':a147_0x37a234(0x146),'description':a147_0x37a234(0x158),'risk':'write','defaultOutputFormat':a147_0x37a234(0x15b),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a147_0x37a234(0x161),'required':!![],'description':a147_0x37a234(0x15e)},{'name':a147_0x37a234(0x150),'type':a147_0x37a234(0x140),'description':'Optional\x20publish\x20remark'}],async 'validate'(_0x2b87e8){readCustomPageId(_0x2b87e8);},async 'dryRun'(_0x130654){const _0x6a5b69=a147_0x37a234,_0x4c9549=readInput(_0x130654);return{'method':_0x6a5b69(0x147),'url':_0x6a5b69(0x13f),'body':{'id':_0x4c9549[_0x6a5b69(0x14c)],..._0x4c9549[_0x6a5b69(0x150)]?{'remark':_0x4c9549[_0x6a5b69(0x150)]}:{}},'description':_0x6a5b69(0x155)+_0x4c9549[_0x6a5b69(0x14c)]+'.'};},async 'execute'(_0x447b90){const _0x9e51e5=a147_0x37a234,_0x41cb41=readInput(_0x447b90);await getCustomPageSource(_0x41cb41[_0x9e51e5(0x14c)]);const _0x198e47=await publishCustomPage(_0x41cb41);if(!Number[_0x9e51e5(0x15c)](_0x198e47)||_0x198e47!==_0x41cb41['pageId'])throw CliErrors[_0x9e51e5(0x159)](_0x9e51e5(0x142));const _0x1b2815=await getCustomPageSource(_0x41cb41[_0x9e51e5(0x14c)]);if(_0x1b2815[_0x9e51e5(0x154)]!=='FORMAL')throw CliErrors['apiError'](_0x9e51e5(0x160)+(_0x1b2815['status']??_0x9e51e5(0x162))+'.');const _0x214c69=_0x1b2815['appCode']?.['trim'](),_0x2f2dae=buildCustomPageEditUrl(_0x214c69,_0x41cb41[_0x9e51e5(0x14c)]),_0x5055cd=await resolveCustomPageDevelopmentUrl(_0x214c69,_0x41cb41['pageId'],_0x447b90[_0x9e51e5(0x153)]),_0x168f6a=buildMutationData(_0x41cb41,!![],_0x5055cd,_0x2f2dae);_0x214c69&&!_0x5055cd&&_0x168f6a[_0x9e51e5(0x141)][_0x9e51e5(0x149)](_0x9e51e5(0x152));const _0x2864ae=buildCustomPageRuntimeUrl(_0x1b2815[_0x9e51e5(0x13b)],_0x1b2815['pageCode']);return _0x2864ae?_0x168f6a[_0x9e51e5(0x144)]=_0x2864ae:_0x168f6a[_0x9e51e5(0x141)][_0x9e51e5(0x149)](_0x9e51e5(0x15a)),{'ok':!![],'data':_0x168f6a,'message':_0x9e51e5(0x151)+_0x41cb41['pageId']+'.'};}};function readInput(_0x1197a4){const _0x3c06ca=a147_0x37a234,_0x536604=readCustomPageId(_0x1197a4),_0x559616=_0x1197a4[_0x3c06ca(0x15d)](_0x3c06ca(0x150))[_0x3c06ca(0x14e)]();return{'pageId':_0x536604,..._0x559616?{'remark':_0x559616}:{}};}function buildMutationData(_0x3c66dd,_0x22d8f6=![],_0x5c7558,_0x28603d){const _0x38e7a7=a147_0x37a234;return{'operation':_0x38e7a7(0x14f),'selector':{'pageId':_0x3c66dd[_0x38e7a7(0x14c)]},'before':null,'after':{'pageId':_0x3c66dd[_0x38e7a7(0x14c)],'status':_0x38e7a7(0x13c)},'dryRun':!_0x22d8f6,'request':_0x3c66dd,..._0x5c7558?{'pageUrl':_0x5c7558}:{},..._0x28603d?{'editPageUrl':_0x28603d}:{},'warnings':[]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
const a148_0x40d252=a148_0x1df4;function a148_0x1df4(_0x3aaca1,_0x10f34c){_0x3aaca1=_0x3aaca1-0x117;const _0x328108=a148_0x3281();let _0x1df4c6=_0x328108[_0x3aaca1];return _0x1df4c6;}(function(_0x9b22e9,_0x4cbd05){const _0x154831=a148_0x1df4,_0x2e44ee=_0x9b22e9();while(!![]){try{const _0x1f47b8=-parseInt(_0x154831(0x130))/0x1+-parseInt(_0x154831(0x129))/0x2+parseInt(_0x154831(0x12d))/0x3*(-parseInt(_0x154831(0x11d))/0x4)+parseInt(_0x154831(0x11c))/0x5+-parseInt(_0x154831(0x124))/0x6*(-parseInt(_0x154831(0x126))/0x7)+-parseInt(_0x154831(0x12a))/0x8*(parseInt(_0x154831(0x119))/0x9)+parseInt(_0x154831(0x12b))/0xa;if(_0x1f47b8===_0x4cbd05)break;else _0x2e44ee['push'](_0x2e44ee['shift']());}catch(_0x41a05b){_0x2e44ee['push'](_0x2e44ee['shift']());}}}(a148_0x3281,0x3a0c6));import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';function a148_0x3281(){const _0xd04f23=['react','length','object','28017hAibfg','--id\x20must\x20be\x20a\x20positive\x20integer.','path','2325820pyxJdJ','4UDzCen','num','/app','string','parse','isInteger','https://','18mUhZVO','message','440839hcOIjd','trim','menus','257224zmfVML','1152JNiAAD','4511140lkJoaa','https://daily.lovrabet.com','741153AXhCTC','type','file','43508JwGMXl','isArray','map','https://app.lovrabet.com','page-content','validation','/web-app/app','Optional\x20app\x20code\x20resolved\x20from\x20page\x20ID\x20when\x20omitted','join','Invalid\x20Custom\x20Page\x20content:\x20'];a148_0x3281=function(){return _0xd04f23;};return a148_0x3281();}import{getEnv,isProduction}from'../../../constant/env.js';import{getAppBaseUrl}from'../../../constant/domain.js';import{CliErrors}from'../../../errors.js';import{validateCustomPageSourceFiles}from'./syntax.js';export const CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL={...APPCODE_FLAG_OPTIONAL,'description':a148_0x40d252(0x137)};function trimOptional(_0x1bdcca){const _0x13bad8=a148_0x40d252;return _0x1bdcca?.[_0x13bad8(0x127)]()||undefined;}export function buildCustomPageRuntimeUrl(_0x5e8b59,_0x2fc8c2){const _0x50450e=a148_0x40d252,_0x10e356=trimOptional(_0x5e8b59),_0x312a96=trimOptional(_0x2fc8c2);if(!_0x10e356||!_0x312a96)return undefined;const _0x2a7f8c=isProduction(getEnv())?_0x10e356+'.app.lovrabet.com':_0x10e356+'.daily.lovrabet.com';return _0x50450e(0x123)+_0x2a7f8c+'/'+encodeURIComponent(_0x312a96);}export function buildCustomPageDevelopmentUrl(_0x1652ec,_0x22cbbf){const _0x1fbbbb=trimOptional(_0x1652ec),_0x22cfe8=trimOptional(_0x22cbbf);if(!_0x1fbbbb||!_0x22cfe8)return undefined;return getAppBaseUrl(_0x1fbbbb)+'/pages/'+encodeURIComponent(_0x22cfe8);}export async function resolveCustomPageDevelopmentUrl(_0x2b8c22,_0xb129c2,_0x18822f){const _0x172f40=a148_0x40d252,_0x48724e=trimOptional(_0x2b8c22);if(!_0x48724e)return undefined;try{const _0x2f22f5=(await fetchMenuSnapshot(_0x48724e,_0x18822f))[_0x172f40(0x128)]['find'](_0x9b63ac=>_0x9b63ac[_0x172f40(0x12e)]===_0x172f40(0x13a)&&_0x9b63ac['pageId']===_0xb129c2);return buildCustomPageDevelopmentUrl(_0x48724e,_0x2f22f5?.[_0x172f40(0x11b)]);}catch{return undefined;}}export function buildCustomPageEditUrl(_0x4ed059,_0x3a0d98){const _0x2eaf89=a148_0x40d252,_0x384a53=trimOptional(_0x4ed059);if(!_0x384a53)return;const _0x596211=trimOptional(_0x3a0d98==null?undefined:String(_0x3a0d98));if(!_0x596211)return;const _0x43b5ce=isProduction(getEnv())?_0x2eaf89(0x11f):_0x2eaf89(0x136),_0x2cd339=isProduction(getEnv())?_0x2eaf89(0x133):_0x2eaf89(0x12c);return''+_0x2cd339+_0x43b5ce+'/'+encodeURIComponent(_0x384a53)+'/ide/'+encodeURIComponent(_0x596211);}export function parseCustomPageContent(_0x9a67e){const _0x40cbd5=a148_0x40d252;if(!_0x9a67e[_0x40cbd5(0x127)]())throw CliErrors['flagMissing'](_0x40cbd5(0x134));let _0x36fe7e;try{_0x36fe7e=JSON[_0x40cbd5(0x121)](_0x9a67e);}catch{throw CliErrors[_0x40cbd5(0x135)]('--page-content\x20must\x20be\x20valid\x20JSON.');}if(typeof _0x36fe7e!==_0x40cbd5(0x118)||_0x36fe7e===null||Array[_0x40cbd5(0x131)](_0x36fe7e)||Object['values'](_0x36fe7e)['some'](_0x26634a=>typeof _0x26634a!==_0x40cbd5(0x120)))throw CliErrors['validation']('--page-content\x20must\x20be\x20a\x20JSON\x20object\x20whose\x20values\x20are\x20file\x20content\x20strings.');return _0x36fe7e;}export async function validateCustomPageContent(_0x59e20d){const _0x2f7fc2=a148_0x40d252,_0x176a49=await validateCustomPageSourceFiles(_0x59e20d);if(_0x176a49[_0x2f7fc2(0x117)]>0x0)throw CliErrors[_0x2f7fc2(0x135)](_0x2f7fc2(0x139)+_0x176a49[_0x2f7fc2(0x132)](_0x5cf360=>_0x5cf360[_0x2f7fc2(0x12f)]+':\x20'+_0x5cf360[_0x2f7fc2(0x125)])[_0x2f7fc2(0x138)](';\x20'));}export function readCustomPageId(_0x5cc354){const _0x32b31b=a148_0x40d252,_0x1bdec6=_0x5cc354[_0x32b31b(0x11e)]('id');if(!Number[_0x32b31b(0x122)](_0x1bdec6)||_0x1bdec6<=0x0)throw CliErrors[_0x32b31b(0x135)](_0x32b31b(0x11a));return _0x1bdec6;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a149_0x4f98e9=a149_0x56b7;(function(_0x1eea89,_0x1afe70){const _0xa6cdc7=a149_0x56b7,_0x422eb4=_0x1eea89();while(!![]){try{const _0x455715=parseInt(_0xa6cdc7(0x181))/0x1+-parseInt(_0xa6cdc7(0x18d))/0x2*(-parseInt(_0xa6cdc7(0x191))/0x3)+-parseInt(_0xa6cdc7(0x183))/0x4*(parseInt(_0xa6cdc7(0x180))/0x5)+-parseInt(_0xa6cdc7(0x17f))/0x6*(-parseInt(_0xa6cdc7(0x184))/0x7)+parseInt(_0xa6cdc7(0x187))/0x8+-parseInt(_0xa6cdc7(0x192))/0x9*(-parseInt(_0xa6cdc7(0x18a))/0xa)+parseInt(_0xa6cdc7(0x18c))/0xb*(-parseInt(_0xa6cdc7(0x185))/0xc);if(_0x455715===_0x1afe70)break;else _0x422eb4['push'](_0x422eb4['shift']());}catch(_0x5b3157){_0x422eb4['push'](_0x422eb4['shift']());}}}(a149_0x4533,0x55450));function a149_0x56b7(_0x4b58da,_0x58177b){_0x4b58da=_0x4b58da-0x17e;const _0x4533fa=a149_0x4533();let _0x56b7f9=_0x4533fa[_0x4b58da];return _0x56b7f9;}function a149_0x4533(){const _0xf0f529=['570464XEeUnE','toLowerCase','1584vSwfAD','2304526uaZYub','348RVzkRc','.tsx','3322672EZZMlZ','.jsx','all','60qqUKXA','trim','566027mmzvPG','2KDWHuC','babel','page-content','Missing\x20React\x20source\x20file\x20with\x20extension\x20.jsx\x20or\x20.tsx','1781607JsOHQY','58734SqBTcp','find','endsWith','filter','typescript','some','message','6kgmoiU','1345efzbaF'];a149_0x4533=function(){return _0xf0f529;};return a149_0x4533();}import{format}from'prettier';const SOURCE_PARSERS={'.js':a149_0x4f98e9(0x18e),'.jsx':a149_0x4f98e9(0x18e),'.ts':a149_0x4f98e9(0x196),'.tsx':a149_0x4f98e9(0x196)},CUSTOM_PAGE_EXTENSIONS=[a149_0x4f98e9(0x188),a149_0x4f98e9(0x186)];export async function validateCustomPageSourceFiles(_0x4e9cd9){const _0x45271d=a149_0x4f98e9,_0x515107=Object['entries'](_0x4e9cd9)['filter'](([_0x2efc13])=>getParser(_0x2efc13));if(!_0x515107[_0x45271d(0x197)](([_0x2a7fd1])=>isReactSourceFile(_0x2a7fd1)))return[{'file':_0x45271d(0x18f),'message':_0x45271d(0x190)}];const _0x3ccafc=await Promise[_0x45271d(0x189)](_0x515107['map'](async([_0x38e026,_0x4ad04b])=>{const _0x809d3d=_0x45271d;try{return await format(_0x4ad04b,{'parser':getParser(_0x38e026)}),undefined;}catch(_0x35eb14){return{'file':_0x38e026,'message':_0x35eb14 instanceof Error?_0x35eb14[_0x809d3d(0x17e)]:String(_0x35eb14)};}}));return _0x3ccafc[_0x45271d(0x195)](_0x4629a8=>_0x4629a8!==undefined);}function getParser(_0x522c83){const _0xae6fec=a149_0x4f98e9,_0x2f585b=_0x522c83[_0xae6fec(0x18b)]()[_0xae6fec(0x182)]();return Object['entries'](SOURCE_PARSERS)[_0xae6fec(0x193)](([_0x341b46])=>_0x2f585b[_0xae6fec(0x194)](_0x341b46))?.[0x1];}function isReactSourceFile(_0x2f9b18){const _0x6c9e85=a149_0x4f98e9,_0x575116=_0x2f9b18[_0x6c9e85(0x18b)]()[_0x6c9e85(0x182)]();return CUSTOM_PAGE_EXTENSIONS['some'](_0x325c6c=>_0x575116[_0x6c9e85(0x194)](_0x325c6c));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a150_0x401e(_0x228dd7,_0x507dab){_0x228dd7=_0x228dd7-0x134;const _0x2470a1=a150_0x2470();let _0x401eab=_0x2470a1[_0x228dd7];return _0x401eab;}(function(_0x11af4d,_0x351dd9){const _0x4f04e9=a150_0x401e,_0x44d29b=_0x11af4d();while(!![]){try{const _0x3de381=-parseInt(_0x4f04e9(0x14b))/0x1+-parseInt(_0x4f04e9(0x145))/0x2+parseInt(_0x4f04e9(0x149))/0x3*(parseInt(_0x4f04e9(0x139))/0x4)+-parseInt(_0x4f04e9(0x14a))/0x5+-parseInt(_0x4f04e9(0x147))/0x6+-parseInt(_0x4f04e9(0x148))/0x7+-parseInt(_0x4f04e9(0x13c))/0x8*(-parseInt(_0x4f04e9(0x14c))/0x9);if(_0x3de381===_0x351dd9)break;else _0x44d29b['push'](_0x44d29b['shift']());}catch(_0x25ec38){_0x44d29b['push'](_0x44d29b['shift']());}}}(a150_0x2470,0x6bb89));function buildIndexFile(_0x49ad6f){const _0x5d5d74=a150_0x401e;return _0x5d5d74(0x13a)+JSON[_0x5d5d74(0x138)](_0x49ad6f)+'}</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';}function buildStyleFile(){const _0x468f2b=a150_0x401e;return _0x468f2b(0x141);}function buildLocalesFile(_0x26ae10){const _0x3237a4=a150_0x401e,_0x4f3d51=_0x26ae10[_0x3237a4(0x144)](_0x1dd965=>{const _0x53b77d=_0x3237a4;let _0x5b3d22='';switch(_0x1dd965){case _0x53b77d(0x13e):_0x5b3d22=_0x53b77d(0x143);break;case _0x53b77d(0x134):_0x5b3d22='This\x20is\x20a\x20basic\x20page\x20template,\x20you\x20can\x20develop\x20based\x20on\x20it.';break;case _0x53b77d(0x13f):_0x5b3d22='これは基本ページテンプレートです。あなたは、これに基づいて開発できます。';break;case _0x53b77d(0x135):_0x5b3d22=_0x53b77d(0x140);break;case'id-ID':_0x5b3d22=_0x53b77d(0x137);break;default:_0x5b3d22=_0x53b77d(0x14d);}return'\x20\x20'+JSON[_0x53b77d(0x138)](_0x1dd965)+_0x53b77d(0x146)+JSON[_0x53b77d(0x138)]('pageDescription')+':\x20'+JSON['stringify'](_0x5b3d22)+_0x53b77d(0x142);})[_0x3237a4(0x13b)](',\x0a');return _0x3237a4(0x136)+_0x4f3d51+_0x3237a4(0x13d);}export function buildInitialFiles(_0x635b27,_0x4f6167){return{'src/app/index.jsx':buildIndexFile(_0x635b27),'src/app/index.css':buildStyleFile(),'src/locales/index.js':buildLocalesFile(_0x4f6167)};}function a150_0x2470(){const _0x3dcccd=['stringify','3209236GeDLcA','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}>{','join','957448VyTvVY','\x0a};\x0a','zh-CN','ja-JP','Bu\x20bir\x20temel\x20sayfa\x20şablonudur.\x20Bu\x20temaplana\x20dayanarak\x20geliştirilebilir.','.page-container\x20{\x0a\x20\x20padding:\x2024px;\x0a\x20\x20background:\x20#f0f2f5;\x0a\x20\x20min-height:\x20100vh;\x0a}\x0a',',\x0a\x20\x20}','这是一个基础页面模板,你可以在此基础上进行开发。','map','1256714VQcJup',':\x20{\x0a\x20\x20\x20\x20','828702gmBuzZ','255766zHPKun','3zbfekT','498000ooarkw','774963SIQHnR','99bWrEqC','This\x20is\x20a\x20basic\x20page\x20template,\x20you\x20can\x20develop\x20based\x20on\x20it.','en-US','tr-TR','export\x20const\x20locales\x20=\x20{\x0a','Ini\x20adalah\x20sebuah\x20halaman\x20dasar.\x20Anda\x20dapat\x20mengembangkan\x20ini.'];a150_0x2470=function(){return _0x3dcccd;};return a150_0x2470();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a151_0x3422c8=a151_0x2728;(function(_0x580c68,_0x5a52c1){const _0x53ac5f=a151_0x2728,_0x5b47a8=_0x580c68();while(!![]){try{const _0x4f888c=parseInt(_0x53ac5f(0x1de))/0x1+-parseInt(_0x53ac5f(0x1c4))/0x2*(parseInt(_0x53ac5f(0x1c6))/0x3)+parseInt(_0x53ac5f(0x1d0))/0x4*(parseInt(_0x53ac5f(0x1cf))/0x5)+parseInt(_0x53ac5f(0x1c8))/0x6+parseInt(_0x53ac5f(0x1d9))/0x7*(-parseInt(_0x53ac5f(0x1df))/0x8)+parseInt(_0x53ac5f(0x1d3))/0x9+parseInt(_0x53ac5f(0x1e3))/0xa;if(_0x4f888c===_0x5a52c1)break;else _0x5b47a8['push'](_0x5b47a8['shift']());}catch(_0x1db855){_0x5b47a8['push'](_0x5b47a8['shift']());}}}(a151_0x507c,0x62257));import{getCustomPageSource,updateCustomPageContent}from'../../../core/api-client.js';function a151_0x2728(_0x5270c9,_0x324900){_0x5270c9=_0x5270c9-0x1c3;const _0x507c0c=a151_0x507c();let _0x272881=_0x507c0c[_0x5270c9];return _0x272881;}import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,parseCustomPageContent,resolveCustomPageDevelopmentUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,validateCustomPageContent}from'./shared.js';export const pageCustomUpdate={'service':a151_0x3422c8(0x1d1),'command':a151_0x3422c8(0x1da),'description':a151_0x3422c8(0x1d8),'risk':a151_0x3422c8(0x1e1),'defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a151_0x3422c8(0x1ce),'required':!![],'description':'Custom\x20Page\x20ID'},{'name':a151_0x3422c8(0x1e0),'type':'string','required':!![],'description':a151_0x3422c8(0x1d7)},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x322dec){const _0x54c2a9=a151_0x3422c8;readCustomPageId(_0x322dec),await validateCustomPageContent(parseCustomPageContent(_0x322dec['str'](_0x54c2a9(0x1e0))));},async 'dryRun'(_0x49e5da){const _0x3376f0=a151_0x3422c8,_0x5e6eb0=await readInput(_0x49e5da);return{'method':_0x3376f0(0x1cd),'url':'/smartapi/webcode/page/update/content','body':{'id':_0x5e6eb0[_0x3376f0(0x1c7)],'codeContent':_0x5e6eb0['pageContent']},'description':_0x3376f0(0x1e2)+_0x5e6eb0[_0x3376f0(0x1c7)]+'.'};},async 'execute'(_0x405580){const _0x461066=a151_0x3422c8,_0x57c858=await readInput(_0x405580),_0x52616b=await updateCustomPageContent({'pageId':_0x57c858[_0x461066(0x1c7)],'pageContent':_0x57c858['pageContent']});if(!Number[_0x461066(0x1cb)](_0x52616b[_0x461066(0x1c3)])||_0x52616b[_0x461066(0x1c3)]<=0x0)throw CliErrors[_0x461066(0x1db)]('Custom\x20Page\x20update\x20did\x20not\x20create\x20a\x20new\x20version.');const _0x39c40=buildCustomPageEditUrl(_0x57c858[_0x461066(0x1d6)],_0x57c858['pageId']),_0x51eb36=await resolveCustomPageDevelopmentUrl(_0x57c858[_0x461066(0x1d6)],_0x57c858[_0x461066(0x1c7)],_0x405580[_0x461066(0x1dc)]);return{'ok':!![],'data':buildMutationData(_0x57c858,_0x52616b,_0x51eb36,_0x39c40,_0x51eb36?[]:[_0x461066(0x1ca)]),'message':_0x461066(0x1c5)+_0x57c858[_0x461066(0x1c7)]+'.'};}};async function readInput(_0x282dff){const _0x57fd9a=a151_0x3422c8,_0x27cf1e=readCustomPageId(_0x282dff),_0x3e541e=_0x282dff[_0x57fd9a(0x1d5)](_0x57fd9a(0x1c9))['trim']()||(await getCustomPageSource(_0x27cf1e))[_0x57fd9a(0x1d6)]?.[_0x57fd9a(0x1d4)]();if(!_0x3e541e)throw CliErrors[_0x57fd9a(0x1dd)](_0x57fd9a(0x1cc)+_0x27cf1e+'.');return{'appCode':_0x3e541e,'pageId':_0x27cf1e,'pageContent':parseCustomPageContent(_0x282dff[_0x57fd9a(0x1d5)]('page-content'))};}function buildMutationData(_0x201a82,_0x2be000,_0x5f5196,_0x43ddd4,_0x584861=[]){const _0x15ec33=a151_0x3422c8;return{'operation':_0x15ec33(0x1d2),'selector':{'appCode':_0x201a82[_0x15ec33(0x1d6)],'pageId':_0x201a82[_0x15ec33(0x1c7)]},'before':null,'after':{'pageId':_0x2be000?.[_0x15ec33(0x1c7)]??_0x201a82[_0x15ec33(0x1c7)],'version':_0x2be000?.['newVersion']??null,'pageContent':_0x201a82['pageContent']},'dryRun':_0x2be000===undefined,'request':_0x201a82,..._0x5f5196?{'pageUrl':_0x5f5196}:{},..._0x43ddd4?{'editPageUrl':_0x43ddd4}:{},'warnings':_0x584861};}function a151_0x507c(){const _0x2f0c0e=['Custom\x20Page\x20was\x20updated,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','isInteger','Cannot\x20determine\x20the\x20appCode\x20for\x20Custom\x20Page\x20','POST','number','1557725CzHJLH','4dZhGCw','page','page.custom-update','3531564pVUWmH','trim','str','appCode','Complete\x20page\x20files\x20as\x20JSON','Save\x20all\x20files\x20of\x20a\x20Custom\x20Page','7rvfdOj','custom-update','apiError','cookie','validation','45050LpAIWY','56272oRPQHq','page-content','write','Would\x20save\x20all\x20files\x20of\x20Custom\x20Page\x20','1874370lSNlrw','newVersion','52892hwKwnh','Updated\x20Custom\x20Page\x20','60BegIXp','pageId','9198lRCbpH','appcode'];a151_0x507c=function(){return _0x2f0c0e;};return a151_0x507c();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a152_0xf069(){const _0x1ab146=['820614zKiFzV','page','status','nextAction','GET','1668190JmXoSK','data-list-status','compress','relatedPages','/smartapi/lovrabet/dataset/','1376124AUftcU','Query\x20Data\x20List\x20Page\x20facts\x20for\x20a\x20dataset','read','59070NAjfaQ','code','28965800OSCtnO','appCode','manualResolutionRequired','938BUZtvz','name','626192DLksVA','length','1863590fOZRSd','source','related-pages-fallback'];a152_0xf069=function(){return _0x1ab146;};return a152_0xf069();}const a152_0x75d7ac=a152_0x1770;(function(_0x343ca0,_0x8ef556){const _0x4f5c7b=a152_0x1770,_0xb98627=_0x343ca0();while(!![]){try{const _0x240af1=-parseInt(_0x4f5c7b(0xff))/0x1+-parseInt(_0x4f5c7b(0xeb))/0x2+-parseInt(_0x4f5c7b(0xf0))/0x3+parseInt(_0x4f5c7b(0xfa))/0x4+parseInt(_0x4f5c7b(0xfc))/0x5+parseInt(_0x4f5c7b(0xf3))/0x6*(-parseInt(_0x4f5c7b(0xf8))/0x7)+parseInt(_0x4f5c7b(0xf5))/0x8;if(_0x240af1===_0x8ef556)break;else _0xb98627['push'](_0xb98627['shift']());}catch(_0x2ed92e){_0xb98627['push'](_0xb98627['shift']());}}}(a152_0xf069,0xaf220));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assessDataListPageState,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';function a152_0x1770(_0x49f56e,_0x4343e3){_0x49f56e=_0x49f56e-0xea;const _0xf06997=a152_0xf069();let _0x17704d=_0xf06997[_0x49f56e];return _0x17704d;}export const pageDataListStatus={'service':a152_0x75d7ac(0x100),'command':a152_0x75d7ac(0xec),'description':a152_0x75d7ac(0xf1),'risk':a152_0x75d7ac(0xf2),'defaultOutputFormat':a152_0x75d7ac(0xed),'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':'alias','type':'string','description':'Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)'}],async 'validate'(_0x2d6a7d){validateDatasetSelector(_0x2d6a7d);},async 'dryRun'(_0x51dfe5){const _0x22d88e=a152_0x75d7ac,_0x5feedb=await loadDatasetDetailForPage(_0x51dfe5);return{'method':_0x22d88e(0xea),'url':_0x22d88e(0xef)+_0x5feedb[_0x22d88e(0xf4)]+'/standard-page-status?appCode='+encodeURIComponent(_0x51dfe5[_0x22d88e(0xf6)]),'description':serializeDryRunDescription({'dataset':{'id':_0x5feedb['id'],'code':_0x5feedb['code'],'name':_0x5feedb[_0x22d88e(0xf9)]},'action':'query-data-list-status'})};},async 'execute'(_0x49632c){const _0x112b2e=a152_0x75d7ac,_0x3be510=await loadDatasetDetailForPage(_0x49632c),_0x7cdba3=await loadDataListPageStatusForGenerate(_0x49632c,_0x3be510[_0x112b2e(0xf4)]),_0x49e177=getUndeletedRelatedPages(_0x3be510),_0x4ee203=assessDataListPageState(_0x3be510[_0x112b2e(0xf4)],_0x7cdba3,{'fallbackUndeletedPages':_0x49e177});return{'ok':!![],'data':{'datasetCode':_0x3be510[_0x112b2e(0xf4)],'precheckSource':_0x7cdba3?.[_0x112b2e(0xfd)]??_0x112b2e(0xfe),'status':_0x4ee203[_0x112b2e(0x101)],'manualResolutionRequired':_0x4ee203[_0x112b2e(0xf7)],'nextAction':_0x4ee203[_0x112b2e(0x102)],'dataListPageStatus':_0x7cdba3,'relatedPages':{'total':_0x3be510[_0x112b2e(0xee)][_0x112b2e(0xfb)],'undeletedCount':_0x49e177[_0x112b2e(0xfb)]}}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a153_0x1348(){const _0x237fc8=['/generate-standard-pages/start','progressRate','dryRun','appCode','PARTIAL_SUCCESS','181791enzrJt','dataListPageStatus','4917gvmUtT','related-pages-fallback','已提交生成任务','page\x20generate-start\x20does\x20not\x20accept\x20--page-pattern.','write','70jdZyxC','currentStep','alias','status','nextAction','2wdLbcG','POST','generate-start','reused','4OkAXOF','manualResolutionRequired','24624AYpROC','dataset','1613320HdkszJ','SUCCESS','code','Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','page-pattern','7XftxWt','page-type','Start\x20async\x20Data\x20List\x20Page\x20generation\x20from\x20a\x20dataset','43989PvMVmC','taskId','复用已有生成任务','clientOperationId','operationId','name','296993dxnpzu','CRUD_PAGE_SET','source','This\x20command\x20always\x20generates\x20a\x20DATA_LIST\x20page\x20from\x20a\x20dataset.','boolean','275322BRrtXY','bool','precheck','2018912BYnWvW','Actually\x20execute\x20the\x20generation.\x20Without\x20this\x20flag,\x20only\x20a\x20dry-run\x20preview\x20is\x20shown.','apply','page'];a153_0x1348=function(){return _0x237fc8;};return a153_0x1348();}const a153_0x2b3962=a153_0x5976;(function(_0x1f33db,_0x2660d2){const _0x5bf8ff=a153_0x5976,_0x57a0e9=_0x1f33db();while(!![]){try{const _0x301f02=-parseInt(_0x5bf8ff(0xf5))/0x1+-parseInt(_0x5bf8ff(0xdf))/0x2*(parseInt(_0x5bf8ff(0xef))/0x3)+-parseInt(_0x5bf8ff(0xe3))/0x4*(parseInt(_0x5bf8ff(0xe7))/0x5)+-parseInt(_0x5bf8ff(0xfa))/0x6*(-parseInt(_0x5bf8ff(0xec))/0x7)+-parseInt(_0x5bf8ff(0xfd))/0x8+-parseInt(_0x5bf8ff(0x106))/0x9*(-parseInt(_0x5bf8ff(0xda))/0xa)+-parseInt(_0x5bf8ff(0xd5))/0xb*(-parseInt(_0x5bf8ff(0xe5))/0xc);if(_0x301f02===_0x2660d2)break;else _0x57a0e9['push'](_0x57a0e9['shift']());}catch(_0x3c73c3){_0x57a0e9['push'](_0x57a0e9['shift']());}}}(a153_0x1348,0x352f0));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a153_0x5976(_0x324682,_0x1773a7){_0x324682=_0x324682-0xd4;const _0x13489f=a153_0x1348();let _0x597682=_0x13489f[_0x324682];return _0x597682;}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':a153_0x2b3962(0x100),'command':a153_0x2b3962(0xe1),'description':a153_0x2b3962(0xee),'risk':a153_0x2b3962(0xd9),'defaultOutputFormat':'compress','rejectedFlags':[{'name':a153_0x2b3962(0xed),'message':'page\x20generate-start\x20does\x20not\x20accept\x20--page-type.','hint':a153_0x2b3962(0xf8)},{'name':a153_0x2b3962(0xeb),'message':a153_0x2b3962(0xd8),'hint':'DATA_LIST\x20currently\x20has\x20one\x20fixed\x20pattern:\x20CRUD_PAGE_SET.'}],'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a153_0x2b3962(0xdc),'type':'string','description':a153_0x2b3962(0xea)},{'name':a153_0x2b3962(0xff),'type':a153_0x2b3962(0xf9),'description':a153_0x2b3962(0xfe)}],async 'validate'(_0x29e2ac){validateDatasetSelector(_0x29e2ac);},async 'dryRun'(_0x579c30){const _0x398afc=a153_0x2b3962,_0x7ba569=await prepare(_0x579c30);return{'method':_0x398afc(0xe0),'url':'/smartapi/lovrabet/dataset/'+_0x7ba569['dataset'][_0x398afc(0xe9)]+_0x398afc(0x101),'body':{'appCode':_0x579c30['appCode'],'clientOperationId':_0x7ba569[_0x398afc(0xf2)]},'description':serializeDryRunDescription({'dataset':{'id':_0x7ba569[_0x398afc(0xe6)]['id'],'code':_0x7ba569[_0x398afc(0xe6)][_0x398afc(0xe9)],'name':_0x7ba569[_0x398afc(0xe6)][_0x398afc(0xf4)],'fieldCount':_0x7ba569[_0x398afc(0xe6)]['fieldCount']},'precheckSource':_0x7ba569[_0x398afc(0xd4)]?.[_0x398afc(0xf7)]??_0x398afc(0xd6),'action':_0x398afc(0xe1),'clientOperationId':_0x7ba569[_0x398afc(0xf2)],'plannedStatus':_0x7ba569[_0x398afc(0xfc)][_0x398afc(0xdd)],'reason':_0x7ba569['precheck']['message']})};},async 'execute'(_0x37774c){const _0x567f63=a153_0x2b3962;if(!_0x37774c[_0x567f63(0xfb)](_0x567f63(0xff))){const _0x127e8e=await pageGenerateStart[_0x567f63(0x103)](_0x37774c);return{'ok':!![],'message':'Dry-run\x20preview\x20(pass\x20--apply\x20to\x20execute\x20the\x20generation)','data':_0x127e8e};}const _0x1f7d47=await prepare(_0x37774c);if(!_0x1f7d47[_0x567f63(0xfc)]['allowGenerate'])return{'ok':![],'message':_0x1f7d47[_0x567f63(0xfc)]['message'],'data':{'datasetCode':_0x1f7d47[_0x567f63(0xe6)][_0x567f63(0xe9)],'pageType':'DATA_LIST','pagePattern':'CRUD_PAGE_SET','clientOperationId':_0x1f7d47[_0x567f63(0xf2)],'precheckSource':_0x1f7d47['dataListPageStatus']?.[_0x567f63(0xf7)]??_0x567f63(0xd6),'status':_0x1f7d47[_0x567f63(0xfc)]['status'],'manualResolutionRequired':_0x1f7d47[_0x567f63(0xfc)][_0x567f63(0xe4)],'nextAction':_0x1f7d47[_0x567f63(0xfc)][_0x567f63(0xde)],'query':{'command':buildDataListPageStatusQueryCommand(_0x1f7d47[_0x567f63(0xe6)][_0x567f63(0xe9)],_0x37774c[_0x567f63(0x104)])},'dataListPageStatus':_0x1f7d47[_0x567f63(0xd4)]}};const _0x11b127=await startGenerateDataListPages(_0x37774c[_0x567f63(0x104)],_0x1f7d47[_0x567f63(0xe6)][_0x567f63(0xe9)],{'clientOperationId':_0x1f7d47['clientOperationId']}),_0x59edb2=_0x11b127[_0x567f63(0xdd)]===_0x567f63(0xe8)||_0x11b127[_0x567f63(0xdd)]===_0x567f63(0x105)?await loadDataListPageStatusForGenerate(_0x37774c,_0x1f7d47[_0x567f63(0xe6)][_0x567f63(0xe9)]):null,_0x19cc3c=assessGenerateOperationState(_0x1f7d47[_0x567f63(0xe6)][_0x567f63(0xe9)],_0x11b127[_0x567f63(0xdd)],_0x59edb2);return{'ok':!![],'message':_0x11b127[_0x567f63(0xe2)]?_0x567f63(0xf1):_0x567f63(0xd7),'data':{'datasetCode':_0x1f7d47[_0x567f63(0xe6)]['code'],'appCode':_0x37774c[_0x567f63(0x104)],'pageType':'DATA_LIST','pagePattern':_0x567f63(0xf6),'taskId':_0x11b127[_0x567f63(0xf0)]??null,'operationId':_0x11b127['operationId']??null,'clientOperationId':_0x1f7d47[_0x567f63(0xf2)],'jobStatus':_0x11b127['status']??null,'progressRate':typeof _0x11b127[_0x567f63(0x102)]==='number'?_0x11b127[_0x567f63(0x102)]:null,'currentStep':_0x11b127[_0x567f63(0xdb)]??null,'reused':_0x11b127[_0x567f63(0xe2)]===!![],'status':_0x19cc3c['status'],'manualResolutionRequired':_0x19cc3c[_0x567f63(0xe4)],'nextAction':_0x19cc3c[_0x567f63(0xde)],'query':{'command':buildPageGenerateOperationStatusQueryCommand(_0x1f7d47[_0x567f63(0xe6)]['code'],{'appCode':_0x37774c['appCode'],'taskId':_0x11b127[_0x567f63(0xf0)],'operationId':_0x11b127[_0x567f63(0xf3)],'clientOperationId':_0x1f7d47[_0x567f63(0xf2)]})},'dataListPageStatus':_0x59edb2}};}};async function prepare(_0x58510e){const _0x4c7e54=a153_0x2b3962,_0x594c8a=await loadDatasetDetailForPage(_0x58510e),_0x1dd669=await loadDataListPageStatusForGenerate(_0x58510e,_0x594c8a[_0x4c7e54(0xe9)]),_0x5306cf=getUndeletedRelatedPages(_0x594c8a);return{'dataset':_0x594c8a,'dataListPageStatus':_0x1dd669,'clientOperationId':createPageGenerateClientOperationId(),'precheck':assessDataListPageState(_0x594c8a[_0x4c7e54(0xe9)],_0x1dd669,{'fallbackUndeletedPages':_0x5306cf})};}
|