@ozdao/prometheus-framework 0.2.51 → 0.2.53

Sign up to get free protection for your applications and to get access to all the features.
Files changed (142) hide show
  1. package/dist/main-0a2437f4.js +91 -0
  2. package/dist/main-482dc398.mjs +13626 -0
  3. package/dist/main-4fnApBsF.js +91 -0
  4. package/dist/main-b2JI9sFg.js +91 -0
  5. package/dist/main-c56d4c09.js +91 -0
  6. package/dist/main-cdd0be68.mjs +13628 -0
  7. package/dist/main-kjbLXQEa.mjs +13606 -0
  8. package/dist/main-x-9D8zvb.mjs +13604 -0
  9. package/dist/main.css +1 -1
  10. package/dist/organizations.server.js +2 -2
  11. package/dist/organizations.server.mjs +2 -2
  12. package/dist/products.server.js +81 -56
  13. package/dist/products.server.mjs +81 -56
  14. package/dist/prometheus-framework/src/components/Button/Button.vue2.cjs +1 -1
  15. package/dist/prometheus-framework/src/components/Button/Button.vue2.js +18 -20
  16. package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
  17. package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +19 -19
  18. package/dist/prometheus-framework/src/components/Field/Field.vue2.cjs +1 -1
  19. package/dist/prometheus-framework/src/components/Field/Field.vue2.js +28 -26
  20. package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.cjs +1 -1
  21. package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.js +2 -2
  22. package/dist/prometheus-framework/src/components/Map/Map.vue.cjs +1 -1
  23. package/dist/prometheus-framework/src/components/Map/Map.vue.js +35 -2
  24. package/dist/prometheus-framework/src/components/Map/Map.vue2.cjs +1 -1
  25. package/dist/prometheus-framework/src/components/Map/Map.vue2.js +2 -35
  26. package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.cjs +1 -1
  27. package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.js +1 -1
  28. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.cjs +1 -0
  29. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.js +37 -0
  30. package/dist/prometheus-framework/src/modules/icons/entities/IconShopcart.vue.cjs +1 -1
  31. package/dist/prometheus-framework/src/modules/icons/entities/IconShopcart.vue.js +21 -14
  32. package/dist/prometheus-framework/src/modules/icons/navigation/IconSearch.vue.cjs +1 -0
  33. package/dist/prometheus-framework/src/modules/icons/navigation/IconSearch.vue.js +24 -0
  34. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
  35. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +1 -1
  36. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue.cjs +1 -1
  37. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue.js +2 -11
  38. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue2.cjs +1 -1
  39. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue2.js +11 -2
  40. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardDepartment.vue.cjs +1 -1
  41. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardDepartment.vue.js +49 -101
  42. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.js +25 -25
  43. package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.cjs +1 -1
  44. package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.js +68 -39
  45. package/dist/prometheus-framework/src/modules/organizations/components/blocks/User.vue.cjs +1 -1
  46. package/dist/prometheus-framework/src/modules/organizations/components/blocks/User.vue.js +38 -48
  47. package/dist/prometheus-framework/src/modules/organizations/components/pages/Department.vue.cjs +1 -1
  48. package/dist/prometheus-framework/src/modules/organizations/components/pages/Department.vue.js +69 -62
  49. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
  50. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +131 -126
  51. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.cjs +1 -1
  52. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.js +1 -1
  53. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.cjs +1 -1
  54. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.js +117 -146
  55. package/dist/prometheus-framework/src/modules/organizations/components/sections/Feed.vue.cjs +1 -1
  56. package/dist/prometheus-framework/src/modules/organizations/components/sections/Feed.vue.js +13 -13
  57. package/dist/prometheus-framework/src/modules/organizations/router/products.router.cjs +1 -1
  58. package/dist/prometheus-framework/src/modules/organizations/router/products.router.js +22 -0
  59. package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue.cjs +1 -0
  60. package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue.js +45 -0
  61. package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue2.cjs +1 -0
  62. package/dist/prometheus-framework/src/modules/products/components/blocks/CardCategory.vue2.js +4 -0
  63. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs +1 -0
  64. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +79 -0
  65. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +1 -0
  66. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +193 -0
  67. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue2.cjs +1 -0
  68. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue2.js +4 -0
  69. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
  70. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +43 -43
  71. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +1 -1
  72. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +65 -55
  73. package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.cjs +1 -1
  74. package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.js +64 -51
  75. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.cjs +1 -1
  76. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.js +35 -33
  77. package/dist/prometheus-framework/src/modules/products/products.client.cjs +1 -1
  78. package/dist/prometheus-framework/src/modules/products/products.client.js +2 -2
  79. package/dist/prometheus-framework/src/modules/products/store/categories.cjs +1 -1
  80. package/dist/prometheus-framework/src/modules/products/store/categories.js +39 -27
  81. package/dist/prometheus-framework/src/modules/products/store/products.cjs +1 -1
  82. package/dist/prometheus-framework/src/modules/products/store/products.js +23 -23
  83. package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.cjs +1 -1
  84. package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.js +1 -1
  85. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
  86. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +1 -1
  87. package/dist/prometheus-framework.cjs.js +1 -1
  88. package/dist/prometheus-framework.es.js +1 -1
  89. package/dist/style.css +1 -1
  90. package/dist/web-0066fd51.mjs +55 -0
  91. package/dist/web-6b9fa713.js +1 -0
  92. package/dist/web-6dcbb74b.mjs +55 -0
  93. package/dist/web-caJAdsxy.js +1 -0
  94. package/dist/web-ee302c1d.js +1 -0
  95. package/dist/web-i08OVMw9.mjs +55 -0
  96. package/dist/web-ngl7bNhF.js +1 -0
  97. package/dist/web-t91TrxXa.mjs +55 -0
  98. package/package.json +1 -1
  99. package/src/components/Button/Button.vue +4 -6
  100. package/src/components/Feed/Feed.vue +2 -1
  101. package/src/components/Field/Field.vue +3 -1
  102. package/src/components/LocationMarker/LocationMarker.vue +1 -0
  103. package/src/modules/applications/applications.client.js +0 -1
  104. package/src/modules/globals/components/blocks/BlockSearch.vue +42 -0
  105. package/src/modules/icons/entities/IconProfile.vue +10 -1
  106. package/src/modules/icons/entities/IconShopcart.vue +12 -2
  107. package/src/modules/marketplace/components/layouts/Marketplace.vue +7 -14
  108. package/src/modules/marketplace/components/sections/Filters.vue +7 -1
  109. package/src/modules/mobile/components/NavigationBar/NavigationBar.vue +27 -7
  110. package/src/modules/orders/components/partials/ShopCart.vue +4 -1
  111. package/src/modules/organizations/components/blocks/CardDepartment.vue +34 -66
  112. package/src/modules/organizations/components/blocks/DepartmentMemberModify.vue +50 -13
  113. package/src/modules/organizations/components/blocks/User.vue +18 -9
  114. package/src/modules/organizations/components/pages/Department.vue +19 -3
  115. package/src/modules/organizations/components/pages/DepartmentEdit.vue +14 -10
  116. package/src/modules/organizations/components/pages/Organization.vue +38 -71
  117. package/src/modules/organizations/components/sections/Feed.vue +1 -1
  118. package/src/modules/organizations/controllers/memberships.controller.js +2 -2
  119. package/src/modules/organizations/controllers/organizations.controller.js +0 -1
  120. package/src/modules/organizations/router/products.router.js +24 -4
  121. package/src/modules/products/components/blocks/CardCategory.vue +53 -0
  122. package/src/modules/products/components/pages/Categories.vue +90 -0
  123. package/src/modules/products/components/pages/CategoryEdit.vue +214 -0
  124. package/src/modules/products/components/pages/EditLeftover.vue +6 -4
  125. package/src/modules/products/components/pages/ProductEdit.vue +9 -1
  126. package/src/modules/products/components/pages/Products.vue +58 -38
  127. package/src/modules/products/components/sections/FilterProducts.vue +9 -6
  128. package/src/modules/products/controllers/categories.controller.js +30 -13
  129. package/src/modules/products/controllers/leftovers.controller.js +12 -5
  130. package/src/modules/products/controllers/products.controller.js +18 -0
  131. package/src/modules/products/models/category.model.js +42 -32
  132. package/src/modules/products/products.client.js +4 -2
  133. package/src/modules/products/store/categories.js +17 -3
  134. package/src/modules/products/store/products.js +4 -0
  135. package/src/modules/backoffice/components/admin/Categories.vue +0 -53
  136. package/src/modules/backoffice/components/admin/CategoryEdit.vue +0 -98
  137. package/src/modules/products/components/blocks/CategoryCard.vue +0 -42
  138. package/src/modules/products/router/products.router.js +0 -48
  139. /package/src/modules/{products → organizations}/components/pages/OrganizationCreate.vue +0 -0
  140. /package/src/modules/{products → organizations}/components/pages/OrganizationDetails.vue +0 -0
  141. /package/src/modules/{products → organizations}/components/pages/OrganizationDocuments.vue +0 -0
  142. /package/src/modules/{products → organizations}/components/pages/OrganizationPeople.vue +0 -0
