@endora-commerce/mod-catalog 0.100.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 (443) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +63 -0
  3. package/dist/admin/components/PackagingUnitsEditor.d.ts +12 -0
  4. package/dist/admin/components/PackagingUnitsEditor.d.ts.map +1 -0
  5. package/dist/admin/components/PackagingUnitsEditor.js +99 -0
  6. package/dist/admin/components/PackagingUnitsEditor.js.map +1 -0
  7. package/dist/admin/components/ProductAttributesTab.d.ts +13 -0
  8. package/dist/admin/components/ProductAttributesTab.d.ts.map +1 -0
  9. package/dist/admin/components/ProductAttributesTab.js +140 -0
  10. package/dist/admin/components/ProductAttributesTab.js.map +1 -0
  11. package/dist/admin/components/ProductInventoryTab.d.ts +14 -0
  12. package/dist/admin/components/ProductInventoryTab.d.ts.map +1 -0
  13. package/dist/admin/components/ProductInventoryTab.js +284 -0
  14. package/dist/admin/components/ProductInventoryTab.js.map +1 -0
  15. package/dist/admin/components/ProductScopeEditor.d.ts +94 -0
  16. package/dist/admin/components/ProductScopeEditor.d.ts.map +1 -0
  17. package/dist/admin/components/ProductScopeEditor.js +395 -0
  18. package/dist/admin/components/ProductScopeEditor.js.map +1 -0
  19. package/dist/admin/components/ProductsBulkEditDialog.d.ts +11 -0
  20. package/dist/admin/components/ProductsBulkEditDialog.d.ts.map +1 -0
  21. package/dist/admin/components/ProductsBulkEditDialog.js +304 -0
  22. package/dist/admin/components/ProductsBulkEditDialog.js.map +1 -0
  23. package/dist/admin/index.d.ts +45 -0
  24. package/dist/admin/index.d.ts.map +1 -0
  25. package/dist/admin/index.js +184 -0
  26. package/dist/admin/index.js.map +1 -0
  27. package/dist/admin/lib/resolve-product-selection.d.ts +21 -0
  28. package/dist/admin/lib/resolve-product-selection.d.ts.map +1 -0
  29. package/dist/admin/lib/resolve-product-selection.js +25 -0
  30. package/dist/admin/lib/resolve-product-selection.js.map +1 -0
  31. package/dist/admin/pages/AttachmentTypesPage.d.ts +18 -0
  32. package/dist/admin/pages/AttachmentTypesPage.d.ts.map +1 -0
  33. package/dist/admin/pages/AttachmentTypesPage.js +92 -0
  34. package/dist/admin/pages/AttachmentTypesPage.js.map +1 -0
  35. package/dist/admin/pages/AttributeSetsPage.d.ts +21 -0
  36. package/dist/admin/pages/AttributeSetsPage.d.ts.map +1 -0
  37. package/dist/admin/pages/AttributeSetsPage.js +158 -0
  38. package/dist/admin/pages/AttributeSetsPage.js.map +1 -0
  39. package/dist/admin/pages/AttributesManager.d.ts +9 -0
  40. package/dist/admin/pages/AttributesManager.d.ts.map +1 -0
  41. package/dist/admin/pages/AttributesManager.js +305 -0
  42. package/dist/admin/pages/AttributesManager.js.map +1 -0
  43. package/dist/admin/pages/BulkOperationDetailPage.d.ts +9 -0
  44. package/dist/admin/pages/BulkOperationDetailPage.d.ts.map +1 -0
  45. package/dist/admin/pages/BulkOperationDetailPage.js +187 -0
  46. package/dist/admin/pages/BulkOperationDetailPage.js.map +1 -0
  47. package/dist/admin/pages/BulkOperationsPage.d.ts +9 -0
  48. package/dist/admin/pages/BulkOperationsPage.d.ts.map +1 -0
  49. package/dist/admin/pages/BulkOperationsPage.js +98 -0
  50. package/dist/admin/pages/BulkOperationsPage.js.map +1 -0
  51. package/dist/admin/pages/CategoriesTree.d.ts +9 -0
  52. package/dist/admin/pages/CategoriesTree.d.ts.map +1 -0
  53. package/dist/admin/pages/CategoriesTree.js +176 -0
  54. package/dist/admin/pages/CategoriesTree.js.map +1 -0
  55. package/dist/admin/pages/ProductEditor.d.ts +13 -0
  56. package/dist/admin/pages/ProductEditor.d.ts.map +1 -0
  57. package/dist/admin/pages/ProductEditor.js +1050 -0
  58. package/dist/admin/pages/ProductEditor.js.map +1 -0
  59. package/dist/admin/pages/ProductsList.d.ts +9 -0
  60. package/dist/admin/pages/ProductsList.d.ts.map +1 -0
  61. package/dist/admin/pages/ProductsList.js +399 -0
  62. package/dist/admin/pages/ProductsList.js.map +1 -0
  63. package/dist/backend/commands/attribute-commands.d.ts +111 -0
  64. package/dist/backend/commands/attribute-commands.d.ts.map +1 -0
  65. package/dist/backend/commands/attribute-commands.js +482 -0
  66. package/dist/backend/commands/attribute-commands.js.map +1 -0
  67. package/dist/backend/demo/reset.d.ts +23 -0
  68. package/dist/backend/demo/reset.d.ts.map +1 -0
  69. package/dist/backend/demo/reset.js +41 -0
  70. package/dist/backend/demo/reset.js.map +1 -0
  71. package/dist/backend/demo/rows.d.ts +103 -0
  72. package/dist/backend/demo/rows.d.ts.map +1 -0
  73. package/dist/backend/demo/rows.js +162 -0
  74. package/dist/backend/demo/rows.js.map +1 -0
  75. package/dist/backend/demo/seed.d.ts +35 -0
  76. package/dist/backend/demo/seed.d.ts.map +1 -0
  77. package/dist/backend/demo/seed.js +177 -0
  78. package/dist/backend/demo/seed.js.map +1 -0
  79. package/dist/backend/entities/attachment-type.entity.d.ts +16 -0
  80. package/dist/backend/entities/attachment-type.entity.d.ts.map +1 -0
  81. package/dist/backend/entities/attachment-type.entity.js +57 -0
  82. package/dist/backend/entities/attachment-type.entity.js.map +1 -0
  83. package/dist/backend/entities/attribute-set-attribute.entity.d.ts +26 -0
  84. package/dist/backend/entities/attribute-set-attribute.entity.d.ts.map +1 -0
  85. package/dist/backend/entities/attribute-set-attribute.entity.js +55 -0
  86. package/dist/backend/entities/attribute-set-attribute.entity.js.map +1 -0
  87. package/dist/backend/entities/attribute-set.entity.d.ts +22 -0
  88. package/dist/backend/entities/attribute-set.entity.d.ts.map +1 -0
  89. package/dist/backend/entities/attribute-set.entity.js +67 -0
  90. package/dist/backend/entities/attribute-set.entity.js.map +1 -0
  91. package/dist/backend/entities/bulk-operation.entity.d.ts +78 -0
  92. package/dist/backend/entities/bulk-operation.entity.d.ts.map +1 -0
  93. package/dist/backend/entities/bulk-operation.entity.js +138 -0
  94. package/dist/backend/entities/bulk-operation.entity.js.map +1 -0
  95. package/dist/backend/entities/bundle-slot-option.entity.d.ts +23 -0
  96. package/dist/backend/entities/bundle-slot-option.entity.d.ts.map +1 -0
  97. package/dist/backend/entities/bundle-slot-option.entity.js +68 -0
  98. package/dist/backend/entities/bundle-slot-option.entity.js.map +1 -0
  99. package/dist/backend/entities/bundle-slot.entity.d.ts +25 -0
  100. package/dist/backend/entities/bundle-slot.entity.d.ts.map +1 -0
  101. package/dist/backend/entities/bundle-slot.entity.js +74 -0
  102. package/dist/backend/entities/bundle-slot.entity.js.map +1 -0
  103. package/dist/backend/entities/category.entity.d.ts +26 -0
  104. package/dist/backend/entities/category.entity.d.ts.map +1 -0
  105. package/dist/backend/entities/category.entity.js +119 -0
  106. package/dist/backend/entities/category.entity.js.map +1 -0
  107. package/dist/backend/entities/gallery-item-label.entity.d.ts +22 -0
  108. package/dist/backend/entities/gallery-item-label.entity.d.ts.map +1 -0
  109. package/dist/backend/entities/gallery-item-label.entity.js +50 -0
  110. package/dist/backend/entities/gallery-item-label.entity.js.map +1 -0
  111. package/dist/backend/entities/gallery-item.entity.d.ts +17 -0
  112. package/dist/backend/entities/gallery-item.entity.d.ts.map +1 -0
  113. package/dist/backend/entities/gallery-item.entity.js +58 -0
  114. package/dist/backend/entities/gallery-item.entity.js.map +1 -0
  115. package/dist/backend/entities/grouped-item.entity.d.ts +23 -0
  116. package/dist/backend/entities/grouped-item.entity.d.ts.map +1 -0
  117. package/dist/backend/entities/grouped-item.entity.js +68 -0
  118. package/dist/backend/entities/grouped-item.entity.js.map +1 -0
  119. package/dist/backend/entities/product-attachment.entity.d.ts +23 -0
  120. package/dist/backend/entities/product-attachment.entity.d.ts.map +1 -0
  121. package/dist/backend/entities/product-attachment.entity.js +77 -0
  122. package/dist/backend/entities/product-attachment.entity.js.map +1 -0
  123. package/dist/backend/entities/product-attribute.entity.d.ts +72 -0
  124. package/dist/backend/entities/product-attribute.entity.d.ts.map +1 -0
  125. package/dist/backend/entities/product-attribute.entity.js +161 -0
  126. package/dist/backend/entities/product-attribute.entity.js.map +1 -0
  127. package/dist/backend/entities/product-editor-preference.entity.d.ts +28 -0
  128. package/dist/backend/entities/product-editor-preference.entity.d.ts.map +1 -0
  129. package/dist/backend/entities/product-editor-preference.entity.js +63 -0
  130. package/dist/backend/entities/product-editor-preference.entity.js.map +1 -0
  131. package/dist/backend/entities/product-link.entity.d.ts +25 -0
  132. package/dist/backend/entities/product-link.entity.d.ts.map +1 -0
  133. package/dist/backend/entities/product-link.entity.js +70 -0
  134. package/dist/backend/entities/product-link.entity.js.map +1 -0
  135. package/dist/backend/entities/product-packaging-unit.entity.d.ts +26 -0
  136. package/dist/backend/entities/product-packaging-unit.entity.d.ts.map +1 -0
  137. package/dist/backend/entities/product-packaging-unit.entity.js +76 -0
  138. package/dist/backend/entities/product-packaging-unit.entity.js.map +1 -0
  139. package/dist/backend/entities/product-value-override.entity.d.ts +43 -0
  140. package/dist/backend/entities/product-value-override.entity.d.ts.map +1 -0
  141. package/dist/backend/entities/product-value-override.entity.js +90 -0
  142. package/dist/backend/entities/product-value-override.entity.js.map +1 -0
  143. package/dist/backend/entities/product-variant.entity.d.ts +18 -0
  144. package/dist/backend/entities/product-variant.entity.d.ts.map +1 -0
  145. package/dist/backend/entities/product-variant.entity.js +68 -0
  146. package/dist/backend/entities/product-variant.entity.js.map +1 -0
  147. package/dist/backend/entities/product.entity.d.ts +108 -0
  148. package/dist/backend/entities/product.entity.d.ts.map +1 -0
  149. package/dist/backend/entities/product.entity.js +230 -0
  150. package/dist/backend/entities/product.entity.js.map +1 -0
  151. package/dist/backend/index.d.ts +262 -0
  152. package/dist/backend/index.d.ts.map +1 -0
  153. package/dist/backend/index.js +642 -0
  154. package/dist/backend/index.js.map +1 -0
  155. package/dist/backend/plugin.d.ts +216 -0
  156. package/dist/backend/plugin.d.ts.map +1 -0
  157. package/dist/backend/plugin.js +223 -0
  158. package/dist/backend/plugin.js.map +1 -0
  159. package/dist/backend/prompt-tools.d.ts +47 -0
  160. package/dist/backend/prompt-tools.d.ts.map +1 -0
  161. package/dist/backend/prompt-tools.js +284 -0
  162. package/dist/backend/prompt-tools.js.map +1 -0
  163. package/dist/backend/routes.admin.d.ts +105 -0
  164. package/dist/backend/routes.admin.d.ts.map +1 -0
  165. package/dist/backend/routes.admin.js +1162 -0
  166. package/dist/backend/routes.admin.js.map +1 -0
  167. package/dist/backend/routes.api-key.d.ts +33 -0
  168. package/dist/backend/routes.api-key.d.ts.map +1 -0
  169. package/dist/backend/routes.api-key.js +43 -0
  170. package/dist/backend/routes.api-key.js.map +1 -0
  171. package/dist/backend/routes.external.d.ts +32 -0
  172. package/dist/backend/routes.external.d.ts.map +1 -0
  173. package/dist/backend/routes.external.js +115 -0
  174. package/dist/backend/routes.external.js.map +1 -0
  175. package/dist/backend/routes.public.d.ts +46 -0
  176. package/dist/backend/routes.public.d.ts.map +1 -0
  177. package/dist/backend/routes.public.js +318 -0
  178. package/dist/backend/routes.public.js.map +1 -0
  179. package/dist/backend/services/asset-references.d.ts +4 -0
  180. package/dist/backend/services/asset-references.d.ts.map +1 -0
  181. package/dist/backend/services/asset-references.js +104 -0
  182. package/dist/backend/services/asset-references.js.map +1 -0
  183. package/dist/backend/services/attachment.service.d.ts +45 -0
  184. package/dist/backend/services/attachment.service.d.ts.map +1 -0
  185. package/dist/backend/services/attachment.service.js +268 -0
  186. package/dist/backend/services/attachment.service.js.map +1 -0
  187. package/dist/backend/services/attribute-option-validator.d.ts +47 -0
  188. package/dist/backend/services/attribute-option-validator.d.ts.map +1 -0
  189. package/dist/backend/services/attribute-option-validator.js +69 -0
  190. package/dist/backend/services/attribute-option-validator.js.map +1 -0
  191. package/dist/backend/services/attribute-set-validations.d.ts +65 -0
  192. package/dist/backend/services/attribute-set-validations.d.ts.map +1 -0
  193. package/dist/backend/services/attribute-set-validations.js +89 -0
  194. package/dist/backend/services/attribute-set-validations.js.map +1 -0
  195. package/dist/backend/services/attribute-set.service.d.ts +50 -0
  196. package/dist/backend/services/attribute-set.service.d.ts.map +1 -0
  197. package/dist/backend/services/attribute-set.service.js +401 -0
  198. package/dist/backend/services/attribute-set.service.js.map +1 -0
  199. package/dist/backend/services/attribute-type-mapping.d.ts +66 -0
  200. package/dist/backend/services/attribute-type-mapping.d.ts.map +1 -0
  201. package/dist/backend/services/attribute-type-mapping.js +121 -0
  202. package/dist/backend/services/attribute-type-mapping.js.map +1 -0
  203. package/dist/backend/services/attribute-value-key.service.d.ts +48 -0
  204. package/dist/backend/services/attribute-value-key.service.d.ts.map +1 -0
  205. package/dist/backend/services/attribute-value-key.service.js +118 -0
  206. package/dist/backend/services/attribute-value-key.service.js.map +1 -0
  207. package/dist/backend/services/audit-references.d.ts +13 -0
  208. package/dist/backend/services/audit-references.d.ts.map +1 -0
  209. package/dist/backend/services/audit-references.js +51 -0
  210. package/dist/backend/services/audit-references.js.map +1 -0
  211. package/dist/backend/services/bulk-operation-queue.d.ts +26 -0
  212. package/dist/backend/services/bulk-operation-queue.d.ts.map +1 -0
  213. package/dist/backend/services/bulk-operation-queue.js +34 -0
  214. package/dist/backend/services/bulk-operation-queue.js.map +1 -0
  215. package/dist/backend/services/bulk-operation.service.d.ts +195 -0
  216. package/dist/backend/services/bulk-operation.service.d.ts.map +1 -0
  217. package/dist/backend/services/bulk-operation.service.js +510 -0
  218. package/dist/backend/services/bulk-operation.service.js.map +1 -0
  219. package/dist/backend/services/bundle.service.d.ts +87 -0
  220. package/dist/backend/services/bundle.service.d.ts.map +1 -0
  221. package/dist/backend/services/bundle.service.js +286 -0
  222. package/dist/backend/services/bundle.service.js.map +1 -0
  223. package/dist/backend/services/catalog-admin.service.d.ts +398 -0
  224. package/dist/backend/services/catalog-admin.service.d.ts.map +1 -0
  225. package/dist/backend/services/catalog-admin.service.js +1516 -0
  226. package/dist/backend/services/catalog-admin.service.js.map +1 -0
  227. package/dist/backend/services/catalog-attribute-read.service.d.ts +78 -0
  228. package/dist/backend/services/catalog-attribute-read.service.d.ts.map +1 -0
  229. package/dist/backend/services/catalog-attribute-read.service.js +216 -0
  230. package/dist/backend/services/catalog-attribute-read.service.js.map +1 -0
  231. package/dist/backend/services/catalog-bulk-import.service.d.ts +30 -0
  232. package/dist/backend/services/catalog-bulk-import.service.d.ts.map +1 -0
  233. package/dist/backend/services/catalog-bulk-import.service.js +136 -0
  234. package/dist/backend/services/catalog-bulk-import.service.js.map +1 -0
  235. package/dist/backend/services/catalog-bulk-update.service.d.ts +91 -0
  236. package/dist/backend/services/catalog-bulk-update.service.d.ts.map +1 -0
  237. package/dist/backend/services/catalog-bulk-update.service.js +330 -0
  238. package/dist/backend/services/catalog-bulk-update.service.js.map +1 -0
  239. package/dist/backend/services/catalog-category-read.service.d.ts +66 -0
  240. package/dist/backend/services/catalog-category-read.service.d.ts.map +1 -0
  241. package/dist/backend/services/catalog-category-read.service.js +248 -0
  242. package/dist/backend/services/catalog-category-read.service.js.map +1 -0
  243. package/dist/backend/services/catalog-org-price-decorator.d.ts +90 -0
  244. package/dist/backend/services/catalog-org-price-decorator.d.ts.map +1 -0
  245. package/dist/backend/services/catalog-org-price-decorator.js +184 -0
  246. package/dist/backend/services/catalog-org-price-decorator.js.map +1 -0
  247. package/dist/backend/services/catalog-product-filter.service.d.ts +82 -0
  248. package/dist/backend/services/catalog-product-filter.service.d.ts.map +1 -0
  249. package/dist/backend/services/catalog-product-filter.service.js +275 -0
  250. package/dist/backend/services/catalog-product-filter.service.js.map +1 -0
  251. package/dist/backend/services/catalog-product-read.service.d.ts +46 -0
  252. package/dist/backend/services/catalog-product-read.service.d.ts.map +1 -0
  253. package/dist/backend/services/catalog-product-read.service.js +197 -0
  254. package/dist/backend/services/catalog-product-read.service.js.map +1 -0
  255. package/dist/backend/services/catalog-query.service.d.ts +444 -0
  256. package/dist/backend/services/catalog-query.service.d.ts.map +1 -0
  257. package/dist/backend/services/catalog-query.service.js +1633 -0
  258. package/dist/backend/services/catalog-query.service.js.map +1 -0
  259. package/dist/backend/services/catalog-quick-search.service.d.ts +78 -0
  260. package/dist/backend/services/catalog-quick-search.service.d.ts.map +1 -0
  261. package/dist/backend/services/catalog-quick-search.service.js +159 -0
  262. package/dist/backend/services/catalog-quick-search.service.js.map +1 -0
  263. package/dist/backend/services/catalog-write-ports.d.ts +25 -0
  264. package/dist/backend/services/catalog-write-ports.d.ts.map +1 -0
  265. package/dist/backend/services/catalog-write-ports.js +63 -0
  266. package/dist/backend/services/catalog-write-ports.js.map +1 -0
  267. package/dist/backend/services/category-admin.service.d.ts +102 -0
  268. package/dist/backend/services/category-admin.service.d.ts.map +1 -0
  269. package/dist/backend/services/category-admin.service.js +271 -0
  270. package/dist/backend/services/category-admin.service.js.map +1 -0
  271. package/dist/backend/services/gallery.service.d.ts +85 -0
  272. package/dist/backend/services/gallery.service.d.ts.map +1 -0
  273. package/dist/backend/services/gallery.service.js +326 -0
  274. package/dist/backend/services/gallery.service.js.map +1 -0
  275. package/dist/backend/services/grouped.service.d.ts +39 -0
  276. package/dist/backend/services/grouped.service.d.ts.map +1 -0
  277. package/dist/backend/services/grouped.service.js +136 -0
  278. package/dist/backend/services/grouped.service.js.map +1 -0
  279. package/dist/backend/services/label-resolver.d.ts +16 -0
  280. package/dist/backend/services/label-resolver.d.ts.map +1 -0
  281. package/dist/backend/services/label-resolver.js +43 -0
  282. package/dist/backend/services/label-resolver.js.map +1 -0
  283. package/dist/backend/services/packaging-unit.service.d.ts +28 -0
  284. package/dist/backend/services/packaging-unit.service.d.ts.map +1 -0
  285. package/dist/backend/services/packaging-unit.service.js +197 -0
  286. package/dist/backend/services/packaging-unit.service.js.map +1 -0
  287. package/dist/backend/services/primary-asset-url.d.ts +4 -0
  288. package/dist/backend/services/primary-asset-url.d.ts.map +1 -0
  289. package/dist/backend/services/primary-asset-url.js +55 -0
  290. package/dist/backend/services/primary-asset-url.js.map +1 -0
  291. package/dist/backend/services/product-editor-preferences.service.d.ts +20 -0
  292. package/dist/backend/services/product-editor-preferences.service.d.ts.map +1 -0
  293. package/dist/backend/services/product-editor-preferences.service.js +44 -0
  294. package/dist/backend/services/product-editor-preferences.service.js.map +1 -0
  295. package/dist/backend/services/product-link.service.d.ts +169 -0
  296. package/dist/backend/services/product-link.service.d.ts.map +1 -0
  297. package/dist/backend/services/product-link.service.js +297 -0
  298. package/dist/backend/services/product-link.service.js.map +1 -0
  299. package/dist/backend/services/product-overrides.service.d.ts +77 -0
  300. package/dist/backend/services/product-overrides.service.d.ts.map +1 -0
  301. package/dist/backend/services/product-overrides.service.js +204 -0
  302. package/dist/backend/services/product-overrides.service.js.map +1 -0
  303. package/dist/backend/services/product-scope-context.service.d.ts +36 -0
  304. package/dist/backend/services/product-scope-context.service.d.ts.map +1 -0
  305. package/dist/backend/services/product-scope-context.service.js +106 -0
  306. package/dist/backend/services/product-scope-context.service.js.map +1 -0
  307. package/dist/backend/services/product-type-validations.d.ts +42 -0
  308. package/dist/backend/services/product-type-validations.d.ts.map +1 -0
  309. package/dist/backend/services/product-type-validations.js +55 -0
  310. package/dist/backend/services/product-type-validations.js.map +1 -0
  311. package/dist/backend/services/product-value-resolver.service.d.ts +59 -0
  312. package/dist/backend/services/product-value-resolver.service.d.ts.map +1 -0
  313. package/dist/backend/services/product-value-resolver.service.js +111 -0
  314. package/dist/backend/services/product-value-resolver.service.js.map +1 -0
  315. package/dist/backend/services/system-attribute-scopes.d.ts +18 -0
  316. package/dist/backend/services/system-attribute-scopes.d.ts.map +1 -0
  317. package/dist/backend/services/system-attribute-scopes.js +18 -0
  318. package/dist/backend/services/system-attribute-scopes.js.map +1 -0
  319. package/dist/backend/services/viewer-organization.d.ts +25 -0
  320. package/dist/backend/services/viewer-organization.d.ts.map +1 -0
  321. package/dist/backend/services/viewer-organization.js +31 -0
  322. package/dist/backend/services/viewer-organization.js.map +1 -0
  323. package/dist/manifest.d.ts +204 -0
  324. package/dist/manifest.d.ts.map +1 -0
  325. package/dist/manifest.js +686 -0
  326. package/dist/manifest.js.map +1 -0
  327. package/dist/migrations/20260429T064146_catalog_attribute_sets_init.d.ts +33 -0
  328. package/dist/migrations/20260429T064146_catalog_attribute_sets_init.d.ts.map +1 -0
  329. package/dist/migrations/20260429T064146_catalog_attribute_sets_init.js +118 -0
  330. package/dist/migrations/20260429T064146_catalog_attribute_sets_init.js.map +1 -0
  331. package/dist/migrations/20260429T070004_catalog_product_attribute_extensions.d.ts +24 -0
  332. package/dist/migrations/20260429T070004_catalog_product_attribute_extensions.d.ts.map +1 -0
  333. package/dist/migrations/20260429T070004_catalog_product_attribute_extensions.js +31 -0
  334. package/dist/migrations/20260429T070004_catalog_product_attribute_extensions.js.map +1 -0
  335. package/dist/migrations/20260429T102322_catalog_product_type_and_virtual_fields.d.ts +32 -0
  336. package/dist/migrations/20260429T102322_catalog_product_type_and_virtual_fields.d.ts.map +1 -0
  337. package/dist/migrations/20260429T102322_catalog_product_type_and_virtual_fields.js +58 -0
  338. package/dist/migrations/20260429T102322_catalog_product_type_and_virtual_fields.js.map +1 -0
  339. package/dist/migrations/20260429T111839_catalog_gallery_items_and_labels.d.ts +22 -0
  340. package/dist/migrations/20260429T111839_catalog_gallery_items_and_labels.d.ts.map +1 -0
  341. package/dist/migrations/20260429T111839_catalog_gallery_items_and_labels.js +66 -0
  342. package/dist/migrations/20260429T111839_catalog_gallery_items_and_labels.js.map +1 -0
  343. package/dist/migrations/20260429T112543_catalog_product_attachments.d.ts +18 -0
  344. package/dist/migrations/20260429T112543_catalog_product_attachments.d.ts.map +1 -0
  345. package/dist/migrations/20260429T112543_catalog_product_attachments.js +73 -0
  346. package/dist/migrations/20260429T112543_catalog_product_attachments.js.map +1 -0
  347. package/dist/migrations/20260429T123726_catalog_product_links.d.ts +21 -0
  348. package/dist/migrations/20260429T123726_catalog_product_links.d.ts.map +1 -0
  349. package/dist/migrations/20260429T123726_catalog_product_links.js +48 -0
  350. package/dist/migrations/20260429T123726_catalog_product_links.js.map +1 -0
  351. package/dist/migrations/20260429T130803_catalog_grouped_and_bundle.d.ts +23 -0
  352. package/dist/migrations/20260429T130803_catalog_grouped_and_bundle.d.ts.map +1 -0
  353. package/dist/migrations/20260429T130803_catalog_grouped_and_bundle.js +94 -0
  354. package/dist/migrations/20260429T130803_catalog_grouped_and_bundle.js.map +1 -0
  355. package/dist/migrations/20260501T185835_catalog_product_attribute_is_comparable.d.ts +24 -0
  356. package/dist/migrations/20260501T185835_catalog_product_attribute_is_comparable.d.ts.map +1 -0
  357. package/dist/migrations/20260501T185835_catalog_product_attribute_is_comparable.js +31 -0
  358. package/dist/migrations/20260501T185835_catalog_product_attribute_is_comparable.js.map +1 -0
  359. package/dist/migrations/20260505T060113_catalog_attribute_options_and_flags.d.ts +31 -0
  360. package/dist/migrations/20260505T060113_catalog_attribute_options_and_flags.d.ts.map +1 -0
  361. package/dist/migrations/20260505T060113_catalog_attribute_options_and_flags.js +133 -0
  362. package/dist/migrations/20260505T060113_catalog_attribute_options_and_flags.js.map +1 -0
  363. package/dist/migrations/20260515T082629_catalog_attribute_mass_editable.d.ts +16 -0
  364. package/dist/migrations/20260515T082629_catalog_attribute_mass_editable.d.ts.map +1 -0
  365. package/dist/migrations/20260515T082629_catalog_attribute_mass_editable.js +23 -0
  366. package/dist/migrations/20260515T082629_catalog_attribute_mass_editable.js.map +1 -0
  367. package/dist/migrations/20260526T124736_catalog_product_status_inactive.d.ts +10 -0
  368. package/dist/migrations/20260526T124736_catalog_product_status_inactive.d.ts.map +1 -0
  369. package/dist/migrations/20260526T124736_catalog_product_status_inactive.js +22 -0
  370. package/dist/migrations/20260526T124736_catalog_product_status_inactive.js.map +1 -0
  371. package/dist/migrations/20260611T140346_catalog_product_value_overrides_init.d.ts +38 -0
  372. package/dist/migrations/20260611T140346_catalog_product_value_overrides_init.d.ts.map +1 -0
  373. package/dist/migrations/20260611T140346_catalog_product_value_overrides_init.js +98 -0
  374. package/dist/migrations/20260611T140346_catalog_product_value_overrides_init.js.map +1 -0
  375. package/dist/migrations/20260611T140400_catalog_attribute_quick_searchable.d.ts +13 -0
  376. package/dist/migrations/20260611T140400_catalog_attribute_quick_searchable.d.ts.map +1 -0
  377. package/dist/migrations/20260611T140400_catalog_attribute_quick_searchable.js +17 -0
  378. package/dist/migrations/20260611T140400_catalog_attribute_quick_searchable.js.map +1 -0
  379. package/dist/migrations/20260611T140407_catalog_bulk_operations.d.ts +16 -0
  380. package/dist/migrations/20260611T140407_catalog_bulk_operations.d.ts.map +1 -0
  381. package/dist/migrations/20260611T140407_catalog_bulk_operations.js +42 -0
  382. package/dist/migrations/20260611T140407_catalog_bulk_operations.js.map +1 -0
  383. package/dist/migrations/20260611T140408_catalog_bulk_operation_logs.d.ts +14 -0
  384. package/dist/migrations/20260611T140408_catalog_bulk_operation_logs.d.ts.map +1 -0
  385. package/dist/migrations/20260611T140408_catalog_bulk_operation_logs.js +18 -0
  386. package/dist/migrations/20260611T140408_catalog_bulk_operation_logs.js.map +1 -0
  387. package/dist/migrations/20260611T140412_catalog_product_packaging_units.d.ts +11 -0
  388. package/dist/migrations/20260611T140412_catalog_product_packaging_units.d.ts.map +1 -0
  389. package/dist/migrations/20260611T140412_catalog_product_packaging_units.js +29 -0
  390. package/dist/migrations/20260611T140412_catalog_product_packaging_units.js.map +1 -0
  391. package/dist/migrations/20260718T060659_catalog_bulk_operation_revert_state.d.ts +23 -0
  392. package/dist/migrations/20260718T060659_catalog_bulk_operation_revert_state.d.ts.map +1 -0
  393. package/dist/migrations/20260718T060659_catalog_bulk_operation_revert_state.js +35 -0
  394. package/dist/migrations/20260718T060659_catalog_bulk_operation_revert_state.js.map +1 -0
  395. package/dist/migrations/20260718T200343_catalog_category_custom_field_values.d.ts +12 -0
  396. package/dist/migrations/20260718T200343_catalog_category_custom_field_values.d.ts.map +1 -0
  397. package/dist/migrations/20260718T200343_catalog_category_custom_field_values.js +16 -0
  398. package/dist/migrations/20260718T200343_catalog_category_custom_field_values.js.map +1 -0
  399. package/dist/migrations/20260723T230401_catalog_attributes_on_custom_fields.d.ts +32 -0
  400. package/dist/migrations/20260723T230401_catalog_attributes_on_custom_fields.d.ts.map +1 -0
  401. package/dist/migrations/20260723T230401_catalog_attributes_on_custom_fields.js +286 -0
  402. package/dist/migrations/20260723T230401_catalog_attributes_on_custom_fields.js.map +1 -0
  403. package/dist/migrations/20260804T152604_catalog_widen_product_sku.d.ts +36 -0
  404. package/dist/migrations/20260804T152604_catalog_widen_product_sku.d.ts.map +1 -0
  405. package/dist/migrations/20260804T152604_catalog_widen_product_sku.js +63 -0
  406. package/dist/migrations/20260804T152604_catalog_widen_product_sku.js.map +1 -0
  407. package/dist/migrations/20260804T160244_catalog_category_activation.d.ts +18 -0
  408. package/dist/migrations/20260804T160244_catalog_category_activation.d.ts.map +1 -0
  409. package/dist/migrations/20260804T160244_catalog_category_activation.js +22 -0
  410. package/dist/migrations/20260804T160244_catalog_category_activation.js.map +1 -0
  411. package/dist/migrations/20260912T094557_catalog_sales_channel_products.d.ts +27 -0
  412. package/dist/migrations/20260912T094557_catalog_sales_channel_products.d.ts.map +1 -0
  413. package/dist/migrations/20260912T094557_catalog_sales_channel_products.js +44 -0
  414. package/dist/migrations/20260912T094557_catalog_sales_channel_products.js.map +1 -0
  415. package/dist/migrations/20260912T094623_catalog_sales_channel_categories.d.ts +27 -0
  416. package/dist/migrations/20260912T094623_catalog_sales_channel_categories.d.ts.map +1 -0
  417. package/dist/migrations/20260912T094623_catalog_sales_channel_categories.js +44 -0
  418. package/dist/migrations/20260912T094623_catalog_sales_channel_categories.js.map +1 -0
  419. package/dist/migrations/20260925T125527_catalog_inventory_columns.d.ts +36 -0
  420. package/dist/migrations/20260925T125527_catalog_inventory_columns.d.ts.map +1 -0
  421. package/dist/migrations/20260925T125527_catalog_inventory_columns.js +87 -0
  422. package/dist/migrations/20260925T125527_catalog_inventory_columns.js.map +1 -0
  423. package/dist/migrations/index.d.ts +55 -0
  424. package/dist/migrations/index.d.ts.map +1 -0
  425. package/dist/migrations/index.js +80 -0
  426. package/dist/migrations/index.js.map +1 -0
  427. package/dist/ports/index.d.ts +96 -0
  428. package/dist/ports/index.d.ts.map +1 -0
  429. package/dist/ports/index.js +2 -0
  430. package/dist/ports/index.js.map +1 -0
  431. package/docs/catalog/attachments.md +69 -0
  432. package/docs/catalog/attribute-sets.md +63 -0
  433. package/docs/catalog/attributes.md +244 -0
  434. package/docs/catalog/composite-products.md +115 -0
  435. package/docs/catalog/gallery-and-labels.md +73 -0
  436. package/docs/catalog/packaging-units.md +67 -0
  437. package/docs/catalog/per-channel-per-language-overrides.md +234 -0
  438. package/docs/catalog/product-links.md +79 -0
  439. package/docs/catalog.md +207 -0
  440. package/i18n/en.json +649 -0
  441. package/i18n/pl.json +649 -0
  442. package/package.json +109 -0
  443. package/tailwind.css +14 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260611T140400_catalog_attribute_quick_searchable.js","sourceRoot":"","sources":["../../src/migrations/20260611T140400_catalog_attribute_quick_searchable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;GAMG;AACH,MAAM,OAAO,uDAAwD,SAAQ,SAAS;IAC3E,KAAK,CAAC,EAAE;QACf,IAAI,CAAC,MAAM,CACT,gGAAgG,CACjG,CAAC;IACJ,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,IAAI,CAAC,MAAM,CAAC,kEAAkE,CAAC,CAAC;IAClF,CAAC;CACF"}
