@hed-hog/catalog 0.0.292 → 0.0.294

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 (65) hide show
  1. package/README.md +409 -379
  2. package/dist/catalog-resource.config.d.ts.map +1 -1
  3. package/dist/catalog-resource.config.js +51 -24
  4. package/dist/catalog-resource.config.js.map +1 -1
  5. package/dist/catalog.controller.d.ts +420 -0
  6. package/dist/catalog.controller.d.ts.map +1 -1
  7. package/dist/catalog.controller.js +98 -0
  8. package/dist/catalog.controller.js.map +1 -1
  9. package/dist/catalog.module.d.ts.map +1 -1
  10. package/dist/catalog.module.js +5 -1
  11. package/dist/catalog.module.js.map +1 -1
  12. package/dist/catalog.service.d.ts +216 -1
  13. package/dist/catalog.service.d.ts.map +1 -1
  14. package/dist/catalog.service.js +1111 -5
  15. package/dist/catalog.service.js.map +1 -1
  16. package/hedhog/data/catalog_attribute.yaml +202 -0
  17. package/hedhog/data/catalog_attribute_option.yaml +109 -0
  18. package/hedhog/data/catalog_category.yaml +47 -0
  19. package/hedhog/data/catalog_category_attribute.yaml +209 -0
  20. package/hedhog/data/menu.yaml +163 -129
  21. package/hedhog/data/role.yaml +7 -7
  22. package/hedhog/data/route.yaml +75 -11
  23. package/hedhog/frontend/app/[resource]/page.tsx.ejs +391 -33
  24. package/hedhog/frontend/app/_components/catalog-ai-form-assist-dialog.tsx.ejs +340 -0
  25. package/hedhog/frontend/app/_components/catalog-resource-form-sheet.tsx.ejs +907 -92
  26. package/hedhog/frontend/app/_lib/catalog-resources.tsx.ejs +929 -1161
  27. package/hedhog/frontend/messages/en.json +389 -299
  28. package/hedhog/frontend/messages/pt.json +389 -299
  29. package/hedhog/table/catalog_affiliate_program.yaml +41 -41
  30. package/hedhog/table/catalog_attribute.yaml +23 -8
  31. package/hedhog/table/catalog_attribute_group.yaml +18 -18
  32. package/hedhog/table/catalog_attribute_option.yaml +40 -0
  33. package/hedhog/table/catalog_brand.yaml +34 -34
  34. package/hedhog/table/catalog_category.yaml +40 -0
  35. package/hedhog/table/catalog_category_attribute.yaml +18 -12
  36. package/hedhog/table/catalog_click_event.yaml +50 -50
  37. package/hedhog/table/catalog_comparison.yaml +46 -49
  38. package/hedhog/table/catalog_comparison_highlight.yaml +39 -39
  39. package/hedhog/table/catalog_comparison_item.yaml +30 -30
  40. package/hedhog/table/catalog_content_relation.yaml +42 -42
  41. package/hedhog/table/catalog_import_run.yaml +33 -33
  42. package/hedhog/table/catalog_import_source.yaml +24 -24
  43. package/hedhog/table/catalog_merchant.yaml +29 -29
  44. package/hedhog/table/catalog_offer.yaml +83 -83
  45. package/hedhog/table/catalog_price_history.yaml +34 -34
  46. package/hedhog/table/catalog_product.yaml +53 -51
  47. package/hedhog/table/catalog_product_attribute_value.yaml +43 -30
  48. package/hedhog/table/catalog_product_category.yaml +16 -16
  49. package/hedhog/table/catalog_product_image.yaml +34 -34
  50. package/hedhog/table/catalog_product_score.yaml +38 -38
  51. package/hedhog/table/catalog_product_site.yaml +47 -47
  52. package/hedhog/table/catalog_product_tag.yaml +19 -19
  53. package/hedhog/table/catalog_score_criterion.yaml +37 -20
  54. package/hedhog/table/catalog_seo_page_rule.yaml +43 -43
  55. package/hedhog/table/catalog_similarity_rule.yaml +27 -14
  56. package/hedhog/table/catalog_site.yaml +35 -27
  57. package/hedhog/table/catalog_site_category.yaml +17 -17
  58. package/package.json +6 -6
  59. package/src/catalog-resource.config.ts +132 -105
  60. package/src/catalog.controller.ts +112 -45
  61. package/src/catalog.module.ts +5 -1
  62. package/src/catalog.service.ts +1569 -56
  63. package/src/index.ts +1 -1
  64. package/src/language/en.json +4 -4
  65. package/src/language/pt.json +4 -4
