@ozdao/martyrs 0.2.453 → 0.2.455
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/dist/{Media-BsgJlo-X.js → Media-1oukRVfv.js} +1 -1
- package/dist/{Media-CxRfrG2S.mjs → Media-q-XJSM_H.mjs} +3 -3
- package/dist/builder.js +5 -0
- package/dist/builder.mjs +5 -0
- package/dist/{main-Zocv7IVl.js → main-C7jGMDJC.js} +6 -6
- package/dist/{main-7FA_ai95.mjs → main-yXkgrjj8.mjs} +120 -133
- package/dist/martyrs/src/components/DatePicker/DatePicker.vue.cjs +2 -2
- package/dist/martyrs/src/components/DatePicker/DatePicker.vue.cjs.map +1 -1
- package/dist/martyrs/src/components/DatePicker/DatePicker.vue.js +2 -2
- package/dist/martyrs/src/components/DatePicker/DatePicker.vue.js.map +1 -1
- package/dist/martyrs/src/components/EmptyState/EmptyState.vue.cjs +1 -1
- package/dist/martyrs/src/components/EmptyState/EmptyState.vue.js +1 -1
- package/dist/martyrs/src/components/Media/Media.vue.cjs +2 -2
- package/dist/martyrs/src/components/Media/Media.vue.cjs.map +1 -1
- package/dist/martyrs/src/components/Media/Media.vue.js +2 -2
- package/dist/martyrs/src/components/Media/Media.vue.js.map +1 -1
- package/dist/martyrs/src/components/Popup/Popup.vue2.cjs +0 -8
- package/dist/martyrs/src/components/Popup/Popup.vue2.cjs.map +1 -1
- package/dist/martyrs/src/components/Popup/Popup.vue2.js +0 -8
- package/dist/martyrs/src/components/Popup/Popup.vue2.js.map +1 -1
- package/dist/martyrs/src/components/Slider/Slider.native.vue.cjs +229 -0
- package/dist/martyrs/src/components/Slider/Slider.native.vue.cjs.map +1 -0
- package/dist/martyrs/src/components/Slider/Slider.native.vue.js +229 -0
- package/dist/martyrs/src/components/Slider/Slider.native.vue.js.map +1 -0
- package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.cjs +29 -17
- package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.js +29 -17
- package/dist/martyrs/src/modules/events/components/blocks/CardEvent.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.cjs +1 -22
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.js +4 -25
- package/dist/martyrs/src/modules/events/components/pages/Event.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/Events.vue.cjs +50 -132
- package/dist/martyrs/src/modules/events/components/pages/Events.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/Events.vue.js +66 -148
- package/dist/martyrs/src/modules/events/components/pages/Events.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/EventsBackoffice.vue.cjs +3 -33
- package/dist/martyrs/src/modules/events/components/pages/EventsBackoffice.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/EventsBackoffice.vue.js +3 -33
- package/dist/martyrs/src/modules/events/components/pages/EventsBackoffice.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/pages/EventsSearch.vue.cjs +98 -0
- package/dist/martyrs/src/modules/events/components/pages/EventsSearch.vue.cjs.map +1 -0
- package/dist/martyrs/src/modules/events/components/pages/EventsSearch.vue.js +98 -0
- package/dist/martyrs/src/modules/events/components/pages/EventsSearch.vue.js.map +1 -0
- package/dist/martyrs/src/modules/events/components/sections/EventsHot.vue.cjs +2 -4
- package/dist/martyrs/src/modules/events/components/sections/EventsHot.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/components/sections/EventsHot.vue.js +2 -4
- package/dist/martyrs/src/modules/events/components/sections/EventsHot.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/sections/FeaturedEvents.vue.cjs +8 -7
- package/dist/martyrs/src/modules/events/components/sections/FeaturedEvents.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/components/sections/FeaturedEvents.vue.js +8 -7
- package/dist/martyrs/src/modules/events/components/sections/FeaturedEvents.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/sections/List.vue.cjs +3 -3
- package/dist/martyrs/src/modules/events/components/sections/List.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/components/sections/List.vue.js +3 -3
- package/dist/martyrs/src/modules/events/components/sections/List.vue.js.map +1 -1
- package/dist/martyrs/src/modules/events/components/sections/SelectDate.vue.cjs +190 -0
- package/dist/martyrs/src/modules/events/components/sections/SelectDate.vue.cjs.map +1 -0
- package/dist/martyrs/src/modules/events/components/sections/SelectDate.vue.js +190 -0
- package/dist/martyrs/src/modules/events/components/sections/SelectDate.vue.js.map +1 -0
- package/dist/martyrs/src/modules/events/router/events.cjs +15 -0
- package/dist/martyrs/src/modules/events/router/events.cjs.map +1 -1
- package/dist/martyrs/src/modules/events/router/events.js +15 -0
- package/dist/martyrs/src/modules/events/router/events.js.map +1 -1
- package/dist/martyrs/src/modules/globals/globals.client.cjs +2 -0
- package/dist/martyrs/src/modules/globals/globals.client.cjs.map +1 -1
- package/dist/martyrs/src/modules/globals/globals.client.js +2 -0
- package/dist/martyrs/src/modules/globals/globals.client.js.map +1 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/App.vue.cjs +4 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/App.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/App.vue.js +3 -0
- package/dist/martyrs/src/modules/globals/views/components/layouts/App.vue.js.map +1 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.cjs +2 -4
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.js +0 -2
- package/dist/martyrs/src/modules/globals/views/components/layouts/Client.vue.js.map +1 -1
- package/dist/martyrs/src/modules/globals/views/plugins/AlertDialog.vue.cjs +43 -0
- package/dist/martyrs/src/modules/globals/views/plugins/AlertDialog.vue.cjs.map +1 -0
- package/dist/martyrs/src/modules/globals/views/plugins/AlertDialog.vue.js +43 -0
- package/dist/martyrs/src/modules/globals/views/plugins/AlertDialog.vue.js.map +1 -0
- package/dist/martyrs/src/modules/globals/views/plugins/alert.plugin.cjs +53 -0
- package/dist/martyrs/src/modules/globals/views/plugins/alert.plugin.cjs.map +1 -0
- package/dist/martyrs/src/modules/globals/views/plugins/alert.plugin.js +53 -0
- package/dist/martyrs/src/modules/globals/views/plugins/alert.plugin.js.map +1 -0
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.cjs +0 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.js +0 -1
- package/dist/martyrs/src/modules/organizations/components/sections/Documents.vue.js.map +1 -1
- package/dist/martyrs/src/modules/products/components/elements/Price.vue.cjs +5 -6
- package/dist/martyrs/src/modules/products/components/elements/Price.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/products/components/elements/Price.vue.js +5 -6
- package/dist/martyrs/src/modules/products/components/elements/Price.vue.js.map +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.cjs +61 -69
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.js +62 -70
- package/dist/martyrs/src/modules/products/components/pages/Product.vue.js.map +1 -1
- package/dist/martyrs/src/modules/products/store/products.cjs +0 -1
- package/dist/martyrs/src/modules/products/store/products.cjs.map +1 -1
- package/dist/martyrs/src/modules/products/store/products.js +0 -1
- package/dist/martyrs/src/modules/products/store/products.js.map +1 -1
- package/dist/martyrs/src/modules/spots/components/pages/SpotEdit.vue.cjs +0 -1
- package/dist/martyrs/src/modules/spots/components/pages/SpotEdit.vue.cjs.map +1 -1
- package/dist/martyrs/src/modules/spots/components/pages/SpotEdit.vue.js +0 -1
- package/dist/martyrs/src/modules/spots/components/pages/SpotEdit.vue.js.map +1 -1
- package/dist/martyrs.cjs.js +1 -1
- package/dist/martyrs.css +1 -1
- package/dist/martyrs.es.js +1 -1
- package/dist/organizations.server.js +0 -1
- package/dist/organizations.server.mjs +0 -1
- package/dist/products.server.js +5 -0
- package/dist/products.server.mjs +5 -0
- package/dist/style.css +93 -6
- package/package.json +1 -1
- package/src/builder/rspack/rspack.config.client.js +5 -0
- package/src/components/DatePicker/DatePicker.vue +1 -1
- package/src/components/EmptyState/EmptyState.vue +1 -1
- package/src/components/Media/Media.vue +1 -1
- package/src/components/Popup/Popup.vue +2 -2
- package/src/components/Slider/Slider.native.vue +313 -0
- package/src/modules/events/components/blocks/CardEvent.vue +21 -7
- package/src/modules/events/components/pages/Event.vue +0 -20
- package/src/modules/events/components/pages/Events.vue +91 -141
- package/src/modules/events/components/pages/EventsBackoffice.vue +5 -3
- package/src/modules/events/components/pages/EventsSearch.vue +122 -0
- package/src/modules/events/components/sections/EventsHot.vue +3 -5
- package/src/modules/events/components/sections/FeaturedEvents.vue +44 -12
- package/src/modules/events/components/sections/List.vue +3 -3
- package/src/modules/events/components/sections/SelectDate.vue +217 -0
- package/src/modules/events/router/events.js +12 -0
- package/src/modules/globals/globals.client.js +5 -2
- package/src/modules/globals/views/components/layouts/App.vue +7 -1
- package/src/modules/globals/views/components/layouts/Client.vue +0 -3
- package/src/modules/globals/views/plugins/AlertDialog.vue +35 -0
- package/src/modules/globals/views/plugins/alert.plugin.js +65 -0
- package/src/modules/organizations/policies/organizations.policies.js +0 -1
- package/src/modules/products/components/elements/Price.vue +3 -4
- package/src/modules/products/components/pages/Product.old.vue +201 -0
- package/src/modules/products/components/pages/Product.vue +57 -38
- package/src/modules/products/controllers/products.controller.js +7 -0
- package/src/modules/products/store/products.js +0 -1
- package/src/styles/base/all.scss +1 -0
- package/src/styles/typography.scss +22 -0
|
@@ -13,41 +13,43 @@
|
|
|
13
13
|
@click="$router.push({ name: 'ProductEdit', params: { _id: product.owner.target, product: product._id } })"
|
|
14
14
|
class="pos-absolute pos-t-regular pos-r-regular i-regular t-transp"
|
|
15
15
|
/>
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
16
19
|
<h2 class="w-100 h1-product mn-b-small">{{ product.name }}</h2>
|
|
20
|
+
|
|
17
21
|
<Price :product="product" size="big" class="flex gap-micro flex-center pd-small br-solid br-1px br-black-transp-10 w-max mn-b-medium" />
|
|
18
22
|
|
|
19
|
-
<
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
{{ t('description') }}
|
|
36
|
-
</p>
|
|
37
|
-
</div>
|
|
38
|
-
<div v-else class="cols-2 pd-medium w-100 gap-small">
|
|
39
|
-
<div
|
|
40
|
-
v-if="product.information.length > 0"
|
|
41
|
-
v-for="information in product.information"
|
|
42
|
-
class="w-100 pd-small radius-small bg-white product-information"
|
|
43
|
-
>
|
|
44
|
-
<p class="t-demi">{{ information.name }}</p>
|
|
45
|
-
<p>{{ information.value }}</p>
|
|
46
|
-
</div>
|
|
47
|
-
</div>
|
|
48
|
-
</transition>
|
|
23
|
+
<p v-if="product.description && !product.localization < 1 && !recommendation" class="w-100 t-transp mn-b-small">
|
|
24
|
+
{{ product.description }}
|
|
25
|
+
</p>
|
|
26
|
+
<p v-if="product.localization && product.localization.length > 1 && !recommendation" class="w-100 t-transp mn-b-small">
|
|
27
|
+
{{ t('description') }}
|
|
28
|
+
</p>
|
|
29
|
+
|
|
30
|
+
<div class="cols-2 mn-b-small w-100 gap-small">
|
|
31
|
+
<div
|
|
32
|
+
v-if="product.information.length > 0"
|
|
33
|
+
v-for="information in product.information"
|
|
34
|
+
class="w-100 pd-small radius-small bg-light product-information"
|
|
35
|
+
>
|
|
36
|
+
<p class="t-demi">{{ information.name }}</p>
|
|
37
|
+
<p>{{ information.value }}</p>
|
|
38
|
+
</div>
|
|
49
39
|
</div>
|
|
50
40
|
|
|
41
|
+
<p class="t-medium mn-b-small">Provided by</p>
|
|
42
|
+
<CardOrganization
|
|
43
|
+
v-if="product.owner"
|
|
44
|
+
:organization="product.owner.target"
|
|
45
|
+
:showRating="true"
|
|
46
|
+
:showFollowers="false"
|
|
47
|
+
:showProducts="false"
|
|
48
|
+
class="bg-light mn-b-thin w-100 o-hidden radius-medium pd-small "
|
|
49
|
+
/>
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
|
|
51
53
|
<div class="w-max-33r">
|
|
52
54
|
<div class="w-max-33r">
|
|
53
55
|
<div v-if="product.listing === 'rent'">
|
|
@@ -71,8 +73,8 @@
|
|
|
71
73
|
<div v-else>
|
|
72
74
|
<Button
|
|
73
75
|
v-if="product.available > 0"
|
|
74
|
-
|
|
75
|
-
class="h-3r w-100 bg-main button"
|
|
76
|
+
:submit="() => addToCart(product, null)"
|
|
77
|
+
class="h-3r w-max mobile:w-100 bg-main button"
|
|
76
78
|
>
|
|
77
79
|
<div class="gap-thin flex flex-center flex-nowrap">
|
|
78
80
|
<IconShopcartAdd class="i-semi" />
|
|
@@ -99,10 +101,11 @@
|
|
|
99
101
|
</template>
|
|
100
102
|
|
|
101
103
|
<script setup>
|
|
102
|
-
import { computed, ref, onMounted } from 'vue'
|
|
104
|
+
import { computed, ref, onMounted, getCurrentInstance } from 'vue'
|
|
103
105
|
import { useRoute, useRouter } from 'vue-router'
|
|
104
106
|
import { useI18n } from 'vue-i18n'
|
|
105
107
|
|
|
108
|
+
|
|
106
109
|
import * as auth from '@martyrs/src/modules/auth/views/store/auth'
|
|
107
110
|
import * as globals from '@martyrs/src/modules/globals/views/store/globals'
|
|
108
111
|
import * as products from '@martyrs/src/modules/products/store/products'
|
|
@@ -120,8 +123,11 @@ import ImagesThumbnails from '@martyrs/src/modules/products/components/blocks/Im
|
|
|
120
123
|
import Price from '@martyrs/src/modules/products/components/elements/Price.vue'
|
|
121
124
|
import PopularProducts from '@martyrs/src/modules/products/components/sections/PopularProducts.vue'
|
|
122
125
|
|
|
126
|
+
import CardOrganization from '@martyrs/src/modules/organizations/components/blocks/CardOrganization.vue'
|
|
127
|
+
|
|
123
128
|
const route = useRoute()
|
|
124
129
|
const router = useRouter()
|
|
130
|
+
const { proxy } = getCurrentInstance()
|
|
125
131
|
|
|
126
132
|
const product = computed(() => products.state.current)
|
|
127
133
|
const images = computed(() => products.state.current.images)
|
|
@@ -148,15 +154,15 @@ function closePopup() {
|
|
|
148
154
|
const emits = defineEmits(['page-loading', 'page-loaded']);
|
|
149
155
|
|
|
150
156
|
const pageProduct = ref(null)
|
|
151
|
-
|
|
152
|
-
|
|
157
|
+
const orderOrganization = ref(null)
|
|
158
|
+
|
|
159
|
+
products.state.current = null
|
|
153
160
|
onMounted(async () => {
|
|
154
161
|
|
|
155
162
|
emits('page-loading');
|
|
156
163
|
await products.actions.read({ _id: route.params.product })
|
|
157
164
|
emits('page-loaded');
|
|
158
165
|
|
|
159
|
-
|
|
160
166
|
// route.meta.title.en = product.value.name
|
|
161
167
|
// route.meta.title.ru = roduct.value.name
|
|
162
168
|
|
|
@@ -170,14 +176,27 @@ function validateToCard(product) {
|
|
|
170
176
|
|
|
171
177
|
async function addToCart(product, selectedDates = null) {
|
|
172
178
|
try {
|
|
173
|
-
|
|
179
|
+
// Если организация товара отличается от текущей в корзине
|
|
180
|
+
if (shopcart.state.organization && shopcart.state.organization !== product.owner.target) {
|
|
181
|
+
const result = await proxy.$alert({
|
|
182
|
+
title: 'Start a new order?',
|
|
183
|
+
message: `Your cart has items from another vendor. If you continue, we'll clear it so you can order from this one instead.`,
|
|
184
|
+
actions: [
|
|
185
|
+
{ label: 'Cancel', value: false },
|
|
186
|
+
{ label: 'Start New Order', value: true }
|
|
187
|
+
]
|
|
188
|
+
})
|
|
189
|
+
|
|
190
|
+
if (!result) throw error
|
|
191
|
+
|
|
174
192
|
shopcart.state.organization = product.owner.target
|
|
175
193
|
shopcart.state.positions = []
|
|
176
194
|
}
|
|
195
|
+
|
|
177
196
|
await shopcart.actions.addProductToCart(product, product.owner.target, selectedDates)
|
|
178
197
|
return true
|
|
179
198
|
} catch (error) {
|
|
180
|
-
console.error('
|
|
199
|
+
console.error('Error while adding product to cart:', error)
|
|
181
200
|
throw error
|
|
182
201
|
}
|
|
183
202
|
}
|
|
@@ -10,6 +10,9 @@ const openai = new OpenAI({
|
|
|
10
10
|
apiKey: process.env.OPENAI_API_KEY,
|
|
11
11
|
});
|
|
12
12
|
|
|
13
|
+
const queryProcessorGlobals = require('@martyrs/src/modules/globals/controllers/utils/queryProcessor');
|
|
14
|
+
|
|
15
|
+
|
|
13
16
|
// Factory
|
|
14
17
|
const controllerFactory = (db) => {
|
|
15
18
|
const Product = db.product;
|
|
@@ -253,6 +256,10 @@ const controllerFactory = (db) => {
|
|
|
253
256
|
}
|
|
254
257
|
}
|
|
255
258
|
},
|
|
259
|
+
// For owner
|
|
260
|
+
queryProcessorGlobals.getOwnerUserLookupStage(),
|
|
261
|
+
queryProcessorGlobals.getOwnerOrganizationLookupStage(),
|
|
262
|
+
queryProcessorGlobals.getAddFieldsCreatorOwnerStage(),
|
|
256
263
|
{
|
|
257
264
|
$set: {
|
|
258
265
|
available: {
|
package/src/styles/base/all.scss
CHANGED
|
@@ -159,6 +159,7 @@ body {
|
|
|
159
159
|
.o-hidden {overflow: hidden; }
|
|
160
160
|
.o-scroll {overflow: scroll; }
|
|
161
161
|
.o-y-scroll {overflow-y: scroll; }
|
|
162
|
+
.o-x-scroll {overflow-y: scroll; }
|
|
162
163
|
.o-x-hidden {overflow-x: hidden; touch-action: pan-y;}
|
|
163
164
|
.o-auto {overflow: auto; }
|
|
164
165
|
.o-visible {overflow: visible; }
|
|
@@ -59,6 +59,28 @@ a:hover { cursor: pointer;}
|
|
|
59
59
|
.lh-medium { line-height: 1.250; }
|
|
60
60
|
.lh-regular { line-height: 1.125; }
|
|
61
61
|
.lh-light { line-height: 1.000; }
|
|
62
|
+
/*Text trim*/
|
|
63
|
+
.t-trim {
|
|
64
|
+
display: -webkit-box;
|
|
65
|
+
-webkit-box-orient: vertical;
|
|
66
|
+
overflow: hidden;
|
|
67
|
+
-webkit-line-clamp: 1;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.t-trim-2 {
|
|
71
|
+
display: -webkit-box;
|
|
72
|
+
-webkit-box-orient: vertical;
|
|
73
|
+
overflow: hidden;
|
|
74
|
+
-webkit-line-clamp: 2;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.t-trim-3 {
|
|
78
|
+
display: -webkit-box;
|
|
79
|
+
-webkit-box-orient: vertical;
|
|
80
|
+
overflow: hidden;
|
|
81
|
+
-webkit-line-clamp: 3;
|
|
82
|
+
}
|
|
83
|
+
|
|
62
84
|
|
|
63
85
|
|
|
64
86
|
// Text decoration
|