@@ -47,6 +47,7 @@ let map, marker;
47
47
 
48
48
  onMounted(() => {
49
49
  console.log(props.location)
50
+
50
51
  map = new google.maps.Map(mapContainer.value, {
51
52
  center: props.location,
52
53
  zoom: 15,
@@ -1,2 +1 @@
1
-
2
1
  import SubscribeNewsletter from './components/sections/SubscribeNewsletter.vue';
@@ -0,0 +1,42 @@
1
+ <script setup>
2
+ import { ref } from 'vue';
3
+
4
+ import IconSearch from '@pf/src/modules/icons/navigation/IconSearch.vue';
5
+ import Field from '@pf/src/components/Field/Field.vue';
6
+
7
+ const emits = defineEmits(['search']);
8
+ const props = defineProps({
9
+ placeholder: {
10
+ type: String,
11
+ default: 'Enter shop or product name'
12
+ },
13
+ button: {
14
+ type: String,
15
+ default: 'Search'
16
+ },
17
+ });
18
+
19
+ const stateSearch = ref(null)
20
+
21
+ const updateSearch = (search) => {
22
+ emits('search', search);
23
+ };
24
+ </script>
25
+
26
+ <template>
27
+ <div class="flex-v-center flex-nowrap flex pd-small bg-grey w-100 radius-big">
28
+ <IconSearch class="i-medium t-transp mn-r-thin" />
29
+ <Field
30
+ :placeholder="placeholder"
31
+ @update:field="search => stateSearch = search"
32
+ class="w-100"
33
+ />
34
+
35
+ <button
36
+ class="pd-r-small pd-l-small pd-t-thin pd-b-thin p-medium uppercase p-small t-medium cursor-pointer radius-extra bg-main"
37
+ @click="updateSearch(stateSearch)"
38
+ >
39
+ {{ button }}
40
+ </button>
41
+ </div>
42
+ </template>
@@ -1,5 +1,14 @@
1
1
  <template>
2
2
  <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
3
- <path d="M13.875 14.375H10.125C6.33594 14.375 3.25 17.4609 3.25 21.25C3.25 21.9531 3.79688 22.5 4.5 22.5H19.5C20.2031 22.5 20.75 21.9531 20.75 21.25C20.75 17.4609 17.6641 14.375 13.875 14.375ZM5.16406 20.625C5.47656 18.1641 7.58594 16.25 10.125 16.25H13.875C16.4141 16.25 18.5234 18.1641 18.8359 20.625H5.16406ZM12 12.5C14.7734 12.5 17 10.2734 17 7.5C17 4.72656 14.7734 2.5 12 2.5C9.22656 2.5 7 4.72656 7 7.5C7 10.2734 9.22656 12.5 12 12.5ZM12 4.375C13.7188 4.375 15.125 5.78125 15.125 7.5C15.125 9.21875 13.7188 10.625 12 10.625C10.2812 10.625 8.875 9.21875 8.875 7.5C8.875 5.78125 10.2812 4.375 12 4.375Z" fill="rgb(var(--black))"/>
3
+ <path :fill="fill" :class="$attrs.class" d="M13.875 14.375H10.125C6.33594 14.375 3.25 17.4609 3.25 21.25C3.25 21.9531 3.79688 22.5 4.5 22.5H19.5C20.2031 22.5 20.75 21.9531 20.75 21.25C20.75 17.4609 17.6641 14.375 13.875 14.375ZM5.16406 20.625C5.47656 18.1641 7.58594 16.25 10.125 16.25H13.875C16.4141 16.25 18.5234 18.1641 18.8359 20.625H5.16406ZM12 12.5C14.7734 12.5 17 10.2734 17 7.5C17 4.72656 14.7734 2.5 12 2.5C9.22656 2.5 7 4.72656 7 7.5C7 10.2734 9.22656 12.5 12 12.5ZM12 4.375C13.7188 4.375 15.125 5.78125 15.125 7.5C15.125 9.21875 13.7188 10.625 12 10.625C10.2812 10.625 8.875 9.21875 8.875 7.5C8.875 5.78125 10.2812 4.375 12 4.375Z"/>
4
4
  </svg>
5
5
  </template>
6
+
7
+ <script setup>
8
+ const props = defineProps({
9
+ fill: {
10
+ type: String,
11
+ default: 'rgb(var(--black))'
12
+ }
13
+ })
14
+ </script>
@@ -1,5 +1,15 @@
1
1
  <template>
2
2
  <svg width="49" height="49" viewBox="0 0 49 49" fill="none" xmlns="http://www.w3.org/2000/svg">
3
- <path d="M43.6479 32.1117C44.7969 31.1767 45.5809 29.8596 45.8562 28.404L48.8334 12.6366L13.0939 9.60262L12.5743 5.71378C12.3618 4.12526 11.5726 2.67323 10.3521 1.62504C9.131 0.577364 7.55684 0 5.91995 0H0.127808V3.05678H5.91943C7.7435 3.05678 9.23937 4.34089 9.47632 6.11052L13.2038 34.0001C13.4164 35.5886 14.2055 37.0411 15.4256 38.0898C16.6461 39.139 18.2203 39.7169 19.8577 39.7169H44.7404V36.6601H19.8577C18.0336 36.6601 16.5377 35.3745 16.3008 33.6038L16.2951 33.5622H39.5181C41.0326 33.5617 42.4989 33.0468 43.6479 32.1117ZM13.5087 12.7061L45.1365 15.391L42.7841 27.8484C42.4886 29.4126 41.1462 30.5049 39.5191 30.5049H15.887L13.5087 12.7061ZM22.166 40.4556C19.8416 40.4556 17.9506 42.3059 17.9506 44.5809C17.9506 46.8553 19.8416 48.7056 22.166 48.7056C24.4905 48.7056 26.3819 46.8553 26.3819 44.5809C26.3814 42.3059 24.4905 40.4556 22.166 40.4556ZM22.166 45.6488C21.5641 45.6488 21.0741 45.1694 21.0741 44.5803C21.0741 43.9913 21.5641 43.5119 22.166 43.5119C22.768 43.5119 23.258 43.9913 23.258 44.5803C23.2575 45.1699 22.768 45.6488 22.166 45.6488ZM37.3243 40.4556C34.9999 40.4556 33.1084 42.3059 33.1084 44.5809C33.1084 46.8553 34.9994 48.7056 37.3243 48.7056C39.6503 48.7056 41.5428 46.8553 41.5428 44.5809C41.5428 42.3059 39.6508 40.4556 37.3243 40.4556ZM37.3243 45.6488C36.7223 45.6488 36.2324 45.1694 36.2324 44.5803C36.2324 43.9913 36.7223 43.5119 37.3243 43.5119C37.9279 43.5119 38.4189 43.9913 38.4189 44.5803C38.4189 45.1699 37.9279 45.6488 37.3243 45.6488Z" fill="rgb(var(--black))"/>
3
+ <path :fill="fill" :class="$attrs.class" d="M43.6479 32.1117C44.7969 31.1767 45.5809 29.8596 45.8562 28.404L48.8334 12.6366L13.0939 9.60262L12.5743 5.71378C12.3618 4.12526 11.5726 2.67323 10.3521 1.62504C9.131 0.577364 7.55684 0 5.91995 0H0.127808V3.05678H5.91943C7.7435 3.05678 9.23937 4.34089 9.47632 6.11052L13.2038 34.0001C13.4164 35.5886 14.2055 37.0411 15.4256 38.0898C16.6461 39.139 18.2203 39.7169 19.8577 39.7169H44.7404V36.6601H19.8577C18.0336 36.6601 16.5377 35.3745 16.3008 33.6038L16.2951 33.5622H39.5181C41.0326 33.5617 42.4989 33.0468 43.6479 32.1117ZM13.5087 12.7061L45.1365 15.391L42.7841 27.8484C42.4886 29.4126 41.1462 30.5049 39.5191 30.5049H15.887L13.5087 12.7061ZM22.166 40.4556C19.8416 40.4556 17.9506 42.3059 17.9506 44.5809C17.9506 46.8553 19.8416 48.7056 22.166 48.7056C24.4905 48.7056 26.3819 46.8553 26.3819 44.5809C26.3814 42.3059 24.4905 40.4556 22.166 40.4556ZM22.166 45.6488C21.5641 45.6488 21.0741 45.1694 21.0741 44.5803C21.0741 43.9913 21.5641 43.5119 22.166 43.5119C22.768 43.5119 23.258 43.9913 23.258 44.5803C23.2575 45.1699 22.768 45.6488 22.166 45.6488ZM37.3243 40.4556C34.9999 40.4556 33.1084 42.3059 33.1084 44.5809C33.1084 46.8553 34.9994 48.7056 37.3243 48.7056C39.6503 48.7056 41.5428 46.8553 41.5428 44.5809C41.5428 42.3059 39.6508 40.4556 37.3243 40.4556ZM37.3243 45.6488C36.7223 45.6488 36.2324 45.1694 36.2324 44.5803C36.2324 43.9913 36.7223 43.5119 37.3243 43.5119C37.9279 43.5119 38.4189 43.9913 38.4189 44.5803C38.4189 45.1699 37.9279 45.6488 37.3243 45.6488Z"/>
4
4
  </svg>
5
- </template>
5
+ </template>
6
+
7
+
8
+ <script setup>
9
+ const props = defineProps({
10
+ fill: {
11
+ type: String,
12
+ default: 'rgb(var(--black))'
13
+ }
14
+ })
15
+ </script>
@@ -20,17 +20,9 @@
20
20
  class="mn-b-thin"
21
21
  />
22
22
 
23
- <div class="flex-v-center flex-nowrap flex pd-small bg-grey w-100 radius-big">
24
- <IconSearch
25
- class="i-medium mn-r-thin"
26
- />
27
- <Field
28
- placeholder="Enter shop or product name"
29
- @update:field="search => store.globals.state.search = search"
30
- class="w-100"
31
- />
32
- <button class="pd-thin uppercase p-small t-medium cursor-pointer radius-extra bg-main" @click="updateSearchQuery">Search</button>
33
- </div>
23
+ <BlockSearch
24
+ @search="updateSearch"
25
+ />
34
26
 
35
27
  <!-- Catalog wrapper -->
36
28
  <div class="cols-1 gap-thin pd-thin">
@@ -53,6 +45,8 @@
53
45
  import { useI18n } from 'vue-i18n'
54
46
  import { useMeta } from 'vue-meta'
55
47
  // Import components
48
+ import BlockSearch from '@pf/src/modules/globals/components/blocks/BlockSearch.vue'
49
+
56
50
  import Filters from '@pf/src/modules/marketplace/components/sections/Filters.vue'
57
51
  import IconSearch from '@pf/src/modules/icons/navigation/IconSearch.vue'
58
52
  import Field from '@pf/src/components/Field/Field.vue'
@@ -81,11 +75,10 @@
81
75
  .replace(/[^a-z0-9-]/g, '');
82
76
  }
83
77
 
84
-
85
- function updateSearchQuery() {
78
+ function updateSearch(search) {
86
79
  let query = { ...route.query}
87
80
 
88
- query.search = store.globals.state.search
81
+ query.search = search
89
82
 
90
83
  router.push({ query });
91
84
  }
@@ -185,7 +185,13 @@
185
185
  const { t } = useI18n(text)
186
186
 
187
187
  onMounted(async () => {
188
- await store.categories.actions.fetchCategories()
188
+ let options = {
189
+ status: 'published'
190
+ }
191
+
192
+ console.log(options)
193
+ console.log()
194
+ await store.categories.actions.fetchCategories(options)
189
195
 
190
196
  store.categories.state.all.forEach( category => {
191
197
  category.localization.forEach( localization => {
@@ -3,17 +3,26 @@
3
3
  class="pos-sticky w-100 z-index-4 br-b br-solid br-black-transp flex-center flex t-center pd-medium bg-white"
4
4
  >
5
5
 
6
+ <Button
7
+ v-if="route.meta.title_hide"
8
+ :submit="a => store.shopcart.actions.toggleShopcart()"
9
+ :counter="store.shopcart.getters.cartTotalAmount"
10
+ :showSucces="false"
11
+ :showLoader="false"
12
+ class="header-shopcart pd-zero mn-l-auto"
13
+ >
14
+ <IconShopcart class="i-semi" fill="#00ff88" />
15
+ </Button>
16
+
17
+
6
18
  <transition name="slideIn" mode="out-in">
7
19
 
8
- <svg
20
+ <IconProfile
9
21
  v-if="route.meta.title_hide"
10
22
  @click="handleToggle()"
11
- class="header-profile" width="26" height="26" viewBox="0 0 26 26" fill="none" xmlns="http://www.w3.org/2000/svg"
12
- >
13
- <path fill="rgb(var(--main))" d="M13.0005 1.3116e-05C10.3952 -0.0036893 7.84916 0.776533 5.6933 2.23923C3.53744 3.70193 1.87154 5.77943 0.912205 8.20159C-0.0471263 10.6238 -0.255503 13.2785 0.31417 15.8207C0.883843 18.3629 2.20521 20.6749 4.10645 22.456C4.16716 22.5296 4.23824 22.5939 4.31745 22.647C6.69461 24.8048 9.79003 26.0001 13.0005 26.0001C16.2109 26.0001 19.3063 24.8048 21.6835 22.647C21.7624 22.5939 21.8331 22.5295 21.8935 22.456C23.7946 20.6749 25.116 18.363 25.6857 15.821C26.2554 13.2789 26.0471 10.6242 25.0879 8.20206C24.1287 5.77994 22.4629 3.70243 20.3072 2.23965C18.1515 0.77688 15.6056 -0.0034882 13.0005 1.3116e-05ZM5.96345 21.445C6.30727 20.174 7.05858 19.0509 8.10211 18.248C9.14565 17.445 10.4238 17.0066 11.7405 17H14.2605C15.5774 17.006 16.856 17.444 17.8999 18.2468C18.9439 19.0496 19.6955 20.1728 20.0395 21.444C18.0658 23.095 15.5746 23.9996 13.0015 23.9996C10.4283 23.9996 7.93709 23.096 5.96345 21.445ZM21.6005 19.837C20.9791 18.4049 19.9541 17.1848 18.6506 16.3258C17.3471 15.4668 15.8215 15.0061 14.2605 15H11.7405C10.1789 15.0059 8.65303 15.4669 7.34941 16.3265C6.04579 17.1861 5.02101 18.4071 4.40045 19.84C3.10942 18.2212 2.30151 16.2708 2.06964 14.2132C1.83777 12.1556 2.19136 10.0744 3.08975 8.20883C3.98813 6.34326 5.39482 4.76915 7.14805 3.66751C8.90128 2.56587 10.9298 1.98144 13.0005 1.98144C15.0711 1.98144 17.0996 2.56587 18.8529 3.66751C20.6061 4.76915 22.0128 6.34326 22.9112 8.20883C23.8095 10.0744 24.1631 12.1556 23.9313 14.2132C23.6994 16.2708 22.8915 18.2212 21.6005 19.84V19.837Z"/>
14
- <path fill="rgb(var(--main))" d="M13.0005 4C12.0116 4 11.0449 4.29324 10.2226 4.84265C9.40039 5.39206 8.75953 6.17295 8.38109 7.08658C8.00265 8.00021 7.90364 9.00555 8.09656 9.97545C8.28949 10.9454 8.76569 11.8363 9.46496 12.5355C10.1642 13.2348 11.0551 13.711 12.025 13.9039C12.9949 14.0969 14.0003 13.9978 14.9139 13.6194C15.8275 13.241 16.6084 12.6001 17.1578 11.7779C17.7072 10.9556 18.0005 9.98891 18.0005 9C17.9989 7.67441 17.4716 6.40356 16.5343 5.46622C15.5969 4.52888 14.3261 4.00159 13.0005 4ZM13.0005 12C12.4071 12 11.8271 11.8241 11.3338 11.4944C10.8404 11.1648 10.4559 10.6962 10.2289 10.1481C10.0018 9.59987 9.94238 8.99667 10.0581 8.41473C10.1739 7.83279 10.4596 7.29824 10.8792 6.87868C11.2987 6.45912 11.8333 6.1734 12.4152 6.05764C12.9972 5.94189 13.6004 6.0013 14.1485 6.22836C14.6967 6.45542 15.1653 6.83994 15.4949 7.33329C15.8245 7.82664 16.0005 8.40666 16.0005 9C16.0005 9.79565 15.6844 10.5587 15.1218 11.1213C14.5592 11.6839 13.7961 12 13.0005 12Z"/>
15
- </svg>
16
-
23
+ class="header-profile i-semi"
24
+ fill="#00ff88"
25
+ />
17
26
 
18
27
  <svg
19
28
  v-else
@@ -47,6 +56,11 @@
47
56
  import { useI18n } from 'vue-i18n';
48
57
  import { useStore } from '@/store';
49
58
 
59
+ import IconShopcart from '@pf/src/modules/icons/entities/IconShopcart.vue'
60
+ import IconProfile from '@pf/src/modules/icons/entities/IconProfile.vue'
61
+
62
+ import Button from '@pf/src/components/Button/Button.vue'
63
+
50
64
 
51
65
  const router = useRouter()
52
66
  const route = useRoute()
@@ -100,6 +114,12 @@
100
114
  height: 2rem;
101
115
  }
102
116
 
117
+ .header-shopcart {
118
+ position: absolute;
119
+ right: 4.25rem;
120
+ height: 2rem;
121
+ }
122
+
103
123
  .header-title {
104
124
  pointer-events: none;
105
125
  }
@@ -8,7 +8,7 @@
8
8
  <h4 class="mn-b-thin p-big">{{t('title')}}</h4>
9
9
  <p class="t-transp p-small">{{t('subtitle')}} {{ t('positions', { count: StoreCartAmount }) }}</p>
10
10
  </div>
11
- <button @click="shopcart.actions.toggleShopcart" class="button-icon"><img src="@/assets/icons/cross.svg"></button>
11
+ <IconCross @click="shopcart.actions.toggleShopcart" class="button-icon"/>
12
12
  </div>
13
13
  <!-- ---------------------------------------------------------------- -->
14
14
  <!-- 02. Popup Content -->
@@ -57,6 +57,9 @@
57
57
  // Components
58
58
  import CardOrderItem from '@pf/src/modules/orders/components/blocks/CardOrderItem.vue';
59
59
 
60
+ import IconCross from '@pf/src/modules/icons/navigation/IconCross.vue';
61
+
62
+
60
63
  import * as shopcart from '@pf/src/modules/orders/store/shopcart';
61
64
  /////////////////////////////
62
65
  // CREATED
@@ -1,77 +1,45 @@
1
1
  <template>
2
2
  <div class="radius-big o-hidden cols-2-1_3">
3
- <!-- <Map :location="{lat: department.location.coordinates[1] ,lng: department.location.coordinates[0]}" class=""/> -->
4
3
 
5
4
  <div class="pd-medium w-100">
6
- <svg @click="$router.push(`/organizations/${props.organization}/departments/${department._id}/edit`)" class="i-regular pos-absolute pos-r-0 pos-t-0 t-transp" width="652" height="652" viewBox="0 0 652 652" fill="none" xmlns="http://www.w3.org/2000/svg">
7
- <path d="M515.693 9.52082C510.095 3.91669 502.49 0.765625 494.563 0.765625C486.635 0.765625 479.036 3.91669 473.432 9.52082L48.7255 434.307C44.8244 438.214 42.0848 443.125 40.8088 448.496L0.939444 615.069C-1.47202 625.168 1.528 635.788 8.86652 643.132C16.2103 650.47 26.8305 653.47 36.9292 651.059L203.516 611.261H203.511C208.88 609.985 213.792 607.246 217.699 603.35L642.485 178.496C648.089 172.892 651.241 165.293 651.241 157.366C651.241 149.439 648.089 141.835 642.485 136.235L515.693 9.52082ZM113.76 453.708L388.307 179.161L472.828 263.682L198.281 538.229L113.76 453.708ZM87.1041 511.5L140.416 564.812L70.3014 581.614L87.1041 511.5ZM515.091 221.793L430.195 136.897L494.184 72.9075L579.08 157.429L515.091 221.793Z" fill="rgb(var(--black))"/>
8
- </svg>
9
-
5
+
6
+ <router-link
7
+ :to="{
8
+ name: 'Department Edit',
9
+ params: {
10
+ _id: props.organization,
11
+ department: department._id
12
+ }
13
+ }"
14
+ class="
15
+ cursor-pointer
16
+ pos-absolute pos-t-regular pos-r-regular
17
+ radius-extra pd-thin bg-second
18
+ "
19
+ >
20
+ <IconEdit
21
+ class="i-regular"
22
+ classes="fill-white"
23
+ />
24
+ </router-link>
25
+
10
26
  <h3
11
27
  @click="$router.push(`/organizations/${props.organization}/departments/${department._id}`)"
12
28
  class="mn-b-small w-100"
13
29
  v-html="department.profile.name"
14
30
  />
15
31
 
16
- <Spoiler
17
- class="
18
- radius-small
19
- o-hidden
20
- br-1px br-solid br-grey
21
- mn-b-thin
22
- "
23
- >
24
- <template #header>
25
- <div class="pd-small flex-v-center flex-nowrap flex">
26
- <h5 class="w-100" >Contacts </h5>
27
- <p class="mn-r-small">{{department.members.length}}&nbsp;человек</p>
28
- <svg width="14" height="9" viewBox="0 0 14 9" fill="none" xmlns="http://www.w3.org/2000/svg">
29
- <path fill-rule="evenodd" clip-rule="evenodd" d="M12.4697 0.469727L13.5304 1.53039L7.00006 8.06072L0.469727 1.53039L1.53039 0.469727L7.00006 5.9394L12.4697 0.469727Z" fill="#8A8A8A"/>
30
- </svg>
31
-
32
- </div>
33
- </template>
34
- <template #content>
35
- <ul>
36
- <li v-if="department.members.length < 1">В отделе еще нет участников</li>
37
- <User
38
- class="br-b br-solid br-grey"
39
- v-for="(member, index) in department.members"
40
- :key="index"
41
- :user="member.user"
42
- :position="member.position"
43
- @click="$router.push(`/app/profile/${member.user._id}`)"
44
- />
45
- </ul>
46
- </template>
47
- </Spoiler>
48
-
49
- <Spoiler
50
- class="
51
- radius-small
52
- o-hidden
53
- br-1px br-solid br-grey
54
- mn-b-thin
55
- "
56
- >
57
- <template #header>
58
- <div class="pd-small flex-v-center flex-nowrap flex">
59
- <h5 class="w-100" >Working Hours </h5>
60
- <p class="mn-r-small">{{department.subdepartments ? department.subdepartments.length : 0}}&nbsp;отделов</p>
61
- <svg width="14" height="9" viewBox="0 0 14 9" fill="none" xmlns="http://www.w3.org/2000/svg">
62
- <path fill-rule="evenodd" clip-rule="evenodd" d="M12.4697 0.469727L13.5304 1.53039L7.00006 8.06072L0.469727 1.53039L1.53039 0.469727L7.00006 5.9394L12.4697 0.469727Z" fill="#8A8A8A"/>
63
- </svg>
64
-
65
- </div>
66
- </template>
67
- <template #content>
68
- <ul>
69
- <li v-if="department.subdepartments.length < 1">В отделе еще нет подотделов</li>
70
- <DepartmentSub v-for="(subdepartmentsartment, index) in department.subdepartments" @click="$router.push(`/organization/departments/${subdepartmentsartment._id}`)" :key="index" class="br-b br-solid br-grey" :department="subdepartmentsartment" />
71
- </ul>
72
- </template>
73
- </Spoiler>
74
-
32
+ <ul>
33
+ <li v-if="department.members.length < 1">В отделе еще нет участников</li>
34
+ <User
35
+ class="br-b br-solid br-grey"
36
+ v-for="(member, index) in department.members"
37
+ :key="index"
38
+ :user="member.user"
39
+ :position="member.position"
40
+ @click="$router.push(`/app/profile/${member.user._id}`)"
41
+ />
42
+ </ul>
75
43
  </div>
76
44
  </div>
77
45
  </template>
@@ -79,9 +47,9 @@
79
47
  <script setup>
80
48
  import { ref } from 'vue';
81
49
 
82
- import Spoiler from '@pf/src/components/Spoiler/Spoiler.vue';
83
- import Map from '@pf/src/components/Map/Map.vue';
50
+ import IconEdit from '@pf/src/modules/icons/navigation/IconEdit.vue'
84
51
 
52
+ import Spoiler from '@pf/src/components/Spoiler/Spoiler.vue';
85
53
  import DepartmentSub from '@pf/src/modules/organizations/components/blocks/DepartmentSub.vue';
86
54
  import User from '@pf/src/modules/organizations/components/blocks/User.vue';
87
55
 
@@ -2,10 +2,43 @@
2
2
  <div>
3
3
 
4
4
  <div class="br-grey radius-small mn-small">
5
- {{memberForm.id}}
5
+ <h3 class="mn-b-semi">Add to deparment</h3>
6
+
7
+ <div class="bg-grey mn-b-thin h-min-10r h-max-10r o-scroll pd-medium radius-big">
8
+ <Feed
9
+ :states="{
10
+ empty: {
11
+ title: 'No Members Found',
12
+ description: 'Currently, there are no members available.'
13
+ }
14
+ }"
15
+ :store="{
16
+ read: (options) => memberships.actions.read(options),
17
+ state: null
18
+ }"
19
+ :options="{
20
+ target: $route.params._id
21
+ }"
22
+ v-slot="{
23
+ items
24
+ }"
25
+ >
26
+ <User
27
+ v-for="(item, index) in items"
28
+ :key="index"
29
+ :photo="item.user.profile.photo"
30
+ :name="item.user.profile.name || item.user.phone || item.user.email || item.user._id"
31
+ :user="item"
32
+ :position="item.position"
33
+ @click="$router.push(`/app/profile/${user._id}`)"
34
+ class="mn-b-thin"
35
+ />
36
+ </Feed>
37
+ </div>
38
+
6
39
  <SelectMulti
7
40
  v-if="props.member === null"
8
- v-model="memberForm.user"
41
+ v-model="userInput"
9
42
  :options="users"
10
43
  :multiple="false"
11
44
  :taggable="false"
@@ -13,11 +46,11 @@
13
46
  class="mn-b-semi bg-grey pd-medium radius-small"
14
47
  />
15
48
 
16
- <div v-else class="pd-small br-grey br-1px br-solid">
49
+ <!-- <div v-else class="pd-small br-grey br-1px br-solid">
17
50
  {{ memberForm.user.name ? memberForm.user.name : 'Безымянный' }}, {{memberForm.user.id}}
18
- </div>
51
+ </div> -->
19
52
  <Field
20
- v-model:field="memberForm.position"
53
+ v-model:field="roleInput"
21
54
  label="Должность"
22
55
  placeholder="Название должности"
23
56
  class="bg-white "
@@ -25,7 +58,7 @@
25
58
  />
26
59
  </div>
27
60
 
28
- <button :disabled="!memberForm.user._id || !memberForm.position" @click="submitForm" class="w-100 button bg-blue t-white">
61
+ <button :disabled="!userInput || !roleInput" @click="submitForm" class="w-100 button bg-blue t-white">
29
62
  {{ props.member !== null ? "Редактировать участника" : "Добавить участника" }}
30
63
  </button>
31
64
 
@@ -42,6 +75,11 @@ import SelectMulti from '@pf/src/components/SelectMulti/SelectMulti.vue'
42
75
  import Field from "@pf/src/components/Field/Field.vue";
43
76
  import Select from "@pf/src/components/Select/Select.vue";
44
77
 
78
+ import Feed from '@pf/src/components/Feed/Feed.vue'
79
+ import User from '@pf/src/modules/organizations/components/blocks/User.vue';
80
+
81
+ import * as memberships from '@pf/src/modules/organizations/store/memberships'
82
+
45
83
  const props = defineProps({
46
84
  isPopupOpen: Boolean,
47
85
  member: Number,
@@ -51,13 +89,11 @@ const props = defineProps({
51
89
 
52
90
  const emits = defineEmits(['callback','remove'])
53
91
 
54
- const memberForm = ref({
55
- user: "",
56
- position: "",
57
- });
92
+ const userInput = ref(null);
93
+ const roleInput = ref(null);
58
94
 
59
95
  if (props.member !== null) {
60
- memberForm.value = props.members[props.member]
96
+ userInput.value = props.members[props.member]
61
97
  }
62
98
 
63
99
  import * as inputsValidation from '@pf/src/modules/middlewares/client/inputs.validation'
@@ -66,10 +102,11 @@ const placeValidation = ref(null)
66
102
 
67
103
  async function submitForm() {
68
104
  if (props.member !== null) {
69
- props.members[props.member] = memberForm.value
105
+ props.members[props.member] = userInput
106
+ props.members[props.member].role = roleInput.value
70
107
  emits("callback");
71
108
  } else {
72
- props.members.push(memberForm.value);
109
+ props.members.push({...userInput.value, role: roleInput.value});
73
110
  emits("callback");
74
111
  }
75
112
  }
@@ -1,8 +1,8 @@
1
1
  <template>
2
- <div class="">
2
+ <div class="flex-v-center flex-nowrap flex">
3
3
  <img
4
- v-if="user.profile?.photo.length > 0 && type !== 'short'"
5
- :src="(FILE_SERVER_URL || '') + member.profile.photo"
4
+ v-if="photo"
5
+ :src="(FILE_SERVER_URL || '') + photo"
6
6
  class="radius-medium object-fit-cover mn-r-thin i-thin"
7
7
 
8
8
  @click.stop="$router.push({
@@ -12,9 +12,9 @@
12
12
  }
13
13
  })"
14
14
  />
15
- {{user}}123
15
+ <!-- <pre>{{user}}</pre> -->
16
16
  <PlaceholderUserpic
17
- v-if="!user.profile?.photo && type !== 'short'"
17
+ v-if="!photo"
18
18
  class="radius-medium mn-r-thin i-thin"
19
19
 
20
20
  @click.stop="$router.push({
@@ -24,10 +24,11 @@
24
24
  }
25
25
  })"
26
26
  />
27
- <!-- <div class="user-card__info"> -->
28
- <!-- <p class="user-card__name">{{ user.profile?.name || 'Безымянный' }}</p> -->
27
+
28
+ <p>{{ name }}</p>
29
+
29
30
  <!-- </div> -->
30
- <div class="mn-r-auto">
31
+ <!-- <div class="mn-r-auto">
31
32
  <span class=" mn-r-small">{{user.profile?.email}} {{user.profile?.phone}}</span>
32
33
  <span class="t-transp">{{user.role}}</span>
33
34
  <br>
@@ -36,7 +37,7 @@
36
37
 
37
38
  <div v-if="user.position !== 'Основатель'" class="mn-l-medium flex-v-center flex">
38
39
  <button @click="removeMember(user)" class="button-small button">×</button>
39
- </div>
40
+ </div> -->
40
41
 
41
42
  </div>
42
43
  </template>
@@ -50,6 +51,14 @@
50
51
  user: {
51
52
  type: Object,
52
53
  required: true
54
+ },
55
+ photo: {
56
+ type: String,
57
+ default: null
58
+ },
59
+ name: {
60
+ type: String,
61
+ default: 'Anonymous'
53
62
  }
54
63
  // Define other props here
55
64
  });