@@ -1,26 +1,43 @@
1
- - icon: boxes
2
- name:
3
- en: Catalog
4
- pt: Catalogo
5
- slug: /catalog
6
- order: 70
7
- relations:
8
- role:
9
- - where:
10
- slug: admin
11
- - where:
12
- slug: admin-catalog
13
-
1
+ - icon: boxes
2
+ name:
3
+ en: Catalog
4
+ pt: Catalogo
5
+ slug: /catalog
6
+ order: 70
7
+ relations:
8
+ role:
9
+ - where:
10
+ slug: admin
11
+ - where:
12
+ slug: admin-catalog
13
+
14
+ - menu_id:
15
+ where:
16
+ slug: /catalog
17
+ icon: layout-dashboard
18
+ url: /catalog/dashboard
19
+ name:
20
+ en: Dashboard
21
+ pt: Dashboard
22
+ slug: /catalog/dashboard
23
+ order: 71
24
+ relations:
25
+ role:
26
+ - where:
27
+ slug: admin
28
+ - where:
29
+ slug: admin-catalog
30
+
14
31
  - menu_id:
15
32
  where:
16
33
  slug: /catalog
17
- icon: layout-dashboard
18
- url: /catalog/dashboard
34
+ icon: folders
35
+ url: /catalog/categories
19
36
  name:
20
- en: Dashboard
21
- pt: Dashboard
22
- slug: /catalog/dashboard
23
- order: 71
37
+ en: Categories
38
+ pt: Categorias
39
+ slug: /catalog/categories
40
+ order: 72
24
41
  relations:
25
42
  role:
26
43
  - where:
@@ -37,75 +54,75 @@
37
54
  en: Brands
38
55
  pt: Marcas
39
56
  slug: /catalog/brands
40
- order: 72
57
+ order: 73
41
58
  relations:
42
59
  role:
43
60
  - where:
44
61
  slug: admin
45
- - where:
46
- slug: admin-catalog
47
-
48
- - menu_id:
49
- where:
50
- slug: /catalog
62
+ - where:
63
+ slug: admin-catalog
64
+
65
+ - menu_id:
66
+ where:
67
+ slug: /catalog
51
68
  icon: globe
52
69
  url: /catalog/sites
53
70
  name:
54
71
  en: Sites
55
72
  pt: Sites
56
73
  slug: /catalog/sites
57
- order: 73
58
- relations:
59
- role:
60
- - where:
61
- slug: admin
62
- - where:
63
- slug: admin-catalog
64
-
65
- - menu_id:
66
- where:
67
- slug: /catalog
74
+ order: 74
75
+ relations:
76
+ role:
77
+ - where:
78
+ slug: admin
79
+ - where:
80
+ slug: admin-catalog
81
+
82
+ - menu_id:
83
+ where:
84
+ slug: /catalog
68
85
  icon: package-search
69
86
  url: /catalog/products
70
87
  name:
71
88
  en: Products
72
89
  pt: Produtos
73
90
  slug: /catalog/products
74
- order: 74
75
- relations:
76
- role:
77
- - where:
78
- slug: admin
79
- - where:
80
- slug: admin-catalog
81
-
82
- - menu_id:
83
- where:
84
- slug: /catalog
91
+ order: 75
92
+ relations:
93
+ role:
94
+ - where:
95
+ slug: admin
96
+ - where:
97
+ slug: admin-catalog
98
+
99
+ - menu_id:
100
+ where:
101
+ slug: /catalog
85
102
  icon: layers-3
86
103
  url: /catalog/attribute-groups
87
104
  name:
88
105
  en: Attribute Groups
89
106
  pt: Grupos de atributos
90
107
  slug: /catalog/attribute-groups
91
- order: 75
92
- relations:
93
- role:
94
- - where:
95
- slug: admin
96
- - where:
97
- slug: admin-catalog
98
-
99
- - menu_id:
100
- where:
101
- slug: /catalog
108
+ order: 76
109
+ relations:
110
+ role:
111
+ - where:
112
+ slug: admin
113
+ - where:
114
+ slug: admin-catalog
115
+
116
+ - menu_id:
117
+ where:
118
+ slug: /catalog
102
119
  icon: tags
103
120
  url: /catalog/attributes
104
121
  name:
105
122
  en: Attributes
106
123
  pt: Atributos
107
124
  slug: /catalog/attributes
108
- order: 76
125
+ order: 77
109
126
  relations:
110
127
  role:
111
128
  - where:
@@ -116,118 +133,135 @@
116
133
  - menu_id:
117
134
  where:
118
135
  slug: /catalog
