@lovrabet/rabetbase-cli 2.3.11-beta.1 → 2.3.11

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.
Files changed (260) hide show
  1. package/lib/api/api-doc.js +1 -1
  2. package/lib/api/fetch-model-list.js +1 -1
  3. package/lib/api/generate-api-file.js +1 -1
  4. package/lib/auth/auth-server-ui.js +1 -1
  5. package/lib/auth/auth-server.js +1 -1
  6. package/lib/auth/constant.js +1 -1
  7. package/lib/auth/get-cookie.js +1 -1
  8. package/lib/auth/get-session-user.js +1 -1
  9. package/lib/auth/is-session-valid.js +1 -1
  10. package/lib/auth/login-success-html.js +1 -1
  11. package/lib/auth/logout.js +1 -1
  12. package/lib/cli-flags.js +1 -1
  13. package/lib/cli.js +1 -1
  14. package/lib/commands/api/generate.js +1 -1
  15. package/lib/commands/api/index.js +1 -1
  16. package/lib/commands/api/list.js +1 -1
  17. package/lib/commands/api/pull.js +1 -1
  18. package/lib/commands/api/shared.js +1 -1
  19. package/lib/commands/app/add.js +1 -1
  20. package/lib/commands/app/index.js +1 -1
  21. package/lib/commands/app/list.js +1 -1
  22. package/lib/commands/app/remote-directory.js +1 -1
  23. package/lib/commands/app/remove.js +1 -1
  24. package/lib/commands/app/shared.js +1 -1
  25. package/lib/commands/app-config/delete.js +1 -1
  26. package/lib/commands/app-config/get.js +1 -1
  27. package/lib/commands/app-config/index.js +1 -1
  28. package/lib/commands/app-config/list.js +1 -1
  29. package/lib/commands/app-config/set.js +1 -1
  30. package/lib/commands/app-config/shared.js +1 -1
  31. package/lib/commands/auth/index.js +1 -1
  32. package/lib/commands/bff/create.js +1 -1
  33. package/lib/commands/bff/delete.js +1 -1
  34. package/lib/commands/bff/detail.js +1 -1
  35. package/lib/commands/bff/index.js +1 -1
  36. package/lib/commands/bff/list.js +1 -1
  37. package/lib/commands/bff/pull.js +1 -1
  38. package/lib/commands/bff/push.js +1 -1
  39. package/lib/commands/bff/status.js +1 -1
  40. package/lib/commands/cli-skill/index.js +1 -1
  41. package/lib/commands/cli-update.js +1 -1
  42. package/lib/commands/codegen/index.js +1 -1
  43. package/lib/commands/codegen/sdk.js +1 -1
  44. package/lib/commands/codegen/sql.js +1 -1
  45. package/lib/commands/common/app-registry.js +1 -1
  46. package/lib/commands/common/app-selector.js +1 -1
  47. package/lib/commands/common/async-task.js +1 -1
  48. package/lib/commands/common/dry-run.js +1 -1
  49. package/lib/commands/common/flags.js +1 -1
  50. package/lib/commands/common/local-file.js +1 -1
  51. package/lib/commands/common/validate.js +1 -1
  52. package/lib/commands/config/get.js +1 -1
  53. package/lib/commands/config/index.js +1 -1
  54. package/lib/commands/config/list.js +1 -1
  55. package/lib/commands/config/set.js +1 -1
  56. package/lib/commands/config/shared.js +1 -1
  57. package/lib/commands/data/filter.js +1 -1
  58. package/lib/commands/data/getOne.js +1 -1
  59. package/lib/commands/data/index.js +1 -1
  60. package/lib/commands/data/shared.js +1 -1
  61. package/lib/commands/dataset/business-group-update.js +1 -1
  62. package/lib/commands/dataset/capability.js +1 -1
  63. package/lib/commands/dataset/delete.js +1 -1
  64. package/lib/commands/dataset/detail.js +1 -1
  65. package/lib/commands/dataset/extend-update.js +1 -1
  66. package/lib/commands/dataset/field-update.js +1 -1
  67. package/lib/commands/dataset/generate.js +1 -1
  68. package/lib/commands/dataset/index.js +1 -1
  69. package/lib/commands/dataset/list.js +1 -1
  70. package/lib/commands/dataset/operations.js +1 -1
  71. package/lib/commands/dataset/relation-audit.js +1 -1
  72. package/lib/commands/dataset/relation-create.js +1 -1
  73. package/lib/commands/dataset/relation-delete.js +1 -1
  74. package/lib/commands/dataset/relation-shared.js +1 -1
  75. package/lib/commands/dataset/relation-update.js +1 -1
  76. package/lib/commands/dataset/relations.js +1 -1
  77. package/lib/commands/dataset/rename.js +1 -1
  78. package/lib/commands/dataset/restore.js +1 -1
  79. package/lib/commands/db/analysis-batching.js +1 -1
  80. package/lib/commands/db/analyze-batch-plan.js +1 -1
  81. package/lib/commands/db/analyze-cancel.js +1 -1
  82. package/lib/commands/db/analyze-start.js +1 -1
  83. package/lib/commands/db/analyze-status.js +1 -1
  84. package/lib/commands/db/create.js +1 -1
  85. package/lib/commands/db/delete.js +1 -1
  86. package/lib/commands/db/detail.js +1 -1
  87. package/lib/commands/db/diff.js +1 -1
  88. package/lib/commands/db/index.js +1 -1
  89. package/lib/commands/db/list.js +1 -1
  90. package/lib/commands/db/shared.js +1 -1
  91. package/lib/commands/db/tables.js +1 -1
  92. package/lib/commands/db/test.js +1 -1
  93. package/lib/commands/db/update.js +1 -1
  94. package/lib/commands/doctor.js +1 -1
  95. package/lib/commands/file/index.js +1 -1
  96. package/lib/commands/init/index.js +1 -1
  97. package/lib/commands/issue/index.js +1 -1
  98. package/lib/commands/issue/nudge.js +1 -1
  99. package/lib/commands/issue/report.js +1 -1
  100. package/lib/commands/issue/shared.js +1 -1
  101. package/lib/commands/logs/index.js +1 -1
  102. package/lib/commands/menu/delete.js +1 -1
  103. package/lib/commands/menu/external-link-create.js +1 -1
  104. package/lib/commands/menu/group-create.js +1 -1
  105. package/lib/commands/menu/group-update.js +1 -1
  106. package/lib/commands/menu/index.js +1 -1
  107. package/lib/commands/menu/list.js +1 -1
  108. package/lib/commands/menu/move.js +1 -1
  109. package/lib/commands/menu/regroup-start.js +1 -1
  110. package/lib/commands/menu/shared/compare-table.js +1 -1
  111. package/lib/commands/menu/shared/delete-plan.js +1 -1
  112. package/lib/commands/menu/shared/facts.js +1 -1
  113. package/lib/commands/menu/shared/index.js +1 -1
  114. package/lib/commands/menu/shared/inquirer.js +1 -1
  115. package/lib/commands/menu/shared/local-pages.js +1 -1
  116. package/lib/commands/menu/shared/logic.js +1 -1
  117. package/lib/commands/menu/shared/mutations.js +1 -1
  118. package/lib/commands/menu/shared/service.js +1 -1
  119. package/lib/commands/menu/shared/sync-core.js +1 -1
  120. package/lib/commands/menu/shared/update-core.js +1 -1
  121. package/lib/commands/menu/shared/valid-url.js +1 -1
  122. package/lib/commands/menu/sync.js +1 -1
  123. package/lib/commands/menu/update.js +1 -1
  124. package/lib/commands/notification/config-list.js +1 -1
  125. package/lib/commands/notification/index.js +1 -1
  126. package/lib/commands/page/generate-start.js +1 -1
  127. package/lib/commands/page/generate-status.js +1 -1
  128. package/lib/commands/page/index.js +1 -1
  129. package/lib/commands/page/pull.js +1 -1
  130. package/lib/commands/page/push.js +1 -1
  131. package/lib/commands/page/relation-audit.js +1 -1
  132. package/lib/commands/page/shared.js +1 -1
  133. package/lib/commands/page/standard-page-status.js +1 -1
  134. package/lib/commands/page/sync.js +1 -1
  135. package/lib/commands/permit/index.js +1 -1
  136. package/lib/commands/permit/page-get.js +1 -1
  137. package/lib/commands/permit/page-set.js +1 -1
  138. package/lib/commands/permit/role-apis-set.js +1 -1
  139. package/lib/commands/permit/role-menus-set.js +1 -1
  140. package/lib/commands/permit/role-menus.js +1 -1
  141. package/lib/commands/permit/shared.js +1 -1
  142. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  143. package/lib/commands/project/create/format-elapsed.js +1 -1
  144. package/lib/commands/project/create/main.js +1 -1
  145. package/lib/commands/project/create/non-interactive.js +1 -1
  146. package/lib/commands/project/create/project-template-path.js +1 -1
  147. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  148. package/lib/commands/project/create/use-format-code.js +1 -1
  149. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  150. package/lib/commands/project/index.js +1 -1
  151. package/lib/commands/project/init.js +1 -1
  152. package/lib/commands/project/upgrade.js +1 -1
  153. package/lib/commands/registry.js +1 -1
  154. package/lib/commands/role/create.js +1 -1
  155. package/lib/commands/role/delete.js +1 -1
  156. package/lib/commands/role/detail.js +1 -1
  157. package/lib/commands/role/index.js +1 -1
  158. package/lib/commands/role/list.js +1 -1
  159. package/lib/commands/role/shared.js +1 -1
  160. package/lib/commands/role/update.js +1 -1
  161. package/lib/commands/role/user-add.js +1 -1
  162. package/lib/commands/role/user-remove.js +1 -1
  163. package/lib/commands/role/user-resolve.js +1 -1
  164. package/lib/commands/run/index.js +1 -1
  165. package/lib/commands/schema.js +1 -1
  166. package/lib/commands/sql/create.js +1 -1
  167. package/lib/commands/sql/delete.js +1 -1
  168. package/lib/commands/sql/detail.js +1 -1
  169. package/lib/commands/sql/exec.js +1 -1
  170. package/lib/commands/sql/index.js +1 -1
  171. package/lib/commands/sql/list.js +1 -1
  172. package/lib/commands/sql/pull.js +1 -1
  173. package/lib/commands/sql/push.js +1 -1
  174. package/lib/commands/sql/save.js +1 -1
  175. package/lib/commands/sql/shared.js +1 -1
  176. package/lib/commands/sql/status.js +1 -1
  177. package/lib/commands/sql/validate.js +1 -1
  178. package/lib/commands/task/index.js +1 -1
  179. package/lib/commands/task/status.js +1 -1
  180. package/lib/commands/workspace/add.js +1 -1
  181. package/lib/commands/workspace/index.js +1 -1
  182. package/lib/commands/workspace/remove.js +1 -1
  183. package/lib/config/schema.js +1 -1
  184. package/lib/constant/cdn.js +1 -1
  185. package/lib/constant/cli.js +1 -1
  186. package/lib/constant/defaults.js +1 -1
  187. package/lib/constant/domain.js +1 -1
  188. package/lib/constant/env.js +1 -1
  189. package/lib/constant/output.js +1 -1
  190. package/lib/constant/paths.js +1 -1
  191. package/lib/constant/risk.js +1 -1
  192. package/lib/context/app-resolver.js +1 -1
  193. package/lib/context/auth-resolver.js +1 -1
  194. package/lib/context/config-loader.js +1 -1
  195. package/lib/context.js +1 -1
  196. package/lib/core/alias-resolver.js +1 -1
  197. package/lib/core/api-client.js +1 -1
  198. package/lib/core/bff/config.js +1 -1
  199. package/lib/core/bff/file-system.js +1 -1
  200. package/lib/core/bff/hash.js +1 -1
  201. package/lib/core/bff/lock.js +1 -1
  202. package/lib/core/bff/utils.js +1 -1
  203. package/lib/core/db-resolver.js +1 -1
  204. package/lib/core/page/file-system.js +1 -1
  205. package/lib/core/page/hash.js +1 -1
  206. package/lib/core/page/lock.js +1 -1
  207. package/lib/core/sql-index-auditor.js +1 -1
  208. package/lib/core/sql-sync/config.js +1 -1
  209. package/lib/core/sql-sync/file-system.js +1 -1
  210. package/lib/core/sql-sync/hash.js +1 -1
  211. package/lib/core/sql-sync/lock.js +1 -1
  212. package/lib/core/sql-sync/utils.js +1 -1
  213. package/lib/core/sql-validator.js +1 -1
  214. package/lib/errors.js +1 -1
  215. package/lib/framework/build-all-flags.js +1 -1
  216. package/lib/framework/error-output.js +1 -1
  217. package/lib/framework/explicit-yes.js +1 -1
  218. package/lib/framework/flags.js +1 -1
  219. package/lib/framework/help.js +1 -1
  220. package/lib/framework/index.js +1 -1
  221. package/lib/framework/output.js +1 -1
  222. package/lib/framework/response.js +1 -1
  223. package/lib/framework/runner-alias.js +1 -1
  224. package/lib/framework/runner.js +1 -1
  225. package/lib/framework/schema-export.js +1 -1
  226. package/lib/framework/types.js +1 -1
  227. package/lib/generated/build-info.js +1 -1
  228. package/lib/help.js +1 -1
  229. package/lib/skills/main.js +1 -1
  230. package/lib/skills/npx-skills-add.js +1 -1
  231. package/lib/telemetry/cli-command-trace.js +1 -1
  232. package/lib/telemetry/cli-help-trace.js +1 -1
  233. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  234. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  235. package/lib/telemetry/send-cli-trace-log.js +1 -1
  236. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  237. package/lib/utils/ai_config.js +1 -1
  238. package/lib/utils/apply-jq-filter.js +1 -1
  239. package/lib/utils/cdn-config.js +1 -1
  240. package/lib/utils/check-sdk-version.js +1 -1
  241. package/lib/utils/cli-version-check.js +1 -1
  242. package/lib/utils/cli-version-policy.js +1 -1
  243. package/lib/utils/config.js +1 -1
  244. package/lib/utils/copy-directory.js +1 -1
  245. package/lib/utils/entity-with-id.js +1 -1
  246. package/lib/utils/file-utils.js +1 -1
  247. package/lib/utils/guides-cdn.js +1 -1
  248. package/lib/utils/http-client.js +1 -1
  249. package/lib/utils/is-non-interactive.js +1 -1
  250. package/lib/utils/logger.js +1 -1
  251. package/lib/utils/params.js +1 -1
  252. package/lib/utils/platform.js +1 -1
  253. package/lib/utils/rules-cdn.js +1 -1
  254. package/lib/utils/sleep.js +1 -1
  255. package/lib/utils/template-replacer.js +1 -1
  256. package/lib/utils/update-notice.js +1 -1
  257. package/lib/utils/version.js +1 -1
  258. package/lib/utils/with-active-cookie.js +1 -1
  259. package/lib/utils/write-cli-side-channel.js +1 -1
  260. package/package.json +1 -1
@@ -1 +1 @@
1
- function a52_0x5c3c(_0x47c12a,_0x5412a3){_0x47c12a=_0x47c12a-0x88;const _0x4d1cc2=a52_0x4d1c();let _0x5c3ceb=_0x4d1cc2[_0x47c12a];return _0x5c3ceb;}function a52_0x4d1c(){const _0x2e067d=['1546140LafAzO','5987130qRvHZb','2192057YAQYvV','1827448Ngqatd','264723ARAjZI','9zmJArz','470740DjZjSi','165189XPESEM','6EPMwxk','2igANHn'];a52_0x4d1c=function(){return _0x2e067d;};return a52_0x4d1c();}(function(_0x561b83,_0xaf5a5){const _0x301cc1=a52_0x5c3c,_0x5b6bbf=_0x561b83();while(!![]){try{const _0x2ef2a6=parseInt(_0x301cc1(0x88))/0x1+-parseInt(_0x301cc1(0x8a))/0x2*(-parseInt(_0x301cc1(0x8f))/0x3)+parseInt(_0x301cc1(0x91))/0x4+parseInt(_0x301cc1(0x8b))/0x5+parseInt(_0x301cc1(0x89))/0x6*(parseInt(_0x301cc1(0x8d))/0x7)+-parseInt(_0x301cc1(0x8e))/0x8+-parseInt(_0x301cc1(0x90))/0x9*(parseInt(_0x301cc1(0x8c))/0xa);if(_0x2ef2a6===_0xaf5a5)break;else _0x5b6bbf['push'](_0x5b6bbf['shift']());}catch(_0x136c14){_0x5b6bbf['push'](_0x5b6bbf['shift']());}}}(a52_0x4d1c,0x289ce));import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';import{configSetDefinition}from'../../commands/config/set.js';export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
1
+ function a52_0x1cb1(){const _0x1dff36=['77UJVhzr','1931955qikjDX','1087836dgZASW','1310868BQQnNw','194344SUYupZ','143291tSXueI','4uARlwl','7664931pNpcyr','459198jsYBaB'];a52_0x1cb1=function(){return _0x1dff36;};return a52_0x1cb1();}(function(_0x5c3f5b,_0x54d7af){const _0x45d825=a52_0x2463,_0x512054=_0x5c3f5b();while(!![]){try{const _0x3a655d=-parseInt(_0x45d825(0xdf))/0x1*(parseInt(_0x45d825(0xe0))/0x2)+-parseInt(_0x45d825(0xd9))/0x3+parseInt(_0x45d825(0xdc))/0x4+-parseInt(_0x45d825(0xdb))/0x5+parseInt(_0x45d825(0xdd))/0x6+-parseInt(_0x45d825(0xda))/0x7*(parseInt(_0x45d825(0xde))/0x8)+parseInt(_0x45d825(0xe1))/0x9;if(_0x3a655d===_0x54d7af)break;else _0x512054['push'](_0x512054['shift']());}catch(_0x1b9cdf){_0x512054['push'](_0x512054['shift']());}}}(a52_0x1cb1,0x3cc02));function a52_0x2463(_0xecaa50,_0x446cde){_0xecaa50=_0xecaa50-0xd9;const _0x1cb1bc=a52_0x1cb1();let _0x24631d=_0x1cb1bc[_0xecaa50];return _0x24631d;}import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';import{configSetDefinition}from'../../commands/config/set.js';export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
@@ -1 +1 @@
1
- const a53_0x31a741=a53_0x20c4;(function(_0x128cd8,_0x1f83d8){const _0x4d4410=a53_0x20c4,_0x25c539=_0x128cd8();while(!![]){try{const _0x54e2ea=parseInt(_0x4d4410(0xe4))/0x1+parseInt(_0x4d4410(0xdc))/0x2+parseInt(_0x4d4410(0xe3))/0x3*(parseInt(_0x4d4410(0xdf))/0x4)+parseInt(_0x4d4410(0xd4))/0x5+-parseInt(_0x4d4410(0xda))/0x6+-parseInt(_0x4d4410(0xd9))/0x7+parseInt(_0x4d4410(0xdb))/0x8*(parseInt(_0x4d4410(0xdd))/0x9);if(_0x54e2ea===_0x1f83d8)break;else _0x25c539['push'](_0x25c539['shift']());}catch(_0x191819){_0x25c539['push'](_0x25c539['shift']());}}}(a53_0x2046,0x2db26));function a53_0x20c4(_0x21de97,_0x1222f4){_0x21de97=_0x21de97-0xd4;const _0x2046ee=a53_0x2046();let _0x20c4c1=_0x2046ee[_0x21de97];return _0x20c4c1;}function a53_0x2046(){const _0x6e7161=['boolean','read','3WJmFEg','6712laIkXG','265020seZUpy','List\x20all\x20config\x20values','Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','config','global','872781uiVNuK','1751454HwzSMW','1566184yAhjZs','650076veFjzW','9nFHvuG','list','92956EPmVsP','bool'];a53_0x2046=function(){return _0x6e7161;};return a53_0x2046();}import{readScopedConfig}from'../../commands/config/shared.js';import{readConfig}from'../../utils/config.js';async function execute(_0x567de8){const _0x434c51=a53_0x20c4,_0x263ebb=_0x567de8[_0x434c51(0xe0)]('global')?readScopedConfig(_0x434c51(0xd8)):readConfig();return{'ok':!![],'data':_0x263ebb};}export const configListDefinition={'service':a53_0x31a741(0xd7),'command':a53_0x31a741(0xde),'description':a53_0x31a741(0xd5),'risk':a53_0x31a741(0xe2),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'global','type':a53_0x31a741(0xe1),'description':a53_0x31a741(0xd6),'default':![]}],'execute':execute};
1
+ const a53_0xa480a7=a53_0x58bc;(function(_0x22899d,_0x47ed8d){const _0x48e562=a53_0x58bc,_0x350dbd=_0x22899d();while(!![]){try{const _0x21b8d6=parseInt(_0x48e562(0xf3))/0x1+-parseInt(_0x48e562(0xec))/0x2*(-parseInt(_0x48e562(0xef))/0x3)+parseInt(_0x48e562(0xf6))/0x4*(-parseInt(_0x48e562(0xf8))/0x5)+parseInt(_0x48e562(0xea))/0x6+parseInt(_0x48e562(0xf5))/0x7+-parseInt(_0x48e562(0xed))/0x8+parseInt(_0x48e562(0xee))/0x9*(-parseInt(_0x48e562(0xf9))/0xa);if(_0x21b8d6===_0x47ed8d)break;else _0x350dbd['push'](_0x350dbd['shift']());}catch(_0x20f8cd){_0x350dbd['push'](_0x350dbd['shift']());}}}(a53_0x48c2,0xf3224));function a53_0x58bc(_0x214c37,_0x26ba33){_0x214c37=_0x214c37-0xea;const _0x48c201=a53_0x48c2();let _0x58bc5e=_0x48c201[_0x214c37];return _0x58bc5e;}import{readScopedConfig}from'../../commands/config/shared.js';function a53_0x48c2(){const _0x148658=['37938lfmQOu','8939400QFJcLg','18601290gOfLBB','207YnQdbL','bool','config','read','1265529RpXvKl','global','7859439mnPfgo','82728MWmXFj','Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','70esIyUb','10VVStRd','4634952zUwyuJ','List\x20all\x20config\x20values'];a53_0x48c2=function(){return _0x148658;};return a53_0x48c2();}import{readConfig}from'../../utils/config.js';async function execute(_0x35dc1f){const _0x3d1492=a53_0x58bc,_0x17a52d=_0x35dc1f[_0x3d1492(0xf0)](_0x3d1492(0xf4))?readScopedConfig(_0x3d1492(0xf4)):readConfig();return{'ok':!![],'data':_0x17a52d};}export const configListDefinition={'service':a53_0xa480a7(0xf1),'command':'list','description':a53_0xa480a7(0xeb),'risk':a53_0xa480a7(0xf2),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a53_0xa480a7(0xf4),'type':'boolean','description':a53_0xa480a7(0xf7),'default':![]}],'execute':execute};
@@ -1 +1 @@
1
- const a54_0x370437=a54_0x44f8;(function(_0x28975f,_0xe19d71){const _0x2df210=a54_0x44f8,_0x132858=_0x28975f();while(!![]){try{const _0x50bd0c=parseInt(_0x2df210(0x199))/0x1+-parseInt(_0x2df210(0x1a0))/0x2+parseInt(_0x2df210(0x196))/0x3*(parseInt(_0x2df210(0x182))/0x4)+parseInt(_0x2df210(0x18e))/0x5+parseInt(_0x2df210(0x194))/0x6*(parseInt(_0x2df210(0x17f))/0x7)+-parseInt(_0x2df210(0x19c))/0x8*(parseInt(_0x2df210(0x183))/0x9)+parseInt(_0x2df210(0x18b))/0xa;if(_0x50bd0c===_0xe19d71)break;else _0x132858['push'](_0x132858['shift']());}catch(_0x2da37e){_0x132858['push'](_0x132858['shift']());}}}(a54_0x3357,0x32510));import{CliErrors}from'../../errors.js';function a54_0x3357(){const _0x3aea8c=['Set\x20a\x20config\x20value','392FPGtPr','1135629tOuLNW','Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.','Global','\x20workspace\x20use\x20--app\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','apps','Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.','includes','840800fqdpOJ','value','keys','954200miRole','Config\x20value\x20is\x20invalid\x20or\x20too\x20long.','\x20app\x20add\x20<name>\x20--appcode\x20','global','Use\x20`','join','932628WeFYBu','Invalid\x20locale\x20value.','7023bOJXxg','\x22.\x20Allowed:\x20','Invalid\x20value\x20for\x20\x22','108451mmvnkq','Project','string','16rwYImY','write','env','\x20set\x20to:\x20','619538pfrryL','key','length','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','locale','\x22\x20is\x20not\x20settable.','app','appcode','str','boolean','Usage:\x20','Settable\x20top-level\x20keys:\x20','\x20appcode\x20set\x20to:\x20','Missing\x20key.','validation','Missing\x20value.','riskLevel','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','Top-level\x20key\x20\x22','7nnoYOA','\x20(stored\x20as\x20apps\x20+\x20defaultApp)'];a54_0x3357=function(){return _0x3aea8c;};return a54_0x3357();}import{buildCanonicalProjectConfig}from'../../config/schema.js';import{CLI_BIN_NAME,CONFIG_ENUM_VALUES,getConfigCommandKeyDescription,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale,resolveWriteScope,readScopedConfig,writeScopedConfig}from'../../commands/config/shared.js';function a54_0x44f8(_0xdb1710,_0x2ec75c){_0xdb1710=_0xdb1710-0x178;const _0x335712=a54_0x3357();let _0x44f8c9=_0x335712[_0xdb1710];return _0x44f8c9;}import{normalizeEnv,isProduction,isDaily}from'../../constant/env.js';async function execute(_0xa7904b){const _0x5e2200=a54_0x44f8,_0x229f68=_0xa7904b['str'](_0x5e2200(0x1a1)),_0x2f45b6=_0xa7904b[_0x5e2200(0x1a8)]('value');if(!_0x229f68)throw CliErrors[_0x5e2200(0x17a)](_0x5e2200(0x179),_0x5e2200(0x1aa)+CLI_BIN_NAME+_0x5e2200(0x17d));if(_0x2f45b6===undefined||_0x2f45b6==='')throw CliErrors[_0x5e2200(0x17a)](_0x5e2200(0x17b),_0x5e2200(0x1aa)+CLI_BIN_NAME+_0x5e2200(0x17d));if(_0x2f45b6[_0x5e2200(0x1a2)]>0x1f4)throw CliErrors['validation'](_0x5e2200(0x18f));if(!isTopLevelConfigKey(_0x229f68))throw CliErrors[_0x5e2200(0x17a)](_0x5e2200(0x17e)+_0x229f68+_0x5e2200(0x1a5),_0x5e2200(0x1ab)+getTopLevelConfigKeySummary());if(_0x229f68===_0x5e2200(0x17c))throw CliErrors['validation'](_0x5e2200(0x1a3));if(CONFIG_ENUM_VALUES[_0x229f68]&&!CONFIG_ENUM_VALUES[_0x229f68][_0x5e2200(0x18a)](_0x2f45b6))throw CliErrors[_0x5e2200(0x17a)](_0x5e2200(0x198)+_0x229f68+_0x5e2200(0x197)+CONFIG_ENUM_VALUES[_0x229f68][_0x5e2200(0x193)](',\x20'));if(_0x229f68===_0x5e2200(0x1a4)&&!normalizeLocale(_0x2f45b6))throw CliErrors['validation'](_0x5e2200(0x195),'Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US');const _0x1de990={'global':_0xa7904b['bool'](_0x5e2200(0x191))},_0x2655f0=resolveWriteScope(_0x1de990),_0x3edc93=readScopedConfig(_0x2655f0);let _0x9b43dc=_0x229f68,_0x5e1cbd=_0x2f45b6;_0x229f68===_0x5e2200(0x1a6)&&(_0x9b43dc=_0x5e2200(0x1a7),delete _0x3edc93[_0x5e2200(0x1a6)]);_0x229f68===_0x5e2200(0x1a4)&&(_0x5e1cbd=normalizeLocale(_0x2f45b6));if(_0x229f68==='env'){_0x5e1cbd=normalizeEnv(_0x2f45b6);if(!isProduction(_0x5e1cbd)&&!isDaily(_0x5e1cbd))throw CliErrors[_0x5e2200(0x17a)](_0x5e2200(0x187),_0x5e2200(0x184));}if(_0x229f68===_0x5e2200(0x1a7)){const _0x429a9c=_0x3edc93['apps']&&typeof _0x3edc93['apps']==='object'?Object[_0x5e2200(0x18d)](_0x3edc93[_0x5e2200(0x188)]):[];if(_0x429a9c[_0x5e2200(0x1a2)]>0x0)throw CliErrors[_0x5e2200(0x17a)](_0x5e2200(0x189),_0x5e2200(0x192)+CLI_BIN_NAME+_0x5e2200(0x190)+_0x5e1cbd+'`,\x20`'+CLI_BIN_NAME+_0x5e2200(0x186));const _0x20b61a=buildCanonicalProjectConfig({..._0x3edc93},{'appCodes':[_0x5e1cbd],'env':typeof _0x3edc93[_0x5e2200(0x19e)]===_0x5e2200(0x19b)?_0x3edc93[_0x5e2200(0x19e)]:undefined});writeScopedConfig(_0x20b61a,_0x2655f0);const _0x1cdeff=_0x2655f0==='global'?'Global':_0x5e2200(0x19a);return{'ok':!![],'message':'✓\x20'+_0x1cdeff+_0x5e2200(0x178)+_0x5e1cbd+_0x5e2200(0x180)};}_0x3edc93[_0x9b43dc]=_0x5e1cbd,writeScopedConfig(_0x3edc93,_0x2655f0);const _0x30162e=_0x2655f0===_0x5e2200(0x191)?_0x5e2200(0x185):_0x5e2200(0x19a);return{'ok':!![],'message':'✓\x20'+_0x30162e+'\x20'+_0x9b43dc+_0x5e2200(0x19f)+_0x5e1cbd};}export const configSetDefinition={'service':'config','command':'set','description':a54_0x370437(0x181),'risk':a54_0x370437(0x19d),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a54_0x370437(0x1a1),'type':'string','description':getConfigCommandKeyDescription(),'required':!![]},{'name':a54_0x370437(0x18c),'type':a54_0x370437(0x19b),'description':'Config\x20value','required':!![]},{'name':'global','type':a54_0x370437(0x1a9),'description':'Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','default':![]}],'execute':execute};
1
+ function a54_0x4da9(_0x21ae4c,_0x525121){_0x21ae4c=_0x21ae4c-0xa1;const _0x3119d7=a54_0x3119();let _0x4da99e=_0x3119d7[_0x21ae4c];return _0x4da99e;}const a54_0x51c154=a54_0x4da9;(function(_0x233f39,_0xb9a769){const _0x1a5390=a54_0x4da9,_0x4b1ed6=_0x233f39();while(!![]){try{const _0x2d961d=-parseInt(_0x1a5390(0xb1))/0x1+parseInt(_0x1a5390(0xc8))/0x2+-parseInt(_0x1a5390(0xce))/0x3+parseInt(_0x1a5390(0xbe))/0x4+-parseInt(_0x1a5390(0xcd))/0x5+parseInt(_0x1a5390(0xa8))/0x6+parseInt(_0x1a5390(0xae))/0x7;if(_0x2d961d===_0xb9a769)break;else _0x4b1ed6['push'](_0x4b1ed6['shift']());}catch(_0x137d89){_0x4b1ed6['push'](_0x4b1ed6['shift']());}}}(a54_0x3119,0xeb260));import{CliErrors}from'../../errors.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';function a54_0x3119(){const _0x1b5143=['Set\x20a\x20config\x20value','config','4816836vXavAC','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','Invalid\x20locale\x20value.','validation','\x20workspace\x20use\x20--app\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.','string','5695431xIXPSk','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','Invalid\x20value\x20for\x20\x22','1391085UYyKIz','\x20app\x20add\x20<name>\x20--appcode\x20','Config\x20value','set','Config\x20value\x20is\x20invalid\x20or\x20too\x20long.','locale','includes','Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.','apps','Top-level\x20key\x20\x22','Project','env','Global','7609664QFarfW','value','bool','Use\x20`','Missing\x20key.','\x22.\x20Allowed:\x20','`,\x20`','Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','join','object','680812vRqhXY','Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.','\x20set\x20to:\x20','str','global','3693705jkSWVB','2298801hGzUnO','appcode','Usage:\x20','Settable\x20top-level\x20keys:\x20','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','\x22\x20is\x20not\x20settable.','key','app'];a54_0x3119=function(){return _0x1b5143;};return a54_0x3119();}import{CLI_BIN_NAME,CONFIG_ENUM_VALUES,getConfigCommandKeyDescription,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale,resolveWriteScope,readScopedConfig,writeScopedConfig}from'../../commands/config/shared.js';import{normalizeEnv,isProduction,isDaily}from'../../constant/env.js';async function execute(_0x1a5842){const _0x39816f=a54_0x4da9,_0xa80379=_0x1a5842[_0x39816f(0xcb)](_0x39816f(0xa4)),_0x2b4c44=_0x1a5842[_0x39816f(0xcb)](_0x39816f(0xbf));if(!_0xa80379)throw CliErrors[_0x39816f(0xab)](_0x39816f(0xc2),_0x39816f(0xd0)+CLI_BIN_NAME+_0x39816f(0xa9));if(_0x2b4c44===undefined||_0x2b4c44==='')throw CliErrors[_0x39816f(0xab)]('Missing\x20value.',_0x39816f(0xd0)+CLI_BIN_NAME+_0x39816f(0xa9));if(_0x2b4c44['length']>0x1f4)throw CliErrors[_0x39816f(0xab)](_0x39816f(0xb5));if(!isTopLevelConfigKey(_0xa80379))throw CliErrors[_0x39816f(0xab)](_0x39816f(0xba)+_0xa80379+_0x39816f(0xa3),_0x39816f(0xa1)+getTopLevelConfigKeySummary());if(_0xa80379==='riskLevel')throw CliErrors[_0x39816f(0xab)]('\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.');if(CONFIG_ENUM_VALUES[_0xa80379]&&!CONFIG_ENUM_VALUES[_0xa80379][_0x39816f(0xb7)](_0x2b4c44))throw CliErrors[_0x39816f(0xab)](_0x39816f(0xb0)+_0xa80379+_0x39816f(0xc3)+CONFIG_ENUM_VALUES[_0xa80379][_0x39816f(0xc6)](',\x20'));if(_0xa80379===_0x39816f(0xb6)&&!normalizeLocale(_0x2b4c44))throw CliErrors['validation'](_0x39816f(0xaa),'Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US');const _0x28df95={'global':_0x1a5842[_0x39816f(0xc0)]('global')},_0x3d8f34=resolveWriteScope(_0x28df95),_0x2f8e22=readScopedConfig(_0x3d8f34);let _0x251834=_0xa80379,_0x5e5224=_0x2b4c44;_0xa80379==='app'&&(_0x251834=_0x39816f(0xcf),delete _0x2f8e22[_0x39816f(0xa5)]);_0xa80379===_0x39816f(0xb6)&&(_0x5e5224=normalizeLocale(_0x2b4c44));if(_0xa80379===_0x39816f(0xbc)){_0x5e5224=normalizeEnv(_0x2b4c44);if(!isProduction(_0x5e5224)&&!isDaily(_0x5e5224))throw CliErrors[_0x39816f(0xab)](_0x39816f(0xaf),_0x39816f(0xb8));}if(_0xa80379==='appcode'){const _0x5cb71e=_0x2f8e22['apps']&&typeof _0x2f8e22[_0x39816f(0xb9)]===_0x39816f(0xc7)?Object['keys'](_0x2f8e22['apps']):[];if(_0x5cb71e['length']>0x0)throw CliErrors[_0x39816f(0xab)](_0x39816f(0xc9),_0x39816f(0xc1)+CLI_BIN_NAME+_0x39816f(0xb2)+_0x5e5224+_0x39816f(0xc4)+CLI_BIN_NAME+_0x39816f(0xac));const _0x39efec=buildCanonicalProjectConfig({..._0x2f8e22},{'appCodes':[_0x5e5224],'env':typeof _0x2f8e22['env']==='string'?_0x2f8e22[_0x39816f(0xbc)]:undefined});writeScopedConfig(_0x39efec,_0x3d8f34);const _0x537d1b=_0x3d8f34===_0x39816f(0xcc)?_0x39816f(0xbd):_0x39816f(0xbb);return{'ok':!![],'message':'✓\x20'+_0x537d1b+'\x20appcode\x20set\x20to:\x20'+_0x5e5224+_0x39816f(0xa2)};}_0x2f8e22[_0x251834]=_0x5e5224,writeScopedConfig(_0x2f8e22,_0x3d8f34);const _0x30aea1=_0x3d8f34===_0x39816f(0xcc)?_0x39816f(0xbd):_0x39816f(0xbb);return{'ok':!![],'message':'✓\x20'+_0x30aea1+'\x20'+_0x251834+_0x39816f(0xca)+_0x5e5224};}export const configSetDefinition={'service':a54_0x51c154(0xa7),'command':a54_0x51c154(0xb4),'description':a54_0x51c154(0xa6),'risk':'write','requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a54_0x51c154(0xa4),'type':'string','description':getConfigCommandKeyDescription(),'required':!![]},{'name':a54_0x51c154(0xbf),'type':a54_0x51c154(0xad),'description':a54_0x51c154(0xb3),'required':!![]},{'name':a54_0x51c154(0xcc),'type':'boolean','description':a54_0x51c154(0xc5),'default':![]}],'execute':execute};
@@ -1 +1 @@
1
- (function(_0x477537,_0x448e6d){var _0x3fe4b1=a55_0x139d,_0x243a17=_0x477537();while(!![]){try{var _0x49b906=parseInt(_0x3fe4b1(0xce))/0x1+parseInt(_0x3fe4b1(0xc9))/0x2+parseInt(_0x3fe4b1(0xcf))/0x3*(parseInt(_0x3fe4b1(0xc3))/0x4)+parseInt(_0x3fe4b1(0xc7))/0x5*(-parseInt(_0x3fe4b1(0xd1))/0x6)+-parseInt(_0x3fe4b1(0xc6))/0x7*(parseInt(_0x3fe4b1(0xcb))/0x8)+-parseInt(_0x3fe4b1(0xcc))/0x9+parseInt(_0x3fe4b1(0xc8))/0xa*(-parseInt(_0x3fe4b1(0xcd))/0xb);if(_0x49b906===_0x448e6d)break;else _0x243a17['push'](_0x243a17['shift']());}catch(_0x5c9468){_0x243a17['push'](_0x243a17['shift']());}}}(a55_0x365c,0xba9a0));import{CLI_BIN_NAME}from'../../constant/cli.js';function a55_0x365c(){var _0x236e99=['6HOAuBG','Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).','4bFcEuf','global','project','7TgHZIY','1828130vxiCZg','790JaeQbN','2670782nKGtEU','validation','1227720QnqoMj','4510935tHgHhK','16159QwMDxT','531155YqGMWH','102393RBsVzW','\x20init`\x20first.'];a55_0x365c=function(){return _0x236e99;};return a55_0x365c();}import{isInProject,resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../../context.js';import{CliErrors}from'../../errors.js';import{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale}from'../../config/schema.js';export{CLI_BIN_NAME};function a55_0x139d(_0x36a989,_0xf399ea){_0x36a989=_0x36a989-0xc3;var _0x365c44=a55_0x365c();var _0x139d0e=_0x365c44[_0x36a989];return _0x139d0e;}export{normalizeLocale};export{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey};export function resolveWriteScope(_0x5a1c06){var _0x5774e0=a55_0x139d;if(_0x5a1c06['global'])return _0x5774e0(0xc4);if(!isInProject())throw CliErrors[_0x5774e0(0xca)](_0x5774e0(0xd3),_0x5774e0(0xd2)+CLI_BIN_NAME+_0x5774e0(0xd0));return _0x5774e0(0xc5);}export function readScopedConfig(_0x9b9d24){return readConfigFile(resolveWriteConfigPath(_0x9b9d24));}export function writeScopedConfig(_0x2be1b9,_0x408d47){writeConfigFile(resolveWriteConfigPath(_0x408d47),_0x2be1b9);}
1
+ (function(_0x9891c7,_0x11aec2){var _0x5075e1=a55_0x5d7e,_0x1a97b8=_0x9891c7();while(!![]){try{var _0x19553d=parseInt(_0x5075e1(0x1b4))/0x1*(parseInt(_0x5075e1(0x1b3))/0x2)+-parseInt(_0x5075e1(0x1b5))/0x3+parseInt(_0x5075e1(0x1ba))/0x4+-parseInt(_0x5075e1(0x1b9))/0x5+parseInt(_0x5075e1(0x1b6))/0x6*(parseInt(_0x5075e1(0x1bc))/0x7)+-parseInt(_0x5075e1(0x1b0))/0x8*(-parseInt(_0x5075e1(0x1ad))/0x9)+parseInt(_0x5075e1(0x1ae))/0xa*(-parseInt(_0x5075e1(0x1bb))/0xb);if(_0x19553d===_0x11aec2)break;else _0x1a97b8['push'](_0x1a97b8['shift']());}catch(_0x223533){_0x1a97b8['push'](_0x1a97b8['shift']());}}}(a55_0xa0de,0x2d5de));import{CLI_BIN_NAME}from'../../constant/cli.js';import{isInProject,resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../../context.js';import{CliErrors}from'../../errors.js';import{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale}from'../../config/schema.js';export{CLI_BIN_NAME};function a55_0xa0de(){var _0x571362=['Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).','\x20init`\x20first.','162704KkXEJC','3NOticr','165759wPuPgP','6jlKJFM','global','validation','1119965VYUSNo','443120vAQOOM','11pZVRwi','1407063mRwcZH','54hniCqu','2960190vbHUdk','project','273656vHwpKR'];a55_0xa0de=function(){return _0x571362;};return a55_0xa0de();}function a55_0x5d7e(_0x59e6ee,_0x5bbd25){_0x59e6ee=_0x59e6ee-0x1ad;var _0xa0deb=a55_0xa0de();var _0x5d7e6a=_0xa0deb[_0x59e6ee];return _0x5d7e6a;}export{normalizeLocale};export{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey};export function resolveWriteScope(_0x1a8d5a){var _0x53fc2b=a55_0x5d7e;if(_0x1a8d5a[_0x53fc2b(0x1b7)])return _0x53fc2b(0x1b7);if(!isInProject())throw CliErrors[_0x53fc2b(0x1b8)](_0x53fc2b(0x1b1),'Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`'+CLI_BIN_NAME+_0x53fc2b(0x1b2));return _0x53fc2b(0x1af);}export function readScopedConfig(_0x128af8){return readConfigFile(resolveWriteConfigPath(_0x128af8));}export function writeScopedConfig(_0x47e673,_0x2e4909){writeConfigFile(resolveWriteConfigPath(_0x2e4909),_0x47e673);}
@@ -1 +1 @@
1
- const a56_0x145897=a56_0x205d;(function(_0x128ec5,_0x19f052){const _0x1b33db=a56_0x205d,_0x255cfe=_0x128ec5();while(!![]){try{const _0x14fc7a=parseInt(_0x1b33db(0x108))/0x1+-parseInt(_0x1b33db(0x107))/0x2+parseInt(_0x1b33db(0x10a))/0x3*(parseInt(_0x1b33db(0xfc))/0x4)+-parseInt(_0x1b33db(0x105))/0x5*(parseInt(_0x1b33db(0x10c))/0x6)+parseInt(_0x1b33db(0x101))/0x7+-parseInt(_0x1b33db(0x106))/0x8+parseInt(_0x1b33db(0x10b))/0x9;if(_0x14fc7a===_0x19f052)break;else _0x255cfe['push'](_0x255cfe['shift']());}catch(_0xc52db5){_0x255cfe['push'](_0x255cfe['shift']());}}}(a56_0x1e83,0x39c91));function a56_0x205d(_0x5a9cf4,_0x1963c5){_0x5a9cf4=_0x5a9cf4-0xfb;const _0x1e8397=a56_0x1e83();let _0x205de7=_0x1e8397[_0x5a9cf4];return _0x205de7;}import{buildDataCommand}from'../../commands/data/shared.js';function a56_0x1e83(){const _0xb27ba2=['\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','1083544zeRcrk','Filter\x20dataset\x20records\x20with\x20query\x20conditions','filter','join','4135ElNAgw','3198152ZwnPGh','759200cAlENL','365857qHRkzI','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]','433929nLgIxR','1491138hXsmbB','756ZuTBfw','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','12RxGmyX','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page'];a56_0x1e83=function(){return _0xb27ba2;};return a56_0x1e83();}export const dataFilter=buildDataCommand({'command':a56_0x145897(0x103),'operation':a56_0x145897(0x103),'description':a56_0x145897(0x102),'paramsRequired':![],'paramsHint':a56_0x145897(0x100),'helpExtra':[a56_0x145897(0xfe),a56_0x145897(0xfb),a56_0x145897(0xff),a56_0x145897(0x109),'\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)',a56_0x145897(0xfd)][a56_0x145897(0x104)]('\x0a')});
1
+ const a56_0x5b5faf=a56_0x392b;(function(_0x7b80a8,_0x158d73){const _0x3abcf7=a56_0x392b,_0x4c45be=_0x7b80a8();while(!![]){try{const _0x143831=-parseInt(_0x3abcf7(0x93))/0x1*(-parseInt(_0x3abcf7(0x92))/0x2)+-parseInt(_0x3abcf7(0x9b))/0x3+-parseInt(_0x3abcf7(0x8c))/0x4*(-parseInt(_0x3abcf7(0x8e))/0x5)+parseInt(_0x3abcf7(0x97))/0x6*(parseInt(_0x3abcf7(0x90))/0x7)+parseInt(_0x3abcf7(0x9c))/0x8+-parseInt(_0x3abcf7(0x8f))/0x9*(-parseInt(_0x3abcf7(0x8d))/0xa)+-parseInt(_0x3abcf7(0x99))/0xb;if(_0x143831===_0x158d73)break;else _0x4c45be['push'](_0x4c45be['shift']());}catch(_0x313c60){_0x4c45be['push'](_0x4c45be['shift']());}}}(a56_0x3128,0x39e81));import{buildDataCommand}from'../../commands/data/shared.js';function a56_0x3128(){const _0x308f26=['\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','562QElSlq','1286QycVyN','filter','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]','54FTXmhL','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','13492908xFjTPn','join','76350UiKabi','124872rGYGBk','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]','1325432oJUDoX','510woUylY','5GUAGjS','76491mLkYDp','270263IDnwsh'];a56_0x3128=function(){return _0x308f26;};return a56_0x3128();}function a56_0x392b(_0x18d7e5,_0x4e9803){_0x18d7e5=_0x18d7e5-0x8c;const _0x3128aa=a56_0x3128();let _0x392b04=_0x3128aa[_0x18d7e5];return _0x392b04;}export const dataFilter=buildDataCommand({'command':'filter','operation':a56_0x5b5faf(0x94),'description':'Filter\x20dataset\x20records\x20with\x20query\x20conditions','paramsRequired':![],'paramsHint':a56_0x5b5faf(0x95),'helpExtra':[a56_0x5b5faf(0x91),a56_0x5b5faf(0x98),a56_0x5b5faf(0x96),a56_0x5b5faf(0x9d),'\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page'][a56_0x5b5faf(0x9a)]('\x0a')});
@@ -1 +1 @@
1
- function a57_0x4367(){const _0x2cfc29=['6238370rZMuWR','getOne','1003797fqGtts','4ysPsiW','16569DqXwcu','624VbawLq','4YdhKBX','Get\x20a\x20single\x20record\x20by\x20ID','3168056xOAMaO','1031118cwWEXS','716535JkNglJ','1042841YaoLun','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27'];a57_0x4367=function(){return _0x2cfc29;};return a57_0x4367();}const a57_0x2147df=a57_0x5133;(function(_0x607e50,_0x725af7){const _0x13b68b=a57_0x5133,_0x1aeecd=_0x607e50();while(!![]){try{const _0x495946=parseInt(_0x13b68b(0x1d8))/0x1+parseInt(_0x13b68b(0x1dd))/0x2*(parseInt(_0x13b68b(0x1d6))/0x3)+parseInt(_0x13b68b(0x1d3))/0x4*(parseInt(_0x13b68b(0x1d7))/0x5)+-parseInt(_0x13b68b(0x1d2))/0x6*(parseInt(_0x13b68b(0x1d1))/0x7)+-parseInt(_0x13b68b(0x1d5))/0x8+parseInt(_0x13b68b(0x1dc))/0x9+-parseInt(_0x13b68b(0x1da))/0xa;if(_0x495946===_0x725af7)break;else _0x1aeecd['push'](_0x1aeecd['shift']());}catch(_0x341c00){_0x1aeecd['push'](_0x1aeecd['shift']());}}}(a57_0x4367,0xaf8e9));function a57_0x5133(_0x503c4e,_0x32e62c){_0x503c4e=_0x503c4e-0x1d1;const _0x43678e=a57_0x4367();let _0x5133ce=_0x43678e[_0x503c4e];return _0x5133ce;}import{buildDataCommand}from'../../commands/data/shared.js';export const dataGetOne=buildDataCommand({'command':a57_0x2147df(0x1db),'operation':'getOne','description':a57_0x2147df(0x1d4),'paramsRequired':!![],'paramsHint':a57_0x2147df(0x1d9)});
1
+ const a57_0x400313=a57_0x53b0;(function(_0x114f8f,_0x477bc5){const _0x38d7d4=a57_0x53b0,_0x2d53cd=_0x114f8f();while(!![]){try{const _0x1af68a=parseInt(_0x38d7d4(0x155))/0x1+parseInt(_0x38d7d4(0x14e))/0x2*(parseInt(_0x38d7d4(0x14c))/0x3)+-parseInt(_0x38d7d4(0x156))/0x4*(parseInt(_0x38d7d4(0x152))/0x5)+-parseInt(_0x38d7d4(0x157))/0x6+parseInt(_0x38d7d4(0x150))/0x7*(parseInt(_0x38d7d4(0x153))/0x8)+parseInt(_0x38d7d4(0x14b))/0x9+-parseInt(_0x38d7d4(0x151))/0xa*(parseInt(_0x38d7d4(0x154))/0xb);if(_0x1af68a===_0x477bc5)break;else _0x2d53cd['push'](_0x2d53cd['shift']());}catch(_0x24cd83){_0x2d53cd['push'](_0x2d53cd['shift']());}}}(a57_0x17ef,0xed59f));import{buildDataCommand}from'../../commands/data/shared.js';function a57_0x17ef(){const _0x1227b1=['271852efmpdb','883790qLQuLO','205qHRmko','96OQMnfF','55FXxtsb','747049BZjBSL','129028hFYizc','2549226PzDPsc','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','11892924pQKjSH','110643iTVszT','Get\x20a\x20single\x20record\x20by\x20ID','34GyPYFf','getOne'];a57_0x17ef=function(){return _0x1227b1;};return a57_0x17ef();}function a57_0x53b0(_0x1f69fd,_0x4b9abf){_0x1f69fd=_0x1f69fd-0x14a;const _0x17efef=a57_0x17ef();let _0x53b09f=_0x17efef[_0x1f69fd];return _0x53b09f;}export const dataGetOne=buildDataCommand({'command':'getOne','operation':a57_0x400313(0x14f),'description':a57_0x400313(0x14d),'paramsRequired':!![],'paramsHint':a57_0x400313(0x14a)});
@@ -1 +1 @@
1
- function a58_0x16f2(_0x378801,_0x5965c4){_0x378801=_0x378801-0xec;const _0x20a0f8=a58_0x20a0();let _0x16f2a2=_0x20a0f8[_0x378801];return _0x16f2a2;}(function(_0x9d9b6f,_0x26fa61){const _0x4c98eb=a58_0x16f2,_0x37edf9=_0x9d9b6f();while(!![]){try{const _0x479e7b=-parseInt(_0x4c98eb(0xf0))/0x1+parseInt(_0x4c98eb(0xf3))/0x2+-parseInt(_0x4c98eb(0xed))/0x3+parseInt(_0x4c98eb(0xf1))/0x4+-parseInt(_0x4c98eb(0xee))/0x5*(-parseInt(_0x4c98eb(0xef))/0x6)+-parseInt(_0x4c98eb(0xf2))/0x7+parseInt(_0x4c98eb(0xec))/0x8;if(_0x479e7b===_0x26fa61)break;else _0x37edf9['push'](_0x37edf9['shift']());}catch(_0x452cdf){_0x37edf9['push'](_0x37edf9['shift']());}}}(a58_0x20a0,0x5edc8));function a58_0x20a0(){const _0x465a1e=['5zWkCFN','4438686RUnNup','735618QbSIbU','1113780vcfPWM','432152xhvSPj','330778cayUoO','479440LFnwMT','172917hNEsyX'];a58_0x20a0=function(){return _0x465a1e;};return a58_0x20a0();}import{dataFilter}from'../../commands/data/filter.js';import{dataGetOne}from'../../commands/data/getOne.js';export const dataDefinitions=[dataFilter,dataGetOne];
1
+ (function(_0x2a45aa,_0xd96128){const _0x54217f=a58_0xa8c3,_0x14e21f=_0x2a45aa();while(!![]){try{const _0x3dbd53=-parseInt(_0x54217f(0x174))/0x1+-parseInt(_0x54217f(0x172))/0x2+-parseInt(_0x54217f(0x16c))/0x3+parseInt(_0x54217f(0x16e))/0x4+-parseInt(_0x54217f(0x16d))/0x5*(-parseInt(_0x54217f(0x170))/0x6)+parseInt(_0x54217f(0x173))/0x7*(parseInt(_0x54217f(0x16f))/0x8)+parseInt(_0x54217f(0x171))/0x9;if(_0x3dbd53===_0xd96128)break;else _0x14e21f['push'](_0x14e21f['shift']());}catch(_0x5cca3d){_0x14e21f['push'](_0x14e21f['shift']());}}}(a58_0x5a84,0x904e3));import{dataFilter}from'../../commands/data/filter.js';function a58_0x5a84(){const _0x4313f9=['2002305RivYTK','34910tcPWvn','1047700ouPJXr','8OfpBhb','18PyJOpK','19756476CfHRIm','2303500soWrGe','2847103bdQpdc','474504PENgfi'];a58_0x5a84=function(){return _0x4313f9;};return a58_0x5a84();}function a58_0xa8c3(_0x15b180,_0x3b19fc){_0x15b180=_0x15b180-0x16c;const _0x5a84fe=a58_0x5a84();let _0xa8c3f4=_0x5a84fe[_0x15b180];return _0xa8c3f4;}import{dataGetOne}from'../../commands/data/getOne.js';export const dataDefinitions=[dataFilter,dataGetOne];
@@ -1 +1 @@
1
- function a59_0x58ce(_0x170282,_0xce885c){_0x170282=_0x170282-0x109;const _0x29164c=a59_0x2916();let _0x58ce4a=_0x29164c[_0x170282];return _0x58ce4a;}(function(_0x4412e6,_0x176499){const _0x5ca3d5=a59_0x58ce,_0x26e87f=_0x4412e6();while(!![]){try{const _0x24702f=-parseInt(_0x5ca3d5(0x117))/0x1+parseInt(_0x5ca3d5(0x10f))/0x2*(-parseInt(_0x5ca3d5(0x124))/0x3)+parseInt(_0x5ca3d5(0x10e))/0x4*(-parseInt(_0x5ca3d5(0x10c))/0x5)+-parseInt(_0x5ca3d5(0x11b))/0x6*(parseInt(_0x5ca3d5(0x112))/0x7)+parseInt(_0x5ca3d5(0x123))/0x8+-parseInt(_0x5ca3d5(0x126))/0x9+parseInt(_0x5ca3d5(0x10d))/0xa;if(_0x24702f===_0x176499)break;else _0x26e87f['push'](_0x26e87f['shift']());}catch(_0x4d18dc){_0x26e87f['push'](_0x26e87f['shift']());}}}(a59_0x2916,0x289a9));import{executeDatasetDataOperation}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{parseJsonParams}from'../../utils/params.js';function assertGetOneId(_0x29da73){const _0x276017=a59_0x58ce;if(!_0x29da73)throw CliErrors[_0x276017(0x11c)](_0x276017(0x121),_0x276017(0x119));const _0xd8f7a4=_0x29da73['id'];if(_0xd8f7a4===undefined||_0xd8f7a4===null||_0xd8f7a4==='')throw CliErrors['validation'](_0x276017(0x120),_0x276017(0x115));}function a59_0x2916(){const _0xbdf951=['1393etPdHT','now','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','getOne','114148DOHSRb','str','Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.','command','9714PabbBf','flagMissing','read','string','helpExtra','data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params','params','operation','2242544vlrJwo','101226DBShmc','alias','339291uSCgSY','data','\x20completed\x20in\x20','appCode','compress','288100OSCiBe','7690770Vbfmnj','12QUQZXM','14VKBldn','paramsRequired','code'];a59_0x2916=function(){return _0xbdf951;};return a59_0x2916();}function parseCommandParams(_0x4719b5){return parseJsonParams(_0x4719b5)??{};}export function buildDataCommand(_0x585a11){const _0x20706e=a59_0x58ce,_0x4ff165=_0x20706e(0x114);return{'service':_0x20706e(0x127),'command':_0x585a11[_0x20706e(0x11a)],'description':_0x585a11['description'],'risk':_0x20706e(0x11d),'defaultOutputFormat':_0x20706e(0x10b),'helpExtra':_0x585a11[_0x20706e(0x11f)],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0x20706e(0x125),'type':_0x20706e(0x11e),'description':_0x4ff165},{'name':'params','type':_0x20706e(0x11e),'description':_0x585a11['paramsHint']}],async 'validate'(_0x1fc00f){const _0x41b447=_0x20706e,_0x18e903=_0x1fc00f[_0x41b447(0x118)](_0x41b447(0x121));if(_0x585a11[_0x41b447(0x110)]&&!_0x18e903)throw CliErrors[_0x41b447(0x11c)]('params',_0x585a11['paramsHint']);const _0x2a93c2=parseJsonParams(_0x18e903);_0x585a11[_0x41b447(0x122)]===_0x41b447(0x116)&&assertGetOneId(_0x2a93c2);},async 'execute'(_0x4df774){const _0x1a5b8b=_0x20706e,_0x50e7b2=parseCommandParams(_0x4df774[_0x1a5b8b(0x118)](_0x1a5b8b(0x121))),_0x317ae8=Date[_0x1a5b8b(0x113)](),_0xd93ecb=await executeDatasetDataOperation(_0x4df774[_0x1a5b8b(0x10a)],_0x4df774[_0x1a5b8b(0x118)](_0x1a5b8b(0x111)),_0x585a11[_0x1a5b8b(0x122)],_0x50e7b2),_0x56eb95=Date[_0x1a5b8b(0x113)]()-_0x317ae8;return{'ok':!![],'data':{'result':_0xd93ecb,'elapsed':_0x56eb95},'message':'data\x20'+_0x585a11['command']+_0x1a5b8b(0x109)+_0x56eb95+'ms'};}};}
1
+ (function(_0x100158,_0x1dc5e4){const _0x243ec2=a59_0x543d,_0x3524cf=_0x100158();while(!![]){try{const _0x4f6032=-parseInt(_0x243ec2(0x18c))/0x1*(parseInt(_0x243ec2(0x19a))/0x2)+parseInt(_0x243ec2(0x191))/0x3+-parseInt(_0x243ec2(0x1a2))/0x4*(parseInt(_0x243ec2(0x199))/0x5)+parseInt(_0x243ec2(0x1a6))/0x6+-parseInt(_0x243ec2(0x1a5))/0x7+parseInt(_0x243ec2(0x192))/0x8+parseInt(_0x243ec2(0x18e))/0x9*(parseInt(_0x243ec2(0x193))/0xa);if(_0x4f6032===_0x1dc5e4)break;else _0x3524cf['push'](_0x3524cf['shift']());}catch(_0x590ca2){_0x3524cf['push'](_0x3524cf['shift']());}}}(a59_0x20f8,0x8d24e));import{executeDatasetDataOperation}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{parseJsonParams}from'../../utils/params.js';function a59_0x543d(_0x490f45,_0x3685ad){_0x490f45=_0x490f45-0x189;const _0x20f800=a59_0x20f8();let _0x543dde=_0x20f800[_0x490f45];return _0x543dde;}function assertGetOneId(_0x970761){const _0x4de1ba=a59_0x543d;if(!_0x970761)throw CliErrors[_0x4de1ba(0x19e)](_0x4de1ba(0x1a4),'Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.');const _0x40bb8c=_0x970761['id'];if(_0x40bb8c===undefined||_0x40bb8c===null||_0x40bb8c==='')throw CliErrors[_0x4de1ba(0x189)]('data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params',_0x4de1ba(0x195));}function a59_0x20f8(){const _0x45a2a1=['2196ynjfNi','string','read','1502613qsyKZX','2560392drgyrd','42050kHyPiy','str','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','alias','\x20completed\x20in\x20','helpExtra','3407605IaXUnS','2cpTbhL','command','data\x20','operation','flagMissing','description','appCode','compress','4JmFvRa','now','params','5561311xIDhOM','4596294VAapYV','paramsHint','validation','getOne','data','558869PJVvTd','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically'];a59_0x20f8=function(){return _0x45a2a1;};return a59_0x20f8();}function parseCommandParams(_0x17a8ca){return parseJsonParams(_0x17a8ca)??{};}export function buildDataCommand(_0x3524d8){const _0x5f26f0=a59_0x543d,_0x3ec086=_0x5f26f0(0x18d);return{'service':_0x5f26f0(0x18b),'command':_0x3524d8['command'],'description':_0x3524d8[_0x5f26f0(0x19f)],'risk':_0x5f26f0(0x190),'defaultOutputFormat':_0x5f26f0(0x1a1),'helpExtra':_0x3524d8[_0x5f26f0(0x198)],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0x5f26f0(0x196),'type':_0x5f26f0(0x18f),'description':_0x3ec086},{'name':_0x5f26f0(0x1a4),'type':'string','description':_0x3524d8[_0x5f26f0(0x1a7)]}],async 'validate'(_0x1d8179){const _0x50033a=_0x5f26f0,_0x5c834b=_0x1d8179[_0x50033a(0x194)](_0x50033a(0x1a4));if(_0x3524d8['paramsRequired']&&!_0x5c834b)throw CliErrors[_0x50033a(0x19e)](_0x50033a(0x1a4),_0x3524d8[_0x50033a(0x1a7)]);const _0x44dde3=parseJsonParams(_0x5c834b);_0x3524d8['operation']===_0x50033a(0x18a)&&assertGetOneId(_0x44dde3);},async 'execute'(_0xff1ab8){const _0x1d69ec=_0x5f26f0,_0x4c486e=parseCommandParams(_0xff1ab8['str'](_0x1d69ec(0x1a4))),_0x5cf8df=Date['now'](),_0x192363=await executeDatasetDataOperation(_0xff1ab8[_0x1d69ec(0x1a0)],_0xff1ab8['str']('code'),_0x3524d8[_0x1d69ec(0x19d)],_0x4c486e),_0x1b9c08=Date[_0x1d69ec(0x1a3)]()-_0x5cf8df;return{'ok':!![],'data':{'result':_0x192363,'elapsed':_0x1b9c08},'message':_0x1d69ec(0x19c)+_0x3524d8[_0x1d69ec(0x19b)]+_0x1d69ec(0x197)+_0x1b9c08+'ms'};}};}
@@ -1 +1 @@
1
- function a60_0x414f(_0xf6550c,_0x401601){_0xf6550c=_0xf6550c-0xb8;const _0x185862=a60_0x1858();let _0x414fba=_0x185862[_0xf6550c];return _0x414fba;}const a60_0x4834ea=a60_0x414f;(function(_0x3498ca,_0x2fb158){const _0xf58325=a60_0x414f,_0x1b4d8a=_0x3498ca();while(!![]){try{const _0x39faf8=parseInt(_0xf58325(0xd0))/0x1+-parseInt(_0xf58325(0xbd))/0x2+parseInt(_0xf58325(0xcd))/0x3+-parseInt(_0xf58325(0xda))/0x4+-parseInt(_0xf58325(0xea))/0x5+-parseInt(_0xf58325(0xc7))/0x6*(parseInt(_0xf58325(0xe1))/0x7)+parseInt(_0xf58325(0xe0))/0x8;if(_0x39faf8===_0x2fb158)break;else _0x1b4d8a['push'](_0x1b4d8a['shift']());}catch(_0x1e7f45){_0x1b4d8a['push'](_0x1b4d8a['shift']());}}}(a60_0x1858,0xb3425));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateErBusinessGroup}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const BACKEND_PATH=a60_0x4834ea(0xc0);export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x33b75a,input:_0xef260f,dryRun:_0x19dfbe}){const _0x271ba1=a60_0x4834ea;validateInput(_0xef260f);const _0x31d225=normalizeBusinessGroup(_0xef260f[_0x271ba1(0xd6)]),_0x33d03d=await getDatasetDetail(_0xef260f['code']),_0x354d17=resolveBusinessGroupDataset(_0x33d03d,_0xef260f[_0x271ba1(0xe5)]),_0x573894=loadCurrentBusinessGroup(_0x33d03d,_0x354d17);assertExpectedBusinessGroup(_0x573894,_0xef260f['expectBusinessGroup']);const _0x3667d3=buildBackendPayload(_0x33b75a,_0x354d17,_0x31d225),_0x190a48=_0x573894!==_0x31d225;let _0x1bf71d;if(_0x190a48&&!_0x19dfbe){await updateErBusinessGroup(_0x3667d3);const _0x504d58=await getDatasetDetail(_0x354d17[_0x271ba1(0xe5)]),_0xaac352=resolveBusinessGroupDataset(_0x504d58,_0x354d17[_0x271ba1(0xe5)]),_0x523593=loadCurrentBusinessGroup(_0x504d58,_0xaac352);if(_0x523593!==_0x31d225)throw CliErrors['apiError'](_0x271ba1(0xf0),_0x271ba1(0xdb)+JSON[_0x271ba1(0xcb)](_0x31d225)+_0x271ba1(0xc6)+JSON['stringify'](_0x523593)+'.');_0x1bf71d={'verified':!![],'status':_0x271ba1(0xf1),'afterReadback':{'businessGroup':_0x523593}};}else!_0x190a48&&(_0x1bf71d={'verified':!![],'status':_0x271ba1(0xc9),'afterReadback':{'businessGroup':_0x573894}});const _0x18840d={'operation':'update','appCode':_0x33b75a,'selector':{'code':_0x354d17['code']},'dataset':_0x354d17,'before':{'businessGroup':_0x573894},'after':{'businessGroup':_0x31d225},'changed':_0x190a48,'dryRun':_0x19dfbe,'submitted':_0x190a48&&!_0x19dfbe,'backend':{'method':_0x271ba1(0xd9),'path':BACKEND_PATH,'payload':_0x3667d3},..._0x1bf71d?{'verification':_0x1bf71d}:{},'warnings':[]};return{'ok':!![],'data':_0x18840d,'message':_0x190a48?_0x19dfbe?_0x271ba1(0xde)+_0x354d17['code']:_0x271ba1(0xc5)+_0x354d17['code']:'No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20'+_0x354d17[_0x271ba1(0xe5)]};}export const datasetBusinessGroupUpdate={'service':a60_0x4834ea(0xed),'command':a60_0x4834ea(0xd2),'description':a60_0x4834ea(0xbe),'risk':a60_0x4834ea(0xe7),'flags':[CODE_FLAG,{'name':a60_0x4834ea(0xe4),'type':a60_0x4834ea(0xdc),'required':!![],'description':a60_0x4834ea(0xe6)},{'name':'expect-business-group','type':'string','required':![],'description':a60_0x4834ea(0xc3)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x3ba608){validateInput(readBusinessGroupUpdateInput(_0x3ba608));},async 'dryRun'(_0x9a1bd6){const _0x332559=a60_0x4834ea,_0xce4f88=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x9a1bd6[_0x332559(0xdd)],'input':readBusinessGroupUpdateInput(_0x9a1bd6),'dryRun':!![]});return{'method':_0x332559(0xd9),'url':BACKEND_PATH,'body':_0xce4f88[_0x332559(0xf3)][_0x332559(0xef)][_0x332559(0xc2)],'description':_0xce4f88['message'],..._0xce4f88[_0x332559(0xf3)]};},async 'execute'(_0x58f318){const _0x1ed4f7=a60_0x4834ea;return buildDatasetBusinessGroupUpdateResult({'appCode':_0x58f318[_0x1ed4f7(0xdd)],'input':readBusinessGroupUpdateInput(_0x58f318),'dryRun':![]});}};function readBusinessGroupUpdateInput(_0x11e133){const _0x2182dc=a60_0x4834ea,_0x2fb06d=_0x11e133['str'](_0x2182dc(0xc8));return{'code':trim(_0x11e133['str'](_0x2182dc(0xe5))),'businessGroup':_0x11e133[_0x2182dc(0xeb)](_0x2182dc(0xe4)),'expectBusinessGroup':_0x2fb06d===undefined||_0x2fb06d===''?undefined:_0x2fb06d};}function validateInput(_0x14a1d4){const _0x15003c=a60_0x4834ea;if(!trim(_0x14a1d4[_0x15003c(0xe5)]))throw CliErrors[_0x15003c(0xd5)](_0x15003c(0xc1));if(_0x14a1d4[_0x15003c(0xd6)]===undefined)throw CliErrors[_0x15003c(0xd5)]('--business-group\x20is\x20required');}function resolveBusinessGroupDataset(_0x182e3d,_0x4532c0){const _0x5df4cc=a60_0x4834ea,_0x556ec4=asPlainObject(_0x182e3d[_0x5df4cc(0xed)]),_0x49d79a=asPlainObject(_0x182e3d[_0x5df4cc(0xd1)]),_0x3e1abc=resolveSourceType(_0x182e3d,_0x556ec4,_0x49d79a),_0x3c8fc2=firstString(_0x182e3d['modelCode'],_0x182e3d['code'],_0x556ec4['datasetCode'],_0x4532c0)||_0x4532c0;return{'id':firstNumber(_0x182e3d[_0x5df4cc(0xe2)],_0x182e3d['id'],_0x556ec4[_0x5df4cc(0xb9)])??firstString(_0x182e3d[_0x5df4cc(0xe2)],_0x182e3d['id'],_0x556ec4['datasetId'])??null,'code':_0x3c8fc2,'name':firstString(_0x182e3d['name'],_0x556ec4[_0x5df4cc(0xba)],_0x556ec4[_0x5df4cc(0xec)])||null,'sourceType':_0x3e1abc};}function resolveSourceType(_0x21dd06,_0x4b3cbf,_0x55deca){const _0x20f7cf=a60_0x4834ea,_0x5e5d49=firstString(_0x21dd06[_0x20f7cf(0xe9)],_0x21dd06['sourceType'],_0x4b3cbf['source'],_0x4b3cbf['sourceType'])?.[_0x20f7cf(0xcc)]()[_0x20f7cf(0xbc)]();if(_0x5e5d49==='DB_TABLE'||_0x5e5d49===_0x20f7cf(0xf4))return _0x5e5d49;if(Object[_0x20f7cf(0xd8)](_0x55deca)[_0x20f7cf(0xdf)]>0x0)return _0x20f7cf(0xd7);throw CliErrors['validation'](_0x20f7cf(0xc4));}function loadCurrentBusinessGroup(_0x4c2d90,_0x4f16fc){const _0x2dcde4=a60_0x4834ea,_0x3221b5=readBusinessGroupFromDatasetDetail(_0x4c2d90,_0x4f16fc[_0x2dcde4(0xe3)]);if(_0x3221b5[_0x2dcde4(0xcf)])return normalizeBusinessGroup(_0x3221b5['value']);if(_0x4f16fc[_0x2dcde4(0xe3)]===_0x2dcde4(0xf4))return'';throw CliErrors[_0x2dcde4(0xd5)](_0x2dcde4(0xca),_0x2dcde4(0xce));}function readBusinessGroupFromDatasetDetail(_0x1985ad,_0x5459e1){const _0x486497=a60_0x4834ea,_0xf188c5=asPlainObject(_0x1985ad['dataset']),_0x444bc3=firstPresent(_0x1985ad[_0x486497(0xd6)]);if(_0x444bc3['found'])return _0x444bc3;const _0x399695=firstPresent(_0xf188c5[_0x486497(0xd6)]);if(_0x399695['found'])return _0x399695;if(_0x5459e1===_0x486497(0xd7))return{'found':![]};const _0x177728=readBusinessGroupFromExtend(_0x1985ad[_0x486497(0xee)]);if(_0x177728[_0x486497(0xcf)])return _0x177728;return readBusinessGroupFromExtend(_0xf188c5[_0x486497(0xee)]);}function readBusinessGroupFromExtend(_0x4202f1){const _0x5badd0=a60_0x4834ea;if(_0x4202f1===undefined||_0x4202f1===null||_0x4202f1==='')return{'found':![]};if(typeof _0x4202f1==='string')try{const _0x313d3d=JSON[_0x5badd0(0xd4)](_0x4202f1);return readBusinessGroupFromExtend(_0x313d3d);}catch{return{'found':![]};}const _0x5bd0cb=asPlainObject(_0x4202f1);if(Object['prototype'][_0x5badd0(0xd3)][_0x5badd0(0xf2)](_0x5bd0cb,_0x5badd0(0xd6)))return{'found':!![],'value':_0x5bd0cb['businessGroup']};return{'found':![]};}function a60_0x1858(){const _0x2721d1=['sourceType','business-group','code','Business\x20scenario\x20group\x20(not\x20technical):\x20use\x20<scenario>,\x20or\x20<domain>---<scenario>\x20when\x20needed\x20for\x20disambiguation\x20or\x20an\x20existing\x20hierarchy;\x20empty\x20string\x20clears\x20it','write','isFinite','source','2119635mFoJet','str','name','dataset','extend','backend','Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.','matched','call','data','METADATA','isArray','datasetId','datasetName','Expectation\x20mismatch\x20at\x20businessGroup','toUpperCase','1498290iaOhQp','Update\x20business\x20scenario\x20group','number','/smartapi/question/er-config/business-group/edit','--code\x20is\x20required','payload','Expected\x20current\x20business\x20scenario\x20group;\x20mismatch\x20aborts\x20without\x20writing','Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.','Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20',',\x20actual\x20','4569012WTEoyJ','expect-business-group','unchanged','Dataset\x20detail\x20does\x20not\x20expose\x20businessGroup.','stringify','trim','1102941TeEdak','Business\x20scenario\x20group\x20readback\x20must\x20be\x20available\x20by\x20datasetCode;\x20upgrade\x20the\x20backend\x20read\x20contract\x20instead\x20of\x20using\x20dblinkId/tableName.','found','580812hOmsPv','dbtableConfig','business-group-update','hasOwnProperty','parse','validation','businessGroup','DB_TABLE','keys','POST','3833204SnVNJS','Expected\x20','string','appCode','Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20','length','21429288ggfitT','7ygqvmL','modelId'];a60_0x1858=function(){return _0x2721d1;};return a60_0x1858();}function firstPresent(..._0x9a53ed){for(const _0x2b80e6 of _0x9a53ed){if(_0x2b80e6!==undefined&&_0x2b80e6!==null)return{'found':!![],'value':_0x2b80e6};}return{'found':![]};}function assertExpectedBusinessGroup(_0x169fcc,_0x12c40d){const _0x599ad2=a60_0x4834ea;if(_0x12c40d===undefined)return;const _0x58a5aa=normalizeBusinessGroup(_0x12c40d);if(_0x169fcc!==_0x58a5aa)throw CliErrors[_0x599ad2(0xd5)](_0x599ad2(0xbb),_0x599ad2(0xdb)+JSON[_0x599ad2(0xcb)](_0x58a5aa)+_0x599ad2(0xc6)+JSON[_0x599ad2(0xcb)](_0x169fcc));}function buildBackendPayload(_0x3c4fc5,_0x13c27d,_0x3125e0){const _0x4931ad=a60_0x4834ea;return{'appCode':_0x3c4fc5,'datasetCode':_0x13c27d[_0x4931ad(0xe5)],'businessGroup':_0x3125e0};}function normalizeBusinessGroup(_0x48806a){const _0x4055c8=a60_0x4834ea;if(_0x48806a===undefined||_0x48806a===null)return'';return String(_0x48806a)[_0x4055c8(0xcc)]();}function asPlainObject(_0x30ab4d){const _0x1c0ee2=a60_0x4834ea;if(!_0x30ab4d||typeof _0x30ab4d!=='object'||Array[_0x1c0ee2(0xb8)](_0x30ab4d))return{};return _0x30ab4d;}function firstString(..._0x23fcb5){const _0x4a06f4=a60_0x4834ea;for(const _0x3e9041 of _0x23fcb5){if(typeof _0x3e9041==='string'&&_0x3e9041[_0x4a06f4(0xcc)]())return _0x3e9041['trim']();if(typeof _0x3e9041===_0x4a06f4(0xbf)&&Number[_0x4a06f4(0xe8)](_0x3e9041))return String(_0x3e9041);}return undefined;}function firstNumber(..._0x4ba9c5){const _0x202153=a60_0x4834ea;for(const _0x55eb26 of _0x4ba9c5){if(typeof _0x55eb26==='number'&&Number[_0x202153(0xe8)](_0x55eb26))return _0x55eb26;if(typeof _0x55eb26===_0x202153(0xdc)&&_0x55eb26[_0x202153(0xcc)]()&&Number[_0x202153(0xe8)](Number(_0x55eb26)))return Number(_0x55eb26);}return null;}function trim(_0x1819fe){const _0x3a8996=a60_0x4834ea;return String(_0x1819fe||'')[_0x3a8996(0xcc)]();}
1
+ const a60_0x447e0f=a60_0x37a7;(function(_0x24459b,_0x520df2){const _0x1d1ab6=a60_0x37a7,_0x3e1413=_0x24459b();while(!![]){try{const _0x52b67a=-parseInt(_0x1d1ab6(0x1f3))/0x1+parseInt(_0x1d1ab6(0x204))/0x2+parseInt(_0x1d1ab6(0x21f))/0x3+-parseInt(_0x1d1ab6(0x232))/0x4+parseInt(_0x1d1ab6(0x233))/0x5*(parseInt(_0x1d1ab6(0x223))/0x6)+parseInt(_0x1d1ab6(0x211))/0x7*(-parseInt(_0x1d1ab6(0x224))/0x8)+-parseInt(_0x1d1ab6(0x1f9))/0x9;if(_0x52b67a===_0x520df2)break;else _0x3e1413['push'](_0x3e1413['shift']());}catch(_0xb16bea){_0x3e1413['push'](_0x3e1413['shift']());}}}(a60_0x549a,0xc62a4));function a60_0x37a7(_0x540317,_0x5804c3){_0x540317=_0x540317-0x1f2;const _0x549a41=a60_0x549a();let _0x37a748=_0x549a41[_0x540317];return _0x37a748;}function a60_0x549a(){const _0x51b327=['data','POST','Business\x20scenario\x20group\x20update\x20did\x20not\x20match\x20dataset\x20detail\x20readback.','business-group','unchanged','526680ppeujn','Dry-run:\x20business\x20scenario\x20group\x20would\x20change\x20for\x20dataset\x20','validation','length','backend','Expectation\x20mismatch\x20at\x20businessGroup','Dataset\x20sourceType\x20is\x20required\x20and\x20must\x20be\x20DB_TABLE\x20or\x20METADATA.','sourceType',',\x20actual\x20','datasetId','--business-group\x20is\x20required','1724800SoHufY','trim','extend','apiError','code','modelCode','keys','found','datasetName','message','string','name','isArray','4042822IKWrfW','str','Dataset\x20detail\x20does\x20not\x20expose\x20businessGroup.','object','expect-business-group','parse','DB_TABLE','business-group-update','METADATA','stringify','isFinite','Update\x20business\x20scenario\x20group','update','number','3817404WUkKXY','dbtableConfig','payload','Business\x20scenario\x20group\x20(not\x20technical):\x20use\x20<scenario>,\x20or\x20<domain>---<scenario>\x20when\x20needed\x20for\x20disambiguation\x20or\x20an\x20existing\x20hierarchy;\x20empty\x20string\x20clears\x20it','246cudhfP','8ELjcVf','modelId','Expected\x20','--code\x20is\x20required','/smartapi/question/er-config/business-group/edit','value','call','Business\x20scenario\x20group\x20readback\x20must\x20be\x20available\x20by\x20datasetCode;\x20upgrade\x20the\x20backend\x20read\x20contract\x20instead\x20of\x20using\x20dblinkId/tableName.','datasetCode','dataset','Expected\x20current\x20business\x20scenario\x20group;\x20mismatch\x20aborts\x20without\x20writing','appCode','businessGroup','toUpperCase','1821188IqRQpu','133200ijqRMZ','write','Updated\x20business\x20scenario\x20group\x20for\x20dataset\x20','source','1324061tegiBD'];a60_0x549a=function(){return _0x51b327;};return a60_0x549a();}import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateErBusinessGroup}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const BACKEND_PATH=a60_0x447e0f(0x228);export async function buildDatasetBusinessGroupUpdateResult({appCode:_0x2d3ab1,input:_0x41f20d,dryRun:_0x2a3c78}){const _0x4df34e=a60_0x447e0f;validateInput(_0x41f20d);const _0xf737bb=normalizeBusinessGroup(_0x41f20d[_0x4df34e(0x230)]),_0x1b4720=await getDatasetDetail(_0x41f20d[_0x4df34e(0x208)]),_0x41df75=resolveBusinessGroupDataset(_0x1b4720,_0x41f20d[_0x4df34e(0x208)]),_0x42fce4=loadCurrentBusinessGroup(_0x1b4720,_0x41df75);assertExpectedBusinessGroup(_0x42fce4,_0x41f20d['expectBusinessGroup']);const _0x32a3e4=buildBackendPayload(_0x2d3ab1,_0x41df75,_0xf737bb),_0x4f0314=_0x42fce4!==_0xf737bb;let _0x13cc98;if(_0x4f0314&&!_0x2a3c78){await updateErBusinessGroup(_0x32a3e4);const _0x1b9297=await getDatasetDetail(_0x41df75[_0x4df34e(0x208)]),_0x1f7ada=resolveBusinessGroupDataset(_0x1b9297,_0x41df75[_0x4df34e(0x208)]),_0x59e601=loadCurrentBusinessGroup(_0x1b9297,_0x1f7ada);if(_0x59e601!==_0xf737bb)throw CliErrors[_0x4df34e(0x207)](_0x4df34e(0x1f6),_0x4df34e(0x226)+JSON[_0x4df34e(0x21a)](_0xf737bb)+_0x4df34e(0x201)+JSON[_0x4df34e(0x21a)](_0x59e601)+'.');_0x13cc98={'verified':!![],'status':'matched','afterReadback':{'businessGroup':_0x59e601}};}else!_0x4f0314&&(_0x13cc98={'verified':!![],'status':_0x4df34e(0x1f8),'afterReadback':{'businessGroup':_0x42fce4}});const _0x103d3e={'operation':_0x4df34e(0x21d),'appCode':_0x2d3ab1,'selector':{'code':_0x41df75['code']},'dataset':_0x41df75,'before':{'businessGroup':_0x42fce4},'after':{'businessGroup':_0xf737bb},'changed':_0x4f0314,'dryRun':_0x2a3c78,'submitted':_0x4f0314&&!_0x2a3c78,'backend':{'method':_0x4df34e(0x1f5),'path':BACKEND_PATH,'payload':_0x32a3e4},..._0x13cc98?{'verification':_0x13cc98}:{},'warnings':[]};return{'ok':!![],'data':_0x103d3e,'message':_0x4f0314?_0x2a3c78?_0x4df34e(0x1fa)+_0x41df75[_0x4df34e(0x208)]:_0x4df34e(0x235)+_0x41df75[_0x4df34e(0x208)]:'No\x20changes\x20for\x20business\x20scenario\x20group\x20on\x20dataset\x20'+_0x41df75['code']};}export const datasetBusinessGroupUpdate={'service':a60_0x447e0f(0x22d),'command':a60_0x447e0f(0x218),'description':a60_0x447e0f(0x21c),'risk':a60_0x447e0f(0x234),'flags':[CODE_FLAG,{'name':a60_0x447e0f(0x1f7),'type':a60_0x447e0f(0x20e),'required':!![],'description':a60_0x447e0f(0x222)},{'name':a60_0x447e0f(0x215),'type':'string','required':![],'description':a60_0x447e0f(0x22e)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x511b2b){validateInput(readBusinessGroupUpdateInput(_0x511b2b));},async 'dryRun'(_0x2cb4c5){const _0x40d204=a60_0x447e0f,_0x13c3cf=await buildDatasetBusinessGroupUpdateResult({'appCode':_0x2cb4c5[_0x40d204(0x22f)],'input':readBusinessGroupUpdateInput(_0x2cb4c5),'dryRun':!![]});return{'method':'POST','url':BACKEND_PATH,'body':_0x13c3cf[_0x40d204(0x1f4)][_0x40d204(0x1fd)][_0x40d204(0x221)],'description':_0x13c3cf[_0x40d204(0x20d)],..._0x13c3cf[_0x40d204(0x1f4)]};},async 'execute'(_0x3dd6f0){const _0x26668b=a60_0x447e0f;return buildDatasetBusinessGroupUpdateResult({'appCode':_0x3dd6f0[_0x26668b(0x22f)],'input':readBusinessGroupUpdateInput(_0x3dd6f0),'dryRun':![]});}};function readBusinessGroupUpdateInput(_0x505a0d){const _0x502a01=a60_0x447e0f,_0x1975a6=_0x505a0d[_0x502a01(0x212)](_0x502a01(0x215));return{'code':trim(_0x505a0d[_0x502a01(0x212)]('code')),'businessGroup':_0x505a0d['str'](_0x502a01(0x1f7)),'expectBusinessGroup':_0x1975a6===undefined||_0x1975a6===''?undefined:_0x1975a6};}function validateInput(_0x5b29b5){const _0x33d41f=a60_0x447e0f;if(!trim(_0x5b29b5[_0x33d41f(0x208)]))throw CliErrors[_0x33d41f(0x1fb)](_0x33d41f(0x227));if(_0x5b29b5[_0x33d41f(0x230)]===undefined)throw CliErrors[_0x33d41f(0x1fb)](_0x33d41f(0x203));}function resolveBusinessGroupDataset(_0x35c53b,_0x11c4f3){const _0x26c24b=a60_0x447e0f,_0x2f01af=asPlainObject(_0x35c53b[_0x26c24b(0x22d)]),_0x2b0feb=asPlainObject(_0x35c53b[_0x26c24b(0x220)]),_0x56cd33=resolveSourceType(_0x35c53b,_0x2f01af,_0x2b0feb),_0x370389=firstString(_0x35c53b[_0x26c24b(0x209)],_0x35c53b[_0x26c24b(0x208)],_0x2f01af[_0x26c24b(0x22c)],_0x11c4f3)||_0x11c4f3;return{'id':firstNumber(_0x35c53b[_0x26c24b(0x225)],_0x35c53b['id'],_0x2f01af['datasetId'])??firstString(_0x35c53b[_0x26c24b(0x225)],_0x35c53b['id'],_0x2f01af[_0x26c24b(0x202)])??null,'code':_0x370389,'name':firstString(_0x35c53b[_0x26c24b(0x20f)],_0x2f01af[_0x26c24b(0x20c)],_0x2f01af[_0x26c24b(0x20f)])||null,'sourceType':_0x56cd33};}function resolveSourceType(_0x1a3362,_0x4a0131,_0x22f43d){const _0x1f4717=a60_0x447e0f,_0x1f20f6=firstString(_0x1a3362[_0x1f4717(0x1f2)],_0x1a3362[_0x1f4717(0x200)],_0x4a0131[_0x1f4717(0x1f2)],_0x4a0131[_0x1f4717(0x200)])?.['trim']()[_0x1f4717(0x231)]();if(_0x1f20f6===_0x1f4717(0x217)||_0x1f20f6==='METADATA')return _0x1f20f6;if(Object[_0x1f4717(0x20a)](_0x22f43d)[_0x1f4717(0x1fc)]>0x0)return _0x1f4717(0x217);throw CliErrors[_0x1f4717(0x1fb)](_0x1f4717(0x1ff));}function loadCurrentBusinessGroup(_0x141b31,_0x26b9bd){const _0x1d7914=a60_0x447e0f,_0x2adfce=readBusinessGroupFromDatasetDetail(_0x141b31,_0x26b9bd[_0x1d7914(0x200)]);if(_0x2adfce[_0x1d7914(0x20b)])return normalizeBusinessGroup(_0x2adfce[_0x1d7914(0x229)]);if(_0x26b9bd[_0x1d7914(0x200)]===_0x1d7914(0x219))return'';throw CliErrors[_0x1d7914(0x1fb)](_0x1d7914(0x213),_0x1d7914(0x22b));}function readBusinessGroupFromDatasetDetail(_0x5a1387,_0x44ab77){const _0x5c59a2=a60_0x447e0f,_0x59e2ce=asPlainObject(_0x5a1387[_0x5c59a2(0x22d)]),_0x35a4fa=firstPresent(_0x5a1387[_0x5c59a2(0x230)]);if(_0x35a4fa['found'])return _0x35a4fa;const _0x34eedc=firstPresent(_0x59e2ce[_0x5c59a2(0x230)]);if(_0x34eedc[_0x5c59a2(0x20b)])return _0x34eedc;if(_0x44ab77===_0x5c59a2(0x217))return{'found':![]};const _0x5d4b68=readBusinessGroupFromExtend(_0x5a1387[_0x5c59a2(0x206)]);if(_0x5d4b68[_0x5c59a2(0x20b)])return _0x5d4b68;return readBusinessGroupFromExtend(_0x59e2ce['extend']);}function readBusinessGroupFromExtend(_0x223bae){const _0x5a4534=a60_0x447e0f;if(_0x223bae===undefined||_0x223bae===null||_0x223bae==='')return{'found':![]};if(typeof _0x223bae===_0x5a4534(0x20e))try{const _0x2a0ecb=JSON[_0x5a4534(0x216)](_0x223bae);return readBusinessGroupFromExtend(_0x2a0ecb);}catch{return{'found':![]};}const _0x8e89c9=asPlainObject(_0x223bae);if(Object['prototype']['hasOwnProperty'][_0x5a4534(0x22a)](_0x8e89c9,_0x5a4534(0x230)))return{'found':!![],'value':_0x8e89c9[_0x5a4534(0x230)]};return{'found':![]};}function firstPresent(..._0x484839){for(const _0x2dc5df of _0x484839){if(_0x2dc5df!==undefined&&_0x2dc5df!==null)return{'found':!![],'value':_0x2dc5df};}return{'found':![]};}function assertExpectedBusinessGroup(_0x1281a3,_0x17d3f7){const _0x5e9f32=a60_0x447e0f;if(_0x17d3f7===undefined)return;const _0x545308=normalizeBusinessGroup(_0x17d3f7);if(_0x1281a3!==_0x545308)throw CliErrors[_0x5e9f32(0x1fb)](_0x5e9f32(0x1fe),_0x5e9f32(0x226)+JSON[_0x5e9f32(0x21a)](_0x545308)+_0x5e9f32(0x201)+JSON[_0x5e9f32(0x21a)](_0x1281a3));}function buildBackendPayload(_0x35185b,_0x2602b6,_0x26016b){const _0x418347=a60_0x447e0f;return{'appCode':_0x35185b,'datasetCode':_0x2602b6[_0x418347(0x208)],'businessGroup':_0x26016b};}function normalizeBusinessGroup(_0x580c6e){const _0x328b3c=a60_0x447e0f;if(_0x580c6e===undefined||_0x580c6e===null)return'';return String(_0x580c6e)[_0x328b3c(0x205)]();}function asPlainObject(_0x30d66a){const _0x1da9d1=a60_0x447e0f;if(!_0x30d66a||typeof _0x30d66a!==_0x1da9d1(0x214)||Array[_0x1da9d1(0x210)](_0x30d66a))return{};return _0x30d66a;}function firstString(..._0x876820){const _0x58e36d=a60_0x447e0f;for(const _0x3b18c8 of _0x876820){if(typeof _0x3b18c8===_0x58e36d(0x20e)&&_0x3b18c8[_0x58e36d(0x205)]())return _0x3b18c8[_0x58e36d(0x205)]();if(typeof _0x3b18c8==='number'&&Number[_0x58e36d(0x21b)](_0x3b18c8))return String(_0x3b18c8);}return undefined;}function firstNumber(..._0x24903c){const _0x543143=a60_0x447e0f;for(const _0x10660b of _0x24903c){if(typeof _0x10660b===_0x543143(0x21e)&&Number[_0x543143(0x21b)](_0x10660b))return _0x10660b;if(typeof _0x10660b==='string'&&_0x10660b[_0x543143(0x205)]()&&Number[_0x543143(0x21b)](Number(_0x10660b)))return Number(_0x10660b);}return null;}function trim(_0x347e94){const _0x5a11cd=a60_0x447e0f;return String(_0x347e94||'')[_0x5a11cd(0x205)]();}
@@ -1 +1 @@
1
- const a61_0x3587cb=a61_0x231c;(function(_0x3dcb06,_0x328015){const _0x5b6423=a61_0x231c,_0x1b942b=_0x3dcb06();while(!![]){try{const _0x450230=-parseInt(_0x5b6423(0x197))/0x1*(-parseInt(_0x5b6423(0x1a7))/0x2)+parseInt(_0x5b6423(0x1b4))/0x3*(-parseInt(_0x5b6423(0x1b0))/0x4)+parseInt(_0x5b6423(0x19c))/0x5*(parseInt(_0x5b6423(0x1a2))/0x6)+-parseInt(_0x5b6423(0x1a6))/0x7+parseInt(_0x5b6423(0x1ae))/0x8+parseInt(_0x5b6423(0x1ac))/0x9*(-parseInt(_0x5b6423(0x195))/0xa)+-parseInt(_0x5b6423(0x1a1))/0xb;if(_0x450230===_0x328015)break;else _0x1b942b['push'](_0x1b942b['shift']());}catch(_0x3920c7){_0x1b942b['push'](_0x1b942b['shift']());}}}(a61_0x43b8,0x64a2c));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':a61_0x3587cb(0x1b3),'filter':a61_0x3587cb(0x194),'getOne':a61_0x3587cb(0x1b8)};export const RUNTIME_DATA_ACCESS_SUMMARY='Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.';function valueToString(_0x4fc3eb){const _0x5e1e42=a61_0x3587cb;return _0x4fc3eb==null?'':String(_0x4fc3eb)[_0x5e1e42(0x1b7)]();}function getDatasetCode(_0x5d2b3e){const _0x16f72b=a61_0x3587cb;return valueToString(_0x5d2b3e[_0x16f72b(0x1aa)]??_0x5d2b3e[_0x16f72b(0x1a5)]??_0x5d2b3e['dataset']?.[_0x16f72b(0x198)]);}function getDatasetName(_0x3538ee){const _0x39af4a=a61_0x3587cb;return valueToString(_0x3538ee[_0x39af4a(0x1af)]??_0x3538ee[_0x39af4a(0x1b1)]?.[_0x39af4a(0x1a0)])||_0x39af4a(0x1ba);}function getDatasetSource(_0x460faa){const _0x1d8d42=a61_0x3587cb;return valueToString(_0x460faa['source']??_0x460faa[_0x1d8d42(0x1b1)]?.[_0x1d8d42(0x19d)])[_0x1d8d42(0x1a4)]();}function getDbtableConfig(_0x35bea0){const _0x1c8c55=a61_0x3587cb,_0xb5c27c=_0x35bea0[_0x1c8c55(0x1a8)]??_0x35bea0['dbtable'];return _0xb5c27c&&typeof _0xb5c27c===_0x1c8c55(0x1b9)?_0xb5c27c:{};}function a61_0x231c(_0x45e2fe,_0x5b4b10){_0x45e2fe=_0x45e2fe-0x194;const _0x43b8c1=a61_0x43b8();let _0x231c58=_0x43b8c1[_0x45e2fe];return _0x231c58;}export function isDbTableBackedDataset(_0x2c730f){const _0x56bd17=a61_0x3587cb,_0x1689e5=getDatasetSource(_0x2c730f);if(_0x1689e5===_0x56bd17(0x19b))return![];const _0x5ed6b2=getDbtableConfig(_0x2c730f),_0x4aebb9=_0x5ed6b2[_0x56bd17(0x199)]??_0x5ed6b2['id'],_0x2110d0=valueToString(_0x5ed6b2['tableName']??_0x2c730f[_0x56bd17(0x1b2)]??_0x2c730f[_0x56bd17(0x1b1)]?.[_0x56bd17(0x1b2)]);return _0x4aebb9!==undefined&&_0x4aebb9!==null&&_0x2110d0['length']>0x0;}function a61_0x43b8(){const _0x3cfe35=['\x20类型,没有可用于\x20','datasetName','7514892KIrxRe','587094sGAuNx','filter','toUpperCase','modelCode','1413307CVMRqn','4vLHyFg','dbtableConfig','\x20是\x20','code','join','9KQzEje','\x20的\x20DB_TABLE\x20数据源上下文。','3366040WXLRLr','name','219016DpcxWk','dataset','tableName','lovrabet','21xTDTbO','validation','UNKNOWN','trim','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress','object','unknown','如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:','SQL\x20schema\x20validation','请先将该数据集升级/迁移为\x20DB_TABLE\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','395170wWDDfE','原因:schema\x20introspection\x20与\x20custom\x20SQL\x20需要\x20source=DB_TABLE、dbtableConfig.dbId、dbtableConfig.tableName\x20与数据库连接上下文。','405036EEOiqJ','datasetCode','dbId','当前数据集\x20\x22','METADATA','25GJoFjK','sourceType','getOne'];a61_0x43b8=function(){return _0x3cfe35;};return a61_0x43b8();}export function filterDbTableBackedDatasets(_0x1f4069){return _0x1f4069['filter'](_0x501211=>isDbTableBackedDataset(_0x501211));}export function buildDbTableBackedRequirementMessage(_0xc31bdd,_0x30a9e5=a61_0x3587cb(0x1bc)){const _0xb5b40f=a61_0x3587cb,_0x26594f=getDatasetSource(_0xc31bdd)||_0xb5b40f(0x1b6),_0x56ee7d=getDatasetName(_0xc31bdd),_0x203f7c=getDatasetCode(_0xc31bdd),_0x9a64dc=_0x203f7c?'\x20('+_0x203f7c+')':'';return[_0xb5b40f(0x19a)+_0x56ee7d+'\x22'+_0x9a64dc+_0xb5b40f(0x1a9)+_0x26594f+_0xb5b40f(0x19f)+_0x30a9e5+_0xb5b40f(0x1ad),_0xb5b40f(0x196),_0xb5b40f(0x1bd),_0xb5b40f(0x1bb)+RUNTIME_DATA_ACCESS_COMMANDS[_0xb5b40f(0x1a3)]+';'+RUNTIME_DATA_ACCESS_COMMANDS[_0xb5b40f(0x19e)]+'。'][_0xb5b40f(0x1ab)]('\x20');}export function assertDatasetIsDbTableBacked(_0x1877e1,_0x5cbaf6){const _0x5b8c57=a61_0x3587cb;if(!isDbTableBackedDataset(_0x1877e1))throw CliErrors[_0x5b8c57(0x1b5)](buildDbTableBackedRequirementMessage(_0x1877e1,_0x5cbaf6));}
1
+ function a61_0x17ff(){const _0x1be216=['请先将该数据集升级/迁移为\x20DB_TABLE\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','dbtableConfig','object','Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.','4020004iFeQZb','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress','\x20类型,没有可用于\x20','METADATA','\x20的\x20DB_TABLE\x20数据源上下文。','name','原因:schema\x20introspection\x20与\x20custom\x20SQL\x20需要\x20source=DB_TABLE、dbtableConfig.dbId、dbtableConfig.tableName\x20与数据库连接上下文。','2116866KTbmWf','10chTLrI','1981840ESUfyg','2377010hYEpWV','UNKNOWN','dbId','2504FxrAzh','code','trim','8bBmFZb','validation','18NEcFki','tableName','420HervLJ','join','datasetName','33703439SmHFUZ','source','如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:','dataset','3706947xYbaAd','unknown','dbtable','lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','modelCode','sourceType'];a61_0x17ff=function(){return _0x1be216;};return a61_0x17ff();}const a61_0x4a1241=a61_0x5d93;(function(_0x1938b1,_0x1875df){const _0x1d8b5f=a61_0x5d93,_0x3b6539=_0x1938b1();while(!![]){try{const _0x4d2a52=parseInt(_0x1d8b5f(0xea))/0x1*(-parseInt(_0x1d8b5f(0xf1))/0x2)+-parseInt(_0x1d8b5f(0x109))/0x3+parseInt(_0x1d8b5f(0x102))/0x4+parseInt(_0x1d8b5f(0x10c))/0x5*(-parseInt(_0x1d8b5f(0xef))/0x6)+parseInt(_0x1d8b5f(0x10b))/0x7*(-parseInt(_0x1d8b5f(0xed))/0x8)+-parseInt(_0x1d8b5f(0xf8))/0x9*(parseInt(_0x1d8b5f(0x10a))/0xa)+parseInt(_0x1d8b5f(0xf4))/0xb;if(_0x4d2a52===_0x1875df)break;else _0x3b6539['push'](_0x3b6539['shift']());}catch(_0x27f2c7){_0x3b6539['push'](_0x3b6539['shift']());}}}(a61_0x17ff,0xaedf7));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':'lovrabet','filter':a61_0x4a1241(0xfb),'getOne':a61_0x4a1241(0x103)};export const RUNTIME_DATA_ACCESS_SUMMARY=a61_0x4a1241(0x101);function valueToString(_0x4d209f){const _0x21f630=a61_0x4a1241;return _0x4d209f==null?'':String(_0x4d209f)[_0x21f630(0xec)]();}function getDatasetCode(_0x4a281b){const _0x519211=a61_0x4a1241;return valueToString(_0x4a281b[_0x519211(0xeb)]??_0x4a281b[_0x519211(0xfc)]??_0x4a281b[_0x519211(0xf7)]?.['datasetCode']);}function getDatasetName(_0x5f4641){const _0x39ca0e=a61_0x4a1241;return valueToString(_0x5f4641[_0x39ca0e(0x107)]??_0x5f4641['dataset']?.[_0x39ca0e(0xf3)])||_0x39ca0e(0xf9);}function getDatasetSource(_0xa4247f){const _0x145927=a61_0x4a1241;return valueToString(_0xa4247f[_0x145927(0xf5)]??_0xa4247f[_0x145927(0xf7)]?.[_0x145927(0xfd)])['toUpperCase']();}function getDbtableConfig(_0x3fee45){const _0x261c9d=a61_0x4a1241,_0x538c1e=_0x3fee45[_0x261c9d(0xff)]??_0x3fee45[_0x261c9d(0xfa)];return _0x538c1e&&typeof _0x538c1e===_0x261c9d(0x100)?_0x538c1e:{};}function a61_0x5d93(_0x4040ff,_0x34c067){_0x4040ff=_0x4040ff-0xea;const _0x17ff68=a61_0x17ff();let _0x5d93a1=_0x17ff68[_0x4040ff];return _0x5d93a1;}export function isDbTableBackedDataset(_0x1b6e3a){const _0x32c8f5=a61_0x4a1241,_0x55990f=getDatasetSource(_0x1b6e3a);if(_0x55990f===_0x32c8f5(0x105))return![];const _0x1d8068=getDbtableConfig(_0x1b6e3a),_0x1a2a67=_0x1d8068[_0x32c8f5(0x10e)]??_0x1d8068['id'],_0x399d6e=valueToString(_0x1d8068[_0x32c8f5(0xf0)]??_0x1b6e3a['tableName']??_0x1b6e3a[_0x32c8f5(0xf7)]?.[_0x32c8f5(0xf0)]);return _0x1a2a67!==undefined&&_0x1a2a67!==null&&_0x399d6e['length']>0x0;}export function filterDbTableBackedDatasets(_0x183177){return _0x183177['filter'](_0x1000ed=>isDbTableBackedDataset(_0x1000ed));}export function buildDbTableBackedRequirementMessage(_0x296cdd,_0x2bea22='SQL\x20schema\x20validation'){const _0x20957f=a61_0x4a1241,_0x5ea1e9=getDatasetSource(_0x296cdd)||_0x20957f(0x10d),_0x56e632=getDatasetName(_0x296cdd),_0x46df67=getDatasetCode(_0x296cdd),_0x515870=_0x46df67?'\x20('+_0x46df67+')':'';return['当前数据集\x20\x22'+_0x56e632+'\x22'+_0x515870+'\x20是\x20'+_0x5ea1e9+_0x20957f(0x104)+_0x2bea22+_0x20957f(0x106),_0x20957f(0x108),_0x20957f(0xfe),_0x20957f(0xf6)+RUNTIME_DATA_ACCESS_COMMANDS['filter']+';'+RUNTIME_DATA_ACCESS_COMMANDS['getOne']+'。'][_0x20957f(0xf2)]('\x20');}export function assertDatasetIsDbTableBacked(_0xeb9600,_0x3832e6){const _0x7c00ff=a61_0x4a1241;if(!isDbTableBackedDataset(_0xeb9600))throw CliErrors[_0x7c00ff(0xee)](buildDbTableBackedRequirementMessage(_0xeb9600,_0x3832e6));}
@@ -1 +1 @@
1
- const a62_0x402f96=a62_0xc902;(function(_0x7c4f0c,_0x4bdf40){const _0x53b9ef=a62_0xc902,_0x488f06=_0x7c4f0c();while(!![]){try{const _0x143b11=-parseInt(_0x53b9ef(0x20f))/0x1*(-parseInt(_0x53b9ef(0x215))/0x2)+parseInt(_0x53b9ef(0x210))/0x3*(-parseInt(_0x53b9ef(0x218))/0x4)+parseInt(_0x53b9ef(0x220))/0x5+-parseInt(_0x53b9ef(0x1f1))/0x6*(parseInt(_0x53b9ef(0x221))/0x7)+parseInt(_0x53b9ef(0x213))/0x8*(parseInt(_0x53b9ef(0x21e))/0x9)+-parseInt(_0x53b9ef(0x214))/0xa*(parseInt(_0x53b9ef(0x21f))/0xb)+-parseInt(_0x53b9ef(0x201))/0xc*(-parseInt(_0x53b9ef(0x1ff))/0xd);if(_0x143b11===_0x4bdf40)break;else _0x488f06['push'](_0x488f06['shift']());}catch(_0x4293d3){_0x488f06['push'](_0x488f06['shift']());}}}(a62_0x384c,0x8f5a7));function a62_0xc902(_0x2ff215,_0x20c09f){_0x2ff215=_0x2ff215-0x1f0;const _0x384c73=a62_0x384c();let _0xc9022f=_0x384c73[_0x2ff215];return _0xc9022f;}import{deleteDataset,listDatasets}from'../../core/api-client.js';function a62_0x384c(){const _0x1b5cff=['Delete\x20dataset\x20metadata\x20by\x20id/code\x20or\x20all\x20datasets\x20under\x20a\x20db\x20id','5268wcaeMB','source','name','Would\x20delete\x20','filter','Dataset\x20id','relationPages','expected-count','\x20dataset(s).\x20This\x20only\x20deletes\x20platform\x20dataset\x20metadata\x20and\x20related\x20page/menu\x20records,\x20not\x20physical\x20databases\x20or\x20tables.','Deleted\x20','\x20failed','id=','dbId','push','1Dsjplf','3uyqnhO','\x20dataset(s)','dbid','16snAfUF','20TIyZbY','943348OCHncy','confirm','/smartapi/dataset/delete-dataset','4443320YBanXU','high-risk-write','tableName','message','\x20dataset(s),\x20but\x20--expected-count\x20is\x20','map','3703977WGVBVN','4710882fBCgLE','182260htAZEU','14bTIBsg','delete','\x20dataset(s);\x20','num','number','length','2305338QyzdNr','code','dbid=','bool','Delete\x20all\x20datasets\x20under\x20this\x20database\x20connection\x20id','dataset','dbtableConfig','str','validation','description','Matched\x20','One\x20of\x20--id,\x20--code,\x20or\x20--dbid\x20is\x20required.','isArray','appCode','58981lpucXF'];a62_0x384c=function(){return _0x1b5cff;};return a62_0x384c();}import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL,CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';const DATASET_ID_FLAG={'name':'id','type':a62_0x402f96(0x225),'description':a62_0x402f96(0x206)},DBID_FLAG={'name':'dbid','type':a62_0x402f96(0x225),'description':a62_0x402f96(0x1f5)},CONFIRM_FLAG={'name':a62_0x402f96(0x216),'type':'boolean','description':'Required\x20to\x20execute\x20dataset\x20deletion'},EXPECTED_COUNT_FLAG={'name':a62_0x402f96(0x208),'type':a62_0x402f96(0x225),'description':'Abort\x20unless\x20the\x20matched\x20dataset\x20count\x20equals\x20this\x20value'};export const datasetDelete={'service':a62_0x402f96(0x1f6),'command':a62_0x402f96(0x222),'description':a62_0x402f96(0x200),'risk':a62_0x402f96(0x219),'flags':[DATASET_ID_FLAG,CODE_FLAG_OPTIONAL,DBID_FLAG,CONFIRM_FLAG,EXPECTED_COUNT_FLAG,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x197e54){const _0x2732b2=a62_0x402f96,_0x44794f=_0x197e54['num']('id'),_0x32c21d=_0x197e54[_0x2732b2(0x1f8)](_0x2732b2(0x1f2)),_0x148431=_0x197e54[_0x2732b2(0x224)](_0x2732b2(0x212)),_0x1d8bb4=[_0x44794f>0x0,Boolean(_0x32c21d),_0x148431>0x0][_0x2732b2(0x205)](Boolean);if(_0x1d8bb4[_0x2732b2(0x1f0)]===0x0)throw CliErrors[_0x2732b2(0x1f9)](_0x2732b2(0x1fc));if(_0x1d8bb4[_0x2732b2(0x1f0)]>0x1)throw CliErrors['validation']('Use\x20only\x20one\x20of\x20--id,\x20--code,\x20or\x20--dbid.');},async 'dryRun'(_0x329142){const _0x220899=a62_0x402f96,_0x1c7881=await resolveTargets(_0x329142);return{'method':'POST','url':_0x220899(0x217),'body':{'appCode':_0x329142['appCode'],'count':_0x1c7881[_0x220899(0x1f0)],'datasets':_0x1c7881},'description':_0x220899(0x204)+_0x1c7881[_0x220899(0x1f0)]+_0x220899(0x209)};},async 'execute'(_0x20676e){const _0x383254=a62_0x402f96;if(!_0x20676e[_0x383254(0x1f4)](_0x383254(0x216)))throw CliErrors['validation']('--confirm\x20is\x20required\x20to\x20delete\x20datasets.','Run\x20with\x20--dry-run\x20first,\x20then\x20add\x20--confirm\x20when\x20the\x20target\x20list\x20is\x20correct.');const _0x366373=await resolveTargets(_0x20676e),_0x36453a=[],_0x460ec5=[];for(const _0x435202 of _0x366373){try{await deleteDataset(_0x20676e[_0x383254(0x1fe)],_0x435202['id']),_0x36453a[_0x383254(0x20e)](_0x435202);}catch(_0x4f0fcc){_0x460ec5['push']({..._0x435202,'error':_0x4f0fcc instanceof Error?_0x4f0fcc[_0x383254(0x21b)]:String(_0x4f0fcc)});}}if(_0x460ec5[_0x383254(0x1f0)]>0x0)return{'ok':![],'data':{'requested':_0x366373['length'],'deletedCount':_0x36453a[_0x383254(0x1f0)],'failedCount':_0x460ec5[_0x383254(0x1f0)],'deleted':_0x36453a,'failed':_0x460ec5},'message':_0x383254(0x20a)+_0x36453a[_0x383254(0x1f0)]+'/'+_0x366373[_0x383254(0x1f0)]+_0x383254(0x223)+_0x460ec5['length']+_0x383254(0x20b)};return{'ok':!![],'data':{'requested':_0x366373[_0x383254(0x1f0)],'deletedCount':_0x36453a[_0x383254(0x1f0)],'deleted':_0x36453a},'message':'Deleted\x20'+_0x36453a['length']+_0x383254(0x211)};}};async function resolveTargets(_0x3329fd){const _0x4c0840=a62_0x402f96,_0x414128=_0x3329fd[_0x4c0840(0x224)]('id'),_0x15b313=_0x3329fd[_0x4c0840(0x1f8)]('code'),_0x5d701a=_0x3329fd[_0x4c0840(0x224)](_0x4c0840(0x212));let _0x2e10d6;_0x15b313?(_0x2e10d6=await listDatasets(_0x3329fd[_0x4c0840(0x1fe)],{'code':_0x15b313}),_0x2e10d6=_0x2e10d6[_0x4c0840(0x205)](_0x30975b=>_0x30975b[_0x4c0840(0x1f2)]===_0x15b313)):(_0x2e10d6=await listDatasets(_0x3329fd[_0x4c0840(0x1fe)]),_0x414128>0x0&&(_0x2e10d6=_0x2e10d6[_0x4c0840(0x205)](_0x687a1f=>_0x687a1f['id']===_0x414128)),_0x5d701a>0x0&&(_0x2e10d6=_0x2e10d6[_0x4c0840(0x205)](_0x23cf2f=>_0x23cf2f[_0x4c0840(0x1f7)]?.[_0x4c0840(0x20d)]===_0x5d701a)));const _0xa97d=_0x2e10d6[_0x4c0840(0x21d)](normalizeTarget);if(_0xa97d['length']===0x0){const _0x51f495=_0x15b313||(_0x414128>0x0?_0x4c0840(0x20c)+_0x414128:_0x4c0840(0x1f3)+_0x5d701a);throw CliErrors[_0x4c0840(0x1f9)]('No\x20undeleted\x20dataset\x20found\x20for\x20'+_0x51f495+'.');}const _0xf674b0=_0x3329fd['num'](_0x4c0840(0x208));if(_0xf674b0>0x0&&_0xa97d['length']!==_0xf674b0)throw CliErrors[_0x4c0840(0x1f9)](_0x4c0840(0x1fb)+_0xa97d[_0x4c0840(0x1f0)]+_0x4c0840(0x21c)+_0xf674b0+'.');return _0xa97d;}function normalizeTarget(_0x4abbfb){const _0x4517bd=a62_0x402f96,_0x741af3=_0x4abbfb[_0x4517bd(0x1f7)]??{};return{'id':_0x4abbfb['id'],'code':_0x4abbfb[_0x4517bd(0x1f2)],'name':_0x4abbfb[_0x4517bd(0x203)],'description':_0x4abbfb[_0x4517bd(0x1fa)],'source':_0x4abbfb[_0x4517bd(0x202)],'dbId':_0x741af3['dbId'],'dbName':_0x741af3['dbName'],'tableName':_0x741af3[_0x4517bd(0x21a)],'relatedPageCount':Array[_0x4517bd(0x1fd)](_0x4abbfb[_0x4517bd(0x207)])?_0x4abbfb[_0x4517bd(0x207)]['length']:undefined};}
1
+ const a62_0x4cdae3=a62_0x45cd;(function(_0x356879,_0x4a4bd6){const _0x1bedf5=a62_0x45cd,_0x2cd428=_0x356879();while(!![]){try{const _0x3f5aae=-parseInt(_0x1bedf5(0x1d3))/0x1+-parseInt(_0x1bedf5(0x1b1))/0x2+-parseInt(_0x1bedf5(0x1e4))/0x3*(-parseInt(_0x1bedf5(0x1b7))/0x4)+parseInt(_0x1bedf5(0x1ca))/0x5*(-parseInt(_0x1bedf5(0x1af))/0x6)+-parseInt(_0x1bedf5(0x1c3))/0x7+parseInt(_0x1bedf5(0x1c2))/0x8*(parseInt(_0x1bedf5(0x1d0))/0x9)+parseInt(_0x1bedf5(0x1d9))/0xa;if(_0x3f5aae===_0x4a4bd6)break;else _0x2cd428['push'](_0x2cd428['shift']());}catch(_0x3fa4a6){_0x2cd428['push'](_0x2cd428['shift']());}}}(a62_0x13cf,0x1d76b));function a62_0x45cd(_0x537b2d,_0x5e2fcb){_0x537b2d=_0x537b2d-0x1af;const _0x13cf6f=a62_0x13cf();let _0x45cdc3=_0x13cf6f[_0x537b2d];return _0x45cdc3;}import{deleteDataset,listDatasets}from'../../core/api-client.js';function a62_0x13cf(){const _0x3bb98c=['length','\x20failed','push','--confirm\x20is\x20required\x20to\x20delete\x20datasets.','858QnxCQb','name','boolean','942upqtrF','/smartapi/dataset/delete-dataset','466610qESwNO','str','map','expected-count','id=','Run\x20with\x20--dry-run\x20first,\x20then\x20add\x20--confirm\x20when\x20the\x20target\x20list\x20is\x20correct.','1516nAWjeo','Would\x20delete\x20','high-risk-write','isArray','validation','\x20dataset(s);\x20','One\x20of\x20--id,\x20--code,\x20or\x20--dbid\x20is\x20required.','description','confirm','Delete\x20dataset\x20metadata\x20by\x20id/code\x20or\x20all\x20datasets\x20under\x20a\x20db\x20id','\x20dataset(s),\x20but\x20--expected-count\x20is\x20','12776GuMNQV','85295XoYMen','dbtableConfig','\x20dataset(s).\x20This\x20only\x20deletes\x20platform\x20dataset\x20metadata\x20and\x20related\x20page/menu\x20records,\x20not\x20physical\x20databases\x20or\x20tables.','delete','code','POST','dbid','465XSSEEi','appCode','Dataset\x20id','tableName','dbId','filter','1035EhLwFI','Delete\x20all\x20datasets\x20under\x20this\x20database\x20connection\x20id','num','214782KQjgvy','Use\x20only\x20one\x20of\x20--id,\x20--code,\x20or\x20--dbid.','dbName','dbid=','Deleted\x20','message','3035070IWeUKg','Required\x20to\x20execute\x20dataset\x20deletion','\x20dataset(s)','bool','source','relationPages','number'];a62_0x13cf=function(){return _0x3bb98c;};return a62_0x13cf();}import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL,CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';const DATASET_ID_FLAG={'name':'id','type':a62_0x4cdae3(0x1df),'description':a62_0x4cdae3(0x1cc)},DBID_FLAG={'name':a62_0x4cdae3(0x1c9),'type':a62_0x4cdae3(0x1df),'description':a62_0x4cdae3(0x1d1)},CONFIRM_FLAG={'name':a62_0x4cdae3(0x1bf),'type':a62_0x4cdae3(0x1e6),'description':a62_0x4cdae3(0x1da)},EXPECTED_COUNT_FLAG={'name':a62_0x4cdae3(0x1b4),'type':a62_0x4cdae3(0x1df),'description':'Abort\x20unless\x20the\x20matched\x20dataset\x20count\x20equals\x20this\x20value'};export const datasetDelete={'service':'dataset','command':a62_0x4cdae3(0x1c6),'description':a62_0x4cdae3(0x1c0),'risk':a62_0x4cdae3(0x1b9),'flags':[DATASET_ID_FLAG,CODE_FLAG_OPTIONAL,DBID_FLAG,CONFIRM_FLAG,EXPECTED_COUNT_FLAG,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x531b93){const _0x4e5854=a62_0x4cdae3,_0x2b1219=_0x531b93['num']('id'),_0x3ef47c=_0x531b93['str'](_0x4e5854(0x1c7)),_0x17200a=_0x531b93['num'](_0x4e5854(0x1c9)),_0x7a9fd5=[_0x2b1219>0x0,Boolean(_0x3ef47c),_0x17200a>0x0][_0x4e5854(0x1cf)](Boolean);if(_0x7a9fd5['length']===0x0)throw CliErrors[_0x4e5854(0x1bb)](_0x4e5854(0x1bd));if(_0x7a9fd5[_0x4e5854(0x1e0)]>0x1)throw CliErrors[_0x4e5854(0x1bb)](_0x4e5854(0x1d4));},async 'dryRun'(_0x54324a){const _0x2e7deb=a62_0x4cdae3,_0x428898=await resolveTargets(_0x54324a);return{'method':_0x2e7deb(0x1c8),'url':_0x2e7deb(0x1b0),'body':{'appCode':_0x54324a[_0x2e7deb(0x1cb)],'count':_0x428898[_0x2e7deb(0x1e0)],'datasets':_0x428898},'description':_0x2e7deb(0x1b8)+_0x428898[_0x2e7deb(0x1e0)]+_0x2e7deb(0x1c5)};},async 'execute'(_0x349be7){const _0x43eb6d=a62_0x4cdae3;if(!_0x349be7[_0x43eb6d(0x1dc)](_0x43eb6d(0x1bf)))throw CliErrors[_0x43eb6d(0x1bb)](_0x43eb6d(0x1e3),_0x43eb6d(0x1b6));const _0x15d5ad=await resolveTargets(_0x349be7),_0x3dc4e6=[],_0x9da9f5=[];for(const _0x130c1c of _0x15d5ad){try{await deleteDataset(_0x349be7[_0x43eb6d(0x1cb)],_0x130c1c['id']),_0x3dc4e6['push'](_0x130c1c);}catch(_0x4bcb0e){_0x9da9f5[_0x43eb6d(0x1e2)]({..._0x130c1c,'error':_0x4bcb0e instanceof Error?_0x4bcb0e[_0x43eb6d(0x1d8)]:String(_0x4bcb0e)});}}if(_0x9da9f5[_0x43eb6d(0x1e0)]>0x0)return{'ok':![],'data':{'requested':_0x15d5ad[_0x43eb6d(0x1e0)],'deletedCount':_0x3dc4e6['length'],'failedCount':_0x9da9f5[_0x43eb6d(0x1e0)],'deleted':_0x3dc4e6,'failed':_0x9da9f5},'message':_0x43eb6d(0x1d7)+_0x3dc4e6[_0x43eb6d(0x1e0)]+'/'+_0x15d5ad[_0x43eb6d(0x1e0)]+_0x43eb6d(0x1bc)+_0x9da9f5['length']+_0x43eb6d(0x1e1)};return{'ok':!![],'data':{'requested':_0x15d5ad['length'],'deletedCount':_0x3dc4e6[_0x43eb6d(0x1e0)],'deleted':_0x3dc4e6},'message':_0x43eb6d(0x1d7)+_0x3dc4e6['length']+_0x43eb6d(0x1db)};}};async function resolveTargets(_0x2da6b9){const _0x4624f2=a62_0x4cdae3,_0x4c0e80=_0x2da6b9[_0x4624f2(0x1d2)]('id'),_0x2e406a=_0x2da6b9[_0x4624f2(0x1b2)](_0x4624f2(0x1c7)),_0xc5b345=_0x2da6b9[_0x4624f2(0x1d2)](_0x4624f2(0x1c9));let _0x1b123d;_0x2e406a?(_0x1b123d=await listDatasets(_0x2da6b9[_0x4624f2(0x1cb)],{'code':_0x2e406a}),_0x1b123d=_0x1b123d['filter'](_0x218f43=>_0x218f43[_0x4624f2(0x1c7)]===_0x2e406a)):(_0x1b123d=await listDatasets(_0x2da6b9[_0x4624f2(0x1cb)]),_0x4c0e80>0x0&&(_0x1b123d=_0x1b123d[_0x4624f2(0x1cf)](_0x1a457e=>_0x1a457e['id']===_0x4c0e80)),_0xc5b345>0x0&&(_0x1b123d=_0x1b123d[_0x4624f2(0x1cf)](_0x1ede9a=>_0x1ede9a[_0x4624f2(0x1c4)]?.[_0x4624f2(0x1ce)]===_0xc5b345)));const _0x20fcea=_0x1b123d[_0x4624f2(0x1b3)](normalizeTarget);if(_0x20fcea[_0x4624f2(0x1e0)]===0x0){const _0x14f37a=_0x2e406a||(_0x4c0e80>0x0?_0x4624f2(0x1b5)+_0x4c0e80:_0x4624f2(0x1d6)+_0xc5b345);throw CliErrors[_0x4624f2(0x1bb)]('No\x20undeleted\x20dataset\x20found\x20for\x20'+_0x14f37a+'.');}const _0x5bda9d=_0x2da6b9[_0x4624f2(0x1d2)](_0x4624f2(0x1b4));if(_0x5bda9d>0x0&&_0x20fcea[_0x4624f2(0x1e0)]!==_0x5bda9d)throw CliErrors[_0x4624f2(0x1bb)]('Matched\x20'+_0x20fcea[_0x4624f2(0x1e0)]+_0x4624f2(0x1c1)+_0x5bda9d+'.');return _0x20fcea;}function normalizeTarget(_0x12e4da){const _0x4f19be=a62_0x4cdae3,_0x1b8df2=_0x12e4da[_0x4f19be(0x1c4)]??{};return{'id':_0x12e4da['id'],'code':_0x12e4da['code'],'name':_0x12e4da[_0x4f19be(0x1e5)],'description':_0x12e4da[_0x4f19be(0x1be)],'source':_0x12e4da[_0x4f19be(0x1dd)],'dbId':_0x1b8df2['dbId'],'dbName':_0x1b8df2[_0x4f19be(0x1d5)],'tableName':_0x1b8df2[_0x4f19be(0x1cd)],'relatedPageCount':Array[_0x4f19be(0x1ba)](_0x12e4da[_0x4f19be(0x1de)])?_0x12e4da[_0x4f19be(0x1de)][_0x4f19be(0x1e0)]:undefined};}
@@ -1 +1 @@
1
- const a63_0x16940c=a63_0x5a02;function a63_0x5a02(_0x2353f9,_0x2690ef){_0x2353f9=_0x2353f9-0x1a0;const _0x3526e7=a63_0x3526();let _0x5a02f5=_0x3526e7[_0x2353f9];return _0x5a02f5;}(function(_0x1bf508,_0x5ea7df){const _0x505317=a63_0x5a02,_0x27a951=_0x1bf508();while(!![]){try{const _0x115f75=parseInt(_0x505317(0x1c3))/0x1*(-parseInt(_0x505317(0x1be))/0x2)+parseInt(_0x505317(0x1ae))/0x3*(-parseInt(_0x505317(0x1af))/0x4)+parseInt(_0x505317(0x1d8))/0x5+-parseInt(_0x505317(0x1b3))/0x6*(-parseInt(_0x505317(0x1d3))/0x7)+parseInt(_0x505317(0x1a7))/0x8*(-parseInt(_0x505317(0x1f2))/0x9)+parseInt(_0x505317(0x1cb))/0xa+parseInt(_0x505317(0x1db))/0xb;if(_0x115f75===_0x5ea7df)break;else _0x27a951['push'](_0x27a951['shift']());}catch(_0x2003c5){_0x27a951['push'](_0x27a951['shift']());}}}(a63_0x3526,0x329f2));import{getDatasetDetail}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function normalizeField(_0x2d26eb){const _0x4c7f47=a63_0x5a02;if(_0x2d26eb[_0x4c7f47(0x1e9)])return null;const _0x2c7f12=Boolean(_0x2d26eb[_0x4c7f47(0x1e6)]!==undefined||_0x2d26eb[_0x4c7f47(0x1df)]!==undefined);let _0x145345={};if(!_0x2c7f12&&typeof _0x2d26eb[_0x4c7f47(0x1b0)]===_0x4c7f47(0x1bd))try{_0x145345=JSON[_0x4c7f47(0x1f0)](_0x2d26eb[_0x4c7f47(0x1b0)]);}catch{}const _0x1c882f=_0x2c7f12?_0x2d26eb[_0x4c7f47(0x1a2)]:_0x2d26eb[_0x4c7f47(0x1c0)],_0x38c052=_0x2c7f12?_0x2d26eb['displayName']:_0x2d26eb['name'],_0x9316f2=_0x2c7f12?_0x2d26eb[_0x4c7f47(0x1df)]:_0x2d26eb[_0x4c7f47(0x1c4)]||_0x2d26eb[_0x4c7f47(0x1e5)],_0x5a26b1=_0x2c7f12?_0x2d26eb[_0x4c7f47(0x1a3)]===!![]:_0x145345[_0x4c7f47(0x1a3)]===!![],_0x471ff6=_0x2c7f12?_0x2d26eb[_0x4c7f47(0x1d4)]===!![]:_0x145345['required']===!![],_0x3a2146=_0x2c7f12?_0x2d26eb[_0x4c7f47(0x1e2)]??null:_0x145345[_0x4c7f47(0x1e2)]??null,_0x4d1062={'name':_0x1c882f,'displayName':_0x38c052||_0x1c882f,'type':_0x9316f2,'dbType':_0x2d26eb['dbType'],'pk':_0x5a26b1,'required':_0x471ff6,'deprecated':_0x2d26eb[_0x4c7f47(0x1b5)]===!![],'description':_0x2d26eb[_0x4c7f47(0x1aa)]||undefined};return Array[_0x4c7f47(0x1cc)](_0x3a2146)&&_0x3a2146[_0x4c7f47(0x1b4)]>0x0&&(_0x4d1062[_0x4c7f47(0x1e2)]=_0x3a2146),_0x4d1062;}function parseJsonMaybe(_0x5a9e49){const _0x463892=a63_0x5a02;if(typeof _0x5a9e49!==_0x463892(0x1bd))return _0x5a9e49;try{return JSON[_0x463892(0x1f0)](_0x5a9e49);}catch{return _0x5a9e49;}}function normalizeOperationEntry(_0x30ecfb,_0x28d7d6){const _0x523ae0=a63_0x5a02;if(!_0x28d7d6||typeof _0x28d7d6!==_0x523ae0(0x1ea))return null;if(!_0x28d7d6['method']||!_0x28d7d6['path'])return null;const _0x24d43a={'name':_0x30ecfb,'method':_0x28d7d6[_0x523ae0(0x1e1)],'path':_0x28d7d6[_0x523ae0(0x1e0)]};if(_0x28d7d6[_0x523ae0(0x1a0)])_0x24d43a[_0x523ae0(0x1a0)]=_0x28d7d6[_0x523ae0(0x1a0)];if(_0x28d7d6[_0x523ae0(0x1a4)]!=null){const _0x391299=parseJsonMaybe(_0x28d7d6[_0x523ae0(0x1a4)]);_0x24d43a[_0x523ae0(0x1a4)]=_0x391299;}if(_0x28d7d6[_0x523ae0(0x1bf)]!=null){const _0x18effe=parseJsonMaybe(_0x28d7d6['responseBody']);_0x24d43a['responseBody']=_0x18effe;}if(_0x28d7d6[_0x523ae0(0x1b1)]!=null)_0x24d43a[_0x523ae0(0x1b1)]=_0x28d7d6['beforeScriptId'];if(_0x28d7d6['afterScriptId']!=null)_0x24d43a['afterScriptId']=_0x28d7d6['afterScriptId'];if(Array['isArray'](_0x28d7d6[_0x523ae0(0x1d1)]))_0x24d43a[_0x523ae0(0x1d1)]=_0x28d7d6[_0x523ae0(0x1d1)];if(Array[_0x523ae0(0x1cc)](_0x28d7d6['responseFields']))_0x24d43a[_0x523ae0(0x1d7)]=_0x28d7d6[_0x523ae0(0x1d7)];return _0x24d43a;}function summarizeDbtable(_0x5557ff){const _0x22c262=a63_0x5a02,_0xdb77b6={},_0x2ad296=[_0x22c262(0x1ab),_0x22c262(0x1bb),_0x22c262(0x1b9),_0x22c262(0x1ef),_0x22c262(0x1a3),_0x22c262(0x1d2),_0x22c262(0x1c7),'createTimeField',_0x22c262(0x1a8),_0x22c262(0x1c9),_0x22c262(0x1d0),'modifierIdField',_0x22c262(0x1e4),_0x22c262(0x1cf),_0x22c262(0x1a5)];for(const _0x48b41d of _0x2ad296){if(_0x5557ff[_0x48b41d]!==undefined)_0xdb77b6[_0x48b41d]=_0x5557ff[_0x48b41d];}return typeof _0xdb77b6['allFields']==='string'&&_0xdb77b6[_0x22c262(0x1d2)]['length']>0x0&&(_0xdb77b6[_0x22c262(0x1eb)]=_0xdb77b6['allFields'][_0x22c262(0x1da)](',')[_0x22c262(0x1c5)](_0x4ba5ac=>_0x4ba5ac[_0x22c262(0x1b8)]())[_0x22c262(0x1dd)](Boolean)),_0xdb77b6;}function normalizeRelatedPages(_0x176d09){const _0x1a0ac9=a63_0x5a02;if(!Array[_0x1a0ac9(0x1cc)](_0x176d09))return[];return _0x176d09[_0x1a0ac9(0x1dd)](_0x4de430=>_0x4de430&&typeof _0x4de430===_0x1a0ac9(0x1ea))[_0x1a0ac9(0x1c5)](_0x8169e0=>({'id':_0x8169e0['id'],'type':_0x8169e0[_0x1a0ac9(0x1c4)],'code':_0x8169e0[_0x1a0ac9(0x1c0)],'title':_0x8169e0[_0x1a0ac9(0x1ca)],'deleted':_0x8169e0[_0x1a0ac9(0x1e9)]===!![]}));}function a63_0x3526(){const _0x21d552=['labelField','creatorNameField','requestFields','allFields','553AMexuy','required','dataset','indexes','responseFields','1176865ELWlEl','formatRules','split','3328028QHXiyN','properties','filter','toDatasetName','doType','path','method','options','str','modifierNameField','dataType','displayName','toTableName','main_sub','deleted','object','allFieldNames','fromField','columnCodeListWithDeleted','tableComment','datasetKey','parse','toDatasetCode','5823QeduHv','cardinality','push','bizRelationType','host','source','name','pkField','requestBody','dblinkInfoDTO','modelCode','3336LzFGNj','updateTimeField','doVersion','description','dbId','toFieldLabel','operations','699InbTSO','2892OmEIOr','extend','beforeScriptId','relatedPageInfoList','3996qLwlnb','length','deprecated','fields','read','trim','tableName','relations','dbName','alias','string','5884VghDmq','responseBody','code','detail','toField','46rSZHiE','type','map','dbtableConfig','logicField','sourceType','creatorIdField','title','1904010zdaYNa','isArray','Get\x20dataset\x20detail\x20including\x20fields\x20and\x20operations','relationId'];a63_0x3526=function(){return _0x21d552;};return a63_0x3526();}export const datasetDetail={'service':a63_0x16940c(0x1d5),'command':a63_0x16940c(0x1c1),'description':a63_0x16940c(0x1cd),'risk':a63_0x16940c(0x1b7),'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':a63_0x16940c(0x1bc),'type':a63_0x16940c(0x1bd),'description':'Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically'}],async 'execute'(_0x49a92d){const _0x5bdff9=a63_0x16940c,_0x29e970=await getDatasetDetail(_0x49a92d[_0x5bdff9(0x1e3)](_0x5bdff9(0x1c0))),_0x427a1e=Array[_0x5bdff9(0x1cc)](_0x29e970[_0x5bdff9(0x1b6)])?_0x29e970[_0x5bdff9(0x1b6)]:Array[_0x5bdff9(0x1cc)](_0x29e970['properties'])?_0x29e970[_0x5bdff9(0x1dc)]:[],_0x321b79=_0x427a1e[_0x5bdff9(0x1c5)](_0x35f786=>normalizeField(_0x35f786))[_0x5bdff9(0x1dd)](_0xae19f6=>_0xae19f6!==null),_0x4df135=_0x29e970[_0x5bdff9(0x1ad)]??{},_0x496cde=[];for(const [_0x4037f8,_0x4f7d63]of Object['entries'](_0x4df135)){const _0x54f125=normalizeOperationEntry(_0x4037f8,_0x4f7d63);if(_0x54f125)_0x496cde[_0x5bdff9(0x1f4)](_0x54f125);}const _0x3a4537=_0x29e970[_0x5bdff9(0x1c6)]??{},_0x4d583d=_0x29e970[_0x5bdff9(0x1d5)]??{},_0x4850be=_0x3a4537[_0x5bdff9(0x1ab)]!=null?{'id':_0x3a4537['dbId'],'name':_0x3a4537[_0x5bdff9(0x1bb)]??null}:undefined;let _0x3998fd;return typeof _0x29e970[_0x5bdff9(0x1b0)]===_0x5bdff9(0x1bd)&&(_0x3998fd=parseJsonMaybe(_0x29e970[_0x5bdff9(0x1b0)])),{'ok':!![],'data':{'id':_0x29e970['modelId']??_0x29e970['id'],'name':_0x29e970[_0x5bdff9(0x1a2)],'code':_0x29e970[_0x5bdff9(0x1a6)]||_0x29e970[_0x5bdff9(0x1c0)],'doVersion':_0x29e970[_0x5bdff9(0x1a9)],'description':_0x29e970[_0x5bdff9(0x1aa)]||_0x4d583d[_0x5bdff9(0x1ee)]||undefined,'source':_0x29e970[_0x5bdff9(0x1a1)]||_0x4d583d[_0x5bdff9(0x1c8)],'table':_0x3a4537['tableName']||_0x4d583d[_0x5bdff9(0x1b9)],'datasetKey':_0x3a4537[_0x5bdff9(0x1ef)],'pk':_0x3a4537[_0x5bdff9(0x1a3)],'db':_0x4850be,'dbtable':summarizeDbtable(_0x3a4537),'fields':_0x321b79,'operations':_0x496cde,'indexes':Array['isArray'](_0x4d583d[_0x5bdff9(0x1d6)])?_0x4d583d[_0x5bdff9(0x1d6)]:[],'relations':Array[_0x5bdff9(0x1cc)](_0x29e970['relations'])?_0x29e970[_0x5bdff9(0x1ba)][_0x5bdff9(0x1c5)](_0x1c6ac2=>({..._0x1c6ac2['relationId']!=null?{'relationId':_0x1c6ac2[_0x5bdff9(0x1ce)]}:{},'fromDataset':_0x29e970[_0x5bdff9(0x1a2)],'fromCode':_0x29e970[_0x5bdff9(0x1a6)]||_0x29e970['code'],'fromTable':_0x3a4537[_0x5bdff9(0x1b9)]||_0x4d583d[_0x5bdff9(0x1b9)],'fromField':_0x1c6ac2[_0x5bdff9(0x1ec)],'toDataset':_0x1c6ac2[_0x5bdff9(0x1de)],'toCode':_0x1c6ac2[_0x5bdff9(0x1f1)],'toTable':_0x1c6ac2[_0x5bdff9(0x1e7)],'toField':_0x1c6ac2[_0x5bdff9(0x1c2)],'labelField':_0x1c6ac2[_0x5bdff9(0x1ac)]||undefined,'cardinality':_0x1c6ac2[_0x5bdff9(0x1f3)]||undefined,'bizRelationType':_0x1c6ac2[_0x5bdff9(0x1f5)]==='main_sub'?_0x5bdff9(0x1e8):null})):[],'relatedPages':normalizeRelatedPages(_0x29e970[_0x5bdff9(0x1b2)]),...Array[_0x5bdff9(0x1cc)](_0x29e970[_0x5bdff9(0x1ed)])?{'columnCodeListWithDeleted':_0x29e970[_0x5bdff9(0x1ed)]}:{},'formatRules':Array[_0x5bdff9(0x1cc)](_0x29e970['formatRules'])?_0x29e970[_0x5bdff9(0x1d9)]:[],'validateRules':Array[_0x5bdff9(0x1cc)](_0x29e970['validateRules'])?_0x29e970['validateRules']:[],..._0x3998fd!==undefined?{'extend':_0x3998fd}:{},'stats':{'fieldCount':_0x321b79['length'],'operationCount':_0x496cde[_0x5bdff9(0x1b4)]}}};}};
1
+ const a63_0x57cb21=a63_0x45e7;(function(_0x5597b1,_0x3bdd00){const _0x359fb1=a63_0x45e7,_0xf2402=_0x5597b1();while(!![]){try{const _0x372b07=-parseInt(_0x359fb1(0xba))/0x1+parseInt(_0x359fb1(0x96))/0x2+parseInt(_0x359fb1(0x7c))/0x3+parseInt(_0x359fb1(0xcc))/0x4*(parseInt(_0x359fb1(0xbe))/0x5)+parseInt(_0x359fb1(0x8f))/0x6+-parseInt(_0x359fb1(0xc9))/0x7*(parseInt(_0x359fb1(0x7e))/0x8)+-parseInt(_0x359fb1(0x80))/0x9;if(_0x372b07===_0x3bdd00)break;else _0xf2402['push'](_0xf2402['shift']());}catch(_0xd5cf8e){_0xf2402['push'](_0xf2402['shift']());}}}(a63_0xd340,0xd1b77));import{getDatasetDetail}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function normalizeField(_0x295823){const _0x263d1b=a63_0x45e7;if(_0x295823[_0x263d1b(0xac)])return null;const _0x568623=Boolean(_0x295823[_0x263d1b(0xa4)]!==undefined||_0x295823[_0x263d1b(0xa5)]!==undefined);let _0x534ff7={};if(!_0x568623&&typeof _0x295823[_0x263d1b(0xb0)]===_0x263d1b(0xc7))try{_0x534ff7=JSON[_0x263d1b(0xbc)](_0x295823[_0x263d1b(0xb0)]);}catch{}const _0x532b8e=_0x568623?_0x295823['name']:_0x295823['code'],_0x3b826b=_0x568623?_0x295823[_0x263d1b(0xa4)]:_0x295823[_0x263d1b(0xb5)],_0x4d116d=_0x568623?_0x295823[_0x263d1b(0xa5)]:_0x295823[_0x263d1b(0xa3)]||_0x295823[_0x263d1b(0x7d)],_0x573897=_0x568623?_0x295823['pkField']===!![]:_0x534ff7[_0x263d1b(0x9f)]===!![],_0x2c5d0b=_0x568623?_0x295823['required']===!![]:_0x534ff7[_0x263d1b(0xa0)]===!![],_0x1a6e23=_0x568623?_0x295823[_0x263d1b(0xc4)]??null:_0x534ff7[_0x263d1b(0xc4)]??null,_0x149c86={'name':_0x532b8e,'displayName':_0x3b826b||_0x532b8e,'type':_0x4d116d,'dbType':_0x295823[_0x263d1b(0x9a)],'pk':_0x573897,'required':_0x2c5d0b,'deprecated':_0x295823[_0x263d1b(0xca)]===!![],'description':_0x295823[_0x263d1b(0xb2)]||undefined};return Array['isArray'](_0x1a6e23)&&_0x1a6e23[_0x263d1b(0xa6)]>0x0&&(_0x149c86[_0x263d1b(0xc4)]=_0x1a6e23),_0x149c86;}function parseJsonMaybe(_0x2de4ae){const _0x5981f1=a63_0x45e7;if(typeof _0x2de4ae!==_0x5981f1(0xc7))return _0x2de4ae;try{return JSON[_0x5981f1(0xbc)](_0x2de4ae);}catch{return _0x2de4ae;}}function a63_0x45e7(_0x4626a6,_0x4946af){_0x4626a6=_0x4626a6-0x7a;const _0xd34009=a63_0xd340();let _0x45e72f=_0xd34009[_0x4626a6];return _0x45e72f;}function normalizeOperationEntry(_0x2c98c0,_0x3641ae){const _0x222c5d=a63_0x45e7;if(!_0x3641ae||typeof _0x3641ae!==_0x222c5d(0xaa))return null;if(!_0x3641ae[_0x222c5d(0xc0)]||!_0x3641ae[_0x222c5d(0xb8)])return null;const _0x4b4972={'name':_0x2c98c0,'method':_0x3641ae['method'],'path':_0x3641ae['path']};if(_0x3641ae['host'])_0x4b4972['host']=_0x3641ae[_0x222c5d(0x95)];if(_0x3641ae['requestBody']!=null){const _0x23c726=parseJsonMaybe(_0x3641ae[_0x222c5d(0x8a)]);_0x4b4972[_0x222c5d(0x8a)]=_0x23c726;}if(_0x3641ae[_0x222c5d(0x84)]!=null){const _0x57067d=parseJsonMaybe(_0x3641ae[_0x222c5d(0x84)]);_0x4b4972[_0x222c5d(0x84)]=_0x57067d;}if(_0x3641ae[_0x222c5d(0xc5)]!=null)_0x4b4972[_0x222c5d(0xc5)]=_0x3641ae['beforeScriptId'];if(_0x3641ae[_0x222c5d(0xad)]!=null)_0x4b4972[_0x222c5d(0xad)]=_0x3641ae['afterScriptId'];if(Array[_0x222c5d(0xb3)](_0x3641ae[_0x222c5d(0xa8)]))_0x4b4972[_0x222c5d(0xa8)]=_0x3641ae[_0x222c5d(0xa8)];if(Array['isArray'](_0x3641ae['responseFields']))_0x4b4972[_0x222c5d(0xbb)]=_0x3641ae[_0x222c5d(0xbb)];return _0x4b4972;}function summarizeDbtable(_0x3bdc76){const _0x29315c=a63_0x45e7,_0x29ddef={},_0x21256b=[_0x29315c(0xcb),_0x29315c(0xa1),'tableName',_0x29315c(0x9b),_0x29315c(0x9f),'allFields','logicField','createTimeField',_0x29315c(0xb4),_0x29315c(0x89),_0x29315c(0xbf),_0x29315c(0x86),_0x29315c(0xab),_0x29315c(0x87),_0x29315c(0xaf)];for(const _0x455a97 of _0x21256b){if(_0x3bdc76[_0x455a97]!==undefined)_0x29ddef[_0x455a97]=_0x3bdc76[_0x455a97];}return typeof _0x29ddef[_0x29315c(0x9c)]===_0x29315c(0xc7)&&_0x29ddef[_0x29315c(0x9c)][_0x29315c(0xa6)]>0x0&&(_0x29ddef[_0x29315c(0xc2)]=_0x29ddef[_0x29315c(0x9c)][_0x29315c(0x9d)](',')[_0x29315c(0x7f)](_0xc55320=>_0xc55320['trim']())[_0x29315c(0x82)](Boolean)),_0x29ddef;}function a63_0xd340(){const _0x545e08=['3601119bHpcZf','dataType','8YoYeRD','map','22842495XSYreM','alias','filter','fromField','responseBody','properties','modifierIdField','labelField','main_sub','creatorIdField','requestBody','code','toDatasetCode','dataset','tableName','9834456PmThjO','dbtableConfig','push','modelCode','toFieldLabel','tableComment','host','1301906iUBLsy','bizRelationType','toDatasetName','sourceType','dbType','datasetKey','allFields','split','toTableName','pkField','required','dbName','fields','type','displayName','doType','length','source','requestFields','formatRules','object','modifierNameField','deleted','afterScriptId','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','dblinkInfoDTO','extend','entries','description','isArray','updateTimeField','name','columnCodeListWithDeleted','toField','path','modelId','804902sFBvau','responseFields','parse','relatedPageInfoList','8574575TDciPC','creatorNameField','method','indexes','allFieldNames','validateRules','options','beforeScriptId','cardinality','string','relationId','7023527GkSMPT','deprecated','dbId','4bOEtxx','doVersion','relations'];a63_0xd340=function(){return _0x545e08;};return a63_0xd340();}function normalizeRelatedPages(_0x46b105){const _0x46ac37=a63_0x45e7;if(!Array['isArray'](_0x46b105))return[];return _0x46b105['filter'](_0x5c5774=>_0x5c5774&&typeof _0x5c5774===_0x46ac37(0xaa))[_0x46ac37(0x7f)](_0x57f8da=>({'id':_0x57f8da['id'],'type':_0x57f8da[_0x46ac37(0xa3)],'code':_0x57f8da[_0x46ac37(0x8b)],'title':_0x57f8da['title'],'deleted':_0x57f8da[_0x46ac37(0xac)]===!![]}));}export const datasetDetail={'service':'dataset','command':'detail','description':'Get\x20dataset\x20detail\x20including\x20fields\x20and\x20operations','risk':'read','flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':a63_0x57cb21(0x81),'type':a63_0x57cb21(0xc7),'description':a63_0x57cb21(0xae)}],async 'execute'(_0x2a826a){const _0x2ce39d=a63_0x57cb21,_0x51b003=await getDatasetDetail(_0x2a826a['str'](_0x2ce39d(0x8b))),_0x1109ac=Array['isArray'](_0x51b003[_0x2ce39d(0xa2)])?_0x51b003[_0x2ce39d(0xa2)]:Array[_0x2ce39d(0xb3)](_0x51b003[_0x2ce39d(0x85)])?_0x51b003[_0x2ce39d(0x85)]:[],_0x3cb72f=_0x1109ac[_0x2ce39d(0x7f)](_0x4747b9=>normalizeField(_0x4747b9))['filter'](_0x382b24=>_0x382b24!==null),_0x577c8a=_0x51b003['operations']??{},_0x7462a3=[];for(const [_0x2d5966,_0x4ce558]of Object[_0x2ce39d(0xb1)](_0x577c8a)){const _0x730779=normalizeOperationEntry(_0x2d5966,_0x4ce558);if(_0x730779)_0x7462a3[_0x2ce39d(0x91)](_0x730779);}const _0x1199d6=_0x51b003[_0x2ce39d(0x90)]??{},_0x580e23=_0x51b003[_0x2ce39d(0x8d)]??{},_0x2c2361=_0x1199d6['dbId']!=null?{'id':_0x1199d6[_0x2ce39d(0xcb)],'name':_0x1199d6[_0x2ce39d(0xa1)]??null}:undefined;let _0x3ff7e6;return typeof _0x51b003[_0x2ce39d(0xb0)]===_0x2ce39d(0xc7)&&(_0x3ff7e6=parseJsonMaybe(_0x51b003[_0x2ce39d(0xb0)])),{'ok':!![],'data':{'id':_0x51b003[_0x2ce39d(0xb9)]??_0x51b003['id'],'name':_0x51b003[_0x2ce39d(0xb5)],'code':_0x51b003['modelCode']||_0x51b003[_0x2ce39d(0x8b)],'doVersion':_0x51b003[_0x2ce39d(0x7a)],'description':_0x51b003[_0x2ce39d(0xb2)]||_0x580e23[_0x2ce39d(0x94)]||undefined,'source':_0x51b003[_0x2ce39d(0xa7)]||_0x580e23[_0x2ce39d(0x99)],'table':_0x1199d6[_0x2ce39d(0x8e)]||_0x580e23[_0x2ce39d(0x8e)],'datasetKey':_0x1199d6[_0x2ce39d(0x9b)],'pk':_0x1199d6[_0x2ce39d(0x9f)],'db':_0x2c2361,'dbtable':summarizeDbtable(_0x1199d6),'fields':_0x3cb72f,'operations':_0x7462a3,'indexes':Array[_0x2ce39d(0xb3)](_0x580e23[_0x2ce39d(0xc1)])?_0x580e23[_0x2ce39d(0xc1)]:[],'relations':Array['isArray'](_0x51b003[_0x2ce39d(0x7b)])?_0x51b003['relations']['map'](_0x16e0d3=>({..._0x16e0d3[_0x2ce39d(0xc8)]!=null?{'relationId':_0x16e0d3[_0x2ce39d(0xc8)]}:{},'fromDataset':_0x51b003[_0x2ce39d(0xb5)],'fromCode':_0x51b003[_0x2ce39d(0x92)]||_0x51b003[_0x2ce39d(0x8b)],'fromTable':_0x1199d6[_0x2ce39d(0x8e)]||_0x580e23[_0x2ce39d(0x8e)],'fromField':_0x16e0d3[_0x2ce39d(0x83)],'toDataset':_0x16e0d3[_0x2ce39d(0x98)],'toCode':_0x16e0d3[_0x2ce39d(0x8c)],'toTable':_0x16e0d3[_0x2ce39d(0x9e)],'toField':_0x16e0d3[_0x2ce39d(0xb7)],'labelField':_0x16e0d3[_0x2ce39d(0x93)]||undefined,'cardinality':_0x16e0d3[_0x2ce39d(0xc6)]||undefined,'bizRelationType':_0x16e0d3[_0x2ce39d(0x97)]===_0x2ce39d(0x88)?_0x2ce39d(0x88):null})):[],'relatedPages':normalizeRelatedPages(_0x51b003[_0x2ce39d(0xbd)]),...Array[_0x2ce39d(0xb3)](_0x51b003[_0x2ce39d(0xb6)])?{'columnCodeListWithDeleted':_0x51b003[_0x2ce39d(0xb6)]}:{},'formatRules':Array['isArray'](_0x51b003[_0x2ce39d(0xa9)])?_0x51b003[_0x2ce39d(0xa9)]:[],'validateRules':Array[_0x2ce39d(0xb3)](_0x51b003[_0x2ce39d(0xc3)])?_0x51b003[_0x2ce39d(0xc3)]:[],..._0x3ff7e6!==undefined?{'extend':_0x3ff7e6}:{},'stats':{'fieldCount':_0x3cb72f[_0x2ce39d(0xa6)],'operationCount':_0x7462a3[_0x2ce39d(0xa6)]}}};}};
@@ -1 +1 @@
1
- const a64_0x2282f9=a64_0xe2cb;(function(_0x4d18ee,_0x33ad7e){const _0x43e850=a64_0xe2cb,_0x565eb1=_0x4d18ee();while(!![]){try{const _0x17ffb7=-parseInt(_0x43e850(0xef))/0x1*(parseInt(_0x43e850(0xea))/0x2)+-parseInt(_0x43e850(0xf4))/0x3*(parseInt(_0x43e850(0xe1))/0x4)+-parseInt(_0x43e850(0xd3))/0x5+parseInt(_0x43e850(0xdd))/0x6+parseInt(_0x43e850(0xcf))/0x7+parseInt(_0x43e850(0xe3))/0x8*(parseInt(_0x43e850(0xd8))/0x9)+parseInt(_0x43e850(0xbc))/0xa;if(_0x17ffb7===_0x33ad7e)break;else _0x565eb1['push'](_0x565eb1['shift']());}catch(_0x40355f){_0x565eb1['push'](_0x565eb1['shift']());}}}(a64_0x1ebc,0x8d42f));import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateDrivenData}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const MUTABLE_EXTEND_KEYS=new Set(),EXTEND_PATCH_REDIRECTS=new Map([[a64_0x2282f9(0xc4),{'message':'dataset\x20extend-update\x20does\x20not\x20support\x20businessGroup;\x20use\x20dataset\x20business-group-update','hint':'Use\x20`rabetbase\x20dataset\x20business-group-update`\x20to\x20update\x20business\x20model\x20groups.'}]]);function a64_0x1ebc(){const _0xcf4922=['--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key','stringify','Patch\x20dataset\x20top-level\x20extend\x20safely','1nVYFrP','Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object','length','isArray','from','17157YAEovp','--code\x20is\x20required','join','str','datasetId','parse','get','/smartapi/dataset/update-driven-data','validation','modelCode','patch-json','483270nwqPAx','JSON\x20object\x20of\x20expected\x20current\x20extend\x20values;\x20mismatch\x20aborts\x20without\x20writing','extend','value','Unsupported\x20patch\x20key:\x20','dbtableConfig','modelId','--patch-json','businessGroup','Allowed\x20keys:\x20','expect','trim','write','object','patch','\x20must\x20be\x20valid\x20JSON\x20object:\x20','hint','\x20must\x20be\x20a\x20JSON\x20object','appCode','7640290wMaMKE','code','string','Expected\x20','3817175njuFlp','expect-json','extend-update','data','Expectation\x20mismatch\x20at\x20extend.','14472EEdIwi','Updated\x20dataset\x20extend\x20(','--expect-json','Dataset\x20extend\x20must\x20be\x20valid\x20JSON\x20object:\x20','Dry-run:\x20dataset\x20extend\x20would\x20change\x20(','5346936nLYccn','push','shape','No\x20dataset\x20extend\x20patch\x20keys\x20are\x20currently\x20supported.','456ZwOoBV','tableName','3544vyXLiL','entries','sort','keys','message','POST','dataset','1498578ITthmM','extend.'];a64_0x1ebc=function(){return _0xcf4922;};return a64_0x1ebc();}export function parseJsonObjectFlag(_0x497f64,_0x499183){const _0x13c802=a64_0x2282f9;if(!_0x497f64)return undefined;let _0x4e1d5d;try{_0x4e1d5d=JSON[_0x13c802(0xb6)](_0x497f64);}catch(_0xa3a9cb){const _0x346544=_0xa3a9cb instanceof Error?_0xa3a9cb[_0x13c802(0xe7)]:String(_0xa3a9cb);throw CliErrors[_0x13c802(0xb9)](_0x499183+_0x13c802(0xcb)+_0x346544);}if(!isPlainObject(_0x4e1d5d)||Array[_0x13c802(0xf2)](_0x4e1d5d))throw CliErrors[_0x13c802(0xb9)](_0x499183+_0x13c802(0xcd));return _0x4e1d5d;}export function validateExtendPatchKeys(_0x2ad7f5){const _0xded9c0=a64_0x2282f9,_0x894c3=Object[_0xded9c0(0xe6)](_0x2ad7f5);if(_0x894c3[_0xded9c0(0xf1)]===0x0)throw CliErrors['validation'](_0xded9c0(0xec));for(const _0x45e7cc of _0x894c3){const _0x4df17e=EXTEND_PATCH_REDIRECTS[_0xded9c0(0xb7)](_0x45e7cc);if(_0x4df17e)throw CliErrors['validation'](_0x4df17e['message'],_0x4df17e[_0xded9c0(0xcc)]);if(!MUTABLE_EXTEND_KEYS['has'](_0x45e7cc))throw CliErrors[_0xded9c0(0xb9)](_0xded9c0(0xc0)+_0x45e7cc,describeMutableExtendKeys());}}function describeMutableExtendKeys(){const _0x49f98d=a64_0x2282f9,_0x5387f4=Array[_0x49f98d(0xf3)](MUTABLE_EXTEND_KEYS)[_0x49f98d(0xe5)]();return _0x5387f4[_0x49f98d(0xf1)]>0x0?_0x49f98d(0xc5)+_0x5387f4[_0x49f98d(0xb3)](',\x20'):_0x49f98d(0xe0);}export function applyExtendPatch(_0x5457fd,_0x2b9924){const _0x42faad=a64_0x2282f9;validateExtendPatchKeys(_0x2b9924);const _0x5cb965=deepClone(_0x5457fd),_0x3f7883=[];for(const [_0x1f18a8,_0x235ce6]of Object[_0x42faad(0xe4)](_0x2b9924)){const _0x27e685=_0x5cb965[_0x1f18a8],_0x2a0ba1=deepClone(_0x235ce6);!deepEqual(_0x27e685,_0x2a0ba1)&&(_0x5cb965[_0x1f18a8]=_0x2a0ba1,_0x3f7883[_0x42faad(0xde)](_0x42faad(0xeb)+_0x1f18a8));}return _0x3f7883[_0x42faad(0xe5)](),{'after':_0x5cb965,'changedPaths':_0x3f7883,'changed':_0x3f7883[_0x42faad(0xf1)]>0x0};}export function assertExpectation(_0x2c2edc,_0x3565db){const _0x38175d=a64_0x2282f9;if(!_0x3565db)return;for(const [_0x289050,_0x2adbf]of Object[_0x38175d(0xe4)](_0x3565db)){const _0xa4db20=_0x2c2edc[_0x289050];if(!deepEqual(_0xa4db20,_0x2adbf))throw CliErrors[_0x38175d(0xb9)](_0x38175d(0xd7)+_0x289050,_0x38175d(0xd2)+JSON[_0x38175d(0xed)](_0x2adbf)+',\x20actual\x20'+JSON[_0x38175d(0xed)](_0xa4db20));}}export async function buildDatasetExtendUpdateResult({appCode:_0x28cf7b,input:_0x47b04c,dryRun:_0x4b1348}){const _0x4a0230=a64_0x2282f9;validateInput(_0x47b04c);const _0x1a73a5=await getDatasetDetail(_0x47b04c['code']),_0x1b51f9=parseDatasetExtend(_0x1a73a5[_0x4a0230(0xbe)]),_0x4513e1=deepClone(_0x1b51f9[_0x4a0230(0xbf)]);assertExpectation(_0x4513e1,_0x47b04c[_0x4a0230(0xc6)]);const {after:_0x21ec70,changedPaths:_0x3b575d,changed:_0x5a8c21}=applyExtendPatch(_0x4513e1,_0x47b04c['patch']),_0x18e36f=summarizeDataset(_0x1a73a5,_0x47b04c[_0x4a0230(0xd0)]);return _0x5a8c21&&!_0x4b1348&&(_0x1a73a5[_0x4a0230(0xbe)]=serializeDatasetExtend(_0x21ec70,_0x1b51f9[_0x4a0230(0xdf)]),await updateDrivenData(_0x1a73a5)),{'ok':!![],'data':{'appCode':_0x28cf7b,'selector':{'code':_0x47b04c[_0x4a0230(0xd0)]},'dataset':_0x18e36f,'dryRun':_0x4b1348,'changed':_0x5a8c21,'changedPaths':_0x3b575d,'before':{'extend':_0x4513e1},'after':{'extend':_0x21ec70},'submitted':_0x5a8c21&&!_0x4b1348},'message':_0x5a8c21?_0x4b1348?_0x4a0230(0xdc)+_0x3b575d[_0x4a0230(0xb3)](',\x20')+')':_0x4a0230(0xd9)+_0x3b575d[_0x4a0230(0xb3)](',\x20')+')':'No\x20changes\x20for\x20dataset\x20extend'};}function a64_0xe2cb(_0xde4987,_0x323832){_0xde4987=_0xde4987-0xb2;const _0x1ebc75=a64_0x1ebc();let _0xe2cbd7=_0x1ebc75[_0xde4987];return _0xe2cbd7;}export const datasetExtendUpdate={'service':a64_0x2282f9(0xe9),'command':a64_0x2282f9(0xd5),'description':a64_0x2282f9(0xee),'risk':a64_0x2282f9(0xc8),'flags':[CODE_FLAG,{'name':a64_0x2282f9(0xbb),'type':a64_0x2282f9(0xd1),'required':!![],'description':'JSON\x20object\x20patch\x20for\x20dataset\x20top-level\x20extend;\x20current\x20allowlist\x20is\x20empty'},{'name':a64_0x2282f9(0xd4),'type':a64_0x2282f9(0xd1),'required':![],'description':a64_0x2282f9(0xbd)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x3c8e95){validateInput(readExtendUpdateInput(_0x3c8e95));},async 'dryRun'(_0x2481eb){const _0x4f80be=a64_0x2282f9,_0x3d388a=await buildDatasetExtendUpdateResult({'appCode':_0x2481eb[_0x4f80be(0xce)],'input':readExtendUpdateInput(_0x2481eb),'dryRun':!![]});return{'method':_0x4f80be(0xe8),'url':_0x4f80be(0xb8),'body':_0x3d388a[_0x4f80be(0xd6)],'description':_0x3d388a[_0x4f80be(0xe7)]};},async 'execute'(_0x16d3c0){return buildDatasetExtendUpdateResult({'appCode':_0x16d3c0['appCode'],'input':readExtendUpdateInput(_0x16d3c0),'dryRun':![]});}};function readExtendUpdateInput(_0x43b435){const _0xe7770b=a64_0x2282f9,_0x130025=trim(_0x43b435[_0xe7770b(0xb4)](_0xe7770b(0xd0))),_0x3dd107=parseJsonObjectFlag(_0x43b435[_0xe7770b(0xb4)](_0xe7770b(0xbb)),_0xe7770b(0xc3)),_0xb5a550=parseJsonObjectFlag(_0x43b435[_0xe7770b(0xb4)](_0xe7770b(0xd4)),_0xe7770b(0xda));return{'code':_0x130025,'patch':_0x3dd107||{},'expect':_0xb5a550};}function validateInput(_0x20f260){const _0x334314=a64_0x2282f9;if(!_0x20f260['code'])throw CliErrors[_0x334314(0xb9)](_0x334314(0xb2));validateExtendPatchKeys(_0x20f260[_0x334314(0xca)]);}function parseDatasetExtend(_0x53b4c0){const _0x5f1026=a64_0x2282f9;if(typeof _0x53b4c0===_0x5f1026(0xd1)){const _0x28942b=_0x53b4c0[_0x5f1026(0xc7)]();if(!_0x28942b)return{'value':{},'shape':_0x5f1026(0xd1)};let _0x5e81a3;try{_0x5e81a3=JSON[_0x5f1026(0xb6)](_0x28942b);}catch(_0x4af229){const _0x2836df=_0x4af229 instanceof Error?_0x4af229[_0x5f1026(0xe7)]:String(_0x4af229);throw CliErrors['validation'](_0x5f1026(0xdb)+_0x2836df);}if(!isPlainObject(_0x5e81a3)||Array[_0x5f1026(0xf2)](_0x5e81a3))throw CliErrors[_0x5f1026(0xb9)](_0x5f1026(0xf0));return{'value':_0x5e81a3,'shape':_0x5f1026(0xd1)};}if(_0x53b4c0===undefined||_0x53b4c0===null)return{'value':{},'shape':_0x5f1026(0xd1)};if(!isPlainObject(_0x53b4c0)||Array[_0x5f1026(0xf2)](_0x53b4c0))throw CliErrors[_0x5f1026(0xb9)](_0x5f1026(0xf0));return{'value':_0x53b4c0,'shape':'object'};}function serializeDatasetExtend(_0x311fdb,_0x220ca9){const _0x196372=a64_0x2282f9;return _0x220ca9===_0x196372(0xd1)?JSON[_0x196372(0xed)](_0x311fdb):_0x311fdb;}function summarizeDataset(_0x592f4b,_0x7078c8){const _0xb83c6a=a64_0x2282f9,_0x5797ab=isPlainObject(_0x592f4b[_0xb83c6a(0xe9)])?_0x592f4b[_0xb83c6a(0xe9)]:{},_0x613e6=isPlainObject(_0x592f4b[_0xb83c6a(0xc1)])?_0x592f4b['dbtableConfig']:{};return{'id':_0x592f4b[_0xb83c6a(0xc2)]??_0x592f4b['id']??_0x5797ab[_0xb83c6a(0xb5)]??null,'code':_0x592f4b[_0xb83c6a(0xba)]??_0x592f4b[_0xb83c6a(0xd0)]??_0x5797ab['datasetCode']??_0x7078c8,'name':_0x592f4b['name']??_0x5797ab['datasetName']??null,'table':_0x613e6['tableName']??_0x5797ab[_0xb83c6a(0xe2)]??null,'db':_0x613e6['dbName']??_0x613e6['dbId']??null};}function deepClone(_0x462a92){const _0x35e453=a64_0x2282f9;if(_0x462a92===undefined)return _0x462a92;return JSON[_0x35e453(0xb6)](JSON[_0x35e453(0xed)](_0x462a92));}function deepEqual(_0x12da0b,_0x25f446){const _0x2dafdb=a64_0x2282f9;return JSON[_0x2dafdb(0xed)](_0x12da0b)===JSON[_0x2dafdb(0xed)](_0x25f446);}function isPlainObject(_0x13a1eb){const _0x11cd17=a64_0x2282f9;return Boolean(_0x13a1eb)&&typeof _0x13a1eb===_0x11cd17(0xc9)&&!Array[_0x11cd17(0xf2)](_0x13a1eb);}function trim(_0x48cc92){const _0x9cda3f=a64_0x2282f9,_0xc96a75=String(_0x48cc92||'')[_0x9cda3f(0xc7)]();return _0xc96a75;}
1
+ const a64_0x35b0ce=a64_0x247a;function a64_0x440d(){const _0x2f5c64=['expect-json','614IlofOV','--patch-json','dataset\x20extend-update\x20does\x20not\x20support\x20businessGroup;\x20use\x20dataset\x20business-group-update','datasetName','patch-json','string','length','Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object','keys','--code\x20is\x20required','datasetCode','\x20must\x20be\x20valid\x20JSON\x20object:\x20','value','56gYDIcm','1318508GYmzCg','649tAwdgE','data','\x20must\x20be\x20a\x20JSON\x20object','1643845GTgcSn','6dZbvDS','from','Use\x20`rabetbase\x20dataset\x20business-group-update`\x20to\x20update\x20business\x20model\x20groups.','565FOobgJ','extend-update','hint','extend.','modelId','/smartapi/dataset/update-driven-data','trim','validation','186753RjKHyQ','No\x20dataset\x20extend\x20patch\x20keys\x20are\x20currently\x20supported.','sort','isArray','Patch\x20dataset\x20top-level\x20extend\x20safely','Unsupported\x20patch\x20key:\x20','code','195036GhTJqE','--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key','shape','message','join','576015vgHtlx','write','entries','patch','expect','stringify','push','object','JSON\x20object\x20patch\x20for\x20dataset\x20top-level\x20extend;\x20current\x20allowlist\x20is\x20empty','parse','name','Expected\x20','modelCode','2870QursMR','Dry-run:\x20dataset\x20extend\x20would\x20change\x20(','extend','JSON\x20object\x20of\x20expected\x20current\x20extend\x20values;\x20mismatch\x20aborts\x20without\x20writing','1593PkMfAl','Updated\x20dataset\x20extend\x20(','appCode','has','dataset','dbtableConfig','str','dbId'];a64_0x440d=function(){return _0x2f5c64;};return a64_0x440d();}(function(_0x21a6b0,_0x372619){const _0x360085=a64_0x247a,_0x164069=_0x21a6b0();while(!![]){try{const _0x597360=-parseInt(_0x360085(0x1b4))/0x1*(parseInt(_0x360085(0x1e2))/0x2)+parseInt(_0x360085(0x1c8))/0x3+-parseInt(_0x360085(0x1f0))/0x4+-parseInt(_0x360085(0x1f4))/0x5*(parseInt(_0x360085(0x1f5))/0x6)+-parseInt(_0x360085(0x1bc))/0x7*(parseInt(_0x360085(0x1ef))/0x8)+parseInt(_0x360085(0x1d9))/0x9*(parseInt(_0x360085(0x1d5))/0xa)+-parseInt(_0x360085(0x1f1))/0xb*(-parseInt(_0x360085(0x1c3))/0xc);if(_0x597360===_0x372619)break;else _0x164069['push'](_0x164069['shift']());}catch(_0x469196){_0x164069['push'](_0x164069['shift']());}}}(a64_0x440d,0x2cb57));function a64_0x247a(_0xca0ee,_0x364718){_0xca0ee=_0xca0ee-0x1b4;const _0x440dc6=a64_0x440d();let _0x247a9f=_0x440dc6[_0xca0ee];return _0x247a9f;}import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{getDatasetDetail,updateDrivenData}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const MUTABLE_EXTEND_KEYS=new Set(),EXTEND_PATCH_REDIRECTS=new Map([['businessGroup',{'message':a64_0x35b0ce(0x1e4),'hint':a64_0x35b0ce(0x1f7)}]]);export function parseJsonObjectFlag(_0x92de40,_0x109645){const _0x4310d5=a64_0x35b0ce;if(!_0x92de40)return undefined;let _0x493954;try{_0x493954=JSON['parse'](_0x92de40);}catch(_0x270559){const _0x4d9335=_0x270559 instanceof Error?_0x270559[_0x4310d5(0x1c6)]:String(_0x270559);throw CliErrors[_0x4310d5(0x1bb)](_0x109645+_0x4310d5(0x1ed)+_0x4d9335);}if(!isPlainObject(_0x493954)||Array[_0x4310d5(0x1bf)](_0x493954))throw CliErrors['validation'](_0x109645+_0x4310d5(0x1f3));return _0x493954;}export function validateExtendPatchKeys(_0x4e6f91){const _0x40f453=a64_0x35b0ce,_0x51e64a=Object[_0x40f453(0x1ea)](_0x4e6f91);if(_0x51e64a[_0x40f453(0x1e8)]===0x0)throw CliErrors['validation'](_0x40f453(0x1c4));for(const _0xaf64e3 of _0x51e64a){const _0x1aa6ca=EXTEND_PATCH_REDIRECTS['get'](_0xaf64e3);if(_0x1aa6ca)throw CliErrors[_0x40f453(0x1bb)](_0x1aa6ca[_0x40f453(0x1c6)],_0x1aa6ca[_0x40f453(0x1b6)]);if(!MUTABLE_EXTEND_KEYS[_0x40f453(0x1dc)](_0xaf64e3))throw CliErrors[_0x40f453(0x1bb)](_0x40f453(0x1c1)+_0xaf64e3,describeMutableExtendKeys());}}function describeMutableExtendKeys(){const _0x13b337=a64_0x35b0ce,_0x239ae8=Array[_0x13b337(0x1f6)](MUTABLE_EXTEND_KEYS)[_0x13b337(0x1be)]();return _0x239ae8[_0x13b337(0x1e8)]>0x0?'Allowed\x20keys:\x20'+_0x239ae8[_0x13b337(0x1c7)](',\x20'):_0x13b337(0x1bd);}export function applyExtendPatch(_0x41ca29,_0x4663e5){const _0x38bedc=a64_0x35b0ce;validateExtendPatchKeys(_0x4663e5);const _0x203cc2=deepClone(_0x41ca29),_0x2cf0aa=[];for(const [_0x2c3b7e,_0x2c4382]of Object[_0x38bedc(0x1ca)](_0x4663e5)){const _0x35318b=_0x203cc2[_0x2c3b7e],_0x22abb8=deepClone(_0x2c4382);!deepEqual(_0x35318b,_0x22abb8)&&(_0x203cc2[_0x2c3b7e]=_0x22abb8,_0x2cf0aa[_0x38bedc(0x1ce)](_0x38bedc(0x1b7)+_0x2c3b7e));}return _0x2cf0aa[_0x38bedc(0x1be)](),{'after':_0x203cc2,'changedPaths':_0x2cf0aa,'changed':_0x2cf0aa[_0x38bedc(0x1e8)]>0x0};}export function assertExpectation(_0x1d210c,_0x54a0e5){const _0xaf8749=a64_0x35b0ce;if(!_0x54a0e5)return;for(const [_0x2c8a4a,_0x5b5690]of Object[_0xaf8749(0x1ca)](_0x54a0e5)){const _0x4925bd=_0x1d210c[_0x2c8a4a];if(!deepEqual(_0x4925bd,_0x5b5690))throw CliErrors[_0xaf8749(0x1bb)]('Expectation\x20mismatch\x20at\x20extend.'+_0x2c8a4a,_0xaf8749(0x1d3)+JSON[_0xaf8749(0x1cd)](_0x5b5690)+',\x20actual\x20'+JSON[_0xaf8749(0x1cd)](_0x4925bd));}}export async function buildDatasetExtendUpdateResult({appCode:_0x4b8156,input:_0x459827,dryRun:_0x1db283}){const _0x4f1c41=a64_0x35b0ce;validateInput(_0x459827);const _0x5c80b2=await getDatasetDetail(_0x459827[_0x4f1c41(0x1c2)]),_0x1355cc=parseDatasetExtend(_0x5c80b2[_0x4f1c41(0x1d7)]),_0x273bfd=deepClone(_0x1355cc[_0x4f1c41(0x1ee)]);assertExpectation(_0x273bfd,_0x459827[_0x4f1c41(0x1cc)]);const {after:_0x39e49d,changedPaths:_0x38e52e,changed:_0xaaef5d}=applyExtendPatch(_0x273bfd,_0x459827[_0x4f1c41(0x1cb)]),_0x6a922=summarizeDataset(_0x5c80b2,_0x459827['code']);return _0xaaef5d&&!_0x1db283&&(_0x5c80b2[_0x4f1c41(0x1d7)]=serializeDatasetExtend(_0x39e49d,_0x1355cc[_0x4f1c41(0x1c5)]),await updateDrivenData(_0x5c80b2)),{'ok':!![],'data':{'appCode':_0x4b8156,'selector':{'code':_0x459827[_0x4f1c41(0x1c2)]},'dataset':_0x6a922,'dryRun':_0x1db283,'changed':_0xaaef5d,'changedPaths':_0x38e52e,'before':{'extend':_0x273bfd},'after':{'extend':_0x39e49d},'submitted':_0xaaef5d&&!_0x1db283},'message':_0xaaef5d?_0x1db283?_0x4f1c41(0x1d6)+_0x38e52e[_0x4f1c41(0x1c7)](',\x20')+')':_0x4f1c41(0x1da)+_0x38e52e[_0x4f1c41(0x1c7)](',\x20')+')':'No\x20changes\x20for\x20dataset\x20extend'};}export const datasetExtendUpdate={'service':a64_0x35b0ce(0x1dd),'command':a64_0x35b0ce(0x1b5),'description':a64_0x35b0ce(0x1c0),'risk':a64_0x35b0ce(0x1c9),'flags':[CODE_FLAG,{'name':a64_0x35b0ce(0x1e6),'type':'string','required':!![],'description':a64_0x35b0ce(0x1d0)},{'name':a64_0x35b0ce(0x1e1),'type':a64_0x35b0ce(0x1e7),'required':![],'description':a64_0x35b0ce(0x1d8)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x29a5f5){validateInput(readExtendUpdateInput(_0x29a5f5));},async 'dryRun'(_0x510907){const _0xe1bc97=a64_0x35b0ce,_0x50ea19=await buildDatasetExtendUpdateResult({'appCode':_0x510907[_0xe1bc97(0x1db)],'input':readExtendUpdateInput(_0x510907),'dryRun':!![]});return{'method':'POST','url':_0xe1bc97(0x1b9),'body':_0x50ea19[_0xe1bc97(0x1f2)],'description':_0x50ea19[_0xe1bc97(0x1c6)]};},async 'execute'(_0x364b6e){const _0x1fba35=a64_0x35b0ce;return buildDatasetExtendUpdateResult({'appCode':_0x364b6e[_0x1fba35(0x1db)],'input':readExtendUpdateInput(_0x364b6e),'dryRun':![]});}};function readExtendUpdateInput(_0x1fdff9){const _0x5807b0=a64_0x35b0ce,_0x1b7b71=trim(_0x1fdff9['str'](_0x5807b0(0x1c2))),_0x109f6a=parseJsonObjectFlag(_0x1fdff9[_0x5807b0(0x1df)](_0x5807b0(0x1e6)),_0x5807b0(0x1e3)),_0x168256=parseJsonObjectFlag(_0x1fdff9[_0x5807b0(0x1df)](_0x5807b0(0x1e1)),'--expect-json');return{'code':_0x1b7b71,'patch':_0x109f6a||{},'expect':_0x168256};}function validateInput(_0x5d06a2){const _0xec08e6=a64_0x35b0ce;if(!_0x5d06a2[_0xec08e6(0x1c2)])throw CliErrors['validation'](_0xec08e6(0x1eb));validateExtendPatchKeys(_0x5d06a2[_0xec08e6(0x1cb)]);}function parseDatasetExtend(_0xb74034){const _0x576b93=a64_0x35b0ce;if(typeof _0xb74034===_0x576b93(0x1e7)){const _0x46bf99=_0xb74034[_0x576b93(0x1ba)]();if(!_0x46bf99)return{'value':{},'shape':_0x576b93(0x1e7)};let _0x45d202;try{_0x45d202=JSON[_0x576b93(0x1d1)](_0x46bf99);}catch(_0x355f70){const _0x5f2f14=_0x355f70 instanceof Error?_0x355f70['message']:String(_0x355f70);throw CliErrors[_0x576b93(0x1bb)]('Dataset\x20extend\x20must\x20be\x20valid\x20JSON\x20object:\x20'+_0x5f2f14);}if(!isPlainObject(_0x45d202)||Array[_0x576b93(0x1bf)](_0x45d202))throw CliErrors[_0x576b93(0x1bb)]('Dataset\x20extend\x20must\x20be\x20a\x20JSON\x20object');return{'value':_0x45d202,'shape':_0x576b93(0x1e7)};}if(_0xb74034===undefined||_0xb74034===null)return{'value':{},'shape':_0x576b93(0x1e7)};if(!isPlainObject(_0xb74034)||Array[_0x576b93(0x1bf)](_0xb74034))throw CliErrors['validation'](_0x576b93(0x1e9));return{'value':_0xb74034,'shape':'object'};}function serializeDatasetExtend(_0x25774a,_0x57368f){return _0x57368f==='string'?JSON['stringify'](_0x25774a):_0x25774a;}function summarizeDataset(_0x2edf0c,_0x1a358c){const _0x20b979=a64_0x35b0ce,_0x5d4827=isPlainObject(_0x2edf0c[_0x20b979(0x1dd)])?_0x2edf0c[_0x20b979(0x1dd)]:{},_0x5e0ce4=isPlainObject(_0x2edf0c[_0x20b979(0x1de)])?_0x2edf0c[_0x20b979(0x1de)]:{};return{'id':_0x2edf0c[_0x20b979(0x1b8)]??_0x2edf0c['id']??_0x5d4827['datasetId']??null,'code':_0x2edf0c[_0x20b979(0x1d4)]??_0x2edf0c[_0x20b979(0x1c2)]??_0x5d4827[_0x20b979(0x1ec)]??_0x1a358c,'name':_0x2edf0c[_0x20b979(0x1d2)]??_0x5d4827[_0x20b979(0x1e5)]??null,'table':_0x5e0ce4['tableName']??_0x5d4827['tableName']??null,'db':_0x5e0ce4['dbName']??_0x5e0ce4[_0x20b979(0x1e0)]??null};}function deepClone(_0x36e3e7){const _0x2e7656=a64_0x35b0ce;if(_0x36e3e7===undefined)return _0x36e3e7;return JSON[_0x2e7656(0x1d1)](JSON[_0x2e7656(0x1cd)](_0x36e3e7));}function deepEqual(_0x399286,_0x2225f6){const _0x4c5faa=a64_0x35b0ce;return JSON[_0x4c5faa(0x1cd)](_0x399286)===JSON[_0x4c5faa(0x1cd)](_0x2225f6);}function isPlainObject(_0x2d6d90){const _0x5ad6af=a64_0x35b0ce;return Boolean(_0x2d6d90)&&typeof _0x2d6d90===_0x5ad6af(0x1cf)&&!Array[_0x5ad6af(0x1bf)](_0x2d6d90);}function trim(_0xd331bc){const _0x4edb7d=String(_0xd331bc||'')['trim']();return _0x4edb7d;}
@@ -1 +1 @@
1
- function a65_0x23fd(){const _0x53ccce=['Expectation\x20mismatch\x20at\x20','isArray','\x20would\x20change\x20(','data','116695luWoQz','keys','expect-json','/smartapi/dataset/update-driven-data','3833648raNYaj','sort','from','code','8596521GQedJL','datasetCode','datasetName','tableName','JSON\x20object\x20of\x20expected\x20current\x20field\x20values;\x20mismatch\x20aborts\x20without\x20writing','Field\x20not\x20found:\x20','Patch\x20one\x20raw\x20dataset\x20fields[]\x20field\x20object\x20safely','properties','displayName','string','message','dbTypeScale','defaultAggregation','Allowed\x20keys:\x20','--expect-json','expect','trim','appCode','chartRole','dbTypeLen','field-update','dbFieldName','stringify','add','has','name','required','entries','datasetId','pkField','dbType','description','869536BtAzuB','write','autoIncrement','datetimeFormat','Driven\x20data\x20does\x20not\x20contain\x20fields[]\x20or\x20properties[]','field','modelCode','findIndex','536160VzmrkY','dbName','1572erMUkj','str','Forbidden\x20patch\x20key:\x20','patch','Unsupported\x20patch\x20key:\x20','--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key','\x20must\x20be\x20valid\x20JSON\x20object:\x20','join','4YvKuux','size','doType','Expected\x20','5537VBwQvk','options','validation','patch-json','systemRetain','--code\x20is\x20required','fields','No\x20changes\x20for\x20dataset\x20field\x20','parse','693470ycgPFB','deprecated','dataset','dbtableConfig','JSON\x20object\x20patch;\x20allowed\x20keys:\x20doType/displayName/description/options/required/datetimeFormat/defaultAggregation/chartRole/deprecated','POST','--field\x20is\x20required'];a65_0x23fd=function(){return _0x53ccce;};return a65_0x23fd();}function a65_0x1af6(_0x735a53,_0x5c7af0){_0x735a53=_0x735a53-0xfd;const _0x23fd50=a65_0x23fd();let _0x1af690=_0x23fd50[_0x735a53];return _0x1af690;}const a65_0x3a8fc2=a65_0x1af6;(function(_0x8573f8,_0x4a4205){const _0x5dac16=a65_0x1af6,_0x2668d7=_0x8573f8();while(!![]){try{const _0xc2c928=-parseInt(_0x5dac16(0x13a))/0x1+parseInt(_0x5dac16(0x122))/0x2*(-parseInt(_0x5dac16(0x118))/0x3)+parseInt(_0x5dac16(0x110))/0x4+-parseInt(_0x5dac16(0x12f))/0x5+-parseInt(_0x5dac16(0x11a))/0x6*(-parseInt(_0x5dac16(0x126))/0x7)+-parseInt(_0x5dac16(0x13e))/0x8+parseInt(_0x5dac16(0x142))/0x9;if(_0xc2c928===_0x4a4205)break;else _0x2668d7['push'](_0x2668d7['shift']());}catch(_0x4ace0b){_0x2668d7['push'](_0x2668d7['shift']());}}}(a65_0x23fd,0x46410));import{getDatasetDetail,updateDrivenData}from'../../core/api-client.js';import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';const MUTABLE_FIELD_KEYS=new Set([a65_0x3a8fc2(0x124),a65_0x3a8fc2(0x14a),a65_0x3a8fc2(0x10f),a65_0x3a8fc2(0x127),a65_0x3a8fc2(0x10a),a65_0x3a8fc2(0x113),a65_0x3a8fc2(0x14e),a65_0x3a8fc2(0x102),a65_0x3a8fc2(0x130)]),FORBIDDEN_FIELD_KEYS=new Set(['id','name',a65_0x3a8fc2(0x141),a65_0x3a8fc2(0x10e),a65_0x3a8fc2(0x103),a65_0x3a8fc2(0x14d),a65_0x3a8fc2(0x105),a65_0x3a8fc2(0x145),'deleted',a65_0x3a8fc2(0x10d),a65_0x3a8fc2(0x112),a65_0x3a8fc2(0x12a)]);export function parseJsonObjectFlag(_0x4edfa9,_0x401bf4){const _0x5a8444=a65_0x3a8fc2;if(!_0x4edfa9)return undefined;let _0xe96e48;try{_0xe96e48=JSON[_0x5a8444(0x12e)](_0x4edfa9);}catch(_0x54161e){const _0x1f3b54=_0x54161e instanceof Error?_0x54161e[_0x5a8444(0x14c)]:String(_0x54161e);throw CliErrors[_0x5a8444(0x128)](_0x401bf4+_0x5a8444(0x120)+_0x1f3b54);}if(!isPlainObject(_0xe96e48)||Array[_0x5a8444(0x137)](_0xe96e48))throw CliErrors[_0x5a8444(0x128)](_0x401bf4+'\x20must\x20be\x20a\x20JSON\x20object');return _0xe96e48;}export function validatePatchKeys(_0x42969a){const _0x3f251c=a65_0x3a8fc2,_0x4393fe=Object[_0x3f251c(0x13b)](_0x42969a);if(_0x4393fe['length']===0x0)throw CliErrors['validation'](_0x3f251c(0x11f));for(const _0x26554d of _0x4393fe){if(FORBIDDEN_FIELD_KEYS['has'](_0x26554d))throw CliErrors['validation'](_0x3f251c(0x11c)+_0x26554d);if(!MUTABLE_FIELD_KEYS[_0x3f251c(0x108)](_0x26554d))throw CliErrors[_0x3f251c(0x128)](_0x3f251c(0x11e)+_0x26554d,_0x3f251c(0xfd)+Array[_0x3f251c(0x140)](MUTABLE_FIELD_KEYS)[_0x3f251c(0x121)](',\x20'));}}export function applyFieldPatch(_0x58ed2a,_0x2c6542){const _0x5eee0b=a65_0x3a8fc2;validatePatchKeys(_0x2c6542);const _0x11633d=deepClone(_0x58ed2a),_0x36d78a=new Set();for(const [_0x363739,_0x293478]of Object[_0x5eee0b(0x10b)](_0x2c6542)){const _0x5b12b9=_0x11633d[_0x363739],_0x11defe=mergePatchValue(_0x5b12b9,_0x293478);!deepEqual(_0x5b12b9,_0x11defe)&&(_0x11633d[_0x363739]=_0x11defe,_0x36d78a[_0x5eee0b(0x107)](_0x363739),collectChangedPaths(_0x363739,_0x5b12b9,_0x11defe,_0x36d78a));}return{'after':_0x11633d,'changedPaths':Array[_0x5eee0b(0x140)](_0x36d78a)[_0x5eee0b(0x13f)](),'changed':_0x36d78a[_0x5eee0b(0x123)]>0x0};}export function assertExpectation(_0x1e0dd5,_0x1f511b){const _0x3dce80=a65_0x3a8fc2;if(!_0x1f511b)return;for(const [_0xc5005a,_0x41ad75]of Object[_0x3dce80(0x10b)](_0x1f511b)){const _0x2cdfb1=_0x1e0dd5[_0xc5005a];if(!deepEqual(_0x2cdfb1,_0x41ad75))throw CliErrors[_0x3dce80(0x128)](_0x3dce80(0x136)+_0xc5005a,_0x3dce80(0x125)+JSON[_0x3dce80(0x106)](_0x41ad75)+',\x20actual\x20'+JSON[_0x3dce80(0x106)](_0x2cdfb1));}}export async function buildDatasetFieldUpdateResult({appCode:_0x4111a6,input:_0x2f2213,dryRun:_0x28cad6}){const _0x28ddef=a65_0x3a8fc2;validateInput(_0x2f2213);const _0x23123c=await getDatasetDetail(_0x2f2213[_0x28ddef(0x141)]),_0x25f1e3=readFieldArray(_0x23123c),_0x44680c=_0x25f1e3[_0x28ddef(0x117)](_0x1acf9f=>_0x1acf9f?.['name']===_0x2f2213[_0x28ddef(0x115)]);if(_0x44680c<0x0)throw CliErrors[_0x28ddef(0x128)](_0x28ddef(0x147)+_0x2f2213[_0x28ddef(0x115)]);const _0x4d2adb=deepClone(_0x25f1e3[_0x44680c]);assertExpectation(_0x4d2adb,_0x2f2213[_0x28ddef(0xff)]);const {after:_0x58734f,changedPaths:_0x196e5a,changed:_0x556b6d}=applyFieldPatch(_0x4d2adb,_0x2f2213[_0x28ddef(0x11d)]),_0x24e834=summarizeDataset(_0x23123c,_0x2f2213[_0x28ddef(0x141)]);return _0x556b6d&&!_0x28cad6&&(_0x25f1e3[_0x44680c]=_0x58734f,await updateDrivenData(_0x23123c)),{'ok':!![],'data':{'appCode':_0x4111a6,'selector':{'code':_0x2f2213[_0x28ddef(0x141)]},'dataset':_0x24e834,'field':{'id':_0x4d2adb['id']??null,'name':_0x4d2adb[_0x28ddef(0x109)]},'dryRun':_0x28cad6,'changed':_0x556b6d,'changedPaths':_0x196e5a,'before':_0x4d2adb,'after':_0x58734f,'submitted':_0x556b6d&&!_0x28cad6},'message':_0x556b6d?_0x28cad6?'Dry-run:\x20dataset\x20field\x20'+_0x2f2213['field']+_0x28ddef(0x138)+_0x196e5a['join'](',\x20')+')':'Updated\x20dataset\x20field\x20'+_0x2f2213[_0x28ddef(0x115)]+'\x20('+_0x196e5a[_0x28ddef(0x121)](',\x20')+')':_0x28ddef(0x12d)+_0x2f2213[_0x28ddef(0x115)]};}export const datasetFieldUpdate={'service':a65_0x3a8fc2(0x131),'command':a65_0x3a8fc2(0x104),'description':a65_0x3a8fc2(0x148),'risk':a65_0x3a8fc2(0x111),'flags':[CODE_FLAG,{'name':'field','type':a65_0x3a8fc2(0x14b),'required':!![],'description':'Exact\x20raw\x20fields[].name\x20to\x20patch'},{'name':a65_0x3a8fc2(0x129),'type':a65_0x3a8fc2(0x14b),'required':!![],'description':a65_0x3a8fc2(0x133)},{'name':a65_0x3a8fc2(0x13c),'type':a65_0x3a8fc2(0x14b),'required':![],'description':a65_0x3a8fc2(0x146)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x58748b){validateInput(readFieldUpdateInput(_0x58748b));},async 'dryRun'(_0x56aea1){const _0x37daa6=a65_0x3a8fc2,_0x4f9791=await buildDatasetFieldUpdateResult({'appCode':_0x56aea1[_0x37daa6(0x101)],'input':readFieldUpdateInput(_0x56aea1),'dryRun':!![]});return{'method':_0x37daa6(0x134),'url':_0x37daa6(0x13d),'body':_0x4f9791[_0x37daa6(0x139)],'description':_0x4f9791[_0x37daa6(0x14c)]};},async 'execute'(_0x55f9da){return buildDatasetFieldUpdateResult({'appCode':_0x55f9da['appCode'],'input':readFieldUpdateInput(_0x55f9da),'dryRun':![]});}};function readFieldUpdateInput(_0x24aad7){const _0x4d1f36=a65_0x3a8fc2,_0x348868=trim(_0x24aad7[_0x4d1f36(0x11b)](_0x4d1f36(0x141))),_0xc5d2a8=emptyToUndefined(_0x24aad7['str'](_0x4d1f36(0x115))),_0x533267=parseJsonObjectFlag(_0x24aad7[_0x4d1f36(0x11b)](_0x4d1f36(0x129)),'--patch-json'),_0x122c53=parseJsonObjectFlag(_0x24aad7['str'](_0x4d1f36(0x13c)),_0x4d1f36(0xfe));return{'code':_0x348868,'field':_0xc5d2a8||'','patch':_0x533267||{},'expect':_0x122c53};}function validateInput(_0x2a6546){const _0x42bbd6=a65_0x3a8fc2;if(!_0x2a6546['code'])throw CliErrors[_0x42bbd6(0x128)](_0x42bbd6(0x12b));if(!_0x2a6546[_0x42bbd6(0x115)])throw CliErrors['validation'](_0x42bbd6(0x135));validatePatchKeys(_0x2a6546[_0x42bbd6(0x11d)]);}function readFieldArray(_0x24a8b4){const _0x4f536d=a65_0x3a8fc2;if(Array[_0x4f536d(0x137)](_0x24a8b4[_0x4f536d(0x12c)]))return _0x24a8b4[_0x4f536d(0x12c)];if(Array[_0x4f536d(0x137)](_0x24a8b4['properties']))return _0x24a8b4[_0x4f536d(0x149)];throw CliErrors[_0x4f536d(0x128)](_0x4f536d(0x114));}function summarizeDataset(_0x8efe0,_0x271a6e){const _0x2be37c=a65_0x3a8fc2,_0x169d78=isPlainObject(_0x8efe0[_0x2be37c(0x131)])?_0x8efe0[_0x2be37c(0x131)]:{},_0x4d7e05=isPlainObject(_0x8efe0[_0x2be37c(0x132)])?_0x8efe0[_0x2be37c(0x132)]:{};return{'id':_0x8efe0['modelId']??_0x8efe0['id']??_0x169d78[_0x2be37c(0x10c)]??null,'code':_0x8efe0[_0x2be37c(0x116)]??_0x8efe0[_0x2be37c(0x141)]??_0x169d78[_0x2be37c(0x143)]??_0x271a6e,'name':_0x8efe0[_0x2be37c(0x109)]??_0x169d78[_0x2be37c(0x144)]??null,'table':_0x4d7e05[_0x2be37c(0x145)]??_0x169d78[_0x2be37c(0x145)]??null,'db':_0x4d7e05[_0x2be37c(0x119)]??_0x4d7e05['dbId']??null};}function mergePatchValue(_0x34a9bf,_0xd09914){if(isPlainObject(_0x34a9bf)&&isPlainObject(_0xd09914))return deepMerge(_0x34a9bf,_0xd09914);return deepClone(_0xd09914);}function deepMerge(_0x6bb1c1,_0xf0fc3){const _0x876753=deepClone(_0x6bb1c1);for(const [_0x4f0aa4,_0x13575c]of Object['entries'](_0xf0fc3)){_0x876753[_0x4f0aa4]=isPlainObject(_0x876753[_0x4f0aa4])&&isPlainObject(_0x13575c)?deepMerge(_0x876753[_0x4f0aa4],_0x13575c):deepClone(_0x13575c);}return _0x876753;}function collectChangedPaths(_0x389e78,_0x537cac,_0x1b4882,_0x8ee87){const _0x3377b8=a65_0x3a8fc2;if(!isPlainObject(_0x537cac)||!isPlainObject(_0x1b4882))return;const _0x38af53=new Set([...Object['keys'](_0x537cac),...Object[_0x3377b8(0x13b)](_0x1b4882)]);for(const _0x5c1051 of _0x38af53){const _0x46136e=_0x537cac[_0x5c1051],_0x415e34=_0x1b4882[_0x5c1051];!deepEqual(_0x46136e,_0x415e34)&&_0x8ee87[_0x3377b8(0x107)](_0x389e78+'.'+_0x5c1051);}}function deepClone(_0x54a954){const _0x4b5d3d=a65_0x3a8fc2;if(_0x54a954===undefined)return _0x54a954;return JSON[_0x4b5d3d(0x12e)](JSON[_0x4b5d3d(0x106)](_0x54a954));}function deepEqual(_0x94b1a3,_0x154436){const _0x5a1dbf=a65_0x3a8fc2;return JSON[_0x5a1dbf(0x106)](_0x94b1a3)===JSON[_0x5a1dbf(0x106)](_0x154436);}function isPlainObject(_0x512c46){const _0x55a362=a65_0x3a8fc2;return Boolean(_0x512c46)&&typeof _0x512c46==='object'&&!Array[_0x55a362(0x137)](_0x512c46);}function emptyToUndefined(_0x547346){const _0xbf0674=a65_0x3a8fc2,_0x56bb3a=String(_0x547346||'')[_0xbf0674(0x100)]();return _0x56bb3a||undefined;}function trim(_0x5311b7){return String(_0x5311b7||'')['trim']();}
1
+ const a65_0x21eedf=a65_0x3b8b;(function(_0x483234,_0x3db8f0){const _0x99d85b=a65_0x3b8b,_0x296e7f=_0x483234();while(!![]){try{const _0x1b5824=parseInt(_0x99d85b(0x225))/0x1*(-parseInt(_0x99d85b(0x216))/0x2)+parseInt(_0x99d85b(0x208))/0x3+-parseInt(_0x99d85b(0x1f8))/0x4+-parseInt(_0x99d85b(0x217))/0x5*(-parseInt(_0x99d85b(0x200))/0x6)+parseInt(_0x99d85b(0x1e7))/0x7*(parseInt(_0x99d85b(0x202))/0x8)+parseInt(_0x99d85b(0x231))/0x9*(parseInt(_0x99d85b(0x1f6))/0xa)+-parseInt(_0x99d85b(0x21a))/0xb*(parseInt(_0x99d85b(0x21f))/0xc);if(_0x1b5824===_0x3db8f0)break;else _0x296e7f['push'](_0x296e7f['shift']());}catch(_0x24d594){_0x296e7f['push'](_0x296e7f['shift']());}}}(a65_0x1b0f,0xd02ac));import{getDatasetDetail,updateDrivenData}from'../../core/api-client.js';import{APPCODE_FLAG_OPTIONAL,CODE_FLAG}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';const MUTABLE_FIELD_KEYS=new Set([a65_0x21eedf(0x21b),'displayName',a65_0x21eedf(0x1f3),'options',a65_0x21eedf(0x222),'datetimeFormat',a65_0x21eedf(0x227),a65_0x21eedf(0x1f1),a65_0x21eedf(0x1f7)]),FORBIDDEN_FIELD_KEYS=new Set(['id','name',a65_0x21eedf(0x214),a65_0x21eedf(0x219),'dbTypeLen','dbTypeScale',a65_0x21eedf(0x22f),a65_0x21eedf(0x1f5),a65_0x21eedf(0x1fc),'pkField',a65_0x21eedf(0x1e6),a65_0x21eedf(0x205)]);export function parseJsonObjectFlag(_0x4971ed,_0x5975f2){const _0x504abc=a65_0x21eedf;if(!_0x4971ed)return undefined;let _0x305817;try{_0x305817=JSON[_0x504abc(0x1e8)](_0x4971ed);}catch(_0xf6d19d){const _0x137f07=_0xf6d19d instanceof Error?_0xf6d19d[_0x504abc(0x1ed)]:String(_0xf6d19d);throw CliErrors[_0x504abc(0x22b)](_0x5975f2+_0x504abc(0x21c)+_0x137f07);}if(!isPlainObject(_0x305817)||Array['isArray'](_0x305817))throw CliErrors[_0x504abc(0x22b)](_0x5975f2+'\x20must\x20be\x20a\x20JSON\x20object');return _0x305817;}function a65_0x1b0f(){const _0x2c5c94=['has','keys','systemRetain','Expectation\x20mismatch\x20at\x20','JSON\x20object\x20of\x20expected\x20current\x20field\x20values;\x20mismatch\x20aborts\x20without\x20writing','3951417KeXZSD','patch','modelId','expect','Dry-run:\x20dataset\x20field\x20','Driven\x20data\x20does\x20not\x20contain\x20fields[]\x20or\x20properties[]','Forbidden\x20patch\x20key:\x20','No\x20changes\x20for\x20dataset\x20field\x20','Unsupported\x20patch\x20key:\x20','isArray','from','dbtableConfig','code','Expected\x20','239386oSHkGs','917685dbfExp','Field\x20not\x20found:\x20','dbType','11qvjvCk','doType','\x20must\x20be\x20valid\x20JSON\x20object:\x20','string','findIndex','110208dMExtb','/smartapi/dataset/update-driven-data','--field\x20is\x20required','required','data','add','11AtIgeJ','join','defaultAggregation','str','datasetId','fields','validation','datasetName','name','properties','dbFieldName','dbId','5661JeKjPe','Patch\x20one\x20raw\x20dataset\x20fields[]\x20field\x20object\x20safely','--patch-json','autoIncrement','769643DuLOpR','parse','--expect-json','\x20would\x20change\x20(','POST','field','message','Updated\x20dataset\x20field\x20','trim','patch-json','chartRole','write','description','appCode','tableName','12130GeAGoG','deprecated','6646828YGMvos','sort','JSON\x20object\x20patch;\x20allowed\x20keys:\x20doType/displayName/description/options/required/datetimeFormat/defaultAggregation/chartRole/deprecated','dataset','deleted','stringify','entries','size','18JJMKzF','expect-json','88pypnbL'];a65_0x1b0f=function(){return _0x2c5c94;};return a65_0x1b0f();}export function validatePatchKeys(_0x4309e5){const _0x2cd6ce=a65_0x21eedf,_0x3b3d3a=Object['keys'](_0x4309e5);if(_0x3b3d3a['length']===0x0)throw CliErrors[_0x2cd6ce(0x22b)]('--patch-json\x20must\x20contain\x20at\x20least\x20one\x20key');for(const _0x207db7 of _0x3b3d3a){if(FORBIDDEN_FIELD_KEYS[_0x2cd6ce(0x203)](_0x207db7))throw CliErrors[_0x2cd6ce(0x22b)](_0x2cd6ce(0x20e)+_0x207db7);if(!MUTABLE_FIELD_KEYS['has'](_0x207db7))throw CliErrors[_0x2cd6ce(0x22b)](_0x2cd6ce(0x210)+_0x207db7,'Allowed\x20keys:\x20'+Array[_0x2cd6ce(0x212)](MUTABLE_FIELD_KEYS)['join'](',\x20'));}}export function applyFieldPatch(_0x1af0c3,_0x247867){const _0x44ebfc=a65_0x21eedf;validatePatchKeys(_0x247867);const _0x444033=deepClone(_0x1af0c3),_0x4372dd=new Set();for(const [_0x2389e7,_0x353b55]of Object[_0x44ebfc(0x1fe)](_0x247867)){const _0x3d94c3=_0x444033[_0x2389e7],_0x44aedd=mergePatchValue(_0x3d94c3,_0x353b55);!deepEqual(_0x3d94c3,_0x44aedd)&&(_0x444033[_0x2389e7]=_0x44aedd,_0x4372dd[_0x44ebfc(0x224)](_0x2389e7),collectChangedPaths(_0x2389e7,_0x3d94c3,_0x44aedd,_0x4372dd));}return{'after':_0x444033,'changedPaths':Array[_0x44ebfc(0x212)](_0x4372dd)[_0x44ebfc(0x1f9)](),'changed':_0x4372dd[_0x44ebfc(0x1ff)]>0x0};}export function assertExpectation(_0x58523b,_0x9e29f5){const _0xc211d2=a65_0x21eedf;if(!_0x9e29f5)return;for(const [_0x242e60,_0x4923dc]of Object[_0xc211d2(0x1fe)](_0x9e29f5)){const _0x109830=_0x58523b[_0x242e60];if(!deepEqual(_0x109830,_0x4923dc))throw CliErrors[_0xc211d2(0x22b)](_0xc211d2(0x206)+_0x242e60,_0xc211d2(0x215)+JSON[_0xc211d2(0x1fd)](_0x4923dc)+',\x20actual\x20'+JSON[_0xc211d2(0x1fd)](_0x109830));}}export async function buildDatasetFieldUpdateResult({appCode:_0x333891,input:_0x42d886,dryRun:_0x2a3773}){const _0x4df271=a65_0x21eedf;validateInput(_0x42d886);const _0x494ca9=await getDatasetDetail(_0x42d886[_0x4df271(0x214)]),_0x264180=readFieldArray(_0x494ca9),_0x3d4c01=_0x264180[_0x4df271(0x21e)](_0x4dce51=>_0x4dce51?.[_0x4df271(0x22d)]===_0x42d886[_0x4df271(0x1ec)]);if(_0x3d4c01<0x0)throw CliErrors['validation'](_0x4df271(0x218)+_0x42d886[_0x4df271(0x1ec)]);const _0x4faf09=deepClone(_0x264180[_0x3d4c01]);assertExpectation(_0x4faf09,_0x42d886[_0x4df271(0x20b)]);const {after:_0x4c44ac,changedPaths:_0x503c1d,changed:_0x98d6b2}=applyFieldPatch(_0x4faf09,_0x42d886[_0x4df271(0x209)]),_0x1d8fb1=summarizeDataset(_0x494ca9,_0x42d886[_0x4df271(0x214)]);return _0x98d6b2&&!_0x2a3773&&(_0x264180[_0x3d4c01]=_0x4c44ac,await updateDrivenData(_0x494ca9)),{'ok':!![],'data':{'appCode':_0x333891,'selector':{'code':_0x42d886[_0x4df271(0x214)]},'dataset':_0x1d8fb1,'field':{'id':_0x4faf09['id']??null,'name':_0x4faf09[_0x4df271(0x22d)]},'dryRun':_0x2a3773,'changed':_0x98d6b2,'changedPaths':_0x503c1d,'before':_0x4faf09,'after':_0x4c44ac,'submitted':_0x98d6b2&&!_0x2a3773},'message':_0x98d6b2?_0x2a3773?_0x4df271(0x20c)+_0x42d886[_0x4df271(0x1ec)]+_0x4df271(0x1ea)+_0x503c1d[_0x4df271(0x226)](',\x20')+')':_0x4df271(0x1ee)+_0x42d886['field']+'\x20('+_0x503c1d[_0x4df271(0x226)](',\x20')+')':_0x4df271(0x20f)+_0x42d886[_0x4df271(0x1ec)]};}export const datasetFieldUpdate={'service':'dataset','command':'field-update','description':a65_0x21eedf(0x232),'risk':a65_0x21eedf(0x1f2),'flags':[CODE_FLAG,{'name':'field','type':a65_0x21eedf(0x21d),'required':!![],'description':'Exact\x20raw\x20fields[].name\x20to\x20patch'},{'name':a65_0x21eedf(0x1f0),'type':a65_0x21eedf(0x21d),'required':!![],'description':a65_0x21eedf(0x1fa)},{'name':a65_0x21eedf(0x201),'type':a65_0x21eedf(0x21d),'required':![],'description':a65_0x21eedf(0x207)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x23f9f8){validateInput(readFieldUpdateInput(_0x23f9f8));},async 'dryRun'(_0x4fcc82){const _0x1e8f71=a65_0x21eedf,_0x243aad=await buildDatasetFieldUpdateResult({'appCode':_0x4fcc82['appCode'],'input':readFieldUpdateInput(_0x4fcc82),'dryRun':!![]});return{'method':_0x1e8f71(0x1eb),'url':_0x1e8f71(0x220),'body':_0x243aad[_0x1e8f71(0x223)],'description':_0x243aad['message']};},async 'execute'(_0x44127e){const _0x1c118d=a65_0x21eedf;return buildDatasetFieldUpdateResult({'appCode':_0x44127e[_0x1c118d(0x1f4)],'input':readFieldUpdateInput(_0x44127e),'dryRun':![]});}};function readFieldUpdateInput(_0x53c64e){const _0x1c87ed=a65_0x21eedf,_0x13f040=trim(_0x53c64e[_0x1c87ed(0x228)](_0x1c87ed(0x214))),_0x8a9321=emptyToUndefined(_0x53c64e['str'](_0x1c87ed(0x1ec))),_0xdf44d4=parseJsonObjectFlag(_0x53c64e['str'](_0x1c87ed(0x1f0)),_0x1c87ed(0x233)),_0x131dda=parseJsonObjectFlag(_0x53c64e[_0x1c87ed(0x228)](_0x1c87ed(0x201)),_0x1c87ed(0x1e9));return{'code':_0x13f040,'field':_0x8a9321||'','patch':_0xdf44d4||{},'expect':_0x131dda};}function validateInput(_0x4cc7d2){const _0x482fb3=a65_0x21eedf;if(!_0x4cc7d2[_0x482fb3(0x214)])throw CliErrors[_0x482fb3(0x22b)]('--code\x20is\x20required');if(!_0x4cc7d2[_0x482fb3(0x1ec)])throw CliErrors['validation'](_0x482fb3(0x221));validatePatchKeys(_0x4cc7d2['patch']);}function readFieldArray(_0x31b90a){const _0x3f02ce=a65_0x21eedf;if(Array[_0x3f02ce(0x211)](_0x31b90a['fields']))return _0x31b90a[_0x3f02ce(0x22a)];if(Array[_0x3f02ce(0x211)](_0x31b90a[_0x3f02ce(0x22e)]))return _0x31b90a[_0x3f02ce(0x22e)];throw CliErrors[_0x3f02ce(0x22b)](_0x3f02ce(0x20d));}function summarizeDataset(_0x5796b2,_0x4725da){const _0x5b9f01=a65_0x21eedf,_0x2aed37=isPlainObject(_0x5796b2[_0x5b9f01(0x1fb)])?_0x5796b2[_0x5b9f01(0x1fb)]:{},_0xac7eca=isPlainObject(_0x5796b2['dbtableConfig'])?_0x5796b2[_0x5b9f01(0x213)]:{};return{'id':_0x5796b2[_0x5b9f01(0x20a)]??_0x5796b2['id']??_0x2aed37[_0x5b9f01(0x229)]??null,'code':_0x5796b2['modelCode']??_0x5796b2[_0x5b9f01(0x214)]??_0x2aed37['datasetCode']??_0x4725da,'name':_0x5796b2[_0x5b9f01(0x22d)]??_0x2aed37[_0x5b9f01(0x22c)]??null,'table':_0xac7eca['tableName']??_0x2aed37[_0x5b9f01(0x1f5)]??null,'db':_0xac7eca['dbName']??_0xac7eca[_0x5b9f01(0x230)]??null};}function mergePatchValue(_0x5f4b5a,_0x4e88f2){if(isPlainObject(_0x5f4b5a)&&isPlainObject(_0x4e88f2))return deepMerge(_0x5f4b5a,_0x4e88f2);return deepClone(_0x4e88f2);}function deepMerge(_0xe5e8d3,_0x4b8032){const _0x346bde=deepClone(_0xe5e8d3);for(const [_0x7369b4,_0xb24b9a]of Object['entries'](_0x4b8032)){_0x346bde[_0x7369b4]=isPlainObject(_0x346bde[_0x7369b4])&&isPlainObject(_0xb24b9a)?deepMerge(_0x346bde[_0x7369b4],_0xb24b9a):deepClone(_0xb24b9a);}return _0x346bde;}function collectChangedPaths(_0x3a4b49,_0x458cfb,_0xd8bb1f,_0x19ea2e){const _0x160e91=a65_0x21eedf;if(!isPlainObject(_0x458cfb)||!isPlainObject(_0xd8bb1f))return;const _0x3078b2=new Set([...Object[_0x160e91(0x204)](_0x458cfb),...Object['keys'](_0xd8bb1f)]);for(const _0x4f0f4b of _0x3078b2){const _0x1ab2d5=_0x458cfb[_0x4f0f4b],_0x334072=_0xd8bb1f[_0x4f0f4b];!deepEqual(_0x1ab2d5,_0x334072)&&_0x19ea2e[_0x160e91(0x224)](_0x3a4b49+'.'+_0x4f0f4b);}}function a65_0x3b8b(_0x3058d6,_0x5a9b96){_0x3058d6=_0x3058d6-0x1e6;const _0x1b0f29=a65_0x1b0f();let _0x3b8be3=_0x1b0f29[_0x3058d6];return _0x3b8be3;}function deepClone(_0x381203){const _0x39ccad=a65_0x21eedf;if(_0x381203===undefined)return _0x381203;return JSON['parse'](JSON[_0x39ccad(0x1fd)](_0x381203));}function deepEqual(_0x2fbca9,_0x27676e){const _0x3751a5=a65_0x21eedf;return JSON[_0x3751a5(0x1fd)](_0x2fbca9)===JSON['stringify'](_0x27676e);}function isPlainObject(_0x542e2a){return Boolean(_0x542e2a)&&typeof _0x542e2a==='object'&&!Array['isArray'](_0x542e2a);}function emptyToUndefined(_0xf613e5){const _0x181c53=a65_0x21eedf,_0x52c56b=String(_0xf613e5||'')[_0x181c53(0x1ef)]();return _0x52c56b||undefined;}function trim(_0x4707c5){const _0x1d33a8=a65_0x21eedf;return String(_0x4707c5||'')[_0x1d33a8(0x1ef)]();}