@ozdao/prometheus-framework 0.2.309 → 0.2.310
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/products.server.js +196 -198
- package/dist/products.server.mjs +196 -198
- package/dist/prometheus-framework/src/components/Block/Block.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Block/Block.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/components/Block/Block.vue.js +1 -1
- package/dist/prometheus-framework/src/components/Block/Block.vue.js.map +1 -1
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.cjs +2 -1
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.cjs.map +1 -1
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.js +3 -2
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.js.map +1 -1
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue.cjs +93 -0
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue.js +94 -1
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue.js.map +1 -1
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue2.cjs +0 -93
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue2.cjs.map +1 -1
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue2.js +1 -94
- package/dist/prometheus-framework/src/components/EditImages/EditImages.vue2.js.map +1 -1
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +1 -1
- package/dist/prometheus-framework/src/components/Field/Field.vue.cjs +13 -12
- package/dist/prometheus-framework/src/components/Field/Field.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/components/Field/Field.vue.js +13 -12
- package/dist/prometheus-framework/src/components/Field/Field.vue.js.map +1 -1
- package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/components/layouts/Auth.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/layouts/Auth.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterCode.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterCode.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterPassword.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterPassword.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/Invite.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/Invite.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/Profile.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/Profile.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/ProfileEdit.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/ProfileEdit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/ResetPassword.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/ResetPassword.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignIn.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignIn.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignUp.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignUp.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/sections/ProfileEditCredentials.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/components/sections/ProfileEditCredentials.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/views/middlewares/auth.validation.cjs +1 -0
- package/dist/prometheus-framework/src/modules/auth/views/middlewares/auth.validation.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/middlewares/auth.validation.js +1 -0
- package/dist/prometheus-framework/src/modules/auth/views/middlewares/auth.validation.js.map +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/store/auth.cjs +6 -2
- package/dist/prometheus-framework/src/modules/auth/views/store/auth.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/store/auth.js +6 -2
- package/dist/prometheus-framework/src/modules/auth/views/store/auth.js.map +1 -1
- package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.cjs +3 -5
- package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.js +4 -6
- package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/backoffice/components/partials/Sidebar.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/backoffice/components/partials/Sidebar.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Card.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Card.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +4 -4
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/events/components/pages/Event.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/Event.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +5 -5
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/BlockSearch.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/BlockSearch.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/CardHeader.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/CardHeader.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/BottomNavigationBar.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/BottomNavigationBar.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/BottomNavigationBar.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/BottomNavigationBar.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/Header.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/Header.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/NavigationBar.vue.cjs +5 -5
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/NavigationBar.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/NavigationBar.vue.js +8 -8
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/NavigationBar.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/store/globals.cjs +4 -0
- package/dist/prometheus-framework/src/modules/globals/views/store/globals.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/store/globals.js +4 -0
- package/dist/prometheus-framework/src/modules/globals/views/store/globals.js.map +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationBackoffice.vue.cjs +2 -3
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationBackoffice.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationBackoffice.vue.js +3 -4
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationBackoffice.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTabSection.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTabSection.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/pages/pages.client.cjs +743 -743
- package/dist/prometheus-framework/src/modules/pages/pages.client.js +743 -743
- package/dist/prometheus-framework/src/modules/pages/views/components/blocks/CardPage.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/pages/views/components/blocks/CardPage.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/pages/views/components/pages/PageEdit.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/pages/views/components/pages/PageEdit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/pages/views/components/partials/SidebarPages.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/pages/views/components/partials/SidebarPages.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardProduct.vue.cjs +11 -10
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardProduct.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardProduct.vue.js +11 -10
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardProduct.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs +79 -44
- package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +83 -48
- package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +81 -31
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +91 -41
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +122 -83
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +135 -96
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.cjs +39 -21
- package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.js +51 -33
- package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/CategoriesTree.vue.cjs +96 -0
- package/dist/prometheus-framework/src/modules/products/components/sections/CategoriesTree.vue.cjs.map +1 -0
- package/dist/prometheus-framework/src/modules/products/components/sections/CategoriesTree.vue.js +96 -0
- package/dist/prometheus-framework/src/modules/products/components/sections/CategoriesTree.vue.js.map +1 -0
- package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +22 -8
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +22 -8
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/Filters.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/Filters.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/products.client.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/products.client.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/router/categories.router.cjs +17 -5
- package/dist/prometheus-framework/src/modules/products/router/categories.router.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/router/categories.router.js +17 -5
- package/dist/prometheus-framework/src/modules/products/router/categories.router.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/router/products.router.cjs +1 -12
- package/dist/prometheus-framework/src/modules/products/router/products.router.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/router/products.router.js +1 -12
- package/dist/prometheus-framework/src/modules/products/router/products.router.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/store/categories.cjs +52 -71
- package/dist/prometheus-framework/src/modules/products/store/categories.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/store/categories.js +52 -71
- package/dist/prometheus-framework/src/modules/products/store/categories.js.map +1 -1
- package/dist/prometheus-framework/src/modules/products/store/products.cjs +6 -8
- package/dist/prometheus-framework/src/modules/products/store/products.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/products/store/products.js +6 -8
- package/dist/prometheus-framework/src/modules/products/store/products.js.map +1 -1
- package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/blocks/SpotMemberModify.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/blocks/SpotMemberModify.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/layouts/Spots.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/spots/components/layouts/Spots.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/spots/components/pages/Map.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/pages/Map.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/pages/SpotEdit.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/spots/components/pages/SpotEdit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CardDeposit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CardDeposit.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +3 -3
- package/package.json +1 -1
- package/src/components/Block/Block.vue +1 -1
- package/src/components/EditImages/EditImages.vue +1 -1
- package/src/modules/auth/views/middlewares/auth.validation.js +1 -0
- package/src/modules/auth/views/store/auth.js +6 -2
- package/src/modules/backoffice/components/pages/Dashboard.vue +1 -3
- package/src/modules/globals/views/components/partials/BottomNavigationBar.vue +1 -1
- package/src/modules/globals/views/components/partials/NavigationBar.vue +3 -3
- package/src/modules/globals/views/store/globals.js +5 -0
- package/src/modules/organizations/components/pages/Organization.vue +1 -1
- package/src/modules/organizations/components/pages/OrganizationBackoffice.vue +1 -2
- package/src/modules/products/components/blocks/CardCategory.vue +14 -3
- package/src/modules/products/components/blocks/CardProduct.vue +12 -11
- package/src/modules/products/components/pages/Categories.vue +120 -28
- package/src/modules/products/components/pages/CategoryEdit.vue +206 -151
- package/src/modules/products/components/pages/ProductEdit.vue +107 -69
- package/src/modules/products/components/pages/Products.vue +35 -20
- package/src/modules/products/components/sections/CategoriesTree.vue +102 -0
- package/src/modules/products/components/sections/EditProductInfo.vue +53 -40
- package/src/modules/products/controllers/categories.controller.js +177 -97
- package/src/modules/products/controllers/products.controller.js +4 -2
- package/src/modules/products/models/category.model.js +15 -66
- package/src/modules/products/models/product.model.js +15 -12
- package/src/modules/products/products.client.js +0 -1
- package/src/modules/products/router/categories.router.js +17 -5
- package/src/modules/products/router/products.router.js +0 -12
- package/src/modules/products/routes/categories.routes.js +5 -34
- package/src/modules/products/store/categories.js +69 -83
- package/src/modules/products/store/products.js +6 -8
package/dist/products.server.js
CHANGED
@@ -9,7 +9,13 @@ const queryProcessor = require("./queryProcessor-B3NJuQbL.js");
|
|
9
9
|
const applyOwnershipSchema$1 = ownership_schema.ownership_schema;
|
10
10
|
var product_model = (db) => {
|
11
11
|
const ProductSchema = new db.mongoose.Schema({
|
12
|
-
status: {
|
12
|
+
status: {
|
13
|
+
type: String
|
14
|
+
},
|
15
|
+
listing: {
|
16
|
+
type: String,
|
17
|
+
enum: ["sale", "rent"]
|
18
|
+
},
|
13
19
|
name: { type: String },
|
14
20
|
category: { type: Array },
|
15
21
|
description: { type: String },
|
@@ -24,7 +30,13 @@ var product_model = (db) => {
|
|
24
30
|
value: { type: String }
|
25
31
|
}],
|
26
32
|
// ЗАДАЧА: Нужно отрефачить price, перенести его в default variant
|
27
|
-
price: {
|
33
|
+
price: {
|
34
|
+
type: Number
|
35
|
+
},
|
36
|
+
price_currency: {
|
37
|
+
type: String,
|
38
|
+
default: "$"
|
39
|
+
},
|
28
40
|
prices: { type: Array },
|
29
41
|
//
|
30
42
|
variants: [{
|
@@ -71,16 +83,7 @@ var product_model = (db) => {
|
|
71
83
|
min: [0, "Quantity-based discount cannot be less than 0"],
|
72
84
|
max: [100, "Quantity-based discount cannot be more than 100"]
|
73
85
|
}
|
74
|
-
}]
|
75
|
-
// Refactor
|
76
|
-
owner: {
|
77
|
-
type: db.mongoose.Schema.Types.ObjectId,
|
78
|
-
ref: "User"
|
79
|
-
},
|
80
|
-
organization: {
|
81
|
-
type: db.mongoose.Schema.Types.ObjectId,
|
82
|
-
ref: "Organization"
|
83
|
-
}
|
86
|
+
}]
|
84
87
|
}, {
|
85
88
|
timestamps: {
|
86
89
|
currentTime: () => Date.now()
|
@@ -93,76 +96,26 @@ var product_model = (db) => {
|
|
93
96
|
return Product;
|
94
97
|
};
|
95
98
|
var category_model = (db) => {
|
96
|
-
const
|
97
|
-
name: {
|
98
|
-
type: String,
|
99
|
-
required: true,
|
100
|
-
trim: true
|
101
|
-
},
|
99
|
+
const CategorySchema = new db.mongoose.Schema({
|
100
|
+
name: { type: String, required: true, trim: true },
|
102
101
|
status: {
|
103
102
|
type: String,
|
104
103
|
enum: ["draft", "internal", "published", "removed"],
|
105
104
|
default: "draft",
|
106
105
|
required: true
|
107
106
|
},
|
108
|
-
order: {
|
109
|
-
|
110
|
-
|
111
|
-
},
|
112
|
-
|
113
|
-
type: String,
|
114
|
-
required: true,
|
115
|
-
trim: true
|
116
|
-
},
|
117
|
-
subcategories: {
|
118
|
-
type: Array
|
119
|
-
},
|
120
|
-
localization: {
|
121
|
-
type: Array
|
122
|
-
},
|
123
|
-
filters: {
|
124
|
-
type: Array
|
125
|
-
}
|
126
|
-
// owner: {
|
127
|
-
// type: {
|
128
|
-
// type: String,
|
129
|
-
// required: true
|
130
|
-
// },
|
131
|
-
// target: {
|
132
|
-
// type: mongoose.Schema.Types.ObjectId,
|
133
|
-
// ref: function (value) {
|
134
|
-
// if (this.owner.type === 'user') return 'User';
|
135
|
-
// if (this.owner.type === 'organization') return 'Organization';
|
136
|
-
// },
|
137
|
-
// required: true,
|
138
|
-
// },
|
139
|
-
// },
|
140
|
-
// creator: {
|
141
|
-
// hidden: {
|
142
|
-
// type: Boolean,
|
143
|
-
// required: true
|
144
|
-
// },
|
145
|
-
// type: {
|
146
|
-
// type: String,
|
147
|
-
// required: true
|
148
|
-
// },
|
149
|
-
// target: {
|
150
|
-
// type: mongoose.Schema.Types.ObjectId,
|
151
|
-
// ref: function (value) {
|
152
|
-
// if (this.owner.type === 'user') return 'User';
|
153
|
-
// if (this.owner.type === 'organization') return 'Organization';
|
154
|
-
// },
|
155
|
-
// required: true,
|
156
|
-
// },
|
157
|
-
// }
|
107
|
+
order: { type: Number, required: true },
|
108
|
+
url: { type: String, required: true, trim: true },
|
109
|
+
parent: { type: db.mongoose.Schema.Types.ObjectId, ref: "Category" },
|
110
|
+
localization: { type: Array },
|
111
|
+
filters: { type: Array }
|
158
112
|
}, {
|
159
|
-
timestamps: {
|
160
|
-
currentTime: () => Date.now()
|
161
|
-
}
|
113
|
+
timestamps: { currentTime: () => Date.now() }
|
162
114
|
});
|
163
|
-
|
164
|
-
|
165
|
-
|
115
|
+
CategorySchema.index({ parent: 1 });
|
116
|
+
CategorySchema.index({ "owner.target": 1, "creator.target": 1 });
|
117
|
+
const Category = db.mongoose.model("Category", CategorySchema, "categories");
|
118
|
+
return Category;
|
166
119
|
};
|
167
120
|
const applyOwnershipSchema = ownership_schema.ownership_schema;
|
168
121
|
var leftover_model = (db) => {
|
@@ -214,7 +167,7 @@ var leftover_model = (db) => {
|
|
214
167
|
const Leftover = db.mongoose.model("Leftover", LeftoverSchema);
|
215
168
|
return Leftover;
|
216
169
|
};
|
217
|
-
const ObjectId = require$$0.Types.ObjectId;
|
170
|
+
const ObjectId$1 = require$$0.Types.ObjectId;
|
218
171
|
const OpenAI = require$$3;
|
219
172
|
const openai = new OpenAI({
|
220
173
|
organization: process.env.OPENAI_ORG_KEY,
|
@@ -237,18 +190,18 @@ const controllerFactory$5 = (db) => {
|
|
237
190
|
const Read = async (req, res) => {
|
238
191
|
try {
|
239
192
|
const query = {};
|
240
|
-
if (req.query.
|
241
|
-
query.
|
193
|
+
if (req.query.owner) {
|
194
|
+
query["owner.target"] = new ObjectId$1(req.query.owner);
|
242
195
|
}
|
243
196
|
if (req.query._id) {
|
244
|
-
query._id = new ObjectId(req.query._id);
|
197
|
+
query._id = new ObjectId$1(req.query._id);
|
245
198
|
}
|
246
199
|
if (req.query.status) {
|
247
200
|
query.status = req.query.status;
|
248
201
|
}
|
249
202
|
const categories = req.query.categories?.split(",") || [];
|
250
203
|
if (categories.length) {
|
251
|
-
query.category = { $in: categories.map((cat) => new ObjectId(cat)) };
|
204
|
+
query.category = { $in: categories.map((cat) => new ObjectId$1(cat)) };
|
252
205
|
}
|
253
206
|
const deliveryOptions = req.query.delivery?.split(",") || [];
|
254
207
|
if (deliveryOptions.length) {
|
@@ -411,8 +364,10 @@ const controllerFactory$5 = (db) => {
|
|
411
364
|
{
|
412
365
|
name: req.body.name,
|
413
366
|
status: req.body.status,
|
367
|
+
listing: req.body.listing,
|
414
368
|
description: req.body.description,
|
415
369
|
price: req.body.price,
|
370
|
+
price_currency: req.body.price_currency,
|
416
371
|
sale: req.body.sale,
|
417
372
|
category: req.body.category,
|
418
373
|
images: req.body.images,
|
@@ -551,104 +506,168 @@ var products_routes = function(app, db, allowedOrigins) {
|
|
551
506
|
controller.getProductRecommendation
|
552
507
|
);
|
553
508
|
};
|
509
|
+
var categories_routes = { exports: {} };
|
510
|
+
const ObjectId = require$$0.Types.ObjectId;
|
554
511
|
const controllerFactory$3 = (db) => {
|
555
512
|
const Category = db.category;
|
556
|
-
|
557
|
-
|
558
|
-
|
559
|
-
|
560
|
-
|
561
|
-
|
562
|
-
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
|
513
|
+
return {
|
514
|
+
async read(req, res) {
|
515
|
+
try {
|
516
|
+
let buildTree = function(items) {
|
517
|
+
const itemMap = {};
|
518
|
+
const roots = [];
|
519
|
+
items.forEach((item) => {
|
520
|
+
itemMap[item._id.toString()] = {
|
521
|
+
...item,
|
522
|
+
children: []
|
523
|
+
};
|
524
|
+
});
|
525
|
+
items.forEach((item) => {
|
526
|
+
const itemId = item._id.toString();
|
527
|
+
const parentId = item.parent?._id?.toString();
|
528
|
+
if (parentId && itemMap[parentId]) {
|
529
|
+
itemMap[parentId].children.push(itemMap[itemId]);
|
530
|
+
} else {
|
531
|
+
roots.push(itemMap[itemId]);
|
532
|
+
}
|
533
|
+
});
|
534
|
+
const sortByOrder = (a, b) => {
|
535
|
+
const orderA = a.order ?? Number.MAX_SAFE_INTEGER;
|
536
|
+
const orderB = b.order ?? Number.MAX_SAFE_INTEGER;
|
537
|
+
return orderA - orderB;
|
538
|
+
};
|
539
|
+
const sortChildren = (node) => {
|
540
|
+
if (node.children && node.children.length > 0) {
|
541
|
+
node.children.sort(sortByOrder);
|
542
|
+
node.children.forEach(sortChildren);
|
543
|
+
}
|
544
|
+
};
|
545
|
+
roots.sort(sortByOrder);
|
546
|
+
roots.forEach(sortChildren);
|
547
|
+
return roots;
|
548
|
+
};
|
549
|
+
const {
|
550
|
+
parent,
|
551
|
+
url,
|
552
|
+
search,
|
553
|
+
sort = "order",
|
554
|
+
order = 1,
|
555
|
+
page = 1,
|
556
|
+
limit = 10,
|
557
|
+
excludeChildren = false,
|
558
|
+
rootOnly = false
|
559
|
+
} = req.query;
|
560
|
+
const matchStage = {
|
561
|
+
...req.query.status && { status: req.query.status },
|
562
|
+
...req.query.url && { url: req.query.url },
|
563
|
+
...search && { name: { $regex: search, $options: "i" } },
|
564
|
+
...parent ? { parent: new mongoose.Types.ObjectId(parent) } : {},
|
565
|
+
...rootOnly ? { parent: null } : {}
|
566
|
+
};
|
567
|
+
const pipeline = [
|
568
|
+
{ $match: matchStage },
|
569
|
+
{
|
570
|
+
$graphLookup: {
|
571
|
+
from: "categories",
|
572
|
+
startWith: "$_id",
|
573
|
+
connectFromField: "_id",
|
574
|
+
connectToField: "parent",
|
575
|
+
as: "allDescendants",
|
576
|
+
maxDepth: 10
|
577
|
+
}
|
578
|
+
},
|
579
|
+
{ $sort: { [sort]: order === "asc" ? 1 : -1 } },
|
580
|
+
{ $skip: (page - 1) * limit },
|
581
|
+
{ $limit: Number(limit) }
|
582
|
+
];
|
583
|
+
const flatResults = await Category.aggregate(pipeline);
|
584
|
+
const treeResults = flatResults.map((doc) => {
|
585
|
+
const descendants = doc.allDescendants || [];
|
586
|
+
const allItems = [doc, ...descendants];
|
587
|
+
const tree = buildTree(allItems);
|
588
|
+
return tree.find((node) => node._id.toString() === doc._id.toString());
|
589
|
+
});
|
590
|
+
treeResults.sort((a, b) => {
|
591
|
+
const orderA = a.order ?? Number.MAX_SAFE_INTEGER;
|
592
|
+
const orderB = b.order ?? Number.MAX_SAFE_INTEGER;
|
593
|
+
return orderA - orderB;
|
594
|
+
});
|
595
|
+
res.json(treeResults);
|
596
|
+
} catch (err) {
|
597
|
+
res.status(500).json({ message: err.message });
|
567
598
|
}
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
|
572
|
-
|
573
|
-
|
574
|
-
|
575
|
-
|
576
|
-
|
577
|
-
|
578
|
-
|
579
|
-
|
580
|
-
|
581
|
-
|
599
|
+
},
|
600
|
+
async create(req, res) {
|
601
|
+
try {
|
602
|
+
const highestOrder = await Category.findOne().sort("-order");
|
603
|
+
const order = highestOrder ? highestOrder.order + 1 : 1;
|
604
|
+
const category = new Category({ ...req.body, order });
|
605
|
+
if (req.body.parent) {
|
606
|
+
const parent = await Category.findByIdAndUpdate(
|
607
|
+
req.body.parent,
|
608
|
+
{ $push: { children: category._id } },
|
609
|
+
{ new: true }
|
610
|
+
);
|
611
|
+
if (!parent) throw new Error("Parent category not found");
|
612
|
+
category.parent = parent._id;
|
582
613
|
}
|
583
|
-
|
584
|
-
|
585
|
-
|
586
|
-
|
587
|
-
|
588
|
-
|
589
|
-
|
590
|
-
|
591
|
-
|
592
|
-
|
593
|
-
try {
|
594
|
-
const category = await Category.findOne({ url: req.params.url }).exec();
|
595
|
-
if (!category) {
|
596
|
-
return res.status(404).send({ message: "Category not found." });
|
597
|
-
}
|
598
|
-
res.status(200).send(category);
|
599
|
-
} catch (err) {
|
600
|
-
res.status(500).send({ message: err });
|
601
|
-
}
|
602
|
-
};
|
603
|
-
const addCategory = async (req, res) => {
|
604
|
-
try {
|
605
|
-
const highestOrderDoc = await Category.findOne().sort("-order");
|
606
|
-
req.body.order = highestOrderDoc ? highestOrderDoc.order + 1 : 1;
|
607
|
-
const category = await Category.create(req.body);
|
608
|
-
if (!category) {
|
609
|
-
return res.status(404).send({ message: "Category is not created." });
|
614
|
+
if (req.body.children && req.body.children.length > 0) {
|
615
|
+
await Category.updateMany(
|
616
|
+
{ _id: { $in: req.body.children } },
|
617
|
+
{ $set: { parent: category._id } }
|
618
|
+
);
|
619
|
+
}
|
620
|
+
await category.save();
|
621
|
+
res.status(201).json(category);
|
622
|
+
} catch (err) {
|
623
|
+
res.status(err.message === "Parent category not found" ? 404 : 500).json({ message: err.message });
|
610
624
|
}
|
611
|
-
|
612
|
-
|
613
|
-
|
614
|
-
|
615
|
-
|
616
|
-
|
617
|
-
|
618
|
-
|
619
|
-
|
620
|
-
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
626
|
-
|
625
|
+
},
|
626
|
+
async update(req, res) {
|
627
|
+
try {
|
628
|
+
const { categories } = req.body;
|
629
|
+
const bulkOps = categories.map((category) => ({
|
630
|
+
updateOne: {
|
631
|
+
filter: { _id: category._id },
|
632
|
+
update: {
|
633
|
+
$set: {
|
634
|
+
order: category.order,
|
635
|
+
parent: category.parent ? new ObjectId(category.parent) : null
|
636
|
+
}
|
637
|
+
}
|
638
|
+
}
|
639
|
+
}));
|
640
|
+
await Category.bulkWrite(bulkOps);
|
641
|
+
const updatedCategories = await Category.find().sort({ order: "asc" }).lean();
|
642
|
+
res.status(200).json(updatedCategories);
|
643
|
+
} catch (err) {
|
644
|
+
console.error("Category update error:", err);
|
645
|
+
res.status(500).json({ message: "Failed to update categories" });
|
627
646
|
}
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
633
|
-
|
634
|
-
|
635
|
-
|
636
|
-
|
637
|
-
|
647
|
+
},
|
648
|
+
async delete(req, res) {
|
649
|
+
try {
|
650
|
+
const category = await Category.findOne({ url: req.body.url });
|
651
|
+
if (!category) throw new Error("Category not found");
|
652
|
+
const deleteSubcategories = async (categoryId) => {
|
653
|
+
const cat = await Category.findById(categoryId);
|
654
|
+
if (cat) {
|
655
|
+
for (const childId of cat.children) {
|
656
|
+
await deleteSubcategories(childId);
|
657
|
+
}
|
658
|
+
await Category.findByIdAndDelete(categoryId);
|
659
|
+
}
|
660
|
+
};
|
661
|
+
if (category.parent) {
|
662
|
+
await Category.findByIdAndUpdate(category.parent, { $pull: { children: category._id } });
|
663
|
+
}
|
664
|
+
await deleteSubcategories(category._id);
|
665
|
+
res.status(200).json({ message: "Category deleted successfully" });
|
666
|
+
} catch (err) {
|
667
|
+
res.status(err.message === "Category not found" ? 404 : 500).json({ message: err.message });
|
638
668
|
}
|
639
|
-
res.status(200).send(category);
|
640
|
-
} catch (err) {
|
641
|
-
res.status(500).send({ message: err });
|
642
669
|
}
|
643
670
|
};
|
644
|
-
return {
|
645
|
-
getCategories,
|
646
|
-
updateCategories,
|
647
|
-
getCategory,
|
648
|
-
addCategory,
|
649
|
-
updateCategory,
|
650
|
-
deleteCategory
|
651
|
-
};
|
652
671
|
};
|
653
672
|
var categories_controller = controllerFactory$3;
|
654
673
|
var verifyCategory;
|
@@ -686,37 +705,16 @@ const middlewareIndexFactory = (db) => {
|
|
686
705
|
var middlewares = middlewareIndexFactory;
|
687
706
|
const controllerFactory$2 = categories_controller;
|
688
707
|
const middlewareFactoryProducts = middlewares;
|
689
|
-
|
708
|
+
categories_routes.exports = function(app, db) {
|
690
709
|
const controller = controllerFactory$2(db);
|
691
710
|
const { verifyCategory: verifyCategory2 } = middlewareFactoryProducts(db);
|
692
|
-
app.get(
|
693
|
-
|
694
|
-
|
695
|
-
);
|
696
|
-
app.post(
|
697
|
-
"/categories",
|
698
|
-
controller.updateCategories
|
699
|
-
);
|
700
|
-
app.get(
|
701
|
-
"/categories/:url",
|
702
|
-
controller.getCategory
|
703
|
-
);
|
704
|
-
app.post(
|
705
|
-
"/categories/add",
|
706
|
-
[
|
707
|
-
verifyCategory2.checkCategoryExistOrNot
|
708
|
-
],
|
709
|
-
controller.addCategory
|
710
|
-
);
|
711
|
-
app.post(
|
712
|
-
"/categories/:url",
|
713
|
-
controller.updateCategory
|
714
|
-
);
|
715
|
-
app.delete(
|
716
|
-
"/categories/:url",
|
717
|
-
controller.deleteCategory
|
718
|
-
);
|
711
|
+
app.get("/api/categories", controller.read);
|
712
|
+
app.post("/api/categories/create", [verifyCategory2.checkCategoryExistOrNot], controller.create);
|
713
|
+
app.post("/api/categories/update", controller.update);
|
714
|
+
app.post("/api/categories/delete", controller.delete);
|
719
715
|
};
|
716
|
+
categories_routes.exports.controllerFactory = controllerFactory$2;
|
717
|
+
var categories_routesExports = categories_routes.exports;
|
720
718
|
const queryProcessorGlobals = queryProcessor.queryProcessor;
|
721
719
|
const controllerFactory$1 = (db) => {
|
722
720
|
const Leftover = db.leftover;
|
@@ -864,7 +862,7 @@ const ProductModel = product_model;
|
|
864
862
|
const CategoryModel = category_model;
|
865
863
|
const LeftoverModel = leftover_model;
|
866
864
|
const productsRoutes = products_routes;
|
867
|
-
const categoriesRoutes =
|
865
|
+
const categoriesRoutes = categories_routesExports;
|
868
866
|
const leftoversRoutes = leftovers_routes;
|
869
867
|
const ProductController = products_controller;
|
870
868
|
const CategoryController = categories_controller;
|
@@ -875,7 +873,7 @@ function initializeProduct(app, db, origins, publicPath) {
|
|
875
873
|
db.leftover = LeftoverModel(db);
|
876
874
|
if (app) {
|
877
875
|
productsRoutes(app, db);
|
878
|
-
categoriesRoutes(app, db);
|
876
|
+
categoriesRoutes(app, db, origins, publicPath);
|
879
877
|
leftoversRoutes(app, db);
|
880
878
|
}
|
881
879
|
}
|