@@ -7,9 +7,25 @@
7
7
 
8
8
  <h2 class="w-100">{{ departments.state.department.profile.name }}</h2>
9
9
 
10
- <svg @click="$router.push(`/organizations/${route.params._id}/departments/${route.params.department}/edit`)" class="i-regular t-transp" width="652" height="652" viewBox="0 0 652 652" fill="none" xmlns="http://www.w3.org/2000/svg">
11
- <path d="M515.693 9.52082C510.095 3.91669 502.49 0.765625 494.563 0.765625C486.635 0.765625 479.036 3.91669 473.432 9.52082L48.7255 434.307C44.8244 438.214 42.0848 443.125 40.8088 448.496L0.939444 615.069C-1.47202 625.168 1.528 635.788 8.86652 643.132C16.2103 650.47 26.8305 653.47 36.9292 651.059L203.516 611.261H203.511C208.88 609.985 213.792 607.246 217.699 603.35L642.485 178.496C648.089 172.892 651.241 165.293 651.241 157.366C651.241 149.439 648.089 141.835 642.485 136.235L515.693 9.52082ZM113.76 453.708L388.307 179.161L472.828 263.682L198.281 538.229L113.76 453.708ZM87.1041 511.5L140.416 564.812L70.3014 581.614L87.1041 511.5ZM515.091 221.793L430.195 136.897L494.184 72.9075L579.08 157.429L515.091 221.793Z" fill="rgb(var(--black))"/>
12
- </svg>
10
+ <router-link
11
+ :to="{
12
+ name: 'Department Edit',
13
+ params: {
14
+ _id: route.params._id,
15
+ department: route.params.department
16
+ }
17
+ }"
18
+ class="
19
+ cursor-pointer
20
+ pos-absolute pos-t-regular pos-r-regular
21
+ radius-extra pd-thin bg-second
22
+ "
23
+ >
24
+ <IconEdit
25
+ class="i-regular"
26
+ classes="fill-white"
27
+ />
28
+ </router-link>
13
29
 
