@ozdao/prometheus-framework 0.2.90 → 0.2.92

Sign up to get free protection for your applications and to get access to all the features.
Files changed (137) hide show
  1. package/dist/auth.server.js +1 -0
  2. package/dist/auth.server.mjs +1 -0
  3. package/dist/events.server.js +5 -3
  4. package/dist/events.server.mjs +5 -3
  5. package/dist/main-BQisDfLk.js +92 -0
  6. package/dist/main-DTlUA63C.mjs +13617 -0
  7. package/dist/main.css +1 -1
  8. package/dist/prometheus-framework/src/components/Block/Block.vue.cjs +1 -1
  9. package/dist/prometheus-framework/src/components/Block/Block.vue.js +1 -1
  10. package/dist/prometheus-framework/src/components/Button/Button.vue2.cjs +1 -1
  11. package/dist/prometheus-framework/src/components/Button/Button.vue2.js +24 -32
  12. package/dist/prometheus-framework/src/components/FieldPhone/FieldPhone.vue.cjs +1 -1
  13. package/dist/prometheus-framework/src/components/FieldPhone/FieldPhone.vue.js +17 -16
  14. package/dist/prometheus-framework/src/components/Select/Select.vue.cjs +1 -1
  15. package/dist/prometheus-framework/src/components/Select/Select.vue.js +1 -103
  16. package/dist/prometheus-framework/src/components/Select/Select.vue2.cjs +1 -1
  17. package/dist/prometheus-framework/src/components/Select/Select.vue2.js +103 -1
  18. package/dist/prometheus-framework/src/components/Spoiler/Spoiler.vue.cjs +1 -1
  19. package/dist/prometheus-framework/src/components/Spoiler/Spoiler.vue.js +1 -36
  20. package/dist/prometheus-framework/src/components/Spoiler/Spoiler.vue2.cjs +1 -1
  21. package/dist/prometheus-framework/src/components/Spoiler/Spoiler.vue2.js +36 -1
  22. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.cjs +1 -1
  23. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.js +1 -45
  24. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.cjs +1 -1
  25. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.js +45 -1
  26. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.cjs +1 -1
  27. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.js +7 -6
  28. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.cjs +1 -1
  29. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.js +28 -29
  30. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
  31. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +64 -64
  32. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.cjs +1 -1
  33. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.js +37 -38
  34. package/dist/prometheus-framework/src/modules/auth/store/auth.cjs +1 -1
  35. package/dist/prometheus-framework/src/modules/auth/store/auth.js +35 -37
  36. package/dist/prometheus-framework/src/modules/auth/store/twofa.cjs +1 -1
  37. package/dist/prometheus-framework/src/modules/auth/store/twofa.js +3 -3
  38. package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.cjs +1 -1
  39. package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.js +1 -1
  40. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +1 -1
  41. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +10 -9
  42. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
  43. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +1 -1
  44. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.cjs +1 -5
  45. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.js +0 -66
  46. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.cjs +5 -1
  47. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.js +66 -0
  48. package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.cjs +1 -1
  49. package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.js +1 -1
  50. package/dist/prometheus-framework/src/modules/events/components/layouts/layoutEvents.vue.cjs +1 -1
  51. package/dist/prometheus-framework/src/modules/events/components/layouts/layoutEvents.vue.js +14 -48
  52. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +1 -1
  53. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +1 -1
  54. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.cjs +1 -1
  55. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.js +85 -25
  56. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
  57. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +1 -1
  58. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.cjs +1 -1
  59. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.js +1 -1
  60. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.cjs +1 -1
  61. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.js +69 -57
  62. package/dist/prometheus-framework/src/modules/landing/components/sections/SectionFeatures.vue.cjs +1 -0
  63. package/dist/prometheus-framework/src/modules/landing/components/sections/SectionFeatures.vue.js +74 -0
  64. package/dist/prometheus-framework/src/modules/landing/landing.client.cjs +1 -1
  65. package/dist/prometheus-framework/src/modules/landing/landing.client.js +4 -2
  66. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
  67. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +3 -2
  68. package/dist/prometheus-framework/src/modules/middlewares/client/inputs.validation.cjs +1 -1
  69. package/dist/prometheus-framework/src/modules/middlewares/client/inputs.validation.js +10 -13
  70. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +1 -1
  71. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +1 -1
  72. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.cjs +1 -1
  73. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +1 -1
  74. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.cjs +1 -1
  75. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.js +1 -1
  76. package/dist/prometheus-framework/src/modules/orders/components/sections/FormPayment.vue.cjs +1 -1
  77. package/dist/prometheus-framework/src/modules/orders/components/sections/FormPayment.vue.js +1 -1
  78. package/dist/prometheus-framework/src/modules/orders/router/orders.backoffice.router.cjs +1 -1
  79. package/dist/prometheus-framework/src/modules/orders/router/orders.backoffice.router.js +6 -8
  80. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardDepartment.vue.cjs +1 -1
  81. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardDepartment.vue.js +1 -1
  82. package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.cjs +1 -1
  83. package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.js +1 -1
  84. package/dist/prometheus-framework/src/modules/organizations/components/pages/Department.vue.cjs +1 -1
  85. package/dist/prometheus-framework/src/modules/organizations/components/pages/Department.vue.js +1 -1
  86. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
  87. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +1 -1
  88. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +1 -1
  89. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +1 -1
  90. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +1 -1
  91. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.js +3 -2
  92. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +1 -1
  93. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +1 -1
  94. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
  95. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +4 -3
  96. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +1 -1
  97. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +1 -1
  98. package/dist/prometheus-framework/src/modules/products/components/blocks/CardProduct.vue.cjs +1 -1
  99. package/dist/prometheus-framework/src/modules/products/components/blocks/CardProduct.vue.js +36 -25
  100. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +1 -1
  101. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +1 -1
  102. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
  103. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +1 -1
  104. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +1 -1
  105. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +7 -6
  106. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.cjs +1 -1
  107. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.js +1 -1
  108. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.cjs +1 -1
  109. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +1 -1
  110. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
  111. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +3 -2
  112. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
  113. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +5 -4
  114. package/dist/prometheus-framework.cjs.js +1 -1
  115. package/dist/prometheus-framework.es.js +1 -1
  116. package/dist/style.css +1 -1
  117. package/dist/web-CXzcKdk4.mjs +54 -0
  118. package/dist/web-D9Cfcy5k.js +1 -0
  119. package/package.json +1 -1
  120. package/src/components/Button/Button.vue +5 -8
  121. package/src/components/FieldPhone/FieldPhone.vue +4 -0
  122. package/src/modules/auth/components/pages/ResetPassword.vue +1 -1
  123. package/src/modules/auth/components/pages/SignIn.vue +3 -3
  124. package/src/modules/auth/components/pages/SignUp.vue +1 -1
  125. package/src/modules/auth/controllers/auth.controller.js +1 -0
  126. package/src/modules/auth/store/auth.js +3 -5
  127. package/src/modules/auth/store/twofa.js +1 -1
  128. package/src/modules/events/components/layouts/layoutEvents.vue +2 -59
  129. package/src/modules/events/components/pages/Events.vue +106 -23
  130. package/src/modules/events/controllers/events.controller.js +6 -3
  131. package/src/modules/globals/components/blocks/CardHeader.vue +29 -4
  132. package/src/modules/landing/landing.client.js +3 -1
  133. package/src/modules/middlewares/client/inputs.validation.js +0 -13
  134. package/src/modules/orders/components/sections/SubscribeNewsletter.vue +2 -2
  135. package/src/modules/orders/router/orders.backoffice.router.js +2 -4
  136. package/src/modules/products/components/blocks/CardProduct.vue +31 -20
  137. package/src/modules/products/components/sections/HeroRecommendation.vue +1 -1
