@hed-hog/catalog 0.0.293 → 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.
- package/README.md +409 -379
- package/dist/catalog-resource.config.d.ts.map +1 -1
- package/dist/catalog-resource.config.js +51 -24
- package/dist/catalog-resource.config.js.map +1 -1
- package/dist/catalog.controller.d.ts +420 -0
- package/dist/catalog.controller.d.ts.map +1 -1
- package/dist/catalog.controller.js +98 -0
- package/dist/catalog.controller.js.map +1 -1
- package/dist/catalog.module.d.ts.map +1 -1
- package/dist/catalog.module.js +5 -1
- package/dist/catalog.module.js.map +1 -1
- package/dist/catalog.service.d.ts +216 -1
- package/dist/catalog.service.d.ts.map +1 -1
- package/dist/catalog.service.js +1111 -5
- package/dist/catalog.service.js.map +1 -1
- package/hedhog/data/catalog_attribute.yaml +202 -0
- package/hedhog/data/catalog_attribute_option.yaml +109 -0
- package/hedhog/data/catalog_category.yaml +47 -0
- package/hedhog/data/catalog_category_attribute.yaml +209 -0
- package/hedhog/data/menu.yaml +133 -99
- package/hedhog/data/route.yaml +72 -8
- package/hedhog/frontend/app/[resource]/page.tsx.ejs +391 -33
- package/hedhog/frontend/app/_components/catalog-ai-form-assist-dialog.tsx.ejs +340 -0
- package/hedhog/frontend/app/_components/catalog-resource-form-sheet.tsx.ejs +907 -92
- package/hedhog/frontend/app/_lib/catalog-resources.tsx.ejs +929 -1161
- package/hedhog/frontend/messages/en.json +389 -299
- package/hedhog/frontend/messages/pt.json +389 -299
- package/hedhog/table/catalog_attribute.yaml +67 -52
- package/hedhog/table/catalog_attribute_option.yaml +40 -0
- package/hedhog/table/catalog_category.yaml +40 -0
- package/hedhog/table/catalog_category_attribute.yaml +37 -31
- package/hedhog/table/catalog_comparison.yaml +19 -22
- package/hedhog/table/catalog_product.yaml +30 -28
- package/hedhog/table/catalog_product_attribute_value.yaml +44 -31
- package/hedhog/table/catalog_product_category.yaml +13 -13
- package/hedhog/table/catalog_score_criterion.yaml +42 -25
- package/hedhog/table/catalog_seo_page_rule.yaml +10 -10
- package/hedhog/table/catalog_similarity_rule.yaml +33 -20
- package/hedhog/table/catalog_site.yaml +21 -13
- package/hedhog/table/catalog_site_category.yaml +12 -12
- package/package.json +6 -6
- package/src/catalog-resource.config.ts +132 -105
- package/src/catalog.controller.ts +91 -24
- package/src/catalog.module.ts +16 -12
- package/src/catalog.service.ts +1569 -56
package/hedhog/data/menu.yaml
CHANGED
|
@@ -28,33 +28,50 @@
|
|
|
28
28
|
- where:
|
|
29
29
|
slug: admin-catalog
|
|
30
30
|
|
|
31
|
-
- menu_id:
|
|
32
|
-
where:
|
|
33
|
-
slug: /catalog
|
|
34
|
-
icon:
|
|
35
|
-
url: /catalog/
|
|
36
|
-
name:
|
|
37
|
-
en:
|
|
38
|
-
pt:
|
|
39
|
-
slug: /catalog/
|
|
40
|
-
order: 72
|
|
41
|
-
relations:
|
|
42
|
-
role:
|
|
43
|
-
- where:
|
|
44
|
-
slug: admin
|
|
31
|
+
- menu_id:
|
|
32
|
+
where:
|
|
33
|
+
slug: /catalog
|
|
34
|
+
icon: folders
|
|
35
|
+
url: /catalog/categories
|
|
36
|
+
name:
|
|
37
|
+
en: Categories
|
|
38
|
+
pt: Categorias
|
|
39
|
+
slug: /catalog/categories
|
|
40
|
+
order: 72
|
|
41
|
+
relations:
|
|
42
|
+
role:
|
|
43
|
+
- where:
|
|
44
|
+
slug: admin
|
|
45
|
+
- where:
|
|
46
|
+
slug: admin-catalog
|
|
47
|
+
|
|
48
|
+
- menu_id:
|
|
49
|
+
where:
|
|
50
|
+
slug: /catalog
|
|
51
|
+
icon: factory
|
|
52
|
+
url: /catalog/brands
|
|
53
|
+
name:
|
|
54
|
+
en: Brands
|
|
55
|
+
pt: Marcas
|
|
56
|
+
slug: /catalog/brands
|
|
57
|
+
order: 73
|
|
58
|
+
relations:
|
|
59
|
+
role:
|
|
60
|
+
- where:
|
|
61
|
+
slug: admin
|
|
45
62
|
- where:
|
|
46
63
|
slug: admin-catalog
|
|
47
64
|
|
|
48
65
|
- menu_id:
|
|
49
66
|
where:
|
|
50
67
|
slug: /catalog
|
|
51
|
-
icon: globe
|
|
52
|
-
url: /catalog/sites
|
|
53
|
-
name:
|
|
54
|
-
en: Sites
|
|
55
|
-
pt: Sites
|
|
56
|
-
slug: /catalog/sites
|
|
57
|
-
order:
|
|
68
|
+
icon: globe
|
|
69
|
+
url: /catalog/sites
|
|
70
|
+
name:
|
|
71
|
+
en: Sites
|
|
72
|
+
pt: Sites
|
|
73
|
+
slug: /catalog/sites
|
|
74
|
+
order: 74
|
|
58
75
|
relations:
|
|
59
76
|
role:
|
|
60
77
|
- where:
|
|
@@ -65,13 +82,13 @@
|
|
|
65
82
|
- menu_id:
|
|
66
83
|
where:
|
|
67
84
|
slug: /catalog
|
|
68
|
-
icon: package-search
|
|
69
|
-
url: /catalog/products
|
|
70
|
-
name:
|
|
71
|
-
en: Products
|
|
72
|
-
pt: Produtos
|
|
73
|
-
slug: /catalog/products
|
|
74
|
-
order:
|
|
85
|
+
icon: package-search
|
|
86
|
+
url: /catalog/products
|
|
87
|
+
name:
|
|
88
|
+
en: Products
|
|
89
|
+
pt: Produtos
|
|
90
|
+
slug: /catalog/products
|
|
91
|
+
order: 75
|
|
75
92
|
relations:
|
|
76
93
|
role:
|
|
77
94
|
- where:
|
|
@@ -82,13 +99,13 @@
|
|
|
82
99
|
- menu_id:
|
|
83
100
|
where:
|
|
84
101
|
slug: /catalog
|
|
85
|
-
icon: layers-3
|
|
86
|
-
url: /catalog/attribute-groups
|
|
87
|
-
name:
|
|
88
|
-
en: Attribute Groups
|
|
89
|
-
pt: Grupos de atributos
|
|
90
|
-
slug: /catalog/attribute-groups
|
|
91
|
-
order:
|
|
102
|
+
icon: layers-3
|
|
103
|
+
url: /catalog/attribute-groups
|
|
104
|
+
name:
|
|
105
|
+
en: Attribute Groups
|
|
106
|
+
pt: Grupos de atributos
|
|
107
|
+
slug: /catalog/attribute-groups
|
|
108
|
+
order: 76
|
|
92
109
|
relations:
|
|
93
110
|
role:
|
|
94
111
|
- where:
|
|
@@ -99,30 +116,47 @@
|
|
|
99
116
|
- menu_id:
|
|
100
117
|
where:
|
|
101
118
|
slug: /catalog
|
|
102
|
-
icon: tags
|
|
103
|
-
url: /catalog/attributes
|
|
104
|
-
name:
|
|
105
|
-
en: Attributes
|
|
106
|
-
pt: Atributos
|
|
107
|
-
slug: /catalog/attributes
|
|
108
|
-
order:
|
|
109
|
-
relations:
|
|
110
|
-
role:
|
|
111
|
-
- where:
|
|
112
|
-
slug: admin
|
|
119
|
+
icon: tags
|
|
120
|
+
url: /catalog/attributes
|
|
121
|
+
name:
|
|
122
|
+
en: Attributes
|
|
123
|
+
pt: Atributos
|
|
124
|
+
slug: /catalog/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
|
|
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
|
|
113
147
|
- where:
|
|
114
148
|
slug: admin-catalog
|
|
115
149
|
|
|
116
150
|
- menu_id:
|
|
117
151
|
where:
|
|
118
152
|
slug: /catalog
|
|
119
|
-
icon: badge-percent
|
|
120
|
-
url: /catalog/category-attributes
|
|
121
|
-
name:
|
|
122
|
-
en: Category Attributes
|
|
123
|
-
pt: Atributos por categoria
|
|
124
|
-
slug: /catalog/category-attributes
|
|
125
|
-
order:
|
|
153
|
+
icon: badge-percent
|
|
154
|
+
url: /catalog/category-attributes
|
|
155
|
+
name:
|
|
156
|
+
en: Category Attributes
|
|
157
|
+
pt: Atributos por categoria
|
|
158
|
+
slug: /catalog/category-attributes
|
|
159
|
+
order: 79
|
|
126
160
|
relations:
|
|
127
161
|
role:
|
|
128
162
|
- where:
|
|
@@ -133,13 +167,13 @@
|
|
|
133
167
|
- menu_id:
|
|
134
168
|
where:
|
|
135
169
|
slug: /catalog
|
|
136
|
-
icon: scale
|
|
137
|
-
url: /catalog/comparisons
|
|
138
|
-
name:
|
|
139
|
-
en: Comparisons
|
|
140
|
-
pt: Comparacoes
|
|
141
|
-
slug: /catalog/comparisons
|
|
142
|
-
order:
|
|
170
|
+
icon: scale
|
|
171
|
+
url: /catalog/comparisons
|
|
172
|
+
name:
|
|
173
|
+
en: Comparisons
|
|
174
|
+
pt: Comparacoes
|
|
175
|
+
slug: /catalog/comparisons
|
|
176
|
+
order: 80
|
|
143
177
|
relations:
|
|
144
178
|
role:
|
|
145
179
|
- where:
|
|
@@ -150,13 +184,13 @@
|
|
|
150
184
|
- menu_id:
|
|
151
185
|
where:
|
|
152
186
|
slug: /catalog
|
|
153
|
-
icon: shopping-cart
|
|
154
|
-
url: /catalog/offers
|
|
155
|
-
name:
|
|
156
|
-
en: Offers
|
|
157
|
-
pt: Ofertas
|
|
158
|
-
slug: /catalog/offers
|
|
159
|
-
order:
|
|
187
|
+
icon: shopping-cart
|
|
188
|
+
url: /catalog/offers
|
|
189
|
+
name:
|
|
190
|
+
en: Offers
|
|
191
|
+
pt: Ofertas
|
|
192
|
+
slug: /catalog/offers
|
|
193
|
+
order: 81
|
|
160
194
|
relations:
|
|
161
195
|
role:
|
|
162
196
|
- where:
|
|
@@ -167,13 +201,13 @@
|
|
|
167
201
|
- menu_id:
|
|
168
202
|
where:
|
|
169
203
|
slug: /catalog
|
|
170
|
-
icon: store
|
|
171
|
-
url: /catalog/merchants
|
|
172
|
-
name:
|
|
173
|
-
en: Merchants
|
|
174
|
-
pt: Lojistas
|
|
175
|
-
slug: /catalog/merchants
|
|
176
|
-
order:
|
|
204
|
+
icon: store
|
|
205
|
+
url: /catalog/merchants
|
|
206
|
+
name:
|
|
207
|
+
en: Merchants
|
|
208
|
+
pt: Lojistas
|
|
209
|
+
slug: /catalog/merchants
|
|
210
|
+
order: 82
|
|
177
211
|
relations:
|
|
178
212
|
role:
|
|
179
213
|
- where:
|
|
@@ -184,13 +218,13 @@
|
|
|
184
218
|
- menu_id:
|
|
185
219
|
where:
|
|
186
220
|
slug: /catalog
|
|
187
|
-
icon: building-2
|
|
188
|
-
url: /catalog/affiliate-programs
|
|
189
|
-
name:
|
|
190
|
-
en: Affiliate Programs
|
|
191
|
-
pt: Programas de afiliacao
|
|
192
|
-
slug: /catalog/affiliate-programs
|
|
193
|
-
order:
|
|
221
|
+
icon: building-2
|
|
222
|
+
url: /catalog/affiliate-programs
|
|
223
|
+
name:
|
|
224
|
+
en: Affiliate Programs
|
|
225
|
+
pt: Programas de afiliacao
|
|
226
|
+
slug: /catalog/affiliate-programs
|
|
227
|
+
order: 83
|
|
194
228
|
relations:
|
|
195
229
|
role:
|
|
196
230
|
- where:
|
|
@@ -201,13 +235,13 @@
|
|
|
201
235
|
- menu_id:
|
|
202
236
|
where:
|
|
203
237
|
slug: /catalog
|
|
204
|
-
icon: search-code
|
|
205
|
-
url: /catalog/seo-rules
|
|
206
|
-
name:
|
|
207
|
-
en: SEO Rules
|
|
208
|
-
pt: Regras de SEO
|
|
209
|
-
slug: /catalog/seo-rules
|
|
210
|
-
order:
|
|
238
|
+
icon: search-code
|
|
239
|
+
url: /catalog/seo-rules
|
|
240
|
+
name:
|
|
241
|
+
en: SEO Rules
|
|
242
|
+
pt: Regras de SEO
|
|
243
|
+
slug: /catalog/seo-rules
|
|
244
|
+
order: 84
|
|
211
245
|
relations:
|
|
212
246
|
role:
|
|
213
247
|
- where:
|
|
@@ -218,16 +252,16 @@
|
|
|
218
252
|
- menu_id:
|
|
219
253
|
where:
|
|
220
254
|
slug: /catalog
|
|
221
|
-
icon: package-plus
|
|
222
|
-
url: /catalog/import-sources
|
|
223
|
-
name:
|
|
224
|
-
en: Import Sources
|
|
225
|
-
pt: Fontes de importacao
|
|
226
|
-
slug: /catalog/import-sources
|
|
227
|
-
order:
|
|
228
|
-
relations:
|
|
229
|
-
role:
|
|
230
|
-
- where:
|
|
231
|
-
slug: admin
|
|
255
|
+
icon: package-plus
|
|
256
|
+
url: /catalog/import-sources
|
|
257
|
+
name:
|
|
258
|
+
en: Import Sources
|
|
259
|
+
pt: Fontes de importacao
|
|
260
|
+
slug: /catalog/import-sources
|
|
261
|
+
order: 85
|
|
262
|
+
relations:
|
|
263
|
+
role:
|
|
264
|
+
- where:
|
|
265
|
+
slug: admin
|
|
232
266
|
- where:
|
|
233
267
|
slug: admin-catalog
|
package/hedhog/data/route.yaml
CHANGED
|
@@ -46,11 +46,75 @@
|
|
|
46
46
|
slug: admin
|
|
47
47
|
- where:
|
|
48
48
|
slug: admin-catalog
|
|
49
|
-
- url: /catalog/products/:id/images
|
|
50
|
-
method: GET
|
|
51
|
-
relations:
|
|
52
|
-
role:
|
|
53
|
-
- where:
|
|
54
|
-
slug: admin
|
|
55
|
-
- where:
|
|
56
|
-
slug: admin-catalog
|
|
49
|
+
- url: /catalog/products/:id/images
|
|
50
|
+
method: GET
|
|
51
|
+
relations:
|
|
52
|
+
role:
|
|
53
|
+
- where:
|
|
54
|
+
slug: admin
|
|
55
|
+
- where:
|
|
56
|
+
slug: admin-catalog
|
|
57
|
+
- url: /catalog/categories/tree
|
|
58
|
+
method: GET
|
|
59
|
+
relations:
|
|
60
|
+
role:
|
|
61
|
+
- where:
|
|
62
|
+
slug: admin
|
|
63
|
+
- where:
|
|
64
|
+
slug: admin-catalog
|
|
65
|
+
- url: /catalog/categories/:id/attributes
|
|
66
|
+
method: GET
|
|
67
|
+
relations:
|
|
68
|
+
role:
|
|
69
|
+
- where:
|
|
70
|
+
slug: admin
|
|
71
|
+
- where:
|
|
72
|
+
slug: admin-catalog
|
|
73
|
+
- url: /catalog/products/:id/attributes
|
|
74
|
+
method: GET
|
|
75
|
+
relations:
|
|
76
|
+
role:
|
|
77
|
+
- where:
|
|
78
|
+
slug: admin
|
|
79
|
+
- where:
|
|
80
|
+
slug: admin-catalog
|
|
81
|
+
- url: /catalog/products/:id/structured
|
|
82
|
+
method: GET
|
|
83
|
+
relations:
|
|
84
|
+
role:
|
|
85
|
+
- where:
|
|
86
|
+
slug: admin
|
|
87
|
+
- where:
|
|
88
|
+
slug: admin-catalog
|
|
89
|
+
- url: /catalog/products/:id/comparison-payload
|
|
90
|
+
method: GET
|
|
91
|
+
relations:
|
|
92
|
+
role:
|
|
93
|
+
- where:
|
|
94
|
+
slug: admin
|
|
95
|
+
- where:
|
|
96
|
+
slug: admin-catalog
|
|
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
|
|
115
|
+
relations:
|
|
116
|
+
role:
|
|
117
|
+
- where:
|
|
118
|
+
slug: admin
|
|
119
|
+
- where:
|
|
120
|
+
slug: admin-catalog
|