14
30
  </div>
15
31
  <p class="t-transp p-big" v-html="departments.state.department.description"></p>
@@ -10,11 +10,15 @@
10
10
  </section>
11
11
 
12
12
  </header>
13
-
14
- <div class="mn-b-thin bg-grey pd-medium o-hidden radius-big">
15
- <h3 class="mn-b-semi">Profile</h3>
16
-
17
- <div v-if="departments.state.department.profile" class="radius-small flex-nowrap flex">
13
+
14
+ <Block
15
+ title="Profile"
16
+ v-if="departments.state.department.profile"
17
+ class="mn-b-thin"
18
+ >
19
+ <div
20
+ class="cols-2-fit-content"
21
+ >
18
22
  <UploadImage
19
23
  v-model:photo="departments.state.department.profile.photo"
20
24
  :uploadPath="'organizations/' + departments.state.department.name + '/avatars'"
@@ -37,7 +41,7 @@
37
41
  />
38
42
  </div>
39
43
  </div>
40
- </div>
44
+ </Block>
41
45
 
42
46
  <Block
43
47
  title="Team"
@@ -48,11 +52,14 @@
48
52
  }]"
49
53
  class="cols-1 gap-thin mn-b-thin"
50
54
  >
55
+ <!-- {{departments.state.department.members[0]}} -->
51
56
  <User