@@ -23,7 +23,7 @@
23
23
  <div v-if="tabAuth === 'phone'" class="mn-b-semi radius-small o-hidden">
24
24
  <p class="mn-b-small t-transp">{{ t('smsInfo') }}</p>
25
25
  <FieldPhone
26
- v-model:modelValue="auth.state.user.phone"
26
+ @change="(event) => auth.state.user.phone = event"
27
27
  :dropdownOptions="{
28
28
  showDialCodeInSelection: true,
29
29
  showFlags: true,
@@ -30,15 +30,16 @@
30
30
  <transition name="slide-fade">
31
31
  <div v-show="tabAuth === 'phone'" class="mn-b-thin radius-small">
32
32
  <FieldPhone
33
- v-model:modelValue="auth.state.user.phone"
33
+ @change="(event) => auth.state.user.phone = event"
34
34
  :dropdownOptions="{
35
35
  showDialCodeInSelection: true,
36
36
  showFlags: true,
37
37
  showDialCodeInList: true
38
38
  }"
39
+ :validCharactersOnly="true"
39
40
  :validation="phoneValidation"
40
41
  mode="national"
41
- :inputOptions="{placeholder: t('phonePlaceholder')}"
42
+ :inputOptions="{placeholder: t('phonePlaceholder'), type: 'tel'}"
42
43
  class="bg-grey pd-small radius-small mn-b-thin"
