@ozdao/prometheus-framework 0.2.130 → 0.2.132
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/auth.server.js +0 -1
- package/dist/auth.server.mjs +0 -1
- package/dist/community.server.js +172 -31
- package/dist/community.server.mjs +172 -31
- package/dist/events.server.js +1 -1
- package/dist/events.server.mjs +1 -1
- package/dist/files.server.js +38 -4
- package/dist/files.server.mjs +38 -4
- package/dist/gallery.server.js +1 -1
- package/dist/gallery.server.mjs +1 -1
- package/dist/main-CI9l9xMs.js +92 -0
- package/dist/main-DPg58GOU.mjs +14509 -0
- package/dist/main.css +1 -1
- package/dist/orders.server.js +1 -1
- package/dist/orders.server.mjs +1 -1
- package/dist/organizations.server.js +4 -3
- package/dist/organizations.server.mjs +4 -3
- package/dist/products.server.js +2 -1
- package/dist/products.server.mjs +2 -1
- package/dist/prometheus-framework/src/components/Address/Address.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/Address/Address.vue.js +89 -0
- package/dist/prometheus-framework/src/components/Address/Address.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Address/Address.vue2.js +22 -23
- package/dist/prometheus-framework/src/components/Block/Block.vue.js +13 -13
- package/dist/prometheus-framework/src/components/Button/Button.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/Button/Button.vue.js +95 -0
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.cjs +1 -0
- package/dist/prometheus-framework/src/components/Chips/Chips.vue2.js +26 -0
- package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.js +32 -33
- package/dist/prometheus-framework/src/components/Draggable/Draggable.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/Draggable/Draggable.vue.js +75 -0
- package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue2.cjs +1 -0
- package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue2.js +57 -0
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +93 -87
- package/dist/prometheus-framework/src/components/Field/Field.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/Field/Field.vue.js +84 -0
- package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.js +32 -29
- package/dist/prometheus-framework/src/components/FieldPhone/FieldPhone.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/FieldPhone/FieldPhone.vue.js +22 -23
- package/dist/prometheus-framework/src/components/FieldTags/FieldTags.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/FieldTags/FieldTags.vue.js +39 -39
- package/dist/prometheus-framework/src/components/FieldTags/tag-input.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/FieldTags/tag-input.vue2.js +5 -5
- package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue.js +127 -0
- package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.js +46 -47
- package/dist/prometheus-framework/src/components/Menu/Menu.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/Menu/Menu.vue.js +13 -0
- package/dist/prometheus-framework/src/components/PhotoViewer/PhotoViewer.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/PhotoViewer/PhotoViewer.vue.js +22 -23
- package/dist/prometheus-framework/src/components/Select/Select.vue.cjs +1 -0
- package/dist/prometheus-framework/src/components/Select/Select.vue.js +103 -0
- package/dist/prometheus-framework/src/components/Spoiler/Spoiler.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/Spoiler/Spoiler.vue2.js +14 -15
- package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.js +9 -10
- package/dist/prometheus-framework/src/components/Upload/Upload.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Upload/Upload.vue.js +37 -34
- package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.js +31 -31
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +32 -32
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.js +20 -20
- package/dist/prometheus-framework/src/modules/auth/store/auth.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/store/auth.js +11 -11
- package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/community/community.client.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/community.client.js +12 -14
- 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 +55 -72
- package/dist/prometheus-framework/src/modules/community/components/blocks/FooterBlogpost.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/blocks/FooterBlogpost.vue.js +57 -29
- package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.js +87 -77
- package/dist/prometheus-framework/src/modules/community/components/pages/Blog.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/Blog.vue.js +58 -28
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +71 -80
- package/dist/prometheus-framework/src/modules/community/components/sections/Comment.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/community/components/sections/Comment.vue.js +104 -0
- package/dist/prometheus-framework/src/modules/community/components/sections/Comments.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/sections/Comments.vue.js +99 -54
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +29 -30
- package/dist/prometheus-framework/src/modules/community/store/blogposts.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/store/blogposts.js +45 -34
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Audio.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Audio.vue.js +31 -29
- 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/constructor/components/elements/ImageUpload.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/ImageUpload.vue.js +32 -27
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.cjs +5 -0
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.js +67 -0
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Video.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Video.vue.js +16 -16
- package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.js +119 -112
- 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 +6 -6
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.js +21 -21
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +30 -30
- package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockFilter.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockFilter.vue.js +33 -22
- package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.js +18 -18
- package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/marketplace/store/marketplace.cjs +1 -1
- package/dist/prometheus-framework/src/modules/marketplace/store/marketplace.js +3 -9
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +1 -1
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +3 -3
- 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 +9 -9
- 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/orders/components/sections/FormPayment.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormPayment.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 +39 -38
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.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.js +113 -86
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationBackoffice.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationBackoffice.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +37 -36
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.js +10 -10
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +1 -1
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Publics.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Publics.vue.js +17 -17
- package/dist/prometheus-framework/src/modules/organizations/store/memberships.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/store/memberships.js +18 -18
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +1 -1
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardProduct.vue.js +6 -6
- package/dist/prometheus-framework/src/modules/products/components/blocks/ImagesThumbnails.vue.js +12 -12
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductRecommmendation.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductRecommmendation.vue.js +3 -2
- 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 +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/products/components/sections/HeroRecommendation.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/HeroRecommendation.vue.js +32 -37
- 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/reports/components/sections/FormReport.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +2 -2
- 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 +5 -5
- package/dist/prometheus-framework/src/modules/users/components/blocks/CardUser.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/blocks/CardUser.vue.js +14 -14
- package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +33 -33
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.js +53 -35
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CardBalanceReplenished.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CardBalanceReplenished.vue.js +30 -0
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CardDeposite.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CardDeposite.vue.js +42 -0
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CashDeposite.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CashDeposite.vue.js +26 -0
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CryptoDeposite.vue.cjs +1 -0
- package/dist/prometheus-framework/src/modules/wallet/components/blocks/CryptoDeposite.vue.js +42 -0
- package/dist/prometheus-framework/src/modules/wallet/localization/Wallet.json.cjs +1 -0
- package/dist/prometheus-framework/src/modules/wallet/localization/Wallet.json.js +26 -0
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +158 -81
- package/dist/prometheus-framework.cjs.js +1 -1
- package/dist/prometheus-framework.es.js +14 -14
- package/dist/queryProcessor-DQSFR9YA.mjs +179 -0
- package/dist/queryProcessor-iewDZq_f.js +178 -0
- package/dist/style.css +1 -1
- package/dist/wallet.server.js +80 -27
- package/dist/wallet.server.mjs +80 -27
- package/dist/web-DZUec7pP.js +1 -0
- package/dist/web-krQQeSb6.mjs +54 -0
- package/package.json +1 -1
- package/src/components/Address/Address.vue +1 -1
- package/src/components/Chips/Chips.vue +1 -1
- package/src/components/Completion/Completion.vue +1 -4
- package/src/components/DatePicker/Calendar.vue +1 -1
- package/src/components/Draggable/Draggable.vue +113 -0
- package/src/components/Dropdown/Dropdown.vue +1 -1
- package/src/components/Feed/Feed.vue +18 -12
- package/src/components/FieldBig/FieldBig.vue +11 -1
- package/src/components/FieldPhone/FieldPhone.vue +1 -1
- package/src/components/FieldTags/FieldTags.vue +2 -1
- package/src/components/FieldTags/tag-input.vue +1 -1
- package/src/components/LocationMarker/LocationMarker.vue +1 -1
- package/src/components/PhotoViewer/PhotoViewer.vue +1 -1
- package/src/components/Shader/Shader.vue +2 -2
- package/src/components/Slider/Slider.vue +1 -5
- package/src/components/Spoiler/Spoiler.vue +1 -1
- package/src/components/Text/Text.vue +1 -4
- package/src/components/Tooltip/Tooltip.vue +1 -1
- package/src/components/Upload/Upload.vue +5 -3
- package/src/modules/auth/controllers/auth.controller.js +0 -2
- package/src/modules/auth/store/auth.js +2 -2
- package/src/modules/community/DOCUMENTATION.MD +4 -0
- package/src/modules/community/community.client.js +0 -2
- package/src/modules/community/components/blocks/CardBlogpost.vue +6 -2
- package/src/modules/community/components/blocks/FooterBlogpost.vue +21 -5
- package/src/modules/community/components/layouts/Community.vue +15 -11
- package/src/modules/community/components/pages/Blog.vue +25 -32
- package/src/modules/community/components/pages/CreateBlogPost.vue +8 -15
- package/src/modules/community/components/sections/Comment.vue +123 -0
- package/src/modules/community/components/sections/Comments.vue +90 -19
- package/src/modules/community/components/sections/HotPosts.vue +3 -6
- package/src/modules/community/controllers/blog.controller.js +1 -1
- package/src/modules/community/controllers/comments.controller.aggr.js +280 -0
- package/src/modules/community/controllers/comments.controller.js +187 -38
- package/src/modules/community/controllers/comments.controller.populate.js +180 -0
- package/src/modules/community/models/comment.model.js +15 -0
- package/src/modules/community/store/blogposts.js +20 -2
- package/src/modules/constructor/components/elements/Audio.vue +28 -40
- package/src/modules/constructor/components/elements/ImageUpload.vue +12 -7
- package/src/modules/constructor/components/elements/Video.vue +10 -18
- package/src/modules/constructor/components/sections/Constructor.vue +54 -47
- package/src/modules/files/controllers/files.controller.js +2 -0
- package/src/modules/files/middlewares/server/middlewareBusboy.js +32 -4
- package/src/modules/files/routes/files.routes.js +8 -0
- package/src/modules/globals/components/blocks/BlockFilter.vue +17 -7
- package/src/modules/globals/components/partials/Header.vue +12 -7
- package/src/modules/globals/controllers/utils/queryProcessor.js +1 -0
- package/src/modules/icons/logos/Logotype.vue +8 -6
- package/src/modules/icons/logos/LogotypeNunito.vue +12 -0
- package/src/modules/marketplace/components/layouts/Marketplace.vue +29 -27
- package/src/modules/marketplace/store/marketplace.js +2 -8
- package/src/modules/organizations/components/blocks/CardOrganization.vue +1 -1
- package/src/modules/organizations/components/pages/Members.vue +1 -1
- package/src/modules/organizations/components/pages/Organization.vue +33 -5
- package/src/modules/organizations/components/pages/OrganizationEdit.vue +7 -4
- package/src/modules/organizations/components/sections/DetailsTab.vue +10 -10
- package/src/modules/organizations/components/sections/Publics.vue +2 -2
- package/src/modules/organizations/controllers/memberships.controller.js +2 -3
- package/src/modules/organizations/controllers/organizations.controller.js +1 -1
- package/src/modules/organizations/store/memberships.js +4 -1
- package/src/modules/products/components/blocks/CardProduct.vue +1 -1
- package/src/modules/products/components/sections/HeroRecommendation.vue +11 -8
- package/src/modules/products/models/product.model.js +2 -1
- package/src/modules/spots/components/layouts/Spots.vue +0 -3
- package/src/modules/spots/components/pages/Map.vue +13 -3
- package/src/modules/users/components/blocks/CardUser.vue +2 -2
- package/src/modules/users/components/pages/ProfileBlogposts.vue +45 -28
- package/src/modules/wallet/components/blocks/CardBalanceReplenished.vue +40 -0
- package/src/modules/wallet/components/blocks/CardDeposite.vue +55 -0
- package/src/modules/wallet/components/blocks/CashDeposite.vue +28 -0
- package/src/modules/wallet/components/blocks/CryptoDeposite.vue +55 -0
- package/src/modules/wallet/controllers/factories/rewards.factory.aggr.js +181 -0
- package/src/modules/wallet/controllers/factories/rewards.factory.js +87 -113
- package/src/modules/wallet/controllers/factories/rewards.factory.population.js +213 -0
- package/src/modules/wallet/localization/Wallet.json +22 -0
- package/src/modules/wallet/views/components/pages/Wallet.vue +153 -53
- package/src/styles/base/all.scss +16 -26
- package/src/styles/config.scss +70 -34
- package/src/styles/typography.scss +5 -5
- package/src/modules/community/components/sections/Feed.vue +0 -148
- package/src/modules/middlewares/server/accessors/AccessController.js +0 -33
- package/src/modules/middlewares/server/accessors/ReadDepartments.js +0 -101
package/dist/auth.server.js
CHANGED
@@ -237,7 +237,6 @@ const controllerFactory$3 = (db) => {
|
|
237
237
|
}
|
238
238
|
const rights = accesses[orgId].rights;
|
239
239
|
const defaultAccesses = new Department();
|
240
|
-
console.log(defaultAccesses);
|
241
240
|
const accessData = isOwner ? defaultAccesses.accesses : (depts.find((dept) => dept.organization.toString() === orgId) || {}).accesses;
|
242
241
|
Object.keys(accessData).forEach((key) => {
|
243
242
|
if (!rights[key]) {
|
package/dist/auth.server.mjs
CHANGED
@@ -236,7 +236,6 @@ const controllerFactory$3 = (db) => {
|
|
236
236
|
}
|
237
237
|
const rights = accesses[orgId].rights;
|
238
238
|
const defaultAccesses = new Department();
|
239
|
-
console.log(defaultAccesses);
|
240
239
|
const accessData = isOwner ? defaultAccesses.accesses : (depts.find((dept) => dept.organization.toString() === orgId) || {}).accesses;
|
241
240
|
Object.keys(accessData).forEach((key) => {
|
242
241
|
if (!rights[key]) {
|
package/dist/community.server.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
const _commonjsHelpers = require("./_commonjsHelpers-DHfMLFPC.js");
|
3
3
|
const require$$0 = require("mongoose");
|
4
|
-
const queryProcessor$3 = require("./queryProcessor-
|
4
|
+
const queryProcessor$3 = require("./queryProcessor-iewDZq_f.js");
|
5
5
|
require("util");
|
6
6
|
require("uuid");
|
7
7
|
const index = require("./index-BshfsiQG.js");
|
@@ -237,8 +237,8 @@ const controllerFactory$3 = (db) => {
|
|
237
237
|
// For owner
|
238
238
|
queryProcessorGlobals.getOwnerUserLookupStage(),
|
239
239
|
queryProcessorGlobals.getOwnerOrganizationLookupStage(),
|
240
|
-
queryProcessorGlobals.getAddFieldsCreatorOwnerStage()
|
241
|
-
{ $sample: { size: Number(req.query.limit) } }
|
240
|
+
queryProcessorGlobals.getAddFieldsCreatorOwnerStage()
|
241
|
+
// { $sample: { size: Number(req.query.limit) } },
|
242
242
|
];
|
243
243
|
try {
|
244
244
|
const posts = await Blogpost.aggregate(stages).exec();
|
@@ -302,46 +302,173 @@ const commentControllerFactory = (db) => {
|
|
302
302
|
const Membership = db.membership;
|
303
303
|
const read = async (req, res) => {
|
304
304
|
try {
|
305
|
-
let
|
306
|
-
|
307
|
-
const
|
308
|
-
|
309
|
-
|
310
|
-
|
305
|
+
let buildCommentTree = function(comments2) {
|
306
|
+
const commentMap = /* @__PURE__ */ new Map();
|
307
|
+
const objectIdToString = (id) => id.toString();
|
308
|
+
function addToMap(comment) {
|
309
|
+
const commentId = objectIdToString(comment._id);
|
310
|
+
if (!commentMap.has(commentId)) {
|
311
|
+
commentMap.set(commentId, { ...comment, children: [] });
|
312
|
+
if (comment.children && comment.children.length > 0) {
|
313
|
+
comment.children.forEach(addToMap);
|
314
|
+
}
|
315
|
+
}
|
311
316
|
}
|
317
|
+
comments2.forEach(addToMap);
|
318
|
+
commentMap.forEach((comment) => {
|
319
|
+
if (comment.parent) {
|
320
|
+
const parentId2 = objectIdToString(comment.parent);
|
321
|
+
const parent = commentMap.get(parentId2);
|
322
|
+
if (parent) {
|
323
|
+
parent.children.push(comment);
|
324
|
+
}
|
325
|
+
}
|
326
|
+
});
|
327
|
+
function sortChildren(comment) {
|
328
|
+
if (comment.children.length > 0) {
|
329
|
+
comment.children.sort((a, b) => new Date(a.createdAt) - new Date(b.createdAt));
|
330
|
+
comment.children.forEach(sortChildren);
|
331
|
+
}
|
332
|
+
}
|
333
|
+
const rootComments = comments2.map((comment) => {
|
334
|
+
const commentId = objectIdToString(comment._id);
|
335
|
+
return commentMap.get(commentId);
|
336
|
+
}).filter((comment) => !comment.parent);
|
337
|
+
rootComments.sort((a, b) => new Date(a.createdAt) - new Date(b.createdAt));
|
338
|
+
rootComments.forEach(sortChildren);
|
339
|
+
return rootComments;
|
340
|
+
};
|
341
|
+
const { target, type, user, maxDepth = 4, parentId = null } = req.query;
|
342
|
+
let conditions = {
|
343
|
+
target: new db.mongoose.Types.ObjectId(target),
|
344
|
+
type
|
345
|
+
};
|
346
|
+
if (parentId) {
|
347
|
+
conditions.parent = new db.mongoose.Types.ObjectId(parentId);
|
348
|
+
} else {
|
349
|
+
conditions.parent = null;
|
312
350
|
}
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
if (!comments) {
|
318
|
-
return res.status(404).send({ message: "Comments not found." });
|
351
|
+
let blockedMembers = [];
|
352
|
+
if (user) {
|
353
|
+
const memberships = await Membership.find({ user, role: "blocked" });
|
354
|
+
blockedMembers = memberships.map((membership) => membership.target);
|
319
355
|
}
|
320
|
-
const
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
|
356
|
+
const pipeline = [
|
357
|
+
{ $match: conditions },
|
358
|
+
{ $sort: { createdAt: 1 } },
|
359
|
+
{
|
360
|
+
$graphLookup: {
|
361
|
+
from: "comments",
|
362
|
+
startWith: "$_id",
|
363
|
+
connectFromField: "_id",
|
364
|
+
connectToField: "parent",
|
365
|
+
as: "children",
|
366
|
+
depthField: "childDepth"
|
367
|
+
}
|
368
|
+
},
|
369
|
+
{
|
370
|
+
$lookup: {
|
371
|
+
from: "users",
|
372
|
+
localField: "user",
|
373
|
+
foreignField: "_id",
|
374
|
+
as: "user"
|
375
|
+
}
|
376
|
+
},
|
377
|
+
{ $unwind: "$user" },
|
378
|
+
{
|
379
|
+
$lookup: {
|
380
|
+
from: "users",
|
381
|
+
localField: "children.user",
|
382
|
+
foreignField: "_id",
|
383
|
+
as: "childUsers"
|
384
|
+
}
|
385
|
+
},
|
386
|
+
{
|
387
|
+
$project: {
|
388
|
+
_id: 1,
|
389
|
+
content: 1,
|
390
|
+
type: 1,
|
391
|
+
target: 1,
|
392
|
+
"user.username": 1,
|
393
|
+
"user.profile.photo": 1,
|
394
|
+
"user.profile.name": 1,
|
395
|
+
"user._id": 1,
|
396
|
+
depth: 1,
|
397
|
+
createdAt: 1,
|
398
|
+
childrenCount: { $size: "$children" },
|
399
|
+
children: {
|
400
|
+
$map: {
|
401
|
+
input: "$children",
|
402
|
+
as: "child",
|
403
|
+
in: {
|
404
|
+
_id: "$$child._id",
|
405
|
+
content: "$$child.content",
|
406
|
+
type: "$$child.type",
|
407
|
+
parent: "$$child.parent",
|
408
|
+
target: "$$child.target",
|
409
|
+
user: {
|
410
|
+
$arrayElemAt: [
|
411
|
+
{
|
412
|
+
$filter: {
|
413
|
+
input: "$childUsers",
|
414
|
+
as: "childUser",
|
415
|
+
cond: { $eq: ["$$childUser._id", "$$child.user"] }
|
416
|
+
}
|
417
|
+
},
|
418
|
+
0
|
419
|
+
]
|
420
|
+
},
|
421
|
+
depth: "$$child.depth",
|
422
|
+
createdAt: "$$child.createdAt",
|
423
|
+
childrenCount: { $size: "$$child.children" }
|
424
|
+
}
|
425
|
+
}
|
426
|
+
}
|
427
|
+
}
|
428
|
+
}
|
429
|
+
];
|
430
|
+
if (blockedMembers.length > 0) {
|
431
|
+
pipeline.unshift({ $match: { user: { $nin: blockedMembers } } });
|
432
|
+
}
|
433
|
+
const comments = await Comment.aggregate(pipeline);
|
434
|
+
commentsTree = buildCommentTree(comments);
|
435
|
+
console.log(commentsTree);
|
436
|
+
res.status(200).json(commentsTree);
|
437
|
+
} catch (error) {
|
438
|
+
console.error(error);
|
439
|
+
res.status(500).json({ message: error.message });
|
329
440
|
}
|
330
441
|
};
|
331
442
|
const create = async (req, res) => {
|
332
443
|
try {
|
444
|
+
const { user, type, target, content, parent } = req.body;
|
445
|
+
let depth = 0;
|
446
|
+
if (parent) {
|
447
|
+
const parentComment = await Comment.findById(parent);
|
448
|
+
if (!parentComment) {
|
449
|
+
return res.status(404).send({ message: "Parent comment not found." });
|
450
|
+
}
|
451
|
+
depth = parentComment.depth + 1;
|
452
|
+
}
|
333
453
|
const comment = new Comment({
|
334
|
-
user
|
335
|
-
type
|
336
|
-
target
|
337
|
-
content
|
454
|
+
user,
|
455
|
+
type,
|
456
|
+
target,
|
457
|
+
content,
|
458
|
+
parent,
|
459
|
+
depth
|
338
460
|
});
|
339
|
-
const
|
340
|
-
|
461
|
+
const savedComment = await comment.save();
|
462
|
+
if (parent) {
|
463
|
+
await Comment.findByIdAndUpdate(parent, {
|
464
|
+
$push: { children: savedComment._id }
|
465
|
+
});
|
466
|
+
}
|
467
|
+
const populatedComment = await Comment.findById(savedComment._id).populate({
|
341
468
|
path: "user",
|
342
469
|
select: "username profile.photo profile.name _id"
|
343
470
|
});
|
344
|
-
res.status(
|
471
|
+
res.status(201).send(populatedComment);
|
345
472
|
} catch (err) {
|
346
473
|
console.error(err);
|
347
474
|
res.status(500).send({
|
@@ -649,6 +776,19 @@ var comment_model = (mongoose) => {
|
|
649
776
|
},
|
650
777
|
required: true
|
651
778
|
},
|
779
|
+
parent: {
|
780
|
+
type: mongoose.Schema.Types.ObjectId,
|
781
|
+
ref: "Comment",
|
782
|
+
default: null
|
783
|
+
},
|
784
|
+
children: [{
|
785
|
+
type: mongoose.Schema.Types.ObjectId,
|
786
|
+
ref: "Comment"
|
787
|
+
}],
|
788
|
+
depth: {
|
789
|
+
type: Number,
|
790
|
+
default: 0
|
791
|
+
},
|
652
792
|
content: {
|
653
793
|
type: String,
|
654
794
|
required: true
|
@@ -658,6 +798,7 @@ var comment_model = (mongoose) => {
|
|
658
798
|
default: Date.now
|
659
799
|
}
|
660
800
|
});
|
801
|
+
CommentSchema.index({ target: 1, parent: 1, depth: 1 });
|
661
802
|
const Comment = mongoose.model("Comment", CommentSchema);
|
662
803
|
return Comment;
|
663
804
|
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { g as getDefaultExportFromCjs } from "./_commonjsHelpers-CUmg6egw.mjs";
|
2
2
|
import require$$0 from "mongoose";
|
3
|
-
import { q as queryProcessor$3 } from "./queryProcessor-
|
3
|
+
import { q as queryProcessor$3 } from "./queryProcessor-DQSFR9YA.mjs";
|
4
4
|
import "util";
|
5
5
|
import "uuid";
|
6
6
|
import { s as server$1 } from "./index-DKtnWDNC.mjs";
|
@@ -236,8 +236,8 @@ const controllerFactory$3 = (db) => {
|
|
236
236
|
// For owner
|
237
237
|
queryProcessorGlobals.getOwnerUserLookupStage(),
|
238
238
|
queryProcessorGlobals.getOwnerOrganizationLookupStage(),
|
239
|
-
queryProcessorGlobals.getAddFieldsCreatorOwnerStage()
|
240
|
-
{ $sample: { size: Number(req.query.limit) } }
|
239
|
+
queryProcessorGlobals.getAddFieldsCreatorOwnerStage()
|
240
|
+
// { $sample: { size: Number(req.query.limit) } },
|
241
241
|
];
|
242
242
|
try {
|
243
243
|
const posts = await Blogpost.aggregate(stages).exec();
|
@@ -301,46 +301,173 @@ const commentControllerFactory = (db) => {
|
|
301
301
|
const Membership = db.membership;
|
302
302
|
const read = async (req, res) => {
|
303
303
|
try {
|
304
|
-
let
|
305
|
-
|
306
|
-
const
|
307
|
-
|
308
|
-
|
309
|
-
|
304
|
+
let buildCommentTree = function(comments2) {
|
305
|
+
const commentMap = /* @__PURE__ */ new Map();
|
306
|
+
const objectIdToString = (id) => id.toString();
|
307
|
+
function addToMap(comment) {
|
308
|
+
const commentId = objectIdToString(comment._id);
|
309
|
+
if (!commentMap.has(commentId)) {
|
310
|
+
commentMap.set(commentId, { ...comment, children: [] });
|
311
|
+
if (comment.children && comment.children.length > 0) {
|
312
|
+
comment.children.forEach(addToMap);
|
313
|
+
}
|
314
|
+
}
|
310
315
|
}
|
316
|
+
comments2.forEach(addToMap);
|
317
|
+
commentMap.forEach((comment) => {
|
318
|
+
if (comment.parent) {
|
319
|
+
const parentId2 = objectIdToString(comment.parent);
|
320
|
+
const parent = commentMap.get(parentId2);
|
321
|
+
if (parent) {
|
322
|
+
parent.children.push(comment);
|
323
|
+
}
|
324
|
+
}
|
325
|
+
});
|
326
|
+
function sortChildren(comment) {
|
327
|
+
if (comment.children.length > 0) {
|
328
|
+
comment.children.sort((a, b) => new Date(a.createdAt) - new Date(b.createdAt));
|
329
|
+
comment.children.forEach(sortChildren);
|
330
|
+
}
|
331
|
+
}
|
332
|
+
const rootComments = comments2.map((comment) => {
|
333
|
+
const commentId = objectIdToString(comment._id);
|
334
|
+
return commentMap.get(commentId);
|
335
|
+
}).filter((comment) => !comment.parent);
|
336
|
+
rootComments.sort((a, b) => new Date(a.createdAt) - new Date(b.createdAt));
|
337
|
+
rootComments.forEach(sortChildren);
|
338
|
+
return rootComments;
|
339
|
+
};
|
340
|
+
const { target, type, user, maxDepth = 4, parentId = null } = req.query;
|
341
|
+
let conditions = {
|
342
|
+
target: new db.mongoose.Types.ObjectId(target),
|
343
|
+
type
|
344
|
+
};
|
345
|
+
if (parentId) {
|
346
|
+
conditions.parent = new db.mongoose.Types.ObjectId(parentId);
|
347
|
+
} else {
|
348
|
+
conditions.parent = null;
|
311
349
|
}
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
if (!comments) {
|
317
|
-
return res.status(404).send({ message: "Comments not found." });
|
350
|
+
let blockedMembers = [];
|
351
|
+
if (user) {
|
352
|
+
const memberships = await Membership.find({ user, role: "blocked" });
|
353
|
+
blockedMembers = memberships.map((membership) => membership.target);
|
318
354
|
}
|
319
|
-
const
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
355
|
+
const pipeline = [
|
356
|
+
{ $match: conditions },
|
357
|
+
{ $sort: { createdAt: 1 } },
|
358
|
+
{
|
359
|
+
$graphLookup: {
|
360
|
+
from: "comments",
|
361
|
+
startWith: "$_id",
|
362
|
+
connectFromField: "_id",
|
363
|
+
connectToField: "parent",
|
364
|
+
as: "children",
|
365
|
+
depthField: "childDepth"
|
366
|
+
}
|
367
|
+
},
|
368
|
+
{
|
369
|
+
$lookup: {
|
370
|
+
from: "users",
|
371
|
+
localField: "user",
|
372
|
+
foreignField: "_id",
|
373
|
+
as: "user"
|
374
|
+
}
|
375
|
+
},
|
376
|
+
{ $unwind: "$user" },
|
377
|
+
{
|
378
|
+
$lookup: {
|
379
|
+
from: "users",
|
380
|
+
localField: "children.user",
|
381
|
+
foreignField: "_id",
|
382
|
+
as: "childUsers"
|
383
|
+
}
|
384
|
+
},
|
385
|
+
{
|
386
|
+
$project: {
|
387
|
+
_id: 1,
|
388
|
+
content: 1,
|
389
|
+
type: 1,
|
390
|
+
target: 1,
|
391
|
+
"user.username": 1,
|
392
|
+
"user.profile.photo": 1,
|
393
|
+
"user.profile.name": 1,
|
394
|
+
"user._id": 1,
|
395
|
+
depth: 1,
|
396
|
+
createdAt: 1,
|
397
|
+
childrenCount: { $size: "$children" },
|
398
|
+
children: {
|
399
|
+
$map: {
|
400
|
+
input: "$children",
|
401
|
+
as: "child",
|
402
|
+
in: {
|
403
|
+
_id: "$$child._id",
|
404
|
+
content: "$$child.content",
|
405
|
+
type: "$$child.type",
|
406
|
+
parent: "$$child.parent",
|
407
|
+
target: "$$child.target",
|
408
|
+
user: {
|
409
|
+
$arrayElemAt: [
|
410
|
+
{
|
411
|
+
$filter: {
|
412
|
+
input: "$childUsers",
|
413
|
+
as: "childUser",
|
414
|
+
cond: { $eq: ["$$childUser._id", "$$child.user"] }
|
415
|
+
}
|
416
|
+
},
|
417
|
+
0
|
418
|
+
]
|
419
|
+
},
|
420
|
+
depth: "$$child.depth",
|
421
|
+
createdAt: "$$child.createdAt",
|
422
|
+
childrenCount: { $size: "$$child.children" }
|
423
|
+
}
|
424
|
+
}
|
425
|
+
}
|
426
|
+
}
|
427
|
+
}
|
428
|
+
];
|
429
|
+
if (blockedMembers.length > 0) {
|
430
|
+
pipeline.unshift({ $match: { user: { $nin: blockedMembers } } });
|
431
|
+
}
|
432
|
+
const comments = await Comment.aggregate(pipeline);
|
433
|
+
commentsTree = buildCommentTree(comments);
|
434
|
+
console.log(commentsTree);
|
435
|
+
res.status(200).json(commentsTree);
|
436
|
+
} catch (error) {
|
437
|
+
console.error(error);
|
438
|
+
res.status(500).json({ message: error.message });
|
328
439
|
}
|
329
440
|
};
|
330
441
|
const create = async (req, res) => {
|
331
442
|
try {
|
443
|
+
const { user, type, target, content, parent } = req.body;
|
444
|
+
let depth = 0;
|
445
|
+
if (parent) {
|
446
|
+
const parentComment = await Comment.findById(parent);
|
447
|
+
if (!parentComment) {
|
448
|
+
return res.status(404).send({ message: "Parent comment not found." });
|
449
|
+
}
|
450
|
+
depth = parentComment.depth + 1;
|
451
|
+
}
|
332
452
|
const comment = new Comment({
|
333
|
-
user
|
334
|
-
type
|
335
|
-
target
|
336
|
-
content
|
453
|
+
user,
|
454
|
+
type,
|
455
|
+
target,
|
456
|
+
content,
|
457
|
+
parent,
|
458
|
+
depth
|
337
459
|
});
|
338
|
-
const
|
339
|
-
|
460
|
+
const savedComment = await comment.save();
|
461
|
+
if (parent) {
|
462
|
+
await Comment.findByIdAndUpdate(parent, {
|
463
|
+
$push: { children: savedComment._id }
|
464
|
+
});
|
465
|
+
}
|
466
|
+
const populatedComment = await Comment.findById(savedComment._id).populate({
|
340
467
|
path: "user",
|
341
468
|
select: "username profile.photo profile.name _id"
|
342
469
|
});
|
343
|
-
res.status(
|
470
|
+
res.status(201).send(populatedComment);
|
344
471
|
} catch (err) {
|
345
472
|
console.error(err);
|
346
473
|
res.status(500).send({
|
@@ -648,6 +775,19 @@ var comment_model = (mongoose) => {
|
|
648
775
|
},
|
649
776
|
required: true
|
650
777
|
},
|
778
|
+
parent: {
|
779
|
+
type: mongoose.Schema.Types.ObjectId,
|
780
|
+
ref: "Comment",
|
781
|
+
default: null
|
782
|
+
},
|
783
|
+
children: [{
|
784
|
+
type: mongoose.Schema.Types.ObjectId,
|
785
|
+
ref: "Comment"
|
786
|
+
}],
|
787
|
+
depth: {
|
788
|
+
type: Number,
|
789
|
+
default: 0
|
790
|
+
},
|
651
791
|
content: {
|
652
792
|
type: String,
|
653
793
|
required: true
|
@@ -657,6 +797,7 @@ var comment_model = (mongoose) => {
|
|
657
797
|
default: Date.now
|
658
798
|
}
|
659
799
|
});
|
800
|
+
CommentSchema.index({ target: 1, parent: 1, depth: 1 });
|
660
801
|
const Comment = mongoose.model("Comment", CommentSchema);
|
661
802
|
return Comment;
|
662
803
|
};
|
package/dist/events.server.js
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
3
3
|
const _commonjsHelpers = require("./_commonjsHelpers-DHfMLFPC.js");
|
4
4
|
const require$$0 = require("mongoose");
|
5
|
-
const queryProcessor$2 = require("./queryProcessor-
|
5
|
+
const queryProcessor$2 = require("./queryProcessor-iewDZq_f.js");
|
6
6
|
const metadata_schema = require("./metadata.schema-6slGhpQS.js");
|
7
7
|
const require$$1 = require("stripe");
|
8
8
|
const index = require("./index-BshfsiQG.js");
|
package/dist/events.server.mjs
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { g as getDefaultExportFromCjs } from "./_commonjsHelpers-CUmg6egw.mjs";
|
2
2
|
import require$$0 from "mongoose";
|
3
|
-
import { q as queryProcessor$2 } from "./queryProcessor-
|
3
|
+
import { q as queryProcessor$2 } from "./queryProcessor-DQSFR9YA.mjs";
|
4
4
|
import { s as seoFriendlyUrl, m as metadata_schema } from "./metadata.schema-CK5e2O3f.mjs";
|
5
5
|
import require$$1 from "stripe";
|
6
6
|
import { s as server$1 } from "./index-DKtnWDNC.mjs";
|
package/dist/files.server.js
CHANGED
@@ -18,6 +18,7 @@ const controllerFactory$1 = (db, publicPath) => {
|
|
18
18
|
return absolutePath;
|
19
19
|
};
|
20
20
|
req.files = req.files.map((file) => convertToRelativePath(file));
|
21
|
+
console.log(req.files);
|
21
22
|
try {
|
22
23
|
const fileResponses = req.files.map((file) => ({
|
23
24
|
message: "File uploaded successfully.",
|
@@ -62,8 +63,8 @@ function requireMiddlewareBusboy() {
|
|
62
63
|
try {
|
63
64
|
const metadata = await sharp(originalPath).metadata();
|
64
65
|
const resizeOptions = {};
|
65
|
-
if (metadata.width >
|
66
|
-
resizeOptions.width =
|
66
|
+
if (metadata.width > 512) {
|
67
|
+
resizeOptions.width = 512;
|
67
68
|
}
|
68
69
|
await sharp(originalPath).rotate().resize(resizeOptions).toFile(thumbnailPath);
|
69
70
|
} catch (error) {
|
@@ -166,6 +167,7 @@ function requireMiddlewareBusboy() {
|
|
166
167
|
};
|
167
168
|
const uploadFilesMiddleware = (req, res, next) => {
|
168
169
|
const allowedTypes = [
|
170
|
+
// Images
|
169
171
|
"image/png",
|
170
172
|
"image/jpeg",
|
171
173
|
"image/jpg",
|
@@ -175,11 +177,19 @@ function requireMiddlewareBusboy() {
|
|
175
177
|
"image/webp",
|
176
178
|
"image/tiff",
|
177
179
|
"image/bmp",
|
178
|
-
"application/pdf",
|
179
180
|
"image/svg+xml",
|
181
|
+
// Video
|
180
182
|
"video/mp4",
|
181
183
|
"video/quicktime",
|
182
|
-
"video/webm"
|
184
|
+
"video/webm",
|
185
|
+
// Audito
|
186
|
+
"audio/mpeg",
|
187
|
+
"audio/wav",
|
188
|
+
"audio/ogg",
|
189
|
+
"audio/flac",
|
190
|
+
"audio/aac",
|
191
|
+
"audio/x-ms-wma",
|
192
|
+
"audio/aiff"
|
183
193
|
];
|
184
194
|
handleFileUpload(req, res, next, publicPath, {
|
185
195
|
folderNameDefault: "unsorted",
|
@@ -187,6 +197,22 @@ function requireMiddlewareBusboy() {
|
|
187
197
|
allowedTypes
|
188
198
|
});
|
189
199
|
};
|
200
|
+
const uploadAudioMiddleware = (req, res, next) => {
|
201
|
+
const allowedTypes = [
|
202
|
+
"audio/mpeg",
|
203
|
+
"audio/wav",
|
204
|
+
"audio/ogg",
|
205
|
+
"audio/flac",
|
206
|
+
"audio/aac",
|
207
|
+
"audio/x-ms-wma",
|
208
|
+
"audio/aiff"
|
209
|
+
];
|
210
|
+
handleFileUpload(req, res, next, publicPath, {
|
211
|
+
folderNameDefault: "unsorted",
|
212
|
+
maxSize: 10 * 1024 * 1024,
|
213
|
+
allowedTypes
|
214
|
+
});
|
215
|
+
};
|
190
216
|
const uploadImagesMiddleware = (req, res, next) => {
|
191
217
|
const allowedTypes = [
|
192
218
|
"image/png",
|
@@ -207,6 +233,7 @@ function requireMiddlewareBusboy() {
|
|
207
233
|
};
|
208
234
|
return {
|
209
235
|
uploadImagesMiddleware,
|
236
|
+
uploadAudioMiddleware,
|
210
237
|
uploadFilesMiddleware,
|
211
238
|
generatePreviewMiddleware,
|
212
239
|
convertImagesMiddleware
|
@@ -238,6 +265,13 @@ var files_routes = function(app, db, origins, publicPath) {
|
|
238
265
|
],
|
239
266
|
controller.uploadMultipleFileController
|
240
267
|
);
|
268
|
+
app.post(
|
269
|
+
"/api/upload/audio",
|
270
|
+
[
|
271
|
+
middlewareBusboy2.uploadAudioMiddleware
|
272
|
+
],
|
273
|
+
controller.uploadMultipleFileController
|
274
|
+
);
|
241
275
|
app.post(
|
242
276
|
"/api/upload/multiple",
|
243
277
|
[
|