@@ -0,0 +1,16 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Queued product bulk-edit — `catalog_bulk_operations`.
4
+ *
5
+ * Backs the asynchronous bulk-edit path: selections above the
6
+ * synchronous threshold are persisted here and processed by the
7
+ * in-process sweeper instead of being applied inline. Live counters
8
+ * (`processed` / `succeeded` / `skipped` / `failed`) drive the
9
+ * "Bulk actions" admin page; `payload` keeps the original request and
10
+ * `results` the per-product outcome list once the run finishes.
11
+ */
12
+ export declare class Migration20260611T140407CatalogBulkOperations extends Migration {
13
+ up(): Promise<void>;
14
+ down(): Promise<void>;
15
+ }
16
+ //# sourceMappingURL=20260611T140407_catalog_bulk_operations.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260611T140407_catalog_bulk_operations.d.ts","sourceRoot":"","sources":["../../src/migrations/20260611T140407_catalog_bulk_operations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;GASG;AACH,qBAAa,6CAA8C,SAAQ,SAAS;IAC3D,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IAgCnB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAGrC"}
@@ -0,0 +1,42 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Queued product bulk-edit — `catalog_bulk_operations`.
4
+ *
5
+ * Backs the asynchronous bulk-edit path: selections above the
6
+ * synchronous threshold are persisted here and processed by the
7
+ * in-process sweeper instead of being applied inline. Live counters
8
+ * (`processed` / `succeeded` / `skipped` / `failed`) drive the
9
+ * "Bulk actions" admin page; `payload` keeps the original request and
10
+ * `results` the per-product outcome list once the run finishes.
11
+ */
12
+ export class Migration20260611T140407CatalogBulkOperations extends Migration {
13
+ async up() {
14
+ this.addSql(`
15
+ create table "catalog_bulk_operations" (
16
+ "id" uuid not null,
17
+ "type" varchar(64) not null default 'product_bulk_update',
18
+ "status" varchar(16) not null default 'pending',
19
+ "requested_by_admin_user_id" uuid not null,
20
+ "total" int not null,
21
+ "processed" int not null default 0,
22
+ "succeeded" int not null default 0,
23
+ "skipped" int not null default 0,
24
+ "failed" int not null default 0,
25
+ "payload" jsonb not null,
26
+ "results" jsonb null,
27
+ "error" text null,
28
+ "created_at" timestamptz not null,
29
+ "started_at" timestamptz null,
30
+ "finished_at" timestamptz null,
31
+ constraint "catalog_bulk_operations_pkey" primary key ("id")
32
+ );
33
+ `);
34
+ this.addSql('create index "catalog_bulk_operations_status_index" on "catalog_bulk_operations" ("status");');
35
+ this.addSql('create index "catalog_bulk_operations_requested_by_admin_user_id_index" on "catalog_bulk_operations" ("requested_by_admin_user_id");');
36
+ this.addSql('create index "catalog_bulk_operations_created_at_index" on "catalog_bulk_operations" ("created_at");');
37
+ }
38
+ async down() {
39
+ this.addSql('drop table if exists "catalog_bulk_operations" cascade;');
40
+ }
41
+ }
42
+ //# sourceMappingURL=20260611T140407_catalog_bulk_operations.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260611T140407_catalog_bulk_operations.js","sourceRoot":"","sources":["../../src/migrations/20260611T140407_catalog_bulk_operations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;GASG;AACH,MAAM,OAAO,6CAA8C,SAAQ,SAAS;IACjE,KAAK,CAAC,EAAE;QACf,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;;;;;;;KAmBX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CACT,8FAA8F,CAC/F,CAAC;QACF,IAAI,CAAC,MAAM,CACT,sIAAsI,CACvI,CAAC;QACF,IAAI,CAAC,MAAM,CACT,sGAAsG,CACvG,CAAC;IACJ,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,IAAI,CAAC,MAAM,CAAC,yDAAyD,CAAC,CAAC;IACzE,CAAC;CACF"}
@@ -0,0 +1,14 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Bulk-operation lifecycle logs — adds `logs` to `catalog_bulk_operations`.
4
+ *
5
+ * Holds an ordered list of timestamped lifecycle events (created / started /
6
+ * completed / failed, plus notable milestones) so the bulk-operations detail
7
+ * view can show "what happened, when" alongside the per-element `results`.
8
+ * Nullable — rows predating this migration simply have no log trail.
9
+ */
10
+ export declare class Migration20260611T140408CatalogBulkOperationLogs extends Migration {
11
+ up(): Promise<void>;
12
+ down(): Promise<void>;
13
+ }
14
+ //# sourceMappingURL=20260611T140408_catalog_bulk_operation_logs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260611T140408_catalog_bulk_operation_logs.d.ts","sourceRoot":"","sources":["../../src/migrations/20260611T140408_catalog_bulk_operation_logs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;GAOG;AACH,qBAAa,gDAAiD,SAAQ,SAAS;IAC9D,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IAInB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAGrC"}
@@ -0,0 +1,18 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Bulk-operation lifecycle logs — adds `logs` to `catalog_bulk_operations`.
4
+ *
5
+ * Holds an ordered list of timestamped lifecycle events (created / started /
6
+ * completed / failed, plus notable milestones) so the bulk-operations detail
7
+ * view can show "what happened, when" alongside the per-element `results`.
8
+ * Nullable — rows predating this migration simply have no log trail.
9
+ */
10
+ export class Migration20260611T140408CatalogBulkOperationLogs extends Migration {
11
+ async up() {
12
+ this.addSql('alter table "catalog_bulk_operations" add column "logs" jsonb null;');
13
+ }
14
+ async down() {
15
+ this.addSql('alter table "catalog_bulk_operations" drop column "logs";');
16
+ }
17
+ }
18
+ //# sourceMappingURL=20260611T140408_catalog_bulk_operation_logs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260611T140408_catalog_bulk_operation_logs.js","sourceRoot":"","sources":["../../src/migrations/20260611T140408_catalog_bulk_operation_logs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;GAOG;AACH,MAAM,OAAO,gDAAiD,SAAQ,SAAS;IACpE,KAAK,CAAC,EAAE;QACf,IAAI,CAAC,MAAM,CAAC,qEAAqE,CAAC,CAAC;IACrF,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,IAAI,CAAC,MAAM,CAAC,2DAA2D,CAAC,CAAC;IAC3E,CAAC;CACF"}
@@ -0,0 +1,11 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Product packaging units (feature 043) — named ordering units (e.g.
4
+ * "Paleta" = 480 pieces) attached to a product. Unique name per product,
5
+ * positive base quantity, ordered by `position`, with one optional default.
6
+ */
7
+ export declare class Migration20260611T140412CatalogProductPackagingUnits extends Migration {
8
+ up(): Promise<void>;
9
+ down(): Promise<void>;
10
+ }
11
+ //# sourceMappingURL=20260611T140412_catalog_product_packaging_units.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260611T140412_catalog_product_packaging_units.d.ts","sourceRoot":"","sources":["../../src/migrations/20260611T140412_catalog_product_packaging_units.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;GAIG;AACH,qBAAa,oDAAqD,SAAQ,SAAS;IAClE,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IA0BnB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAGrC"}
@@ -0,0 +1,29 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Product packaging units (feature 043) — named ordering units (e.g.
4
+ * "Paleta" = 480 pieces) attached to a product. Unique name per product,
5
+ * positive base quantity, ordered by `position`, with one optional default.
6
+ */
7
+ export class Migration20260611T140412CatalogProductPackagingUnits extends Migration {
8
+ async up() {
9
+ this.addSql(`create table "product_packaging_units" (
10
+ "id" uuid not null,
11
+ "product_id" uuid not null,
12
+ "name" varchar(160) not null,
13
+ "base_quantity" integer not null,
14
+ "position" integer not null default 0,
15
+ "is_default" boolean not null default false,
16
+ "created_at" timestamptz not null,
17
+ "updated_at" timestamptz not null,
18
+ constraint "product_packaging_units_pkey" primary key ("id")
19
+ );`);
20
+ this.addSql('alter table "product_packaging_units" add constraint "product_packaging_units_base_quantity_check" check ("base_quantity" >= 1);');
21
+ this.addSql('create index "product_packaging_units_product_id_index" on "product_packaging_units" ("product_id");');
22
+ this.addSql('alter table "product_packaging_units" add constraint "product_packaging_units_product_id_name_unique" unique ("product_id", "name");');
23
+ this.addSql('alter table "product_packaging_units" add constraint "product_packaging_units_product_id_foreign" foreign key ("product_id") references "products" ("id") on update cascade on delete cascade;');
24
+ }
25
+ async down() {
26
+ this.addSql('drop table if exists "product_packaging_units";');
27
+ }
28
+ }
29
+ //# sourceMappingURL=20260611T140412_catalog_product_packaging_units.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260611T140412_catalog_product_packaging_units.js","sourceRoot":"","sources":["../../src/migrations/20260611T140412_catalog_product_packaging_units.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;GAIG;AACH,MAAM,OAAO,oDAAqD,SAAQ,SAAS;IACxE,KAAK,CAAC,EAAE;QACf,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;OAUT,CAAC,CAAC;QACL,IAAI,CAAC,MAAM,CACT,kIAAkI,CACnI,CAAC;QACF,IAAI,CAAC,MAAM,CACT,sGAAsG,CACvG,CAAC;QACF,IAAI,CAAC,MAAM,CACT,sIAAsI,CACvI,CAAC;QACF,IAAI,CAAC,MAAM,CACT,gMAAgM,CACjM,CAAC;IACJ,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,IAAI,CAAC,MAAM,CAAC,iDAAiD,CAAC,CAAC;IACjE,CAAC;CACF"}
@@ -0,0 +1,23 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Reversible bulk operations — feature 054 (Command Bus, US2).
4
+ *
5
+ * Extends `catalog_bulk_operations` (feature 022's store; no parallel table) with
6
+ * the per-record before/after snapshot and undo bookkeeping needed to undo a bulk
7
+ * edit:
8
+ * - `revert_state` — array of `{ recordId, before, after }` (research §R3/§R4);
9
+ * - `reversible` — whether this operation captured revert data (drives the
10
+ * operator-facing undo affordance, FR-004);
11
+ * - `undo_status` — `none | reverted | partially_reverted` (idempotent-safe
12
+ * re-invoke, FR-014);
13
+ * - `undone_at` — when the undo completed;
14
+ * - `undo_operation_id` — links the undo's own audited action (FR-007).
15
+ *
16
+ * All additive + nullable/defaulted, so rows predating this migration remain
17
+ * non-reversible with no backfill.
18
+ */
19
+ export declare class Migration20260718T060659CatalogBulkOperationRevertState extends Migration {
20
+ up(): Promise<void>;
21
+ down(): Promise<void>;
22
+ }
23
+ //# sourceMappingURL=20260718T060659_catalog_bulk_operation_revert_state.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260718T060659_catalog_bulk_operation_revert_state.d.ts","sourceRoot":"","sources":["../../src/migrations/20260718T060659_catalog_bulk_operation_revert_state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;;;;;;;;GAgBG;AACH,qBAAa,uDAAwD,SAAQ,SAAS;IACrE,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IAcnB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAOrC"}
@@ -0,0 +1,35 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Reversible bulk operations — feature 054 (Command Bus, US2).
4
+ *
5
+ * Extends `catalog_bulk_operations` (feature 022's store; no parallel table) with
6
+ * the per-record before/after snapshot and undo bookkeeping needed to undo a bulk
7
+ * edit:
8
+ * - `revert_state` — array of `{ recordId, before, after }` (research §R3/§R4);
9
+ * - `reversible` — whether this operation captured revert data (drives the
10
+ * operator-facing undo affordance, FR-004);
11
+ * - `undo_status` — `none | reverted | partially_reverted` (idempotent-safe
12
+ * re-invoke, FR-014);
13
+ * - `undone_at` — when the undo completed;
14
+ * - `undo_operation_id` — links the undo's own audited action (FR-007).
15
+ *
16
+ * All additive + nullable/defaulted, so rows predating this migration remain
17
+ * non-reversible with no backfill.
18
+ */
19
+ export class Migration20260718T060659CatalogBulkOperationRevertState extends Migration {
20
+ async up() {
21
+ this.addSql('alter table "catalog_bulk_operations" add column "revert_state" jsonb null;');
22
+ this.addSql('alter table "catalog_bulk_operations" add column "reversible" boolean not null default false;');
23
+ this.addSql(`alter table "catalog_bulk_operations" add column "undo_status" varchar(24) not null default 'none';`);
24
+ this.addSql('alter table "catalog_bulk_operations" add column "undone_at" timestamptz null;');
25
+ this.addSql('alter table "catalog_bulk_operations" add column "undo_operation_id" uuid null;');
26
+ }
27
+ async down() {
28
+ this.addSql('alter table "catalog_bulk_operations" drop column "undo_operation_id";');
29
+ this.addSql('alter table "catalog_bulk_operations" drop column "undone_at";');
30
+ this.addSql('alter table "catalog_bulk_operations" drop column "undo_status";');
31
+ this.addSql('alter table "catalog_bulk_operations" drop column "reversible";');
32
+ this.addSql('alter table "catalog_bulk_operations" drop column "revert_state";');
33
+ }
34
+ }
35
+ //# sourceMappingURL=20260718T060659_catalog_bulk_operation_revert_state.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260718T060659_catalog_bulk_operation_revert_state.js","sourceRoot":"","sources":["../../src/migrations/20260718T060659_catalog_bulk_operation_revert_state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,OAAO,uDAAwD,SAAQ,SAAS;IAC3E,KAAK,CAAC,EAAE;QACf,IAAI,CAAC,MAAM,CAAC,6EAA6E,CAAC,CAAC;QAC3F,IAAI,CAAC,MAAM,CACT,+FAA+F,CAChG,CAAC;QACF,IAAI,CAAC,MAAM,CACT,qGAAqG,CACtG,CAAC;QACF,IAAI,CAAC,MAAM,CAAC,gFAAgF,CAAC,CAAC;QAC9F,IAAI,CAAC,MAAM,CACT,iFAAiF,CAClF,CAAC;IACJ,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,IAAI,CAAC,MAAM,CAAC,wEAAwE,CAAC,CAAC;QACtF,IAAI,CAAC,MAAM,CAAC,gEAAgE,CAAC,CAAC;QAC9E,IAAI,CAAC,MAAM,CAAC,kEAAkE,CAAC,CAAC;QAChF,IAAI,CAAC,MAAM,CAAC,iEAAiE,CAAC,CAAC;QAC/E,IAAI,CAAC,MAAM,CAAC,mEAAmE,CAAC,CAAC;IACnF,CAAC;CACF"}
@@ -0,0 +1,12 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Feature 055 — Custom Fields Layer. Additive: adds the `custom_field_values`
4
+ * JSONB bag to `categories` so operator-defined fields persist on the host row.
5
+ * The column inherits the host entity's tenant classification (Principle XI);
6
+ * no scoping column is added.
7
+ */
8
+ export declare class Migration20260718T200343CatalogCategoryCustomFieldValues extends Migration {
9
+ up(): Promise<void>;
10
+ down(): Promise<void>;
11
+ }
12
+ //# sourceMappingURL=20260718T200343_catalog_category_custom_field_values.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260718T200343_catalog_category_custom_field_values.d.ts","sourceRoot":"","sources":["../../src/migrations/20260718T200343_catalog_category_custom_field_values.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;GAKG;AACH,qBAAa,wDAAyD,SAAQ,SAAS;IACtE,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IAMnB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAGrC"}
@@ -0,0 +1,16 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Feature 055 — Custom Fields Layer. Additive: adds the `custom_field_values`
4
+ * JSONB bag to `categories` so operator-defined fields persist on the host row.
5
+ * The column inherits the host entity's tenant classification (Principle XI);
6
+ * no scoping column is added.
7
+ */
8
+ export class Migration20260718T200343CatalogCategoryCustomFieldValues extends Migration {
9
+ async up() {
10
+ this.addSql(`alter table "categories" add column "custom_field_values" jsonb not null default '{}';`);
11
+ }
12
+ async down() {
13
+ this.addSql(`alter table "categories" drop column "custom_field_values";`);
14
+ }
15
+ }
16
+ //# sourceMappingURL=20260718T200343_catalog_category_custom_field_values.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260718T200343_catalog_category_custom_field_values.js","sourceRoot":"","sources":["../../src/migrations/20260718T200343_catalog_category_custom_field_values.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;GAKG;AACH,MAAM,OAAO,wDAAyD,SAAQ,SAAS;IAC5E,KAAK,CAAC,EAAE;QACf,IAAI,CAAC,MAAM,CACT,wFAAwF,CACzF,CAAC;IACJ,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,IAAI,CAAC,MAAM,CAAC,6DAA6D,CAAC,CAAC;IAC7E,CAAC;CACF"}
@@ -0,0 +1,32 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Feature 061 — Product Attributes on Custom Fields.
4
+ *
5
+ * Converges the legacy `product_attributes` registry onto the Custom Fields
6
+ * layer (data-model.md §3, research §R5). Single transaction, six steps:
7
+ *
8
+ * 1. Assert no reserved-key (`name` / `description`) or pre-existing
9
+ * product-host definition collision — abort loudly otherwise.
10
+ * 2. Insert one `custom_field_definitions` row per legacy attribute
11
+ * (`entity_type='product'`, value type mapped per research §R7,
12
+ * deterministic `sort_order` by `(created_at, key)`).
13
+ * 3. Copy `attribute_options` → `custom_field_options` (new option ids —
14
+ * product data and filter URLs reference options by `value`).
15
+ * 4. Reshape `product_attributes` into the catalog extension: add + backfill
16
+ * `custom_field_definition_id` (NOT NULL UNIQUE, FK RESTRICT),
17
+ * `select_display`, `numeric_kind`; drop `key`, `label`, `label_default`,
18
+ * `value_type`, `is_required`.
19
+ * 5. Re-key `attribute_set_attributes.product_attribute_id` →
20
+ * `custom_field_definition_id` (values via the extension join; FK
21
+ * RESTRICT preserved).
22
+ * 6. Drop `attribute_options`.
23
+ *
24
+ * `down()` reverses 6→1 — the §R7 map is bijective, so the legacy columns and
25
+ * option rows are reconstructed from the CF rows, and the product-host
26
+ * definitions/options are deleted.
27
+ */
28
+ export declare class Migration20260723T230401CatalogAttributesOnCustomFields extends Migration {
29
+ up(): Promise<void>;
30
+ down(): Promise<void>;
31
+ }
32
+ //# sourceMappingURL=20260723T230401_catalog_attributes_on_custom_fields.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260723T230401_catalog_attributes_on_custom_fields.d.ts","sourceRoot":"","sources":["../../src/migrations/20260723T230401_catalog_attributes_on_custom_fields.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,qBAAa,uDAAwD,SAAQ,SAAS;IACrE,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IA6InB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CA+HrC"}
@@ -0,0 +1,286 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Feature 061 — Product Attributes on Custom Fields.
4
+ *
5
+ * Converges the legacy `product_attributes` registry onto the Custom Fields
6
+ * layer (data-model.md §3, research §R5). Single transaction, six steps:
7
+ *
8
+ * 1. Assert no reserved-key (`name` / `description`) or pre-existing
9
+ * product-host definition collision — abort loudly otherwise.
10
+ * 2. Insert one `custom_field_definitions` row per legacy attribute
11
+ * (`entity_type='product'`, value type mapped per research §R7,
12
+ * deterministic `sort_order` by `(created_at, key)`).
13
+ * 3. Copy `attribute_options` → `custom_field_options` (new option ids —
14
+ * product data and filter URLs reference options by `value`).
15
+ * 4. Reshape `product_attributes` into the catalog extension: add + backfill
16
+ * `custom_field_definition_id` (NOT NULL UNIQUE, FK RESTRICT),
17
+ * `select_display`, `numeric_kind`; drop `key`, `label`, `label_default`,
18
+ * `value_type`, `is_required`.
19
+ * 5. Re-key `attribute_set_attributes.product_attribute_id` →
20
+ * `custom_field_definition_id` (values via the extension join; FK
21
+ * RESTRICT preserved).
22
+ * 6. Drop `attribute_options`.
23
+ *
24
+ * `down()` reverses 6→1 — the §R7 map is bijective, so the legacy columns and
25
+ * option rows are reconstructed from the CF rows, and the product-host
26
+ * definitions/options are deleted.
27
+ */
28
+ export class Migration20260723T230401CatalogAttributesOnCustomFields extends Migration {
29
+ async up() {
30
+ // -- Step 1: loud abort on reserved-key / pre-existing-definition collision.
31
+ this.addSql(`
32
+ do $$
33
+ begin
34
+ if exists (select 1 from "product_attributes" where "key" in ('name', 'description')) then
35
+ raise exception 'attributes-on-custom-fields migration aborted: reserved system key (name/description) found in product_attributes';
36
+ end if;
37
+ if exists (
38
+ select 1 from "custom_field_definitions" cfd
39
+ join "product_attributes" pa on pa."key" = cfd."key"
40
+ where cfd."entity_type" = 'product'
41
+ ) then
42
+ raise exception 'attributes-on-custom-fields migration aborted: colliding product-host custom_field_definitions rows already exist';
43
+ end if;
44
+ end $$;
45
+ `);
46
+ // -- Step 2: one definition per legacy attribute (type map per §R7).
47
+ this.addSql(`
48
+ insert into "custom_field_definitions"
49
+ ("id", "entity_type", "key", "label", "label_default", "value_type",
50
+ "required", "sort_order", "config", "created_at", "updated_at")
51
+ select
52
+ gen_random_uuid(),
53
+ 'product',
54
+ pa."key",
55
+ pa."label",
56
+ pa."label_default",
57
+ case pa."value_type"
58
+ when 'string' then 'text'
59
+ when 'price' then 'number'
60
+ when 'enum' then 'select'
61
+ else pa."value_type"
62
+ end,
63
+ pa."is_required",
64
+ row_number() over (order by pa."created_at", pa."key") - 1,
65
+ '{}'::jsonb,
66
+ pa."created_at",
67
+ pa."updated_at"
68
+ from "product_attributes" pa;
69
+ `);
70
+ // -- Step 3: copy options (join attribute_id → key → definition_id).
71
+ this.addSql(`
72
+ insert into "custom_field_options"
73
+ ("id", "definition_id", "value", "label", "label_default", "is_default",
74
+ "sort_order", "created_at", "updated_at")
75
+ select
76
+ gen_random_uuid(),
77
+ cfd."id",
78
+ ao."value",
79
+ ao."label",
80
+ ao."label_default",
81
+ ao."is_default",
82
+ ao."sort_order",
83
+ ao."created_at",
84
+ ao."updated_at"
85
+ from "attribute_options" ao
86
+ join "product_attributes" pa on pa."id" = ao."attribute_id"
87
+ join "custom_field_definitions" cfd
88
+ on cfd."entity_type" = 'product' and cfd."key" = pa."key";
89
+ `);
90
+ // -- Step 4: reshape product_attributes into the extension.
91
+ this.addSql(`
92
+ alter table "product_attributes"
93
+ add column "custom_field_definition_id" uuid null,
94
+ add column "select_display" varchar(16) null,
95
+ add column "numeric_kind" varchar(8) null;
96
+ `);
97
+ this.addSql(`
98
+ update "product_attributes" pa
99
+ set
100
+ "custom_field_definition_id" = cfd."id",
101
+ "select_display" = case pa."value_type"
102
+ when 'enum' then 'pill'
103
+ when 'select' then 'dropdown'
104
+ else null
105
+ end,
106
+ "numeric_kind" = case pa."value_type"
107
+ when 'number' then 'number'
108
+ when 'price' then 'price'
109
+ else null
110
+ end
111
+ from "custom_field_definitions" cfd
112
+ where cfd."entity_type" = 'product' and cfd."key" = pa."key";
113
+ `);
114
+ this.addSql(`alter table "product_attributes" alter column "custom_field_definition_id" set not null;`);
115
+ this.addSql(`
116
+ alter table "product_attributes"
117
+ add constraint "product_attributes_custom_field_definition_id_unique"
118
+ unique ("custom_field_definition_id");
119
+ `);
120
+ this.addSql(`
121
+ alter table "product_attributes"
122
+ add constraint "fk_product_attributes_custom_field_definition"
123
+ foreign key ("custom_field_definition_id")
124
+ references "custom_field_definitions" ("id")
125
+ on delete restrict;
126
+ `);
127
+ this.addSql(`
128
+ alter table "product_attributes"
129
+ drop column "key",
130
+ drop column "label",
131
+ drop column "label_default",
132
+ drop column "value_type",
133
+ drop column "is_required";
134
+ `);
135
+ // -- Step 5: re-key set membership onto definition ids.
136
+ this.addSql(`
137
+ alter table "attribute_set_attributes"
138
+ drop constraint "fk_attribute_set_attributes_attribute";
139
+ `);
140
+ this.addSql(`
141
+ alter table "attribute_set_attributes"
142
+ rename column "product_attribute_id" to "custom_field_definition_id";
143
+ `);
144
+ this.addSql(`
145
+ update "attribute_set_attributes" asa
146
+ set "custom_field_definition_id" = pa."custom_field_definition_id"
147
+ from "product_attributes" pa
148
+ where pa."id" = asa."custom_field_definition_id";
149
+ `);
150
+ this.addSql(`
151
+ alter table "attribute_set_attributes"
152
+ add constraint "fk_attribute_set_attributes_definition"
153
+ foreign key ("custom_field_definition_id")
154
+ references "custom_field_definitions" ("id")
155
+ on delete restrict;
156
+ `);
157
+ this.addSql(`
158
+ alter index "attribute_set_attributes_attribute_id_index"
159
+ rename to "attribute_set_attributes_definition_id_index";
160
+ `);
161
+ // -- Step 6: drop the legacy option table.
162
+ this.addSql(`drop table "attribute_options";`);
163
+ }
164
+ async down() {
165
+ // -- Reverse step 6: recreate attribute_options (shape from migration 032).
166
+ this.addSql(`
167
+ create table "attribute_options" (
168
+ "id" uuid primary key default gen_random_uuid(),
169
+ "attribute_id" uuid not null references "product_attributes"("id") on delete cascade,
170
+ "value" varchar(200) not null,
171
+ "label" jsonb not null default '{}'::jsonb,
172
+ "label_default" varchar(200) not null,
173
+ "is_default" boolean not null default false,
174
+ "sort_order" integer not null default 0,
175
+ "created_at" timestamptz not null default now(),
176
+ "updated_at" timestamptz not null default now(),
177
+ unique ("attribute_id", "value")
178
+ );
179
+ `);
180
+ this.addSql(`
181
+ create index "attribute_options_by_attr_order_idx"
182
+ on "attribute_options" ("attribute_id", "sort_order");
183
+ `);
184
+ this.addSql(`
185
+ create index "attribute_options_default_per_attr_idx"
186
+ on "attribute_options" ("attribute_id")
187
+ where "is_default" = true;
188
+ `);
189
+ // -- Reverse step 4: restore the legacy columns from the definitions
190
+ // (bijective §R7 map: cf type + select_display / numeric_kind).
191
+ this.addSql(`
192
+ alter table "product_attributes"
193
+ add column "key" varchar(64) null,
194
+ add column "label" jsonb null,
195
+ add column "label_default" varchar(200) null,
196
+ add column "value_type" varchar(16) null,
197
+ add column "is_required" boolean not null default false;
198
+ `);
199
+ this.addSql(`
200
+ update "product_attributes" pa
201
+ set
202
+ "key" = cfd."key",
203
+ "label" = cfd."label",
204
+ "label_default" = cfd."label_default",
205
+ "is_required" = cfd."required",
206
+ "value_type" = case cfd."value_type"
207
+ when 'text' then 'string'
208
+ when 'number' then coalesce(pa."numeric_kind", 'number')
209
+ when 'select' then case when pa."select_display" = 'pill' then 'enum' else 'select' end
210
+ else cfd."value_type"
211
+ end
212
+ from "custom_field_definitions" cfd
213
+ where cfd."id" = pa."custom_field_definition_id";
214
+ `);
215
+ this.addSql(`alter table "product_attributes" alter column "key" set not null;`);
216
+ this.addSql(`alter table "product_attributes" alter column "label" set not null;`);
217
+ this.addSql(`alter table "product_attributes" alter column "label_default" set not null;`);
218
+ this.addSql(`alter table "product_attributes" alter column "value_type" set not null;`);
219
+ this.addSql(`
220
+ alter table "product_attributes"
221
+ add constraint "product_attributes_key_unique" unique ("key");
222
+ `);
223
+ // -- Reverse step 3: restore option rows (new ids; values preserved).
224
+ this.addSql(`
225
+ insert into "attribute_options"
226
+ ("attribute_id", "value", "label", "label_default", "is_default",
227
+ "sort_order", "created_at", "updated_at")
228
+ select
229
+ pa."id",
230
+ cfo."value",
231
+ cfo."label",
232
+ cfo."label_default",
233
+ cfo."is_default",
234
+ cfo."sort_order",
235
+ cfo."created_at",
236
+ cfo."updated_at"
237
+ from "custom_field_options" cfo
238
+ join "product_attributes" pa on pa."custom_field_definition_id" = cfo."definition_id";
239
+ `);
240
+ // -- Reverse step 5: re-key set membership back onto extension ids.
241
+ this.addSql(`
242
+ alter table "attribute_set_attributes"
243
+ drop constraint "fk_attribute_set_attributes_definition";
244
+ `);
245
+ this.addSql(`
246
+ update "attribute_set_attributes" asa
247
+ set "custom_field_definition_id" = pa."id"
248
+ from "product_attributes" pa
249
+ where pa."custom_field_definition_id" = asa."custom_field_definition_id";
250
+ `);
251
+ this.addSql(`
252
+ alter table "attribute_set_attributes"
253
+ rename column "custom_field_definition_id" to "product_attribute_id";
254
+ `);
255
+ this.addSql(`
256
+ alter table "attribute_set_attributes"
257
+ add constraint "fk_attribute_set_attributes_attribute"
258
+ foreign key ("product_attribute_id")
259
+ references "product_attributes" ("id")
260
+ on delete restrict;
261
+ `);
262
+ this.addSql(`
263
+ alter index "attribute_set_attributes_definition_id_index"
264
+ rename to "attribute_set_attributes_attribute_id_index";
265
+ `);
266
+ // -- Reverse step 2: delete the product-host definitions (+ their options).
267
+ this.addSql(`
268
+ delete from "custom_field_options" cfo
269
+ using "custom_field_definitions" cfd
270
+ where cfd."id" = cfo."definition_id" and cfd."entity_type" = 'product';
271
+ `);
272
+ // -- Drop the extension columns (FK to definitions goes with them).
273
+ this.addSql(`
274
+ alter table "product_attributes"
275
+ drop constraint "fk_product_attributes_custom_field_definition";
276
+ `);
277
+ this.addSql(`
278
+ alter table "product_attributes"
279
+ drop column "custom_field_definition_id",
280
+ drop column "select_display",
281
+ drop column "numeric_kind";
282
+ `);
283
+ this.addSql(`delete from "custom_field_definitions" where "entity_type" = 'product';`);
284
+ }
285
+ }
286
+ //# sourceMappingURL=20260723T230401_catalog_attributes_on_custom_fields.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"20260723T230401_catalog_attributes_on_custom_fields.js","sourceRoot":"","sources":["../../src/migrations/20260723T230401_catalog_attributes_on_custom_fields.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,MAAM,OAAO,uDAAwD,SAAQ,SAAS;IAC3E,KAAK,CAAC,EAAE;QACf,6EAA6E;QAC7E,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;;KAcX,CAAC,CAAC;QAEH,qEAAqE;QACrE,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;;;;;;;;;;KAsBX,CAAC,CAAC;QAEH,qEAAqE;QACrE,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;;;;;;KAkBX,CAAC,CAAC;QAEH,4DAA4D;QAC5D,IAAI,CAAC,MAAM,CAAC;;;;;KAKX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;;;;KAgBX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC,0FAA0F,CAAC,CAAC;QACxG,IAAI,CAAC,MAAM,CAAC;;;;KAIX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;;KAMX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;;;KAOX,CAAC,CAAC;QAEH,wDAAwD;QACxD,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;KAKX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;;KAMX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QAEH,2CAA2C;QAC3C,IAAI,CAAC,MAAM,CAAC,iCAAiC,CAAC,CAAC;IACjD,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,4EAA4E;QAC5E,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;KAaX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;KAIX,CAAC,CAAC;QAEH,qEAAqE;QACrE,mEAAmE;QACnE,IAAI,CAAC,MAAM,CAAC;;;;;;;KAOX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;;;KAeX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC,mEAAmE,CAAC,CAAC;QACjF,IAAI,CAAC,MAAM,CAAC,qEAAqE,CAAC,CAAC;QACnF,IAAI,CAAC,MAAM,CAAC,6EAA6E,CAAC,CAAC;QAC3F,IAAI,CAAC,MAAM,CAAC,0EAA0E,CAAC,CAAC;QACxF,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QAEH,sEAAsE;QACtE,IAAI,CAAC,MAAM,CAAC;;;;;;;;;;;;;;;KAeX,CAAC,CAAC;QAEH,oEAAoE;QACpE,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;KAKX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;;KAMX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QAEH,4EAA4E;QAC5E,IAAI,CAAC,MAAM,CAAC;;;;KAIX,CAAC,CAAC;QAEH,oEAAoE;QACpE,IAAI,CAAC,MAAM,CAAC;;;KAGX,CAAC,CAAC;QACH,IAAI,CAAC,MAAM,CAAC;;;;;KAKX,CAAC,CAAC;QAEH,IAAI,CAAC,MAAM,CAAC,yEAAyE,CAAC,CAAC;IACzF,CAAC;CACF"}
@@ -0,0 +1,36 @@
1
+ import { Migration } from '@mikro-orm/migrations';
2
+ /**
3
+ * Feature 068 (Ergonode PIM integration) — widen the product identifier from
4
+ * 64 to 255 characters (research §A5, data-model §12; blocks FR-016 and
5
+ * FR-019, which require every source product to be representable).
6
+ *
7
+ * Ergonode's `Sku` scalar allows up to 255 characters. Endora capped
8
+ * `products.sku` and `product_variants.sku` at `varchar(64)` — created by
9
+ * `backend/src/db/migrations/20260424T165847_core_foundation_init.ts` — so an
10
+ * import would have had to either skip an arbitrary slice of the customer's
11
+ * catalogue or truncate identifiers, and truncation would silently merge two
12
+ * source products sharing a 64-character prefix into one Endora product.
13
+ * Neither is acceptable, so the column is widened instead.
14
+ *
15
+ * These are two of the three `sku` columns in the schema; the third,
16
+ * `product_feed_run_issues.sku`, is widened by its owning `product_feeds`
17
+ * module in the same feature. Everything else references a product by foreign
18
+ * key rather than snapshotting its identifier.
19
+ *
20
+ * Widening a `varchar` in PostgreSQL rewrites only the catalogue — no table
21
+ * rewrite, no index rebuild. The `products_sku_unique` and
22
+ * `product_variants_sku_unique` btree indexes are unaffected: 255 bytes sits
23
+ * far inside the ~2704-byte btree entry limit.
24
+ *
25
+ * **`down()` refuses rather than truncates.** Narrowing back to 64 is only
26
+ * safe while every stored identifier still fits; once a long SKU has been
27
+ * imported, silently cutting it would corrupt the identity of a real product
28
+ * and could collide two of them. The reversal therefore asserts the
29
+ * precondition first and raises a message naming the offending table if it
30
+ * does not hold, leaving the operator to clean up deliberately.
31
+ */
32
+ export declare class Migration20260804T152604CatalogWidenProductSku extends Migration {
33
+ up(): Promise<void>;
34
+ down(): Promise<void>;
35
+ }
36
+ //# sourceMappingURL=20260804T152604_catalog_widen_product_sku.d.ts.map