43
44
  />
44
45
 
@@ -165,7 +166,6 @@ async function onSubmit() {
165
166
 
166
167
  // COSTIL PLEASE GOD MAKE IT GOOD, FUKEN INPUT COMPONENT RETURN OBJECT NUT NUMBER
167
168
  const userCopy = {...auth.state.user};
168
- userCopy.phone = auth.state.user.phone.number
169
169
  // COSTIL PLEASE GOD MAKE IT GOOD, FUKEN INPUT COMPONENT RETURN OBJECT NUT NUMBER
170
170
 
171
171
  await auth.actions.login(userCopy, tabAuth.value)
@@ -22,7 +22,7 @@
22
22
  <div v-show="tabAuth === 'phone'" class="mn-b-semi radius-small">
23
23
  <p class="mn-b-small t-transp">{{t('smsNotice')}}</p>
24
24
  <FieldPhone
25
- v-model:modelValue="auth.state.user.phone"
25
+ @change="(event) => auth.state.user.phone = event"
26
26
  :dropdownOptions="{
27
27
  showDialCodeInSelection: true,
28
28
  showFlags: true,
@@ -44,6 +44,7 @@ const controllerFactory = (db) => {
44
44
  const passwordIsValid = bcrypt.compareSync(req.body.password, user.password);
45
45
 
46
46
  if (!passwordIsValid) {
47
+ console.log('req obdy is', req.body)
47
48
  return res.status(401).send({ errorCode: "INCORRECT_PASSWORD_ENTERED", accessToken: null });
48
49
  }
49
50
  }
@@ -10,7 +10,7 @@
10
10
  // State
11
11
  import * as twofa from './twofa'
12
12
  // Setup Axios
13
- const $axios = axios.create({ baseURL: process.env.API_URL, withCredentials: true })
13
+ const $axios = axios.create({ baseURL: process.env.API_URL, withCredentials: true });
14
14
  // State
15
15
  const state = reactive({
16
16
  user: {
@@ -104,8 +104,6 @@
104
104
  }
105
105
 
106
106
  try {
107
- if (user.phone?.number) user.phone = user.phone.number
108
-
109
107
  const response = await $axios.post('/api/auth/signup', {
110
108
  ...user,
111
109
  type,
@@ -156,7 +154,7 @@
156
154
  try {
157
155
  const response = await $axios.post('/api/auth/reset-password', {
158
156
  email: user.email,
159
- phone: user.phone.number,
157
+ phone: user.phone,
160
158
  type
161
159
  });
162
160
 
@@ -188,7 +186,7 @@
188
186
  try {
189
187
  const response = await $axios.post('/api/auth/update-password', {
190
188
  email: user.email,
191
- phone: user.phone.number,
189
+ phone: user.phone,
192
190
  password: user.password,
193
191
  passwordRepeat: user.passwordRepeat,
194
192
  type
@@ -24,7 +24,7 @@ async function sendCode (user, method, type) {
24
24
  if (method === 'reset-password') api = '/api/twofa/sendcodereset'
25
25
 
26
26
  return await $axios.post(api, {
27
- phone: user.phone.number,
27
+ phone: user.phone,
28
28
  email: user.email,
29
29
  method: method,
30
30
  type: type
@@ -1,12 +1,5 @@
1
1
  <template>
2
-
3
2
  <div class="pd-thin h-min-100">
4
- <DatePicker
5
- v-model:date="events.state.filter.date"
6
- :locale="$i18n.locale"
7
- class="radius-semi o-hidden bg-grey mn-b-thin pd-l-zero pd-r-zero pd-medium"
8
- />
9
-
10
3
  <router-view v-slot="{ Component, route }">
11
4
  <transition name="scaleIn" mode="out-in">
12
5
  <component ref="page" :key="route.query" :is="Component" />
@@ -17,60 +10,10 @@
17
10
 
18
11
  <script setup="props">
19
12
  import { computed,onMounted, toRefs,ref, watch } from 'vue'
20
- import { useRoute,useRouter } from 'vue-router'
21
-
22
- import Select from '@pf/src/components/Select/Select.vue'
23
- import DatePicker from '@pf/src/components/DatePicker/DatePicker.vue'
24
- // Import state
25
- import * as events from '@pf/src/modules/events/store/events.js';
26
-
27
- // State
13
+ import { useRoute,useRouter } from 'vue-router';
14
+ // Router
28
15
  const route = useRoute();
29
16
  const router = useRouter()
30
-
31
- let baseDate = new Date();
32
- const formattedDate = formatDateForRouter(baseDate);
33
-
34
- function formatDateForRouter(date) {
35
- return `${date.getDate().toString().padStart(2, '0')}${(date.getMonth() + 1).toString().padStart(2, '0')}${date.getFullYear()}`;
36
- }
37
-
38
- if (route.query) {
39
- const query = route.query;
40
-
41
- const newFilterValue = {
42
- tags: query.tags ? query.tags.split(',') : null,
43
- date: query.date ? query.date : formattedDate,
44
- };
45
-
46
- events.state.filter = newFilterValue; // <-- Modified
47
- } else {
48
- const newFilterValue = {
49
- date: formattedDate,
50
- };
51
-
52
- events.state.filter = newFilterValue;
53
- }
54
-
55
- watch(() => events.state.filter, (newFilterValue, oldFilterValue) => { // <-- Modified
56
- const query = { ...route.query };
57
-
58
- Object.keys(oldFilterValue).forEach(key => {
59
- if (query[key]) {
60
- delete query[key];
61
- }
62
- });
63
-
64
- const newQueryValues = Object.fromEntries(
65
- Object.entries(newFilterValue)
66
- .filter(([key, value]) => (Array.isArray(value) && value.length > 0) || (typeof value === 'string' && value))
67
- .map(([key, value]) => [key, Array.isArray(value) ? value.join(',') : value])
68
- );
69
- Object.assign(query, newQueryValues);
70
-
71
- router.push({ query });
72
- }, { deep: true })
73
-
74
17
  </script>
75
18
 
76
19
  <style lang="scss">
@@ -1,34 +1,72 @@
1
1
  <template>
2
2
  <section class="pd-thin">
3
+ <header
4
+ class="mn-b-medium flex-v-center flex-nowrap flex"
5
+ >
6
+ <h2
7
+ class="mn-r-medium"
8
+ >
9
+ Featured
10
+ </h2>
11
+ </header>
3
12
  <List
4
13
  :user="auth.state.user._id"
5
- class="bg-grey mn-b-thin radius-big"
6
- :phase="'week'"
14
+ class="bg-grey mn-b-medium radius-big"
15
+ :phase="'planned'"
7
16
  />
8
17
  <header
9
18
  class="mn-b-medium flex-v-center flex-nowrap flex"
10
19
  >
11
- <h2
12
- class="mn-r-medium"
13
- >
14
- Events
15
- </h2>
16
-
17
- <button
18
- @click="router.push({name: 'Create Event'})"
19
- class="radius-100 i-big hover-scale-1 cursor-pointer t-white bg-second"
20
- >
21
- +
22
- </button>
20
+ <h2
21
+ class="mn-r-medium"
22
+ >
23
+ All Events
24
+ </h2>
25
+
26
+ <button
27
+ @click="router.push({name: 'Create Event'})"
28
+ class="radius-100 i-big hover-scale-1 cursor-pointer t-white bg-second"
29
+ >
30
+ +
31
+ </button>
23
32
  </header>
24
33
 
25
-
26
- <Feed
27
- :user="auth.state.user._id"
28
- :owner="route.params._id"
29
- :sortOrder="'desc'"
30
- :sortParam="'date.start'"
34
+ <DatePicker
35
+ v-model:date="events.state.filter.date"
36
+ :locale="$i18n.locale"
37
+ class="radius-semi o-hidden bg-grey mn-b-thin pd-l-zero pd-r-zero pd-medium"
31
38
  />
39
+
40
+ <Feed
41
+ :states="{
42
+ empty: {
43
+ title: 'No Events Found',
44
+ description: 'Currently, there are no events available.'
45
+ }
46
+ }"
47
+ :store="{
48
+ read: (options) => events.read(options),
49
+ state: events.state
50
+ }"
51
+ :options="{
52
+ user: auth.state.user._id,
53
+ date: events.state.filter.date,
54
+ limit: 10
55
+ }"
56
+ v-slot="{
57
+ items
58
+ }"
59
+ >
60
+ <CardEvent
61
+ @click="$router.push({name: 'Event', params: {url: event.url}})"
62
+ v-for="(event,index) in items"
63
+ :key="event._id"
64
+ :event="event"
65
+ :user="auth.state.user._id"
66
+ :type="'normal'"
67
+ class="bg-grey radius-big mn-b-medium"
68
+ />
69
+ </Feed>
32
70
  </section>
33
71
  </template>
34
72
 
@@ -37,16 +75,61 @@
37
75
  import { useRoute, useRouter } from 'vue-router';
38
76
 
39
77
  import Breadcrumbs from '@pf/src/components/Breadcrumbs/Breadcrumbs.vue';
40
- import Feed from '@pf/src/modules/events/components/sections/Feed.vue';
41
- import List from '@pf/src/modules/events/components/sections/List.vue';
78
+ import Feed from '@pf/src/components/Feed/Feed.vue'
79
+ import DatePicker from '@pf/src/components/DatePicker/DatePicker.vue'
42
80
 
81
+ import List from '@pf/src/modules/events/components/sections/List.vue';
82
+ import CardEvent from '@pf/src/modules/events/components/blocks/CardEvent.vue';
43
83
  // Import state
44
- import * as events from '@pf/src/modules/events/store/events.js'; // <-- Modified
84
+ import * as events from '@pf/src/modules/events/store/events.js';
45
85
  import * as auth from '@pf/src/modules/auth/store/auth'
46
86
 
47
87
  // State
48
88
  const route = useRoute();
49
89
  const router = useRouter();
90
+
91
+ let baseDate = new Date();
92
+ const formattedDate = formatDateForRouter(baseDate);
93
+
94
+ function formatDateForRouter(date) {
95
+ return `${date.getDate().toString().padStart(2, '0')}${(date.getMonth() + 1).toString().padStart(2, '0')}${date.getFullYear()}`;
96
+ }
97
+
98
+ if (route.query) {
99
+ const query = route.query;
100
+
101
+ const newFilterValue = {
102
+ tags: query.tags ? query.tags.split(',') : null,
103
+ date: query.date ? query.date : formattedDate,
104
+ };
105
+
106
+ events.state.filter = newFilterValue; // <-- Modified
107
+ } else {
108
+ const newFilterValue = {
109
+ date: formattedDate,
110
+ };
111
+
112
+ events.state.filter = newFilterValue;
113
+ }
114
+
115
+ watch(() => events.state.filter, (newFilterValue, oldFilterValue) => { // <-- Modified
116
+ const query = { ...route.query };
117
+
118
+ Object.keys(oldFilterValue).forEach(key => {
119
+ if (query[key]) {
120
+ delete query[key];
121
+ }
122
+ });
123
+
124
+ const newQueryValues = Object.fromEntries(
125
+ Object.entries(newFilterValue)
126
+ .filter(([key, value]) => (Array.isArray(value) && value.length > 0) || (typeof value === 'string' && value))
127
+ .map(([key, value]) => [key, Array.isArray(value) ? value.join(',') : value])
128
+ );
129
+ Object.assign(query, newQueryValues);
130
+
131
+ router.push({ query });
132
+ }, { deep: true })
50
133
  </script>
51
134
 
52
135
  <style lang="scss">
@@ -127,10 +127,13 @@ const middlewareFactory = (db) => {
127
127
  event = req.body
128
128
 
129
129
  // Update related product and payment link
130
- const { product, price, paymentLink } = await serviceStripe.updateProduct(event);
130
+ if (event.special) {
131
+ const { product, price, paymentLink } = await serviceStripe.updateProduct(event);
132
+
133
+ if (paymentLink) {
134
+ event.specialData.ticketLinkStripe = paymentLink.url; // Update with new payment link
135
+ }
131
136
 
132
- if (paymentLink) {
133
- event.specialData.ticketLinkStripe = paymentLink.url; // Update with new payment link
134
137
  }
135
138
 
136
139
  await Event.updateOne({ _id: event._id }, { $set: event });
@@ -78,7 +78,7 @@
78
78
 
79
79
  <div class="d-block mn-l-auto flex-nowrap flex flex-v-center">
80
80
 
81
- <div v-if="members" class="w-4r i-thin">
81
+ <div v-if="members" class="w-4r pos-relative i-thin">
82
82
  <!-- Круг с числом участников -->
83
83
  <span
84
84
  :style="{
@@ -103,8 +103,12 @@
103
103
  </span>
104
104
 
105
105
  <!-- Аватарки -->
106
- <img
107
- v-for="(photo, index) in membersPhotos.slice(0,2)"
106
+ <template
107
+ v-for="(photo, index) in membersPhotos.slice(0,2)"
108
+ >
109
+ <img
110
+ v-if="photo"
111
+
108
112
  :key="index"
109
113
  :src="(FILE_SERVER_URL || '') + photo"
110
114
  :style="{
@@ -121,7 +125,28 @@
121
125
  bg-grey
122
126
  radius-big
123
127
  "
124
- />
128
+ />
129
+
130
+ <PlaceholderUserpic
131
+ v-else
132
+ :style="{
133
+ position: 'absolute',
134
+ top: '0px',
135
+ right: (index * 20 + 20) + '%',
136
+ zIndex: 1 - index
137
+ }"
138
+ class="
139
+ br-solid
140
+ br-2px
141
+ br-white
142
+ i-thin
143
+ bg-grey
144
+ radius-big
145
+ "
146
+ />
147
+ </template>
148
+
149
+
125
150
  </div>
126
151
  </div>
127
152
 
@@ -1,6 +1,8 @@
1
1
  // Importing Vue components
2
2
  import MobileApp from './components/sections/MobileApp.vue';
3
+ import SectionFeatures from './components/sections/SectionFeatures.vue';
3
4
 
4
5
  export {
5
- MobileApp
6
+ MobileApp,
7
+ SectionFeatures
6
8
  };
@@ -55,19 +55,6 @@ function validateLength(input) {
55
55
  }
56
56
 
57
57
  function validatePhone(phone) {
58
- // const phoneRegex = /^.{6,}$/;
59
-
60
- // console.log(parsePhoneNumberFromString(phone))
61
- console.log(phone)
62
-
63
- console.log(phone.valid)
64
- if (!phone.valid) {
65
- return {
66
- status: false,
67
- message: i18n.global.t("validation.phone")
68
- }
69
- }
70
-
71
58
  return {
72
59
  status: true,
73
60
  message: null
@@ -88,7 +88,7 @@ async function sendApplication() {
88
88
  }
89
89
  </script>
90
90
 
91
- <style lang="scss">
91
+ <style lang="scss" scoped>
92
92
  .spiral {
93
93
  background-image: url('https://weeder.delivery/spiral.jpg');
94
94
  background-size: cover;
@@ -97,7 +97,7 @@ async function sendApplication() {
97
97
  position: absolute;
98
98
  top: 50%;
99
99
  left: 50%;
100
- opacity: 0.03;
100
+ opacity: 0.066;
101
101
  transform: translate(-50%, -50%) rotate(0deg);
102
102
  transform-origin: center center;
103
103
  animation: spin 5s linear infinite;
@@ -1,16 +1,15 @@
1
- import layoutEmpty from '@pf/src/modules/globals/components/layouts/Empty.vue'
1
+ import layoutEmpty from '@pf/src/modules/globals/components/layouts/Empty.vue';
2
2
 
3
3
  const orders = [
4
4
  {
5
5
  path: 'orders',
6
- name: 'Backoffice Orders',
7
6
  meta: {
8
7
  title: {
9
8
  en: 'Backoffice Orders',
10
9
  ru: 'Управление Заказами'
11
10
  },
12
- authorize: []
13
11
  },
12
+ component: layoutEmpty,
14
13
  children: [{
15
14
  path: '',
16
15
  name: 'Backoffice Orders',
@@ -19,7 +18,6 @@ const orders = [
19
18
  en: 'Backoffice Orders',
20
19
  ru: 'Управление Заказами'
21
20
  },
22
- authorize: []
23
21
  },
24
22
  component: () => import(/* webpackChunkName: 'BackofficeOrders' */ '@pf/src/modules/orders/components/pages/Orders.vue'),
25
23
  },{
@@ -14,25 +14,26 @@
14
14
  "
15
15
  >
16
16
 
17
- <router-link
18
- :to="{
19
- name: 'ProductEdit',
20
- params: {
21
- _id: $route.params.organization,
22
- product: product._id
23
- }
24
- }"
25
- class="
26
- z-index-2
27
- cursor-pointer
28
- pos-absolute pos-t-regular pos-r-regular
29
- radius-extra pd-thin bg-second
30
- "
31
- >
32
- <IconEdit
33
- class="i-regular"
34
- classes="fill-white"
35
- />
17
+ <router-link
18
+ v-if="user"
19
+ :to="{
20
+ name: 'ProductEdit',
21
+ params: {
22
+ _id: $route.params.organization,
23
+ product: product._id
24
+ }
25
+ }"
26
+ class="
27
+ z-index-2
28
+ cursor-pointer
29
+ pos-absolute pos-t-regular pos-r-regular
30
+ radius-extra pd-thin bg-second
31
+ "
32
+ >
33
+ <IconEdit
34
+ class="i-regular"
35
+ classes="fill-white"
36
+ />
36
37
  </router-link>
37
38
 
38
39
  <!-- Product Image Sqaure -->
@@ -121,7 +122,17 @@
121
122
 
122
123
  import PlaceholderImage from '@pf/src/modules/icons/placeholders/PlaceholderImage.vue'
123
124
 
124
- const props = defineProps(['product'])
125
+ const props = defineProps({
126
+ product: {
127
+ type: Object
128
+ },
129
+ user: {
130
+ type: [Object, String]
131
+ },
132
+ type: {
133
+ type: Object
134
+ }
135
+ })
125
136
 
126
137
  const { t } = useI18n()
127
138
  </script>
@@ -161,7 +161,7 @@
161
161
  position: absolute;
162
162
  top: 50%;
163
163
  left: 50%;
164
- opacity: 0.03;
164
+ opacity: 0.066;
165
165
  transform: translate(-50%, -50%) rotate(0deg);
166
166
  transform-origin: center center;
167
167
  animation: spin 5s linear infinite;