52
57
  class="bg-grey o-hidden radius-small mn-b-thin"
53
58
  v-for="(member, index) in departments.state.department.members"
54
59
  :key="index"
55
60
  :user="member.user"
61
+ :photo="member.user.profile.photo"
62
+ :name="member.user.profile.name || member.user.phone || member.user.email || member.user._id"
56
63
  :position="member.position"
57
64
  @click="openMemberPopup(index)"
58
65
  />
@@ -62,6 +69,7 @@
62
69
  title="Добавить участника"
63
70
  @close-popup="closeMemberPopup"
64
71
  :isPopupOpen="isOpenAddMemberPopup"
72
+ class="bg-white w-max-30r radius-big pd-big"
65
73
  >
66
74
  <DepartmentMemberModify
67
75
  :members="departments.state.department.members"
@@ -212,12 +220,8 @@ import User from '@pf/src/modules/organizations/components/blocks/User.vue';
212
220
  import * as departments from "@pf/src/modules/organizations/store/departments";
213
221
  import * as memberships from "@pf/src/modules/organizations/store/memberships";
214
222
 
215
-
216
-
217
223
  const router = useRouter();
218
224
  const route = useRoute();
219
- const tabOrganization = ref("details");
220
- const showAddNew = ref(false);
221
225
 
222
226
  async function fetchData() {
223
227
  if (route.params.department) {