From 52d58d05eb42972f803078d1a197061c49b2c7d7 Mon Sep 17 00:00:00 2001 From: Arina Yakovenko Date: Fri, 17 Apr 2026 08:04:21 +0200 Subject: [PATCH] fix: add product page --- i18n/migrations/20260302163100_routes.sql | 25 ++++++++++++++++++- .../20260302163123_create_tables_data.sql | 4 ++- 2 files changed, 27 insertions(+), 2 deletions(-) diff --git a/i18n/migrations/20260302163100_routes.sql b/i18n/migrations/20260302163100_routes.sql index bd1e790..710262f 100644 --- a/i18n/migrations/20260302163100_routes.sql +++ b/i18n/migrations/20260302163100_routes.sql @@ -71,7 +71,8 @@ INSERT IGNORE INTO `b2b_routes` (`id`, `name`, `path`, `component`, `meta`, `act (20, 'customer-products', 'products', '/components/customer/PageProducts.vue', '{ "guest":true, "name": "Products" }', 1), (21, 'customer-product-details', 'products/:product_id', '/components/customer/PageProduct.vue', '{ "guest":true, "name": "Products" }', 1), (22, 'customer-page-carts', 'carts', '/components/customer/PageCarts.vue', '{ "guest":true, "name": "Carts" }', 1), -(24, 'customer-search-products', 'search-products', '/components/customer/PageSearchProducts.vue', '{ "guest":true, "name": "Carts" }', 1); +(24, 'customer-search-products', 'search-products', '/components/customer/PageSearchProducts.vue', '{ "guest":true, "name": "Carts" }', 1), +(25, 'admin-add-product', 'add-product', '/components/admin/AddProduct.vue', '{ "guest":true, "name": "Add Product" }', 1); CREATE TABLE IF NOT EXISTS b2b_top_menu ( menu_id INT AUTO_INCREMENT NOT NULL, @@ -309,6 +310,28 @@ INSERT IGNORE INTO `b2b_top_menu` (`menu_id`, `label`, `parent_id`, `params`, `a "locale": "" } } +}', 1, 1), +(18, '{ + "name": "admin-add-product", + "trans": { + "pl": { + "label": "Dodaj produkt" + }, + "en": { + "label": "Add Product" + }, + "de": { + "label": "Produkt hinzufügen" + } + }, + "icon": "proicons:cart1" +}', 1, '{ + "route": { + "name": "admin-add-product", + "params": { + "locale": "" + } + } }', 1, 1); diff --git a/i18n/migrations/20260302163123_create_tables_data.sql b/i18n/migrations/20260302163123_create_tables_data.sql index 8593b29..3a554ba 100644 --- a/i18n/migrations/20260302163123_create_tables_data.sql +++ b/i18n/migrations/20260302163123_create_tables_data.sql @@ -115,5 +115,7 @@ INSERT INTO `b2b_route_roles` (`route_id`, `role_id`) VALUES (20, '1'), (21, '1'), (22, '1'), -(24, '1'); +(24, '1'), +(25, '2'), +(25, '3'); -- +goose Down \ No newline at end of file