136
+ icon: list-filter
137
+ url: /catalog/attribute-options
138
+ name:
139
+ en: Attribute Options
140
+ pt: Opcoes de atributos
141
+ slug: /catalog/attribute-options
142
+ order: 78
143
+ relations:
144
+ role:
145
+ - where:
146
+ slug: admin
147
+ - where:
148
+ slug: admin-catalog
149
+
150
+ - menu_id:
151
+ where:
152
+ slug: /catalog
119
153
  icon: badge-percent
120
154
  url: /catalog/category-attributes
121
155
  name:
122
156
  en: Category Attributes
123
157
  pt: Atributos por categoria
124
158
  slug: /catalog/category-attributes
125
- order: 77
126
- relations:
127
- role:
128
- - where:
129
- slug: admin
130
- - where:
131
- slug: admin-catalog
132
-
133
- - menu_id:
134
- where:
135
- slug: /catalog
159
+ order: 79
160
+ relations:
161
+ role:
162
+ - where:
163
+ slug: admin
164
+ - where:
165
+ slug: admin-catalog
166
+
167
+ - menu_id:
168
+ where:
169
+ slug: /catalog
136
170
  icon: scale
137
171
  url: /catalog/comparisons
138
172
  name:
139
173
  en: Comparisons
140
174
  pt: Comparacoes
141
175
  slug: /catalog/comparisons
142
- order: 78
143
- relations:
144
- role:
145
- - where:
146
- slug: admin
147
- - where:
148
- slug: admin-catalog
149
-
150
- - menu_id:
151
- where:
152
- slug: /catalog
176
+ order: 80
177
+ relations:
178
+ role:
179
+ - where:
180
+ slug: admin
181
+ - where:
182
+ slug: admin-catalog
183
+
184
+ - menu_id:
185
+ where:
186
+ slug: /catalog
153
187
  icon: shopping-cart
154
188
  url: /catalog/offers
155
189
  name:
156
190
  en: Offers
157
191
  pt: Ofertas
158
192
  slug: /catalog/offers
159
- order: 79
160
- relations:
161
- role:
162
- - where:
163
- slug: admin
164
- - where:
165
- slug: admin-catalog
166
-
167
- - menu_id:
168
- where:
169
- slug: /catalog
193
+ order: 81
194
+ relations:
195
+ role:
196
+ - where:
197
+ slug: admin
198
+ - where:
199
+ slug: admin-catalog
200
+
201
+ - menu_id:
202
+ where:
203
+ slug: /catalog
170
204
  icon: store
171
205
  url: /catalog/merchants
172
206
  name:
173
207
  en: Merchants
174
208
  pt: Lojistas
175
209
  slug: /catalog/merchants
176
- order: 80
177
- relations:
178
- role:
179
- - where:
180
- slug: admin
181
- - where:
182
- slug: admin-catalog
183
-
184
- - menu_id:
185
- where:
186
- slug: /catalog
210
+ order: 82
211
+ relations:
212
+ role:
213
+ - where:
214
+ slug: admin
215
+ - where:
216
+ slug: admin-catalog
217
+
218
+ - menu_id:
219
+ where:
220
+ slug: /catalog
187
221
  icon: building-2
188
222
  url: /catalog/affiliate-programs
189
223
  name:
190
224
  en: Affiliate Programs
191
225
  pt: Programas de afiliacao
192
226
  slug: /catalog/affiliate-programs
193
- order: 81
194
- relations:
195
- role:
196
- - where:
197
- slug: admin
198
- - where:
199
- slug: admin-catalog
200
-
201
- - menu_id:
202
- where:
203
- slug: /catalog
227
+ order: 83
228
+ relations:
229
+ role:
230
+ - where:
231
+ slug: admin
232
+ - where:
233
+ slug: admin-catalog
234
+
235
+ - menu_id:
236
+ where:
237
+ slug: /catalog
204
238
  icon: search-code
205
239
  url: /catalog/seo-rules
206
240
  name:
207
241
  en: SEO Rules
208
242
  pt: Regras de SEO
209
243
  slug: /catalog/seo-rules
210
- order: 82
211
- relations:
212
- role:
213
- - where:
214
- slug: admin
215
- - where:
216
- slug: admin-catalog
217
-
218
- - menu_id:
219
- where:
220
- slug: /catalog
244
+ order: 84
245
+ relations:
246
+ role:
247
+ - where:
248
+ slug: admin
249
+ - where:
250
+ slug: admin-catalog
251
+
252
+ - menu_id:
253
+ where:
254
+ slug: /catalog
221
255
  icon: package-plus
222
256
  url: /catalog/import-sources
223
257
  name:
224
258
  en: Import Sources
225
259
  pt: Fontes de importacao
226
260
  slug: /catalog/import-sources
