@servicenow/sdk-build-plugins 4.2.0 → 4.4.0

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 (349) hide show
  1. package/dist/acl-plugin.js +11 -0
  2. package/dist/acl-plugin.js.map +1 -1
  3. package/dist/applicability-plugin.d.ts +2 -0
  4. package/dist/applicability-plugin.js +72 -0
  5. package/dist/applicability-plugin.js.map +1 -0
  6. package/dist/atf/test-plugin.js +5 -2
  7. package/dist/atf/test-plugin.js.map +1 -1
  8. package/dist/basic-syntax-plugin.js +7 -1
  9. package/dist/basic-syntax-plugin.js.map +1 -1
  10. package/dist/business-rule-plugin.js +1 -0
  11. package/dist/business-rule-plugin.js.map +1 -1
  12. package/dist/call-expression-plugin.js +1 -107
  13. package/dist/call-expression-plugin.js.map +1 -1
  14. package/dist/column/column-to-record.d.ts +10 -3
  15. package/dist/column/column-to-record.js +44 -7
  16. package/dist/column/column-to-record.js.map +1 -1
  17. package/dist/column-plugin.d.ts +3 -1
  18. package/dist/column-plugin.js +12 -12
  19. package/dist/column-plugin.js.map +1 -1
  20. package/dist/dashboard/dashboard-component-property-defaults.d.ts +152 -0
  21. package/dist/dashboard/dashboard-component-property-defaults.js +264 -0
  22. package/dist/dashboard/dashboard-component-property-defaults.js.map +1 -0
  23. package/dist/dashboard/dashboard-component-resolver.d.ts +13 -0
  24. package/dist/dashboard/dashboard-component-resolver.js +69 -0
  25. package/dist/dashboard/dashboard-component-resolver.js.map +1 -0
  26. package/dist/dashboard/dashboard-plugin.d.ts +12 -0
  27. package/dist/dashboard/dashboard-plugin.js +397 -0
  28. package/dist/dashboard/dashboard-plugin.js.map +1 -0
  29. package/dist/data-plugin.d.ts +3 -0
  30. package/dist/data-plugin.js +61 -113
  31. package/dist/data-plugin.js.map +1 -1
  32. package/dist/email-notification-plugin.d.ts +2 -0
  33. package/dist/email-notification-plugin.js +541 -0
  34. package/dist/email-notification-plugin.js.map +1 -0
  35. package/dist/flow/constants/flow-plugin-constants.d.ts +58 -0
  36. package/dist/flow/constants/flow-plugin-constants.js +70 -0
  37. package/dist/flow/constants/flow-plugin-constants.js.map +1 -0
  38. package/dist/flow/flow-logic/flow-logic-constants.d.ts +38 -0
  39. package/dist/flow/flow-logic/flow-logic-constants.js +118 -0
  40. package/dist/flow/flow-logic/flow-logic-constants.js.map +1 -0
  41. package/dist/flow/flow-logic/flow-logic-diagnostics.d.ts +19 -0
  42. package/dist/flow/flow-logic/flow-logic-diagnostics.js +503 -0
  43. package/dist/flow/flow-logic/flow-logic-diagnostics.js.map +1 -0
  44. package/dist/flow/flow-logic/flow-logic-plugin-helpers.d.ts +62 -0
  45. package/dist/flow/flow-logic/flow-logic-plugin-helpers.js +2092 -0
  46. package/dist/flow/flow-logic/flow-logic-plugin-helpers.js.map +1 -0
  47. package/dist/flow/flow-logic/flow-logic-plugin.d.ts +52 -0
  48. package/dist/flow/flow-logic/flow-logic-plugin.js +283 -0
  49. package/dist/flow/flow-logic/flow-logic-plugin.js.map +1 -0
  50. package/dist/flow/flow-logic/flow-logic-shapes.d.ts +104 -0
  51. package/dist/flow/flow-logic/flow-logic-shapes.js +201 -0
  52. package/dist/flow/flow-logic/flow-logic-shapes.js.map +1 -0
  53. package/dist/flow/plugins/approval-rules-plugin.d.ts +2 -0
  54. package/dist/flow/plugins/approval-rules-plugin.js +49 -0
  55. package/dist/flow/plugins/approval-rules-plugin.js.map +1 -0
  56. package/dist/flow/plugins/flow-action-definition-plugin.d.ts +2 -0
  57. package/dist/flow/plugins/flow-action-definition-plugin.js +286 -0
  58. package/dist/flow/plugins/flow-action-definition-plugin.js.map +1 -0
  59. package/dist/flow/plugins/flow-data-pill-plugin.d.ts +9 -0
  60. package/dist/flow/plugins/flow-data-pill-plugin.js +212 -0
  61. package/dist/flow/plugins/flow-data-pill-plugin.js.map +1 -0
  62. package/dist/flow/plugins/flow-definition-plugin.d.ts +2 -0
  63. package/dist/flow/plugins/flow-definition-plugin.js +1668 -0
  64. package/dist/flow/plugins/flow-definition-plugin.js.map +1 -0
  65. package/dist/flow/plugins/flow-diagnostics-plugin.d.ts +26 -0
  66. package/dist/flow/plugins/flow-diagnostics-plugin.js +217 -0
  67. package/dist/flow/plugins/flow-diagnostics-plugin.js.map +1 -0
  68. package/dist/flow/plugins/flow-instance-plugin.d.ts +12 -0
  69. package/dist/flow/plugins/flow-instance-plugin.js +1205 -0
  70. package/dist/flow/plugins/flow-instance-plugin.js.map +1 -0
  71. package/dist/flow/plugins/flow-trigger-instance-plugin.d.ts +2 -0
  72. package/dist/flow/plugins/flow-trigger-instance-plugin.js +338 -0
  73. package/dist/flow/plugins/flow-trigger-instance-plugin.js.map +1 -0
  74. package/dist/flow/plugins/inline-script-plugin.d.ts +39 -0
  75. package/dist/flow/plugins/inline-script-plugin.js +80 -0
  76. package/dist/flow/plugins/inline-script-plugin.js.map +1 -0
  77. package/dist/flow/plugins/step-definition-plugin.d.ts +5 -0
  78. package/dist/flow/plugins/step-definition-plugin.js +71 -0
  79. package/dist/flow/plugins/step-definition-plugin.js.map +1 -0
  80. package/dist/flow/plugins/step-instance-plugin.d.ts +31 -0
  81. package/dist/flow/plugins/step-instance-plugin.js +339 -0
  82. package/dist/flow/plugins/step-instance-plugin.js.map +1 -0
  83. package/dist/flow/plugins/trigger-plugin.d.ts +2 -0
  84. package/dist/flow/plugins/trigger-plugin.js +96 -0
  85. package/dist/flow/plugins/trigger-plugin.js.map +1 -0
  86. package/dist/flow/plugins/wfa-datapill-plugin.d.ts +15 -0
  87. package/dist/flow/plugins/wfa-datapill-plugin.js +178 -0
  88. package/dist/flow/plugins/wfa-datapill-plugin.js.map +1 -0
  89. package/dist/flow/utils/approval-rules-processor.d.ts +13 -0
  90. package/dist/flow/utils/approval-rules-processor.js +267 -0
  91. package/dist/flow/utils/approval-rules-processor.js.map +1 -0
  92. package/dist/flow/utils/built-in-complex-objects.d.ts +19 -0
  93. package/dist/flow/utils/built-in-complex-objects.js +62 -0
  94. package/dist/flow/utils/built-in-complex-objects.js.map +1 -0
  95. package/dist/flow/utils/complex-object-resolver.d.ts +8 -0
  96. package/dist/flow/utils/complex-object-resolver.js +614 -0
  97. package/dist/flow/utils/complex-object-resolver.js.map +1 -0
  98. package/dist/flow/utils/complex-objects.d.ts +36 -0
  99. package/dist/flow/utils/complex-objects.js +481 -0
  100. package/dist/flow/utils/complex-objects.js.map +1 -0
  101. package/dist/flow/utils/data-pill-shapes.d.ts +58 -0
  102. package/dist/flow/utils/data-pill-shapes.js +135 -0
  103. package/dist/flow/utils/data-pill-shapes.js.map +1 -0
  104. package/dist/flow/utils/datapill-transformer.d.ts +110 -0
  105. package/dist/flow/utils/datapill-transformer.js +503 -0
  106. package/dist/flow/utils/datapill-transformer.js.map +1 -0
  107. package/dist/flow/utils/flow-constants.d.ts +72 -0
  108. package/dist/flow/utils/flow-constants.js +230 -0
  109. package/dist/flow/utils/flow-constants.js.map +1 -0
  110. package/dist/flow/utils/flow-io-to-record.d.ts +44 -0
  111. package/dist/flow/utils/flow-io-to-record.js +409 -0
  112. package/dist/flow/utils/flow-io-to-record.js.map +1 -0
  113. package/dist/flow/utils/flow-shapes.d.ts +161 -0
  114. package/dist/flow/utils/flow-shapes.js +255 -0
  115. package/dist/flow/utils/flow-shapes.js.map +1 -0
  116. package/dist/flow/utils/flow-to-xml.d.ts +16 -0
  117. package/dist/flow/utils/flow-to-xml.js +237 -0
  118. package/dist/flow/utils/flow-to-xml.js.map +1 -0
  119. package/dist/flow/utils/flow-variable-processor.d.ts +51 -0
  120. package/dist/flow/utils/flow-variable-processor.js +69 -0
  121. package/dist/flow/utils/flow-variable-processor.js.map +1 -0
  122. package/dist/flow/utils/label-cache-parser.d.ts +7 -0
  123. package/dist/flow/utils/label-cache-parser.js +24 -0
  124. package/dist/flow/utils/label-cache-parser.js.map +1 -0
  125. package/dist/flow/utils/label-cache-processor.d.ts +119 -0
  126. package/dist/flow/utils/label-cache-processor.js +719 -0
  127. package/dist/flow/utils/label-cache-processor.js.map +1 -0
  128. package/dist/flow/utils/pill-string-parser.d.ts +88 -0
  129. package/dist/flow/utils/pill-string-parser.js +306 -0
  130. package/dist/flow/utils/pill-string-parser.js.map +1 -0
  131. package/dist/flow/utils/schema-to-flow-object.d.ts +22 -0
  132. package/dist/flow/utils/schema-to-flow-object.js +318 -0
  133. package/dist/flow/utils/schema-to-flow-object.js.map +1 -0
  134. package/dist/flow/utils/service-catalog.d.ts +47 -0
  135. package/dist/flow/utils/service-catalog.js +137 -0
  136. package/dist/flow/utils/service-catalog.js.map +1 -0
  137. package/dist/flow/utils/utils.d.ts +117 -0
  138. package/dist/flow/utils/utils.js +345 -0
  139. package/dist/flow/utils/utils.js.map +1 -0
  140. package/dist/index.d.ts +20 -1
  141. package/dist/index.js +21 -1
  142. package/dist/index.js.map +1 -1
  143. package/dist/list-plugin.js +1 -1
  144. package/dist/list-plugin.js.map +1 -1
  145. package/dist/now-attach-plugin.d.ts +1 -0
  146. package/dist/now-attach-plugin.js +10 -10
  147. package/dist/now-attach-plugin.js.map +1 -1
  148. package/dist/now-ref-plugin.js +1 -1
  149. package/dist/now-ref-plugin.js.map +1 -1
  150. package/dist/record-plugin.d.ts +29 -0
  151. package/dist/record-plugin.js +66 -7
  152. package/dist/record-plugin.js.map +1 -1
  153. package/dist/repack/index.d.ts +2 -0
  154. package/dist/repack/index.js +8 -0
  155. package/dist/repack/index.js.map +1 -1
  156. package/dist/rest-api-plugin.js +54 -44
  157. package/dist/rest-api-plugin.js.map +1 -1
  158. package/dist/server-module-plugin/index.d.ts +10 -0
  159. package/dist/server-module-plugin/index.js +83 -59
  160. package/dist/server-module-plugin/index.js.map +1 -1
  161. package/dist/service-catalog/catalog-clientscript-plugin.d.ts +2 -0
  162. package/dist/service-catalog/catalog-clientscript-plugin.js +117 -0
  163. package/dist/service-catalog/catalog-clientscript-plugin.js.map +1 -0
  164. package/dist/service-catalog/catalog-item-plugin.d.ts +2 -0
  165. package/dist/service-catalog/catalog-item-plugin.js +115 -0
  166. package/dist/service-catalog/catalog-item-plugin.js.map +1 -0
  167. package/dist/service-catalog/catalog-ui-policy-plugin.d.ts +2 -0
  168. package/dist/service-catalog/catalog-ui-policy-plugin.js +266 -0
  169. package/dist/service-catalog/catalog-ui-policy-plugin.js.map +1 -0
  170. package/dist/service-catalog/index.d.ts +5 -0
  171. package/dist/service-catalog/index.js +22 -0
  172. package/dist/service-catalog/index.js.map +1 -0
  173. package/dist/service-catalog/record-to-shape.d.ts +6 -0
  174. package/dist/service-catalog/record-to-shape.js +93 -0
  175. package/dist/service-catalog/record-to-shape.js.map +1 -0
  176. package/dist/service-catalog/sc-record-producer-plugin.d.ts +2 -0
  177. package/dist/service-catalog/sc-record-producer-plugin.js +140 -0
  178. package/dist/service-catalog/sc-record-producer-plugin.js.map +1 -0
  179. package/dist/service-catalog/service-catalog-base.d.ts +311 -0
  180. package/dist/service-catalog/service-catalog-base.js +542 -0
  181. package/dist/service-catalog/service-catalog-base.js.map +1 -0
  182. package/dist/service-catalog/service-catalog-diagnostics.d.ts +45 -0
  183. package/dist/service-catalog/service-catalog-diagnostics.js +172 -0
  184. package/dist/service-catalog/service-catalog-diagnostics.js.map +1 -0
  185. package/dist/service-catalog/shape-to-record.d.ts +8 -0
  186. package/dist/service-catalog/shape-to-record.js +235 -0
  187. package/dist/service-catalog/shape-to-record.js.map +1 -0
  188. package/dist/service-catalog/utils.d.ts +323 -0
  189. package/dist/service-catalog/utils.js +1216 -0
  190. package/dist/service-catalog/utils.js.map +1 -0
  191. package/dist/service-catalog/variable-helper.d.ts +43 -0
  192. package/dist/service-catalog/variable-helper.js +92 -0
  193. package/dist/service-catalog/variable-helper.js.map +1 -0
  194. package/dist/service-catalog/variable-set-plugin.d.ts +2 -0
  195. package/dist/service-catalog/variable-set-plugin.js +175 -0
  196. package/dist/service-catalog/variable-set-plugin.js.map +1 -0
  197. package/dist/service-catalog/variables-transform.d.ts +139 -0
  198. package/dist/service-catalog/variables-transform.js +403 -0
  199. package/dist/service-catalog/variables-transform.js.map +1 -0
  200. package/dist/sla/sla-validators.d.ts +61 -0
  201. package/dist/sla/sla-validators.js +224 -0
  202. package/dist/sla/sla-validators.js.map +1 -0
  203. package/dist/sla-plugin.d.ts +5 -0
  204. package/dist/sla-plugin.js +280 -0
  205. package/dist/sla-plugin.js.map +1 -0
  206. package/dist/static-content-plugin.js +25 -2
  207. package/dist/static-content-plugin.js.map +1 -1
  208. package/dist/table-plugin.js +32 -15
  209. package/dist/table-plugin.js.map +1 -1
  210. package/dist/ui-page-plugin.js +832 -19
  211. package/dist/ui-page-plugin.js.map +1 -1
  212. package/dist/ui-policy-plugin.js +5 -7
  213. package/dist/ui-policy-plugin.js.map +1 -1
  214. package/dist/utils.d.ts +10 -1
  215. package/dist/utils.js +16 -0
  216. package/dist/utils.js.map +1 -1
  217. package/dist/ux-list-menu-config-plugin.d.ts +2 -0
  218. package/dist/ux-list-menu-config-plugin.js +292 -0
  219. package/dist/ux-list-menu-config-plugin.js.map +1 -0
  220. package/dist/workspace-plugin/chrome-tab.d.ts +2 -0
  221. package/dist/workspace-plugin/chrome-tab.js +46 -0
  222. package/dist/workspace-plugin/chrome-tab.js.map +1 -0
  223. package/dist/workspace-plugin/constants.d.ts +52 -0
  224. package/dist/workspace-plugin/constants.js +56 -0
  225. package/dist/workspace-plugin/constants.js.map +1 -0
  226. package/dist/workspace-plugin/fluent-utils.d.ts +9 -0
  227. package/dist/workspace-plugin/fluent-utils.js +60 -0
  228. package/dist/workspace-plugin/fluent-utils.js.map +1 -0
  229. package/dist/workspace-plugin/page.d.ts +8 -0
  230. package/dist/workspace-plugin/page.js +108 -0
  231. package/dist/workspace-plugin/page.js.map +1 -0
  232. package/dist/workspace-plugin/screen.d.ts +1 -0
  233. package/dist/workspace-plugin/screen.js +38 -0
  234. package/dist/workspace-plugin/screen.js.map +1 -0
  235. package/dist/workspace-plugin/templates/index.d.ts +10 -0
  236. package/dist/workspace-plugin/templates/index.js +20 -0
  237. package/dist/workspace-plugin/templates/index.js.map +1 -0
  238. package/dist/workspace-plugin/templates/record-page-composition.d.ts +1 -0
  239. package/dist/workspace-plugin/templates/record-page-composition.js +4043 -0
  240. package/dist/workspace-plugin/templates/record-page-composition.js.map +1 -0
  241. package/dist/workspace-plugin/templates/record-page-data.d.ts +1 -0
  242. package/dist/workspace-plugin/templates/record-page-data.js +527 -0
  243. package/dist/workspace-plugin/templates/record-page-data.js.map +1 -0
  244. package/dist/workspace-plugin/templates/record-page-interalEventMappings.d.ts +1 -0
  245. package/dist/workspace-plugin/templates/record-page-interalEventMappings.js +39 -0
  246. package/dist/workspace-plugin/templates/record-page-interalEventMappings.js.map +1 -0
  247. package/dist/workspace-plugin/templates/record-page-layoutModel.d.ts +1 -0
  248. package/dist/workspace-plugin/templates/record-page-layoutModel.js +55 -0
  249. package/dist/workspace-plugin/templates/record-page-layoutModel.js.map +1 -0
  250. package/dist/workspace-plugin/templates/record-page-properties.d.ts +1 -0
  251. package/dist/workspace-plugin/templates/record-page-properties.js +135 -0
  252. package/dist/workspace-plugin/templates/record-page-properties.js.map +1 -0
  253. package/dist/workspace-plugin/templates/record-page.d.ts +3 -0
  254. package/dist/workspace-plugin/templates/record-page.js +8 -0
  255. package/dist/workspace-plugin/templates/record-page.js.map +1 -0
  256. package/dist/workspace-plugin.d.ts +2 -0
  257. package/dist/workspace-plugin.js +453 -0
  258. package/dist/workspace-plugin.js.map +1 -0
  259. package/package.json +10 -12
  260. package/src/acl-plugin.ts +16 -1
  261. package/src/applicability-plugin.ts +82 -0
  262. package/src/atf/test-plugin.ts +6 -3
  263. package/src/basic-syntax-plugin.ts +10 -1
  264. package/src/business-rule-plugin.ts +2 -1
  265. package/src/call-expression-plugin.ts +2 -130
  266. package/src/column/column-to-record.ts +54 -8
  267. package/src/column-plugin.ts +29 -13
  268. package/src/dashboard/dashboard-component-property-defaults.ts +277 -0
  269. package/src/dashboard/dashboard-component-resolver.ts +69 -0
  270. package/src/dashboard/dashboard-plugin.ts +450 -0
  271. package/src/data-plugin.ts +67 -139
  272. package/src/email-notification-plugin.ts +850 -0
  273. package/src/flow/constants/flow-plugin-constants.ts +79 -0
  274. package/src/flow/flow-logic/flow-logic-constants.ts +120 -0
  275. package/src/flow/flow-logic/flow-logic-diagnostics.ts +591 -0
  276. package/src/flow/flow-logic/flow-logic-plugin-helpers.ts +2550 -0
  277. package/src/flow/flow-logic/flow-logic-plugin.ts +337 -0
  278. package/src/flow/flow-logic/flow-logic-shapes.ts +215 -0
  279. package/src/flow/plugins/approval-rules-plugin.ts +48 -0
  280. package/src/flow/plugins/flow-action-definition-plugin.ts +295 -0
  281. package/src/flow/plugins/flow-data-pill-plugin.ts +258 -0
  282. package/src/flow/plugins/flow-definition-plugin.ts +2173 -0
  283. package/src/flow/plugins/flow-diagnostics-plugin.ts +280 -0
  284. package/src/flow/plugins/flow-instance-plugin.ts +1499 -0
  285. package/src/flow/plugins/flow-trigger-instance-plugin.ts +444 -0
  286. package/src/flow/plugins/inline-script-plugin.ts +83 -0
  287. package/src/flow/plugins/step-definition-plugin.ts +67 -0
  288. package/src/flow/plugins/step-instance-plugin.ts +431 -0
  289. package/src/flow/plugins/trigger-plugin.ts +95 -0
  290. package/src/flow/plugins/wfa-datapill-plugin.ts +213 -0
  291. package/src/flow/utils/approval-rules-processor.ts +298 -0
  292. package/src/flow/utils/built-in-complex-objects.ts +81 -0
  293. package/src/flow/utils/complex-object-resolver.ts +875 -0
  294. package/src/flow/utils/complex-objects.ts +656 -0
  295. package/src/flow/utils/data-pill-shapes.ts +165 -0
  296. package/src/flow/utils/datapill-transformer.ts +632 -0
  297. package/src/flow/utils/flow-constants.ts +285 -0
  298. package/src/flow/utils/flow-io-to-record.ts +533 -0
  299. package/src/flow/utils/flow-shapes.ts +296 -0
  300. package/src/flow/utils/flow-to-xml.ts +318 -0
  301. package/src/flow/utils/flow-variable-processor.ts +100 -0
  302. package/src/flow/utils/label-cache-parser.ts +37 -0
  303. package/src/flow/utils/label-cache-processor.ts +870 -0
  304. package/src/flow/utils/pill-string-parser.ts +375 -0
  305. package/src/flow/utils/schema-to-flow-object.ts +385 -0
  306. package/src/flow/utils/service-catalog.ts +174 -0
  307. package/src/flow/utils/utils.ts +395 -0
  308. package/src/index.ts +20 -1
  309. package/src/list-plugin.ts +1 -1
  310. package/src/now-attach-plugin.ts +14 -11
  311. package/src/now-ref-plugin.ts +1 -1
  312. package/src/record-plugin.ts +76 -11
  313. package/src/repack/index.ts +14 -0
  314. package/src/rest-api-plugin.ts +62 -50
  315. package/src/server-module-plugin/index.ts +112 -86
  316. package/src/service-catalog/catalog-clientscript-plugin.ts +140 -0
  317. package/src/service-catalog/catalog-item-plugin.ts +162 -0
  318. package/src/service-catalog/catalog-ui-policy-plugin.ts +324 -0
  319. package/src/service-catalog/index.ts +5 -0
  320. package/src/service-catalog/record-to-shape.ts +109 -0
  321. package/src/service-catalog/sc-record-producer-plugin.ts +201 -0
  322. package/src/service-catalog/service-catalog-base.ts +600 -0
  323. package/src/service-catalog/service-catalog-diagnostics.ts +254 -0
  324. package/src/service-catalog/shape-to-record.ts +279 -0
  325. package/src/service-catalog/utils.ts +1455 -0
  326. package/src/service-catalog/variable-helper.ts +135 -0
  327. package/src/service-catalog/variable-set-plugin.ts +197 -0
  328. package/src/service-catalog/variables-transform.ts +438 -0
  329. package/src/sla/sla-validators.ts +331 -0
  330. package/src/sla-plugin.ts +358 -0
  331. package/src/static-content-plugin.ts +25 -2
  332. package/src/table-plugin.ts +49 -16
  333. package/src/ui-page-plugin.ts +1063 -20
  334. package/src/ui-policy-plugin.ts +5 -9
  335. package/src/utils.ts +24 -1
  336. package/src/ux-list-menu-config-plugin.ts +312 -0
  337. package/src/workspace-plugin/chrome-tab.ts +44 -0
  338. package/src/workspace-plugin/constants.ts +53 -0
  339. package/src/workspace-plugin/fluent-utils.ts +60 -0
  340. package/src/workspace-plugin/page.ts +139 -0
  341. package/src/workspace-plugin/screen.ts +34 -0
  342. package/src/workspace-plugin/templates/index.ts +17 -0
  343. package/src/workspace-plugin/templates/record-page-composition.ts +4051 -0
  344. package/src/workspace-plugin/templates/record-page-data.ts +523 -0
  345. package/src/workspace-plugin/templates/record-page-interalEventMappings.ts +35 -0
  346. package/src/workspace-plugin/templates/record-page-layoutModel.ts +51 -0
  347. package/src/workspace-plugin/templates/record-page-properties.ts +131 -0
  348. package/src/workspace-plugin/templates/record-page.ts +6 -0
  349. package/src/workspace-plugin.ts +574 -0
@@ -0,0 +1,213 @@
1
+ import { type Result, Plugin, type Shape, ts } from '@servicenow/sdk-build-core'
2
+ import { getCallExpressionName } from '../../utils'
3
+ import { findAncestorByCalleeName } from '../utils/utils'
4
+ import { DataPillPlugin } from './flow-data-pill-plugin'
5
+ import { BasicSyntaxPlugin } from '../../basic-syntax-plugin'
6
+ import { ForEachItemShape, PillShape } from '../utils/data-pill-shapes'
7
+ import { FLOW_LOGIC } from '../flow-logic/flow-logic-constants'
8
+
9
+ const DATAPILL_CALLEE = 'wfa.dataPill'
10
+
11
+ // ============================================================================
12
+ // HELPER FUNCTIONS
13
+ // ============================================================================
14
+
15
+ /**
16
+ * Checks if a node is the items argument (first argument) of wfa.flowLogic.forEach()
17
+ *
18
+ * Verifies the following conditions:
19
+ * 1. The immediate parent is a CallExpression
20
+ * 2. The parent's callee is 'wfa.flowLogic.forEach'
21
+ * 3. The node is the first argument of that forEach call
22
+ *
23
+ * @param node - The node to check
24
+ * @returns true if the node is the items argument of forEach, false otherwise
25
+ */
26
+ function isForEachItemsArgument(node: ts.Node): boolean {
27
+ const parentCall = node.getParentIfKind(ts.SyntaxKind.CallExpression)
28
+ return (
29
+ parentCall !== undefined &&
30
+ getCallExpressionName(parentCall) === FLOW_LOGIC.FOR_EACH &&
31
+ parentCall.getArguments()[0] === node
32
+ )
33
+ }
34
+
35
+ /**
36
+ * Extracts metadata from the TypeScript type of a data pill expression.
37
+ * This includes parent table name, column name, and reference table.
38
+ *
39
+ * For example, for params.trigger.current.company:
40
+ * - parentTableName: "user_criteria" (from the record type)
41
+ * - columnName: "company" (the property being accessed)
42
+ * - reference: "core_company" (from the column's referenceTable property)
43
+ */
44
+ function extractMetadataFromType(node: ts.Node): {
45
+ parentTableName: string | null
46
+ columnName: string | null
47
+ reference: string | null
48
+ } {
49
+ let parentTableName: string | null = null
50
+ let columnName: string | null = null
51
+ let reference: string | null = null
52
+
53
+ // For property access like params.trigger.current.company or outOfStockAssets.Records
54
+ if (ts.Node.isPropertyAccessExpression(node)) {
55
+ // Get the property name (e.g., "company" or "Records")
56
+ columnName = node.getName()
57
+
58
+ // Get the parent expression (e.g., params.trigger.current or outOfStockAssets)
59
+ const parentExpr = node.getExpression()
60
+ const parentType = parentExpr.getType()
61
+ const parentTypeText = parentType.getText()
62
+
63
+ // Pattern A: Check for OutputsWithDependentTable<..., "table_name"> from action outputs
64
+ // e.g., OutputsWithDependentTable<{...}, "alm_hardware"> & {...}
65
+ // The type text contains nested brackets, so we look for the pattern: }, "table_name"> &
66
+ if (parentTypeText.includes('OutputsWithDependentTable')) {
67
+ const outputsDependentMatch = parentTypeText.match(/},\s*["']([^"']+)["']\s*>\s*&/)
68
+ if (outputsDependentMatch?.[1]) {
69
+ reference = outputsDependentMatch[1]
70
+ }
71
+ }
72
+
73
+ // Try to extract the table name from TableAwareRecordRecursive or similar types
74
+ if (!reference) {
75
+ const tableMatch = parentTypeText.match(/TableAwareRecord(?:Recursive|WithFallback)?<["']([^"']+)["']/)
76
+ if (tableMatch?.[1]) {
77
+ parentTableName = tableMatch[1]
78
+ }
79
+ }
80
+
81
+ // Get the type of the property being accessed
82
+ const propertyType = node.getType()
83
+ const propertyTypeText = propertyType.getText()
84
+
85
+ // Try to extract referenceTable from the property type
86
+ // Pattern 1: Check if the property type is itself a TableAwareRecordRecursive type
87
+ // e.g., TableAwareRecordRecursive<"core_company", 2>
88
+ if (!reference) {
89
+ const tableTypeMatch = propertyTypeText.match(
90
+ /TableAwareRecord(?:Recursive|WithFallback)?<["']([^"']+)["']/
91
+ )
92
+ if (tableTypeMatch?.[1]) {
93
+ reference = tableTypeMatch[1]
94
+ }
95
+ }
96
+ }
97
+
98
+ return { parentTableName, columnName, reference }
99
+ }
100
+
101
+ // ============================================================================
102
+ // PLUGIN DEFINITION
103
+ // ============================================================================
104
+
105
+ /**
106
+ * WfaDataPillPlugin - Handles wfa.dataPill() CallExpressions
107
+ *
108
+ * This plugin processes datapill wrapper calls and converts them to PillShape.
109
+ *
110
+ * Usage:
111
+ * wfa.dataPill(params.trigger.current.active, 'boolean')
112
+ * wfa.dataPill(params.flowVariables.userName, 'string')
113
+ * wfa.dataPill(actionInstance.output, 'reference')
114
+ *
115
+ * The first argument is the PropertyAccessExpression to the data source.
116
+ * The second argument is the data type string.
117
+ */
118
+ export const WfaDataPillPlugin = Plugin.create({
119
+ name: 'WfaDataPillPlugin',
120
+ nodes: [
121
+ {
122
+ node: 'CallExpression',
123
+ fileTypes: ['fluent'],
124
+ async toShape(node, { diagnostics, transform }): Promise<Result<Shape>> {
125
+ const callee = getCallExpressionName(node)
126
+
127
+ // Only handle wfa.dataPill() calls
128
+ if (callee !== DATAPILL_CALLEE) {
129
+ return { success: false }
130
+ }
131
+
132
+ // Validate wfa.dataPill is inside a Flow or Subflow call expression
133
+ const ancestorFlowOrSubflow = findAncestorByCalleeName(node, 'Flow', 'Subflow')
134
+ if (!ancestorFlowOrSubflow) {
135
+ diagnostics.error(node, 'wfa.dataPill() cannot be used outside of a Flow or Subflow context.')
136
+ return { success: false }
137
+ }
138
+
139
+ // TODO: This is not working, Even though the debug point is hitting this but not printing the error for some reason, need to fix from core team.
140
+ // This will be gone once the toSubclass node -> toShape is refactored to toSubclass() with story ref. STRY62776143
141
+ const ancestorDuration = findAncestorByCalleeName(node, 'Duration')
142
+ if (ancestorDuration) {
143
+ diagnostics.error(node, 'wfa.dataPill() cannot be used inside a Duration().')
144
+ return { success: false }
145
+ }
146
+
147
+ const args = node.getArguments()
148
+
149
+ let expressionArg = args[0]
150
+ const typeArg = args[1]
151
+
152
+ if (!expressionArg) {
153
+ diagnostics.error(node, 'wfa.dataPill: missing required expression argument')
154
+ return { success: false }
155
+ }
156
+
157
+ // Check if this pill is used in forEach items argument (computed once, reused throughout)
158
+ const isForEachItems = isForEachItemsArgument(node)
159
+
160
+ // Check for type assertions (as any, as string, etc.) in forEach items argument ONLY
161
+ if (ts.Node.isAsExpression(expressionArg)) {
162
+ if (isForEachItems) {
163
+ diagnostics.error(
164
+ expressionArg,
165
+ 'wfa.dataPill: Type assertions (e.g., "as any") are not allowed in forEach items argument.'
166
+ )
167
+ return { success: false }
168
+ }
169
+ // For non-forEach uses, unwrap the type assertion to get the underlying expression
170
+ expressionArg = expressionArg.getExpression()
171
+ }
172
+
173
+ // Validate first argument is a property access expression or identifier
174
+ if (
175
+ !ts.Node.isPropertyAccessExpression(expressionArg) &&
176
+ !ts.Node.isIdentifier(expressionArg) // In ForEach scneario we get identifier like "item"
177
+ ) {
178
+ diagnostics.error(
179
+ expressionArg,
180
+ 'wfa.dataPill: first argument must be a property access expression (e.g., params.trigger.current.active)'
181
+ )
182
+ return { success: false }
183
+ }
184
+
185
+ // Convert the expression argument to a shape first
186
+ const shapeResult = await transform.toShape(expressionArg, BasicSyntaxPlugin, DataPillPlugin)
187
+ if (shapeResult.success) {
188
+ if (shapeResult.value instanceof PillShape || shapeResult.value instanceof ForEachItemShape) {
189
+ shapeResult.value.setType((typeArg as ts.StringLiteral).getLiteralValue())
190
+
191
+ // Only extract and set metadata if this pill is the items argument of forEach
192
+ if (isForEachItems) {
193
+ const metadata = extractMetadataFromType(expressionArg)
194
+ if (metadata.parentTableName) {
195
+ shapeResult.value.setParentTableName(metadata.parentTableName)
196
+ }
197
+ if (metadata.columnName) {
198
+ shapeResult.value.setColumnName(metadata.columnName)
199
+ }
200
+ if (metadata.reference) {
201
+ shapeResult.value.setReference(metadata.reference)
202
+ }
203
+ }
204
+ return { success: true, value: shapeResult.value }
205
+ }
206
+ }
207
+ diagnostics.error(expressionArg, 'wfa.dataPill: failed to resolve expression or type')
208
+ return { success: false }
209
+ },
210
+ },
211
+ ],
212
+ shapes: [],
213
+ })
@@ -0,0 +1,298 @@
1
+ /**
2
+ * Utility functions to convert between JSON and string formats for Approval Rules
3
+ */
4
+ import { APPROVAL_ACTION_TYPE_APPROVE_VALUE, APPROVAL_ACTION_TYPES } from './flow-constants'
5
+ import type {
6
+ ApprovalConditionRuleType,
7
+ ApprovalRuleActionType,
8
+ ApprovalRuleConditionType,
9
+ ApprovalRuleSetType,
10
+ ApprovalRulesType,
11
+ } from '@servicenow/sdk-core/runtime/flow'
12
+
13
+ /**
14
+ * Converts Approval Rules JSON to string representation
15
+ * @param {Object} approvalRules - Approval rules JSON containing ruleSets and conditionType attributes
16
+ * @returns {string} String representation of the Approval Rules
17
+ */
18
+ export function approvalRulesJsonToString(approvalRules: ApprovalRulesType): string {
19
+ const { ruleSets = [] } = approvalRules
20
+ return ruleSetsJsonToString(ruleSets)
21
+ }
22
+
23
+ /**
24
+ * Converts a Rule Sets JSON to its string representation
25
+ * @param {Array} ruleSets - Array of Rule Set objects
26
+ * @returns {string} String representation of the Rule Sets
27
+ */
28
+ function ruleSetsJsonToString(ruleSets: Array<ApprovalRuleSetType>): string {
29
+ if (!ruleSets || !Array.isArray(ruleSets) || ruleSets.length === 0) {
30
+ return APPROVAL_ACTION_TYPE_APPROVE_VALUE
31
+ }
32
+
33
+ //Iterate through the RuleSets and convert each RuleSet JSON to string
34
+ return ruleSets
35
+ .map((ruleSet) => ruleSetJsonToString(ruleSet))
36
+ .filter(Boolean)
37
+ .join('Or') //Rule Sets are connected with 'Or' condition
38
+ }
39
+ /**
40
+ * Converts a Rule Set JSON to its string representation
41
+ * @param {Object} ruleSet - Rule Set object containg action and rules
42
+ * @returns {string} String representation of the Rule Set
43
+ */
44
+ function ruleSetJsonToString(ruleSet: ApprovalRuleSetType): string {
45
+ const { action, rules = [] } = ruleSet
46
+
47
+ //Check if action type is valid
48
+ if (!action || !APPROVAL_ACTION_TYPES.includes(action)) {
49
+ return ''
50
+ }
51
+
52
+ //Check if rules are valid
53
+ if (!rules || !Array.isArray(rules) || rules.length === 0) {
54
+ return action
55
+ }
56
+
57
+ //Iterate over the rules and convert each rule json (contains list of conditions) to string
58
+ const rulesString = rules
59
+ .map((rule) => ruleJSONToString(rule))
60
+ .filter(Boolean)
61
+ .join('&') //Rules are connected with & (AND)
62
+
63
+ return `${action}${rulesString}`
64
+ }
65
+ /**
66
+ * Converts a Rule (contains list of conditions) JSON to its string representation
67
+ * @param {Array} rule - Array of Rule condition objects
68
+ * @returns {string} String representation of the Rule conditions
69
+ */
70
+ function ruleJSONToString(rule: Array<ApprovalRuleConditionType>): string {
71
+ if (!rule || !Array.isArray(rule) || rule.length === 0) {
72
+ return ''
73
+ }
74
+ //Iterate through the rule conditions and convert each rule condition to string
75
+ const ruleString = rule
76
+ .map((ruleCondition) => ruleConditionJSONToString(ruleCondition))
77
+ .filter(Boolean)
78
+ .join('|') //Rule conditions are connected with | (OR)
79
+ return ruleString
80
+ }
81
+
82
+ function ruleConditionJSONToString(ruleCondition: ApprovalRuleConditionType): string {
83
+ if (!ruleCondition || Object.keys(ruleCondition).length === 0) {
84
+ return ''
85
+ }
86
+ let result = ''
87
+
88
+ // Handle Count and Percent
89
+ if (ruleCondition.ruleType === 'Count' && ruleCondition.count !== undefined) {
90
+ result = `${ruleCondition.count}#`
91
+ } else if (ruleCondition.ruleType === 'Percent' && ruleCondition.percent !== undefined) {
92
+ result = `${ruleCondition.percent}%`
93
+ } else {
94
+ // Add rule type
95
+ result = ruleCondition.ruleType
96
+ }
97
+
98
+ // Handle manual flag
99
+ if (ruleCondition.manual) {
100
+ result += 'M'
101
+ return result
102
+ }
103
+
104
+ // Add users if present
105
+ if (ruleCondition.users && ruleCondition.users.length > 0) {
106
+ result += `U[${ruleCondition.users
107
+ .map((user) => {
108
+ const trimmed = String(user).trim()
109
+ // Check if user is already a data pill format (e.g., {{trigger.current.manager.city|string}})
110
+ const match = trimmed.match(/^\{\{(.*)\}\}$/)
111
+ if (match) {
112
+ return trimmed
113
+ }
114
+ return `{{static.${user}}}`
115
+ })
116
+ .join(',')}]`
117
+ }
118
+
119
+ // Add groups if present
120
+ if (ruleCondition.groups && ruleCondition.groups.length > 0) {
121
+ result += `G[${ruleCondition.groups
122
+ .map((group) => {
123
+ const trimmed = String(group).trim()
124
+ // Check if group is already a data pill format (e.g., {{trigger.current.group_ref|string}})
125
+ const match = trimmed.match(/^\{\{(.*)\}\}$/)
126
+ if (match) {
127
+ return trimmed
128
+ }
129
+ return `{{static.${group}}}`
130
+ })
131
+ .join(',')}]`
132
+ }
133
+
134
+ return result
135
+ }
136
+
137
+ /**
138
+ * Converts Approval Rules string to JSON representation
139
+ * @param {string} ruleSetsString - String representation of the Approval Rules
140
+ * @returns {Object} Approval rules JSON containing ruleSets and conditionType attributes
141
+ */
142
+ export function approvalRulesStringToJson(ruleSetsString: string): ApprovalRulesType {
143
+ const EMPTY_RULE_SETS_JSON: ApprovalRulesType = {
144
+ conditionType: 'OR',
145
+ ruleSets: [],
146
+ }
147
+
148
+ if (!ruleSetsString || ruleSetsString.length === 0) {
149
+ return EMPTY_RULE_SETS_JSON
150
+ }
151
+
152
+ // 1. Split by 'Or' to get individual Rule Sets
153
+ // 2. Iterate through the Rule Sets and convert each Rule Set string to JSON
154
+ const ruleSetsJson = ruleSetsString.split('Or').map((ruleSetString) => ruleSetStringToJson(ruleSetString))
155
+ return {
156
+ ...EMPTY_RULE_SETS_JSON,
157
+ ruleSets: ruleSetsJson,
158
+ }
159
+ }
160
+ /**
161
+ * Converts a Rule Set string to its JSON representation
162
+ * @param {string} ruleSetString - Rule Set string
163
+ * @returns {Array} JSON representation of the Rule Set
164
+ */
165
+ function ruleSetStringToJson(ruleSetString: string): ApprovalRuleSetType {
166
+ const EMPTY_RULE_SET_JSON: ApprovalRuleSetType = {
167
+ action: 'Approves',
168
+ conditionType: 'AND',
169
+ rules: [],
170
+ }
171
+
172
+ if (!ruleSetString || ruleSetString.length === 0) {
173
+ return EMPTY_RULE_SET_JSON
174
+ }
175
+
176
+ // Extract action (Approves, Rejects, ApprovesRejects)
177
+ const actionRegex = /^(ApprovesRejects|Approves|Rejects)/
178
+ const actionMatch = ruleSetString.match(actionRegex)
179
+ if (!actionMatch) {
180
+ return EMPTY_RULE_SET_JSON
181
+ }
182
+
183
+ const action = actionMatch[0] as ApprovalRuleActionType
184
+
185
+ // If the string is just the action name, return an empty rule set
186
+ if (ruleSetString === action) {
187
+ return { ...EMPTY_RULE_SET_JSON, action }
188
+ }
189
+
190
+ // Remove action from the Rule Set string and extract the rules string
191
+ const rulesString = ruleSetString.substring(action.length)
192
+
193
+ // Split rules by & to get individual rules within the Rule Set
194
+ const rulesRegex = /[&]/g
195
+
196
+ //Iterate through the rules and convert each rule string to JSON
197
+ const rulesJson = rulesString
198
+ .split(rulesRegex)
199
+ .map((ruleString) => ruleStringToJson(ruleString))
200
+ .filter(Boolean)
201
+
202
+ return { ...EMPTY_RULE_SET_JSON, action, rules: rulesJson }
203
+ }
204
+
205
+ /**
206
+ * Converts a Rule string to its JSON representation
207
+ * @param {string} ruleString - Rule string
208
+ * @returns {Array} JSON representation of the Rule
209
+ */
210
+ function ruleStringToJson(ruleString: string): Array<ApprovalRuleConditionType> {
211
+ if (!ruleString || ruleString.length === 0) {
212
+ return []
213
+ }
214
+ const ruleConditionsRegex = /[|]/g
215
+ const ruleConditionStrings: string[] = []
216
+
217
+ ruleString.split(ruleConditionsRegex).forEach((ruleConditionString) => {
218
+ ruleConditionStrings.push(ruleConditionString)
219
+ })
220
+ return ruleConditionStrings
221
+ .map((ruleConditionString) => ruleConditionStringToJson(ruleConditionString))
222
+ .filter((ruleConditionJson): ruleConditionJson is ApprovalRuleConditionType => ruleConditionJson !== undefined)
223
+ }
224
+
225
+ /**
226
+ * Converts a Rule Condition string to its JSON representation
227
+ * @param {string} ruleConditionString - Rule Condition string
228
+ * @returns {Object} JSON representation of the Rule Condition
229
+ */
230
+ function ruleConditionStringToJson(ruleConditionString: string): ApprovalRuleConditionType | undefined {
231
+ if (!ruleConditionString || ruleConditionString.length === 0) {
232
+ return undefined
233
+ }
234
+ const ruleConditionJson: ApprovalRuleConditionType = {
235
+ ruleType: 'Any',
236
+ users: [],
237
+ groups: [],
238
+ manual: false,
239
+ }
240
+
241
+ // Check if manual
242
+ const hasManual = ruleConditionString.includes('M')
243
+ if (hasManual) {
244
+ ruleConditionJson.manual = true
245
+ }
246
+
247
+ // Check for Count or Percent
248
+ const countMatch = ruleConditionString.match(/(\d+)#/)
249
+ const percentMatch = ruleConditionString.match(/(\d+)%/)
250
+
251
+ if (countMatch?.[1]) {
252
+ ruleConditionJson.ruleType = 'Count'
253
+ ruleConditionJson['count'] = parseInt(countMatch[1], 10)
254
+ } else if (percentMatch?.[1]) {
255
+ ruleConditionJson.ruleType = 'Percent'
256
+ ruleConditionJson['percent'] = parseInt(percentMatch[1], 10)
257
+ } else {
258
+ // Extract rule type (Any, All, Res)
259
+ const ruleTypeMatch = ruleConditionString.match(/(Any|All|Res)/)
260
+ if (ruleTypeMatch) {
261
+ ruleConditionJson.ruleType = ruleTypeMatch[0] as ApprovalConditionRuleType
262
+ }
263
+ }
264
+ ruleConditionJson.users = getUsersJson(ruleConditionString)
265
+ ruleConditionJson.groups = getGroupsJson(ruleConditionString)
266
+
267
+ return ruleConditionJson
268
+ }
269
+
270
+ function getUsersJson(ruleConditionString: string) {
271
+ if (ruleConditionString && ruleConditionString.length > 0) {
272
+ // Extract users
273
+ const usersMatch = ruleConditionString.match(/U\[(.*?)\]/)
274
+ if (usersMatch?.[1]) {
275
+ const usersString = usersMatch[1]
276
+ return usersString
277
+ .split(',')
278
+ .map((user) => user.replace(/{{static\.(.*?)}}/, '$1').trim())
279
+ .filter(Boolean)
280
+ }
281
+ }
282
+ return []
283
+ }
284
+
285
+ function getGroupsJson(ruleConditionString: string) {
286
+ if (ruleConditionString && ruleConditionString.length > 0) {
287
+ // Extract groups
288
+ const groupsMatch = ruleConditionString.match(/G\[(.*?)\]/)
289
+ if (groupsMatch?.[1]) {
290
+ const groupsString = groupsMatch[1]
291
+ return groupsString
292
+ .split(',')
293
+ .map((group) => group.replace(/{{static\.(.*?)}}/, '$1').trim())
294
+ .filter(Boolean)
295
+ }
296
+ }
297
+ return []
298
+ }
@@ -0,0 +1,81 @@
1
+ /**
2
+ * Built-in complex objects that are available globally in Flow Designer.
3
+ * These are referenced by flows but may not be present in the user's project metadata.
4
+ */
5
+
6
+ interface BuiltInComplexObject {
7
+ $id: string
8
+ table: 'sys_complex_object'
9
+ data: {
10
+ name: string
11
+ namespace: string
12
+ scope_name?: string
13
+ serialized_content: string
14
+ sys_domain: string
15
+ sys_policy?: string
16
+ type: string
17
+ }
18
+ }
19
+
20
+ const FDChangeDetails: BuiltInComplexObject = {
21
+ $id: '239e04950f023300ecf0cc52ff767e0c',
22
+ table: 'sys_complex_object',
23
+ data: {
24
+ name: 'FDChangeDetails',
25
+ namespace: 'FlowDesigner',
26
+ scope_name: 'global',
27
+ serialized_content:
28
+ '{"FlowDesigner:FDChangeDetails":{"previous_display_value":"String","previous_display_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Previous Display Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"4\\",\\"max_length\\":\\"0\\"}"},"previous_value":"String","previous_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Previous Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"2\\",\\"max_length\\":\\"0\\"}"},"current_display_value":"String","current_display_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Current Display Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"5\\",\\"max_length\\":\\"0\\"}"},"current_value":"String","current_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Current Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"3\\",\\"max_length\\":\\"0\\"}"},"field_name":"String","field_name.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Field Name\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"1\\",\\"max_length\\":\\"0\\"}"}},"FlowDesigner:FDChangeDetails.$type_facets":{"SimpleMapFacet":"{\\"read_only_complex_object\\":\\"true\\",\\"pwd2droppable\\":\\"true\\",\\"default_value\\":\\"\\",\\"label\\":\\"Changed Fields\\",\\"mandatory\\":\\"false\\",\\"child_name\\":\\"FDChangeDetails\\",\\"uiTypeLabel\\":\\"Array.Object\\",\\"co_type_name\\":\\"FDCollection\\",\\"child_label\\":\\"FDChangeDetails\\",\\"child_type_label\\":\\"Object\\",\\"element_mapping_provider\\":\\"com.glide.flow_design.action.data.FlowDesignVariableMapper\\",\\"read_only\\":\\"false\\",\\"hint\\":null,\\"uiType\\":\\"array.object\\",\\"child_type\\":\\"object\\",\\"order\\":\\"1\\",\\"max_length\\":\\"8000\\"}"}}',
29
+ sys_domain: 'global',
30
+ type: 'complex_object_schema',
31
+ },
32
+ }
33
+
34
+ const FDSTEPSTATUS: BuiltInComplexObject = {
35
+ $id: '73720df26f312010bf408271145b3600',
36
+ table: 'sys_complex_object',
37
+ data: {
38
+ name: 'FDSTEPSTATUS',
39
+ namespace: 'FlowDesigner',
40
+ scope_name: 'global',
41
+ serialized_content:
42
+ '{"FlowDesigner:FDSTEPSTATUS":{"code":"Integer","code.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"Integer\\",\\"read_only\\":\\"false\\",\\"hint\\":null,\\"uiType\\":\\"integer\\",\\"default_value\\":\\"\\",\\"label\\":\\"Code\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"1\\",\\"max_length\\":\\"40\\"}"},"message":"String","message.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":null,\\"uiType\\":\\"string\\",\\"default_value\\":null,\\"label\\":\\"Message\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"2\\",\\"max_length\\":\\"4000\\"}"}},"FlowDesigner:FDSTEPSTATUS.$type_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"Object\\",\\"co_type_name\\":\\"FDSTEPSTATUS\\",\\"read_only\\":\\"false\\",\\"hint\\":null,\\"uiType\\":\\"object\\",\\"default_value\\":\\"\\",\\"label\\":\\"Step Status\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"1\\",\\"max_length\\":\\"0\\"}"}}',
43
+ sys_domain: 'global',
44
+ type: 'complex_object_schema',
45
+ },
46
+ }
47
+
48
+ const FDACTIONSTATUS: BuiltInComplexObject = {
49
+ $id: 'b91cc65087022010226ca1bb36cb0be4',
50
+ table: 'sys_complex_object',
51
+ data: {
52
+ name: 'FDACTIONSTATUS',
53
+ namespace: 'FlowDesigner',
54
+ serialized_content:
55
+ '{"FlowDesigner:FDACTIONSTATUS":{"code":"Integer","code.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"Integer\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"integer\\",\\"default_value\\":\\"\\",\\"label\\":\\"Code\\",\\"action_error_output\\":\\"true\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"1\\",\\"max_length\\":\\"40\\"}"},"message":"String","message.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Message\\",\\"action_error_output\\":\\"true\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"2\\",\\"max_length\\":\\"4000\\"}"}},"FlowDesigner:FDACTIONSTATUS.$type_facets":{"SimpleMapFacet":"{\\"default_value\\":\\"\\",\\"label\\":\\"Action Status\\",\\"action_error_output\\":\\"true\\",\\"mandatory\\":\\"false\\",\\"uiUniqueId\\":\\"4adfb7bc-9d67-498d-88d0-8d6c3d584fed\\",\\"uiTypeLabel\\":\\"Object\\",\\"co_type_name\\":\\"FDACTIONSTATUS\\",\\"element_mapping_provider\\":\\"com.glide.flow_design.action.data.FlowDesignVariableMapper\\",\\"read_only\\":\\"false\\",\\"hint\\":null,\\"uiType\\":\\"object\\",\\"order\\":\\"1\\",\\"max_length\\":\\"65000\\"}"}}',
56
+ sys_domain: 'global',
57
+ sys_policy: 'read',
58
+ type: 'complex_object_schema',
59
+ },
60
+ }
61
+
62
+ const FDCollection: BuiltInComplexObject = {
63
+ $id: 'f4f014150f023300ecf0cc52ff767eed',
64
+ table: 'sys_complex_object',
65
+ data: {
66
+ name: 'FDCollection',
67
+ namespace: 'FlowDesigner',
68
+ scope_name: 'global',
69
+ serialized_content:
70
+ '{"FlowDesigner:FDCollection":{"$COCollectionField":[{"FDChangeDetails":{"previous_display_value":"String","previous_display_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Previous Display Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"4\\",\\"max_length\\":\\"0\\"}"},"previous_value":"String","previous_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Previous Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"2\\",\\"max_length\\":\\"0\\"}"},"current_display_value":"String","current_display_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Current Display Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"5\\",\\"max_length\\":\\"0\\"}"},"current_value":"String","current_value.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Current Value\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"3\\",\\"max_length\\":\\"0\\"}"},"field_name":"String","field_name.$field_facets":{"SimpleMapFacet":"{\\"uiTypeLabel\\":\\"String\\",\\"read_only\\":\\"false\\",\\"hint\\":\\"\\",\\"uiType\\":\\"string\\",\\"default_value\\":\\"\\",\\"label\\":\\"Field Name\\",\\"mandatory\\":\\"false\\",\\"order\\":\\"1\\",\\"max_length\\":\\"0\\"}"}}}],"$COCollectionField.$type_facets":{"SimpleMapFacet":"{\\"pwd2droppable\\":\\"true\\",\\"default_value\\":\\"\\",\\"label\\":\\"Changed Fields\\",\\"mandatory\\":\\"false\\",\\"child_name\\":\\"FDChangeDetails\\",\\"uiTypeLabel\\":\\"Array.Object\\",\\"co_type_name\\":\\"FDCollection\\",\\"child_label\\":\\"FDChangeDetails\\",\\"child_type_label\\":\\"Object\\",\\"element_mapping_provider\\":\\"com.glide.flow_design.action.data.FlowDesignVariableMapper\\",\\"read_only\\":\\"false\\",\\"hint\\":null,\\"uiType\\":\\"array.object\\",\\"child_type\\":\\"object\\",\\"order\\":\\"1\\",\\"max_length\\":\\"8000\\"}"},"$COCollectionField.$field_facets":{"SimpleMapFacet":"{\\"up-shift-collection-level\\":\\"true\\"}"}},"FlowDesigner:FDCollection.$type_facets":{"SimpleMapFacet":"{\\"pwd2droppable\\":\\"true\\",\\"default_value\\":\\"\\",\\"label\\":\\"Changed Fields\\",\\"mandatory\\":\\"false\\",\\"child_name\\":\\"FDChangeDetails\\",\\"uiTypeLabel\\":\\"Array.Object\\",\\"co_type_name\\":\\"FDCollection\\",\\"child_label\\":\\"FDChangeDetails\\",\\"child_type_label\\":\\"Object\\",\\"element_mapping_provider\\":\\"com.glide.flow_design.action.data.FlowDesignVariableMapper\\",\\"read_only\\":\\"false\\",\\"hint\\":null,\\"uiType\\":\\"array.object\\",\\"child_type\\":\\"object\\",\\"order\\":\\"1\\",\\"max_length\\":\\"8000\\"}"}}',
71
+ sys_domain: 'global',
72
+ type: 'complex_object_collection',
73
+ },
74
+ }
75
+
76
+ export const builtInComplexObjects: Record<string, BuiltInComplexObject> = {
77
+ FDChangeDetails,
78
+ FDSTEPSTATUS,
79
+ FDACTIONSTATUS,
80
+ FDCollection,
81
+ }