227
- order: 83
261
+ order: 85
228
262
  relations:
229
263
  role:
230
264
  - where:
231
265
  slug: admin
232
- - where:
233
- slug: admin-catalog
266
+ - where:
267
+ slug: admin-catalog
@@ -1,7 +1,7 @@
1
- - slug: admin-catalog
2
- name:
3
- en: Catalog Administrator
4
- pt: Administrador de Catálogo
5
- description:
6
- en: Administrator with access to catalog, comparisons, offers and SEO rules.
7
- pt: Administrador com acesso ao catálogo, comparações, ofertas e regras de SEO.
1
+ - slug: admin-catalog
2
+ name:
3
+ en: Catalog Administrator
4
+ pt: Administrador de Catálogo
5
+ description:
6
+ en: Administrator with access to catalog, comparisons, offers and SEO rules.
7
+ pt: Administrador com acesso ao catálogo, comparações, ofertas e regras de SEO.
@@ -1,4 +1,52 @@
1
- - url: /catalog/:resource
1
+ - url: /catalog/:resource
2
+ method: GET
3
+ relations:
4
+ role:
5
+ - where:
6
+ slug: admin
7
+ - where:
8
+ slug: admin-catalog
9
+ - url: /catalog/:resource
10
+ method: POST
11
+ relations:
12
+ role:
13
+ - where:
14
+ slug: admin
15
+ - where:
16
+ slug: admin-catalog
17
+ - url: /catalog/:resource/stats
18
+ method: GET
19
+ relations:
20
+ role:
21
+ - where:
22
+ slug: admin
23
+ - where:
24
+ slug: admin-catalog
25
+ - url: /catalog/:resource/:id
26
+ method: GET
27
+ relations:
28
+ role:
29
+ - where:
30
+ slug: admin
31
+ - where:
32
+ slug: admin-catalog
33
+ - url: /catalog/:resource/:id
34
+ method: PATCH
35
+ relations:
36
+ role:
37
+ - where:
38
+ slug: admin
39
+ - where:
40
+ slug: admin-catalog
41
+ - url: /catalog/:resource/:id
42
+ method: DELETE
43
+ relations:
44
+ role:
45
+ - where:
46
+ slug: admin
47
+ - where:
48
+ slug: admin-catalog
49
+ - url: /catalog/products/:id/images
2
50
  method: GET
3
51
  relations:
4
52
  role:
@@ -6,15 +54,15 @@
6
54
  slug: admin
7
55
  - where:
8
56
  slug: admin-catalog
9
- - url: /catalog/:resource
10
- method: POST
57
+ - url: /catalog/categories/tree
58
+ method: GET
11
59
  relations:
12
60
  role:
13
61
  - where:
14
62
  slug: admin
15
63
  - where:
16
64
  slug: admin-catalog
17
- - url: /catalog/:resource/stats
65
+ - url: /catalog/categories/:id/attributes
18
66
  method: GET
19
67
  relations:
20
68
  role:
@@ -22,7 +70,7 @@
22
70
  slug: admin
23
71
  - where:
24
72
  slug: admin-catalog
25
- - url: /catalog/:resource/:id
73
+ - url: /catalog/products/:id/attributes
26
74
  method: GET
27
75
  relations:
28
76
  role:
@@ -30,24 +78,40 @@
30
78
  slug: admin
31
79
  - where:
32
80
  slug: admin-catalog
33
- - url: /catalog/:resource/:id
34
- method: PATCH
81
+ - url: /catalog/products/:id/structured
82
+ method: GET
35
83
  relations:
36
84
  role:
37
85
  - where:
38
86
  slug: admin
39
87
  - where:
40
88
  slug: admin-catalog
41
- - url: /catalog/:resource/:id
42
- method: DELETE
89
+ - url: /catalog/products/:id/comparison-payload
90
+ method: GET
43
91
  relations:
44
92
  role:
45
93
  - where:
46
94
  slug: admin
47
95
  - where:
48
96
  slug: admin-catalog
49
- - url: /catalog/products/:id/images
50
- method: GET
97
+ - url: /catalog/forms/:resource/ai-assist
98
+ method: POST
99
+ relations:
100
+ role:
101
+ - where:
102
+ slug: admin
103
+ - where:
104
+ slug: admin-catalog
105
+ - url: /catalog/products/:id/attributes
106
+ method: PUT
107
+ relations:
108
+ role:
109
+ - where:
110
+ slug: admin
111
+ - where:
112
+ slug: admin-catalog
113
+ - url: /catalog/products/:id/materialize-snapshots
114
+ method: POST
51
115
  relations:
52
116
  role:
53
117
  - where: