@ozdao/prometheus-framework 0.1.17 → 0.1.19

Sign up to get free protection for your applications and to get access to all the features.
Files changed (63) hide show
  1. package/dist/Breadcrumbs.vue_vue_type_style_index_0_lang-2426cb6f.mjs +1945 -0
  2. package/dist/Breadcrumbs.vue_vue_type_style_index_0_lang-c6aba800.js +1 -0
  3. package/dist/ButtonFollow-351486b0.js +1 -0
  4. package/dist/ButtonFollow-3a05d29f.mjs +132 -0
  5. package/dist/CardOrganization-4d22037e.js +1 -0
  6. package/dist/CardOrganization-8c5b582b.mjs +230 -0
  7. package/dist/Feed-416d84b0.mjs +439 -0
  8. package/dist/Feed-44beaa4c.mjs +368 -0
  9. package/dist/Feed-8a151970.js +1 -0
  10. package/dist/Feed-c9e6190e.js +1 -0
  11. package/dist/Gallery-9305f294.mjs +357 -0
  12. package/dist/Gallery-dea27e94.js +1 -0
  13. package/dist/Image-22e17cef.js +9 -0
  14. package/dist/Image-c0ae2c5f.mjs +477 -0
  15. package/dist/Popup-ad5f59d0.js +1 -0
  16. package/dist/Popup-e7c9a43e.mjs +76 -0
  17. package/dist/Product-2d05acc8.mjs +839 -0
  18. package/dist/Product-d9c3b9b9.js +7 -0
  19. package/dist/ProductEdit-ab0530e8.js +1 -0
  20. package/dist/ProductEdit-aca44ef7.mjs +300 -0
  21. package/dist/ProfileBlogposts-2063c511.mjs +65 -0
  22. package/dist/ProfileBlogposts-eaecd267.js +1 -0
  23. package/dist/ProfileComments-1ae70859.js +1 -0
  24. package/dist/ProfileComments-78231e6a.mjs +44 -0
  25. package/dist/ProfileEvents-4a2fa422.mjs +57 -0
  26. package/dist/ProfileEvents-90448f97.js +1 -0
  27. package/dist/ProfileLikes-74c78a16.mjs +44 -0
  28. package/dist/ProfileLikes-b48ce0ef.js +1 -0
  29. package/dist/ProfileOrganizations-43710687.js +1 -0
  30. package/dist/ProfileOrganizations-cf8a12f5.mjs +213 -0
  31. package/dist/Publics-5472f70c.mjs +123 -0
  32. package/dist/Publics-71b9efbe.js +1 -0
  33. package/dist/UploadImage-0f488170.js +1 -0
  34. package/dist/UploadImage-3c627d89.mjs +83 -0
  35. package/dist/UploadImageMultiple-cb6c7188.mjs +58 -0
  36. package/dist/UploadImageMultiple-eddaac87.js +1 -0
  37. package/dist/auth-4415a97a.js +7 -0
  38. package/dist/auth-afa25b86.mjs +905 -0
  39. package/dist/auth.client.cjs +1 -1
  40. package/dist/auth.client.js +4 -4
  41. package/dist/auth.validation-3e93dc23.mjs +20 -0
  42. package/dist/auth.validation-a17cd085.js +1 -0
  43. package/dist/backoffice.client.cjs +1 -1
  44. package/dist/backoffice.client.js +11 -11
  45. package/dist/community.client.cjs +1 -1
  46. package/dist/community.client.js +11 -11
  47. package/dist/events.client.cjs +1 -1
  48. package/dist/events.client.js +9 -9
  49. package/dist/gallery.server.js +23 -2
  50. package/dist/gallery.server.mjs +23 -2
  51. package/dist/index-a661083c.mjs +934 -0
  52. package/dist/index-b41aac19.js +2 -0
  53. package/dist/organizations-65937ba4.js +1 -0
  54. package/dist/organizations-af965fcf.mjs +122 -0
  55. package/dist/organizations.client-1e9361ec.js +3 -0
  56. package/dist/organizations.client-43816e25.mjs +3018 -0
  57. package/dist/organizations.client.cjs +1 -1
  58. package/dist/organizations.client.js +11 -11
  59. package/dist/users.client.cjs +1 -1
  60. package/dist/users.client.js +10 -10
  61. package/package.json +1 -1
  62. package/src/modules/backoffice/router/backoffice.js +2 -2
  63. package/src/modules/gallery/gallery.server.js +2 -2
@@ -0,0 +1,3018 @@
1
+ import { computed as Z, resolveComponent as ue, openBlock as o, createElementBlock as r, Fragment as O, renderList as L, unref as k, normalizeClass as te, createCommentVNode as g, createBlock as $, withCtx as x, createTextVNode as W, toDisplayString as f, createElementVNode as a, Transition as H, createVNode as h, renderSlot as z, ref as v, reactive as oe, watch as T, onMounted as pe, pushScopeId as me, popScopeId as he, withAsyncContext as Y, withModifiers as re, watchEffect as de, resolveDirective as Ie, normalizeProps as V, guardReactiveProps as U, resolveDynamicComponent as le, mergeProps as ve, toHandlers as Ue, withDirectives as ae, vShow as ye, toRefs as Be, vModelText as we } from "vue";
2
+ import { useRoute as F, useRouter as q } from "vue-router";
3
+ import { useI18n as Ee } from "vue-i18n";
4
+ import { s as C } from "./globals-96ba60e4.mjs";
5
+ import { S as je, _ as Te, C as J } from "./Breadcrumbs.vue_vue_type_style_index_0_lang-2426cb6f.mjs";
6
+ import { _ as Pe } from "./Tab-a243605d.mjs";
7
+ import { a as ge, B as Fe, m as qe, s as Re } from "./ButtonFollow-3a05d29f.mjs";
8
+ import { _ as Ze } from "./Feed-44beaa4c.mjs";
9
+ import { _ as He } from "./Feed-416d84b0.mjs";
10
+ import { _ as Ne } from "./Socials-8193477c.mjs";
11
+ import { a as Ke, _ as We } from "./CardOrganization-8c5b582b.mjs";
12
+ import { I as Ye, P as Je } from "./IconEdit-eacf3856.mjs";
13
+ import { s as S, F as D, _ as ce } from "./auth-afa25b86.mjs";
14
+ import { a as _e } from "./index-a661083c.mjs";
15
+ import { v as Qe, a as Xe } from "./inputs.validation-14e8e01f.mjs";
16
+ import { a as R, s as b } from "./organizations-af965fcf.mjs";
17
+ import { _ as A } from "./_plugin-vue_export-helper-dad06003.mjs";
18
+ import { _ as ze } from "./UploadImage-3c627d89.mjs";
19
+ import { S as Me } from "./Publics-5472f70c.mjs";
20
+ const Ge = {
21
+ class: "breadcrumbs flex-row flex-nowrap flex-left flex",
22
+ "aria-label": "breadcrumbs"
23
+ }, et = {
24
+ key: 0,
25
+ class: "i-small mn-r-thin",
26
+ viewBox: "0 0 10 9",
27
+ fill: "none",
28
+ xmlns: "http://www.w3.org/2000/svg"
29
+ }, tt = /* @__PURE__ */ a("path", {
30
+ fill: "black",
31
+ d: "M0.494141 4.26391C0.494141 4.48862 0.659906 4.66912 0.928813 4.66912C1.05037 4.66912 1.16825 4.6065 1.27139 4.52177L1.64344 4.20866V7.56448C1.64344 8.13545 1.98971 8.47803 2.5791 8.47803H7.56678C8.15616 8.47803 8.50243 8.13545 8.50243 7.56448V4.19392L8.8929 4.52177C8.99604 4.6065 9.11392 4.66912 9.23916 4.66912C9.48597 4.66912 9.67015 4.5144 9.67015 4.27128C9.67015 4.1313 9.61121 4.01343 9.5007 3.92133L8.50243 3.08146V1.47538C8.50243 1.30961 8.3956 1.1991 8.22984 1.1991H7.63308C7.46732 1.1991 7.35313 1.30961 7.35313 1.47538V2.11634L5.66969 0.70181C5.31606 0.403433 4.85928 0.403433 4.50197 0.70181L0.663589 3.92133C0.553079 4.01711 0.494141 4.14235 0.494141 4.26391ZM6.13752 5.26219C6.13752 5.08906 6.02701 4.97855 5.85387 4.97855H4.31779C4.14097 4.97855 4.02678 5.08906 4.02678 5.26219V7.63447H2.83327C2.60856 7.63447 2.48332 7.50922 2.48332 7.28084V3.5014L4.90349 1.47538C5.01768 1.37592 5.15029 1.37592 5.26817 1.47538L7.66255 3.48298V7.28084C7.66255 7.50922 7.53731 7.63447 7.3126 7.63447H6.13752V5.26219Z"
32
+ }, null, -1), st = [
33
+ tt
34
+ ], at = { key: 2 }, nt = {
35
+ key: 3,
36
+ class: "i-small chevron",
37
+ viewBox: "0 0 4 8",
38
+ fill: "none",
39
+ xmlns: "http://www.w3.org/2000/svg"
40
+ }, ot = /* @__PURE__ */ a("path", {
41
+ d: "M4 3.99992C4 3.83673 3.94307 3.70391 3.81025 3.57867L0.899431 0.732369C0.800759 0.629902 0.679317 0.580566 0.531309 0.580566C0.239089 0.580566 0 0.815861 0 1.10808C0 1.25229 0.0607211 1.38512 0.166983 1.49138L2.74763 3.99613L0.166983 6.50846C0.0607211 6.61093 0 6.74375 0 6.89176C0 7.18398 0.239089 7.41928 0.531309 7.41928C0.675522 7.41928 0.800759 7.36994 0.899431 7.26747L3.81025 4.42117C3.94307 4.29594 4 4.15931 4 3.99992Z",
42
+ fill: "black"
43
+ }, null, -1), it = [
44
+ ot
45
+ ], lt = {
46
+ __name: "Breadcrumbs",
47
+ setup(e) {
48
+ const t = F(), { t: s, locale: n } = Ee(), d = Z(() => t.matched.map((c) => {
49
+ var w, P, I;
50
+ const p = (w = c.meta) == null ? void 0 : w.title, l = n == null ? void 0 : n.value, u = p && l && p[l], i = c.path.replace(/:.+?\//g, (N) => ""), m = (I = (P = c.meta) == null ? void 0 : P.breadcrumbs) == null ? void 0 : I.hidden;
51
+ return { name: u, path: i, isHidden: m };
52
+ }).filter((c) => c.name && !c.isHidden));
53
+ return (c, p) => {
54
+ const l = ue("router-link");
55
+ return o(), r("ol", Ge, [
56
+ (o(!0), r(O, null, L(k(d), (u, i) => (o(), r("li", {
57
+ key: i,
58
+ class: te(["flex-v-center flex-nowrap flex", { "t-main": i === k(d).length - 1 }])
59
+ }, [
60
+ i === 0 ? (o(), r("svg", et, st)) : g("", !0),
61
+ i !== k(d).length - 1 ? (o(), $(l, {
62
+ key: 1,
63
+ to: i === 0 ? "/" : u.path
64
+ }, {
65
+ default: x(() => [
66
+ W(f(u.name), 1)
67
+ ]),
68
+ _: 2
69
+ }, 1032, ["to"])) : (o(), r("span", at, f(u.name), 1)),
70
+ i !== k(d).length - 1 ? (o(), r("svg", nt, it)) : g("", !0)
71
+ ], 2))), 128))
72
+ ]);
73
+ };
74
+ }
75
+ }, rt = { class: "mn-small w-100" }, dt = ["href"], ct = /* @__PURE__ */ a("span", { class: "t-semi uppercase" }, "Website", -1), ut = [
76
+ ct
77
+ ], pt = ["href"], mt = /* @__PURE__ */ a("span", { class: "t-semi uppercase" }, "Phone", -1), ht = [
78
+ mt
79
+ ], _t = ["href"], ft = /* @__PURE__ */ a("span", { class: "t-semi uppercase" }, "Email", -1), gt = [
80
+ ft
81
+ ], bt = ["href"], vt = /* @__PURE__ */ a("span", { class: "t-semi uppercase" }, "Address", -1), yt = [
82
+ vt
83
+ ], bi = {
84
+ __name: "Contacts",
85
+ props: {
86
+ website: String,
87
+ phone: String,
88
+ email: String,
89
+ address: String
90
+ },
91
+ setup(e) {
92
+ const t = e, s = Z(() => t.website ? !t.website.startsWith("http://") && !t.website.startsWith("https://") ? `http://${t.website}` : t.website : null), n = Z(() => t.address ? encodeURIComponent(t.address) : null);
93
+ return (d, c) => (o(), r("div", rt, [
94
+ k(s) ? (o(), r("a", {
95
+ key: 0,
96
+ href: k(s),
97
+ target: "_blank",
98
+ class: "w-100 br-2px br-solid br-grey radius-small pd-small flex-v-center flex-nowrap flex"
99
+ }, ut, 8, dt)) : g("", !0),
100
+ t.phone ? (o(), r("a", {
101
+ key: 1,
102
+ href: `tel:${t.phone}`,
103
+ class: "w-100 br-2px br-solid br-grey radius-small pd-small flex-v-center flex-nowrap flex"
104
+ }, ht, 8, pt)) : g("", !0),
105
+ t.email ? (o(), r("a", {
106
+ key: 2,
107
+ href: `mailto:${t.email}`,
108
+ target: "_blank",
109
+ class: "w-100 br-2px br-solid br-grey radius-small pd-small flex-v-center flex-nowrap flex"
110
+ }, gt, 8, _t)) : g("", !0),
111
+ k(n) ? (o(), r("a", {
112
+ key: 3,
113
+ href: `https://www.google.com/maps/search/?api=1&query=${k(n)}`,
114
+ target: "_blank",
115
+ class: "w-100 br-2px br-solid br-grey radius-small pd-small flex-v-center flex-nowrap flex"
116
+ }, yt, 8, bt)) : g("", !0)
117
+ ]));
118
+ }
119
+ }, wt = { class: "w-100 mn-small star-container flex-v-center flex" }, $t = { class: "p-big t-semi mn-r-small" }, Ct = /* @__PURE__ */ a("path", {
120
+ fill: "#00FF88",
121
+ d: "M62.2406 5.85971L75.413 32.6098L105.203 36.8654C110.472 37.676 112.498 44.3636 108.648 48.0113L87.1668 68.8844L92.2331 98.2689C93.2464 103.741 87.5721 107.591 82.9111 105.159L56.3637 91.3788L29.8163 105.159C25.1553 107.794 19.4811 103.741 20.4944 98.4716L25.5607 68.8844L4.07956 48.0113C0.22917 44.3636 2.25569 37.676 7.52464 36.8654L37.3145 32.6098L50.4868 5.85971C52.9186 0.996063 59.8088 0.996063 62.2406 5.85971Z"
122
+ }, null, -1), kt = [
123
+ Ct
124
+ ], xt = { class: "" }, vi = {
125
+ __name: "Rating",
126
+ props: {
127
+ rating: {
128
+ type: Number,
129
+ required: !0
130
+ },
131
+ amount: {
132
+ type: Number,
133
+ required: !0
134
+ }
135
+ },
136
+ setup(e) {
137
+ return (t, s) => (o(), r("section", null, [
138
+ a("div", wt, [
139
+ a("span", $t, f(e.rating), 1),
140
+ (o(), r(O, null, L(5, (n) => a("svg", {
141
+ class: te(["i-semi mn-r-small", { "t-transp": n > e.rating }]),
142
+ width: "113",
143
+ height: "108",
144
+ viewBox: "0 0 113 108",
145
+ fill: "none",
146
+ xmlns: "http://www.w3.org/2000/svg"
147
+ }, kt, 2)), 64))
148
+ ]),
149
+ a("p", xt, "Based on " + f(e.amount) + " reviews", 1)
150
+ ]));
151
+ }
152
+ }, Ot = { class: "t-center flex-center flex-column flex pd-medium radius-big bg-grey" }, Lt = ["src"], St = { class: "mn-thin" }, Pt = { class: "mn-medium p-big" }, zt = { class: "flex-center flex-wrap gap-thin flex mn-semi" }, Mt = { class: "pd-thin radius-small t-semi uppercase t-black bg-main p-medium" }, Dt = {
153
+ key: 3,
154
+ class: "mn-t-small mn-thin"
155
+ }, At = {
156
+ __name: "DetailsTab",
157
+ props: {
158
+ organization: Object,
159
+ user: Object
160
+ },
161
+ setup(e) {
162
+ return (t, s) => (o(), $(H, { name: "slide-fade" }, {
163
+ default: x(() => [
164
+ a("section", Ot, [
165
+ e.user._id === e.organization.owner ? (o(), $(Ye, {
166
+ key: 0,
167
+ onClick: s[0] || (s[0] = (n) => t.$router.push({
168
+ name: "Organization Edit",
169
+ params: {
170
+ _id: e.organization._id
171
+ }
172
+ })),
173
+ class: "pos-absolute pos-t-regular pos-r-regular i-regular t-transp"
174
+ })) : g("", !0),
175
+ e.organization.profile.photo ? (o(), r("img", {
176
+ key: 1,
177
+ src: (t.FILE_SERVER_URL || "") + e.organization.profile.photo,
178
+ class: "radius-big bg-grey flex-center flex mn-small i-extra"
179
+ }, null, 8, Lt)) : (o(), $(Je, {
180
+ key: 2,
181
+ class: "radius-medium mn-small i-extra"
182
+ })),
183
+ a("h1", St, f(e.organization.profile.name), 1),
184
+ a("p", Pt, [
185
+ h(Ke, {
186
+ text: e.organization.profile.description ? e.organization.profile.description : "",
187
+ maxLen: 240
188
+ }, null, 8, ["text"])
189
+ ]),
190
+ a("div", zt, [
191
+ (o(!0), r(O, null, L(e.organization.profile.tags, (n) => (o(), r("span", Mt, f(n), 1))), 256))
192
+ ]),
193
+ z(t.$slots, "default"),
194
+ Object.values(e.organization.socials).some((n) => n) ? (o(), r("h4", Dt, " Find us in socials ")) : g("", !0),
195
+ h(Ne, {
196
+ telegram: e.organization.socials.telegram,
197
+ facebook: e.organization.socials.facebook,
198
+ instagram: e.organization.socials.instagram,
199
+ twitter: e.organization.socials.twitter
200
+ }, null, 8, ["telegram", "facebook", "instagram", "twitter"])
201
+ ])
202
+ ]),
203
+ _: 3
204
+ }));
205
+ }
206
+ };
207
+ const Vt = {
208
+ key: 0,
209
+ class: "spoiler"
210
+ }, $e = {
211
+ __name: "Spoiler",
212
+ props: {
213
+ status: {
214
+ type: Boolean,
215
+ default: !1
216
+ }
217
+ },
218
+ setup(e) {
219
+ const t = e, s = v(!1);
220
+ return t.status && (s.value = t.status), (n, d) => (o(), r("div", null, [
221
+ a("div", {
222
+ onClick: d[0] || (d[0] = (c) => s.value = !s.value),
223
+ class: "flex-v-center flex-nowrap flex"
224
+ }, [
225
+ z(n.$slots, "header")
226
+ ]),
227
+ h(H, { name: "collapse" }, {
228
+ default: x(() => [
229
+ s.value ? (o(), r("div", Vt, [
230
+ z(n.$slots, "content")
231
+ ])) : g("", !0)
232
+ ]),
233
+ _: 3
234
+ })
235
+ ]));
236
+ }
237
+ }, B = _e.create({ baseURL: process.env.API_URL, withCredentials: !0 }), y = oe({
238
+ all: [],
239
+ current: {
240
+ recommendation: !1,
241
+ category: [],
242
+ status: "unpublished",
243
+ information: [],
244
+ coverImage: "",
245
+ images: [],
246
+ files: [],
247
+ image3d: !1,
248
+ name: "",
249
+ sale: 0,
250
+ price: 0,
251
+ localization: [],
252
+ modifications: [],
253
+ description: ""
254
+ }
255
+ }), yi = {
256
+ async create(e, t) {
257
+ const s = {
258
+ ...t,
259
+ organization: e
260
+ };
261
+ return await B.post("/products/create", s).then(
262
+ (n) => (It(n.data, "current"), Promise.resolve(n.data)),
263
+ (n) => (C(n), Promise.reject(n))
264
+ );
265
+ },
266
+ async read(e = {}) {
267
+ e._id && (e.params = { _id: e._id }), e.category && (e.params = e.params || {}, e.params.category = e.category), e.params = e.params || {}, e.params.skip = e.skip || 0, e.params.limit = e.limit || 10, e.organization && (e.params.organization = e.organization), e.params.sort = "createdAt";
268
+ try {
269
+ console.log("Request params:" + e.params);
270
+ const t = await B.get("/products/read", { params: e.params });
271
+ return e._id ? y.current = t.data[0] : y.all = t.data, Promise.resolve(t.data);
272
+ } catch (t) {
273
+ return C(t), Promise.reject(t);
274
+ }
275
+ },
276
+ async update(e, t) {
277
+ return await B.post("/products/" + e, t).then(
278
+ (s) => Promise.resolve(s.data),
279
+ (s) => (C(s), Promise.reject(s))
280
+ );
281
+ },
282
+ async deleteProduct(e) {
283
+ return await B.delete("/products/" + e).then(
284
+ (t) => Promise.resolve(t.data),
285
+ (t) => (C(t), Promise.reject(t))
286
+ );
287
+ },
288
+ async submitMood(e = null) {
289
+ return console.log(e), B.post("/product/recommended", { mood: e }).then(
290
+ (t) => (y.current = t.data.product, y.current.recommendation = t.data.recommendationText, Promise.resolve(t.data)),
291
+ (t) => (console.log(t), C(t), Promise.reject(t))
292
+ );
293
+ },
294
+ async fetchProducts() {
295
+ return await B.get("/products").then(
296
+ (e) => (y.all = e.data, y.filtered = e.data.slice(), y.filteredPrice = y.filtered, y.filteredPrice.sort(function(t, s) {
297
+ return t[y.sort.current] > s[y.sort.current] ? y.sort.ascending ? 1 : -1 : t[y.sort.current] < s[y.sort.current] ? y.sort.ascending ? -1 : 1 : 0;
298
+ }), Promise.resolve(e.data)),
299
+ (e) => (C(e), Promise.reject(e))
300
+ );
301
+ },
302
+ async fetchProductsPopular() {
303
+ return await B.get("/products/popular").then(
304
+ (e) => (y.popular = e.data, Promise.resolve(e.data)),
305
+ (e) => (C(e), Promise.reject(e))
306
+ );
307
+ },
308
+ async fetchProductsPublished() {
309
+ return await B.get("/products").then(
310
+ (e) => {
311
+ let t = e.data.filter(function(s, n) {
312
+ return s.status !== "unpublished";
313
+ });
314
+ return y.all = t, y.filtered = t.slice(), y.filteredPrice = y.filtered, y.filteredPrice.sort(function(s, n) {
315
+ return s[y.sort.current] > n[y.sort.current] ? y.sort.ascending ? 1 : -1 : s[y.sort.current] < n[y.sort.current] ? y.sort.ascending ? -1 : 1 : 0;
316
+ }), Promise.resolve(e.data);
317
+ },
318
+ (e) => (C(e), Promise.reject(e))
319
+ );
320
+ },
321
+ async fetchProduct(e) {
322
+ return await B.get("/products/" + e).then(
323
+ (t) => (t.localization || (t.localization = []), y.current = t.data, Promise.resolve(t.data)),
324
+ (t) => (C(t), Promise.reject(t))
325
+ );
326
+ },
327
+ async fetchProductPopular() {
328
+ return await B.get("/products").then(
329
+ (e) => (y.all = e.data.slice(1, 5), Promise.resolve(e.data.slice(1, 5))),
330
+ (e) => (C(e), Promise.reject(e))
331
+ );
332
+ }
333
+ };
334
+ function It(e, t) {
335
+ y[t] = e;
336
+ }
337
+ T(y, (e, t) => {
338
+ });
339
+ const Ut = process.env.API_URL, Q = _e.create({ baseURL: Ut, withCredentials: !0 }), E = oe({
340
+ all: [],
341
+ current: {
342
+ order: "1",
343
+ name: "",
344
+ url: "",
345
+ subcategories: [],
346
+ filters: [],
347
+ localization: []
348
+ }
349
+ }), wi = {
350
+ async fetchCategories() {
351
+ return await Q.get("/categories").then(
352
+ (e) => (E.all = e.data, Promise.resolve(e.data)),
353
+ (e) => (C(e), Promise.reject(e))
354
+ );
355
+ },
356
+ updateCategories(e) {
357
+ return Q.post("/categories", e).then(
358
+ (t) => (E.all = e, Promise.resolve(e)),
359
+ (t) => (C(t), Promise.reject(t))
360
+ );
361
+ },
362
+ fetchCategory(e) {
363
+ return Q.get("/categories/" + e).then(
364
+ (t) => (E.current = t.data, Promise.resolve(t.data)),
365
+ (t) => (C(t), Promise.reject(t))
366
+ );
367
+ },
368
+ addCategory() {
369
+ return Q.post("/categories/add", E.current).then(
370
+ (e) => (E.all.push(e.data), Promise.resolve(e.data)),
371
+ (e) => (C(e), Promise.reject(e))
372
+ );
373
+ },
374
+ updateCategory(e) {
375
+ return Q.post("/categories/" + e, E.current).then(
376
+ (t) => (E.current = t.data, Promise.resolve(t.data)),
377
+ (t) => (C(t), Promise.reject(t))
378
+ );
379
+ },
380
+ deleteCategory(e) {
381
+ return Q.delete("/categories/" + e).then(
382
+ (t) => {
383
+ const s = E.all.findIndex((n) => n.url === e);
384
+ E.all.splice(s, 1);
385
+ },
386
+ (t) => {
387
+ C(t);
388
+ }
389
+ );
390
+ }
391
+ };
392
+ T(E, (e) => {
393
+ });
394
+ const Bt = { class: "mn-big radius-medium pd-big bg-white" }, Et = { class: "mn-regular" }, jt = { class: "mn-small t-transp p-medium" }, fe = {
395
+ __name: "EmptyState",
396
+ props: {
397
+ title: {
398
+ type: String,
399
+ default: "У вас еще нет организации"
400
+ },
401
+ description: {
402
+ type: String,
403
+ default: "Для использования сервиса, вам необходимо добавить вашу организацию."
404
+ },
405
+ action: {
406
+ type: String,
407
+ default: "Создать организацию"
408
+ },
409
+ callback: {
410
+ type: Function,
411
+ default: () => {
412
+ }
413
+ }
414
+ },
415
+ setup(e) {
416
+ return (t, s) => (o(), r("section", Bt, [
417
+ a("h3", Et, f(e.title), 1),
418
+ a("p", jt, f(e.description), 1),
419
+ a("button", {
420
+ onClick: s[0] || (s[0] = (...n) => e.callback && e.callback(...n)),
421
+ class: "t-white bg-second w-100 button"
422
+ }, f(e.action), 1)
423
+ ]));
424
+ }
425
+ };
426
+ const Tt = {
427
+ __name: "Map",
428
+ props: {
429
+ location: Object
430
+ },
431
+ setup(e) {
432
+ const t = e;
433
+ let s = v(null), n = null, d = null;
434
+ return pe(async () => {
435
+ n = new google.maps.Map(s.value, {
436
+ zoom: 13,
437
+ center: {
438
+ lat: t.location.lat,
439
+ lng: t.location.lng
440
+ }
441
+ }), d = new google.maps.Marker({
442
+ position: {
443
+ lat: t.location.lat,
444
+ lng: t.location.lng
445
+ },
446
+ map: n
447
+ });
448
+ }), T(() => t.location, () => {
449
+ n && d && (d.setPosition(new google.maps.LatLng(t.location.lat, t.location.lng)), n.setCenter(new google.maps.LatLng(t.location.lat, t.location.lng)));
450
+ }, { deep: !0 }), (c, p) => (o(), r("div", {
451
+ ref_key: "gmap",
452
+ ref: s,
453
+ class: "gmap"
454
+ }, null, 512));
455
+ }
456
+ }, Ft = /* @__PURE__ */ A(Tt, [["__scopeId", "data-v-c194b4a5"]]);
457
+ const qt = { class: "pd-small flex-nowrap flex" }, Rt = { class: "user-card__info" }, Zt = { class: "user-card__name" }, Ht = { class: "user-card__position" }, Nt = {
458
+ __name: "DepartmentSub",
459
+ props: {
460
+ department: {
461
+ type: Object,
462
+ required: !0
463
+ }
464
+ // Define other props here
465
+ },
466
+ setup(e) {
467
+ return (t, s) => (o(), r("div", qt, [
468
+ a("div", Rt, [
469
+ a("p", Zt, f(e.department.name ? e.department.name : "Безымянный"), 1),
470
+ a("p", Ht, f(e.department.members ? e.department.members.length : "0") + " человек", 1)
471
+ ])
472
+ ]));
473
+ }
474
+ }, De = /* @__PURE__ */ A(Nt, [["__scopeId", "data-v-d65b1483"]]);
475
+ const Kt = { class: "pd-small flex-nowrap flex" }, Wt = { class: "user-card__info" }, Yt = { class: "user-card__name" }, Jt = { class: "t-transp" }, Qt = {
476
+ __name: "User",
477
+ props: {
478
+ user: {
479
+ type: Object,
480
+ required: !0
481
+ },
482
+ position: {
483
+ type: String,
484
+ required: !0
485
+ }
486
+ // Define other props here
487
+ },
488
+ setup(e) {
489
+ return (t, s) => (o(), r("div", Kt, [
490
+ a("div", Wt, [
491
+ a("p", Yt, f(e.user.name ? e.user.name : "Безымянный"), 1),
492
+ a("p", Jt, f(e.position), 1)
493
+ ])
494
+ ]));
495
+ }
496
+ }, Ae = /* @__PURE__ */ A(Qt, [["__scopeId", "data-v-a27accf5"]]);
497
+ const ie = (e) => (me("data-v-1d33cf95"), e = e(), he(), e), Xt = { class: "radius-big o-hidden cols-2-1_3" }, Gt = { class: "pd-medium w-100" }, es = /* @__PURE__ */ ie(() => /* @__PURE__ */ a("path", {
498
+ 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",
499
+ fill: "black"
500
+ }, null, -1)), ts = [
501
+ es
502
+ ], ss = ["innerHTML"], as = ["innerHTML"], ns = { class: "pd-small flex-v-center flex-nowrap flex" }, os = /* @__PURE__ */ ie(() => /* @__PURE__ */ a("h5", { class: "w-100" }, "Contacts ", -1)), is = { class: "mn-r-small" }, ls = /* @__PURE__ */ ie(() => /* @__PURE__ */ a("svg", {
503
+ width: "14",
504
+ height: "9",
505
+ viewBox: "0 0 14 9",
506
+ fill: "none",
507
+ xmlns: "http://www.w3.org/2000/svg"
508
+ }, [
509
+ /* @__PURE__ */ a("path", {
510
+ "fill-rule": "evenodd",
511
+ "clip-rule": "evenodd",
512
+ d: "M12.4697 0.469727L13.5304 1.53039L7.00006 8.06072L0.469727 1.53039L1.53039 0.469727L7.00006 5.9394L12.4697 0.469727Z",
513
+ fill: "#8A8A8A"
514
+ })
515
+ ], -1)), rs = { key: 0 }, ds = { class: "pd-small flex-v-center flex-nowrap flex" }, cs = /* @__PURE__ */ ie(() => /* @__PURE__ */ a("h5", { class: "w-100" }, "Working Hours ", -1)), us = { class: "mn-r-small" }, ps = /* @__PURE__ */ ie(() => /* @__PURE__ */ a("svg", {
516
+ width: "14",
517
+ height: "9",
518
+ viewBox: "0 0 14 9",
519
+ fill: "none",
520
+ xmlns: "http://www.w3.org/2000/svg"
521
+ }, [
522
+ /* @__PURE__ */ a("path", {
523
+ "fill-rule": "evenodd",
524
+ "clip-rule": "evenodd",
525
+ d: "M12.4697 0.469727L13.5304 1.53039L7.00006 8.06072L0.469727 1.53039L1.53039 0.469727L7.00006 5.9394L12.4697 0.469727Z",
526
+ fill: "#8A8A8A"
527
+ })
528
+ ], -1)), ms = { key: 0 }, hs = {
529
+ __name: "Department",
530
+ props: {
531
+ department: Object,
532
+ organization: Object
533
+ },
534
+ setup(e) {
535
+ const t = e;
536
+ return (s, n) => (o(), r("div", Xt, [
537
+ h(Ft, {
538
+ location: { lat: e.department.location.coordinates[1], lng: e.department.location.coordinates[0] },
539
+ class: ""
540
+ }, null, 8, ["location"]),
541
+ a("div", Gt, [
542
+ (o(), r("svg", {
543
+ onClick: n[0] || (n[0] = (d) => s.$router.push(`/app/organization/${t.organization._id}/departments/${e.department._id}/edit`)),
544
+ class: "i-regular pos-absolute pos-r-0 pos-t-0 t-transp",
545
+ width: "652",
546
+ height: "652",
547
+ viewBox: "0 0 652 652",
548
+ fill: "none",
549
+ xmlns: "http://www.w3.org/2000/svg"
550
+ }, ts)),
551
+ a("h3", {
552
+ onClick: n[1] || (n[1] = (d) => s.$router.push(`/app/organization/${t.organization._id}/departments/${e.department._id}`)),
553
+ class: "mn-small w-100",
554
+ innerHTML: e.department.profile.name
555
+ }, null, 8, ss),
556
+ a("p", {
557
+ onClick: n[2] || (n[2] = (d) => s.$router.push(`/app/organization/${t.organization._id}/departments/${e.department._id}`)),
558
+ class: "mn-small p-big w-100",
559
+ innerHTML: e.department.address
560
+ }, null, 8, as),
561
+ h($e, { class: "radius-small o-hidden br-1px br-solid br-grey mn-thin" }, {
562
+ header: x(() => [
563
+ a("div", ns, [
564
+ os,
565
+ a("p", is, f(e.department.members.length) + " человек", 1),
566
+ ls
567
+ ])
568
+ ]),
569
+ content: x(() => [
570
+ a("ul", null, [
571
+ e.department.members.length < 1 ? (o(), r("li", rs, "В отделе еще нет участников")) : g("", !0),
572
+ (o(!0), r(O, null, L(e.department.members, (d, c) => (o(), $(Ae, {
573
+ class: "br-b br-solid br-grey",
574
+ key: c,
575
+ user: d.user,
576
+ position: d.position,
577
+ onClick: (p) => s.$router.push(`/app/profile/${d.user._id}`)
578
+ }, null, 8, ["user", "position", "onClick"]))), 128))
579
+ ])
580
+ ]),
581
+ _: 1
582
+ }),
583
+ h($e, { class: "radius-small o-hidden br-1px br-solid br-grey mn-thin" }, {
584
+ header: x(() => [
585
+ a("div", ds, [
586
+ cs,
587
+ a("p", us, f(e.department.subdepartments ? e.department.subdepartments.length : 0) + " отделов", 1),
588
+ ps
589
+ ])
590
+ ]),
591
+ content: x(() => [
592
+ a("ul", null, [
593
+ e.department.subdepartments.length < 1 ? (o(), r("li", ms, "В отделе еще нет подотделов")) : g("", !0),
594
+ (o(!0), r(O, null, L(e.department.subdepartments, (d, c) => (o(), $(De, {
595
+ onClick: (p) => s.$router.push(`/app/organization/departments/${d._id}`),
596
+ key: c,
597
+ class: "br-b br-solid br-grey",
598
+ department: d
599
+ }, null, 8, ["onClick", "department"]))), 128))
600
+ ])
601
+ ]),
602
+ _: 1
603
+ })
604
+ ])
605
+ ]));
606
+ }
607
+ }, _s = /* @__PURE__ */ A(hs, [["__scopeId", "data-v-1d33cf95"]]), G = _e.create({ baseURL: process.env.API_URL, withCredentials: !0 });
608
+ G.defaults.withCredentials = !0;
609
+ const _ = oe({
610
+ departments: [],
611
+ department: {
612
+ organization: "",
613
+ profile: {
614
+ photo: "",
615
+ name: "",
616
+ description: "",
617
+ categories: []
618
+ },
619
+ address: "",
620
+ location: {
621
+ lat: null,
622
+ lng: null
623
+ },
624
+ worktime: [],
625
+ delivery: [],
626
+ payment: [],
627
+ members: [],
628
+ subdepartments: []
629
+ },
630
+ error: null
631
+ }), K = {
632
+ async readOne(e) {
633
+ await G.get(`/api/departments/get/${e}`).then((t) => {
634
+ _.department = t.data, _.error = null;
635
+ }).catch((t) => {
636
+ C(t);
637
+ });
638
+ },
639
+ async read(e) {
640
+ await G.get(`/api/departments/${e}`).then((t) => {
641
+ console.log("Response:", t), _.departments = t.data, _.error = null;
642
+ }).catch((t) => {
643
+ C(t);
644
+ });
645
+ },
646
+ async create(e, t) {
647
+ await G.post(`/api/departments/${e}/create`, t).then((s) => {
648
+ _.error = null, _.department = s.data;
649
+ }).catch((s) => {
650
+ C(s);
651
+ });
652
+ },
653
+ async update(e, t) {
654
+ await G.post(`/api/departments/${e}/update`, t).then(() => {
655
+ _.error = null;
656
+ }).catch((s) => {
657
+ C(s);
658
+ });
659
+ },
660
+ async delete(e, t) {
661
+ await G.delete(`/api/departments/${e}/delete`, { data: { _id: t } }).then(() => {
662
+ _.error = null;
663
+ }).catch((s) => {
664
+ C(s);
665
+ });
666
+ }
667
+ };
668
+ T(_, (e, t) => {
669
+ });
670
+ const $i = {
671
+ __name: "StructureTab",
672
+ props: {
673
+ organization: Object,
674
+ units: Array,
675
+ memberships: Array
676
+ },
677
+ async setup(e) {
678
+ let t, s;
679
+ const n = e;
680
+ v("departments"), [t, s] = Y(() => K.read(n.organization._id)), await t, s();
681
+ const d = Z(() => {
682
+ const c = _.departments, p = c.flatMap(
683
+ (l) => l.subdepartments.map((u) => u._id)
684
+ );
685
+ return c.filter(
686
+ (l) => !p.includes(l._id)
687
+ );
688
+ });
689
+ return (c, p) => (o(), $(H, { name: "slide-fade" }, {
690
+ default: x(() => [
691
+ a("div", null, [
692
+ k(d).length < 1 ? (o(), $(fe, {
693
+ key: 0,
694
+ title: "You don't have any spots yet.",
695
+ description: "Add spots to your hub.",
696
+ action: "Add spot",
697
+ callback: () => c.$router.push(`/app/organization/${n.organization._id}/departments/create`)
698
+ }, null, 8, ["callback"])) : g("", !0),
699
+ a("div", null, [
700
+ (o(!0), r(O, null, L(k(d), (l, u) => (o(), $(_s, {
701
+ key: u,
702
+ department: l,
703
+ organization: e.organization,
704
+ class: "radius-big bg-grey mn-thin"
705
+ }, null, 8, ["department", "organization"]))), 128)),
706
+ k(d).length > 0 && S.user._id === e.organization.owner ? (o(), r("button", {
707
+ key: 0,
708
+ onClick: p[0] || (p[0] = (l) => c.$router.push(`/app/organization/${n.organization._id}/departments/create`)),
709
+ class: "mn-thin button w-100"
710
+ }, " Add spot ")) : g("", !0)
711
+ ])
712
+ ])
713
+ ]),
714
+ _: 1
715
+ }));
716
+ }
717
+ }, ee = _e.create({ baseURL: process.env.API_URL, withCredentials: !0 });
718
+ ee.defaults.withCredentials = !0;
719
+ const j = oe({
720
+ invites: [],
721
+ invite: null,
722
+ error: null
723
+ }), ne = {
724
+ async read(e) {
725
+ await ee.get(`/api/invites/${e}`).then((t) => {
726
+ j.invites = t.data, j.error = null;
727
+ }).catch((t) => {
728
+ C(t);
729
+ });
730
+ },
731
+ async readOne(e) {
732
+ await ee.get(`/api/invites/get/${e}`).then((t) => {
733
+ j.invite = t.data, S.user.phone = t.data.invitedPhone, S.user.email = t.data.invitedEmail;
734
+ }).catch((t) => {
735
+ C(t);
736
+ });
737
+ },
738
+ async create(e, t) {
739
+ await ee.post(`/api/invites/${e}/create`, t).then(() => {
740
+ j.error = null;
741
+ }).catch((s) => {
742
+ C(s);
743
+ });
744
+ },
745
+ async update(e, t) {
746
+ await ee.put(`/api/invites/${e}/update`, t).then(() => {
747
+ j.error = null;
748
+ }).catch((s) => {
749
+ C(s);
750
+ });
751
+ },
752
+ async delete(e) {
753
+ await ee.delete(`/api/invites/${e}/delete`).then(() => {
754
+ j.error = null;
755
+ }).catch((t) => {
756
+ C(t);
757
+ });
758
+ }
759
+ };
760
+ T(j, (e, t) => {
761
+ });
762
+ const Ci = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
763
+ __proto__: null,
764
+ actions: ne,
765
+ state: j
766
+ }, Symbol.toStringTag, { value: "Module" })), fs = { class: "mn-medium radius-medium pd-semi bg-white" }, gs = /* @__PURE__ */ a("h3", { class: "mn-medium" }, "Добавить участников", -1), bs = /* @__PURE__ */ a("p", { class: "mn-small t-transp p-medium" }, "Укажите email или телефон, чтобы отправить ссылку с приглашением:", -1), vs = { class: "w-100 flex-nowrap flex" }, ys = {
767
+ key: 0,
768
+ class: "mn-r-medium flex-v-center flex"
769
+ }, ws = ["onClick"], $s = /* @__PURE__ */ a("p", { class: "t-blue mn-r-small" }, "+ Добавить приглашение", -1), Cs = [
770
+ $s
771
+ ], ks = /* @__PURE__ */ a("span", null, "Отправить приглашения ", -1), xs = {
772
+ __name: "MembersAdd",
773
+ props: {
774
+ organization: Object
775
+ },
776
+ emits: ["send-invite"],
777
+ setup(e, { emit: t }) {
778
+ const s = e, n = v(null), d = v([{ contact: "", role: "" }]);
779
+ function c() {
780
+ d.value.push({ contact: "", role: "" });
781
+ }
782
+ function p(i) {
783
+ d.value.splice(i, 1);
784
+ }
785
+ async function l(i) {
786
+ await ne.create(s.organization._id, d.value);
787
+ }
788
+ function u() {
789
+ }
790
+ return (i, m) => (o(), r("div", null, [
791
+ a("section", fs, [
792
+ gs,
793
+ bs,
794
+ (o(!0), r(O, null, L(d.value, (w, P) => (o(), r("div", {
795
+ key: P,
796
+ class: "br-1px br-solid br-grey flex radius-small mn-thin"
797
+ }, [
798
+ a("div", vs, [
799
+ h(D, {
800
+ field: w.contact,
801
+ "onUpdate:field": (I) => w.contact = I,
802
+ placeholder: "Email или телефон",
803
+ class: "w-100 bg-white",
804
+ validation: n.value
805
+ }, null, 8, ["field", "onUpdate:field", "validation"]),
806
+ P > 0 ? (o(), r("div", ys, [
807
+ a("button", {
808
+ onClick: (I) => p(P),
809
+ class: "button-small button"
810
+ }, "×", 8, ws)
811
+ ])) : g("", !0)
812
+ ]),
813
+ h(Me, {
814
+ options: [
815
+ { name: "Директор", value: "director" },
816
+ { name: "Менеджер", value: "manager" },
817
+ { name: "Сотрудник", value: "member" }
818
+ ],
819
+ prop: w,
820
+ content: "role",
821
+ placeholder: "Роль",
822
+ size: "small",
823
+ class: "w-80"
824
+ }, null, 8, ["prop"])
825
+ ]))), 128)),
826
+ a("div", {
827
+ onClick: c,
828
+ class: "mn-small flex-v-center flex-nowrap flex"
829
+ }, Cs),
830
+ h(ce, {
831
+ submit: i.a = () => l(j.invites),
832
+ callback: u,
833
+ class: "mn-t-medium"
834
+ }, {
835
+ default: x(() => [
836
+ ks
837
+ ]),
838
+ _: 1
839
+ }, 8, ["submit"])
840
+ ])
841
+ ]));
842
+ }
843
+ }, Os = { class: "mn-big radius-medium bg-white" }, Ls = {
844
+ key: 0,
845
+ class: "pd-semi"
846
+ }, Ss = { class: "br-grey br-1px br-solid radius-small flex-nowrap flex-v-center flex pd-medium" }, Ps = { class: "w-100 mn-r-small" }, zs = { class: "t-transp" }, Ms = {
847
+ key: 0,
848
+ class: "mn-l-medium flex-v-center flex"
849
+ }, Ds = ["onClick"], As = {
850
+ key: 1,
851
+ class: "pd-semi"
852
+ }, Vs = { key: 0 }, Is = { class: "br-grey br-1px br-solid radius-small mn-thin flex-nowrap flex-v-center flex pd-medium" }, Us = { class: "w-100 mn-r-small" }, Bs = { class: "t-transp" }, Es = { class: "mn-l-medium flex-v-center flex" }, js = ["onClick"], Ts = {
853
+ __name: "MembersList",
854
+ props: {
855
+ organization: Object,
856
+ memberships: Array,
857
+ invites: Array
858
+ },
859
+ emits: [["removeMember", "removeInvite"]],
860
+ setup(e, { emit: t }) {
861
+ const s = e, n = v("members");
862
+ function d(p, l) {
863
+ s.memberships.splice(p, 1), t("removeMember", l);
864
+ }
865
+ function c(p, l) {
866
+ s.invites.splice(p, 1), t("removeInvite", l);
867
+ }
868
+ return (p, l) => (o(), r("section", Os, [
869
+ h(Pe, {
870
+ selected: n.value,
871
+ "onUpdate:selected": l[0] || (l[0] = (u) => n.value = u),
872
+ class: "br-grey br-b br-solid radius-small",
873
+ tabs: [
874
+ { name: "Участники", value: "members" },
875
+ { name: "Приглашения", value: "invites" }
876
+ ]
877
+ }, null, 8, ["selected"]),
878
+ n.value === "members" ? (o(), r("div", Ls, [
879
+ (o(!0), r(O, null, L(e.memberships, (u, i) => (o(), r("div", Ss, [
880
+ a("span", Ps, f(u.user.email) + " " + f(u.user.phone), 1),
881
+ a("span", zs, f(u.position), 1),
882
+ u.position !== "Основатель" ? (o(), r("div", Ms, [
883
+ a("button", {
884
+ onClick: (m) => d(i, u),
885
+ class: "button-small button"
886
+ }, "×", 8, Ds)
887
+ ])) : g("", !0)
888
+ ]))), 256))
889
+ ])) : g("", !0),
890
+ n.value === "invites" ? (o(), r("div", As, [
891
+ e.invites.length < 1 ? (o(), r("span", Vs, "В организации нет приглашений")) : g("", !0),
892
+ (o(!0), r(O, null, L(e.invites, (u, i) => (o(), r("div", Is, [
893
+ a("span", Us, f(u.invitedEmail) + " " + f(u.invitedPhone), 1),
894
+ a("span", Bs, f(u.status), 1),
895
+ a("div", Es, [
896
+ a("button", {
897
+ onClick: (m) => c(i, u),
898
+ class: "button-small button"
899
+ }, "×", 8, js)
900
+ ])
901
+ ]))), 256))
902
+ ])) : g("", !0)
903
+ ]));
904
+ }
905
+ }, Fs = /* @__PURE__ */ a("section", { class: "mn-medium radius-medium pd-semi bg-white" }, [
906
+ /* @__PURE__ */ a("h2", { class: "mn-regular" }, "Участники"),
907
+ /* @__PURE__ */ a("p", { class: "t-transp p-big" }, "Добавляйте новых участников организации и настраивайте права доступа.")
908
+ ], -1), ki = {
909
+ __name: "MembersTab",
910
+ props: {
911
+ organization: Object,
912
+ memberships: Array
913
+ },
914
+ async setup(e) {
915
+ let t, s;
916
+ const n = e;
917
+ [t, s] = Y(() => ne.read(n.organization._id)), await t, s();
918
+ async function d(l) {
919
+ await ne.create(n.organization._id, l);
920
+ }
921
+ async function c(l) {
922
+ await ge.delete(l._id);
923
+ }
924
+ async function p(l) {
925
+ await ne.delete(l._id);
926
+ }
927
+ return (l, u) => (o(), $(H, { name: "slide-fade" }, {
928
+ default: x(() => [
929
+ a("div", null, [
930
+ Fs,
931
+ h(xs, {
932
+ organization: e.organization,
933
+ onSendInvite: d
934
+ }, null, 8, ["organization"]),
935
+ h(Ts, {
936
+ organization: e.organization,
937
+ memberships: e.memberships,
938
+ invites: j.invites,
939
+ onRemoveInvite: p,
940
+ onRemoveMember: c
941
+ }, null, 8, ["organization", "memberships", "invites"])
942
+ ])
943
+ ]),
944
+ _: 1
945
+ }));
946
+ }
947
+ };
948
+ const qs = {
949
+ key: 0,
950
+ class: "pd-thin for-transition w-100"
951
+ }, Rs = { class: "t-semi mn-small" }, Zs = {
952
+ __name: "Organization",
953
+ setup(e) {
954
+ const t = q(), s = F();
955
+ let n = s.query.tab ? s.query.tab : "events";
956
+ const d = v(null);
957
+ pe(async () => {
958
+ d.value = await R.read({ _id: s.params._id, user: S.user._id }), await ge.read(s.params._id);
959
+ });
960
+ const c = v(n);
961
+ s.query.tab = c.value, T(c, (l) => {
962
+ t.replace({ query: { ...s.query, tab: l } });
963
+ });
964
+ const p = ({ membership: l, isMember: u, targetId: i }) => {
965
+ qe.handleMembershipUpdate(b.current, l, u, i);
966
+ };
967
+ return (l, u) => d.value ? (o(), r("div", qs, [
968
+ h(At, {
969
+ organization: b.current,
970
+ user: S.user,
971
+ class: "mn-semi"
972
+ }, {
973
+ default: x(() => [
974
+ a("p", Rs, " 👨‍👨‍👧‍👧 " + f(b.current.numberOfMemberships) + " followers ", 1),
975
+ S.user._id && k(s).params._id && k(s).params._id !== S.user._id && b.current.owner !== S.user._id ? (o(), $(Fe, {
976
+ key: 0,
977
+ type: "organization",
978
+ isMember: b.current.isMember,
979
+ targetId: b.current._id,
980
+ userId: S.user._id,
981
+ class: "w-min mn-auto",
982
+ onUpdateMembership: p
983
+ }, null, 8, ["isMember", "targetId", "userId"])) : g("", !0)
984
+ ]),
985
+ _: 1
986
+ }, 8, ["organization", "user"]),
987
+ h(Pe, {
988
+ selected: c.value,
989
+ "onUpdate:selected": u[0] || (u[0] = (i) => c.value = i),
990
+ tabs: [
991
+ { name: "Events", value: "events" },
992
+ { name: "Community", value: "community" }
993
+ ],
994
+ class: "mn-small o-hidden h5 radius-big bg-grey"
995
+ }, null, 8, ["selected"]),
996
+ h(H, { name: "slide-fade" }, {
997
+ default: x(() => [
998
+ c.value === "events" ? (o(), $(Ze, {
999
+ key: 0,
1000
+ user: S.user._id,
1001
+ owner: k(s).params._id,
1002
+ sortOrder: "asc"
1003
+ }, null, 8, ["user", "owner"])) : g("", !0)
1004
+ ]),
1005
+ _: 1
1006
+ }),
1007
+ h(H, { name: "slide-fade" }, {
1008
+ default: x(() => [
1009
+ c.value === "community" ? (o(), $(He, {
1010
+ key: 0,
1011
+ user: S.user._id,
1012
+ owner: k(s).params._id
1013
+ }, null, 8, ["user", "owner"])) : g("", !0)
1014
+ ]),
1015
+ _: 1
1016
+ })
1017
+ ])) : g("", !0);
1018
+ }
1019
+ }, Hs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1020
+ __proto__: null,
1021
+ default: Zs
1022
+ }, Symbol.toStringTag, { value: "Module" })), Ns = { class: "for-transition w-100" }, Ks = {
1023
+ id: "dash",
1024
+ class: "pd-medium bg-grey"
1025
+ }, Ws = { class: "mn-medium radius-medium pd-semi bg-white" }, Ys = { class: "flex-nowrap flex mn-small" }, Js = { class: "w-100" }, Qs = /* @__PURE__ */ a("path", {
1026
+ 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",
1027
+ fill: "black"
1028
+ }, null, -1), Xs = [
1029
+ Qs
1030
+ ], Gs = ["innerHTML"], ea = { class: "mn-medium radius-medium pd-semi bg-white" }, ta = /* @__PURE__ */ a("h3", { class: "mn-regular" }, "Команда", -1), sa = { key: 0 }, aa = { class: "mn-medium radius-medium pd-semi bg-white" }, na = /* @__PURE__ */ a("h3", { class: "mn-regular" }, "Подотделы", -1), oa = { key: 0 }, ia = {
1031
+ __name: "Department",
1032
+ async setup(e) {
1033
+ let t, s;
1034
+ q();
1035
+ const n = F();
1036
+ return [t, s] = Y(() => K.readOne(n.params._id)), await t, s(), (d, c) => (o(), r("div", Ns, [
1037
+ a("div", Ks, [
1038
+ a("section", Ws, [
1039
+ a("div", Ys, [
1040
+ a("h2", Js, f(_.department.name), 1),
1041
+ (o(), r("svg", {
1042
+ onClick: c[0] || (c[0] = (p) => d.$router.push(`/app/organization/departments/${_.department._id}/edit`)),
1043
+ class: "i-regular t-transp",
1044
+ width: "652",
1045
+ height: "652",
1046
+ viewBox: "0 0 652 652",
1047
+ fill: "none",
1048
+ xmlns: "http://www.w3.org/2000/svg"
1049
+ }, Xs))
1050
+ ]),
1051
+ a("p", {
1052
+ class: "t-transp p-big",
1053
+ innerHTML: _.department.description
1054
+ }, null, 8, Gs)
1055
+ ]),
1056
+ a("section", ea, [
1057
+ ta,
1058
+ a("ul", null, [
1059
+ _.department.members.length < 1 ? (o(), r("li", sa, "В отделе еще нет участников")) : g("", !0),
1060
+ (o(!0), r(O, null, L(_.department.members, (p, l) => (o(), $(Ae, {
1061
+ class: "br-b br-solid br-grey",
1062
+ key: l,
1063
+ user: p.user,
1064
+ position: p.position,
1065
+ onClick: (u) => d.$router.push(`/app/profile/${p.user._id}`)
1066
+ }, null, 8, ["user", "position", "onClick"]))), 128))
1067
+ ])
1068
+ ]),
1069
+ a("section", aa, [
1070
+ na,
1071
+ a("ul", null, [
1072
+ _.department.subdepartments.length < 1 ? (o(), r("li", oa, "В отделе еще нет подотделов")) : g("", !0),
1073
+ (o(!0), r(O, null, L(_.department.subdepartments, (p, l) => (o(), $(De, {
1074
+ onClick: (u) => d.$router.push(`/app/organization/departments/${p._id}`),
1075
+ key: l,
1076
+ class: "br-b br-solid br-grey",
1077
+ department: p
1078
+ }, null, 8, ["onClick", "department"]))), 128))
1079
+ ])
1080
+ ])
1081
+ ])
1082
+ ]));
1083
+ }
1084
+ }, la = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1085
+ __proto__: null,
1086
+ default: ia
1087
+ }, Symbol.toStringTag, { value: "Module" }));
1088
+ const ra = { class: "for-transition bg-white radius-big w-100" }, da = { class: "flex-v-center flex-nowrap flex pd-semi" }, ca = /* @__PURE__ */ a("h2", { class: "mn-r-medium" }, "Organizations", -1), ua = { class: "pd-semi" }, pa = {
1089
+ key: 1,
1090
+ class: "cols-3"
1091
+ }, ma = ["onClick"], ha = ["src"], _a = {
1092
+ key: 1,
1093
+ class: "radius-medium mn-small i-thin",
1094
+ width: "42",
1095
+ height: "42",
1096
+ viewBox: "0 0 42 42",
1097
+ fill: "none",
1098
+ xmlns: "http://www.w3.org/2000/svg"
1099
+ }, fa = /* @__PURE__ */ a("circle", {
1100
+ fill: "rgb(var(--main))",
1101
+ cx: "21",
1102
+ cy: "21",
1103
+ r: "21"
1104
+ }, null, -1), ga = /* @__PURE__ */ a("path", {
1105
+ fill: "#242424",
1106
+ "fill-opacity": "0.1",
1107
+ "fill-rule": "evenodd",
1108
+ "clip-rule": "evenodd",
1109
+ d: "M8.00233 37.4954C8.00078 37.4458 8 37.3961 8 37.3462C8 32.9066 11.5673 29.3077 15.9677 29.3077H26.0323C30.4328 29.3077 34 32.9066 34 37.3462C34 37.3961 33.9992 37.4458 33.9977 37.4954C30.4223 40.3165 25.9078 42 21 42C16.0922 42 11.5777 40.3164 8.00233 37.4954ZM21 9C16.5995 9 13.0323 12.5989 13.0323 17.0385C13.0323 21.478 16.5995 25.0769 21 25.0769C25.4005 25.0769 28.9677 21.478 28.9677 17.0385C28.9677 12.5989 25.4005 9 21 9Z"
1110
+ }, null, -1), ba = [
1111
+ fa,
1112
+ ga
1113
+ ], va = { class: "h4 mn-r-semi mn-small" }, ya = ["onClick"], wa = /* @__PURE__ */ a("path", {
1114
+ fill: "black",
1115
+ d: "M6.41357 11.979C9.6831 11.979 12.3901 9.26611 12.3901 6.00244C12.3901 2.73291 9.67724 0.0258789 6.40771 0.0258789C3.14404 0.0258789 0.437008 2.73291 0.437008 6.00244C0.437008 9.26611 3.1499 11.979 6.41357 11.979ZM6.41357 10.9829C3.64795 10.9829 1.43896 8.76807 1.43896 6.00244C1.43896 3.23682 3.64209 1.02197 6.40771 1.02197C9.17334 1.02197 11.3882 3.23682 11.394 6.00244C11.3999 8.76807 9.1792 10.9829 6.41357 10.9829ZM8.72802 4.36182L9.1499 3.93408C9.3374 3.74072 9.35498 3.52979 9.1792 3.34814L9.04443 3.21924C8.86865 3.0376 8.65185 3.06104 8.46435 3.24854L8.03662 3.67041L8.72802 4.36182ZM4.53271 8.53955L8.37646 4.71338L7.68505 4.02197L3.84716 7.84814L3.51318 8.62158C3.45459 8.76807 3.59521 8.89697 3.72412 8.8501L4.53271 8.53955Z"
1116
+ }, null, -1), $a = [
1117
+ wa
1118
+ ], Ca = { class: "t-black p-small" }, xi = {
1119
+ __name: "OrganizationsAccount",
1120
+ async setup(e) {
1121
+ let t, s;
1122
+ S.user._id && ([t, s] = Y(() => R.read({ owner: S.user._id })), await t, s());
1123
+ const n = q(), d = F();
1124
+ let c = d.query.tab ? d.query.tab : "details";
1125
+ const p = v(c);
1126
+ return d.query.tab = p.value, T(p, (l) => {
1127
+ n.replace({ query: { ...d.query, tab: l } });
1128
+ }), (l, u) => (o(), r("div", ra, [
1129
+ a("header", da, [
1130
+ ca,
1131
+ a("button", {
1132
+ onClick: u[0] || (u[0] = (i) => l.$router.push({ name: "Create Organization" })),
1133
+ class: "radius-100p i-semi hover-scale-1 cursor-pointer t-white bg-second"
1134
+ }, "+")
1135
+ ]),
1136
+ a("div", ua, [
1137
+ b.all.length < 1 ? (o(), $(fe, {
1138
+ key: 0,
1139
+ title: "You Haven't Joined Any Organization Yet",
1140
+ description: "Weeder is all about community. Join an organization or maybe you want to create your own?",
1141
+ action: "Create organization",
1142
+ callback: l.a = () => l.$router.push("/app/organization/create/details")
1143
+ }, null, 8, ["callback"])) : (o(), r("div", pa, [
1144
+ (o(!0), r(O, null, L(b.all, (i) => (o(), r("div", {
1145
+ key: i._id,
1146
+ class: "mn-small radius-medium pd-medium br-2px br-solid br-grey",
1147
+ onClick: (m) => l.$router.push({ name: "Organization", params: { _id: i._id } })
1148
+ }, [
1149
+ i.profile.photo.length > 0 ? (o(), r("img", {
1150
+ key: 0,
1151
+ src: (l.FILE_SERVER_URL || "") + i.profile.photo,
1152
+ class: "radius-medium mn-small i-thin"
1153
+ }, null, 8, ha)) : (o(), r("svg", _a, ba)),
1154
+ a("p", va, f(i.profile.name), 1),
1155
+ (o(), r("svg", {
1156
+ onClick: re((m) => l.$router.push({ name: "Organization Edit", params: { _id: i._id } }), ["stop"]),
1157
+ class: "t-transp hover-scale-1 z-index-1 pos-absolute pos-t-regular pos-r-regular i-medium",
1158
+ width: "13",
1159
+ height: "12",
1160
+ viewBox: "0 0 13 12",
1161
+ xmlns: "http://www.w3.org/2000/svg"
1162
+ }, $a, 8, ya)),
1163
+ a("p", Ca, f(i.profile.description.slice(0, 120) + "..."), 1)
1164
+ ], 8, ma))), 128))
1165
+ ]))
1166
+ ])
1167
+ ]));
1168
+ }
1169
+ }, ka = { class: "for-transition pd-thin" }, xa = /* @__PURE__ */ a("h3", { class: "mn-small" }, "Type of group", -1), Oa = /* @__PURE__ */ a("p", { class: "mn-thin" }, "Public groups are open to everyone, whereas in exclusive groups only members can post. If you wish to make a group private, select 'hidden'.", -1), La = /* @__PURE__ */ a("h3", { class: "mn-small" }, "Profile", -1), Sa = { class: "mn-thin radius-small w-100 h-10r bg-grey flex-center flex-column flex" }, Pa = /* @__PURE__ */ a("h4", null, "Upload photo", -1), za = /* @__PURE__ */ a("h3", { class: "mn-small" }, "Socials", -1), Ma = /* @__PURE__ */ a("p", { class: "mn-thin" }, "Please provide only the username for social media profiles, without full links.", -1), Da = {
1170
+ __name: "OrganizationEdit",
1171
+ async setup(e) {
1172
+ let t, s;
1173
+ const n = F(), d = q();
1174
+ R.reset(), n.params._id && ([t, s] = Y(() => R.read({ _id: n.params._id })), await t, s());
1175
+ const c = Z(() => b.current);
1176
+ async function p() {
1177
+ n.params._id ? await R.update(n.params._id, c.value) : await R.create(b.current, S.user._id);
1178
+ }
1179
+ function l() {
1180
+ d.replace({ name: "Organization", params: { _id: b.current._id } });
1181
+ }
1182
+ return (u, i) => (o(), r("div", ka, [
1183
+ xa,
1184
+ Oa,
1185
+ h(je, {
1186
+ modelValue: b.current.types,
1187
+ "onUpdate:modelValue": i[0] || (i[0] = (m) => b.current.types = m),
1188
+ options: ["public", "exclusive", "hidden"],
1189
+ multiple: !1,
1190
+ taggable: !1,
1191
+ placeholder: "Type to search or add type of organization",
1192
+ class: "mn-semi bg-grey pd-medium radius-small"
1193
+ }, null, 8, ["modelValue"]),
1194
+ La,
1195
+ a("div", Sa, [
1196
+ h(ze, {
1197
+ photo: b.current.profile.photo,
1198
+ "onUpdate:photo": i[1] || (i[1] = (m) => b.current.profile.photo = m),
1199
+ uploadPath: "organizations/" + b.current._id + "/avatars",
1200
+ class: "h-4r w-4r aspect-1x1 o-hidden mn-thin radius-extra"
1201
+ }, null, 8, ["photo", "uploadPath"]),
1202
+ Pa
1203
+ ]),
1204
+ h(D, {
1205
+ field: b.current.profile.name,
1206
+ "onUpdate:field": i[2] || (i[2] = (m) => b.current.profile.name = m),
1207
+ placeholder: "Name of organization",
1208
+ class: "mn-thin bg-grey pd-medium radius-small"
1209
+ }, null, 8, ["field"]),
1210
+ h(D, {
1211
+ field: b.current.profile.description,
1212
+ "onUpdate:field": i[3] || (i[3] = (m) => b.current.profile.description = m),
1213
+ placeholder: "Brief description of your group",
1214
+ class: "mn-thin bg-grey pd-medium radius-small"
1215
+ }, null, 8, ["field"]),
1216
+ h(Te, {
1217
+ onTagsChanged: i[4] || (i[4] = (m) => b.current.profile.tags = m),
1218
+ tags: b.current.profile.tags
1219
+ }, null, 8, ["tags"]),
1220
+ za,
1221
+ Ma,
1222
+ h(D, {
1223
+ field: b.current.socials.instagram,
1224
+ "onUpdate:field": i[5] || (i[5] = (m) => b.current.socials.instagram = m),
1225
+ label: "Instagram",
1226
+ placeholder: "",
1227
+ class: "mn-thin bg-grey pd-medium radius-small"
1228
+ }, null, 8, ["field"]),
1229
+ h(D, {
1230
+ field: b.current.socials.twitter,
1231
+ "onUpdate:field": i[6] || (i[6] = (m) => b.current.socials.twitter = m),
1232
+ label: "Twitter",
1233
+ placeholder: "",
1234
+ class: "mn-thin bg-grey pd-medium radius-small"
1235
+ }, null, 8, ["field"]),
1236
+ h(D, {
1237
+ field: b.current.socials.facebook,
1238
+ "onUpdate:field": i[7] || (i[7] = (m) => b.current.socials.facebook = m),
1239
+ label: "Facebook",
1240
+ placeholder: "",
1241
+ class: "mn-thin bg-grey pd-medium radius-small"
1242
+ }, null, 8, ["field"]),
1243
+ h(D, {
1244
+ field: b.current.socials.telegram,
1245
+ "onUpdate:field": i[8] || (i[8] = (m) => b.current.socials.telegram = m),
1246
+ label: "Telegram",
1247
+ placeholder: "",
1248
+ class: "mn-thin bg-grey pd-medium radius-small"
1249
+ }, null, 8, ["field"]),
1250
+ h(ce, {
1251
+ submit: p,
1252
+ callback: l,
1253
+ class: "mn-thin"
1254
+ }, {
1255
+ default: x(() => [
1256
+ W("Save")
1257
+ ]),
1258
+ _: 1
1259
+ })
1260
+ ]));
1261
+ }
1262
+ }, Ce = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1263
+ __proto__: null,
1264
+ default: Da
1265
+ }, Symbol.toStringTag, { value: "Module" }));
1266
+ const Aa = { class: "for-transition bg-white radius-big w-100" }, Va = /* @__PURE__ */ a("header", { class: "flex-v-center flex-nowrap flex pd-semi" }, [
1267
+ /* @__PURE__ */ a("h2", { class: "mn-r-medium" }, "Weed dispensaries in Thailand")
1268
+ ], -1), Ia = { class: "pd-semi" }, Ua = {
1269
+ key: 1,
1270
+ class: "cols-3"
1271
+ }, Ba = ["onClick"], Ea = ["src"], ja = {
1272
+ key: 1,
1273
+ class: "radius-medium mn-small i-thin",
1274
+ width: "42",
1275
+ height: "42",
1276
+ viewBox: "0 0 42 42",
1277
+ fill: "none",
1278
+ xmlns: "http://www.w3.org/2000/svg"
1279
+ }, Ta = /* @__PURE__ */ a("circle", {
1280
+ fill: "rgb(var(--main))",
1281
+ cx: "21",
1282
+ cy: "21",
1283
+ r: "21"
1284
+ }, null, -1), Fa = /* @__PURE__ */ a("path", {
1285
+ fill: "#242424",
1286
+ "fill-opacity": "0.1",
1287
+ "fill-rule": "evenodd",
1288
+ "clip-rule": "evenodd",
1289
+ d: "M8.00233 37.4954C8.00078 37.4458 8 37.3961 8 37.3462C8 32.9066 11.5673 29.3077 15.9677 29.3077H26.0323C30.4328 29.3077 34 32.9066 34 37.3462C34 37.3961 33.9992 37.4458 33.9977 37.4954C30.4223 40.3165 25.9078 42 21 42C16.0922 42 11.5777 40.3164 8.00233 37.4954ZM21 9C16.5995 9 13.0323 12.5989 13.0323 17.0385C13.0323 21.478 16.5995 25.0769 21 25.0769C25.4005 25.0769 28.9677 21.478 28.9677 17.0385C28.9677 12.5989 25.4005 9 21 9Z"
1290
+ }, null, -1), qa = [
1291
+ Ta,
1292
+ Fa
1293
+ ], Ra = { class: "h4 mn-r-semi mn-small" }, Za = ["onClick"], Ha = /* @__PURE__ */ a("path", {
1294
+ fill: "black",
1295
+ d: "M6.41357 11.979C9.6831 11.979 12.3901 9.26611 12.3901 6.00244C12.3901 2.73291 9.67724 0.0258789 6.40771 0.0258789C3.14404 0.0258789 0.437008 2.73291 0.437008 6.00244C0.437008 9.26611 3.1499 11.979 6.41357 11.979ZM6.41357 10.9829C3.64795 10.9829 1.43896 8.76807 1.43896 6.00244C1.43896 3.23682 3.64209 1.02197 6.40771 1.02197C9.17334 1.02197 11.3882 3.23682 11.394 6.00244C11.3999 8.76807 9.1792 10.9829 6.41357 10.9829ZM8.72802 4.36182L9.1499 3.93408C9.3374 3.74072 9.35498 3.52979 9.1792 3.34814L9.04443 3.21924C8.86865 3.0376 8.65185 3.06104 8.46435 3.24854L8.03662 3.67041L8.72802 4.36182ZM4.53271 8.53955L8.37646 4.71338L7.68505 4.02197L3.84716 7.84814L3.51318 8.62158C3.45459 8.76807 3.59521 8.89697 3.72412 8.8501L4.53271 8.53955Z"
1296
+ }, null, -1), Na = [
1297
+ Ha
1298
+ ], Ka = { class: "t-black p-small" }, Oi = {
1299
+ __name: "Organizations",
1300
+ async setup(e) {
1301
+ let t, s;
1302
+ S.user._id && ([t, s] = Y(() => R.read({ owner: S.user._id })), await t, s());
1303
+ const n = q(), d = F();
1304
+ let c = d.query.tab ? d.query.tab : "details";
1305
+ const p = v(c);
1306
+ return d.query.tab = p.value, T(p, (l) => {
1307
+ n.replace({ query: { ...d.query, tab: l } });
1308
+ }), (l, u) => (o(), r("div", Aa, [
1309
+ Va,
1310
+ a("div", Ia, [
1311
+ b.all.length < 1 ? (o(), $(fe, {
1312
+ key: 0,
1313
+ title: "You Haven't Joined Any Organization Yet",
1314
+ description: "Weeder is all about community. Join an organization or maybe you want to create your own?",
1315
+ action: "Create organization",
1316
+ callback: l.a = () => l.$router.push("/app/organization/create/details")
1317
+ }, null, 8, ["callback"])) : (o(), r("div", Ua, [
1318
+ (o(!0), r(O, null, L(b.all, (i) => (o(), r("div", {
1319
+ key: i._id,
1320
+ class: "mn-small radius-medium pd-medium br-2px br-solid br-grey",
1321
+ onClick: (m) => l.$router.push({ name: "Organization", params: { _id: i._id } })
1322
+ }, [
1323
+ i.profile.photo.length > 0 ? (o(), r("img", {
1324
+ key: 0,
1325
+ src: (l.FILE_SERVER_URL || "") + i.profile.photo,
1326
+ class: "radius-medium mn-small i-thin"
1327
+ }, null, 8, Ea)) : (o(), r("svg", ja, qa)),
1328
+ a("p", Ra, f(i.profile.name), 1),
1329
+ (o(), r("svg", {
1330
+ onClick: re((m) => l.$router.push({ name: "Organization Edit", params: { _id: i._id } }), ["stop"]),
1331
+ class: "t-transp hover-scale-1 z-index-1 pos-absolute pos-t-regular pos-r-regular i-medium",
1332
+ width: "13",
1333
+ height: "12",
1334
+ viewBox: "0 0 13 12",
1335
+ xmlns: "http://www.w3.org/2000/svg"
1336
+ }, Na, 8, Za)),
1337
+ a("p", Ka, f(i.profile.description.slice(0, 120) + "..."), 1)
1338
+ ], 8, Ba))), 128))
1339
+ ]))
1340
+ ])
1341
+ ]));
1342
+ }
1343
+ };
1344
+ const Wa = {
1345
+ key: 0,
1346
+ class: "t-transp mn-r-small"
1347
+ }, Ya = ["placeholder", "value"], Ja = {
1348
+ key: 0,
1349
+ class: "mn-t-thin invalid-feedback"
1350
+ }, Qa = {
1351
+ __name: "Address",
1352
+ props: {
1353
+ apiKey: {
1354
+ type: String,
1355
+ required: !0
1356
+ },
1357
+ label: null,
1358
+ placeholder: "Enter something here",
1359
+ field: null,
1360
+ location: {
1361
+ type: Object,
1362
+ default: { lat: 48.6900735, lng: 41.1620239 }
1363
+ },
1364
+ address: {
1365
+ type: String,
1366
+ default: ""
1367
+ }
1368
+ },
1369
+ emits: ["update:address", "update:location", "update:country", "update:state", "update:city"],
1370
+ setup(e, { emit: t }) {
1371
+ const s = e, n = v(null);
1372
+ let d;
1373
+ const c = () => {
1374
+ d = new google.maps.places.Autocomplete(n.value), d.addListener("place_changed", l);
1375
+ }, p = () => {
1376
+ d || c();
1377
+ }, l = () => {
1378
+ const u = d.getPlace();
1379
+ if (!u.geometry || !u.address_components)
1380
+ return;
1381
+ let i = "", m = "", w = "";
1382
+ for (let N = 0; N < u.address_components.length; N++) {
1383
+ console.log(u.address_components);
1384
+ let M = u.address_components[N];
1385
+ M.types.includes("country") && (i = M.long_name), M.types.includes("administrative_area_level_1") && (m = M.long_name), M.types.includes("locality") && (w = M.long_name);
1386
+ }
1387
+ const P = u.formatted_address, I = { lat: u.geometry.location.lat(), lng: u.geometry.location.lng() };
1388
+ t("update:address", P), t("update:location", I), t("update:country", i), t("update:state", m), t("update:city", w);
1389
+ };
1390
+ return de(() => {
1391
+ s.address !== n.value && (n.value = s.address);
1392
+ }), pe(() => {
1393
+ c();
1394
+ }), (u, i) => (o(), r("div", {
1395
+ class: te([u.$attrs.class, "flex-nowrap flex"])
1396
+ }, [
1397
+ e.label ? (o(), r("div", Wa, [
1398
+ a("span", null, f(e.label), 1)
1399
+ ])) : g("", !0),
1400
+ a("input", {
1401
+ ref_key: "addressInput",
1402
+ ref: n,
1403
+ class: "w-100",
1404
+ placeholder: e.placeholder,
1405
+ value: e.address,
1406
+ onInput: p
1407
+ }, null, 40, Ya),
1408
+ h(H, {
1409
+ mode: "out-in",
1410
+ name: "fade"
1411
+ }, {
1412
+ default: x(() => [
1413
+ u.validation ? (o(), r("div", Ja, " * " + f(u.validation.message), 1)) : g("", !0)
1414
+ ]),
1415
+ _: 1
1416
+ })
1417
+ ], 2));
1418
+ }
1419
+ }, Xa = /* @__PURE__ */ A(Qa, [["__scopeId", "data-v-faece1a6"]]);
1420
+ const Ga = (e) => (me("data-v-1c7971e5"), e = e(), he(), e), en = { class: "map-container" }, tn = /* @__PURE__ */ Ga(() => /* @__PURE__ */ a("svg", {
1421
+ class: "i-medium",
1422
+ width: "98",
1423
+ height: "98",
1424
+ viewBox: "0 0 98 98",
1425
+ fill: "none",
1426
+ xmlns: "http://www.w3.org/2000/svg"
1427
+ }, [
1428
+ /* @__PURE__ */ a("path", {
1429
+ d: "M50.0004 31.4995C39.7996 31.4995 31.5 39.7991 31.5 49.9999C31.5 60.2007 39.7996 68.5003 50.0004 68.5003C60.2012 68.5003 68.5008 60.2007 68.5008 49.9999C68.5008 39.7991 60.2012 31.4995 50.0004 31.4995ZM50.0004 63.7944C42.3941 63.7944 36.2059 57.6062 36.2059 49.9999C36.2059 42.3936 42.3941 36.2054 50.0004 36.2054C57.6067 36.2054 63.7949 42.3936 63.7949 49.9999C63.7949 57.6062 57.6067 63.7944 50.0004 63.7944Z",
1430
+ fill: "white"
1431
+ }),
1432
+ /* @__PURE__ */ a("path", {
1433
+ d: "M97.6471 47.6471H84.56C83.3977 30.4141 69.5859 16.6024 52.3529 15.44V2.35294C52.3529 1.05255 51.2988 0 50 0C48.6996 0 47.6471 1.05255 47.6471 2.35294V15.44C30.4141 16.6024 16.6024 30.4141 15.44 47.6471H2.35294C1.05255 47.6471 0 48.6996 0 50C0 51.2988 1.05255 52.3529 2.35294 52.3529H15.44C16.6024 69.5859 30.4141 83.3977 47.6471 84.56V97.6471C47.6471 98.9459 48.6996 100 50 100C51.2988 100 52.3529 98.9459 52.3529 97.6471V84.56C69.5859 83.3977 83.3977 69.5859 84.56 52.3529H97.6471C98.9459 52.3529 100 51.2988 100 50C100 48.6996 98.9459 47.6471 97.6471 47.6471ZM50 79.9435C33.4886 79.9435 20.0565 66.5114 20.0565 50C20.0565 33.4886 33.4886 20.0565 50 20.0565C66.5098 20.0565 79.9435 33.4886 79.9435 50C79.9435 66.5098 66.5098 79.9435 50 79.9435Z",
1434
+ fill: "white"
1435
+ })
1436
+ ], -1)), sn = [
1437
+ tn
1438
+ ], an = {
1439
+ __name: "LocationMarker",
1440
+ props: {
1441
+ location: {
1442
+ type: Object,
1443
+ default: { lat: 48.6900735, lng: 41.1620239 }
1444
+ },
1445
+ address: {
1446
+ type: String,
1447
+ default: ""
1448
+ },
1449
+ apiKey: String
1450
+ },
1451
+ emits: ["update:location", "update:address", "update:country", "update:state", "update:city"],
1452
+ setup(e, { emit: t }) {
1453
+ const s = e, n = v(null);
1454
+ let d, c;
1455
+ pe(() => {
1456
+ d = new google.maps.Map(n.value, {
1457
+ center: s.location,
1458
+ zoom: 15,
1459
+ mapTypeControl: !1,
1460
+ fullscreenControl: !1
1461
+ }), c = new google.maps.Marker({
1462
+ position: s.location,
1463
+ map: d,
1464
+ draggable: !0
1465
+ }), c.addListener("dragend", (u) => {
1466
+ const i = { lat: u.latLng.lat(), lng: u.latLng.lng() };
1467
+ t("update:location", i), p(i);
1468
+ });
1469
+ }), de(() => {
1470
+ s.location && c && c.setPosition(new google.maps.LatLng(s.location.lat, s.location.lng));
1471
+ }), de(() => {
1472
+ if (s.location && d) {
1473
+ const u = new google.maps.LatLng(s.location.lat, s.location.lng);
1474
+ d.setCenter(u);
1475
+ }
1476
+ });
1477
+ function p(u) {
1478
+ new google.maps.Geocoder().geocode({ location: u }, (m, w) => {
1479
+ if (w === "OK")
1480
+ if (m[0]) {
1481
+ t("update:address", m[0].formatted_address);
1482
+ let P = "", I = "", N = "";
1483
+ m[0].address_components.forEach((M) => {
1484
+ M.types.includes("country") && (P = M.long_name), M.types.includes("administrative_area_level_1") && (I = M.long_name), M.types.includes("locality") && (N = M.long_name);
1485
+ }), t("update:country", P), t("update:state", I), t("update:city", N);
1486
+ } else
1487
+ console.error("No results found");
1488
+ else
1489
+ console.error("Geocoder failed due to: " + w);
1490
+ });
1491
+ }
1492
+ async function l() {
1493
+ navigator.geolocation ? navigator.geolocation.getCurrentPosition((u) => {
1494
+ const i = { lat: u.coords.latitude, lng: u.coords.longitude };
1495
+ t("update:location", i), p(i);
1496
+ }, () => {
1497
+ console.error("Error getting location");
1498
+ }) : console.error("Geolocation is not supported by this browser.");
1499
+ }
1500
+ return (u, i) => (o(), r("div", en, [
1501
+ a("div", {
1502
+ ref_key: "mapContainer",
1503
+ ref: n,
1504
+ class: "w-100 h-100"
1505
+ }, null, 512),
1506
+ a("button", {
1507
+ class: "pos-absolute pos-t-regular pos-r-regular i-semi bg-second radius-extra",
1508
+ onClick: l
1509
+ }, sn)
1510
+ ]));
1511
+ }
1512
+ }, nn = /* @__PURE__ */ A(an, [["__scopeId", "data-v-1c7971e5"]]);
1513
+ var on = Object.defineProperty, ln = Object.defineProperties, rn = Object.getOwnPropertyDescriptors, ke = Object.getOwnPropertySymbols, dn = Object.prototype.hasOwnProperty, cn = Object.prototype.propertyIsEnumerable, xe = (e, t, s) => t in e ? on(e, t, { enumerable: !0, configurable: !0, writable: !0, value: s }) : e[t] = s, X = (e, t) => {
1514
+ for (var s in t || (t = {}))
1515
+ dn.call(t, s) && xe(e, s, t[s]);
1516
+ if (ke)
1517
+ for (var s of ke(t))
1518
+ cn.call(t, s) && xe(e, s, t[s]);
1519
+ return e;
1520
+ }, Oe = (e, t) => ln(e, rn(t));
1521
+ const un = {
1522
+ props: {
1523
+ autoscroll: {
1524
+ type: Boolean,
1525
+ default: !0
1526
+ }
1527
+ },
1528
+ watch: {
1529
+ typeAheadPointer() {
1530
+ this.autoscroll && this.maybeAdjustScroll();
1531
+ },
1532
+ open(e) {
1533
+ this.autoscroll && e && this.$nextTick(() => this.maybeAdjustScroll());
1534
+ }
1535
+ },
1536
+ methods: {
1537
+ maybeAdjustScroll() {
1538
+ var e;
1539
+ const t = ((e = this.$refs.dropdownMenu) == null ? void 0 : e.children[this.typeAheadPointer]) || !1;
1540
+ if (t) {
1541
+ const s = this.getDropdownViewport(), { top: n, bottom: d, height: c } = t.getBoundingClientRect();
1542
+ if (n < s.top)
1543
+ return this.$refs.dropdownMenu.scrollTop = t.offsetTop;
1544
+ if (d > s.bottom)
1545
+ return this.$refs.dropdownMenu.scrollTop = t.offsetTop - (s.height - c);
1546
+ }
1547
+ },
1548
+ getDropdownViewport() {
1549
+ return this.$refs.dropdownMenu ? this.$refs.dropdownMenu.getBoundingClientRect() : {
1550
+ height: 0,
1551
+ top: 0,
1552
+ bottom: 0
1553
+ };
1554
+ }
1555
+ }
1556
+ }, pn = {
1557
+ data() {
1558
+ return {
1559
+ typeAheadPointer: -1
1560
+ };
1561
+ },
1562
+ watch: {
1563
+ filteredOptions() {
1564
+ for (let e = 0; e < this.filteredOptions.length; e++)
1565
+ if (this.selectable(this.filteredOptions[e])) {
1566
+ this.typeAheadPointer = e;
1567
+ break;
1568
+ }
1569
+ },
1570
+ open(e) {
1571
+ e && this.typeAheadToLastSelected();
1572
+ },
1573
+ selectedValue() {
1574
+ this.open && this.typeAheadToLastSelected();
1575
+ }
1576
+ },
1577
+ methods: {
1578
+ typeAheadUp() {
1579
+ for (let e = this.typeAheadPointer - 1; e >= 0; e--)
1580
+ if (this.selectable(this.filteredOptions[e])) {
1581
+ this.typeAheadPointer = e;
1582
+ break;
1583
+ }
1584
+ },
1585
+ typeAheadDown() {
1586
+ for (let e = this.typeAheadPointer + 1; e < this.filteredOptions.length; e++)
1587
+ if (this.selectable(this.filteredOptions[e])) {
1588
+ this.typeAheadPointer = e;
1589
+ break;
1590
+ }
1591
+ },
1592
+ typeAheadSelect() {
1593
+ const e = this.filteredOptions[this.typeAheadPointer];
1594
+ e && this.selectable(e) && this.select(e);
1595
+ },
1596
+ typeAheadToLastSelected() {
1597
+ this.typeAheadPointer = this.selectedValue.length !== 0 ? this.filteredOptions.indexOf(this.selectedValue[this.selectedValue.length - 1]) : -1;
1598
+ }
1599
+ }
1600
+ }, mn = {
1601
+ props: {
1602
+ loading: {
1603
+ type: Boolean,
1604
+ default: !1
1605
+ }
1606
+ },
1607
+ data() {
1608
+ return {
1609
+ mutableLoading: !1
1610
+ };
1611
+ },
1612
+ watch: {
1613
+ search() {
1614
+ this.$emit("search", this.search, this.toggleLoading);
1615
+ },
1616
+ loading(e) {
1617
+ this.mutableLoading = e;
1618
+ }
1619
+ },
1620
+ methods: {
1621
+ toggleLoading(e = null) {
1622
+ return e == null ? this.mutableLoading = !this.mutableLoading : this.mutableLoading = e;
1623
+ }
1624
+ }
1625
+ }, be = (e, t) => {
1626
+ const s = e.__vccOpts || e;
1627
+ for (const [n, d] of t)
1628
+ s[n] = d;
1629
+ return s;
1630
+ }, hn = {}, _n = {
1631
+ xmlns: "http://www.w3.org/2000/svg",
1632
+ width: "10",
1633
+ height: "10"
1634
+ }, fn = /* @__PURE__ */ a("path", { d: "M6.895455 5l2.842897-2.842898c.348864-.348863.348864-.914488 0-1.263636L9.106534.261648c-.348864-.348864-.914489-.348864-1.263636 0L5 3.104545 2.157102.261648c-.348863-.348864-.914488-.348864-1.263636 0L.261648.893466c-.348864.348864-.348864.914489 0 1.263636L3.104545 5 .261648 7.842898c-.348864.348863-.348864.914488 0 1.263636l.631818.631818c.348864.348864.914773.348864 1.263636 0L5 6.895455l2.842898 2.842897c.348863.348864.914772.348864 1.263636 0l.631818-.631818c.348864-.348864.348864-.914489 0-1.263636L6.895455 5z" }, null, -1), gn = [
1635
+ fn
1636
+ ];
1637
+ function bn(e, t) {
1638
+ return o(), r("svg", _n, gn);
1639
+ }
1640
+ const vn = /* @__PURE__ */ be(hn, [["render", bn]]), yn = {}, wn = {
1641
+ xmlns: "http://www.w3.org/2000/svg",
1642
+ width: "14",
1643
+ height: "10"
1644
+ }, $n = /* @__PURE__ */ a("path", { d: "M9.211364 7.59931l4.48338-4.867229c.407008-.441854.407008-1.158247 0-1.60046l-.73712-.80023c-.407008-.441854-1.066904-.441854-1.474243 0L7 5.198617 2.51662.33139c-.407008-.441853-1.066904-.441853-1.474243 0l-.737121.80023c-.407008.441854-.407008 1.158248 0 1.600461l4.48338 4.867228L7 10l2.211364-2.40069z" }, null, -1), Cn = [
1645
+ $n
1646
+ ];
1647
+ function kn(e, t) {
1648
+ return o(), r("svg", wn, Cn);
1649
+ }
1650
+ const xn = /* @__PURE__ */ be(yn, [["render", kn]]), Le = {
1651
+ Deselect: vn,
1652
+ OpenIndicator: xn
1653
+ }, On = {
1654
+ mounted(e, { instance: t }) {
1655
+ if (t.appendToBody) {
1656
+ const {
1657
+ height: s,
1658
+ top: n,
1659
+ left: d,
1660
+ width: c
1661
+ } = t.$refs.toggle.getBoundingClientRect();
1662
+ let p = window.scrollX || window.pageXOffset, l = window.scrollY || window.pageYOffset;
1663
+ e.unbindPosition = t.calculatePosition(e, t, {
1664
+ width: c + "px",
1665
+ left: p + d + "px",
1666
+ top: l + n + s + "px"
1667
+ }), document.body.appendChild(e);
1668
+ }
1669
+ },
1670
+ unmounted(e, { instance: t }) {
1671
+ t.appendToBody && (e.unbindPosition && typeof e.unbindPosition == "function" && e.unbindPosition(), e.parentNode && e.parentNode.removeChild(e));
1672
+ }
1673
+ };
1674
+ function Ln(e) {
1675
+ const t = {};
1676
+ return Object.keys(e).sort().forEach((s) => {
1677
+ t[s] = e[s];
1678
+ }), JSON.stringify(t);
1679
+ }
1680
+ let Sn = 0;
1681
+ function Pn() {
1682
+ return ++Sn;
1683
+ }
1684
+ const zn = {
1685
+ components: X({}, Le),
1686
+ directives: { appendToBody: On },
1687
+ mixins: [un, pn, mn],
1688
+ compatConfig: {
1689
+ MODE: 3
1690
+ },
1691
+ emits: [
1692
+ "open",
1693
+ "close",
1694
+ "update:modelValue",
1695
+ "search",
1696
+ "search:compositionstart",
1697
+ "search:compositionend",
1698
+ "search:keydown",
1699
+ "search:blur",
1700
+ "search:focus",
1701
+ "search:input",
1702
+ "option:created",
1703
+ "option:selecting",
1704
+ "option:selected",
1705
+ "option:deselecting",
1706
+ "option:deselected"
1707
+ ],
1708
+ props: {
1709
+ modelValue: {},
1710
+ components: {
1711
+ type: Object,
1712
+ default: () => ({})
1713
+ },
1714
+ options: {
1715
+ type: Array,
1716
+ default() {
1717
+ return [];
1718
+ }
1719
+ },
1720
+ disabled: {
1721
+ type: Boolean,
1722
+ default: !1
1723
+ },
1724
+ clearable: {
1725
+ type: Boolean,
1726
+ default: !0
1727
+ },
1728
+ deselectFromDropdown: {
1729
+ type: Boolean,
1730
+ default: !1
1731
+ },
1732
+ searchable: {
1733
+ type: Boolean,
1734
+ default: !0
1735
+ },
1736
+ multiple: {
1737
+ type: Boolean,
1738
+ default: !1
1739
+ },
1740
+ placeholder: {
1741
+ type: String,
1742
+ default: ""
1743
+ },
1744
+ transition: {
1745
+ type: String,
1746
+ default: "vs__fade"
1747
+ },
1748
+ clearSearchOnSelect: {
1749
+ type: Boolean,
1750
+ default: !0
1751
+ },
1752
+ closeOnSelect: {
1753
+ type: Boolean,
1754
+ default: !0
1755
+ },
1756
+ label: {
1757
+ type: String,
1758
+ default: "label"
1759
+ },
1760
+ autocomplete: {
1761
+ type: String,
1762
+ default: "off"
1763
+ },
1764
+ reduce: {
1765
+ type: Function,
1766
+ default: (e) => e
1767
+ },
1768
+ selectable: {
1769
+ type: Function,
1770
+ default: (e) => !0
1771
+ },
1772
+ getOptionLabel: {
1773
+ type: Function,
1774
+ default(e) {
1775
+ return typeof e == "object" ? e.hasOwnProperty(this.label) ? e[this.label] : console.warn(`[vue-select warn]: Label key "option.${this.label}" does not exist in options object ${JSON.stringify(e)}.
1776
+ https://vue-select.org/api/props.html#getoptionlabel`) : e;
1777
+ }
1778
+ },
1779
+ getOptionKey: {
1780
+ type: Function,
1781
+ default(e) {
1782
+ if (typeof e != "object")
1783
+ return e;
1784
+ try {
1785
+ return e.hasOwnProperty("id") ? e.id : Ln(e);
1786
+ } catch (t) {
1787
+ return console.warn(`[vue-select warn]: Could not stringify this option to generate unique key. Please provide'getOptionKey' prop to return a unique key for each option.
1788
+ https://vue-select.org/api/props.html#getoptionkey`, e, t);
1789
+ }
1790
+ }
1791
+ },
1792
+ onTab: {
1793
+ type: Function,
1794
+ default: function() {
1795
+ this.selectOnTab && !this.isComposing && this.typeAheadSelect();
1796
+ }
1797
+ },
1798
+ taggable: {
1799
+ type: Boolean,
1800
+ default: !1
1801
+ },
1802
+ tabindex: {
1803
+ type: Number,
1804
+ default: null
1805
+ },
1806
+ pushTags: {
1807
+ type: Boolean,
1808
+ default: !1
1809
+ },
1810
+ filterable: {
1811
+ type: Boolean,
1812
+ default: !0
1813
+ },
1814
+ filterBy: {
1815
+ type: Function,
1816
+ default(e, t, s) {
1817
+ return (t || "").toLocaleLowerCase().indexOf(s.toLocaleLowerCase()) > -1;
1818
+ }
1819
+ },
1820
+ filter: {
1821
+ type: Function,
1822
+ default(e, t) {
1823
+ return e.filter((s) => {
1824
+ let n = this.getOptionLabel(s);
1825
+ return typeof n == "number" && (n = n.toString()), this.filterBy(s, n, t);
1826
+ });
1827
+ }
1828
+ },
1829
+ createOption: {
1830
+ type: Function,
1831
+ default(e) {
1832
+ return typeof this.optionList[0] == "object" ? { [this.label]: e } : e;
1833
+ }
1834
+ },
1835
+ resetOnOptionsChange: {
1836
+ default: !1,
1837
+ validator: (e) => ["function", "boolean"].includes(typeof e)
1838
+ },
1839
+ clearSearchOnBlur: {
1840
+ type: Function,
1841
+ default: function({ clearSearchOnSelect: e, multiple: t }) {
1842
+ return e && !t;
1843
+ }
1844
+ },
1845
+ noDrop: {
1846
+ type: Boolean,
1847
+ default: !1
1848
+ },
1849
+ inputId: {
1850
+ type: String
1851
+ },
1852
+ dir: {
1853
+ type: String,
1854
+ default: "auto"
1855
+ },
1856
+ selectOnTab: {
1857
+ type: Boolean,
1858
+ default: !1
1859
+ },
1860
+ selectOnKeyCodes: {
1861
+ type: Array,
1862
+ default: () => [13]
1863
+ },
1864
+ searchInputQuerySelector: {
1865
+ type: String,
1866
+ default: "[type=search]"
1867
+ },
1868
+ mapKeydown: {
1869
+ type: Function,
1870
+ default: (e, t) => e
1871
+ },
1872
+ appendToBody: {
1873
+ type: Boolean,
1874
+ default: !1
1875
+ },
1876
+ calculatePosition: {
1877
+ type: Function,
1878
+ default(e, t, { width: s, top: n, left: d }) {
1879
+ e.style.top = n, e.style.left = d, e.style.width = s;
1880
+ }
1881
+ },
1882
+ dropdownShouldOpen: {
1883
+ type: Function,
1884
+ default({ noDrop: e, open: t, mutableLoading: s }) {
1885
+ return e ? !1 : t && !s;
1886
+ }
1887
+ },
1888
+ uid: {
1889
+ type: [String, Number],
1890
+ default: () => Pn()
1891
+ }
1892
+ },
1893
+ data() {
1894
+ return {
1895
+ search: "",
1896
+ open: !1,
1897
+ isComposing: !1,
1898
+ pushedTags: [],
1899
+ _value: [],
1900
+ deselectButtons: []
1901
+ };
1902
+ },
1903
+ computed: {
1904
+ isReducingValues() {
1905
+ return this.$props.reduce !== this.$options.props.reduce.default;
1906
+ },
1907
+ isTrackingValues() {
1908
+ return typeof this.modelValue > "u" || this.isReducingValues;
1909
+ },
1910
+ selectedValue() {
1911
+ let e = this.modelValue;
1912
+ return this.isTrackingValues && (e = this.$data._value), e != null && e !== "" ? [].concat(e) : [];
1913
+ },
1914
+ optionList() {
1915
+ return this.options.concat(this.pushTags ? this.pushedTags : []);
1916
+ },
1917
+ searchEl() {
1918
+ return this.$slots.search ? this.$refs.selectedOptions.querySelector(this.searchInputQuerySelector) : this.$refs.search;
1919
+ },
1920
+ scope() {
1921
+ const e = {
1922
+ search: this.search,
1923
+ loading: this.loading,
1924
+ searching: this.searching,
1925
+ filteredOptions: this.filteredOptions
1926
+ };
1927
+ return {
1928
+ search: {
1929
+ attributes: X({
1930
+ disabled: this.disabled,
1931
+ placeholder: this.searchPlaceholder,
1932
+ tabindex: this.tabindex,
1933
+ readonly: !this.searchable,
1934
+ id: this.inputId,
1935
+ "aria-autocomplete": "list",
1936
+ "aria-labelledby": `vs${this.uid}__combobox`,
1937
+ "aria-controls": `vs${this.uid}__listbox`,
1938
+ ref: "search",
1939
+ type: "search",
1940
+ autocomplete: this.autocomplete,
1941
+ value: this.search
1942
+ }, this.dropdownOpen && this.filteredOptions[this.typeAheadPointer] ? {
1943
+ "aria-activedescendant": `vs${this.uid}__option-${this.typeAheadPointer}`
1944
+ } : {}),
1945
+ events: {
1946
+ compositionstart: () => this.isComposing = !0,
1947
+ compositionend: () => this.isComposing = !1,
1948
+ keydown: this.onSearchKeyDown,
1949
+ blur: this.onSearchBlur,
1950
+ focus: this.onSearchFocus,
1951
+ input: (t) => this.search = t.target.value
1952
+ }
1953
+ },
1954
+ spinner: {
1955
+ loading: this.mutableLoading
1956
+ },
1957
+ noOptions: {
1958
+ search: this.search,
1959
+ loading: this.mutableLoading,
1960
+ searching: this.searching
1961
+ },
1962
+ openIndicator: {
1963
+ attributes: {
1964
+ ref: "openIndicator",
1965
+ role: "presentation",
1966
+ class: "vs__open-indicator"
1967
+ }
1968
+ },
1969
+ listHeader: e,
1970
+ listFooter: e,
1971
+ header: Oe(X({}, e), { deselect: this.deselect }),
1972
+ footer: Oe(X({}, e), { deselect: this.deselect })
1973
+ };
1974
+ },
1975
+ childComponents() {
1976
+ return X(X({}, Le), this.components);
1977
+ },
1978
+ stateClasses() {
1979
+ return {
1980
+ "vs--open": this.dropdownOpen,
1981
+ "vs--single": !this.multiple,
1982
+ "vs--multiple": this.multiple,
1983
+ "vs--searching": this.searching && !this.noDrop,
1984
+ "vs--searchable": this.searchable && !this.noDrop,
1985
+ "vs--unsearchable": !this.searchable,
1986
+ "vs--loading": this.mutableLoading,
1987
+ "vs--disabled": this.disabled
1988
+ };
1989
+ },
1990
+ searching() {
1991
+ return !!this.search;
1992
+ },
1993
+ dropdownOpen() {
1994
+ return this.dropdownShouldOpen(this);
1995
+ },
1996
+ searchPlaceholder() {
1997
+ return this.isValueEmpty && this.placeholder ? this.placeholder : void 0;
1998
+ },
1999
+ filteredOptions() {
2000
+ const e = [].concat(this.optionList);
2001
+ if (!this.filterable && !this.taggable)
2002
+ return e;
2003
+ const t = this.search.length ? this.filter(e, this.search, this) : e;
2004
+ if (this.taggable && this.search.length) {
2005
+ const s = this.createOption(this.search);
2006
+ this.optionExists(s) || t.unshift(s);
2007
+ }
2008
+ return t;
2009
+ },
2010
+ isValueEmpty() {
2011
+ return this.selectedValue.length === 0;
2012
+ },
2013
+ showClearButton() {
2014
+ return !this.multiple && this.clearable && !this.open && !this.isValueEmpty;
2015
+ }
2016
+ },
2017
+ watch: {
2018
+ options(e, t) {
2019
+ const s = () => typeof this.resetOnOptionsChange == "function" ? this.resetOnOptionsChange(e, t, this.selectedValue) : this.resetOnOptionsChange;
2020
+ !this.taggable && s() && this.clearSelection(), this.modelValue && this.isTrackingValues && this.setInternalValueFromOptions(this.modelValue);
2021
+ },
2022
+ modelValue: {
2023
+ immediate: !0,
2024
+ handler(e) {
2025
+ this.isTrackingValues && this.setInternalValueFromOptions(e);
2026
+ }
2027
+ },
2028
+ multiple() {
2029
+ this.clearSelection();
2030
+ },
2031
+ open(e) {
2032
+ this.$emit(e ? "open" : "close");
2033
+ }
2034
+ },
2035
+ created() {
2036
+ this.mutableLoading = this.loading;
2037
+ },
2038
+ methods: {
2039
+ setInternalValueFromOptions(e) {
2040
+ Array.isArray(e) ? this.$data._value = e.map((t) => this.findOptionFromReducedValue(t)) : this.$data._value = this.findOptionFromReducedValue(e);
2041
+ },
2042
+ select(e) {
2043
+ this.$emit("option:selecting", e), this.isOptionSelected(e) ? this.deselectFromDropdown && (this.clearable || this.multiple && this.selectedValue.length > 1) && this.deselect(e) : (this.taggable && !this.optionExists(e) && (this.$emit("option:created", e), this.pushTag(e)), this.multiple && (e = this.selectedValue.concat(e)), this.updateValue(e), this.$emit("option:selected", e)), this.onAfterSelect(e);
2044
+ },
2045
+ deselect(e) {
2046
+ this.$emit("option:deselecting", e), this.updateValue(this.selectedValue.filter((t) => !this.optionComparator(t, e))), this.$emit("option:deselected", e);
2047
+ },
2048
+ clearSelection() {
2049
+ this.updateValue(this.multiple ? [] : null);
2050
+ },
2051
+ onAfterSelect(e) {
2052
+ this.closeOnSelect && (this.open = !this.open, this.searchEl.blur()), this.clearSearchOnSelect && (this.search = "");
2053
+ },
2054
+ updateValue(e) {
2055
+ typeof this.modelValue > "u" && (this.$data._value = e), e !== null && (Array.isArray(e) ? e = e.map((t) => this.reduce(t)) : e = this.reduce(e)), this.$emit("update:modelValue", e);
2056
+ },
2057
+ toggleDropdown(e) {
2058
+ const t = e.target !== this.searchEl;
2059
+ t && e.preventDefault();
2060
+ const s = [
2061
+ ...this.deselectButtons || [],
2062
+ this.$refs.clearButton
2063
+ ];
2064
+ if (this.searchEl === void 0 || s.filter(Boolean).some((n) => n.contains(e.target) || n === e.target)) {
2065
+ e.preventDefault();
2066
+ return;
2067
+ }
2068
+ this.open && t ? this.searchEl.blur() : this.disabled || (this.open = !0, this.searchEl.focus());
2069
+ },
2070
+ isOptionSelected(e) {
2071
+ return this.selectedValue.some((t) => this.optionComparator(t, e));
2072
+ },
2073
+ isOptionDeselectable(e) {
2074
+ return this.isOptionSelected(e) && this.deselectFromDropdown;
2075
+ },
2076
+ optionComparator(e, t) {
2077
+ return this.getOptionKey(e) === this.getOptionKey(t);
2078
+ },
2079
+ findOptionFromReducedValue(e) {
2080
+ const t = (n) => JSON.stringify(this.reduce(n)) === JSON.stringify(e), s = [...this.options, ...this.pushedTags].filter(t);
2081
+ return s.length === 1 ? s[0] : s.find((n) => this.optionComparator(n, this.$data._value)) || e;
2082
+ },
2083
+ closeSearchOptions() {
2084
+ this.open = !1, this.$emit("search:blur");
2085
+ },
2086
+ maybeDeleteValue() {
2087
+ if (!this.searchEl.value.length && this.selectedValue && this.selectedValue.length && this.clearable) {
2088
+ let e = null;
2089
+ this.multiple && (e = [
2090
+ ...this.selectedValue.slice(0, this.selectedValue.length - 1)
2091
+ ]), this.updateValue(e);
2092
+ }
2093
+ },
2094
+ optionExists(e) {
2095
+ return this.optionList.some((t) => this.optionComparator(t, e));
2096
+ },
2097
+ normalizeOptionForSlot(e) {
2098
+ return typeof e == "object" ? e : { [this.label]: e };
2099
+ },
2100
+ pushTag(e) {
2101
+ this.pushedTags.push(e);
2102
+ },
2103
+ onEscape() {
2104
+ this.search.length ? this.search = "" : this.searchEl.blur();
2105
+ },
2106
+ onSearchBlur() {
2107
+ if (this.mousedown && !this.searching)
2108
+ this.mousedown = !1;
2109
+ else {
2110
+ const { clearSearchOnSelect: e, multiple: t } = this;
2111
+ this.clearSearchOnBlur({ clearSearchOnSelect: e, multiple: t }) && (this.search = ""), this.closeSearchOptions();
2112
+ return;
2113
+ }
2114
+ if (this.search.length === 0 && this.options.length === 0) {
2115
+ this.closeSearchOptions();
2116
+ return;
2117
+ }
2118
+ },
2119
+ onSearchFocus() {
2120
+ this.open = !0, this.$emit("search:focus");
2121
+ },
2122
+ onMousedown() {
2123
+ this.mousedown = !0;
2124
+ },
2125
+ onMouseUp() {
2126
+ this.mousedown = !1;
2127
+ },
2128
+ onSearchKeyDown(e) {
2129
+ const t = (d) => (d.preventDefault(), !this.isComposing && this.typeAheadSelect()), s = {
2130
+ 8: (d) => this.maybeDeleteValue(),
2131
+ 9: (d) => this.onTab(),
2132
+ 27: (d) => this.onEscape(),
2133
+ 38: (d) => (d.preventDefault(), this.typeAheadUp()),
2134
+ 40: (d) => (d.preventDefault(), this.typeAheadDown())
2135
+ };
2136
+ this.selectOnKeyCodes.forEach((d) => s[d] = t);
2137
+ const n = this.mapKeydown(s, this);
2138
+ if (typeof n[e.keyCode] == "function")
2139
+ return n[e.keyCode](e);
2140
+ }
2141
+ }
2142
+ }, Mn = ["dir"], Dn = ["id", "aria-expanded", "aria-owns"], An = {
2143
+ ref: "selectedOptions",
2144
+ class: "vs__selected-options"
2145
+ }, Vn = ["disabled", "title", "aria-label", "onClick"], In = {
2146
+ ref: "actions",
2147
+ class: "vs__actions"
2148
+ }, Un = ["disabled"], Bn = { class: "vs__spinner" }, En = ["id"], jn = ["id", "aria-selected", "onMouseover", "onClick"], Tn = {
2149
+ key: 0,
2150
+ class: "vs__no-options"
2151
+ }, Fn = /* @__PURE__ */ W(" Sorry, no matching options. "), qn = ["id"];
2152
+ function Rn(e, t, s, n, d, c) {
2153
+ const p = Ie("append-to-body");
2154
+ return o(), r("div", {
2155
+ dir: s.dir,
2156
+ class: te(["v-select", c.stateClasses])
2157
+ }, [
2158
+ z(e.$slots, "header", V(U(c.scope.header))),
2159
+ a("div", {
2160
+ id: `vs${s.uid}__combobox`,
2161
+ ref: "toggle",
2162
+ class: "vs__dropdown-toggle",
2163
+ role: "combobox",
2164
+ "aria-expanded": c.dropdownOpen.toString(),
2165
+ "aria-owns": `vs${s.uid}__listbox`,
2166
+ "aria-label": "Search for option",
2167
+ onMousedown: t[1] || (t[1] = (l) => c.toggleDropdown(l))
2168
+ }, [
2169
+ a("div", An, [
2170
+ (o(!0), r(O, null, L(c.selectedValue, (l, u) => z(e.$slots, "selected-option-container", {
2171
+ option: c.normalizeOptionForSlot(l),
2172
+ deselect: c.deselect,
2173
+ multiple: s.multiple,
2174
+ disabled: s.disabled
2175
+ }, () => [
2176
+ (o(), r("span", {
2177
+ key: s.getOptionKey(l),
2178
+ class: "vs__selected"
2179
+ }, [
2180
+ z(e.$slots, "selected-option", V(U(c.normalizeOptionForSlot(l))), () => [
2181
+ W(f(s.getOptionLabel(l)), 1)
2182
+ ]),
2183
+ s.multiple ? (o(), r("button", {
2184
+ key: 0,
2185
+ ref_for: !0,
2186
+ ref: (i) => d.deselectButtons[u] = i,
2187
+ disabled: s.disabled,
2188
+ type: "button",
2189
+ class: "vs__deselect",
2190
+ title: `Deselect ${s.getOptionLabel(l)}`,
2191
+ "aria-label": `Deselect ${s.getOptionLabel(l)}`,
2192
+ onClick: (i) => c.deselect(l)
2193
+ }, [
2194
+ (o(), $(le(c.childComponents.Deselect)))
2195
+ ], 8, Vn)) : g("", !0)
2196
+ ]))
2197
+ ])), 256)),
2198
+ z(e.$slots, "search", V(U(c.scope.search)), () => [
2199
+ a("input", ve({ class: "vs__search" }, c.scope.search.attributes, Ue(c.scope.search.events)), null, 16)
2200
+ ])
2201
+ ], 512),
2202
+ a("div", In, [
2203
+ ae(a("button", {
2204
+ ref: "clearButton",
2205
+ disabled: s.disabled,
2206
+ type: "button",
2207
+ class: "vs__clear",
2208
+ title: "Clear Selected",
2209
+ "aria-label": "Clear Selected",
2210
+ onClick: t[0] || (t[0] = (...l) => c.clearSelection && c.clearSelection(...l))
2211
+ }, [
2212
+ (o(), $(le(c.childComponents.Deselect)))
2213
+ ], 8, Un), [
2214
+ [ye, c.showClearButton]
2215
+ ]),
2216
+ z(e.$slots, "open-indicator", V(U(c.scope.openIndicator)), () => [
2217
+ s.noDrop ? g("", !0) : (o(), $(le(c.childComponents.OpenIndicator), V(ve({ key: 0 }, c.scope.openIndicator.attributes)), null, 16))
2218
+ ]),
2219
+ z(e.$slots, "spinner", V(U(c.scope.spinner)), () => [
2220
+ ae(a("div", Bn, "Loading...", 512), [
2221
+ [ye, e.mutableLoading]
2222
+ ])
2223
+ ])
2224
+ ], 512)
2225
+ ], 40, Dn),
2226
+ h(H, { name: s.transition }, {
2227
+ default: x(() => [
2228
+ c.dropdownOpen ? ae((o(), r("ul", {
2229
+ id: `vs${s.uid}__listbox`,
2230
+ ref: "dropdownMenu",
2231
+ key: `vs${s.uid}__listbox`,
2232
+ class: "vs__dropdown-menu",
2233
+ role: "listbox",
2234
+ tabindex: "-1",
2235
+ onMousedown: t[2] || (t[2] = re((...l) => c.onMousedown && c.onMousedown(...l), ["prevent"])),
2236
+ onMouseup: t[3] || (t[3] = (...l) => c.onMouseUp && c.onMouseUp(...l))
2237
+ }, [
2238
+ z(e.$slots, "list-header", V(U(c.scope.listHeader))),
2239
+ (o(!0), r(O, null, L(c.filteredOptions, (l, u) => (o(), r("li", {
2240
+ id: `vs${s.uid}__option-${u}`,
2241
+ key: s.getOptionKey(l),
2242
+ role: "option",
2243
+ class: te(["vs__dropdown-option", {
2244
+ "vs__dropdown-option--deselect": c.isOptionDeselectable(l) && u === e.typeAheadPointer,
2245
+ "vs__dropdown-option--selected": c.isOptionSelected(l),
2246
+ "vs__dropdown-option--highlight": u === e.typeAheadPointer,
2247
+ "vs__dropdown-option--disabled": !s.selectable(l)
2248
+ }]),
2249
+ "aria-selected": u === e.typeAheadPointer ? !0 : null,
2250
+ onMouseover: (i) => s.selectable(l) ? e.typeAheadPointer = u : null,
2251
+ onClick: re((i) => s.selectable(l) ? c.select(l) : null, ["prevent", "stop"])
2252
+ }, [
2253
+ z(e.$slots, "option", V(U(c.normalizeOptionForSlot(l))), () => [
2254
+ W(f(s.getOptionLabel(l)), 1)
2255
+ ])
2256
+ ], 42, jn))), 128)),
2257
+ c.filteredOptions.length === 0 ? (o(), r("li", Tn, [
2258
+ z(e.$slots, "no-options", V(U(c.scope.noOptions)), () => [
2259
+ Fn
2260
+ ])
2261
+ ])) : g("", !0),
2262
+ z(e.$slots, "list-footer", V(U(c.scope.listFooter)))
2263
+ ], 40, En)), [
2264
+ [p]
2265
+ ]) : (o(), r("ul", {
2266
+ key: 1,
2267
+ id: `vs${s.uid}__listbox`,
2268
+ role: "listbox",
2269
+ style: { display: "none", visibility: "hidden" }
2270
+ }, null, 8, qn))
2271
+ ]),
2272
+ _: 3
2273
+ }, 8, ["name"]),
2274
+ z(e.$slots, "footer", V(U(c.scope.footer)))
2275
+ ], 10, Mn);
2276
+ }
2277
+ const Ve = /* @__PURE__ */ be(zn, [["render", Rn]]);
2278
+ const Zn = { class: "w-100" }, Hn = { class: "flex" }, Nn = { class: "mn-regular" }, Kn = { class: "flex-column flex-wrap block" }, Wn = {
2279
+ key: 0,
2280
+ class: "w-100"
2281
+ }, Yn = { class: "w-100 flex-center flex-nowrap flex" }, Jn = { class: "mn-r-regular w-100" }, Qn = ["onClick"], Xn = {
2282
+ key: 0,
2283
+ class: "mn-t-small mn-small w-100"
2284
+ }, Li = {
2285
+ __name: "EditArray",
2286
+ props: {
2287
+ name: Object,
2288
+ items: Array
2289
+ },
2290
+ emits: ["add", "remove"],
2291
+ setup(e, { emit: t }) {
2292
+ q(), F();
2293
+ let s = oe([]);
2294
+ Be(s);
2295
+ const n = v(null), d = v(null), c = v(null);
2296
+ Z(() => {
2297
+ if (n.value === null || c.value === null || c.value === "")
2298
+ return !0;
2299
+ if (n.value.modifications.length > 0)
2300
+ return d.value === null;
2301
+ });
2302
+ function p(l) {
2303
+ store.commit("leftovers/deleteItemFromLeftover", l);
2304
+ }
2305
+ return (l, u) => (o(), r("div", Zn, [
2306
+ a("div", Hn, [
2307
+ a("h3", Nn, f(e.name), 1)
2308
+ ]),
2309
+ a("ul", Kn, [
2310
+ e.items.length < 1 ? (o(), r("span", Wn, "Вы еще не добавили позиции")) : g("", !0),
2311
+ (o(!0), r(O, null, L(e.items, (i, m) => (o(), r("li", {
2312
+ key: i._id,
2313
+ class: "w-100"
2314
+ }, [
2315
+ a("div", Yn, [
2316
+ a("span", Jn, f(i.name), 1),
2317
+ a("a", {
2318
+ class: "w-20 button",
2319
+ onClick: (w) => p(i)
2320
+ }, "Удалить", 8, Qn)
2321
+ ]),
2322
+ m != e.items.length - 1 ? (o(), r("hr", Xn)) : g("", !0)
2323
+ ]))), 128))
2324
+ ])
2325
+ ]));
2326
+ }
2327
+ };
2328
+ const Gn = { class: "br-grey radius-small mn-small" }, eo = {
2329
+ key: 1,
2330
+ class: "pd-small br-grey br-1px br-solid"
2331
+ }, to = ["disabled"], so = {
2332
+ __name: "DepartmentMemberModify",
2333
+ props: {
2334
+ isPopupOpen: Boolean,
2335
+ department: Number,
2336
+ departments: Array,
2337
+ maindepartment: Object,
2338
+ alldepartments: Array
2339
+ },
2340
+ emits: ["callback", "remove"],
2341
+ setup(e, { emit: t }) {
2342
+ const s = e, n = v({
2343
+ subdepartment: null
2344
+ });
2345
+ s.department !== null && (n.value = s.departments[s.department]);
2346
+ function d(u, i, m) {
2347
+ return u.filter((w) => !(i.some((P) => P._id === w._id) || m._id === w._id));
2348
+ }
2349
+ const c = Z(() => d(s.alldepartments, s.departments, s.maindepartment));
2350
+ async function p() {
2351
+ s.departments.push(n.value.subdepartment), t("callback");
2352
+ }
2353
+ async function l() {
2354
+ s.departments.splice(s.department, 1), t("callback");
2355
+ }
2356
+ return (u, i) => (o(), r("div", null, [
2357
+ a("div", Gn, [
2358
+ s.department === null ? (o(), $(k(Ve), {
2359
+ key: 0,
2360
+ modelValue: n.value.subdepartment,
2361
+ "onUpdate:modelValue": i[0] || (i[0] = (m) => n.value.subdepartment = m),
2362
+ options: k(c),
2363
+ "get-option-label": (m) => m.name,
2364
+ class: "w-100 mn-small"
2365
+ }, null, 8, ["modelValue", "options", "get-option-label"])) : (o(), r("div", eo, f(n.value.name ? n.value.name : "Безымянный"), 1))
2366
+ ]),
2367
+ s.department === null ? (o(), r("button", {
2368
+ key: 0,
2369
+ disabled: !n.value.subdepartment,
2370
+ onClick: p,
2371
+ class: "w-100 button bg-second t-white"
2372
+ }, " Добавить отдел ", 8, to)) : g("", !0),
2373
+ s.department !== null ? (o(), r("button", {
2374
+ key: 1,
2375
+ onClick: l,
2376
+ class: "w-100 button bg-fourth t-white"
2377
+ }, " Удалить отдел ")) : g("", !0)
2378
+ ]));
2379
+ }
2380
+ }, Si = /* @__PURE__ */ A(so, [["__scopeId", "data-v-21f393e1"]]);
2381
+ const ao = { class: "br-grey radius-small mn-small" }, no = {
2382
+ key: 1,
2383
+ class: "pd-small br-grey br-1px br-solid"
2384
+ }, oo = ["disabled"], io = {
2385
+ __name: "DepartmentSubDepartmentModify",
2386
+ props: {
2387
+ isPopupOpen: Boolean,
2388
+ department: Number,
2389
+ departments: Array,
2390
+ maindepartment: Object,
2391
+ alldepartments: Array
2392
+ },
2393
+ emits: ["callback", "remove"],
2394
+ setup(e, { emit: t }) {
2395
+ const s = e, n = v({
2396
+ subdepartment: null
2397
+ });
2398
+ s.department !== null && (n.value = s.departments[s.department]);
2399
+ function d(u, i, m) {
2400
+ return u.filter((w) => !(i.some((P) => P._id === w._id) || m._id === w._id));
2401
+ }
2402
+ const c = Z(() => d(s.alldepartments, s.departments, s.maindepartment));
2403
+ async function p() {
2404
+ s.departments.push(n.value.subdepartment), t("callback");
2405
+ }
2406
+ async function l() {
2407
+ s.departments.splice(s.department, 1), t("callback");
2408
+ }
2409
+ return (u, i) => (o(), r("div", null, [
2410
+ a("div", ao, [
2411
+ s.department === null ? (o(), $(k(Ve), {
2412
+ key: 0,
2413
+ modelValue: n.value.subdepartment,
2414
+ "onUpdate:modelValue": i[0] || (i[0] = (m) => n.value.subdepartment = m),
2415
+ options: k(c),
2416
+ "get-option-label": (m) => m.name,
2417
+ class: "w-100 mn-small"
2418
+ }, null, 8, ["modelValue", "options", "get-option-label"])) : (o(), r("div", no, f(n.value.name ? n.value.name : "Безымянный"), 1))
2419
+ ]),
2420
+ s.department === null ? (o(), r("button", {
2421
+ key: 0,
2422
+ disabled: !n.value.subdepartment,
2423
+ onClick: p,
2424
+ class: "w-100 button bg-second t-white"
2425
+ }, " Добавить отдел ", 8, oo)) : g("", !0),
2426
+ s.department !== null ? (o(), r("button", {
2427
+ key: 1,
2428
+ onClick: l,
2429
+ class: "w-100 button bg-fourth t-white"
2430
+ }, " Удалить отдел ")) : g("", !0)
2431
+ ]));
2432
+ }
2433
+ }, Pi = /* @__PURE__ */ A(io, [["__scopeId", "data-v-d3c6f191"]]);
2434
+ const se = (e) => (me("data-v-195322bd"), e = e(), he(), e), lo = { class: "for-transition w-100" }, ro = { class: "pd-b-zero pd-t-zero pd-thin" }, co = { class: "pd-thin" }, uo = { class: "flex-nowrap flex bg-grey pd-medium radius-big" }, po = {
2435
+ key: 0,
2436
+ class: "mn-r-auto"
2437
+ }, mo = {
2438
+ key: 1,
2439
+ class: "mn-r-auto"
2440
+ }, ho = { class: "flex-nowrap flex pd-thin" }, _o = { class: "pd-b-zero pd-t-zero pd-thin cols-2 gap-thin" }, fo = { class: "flex-stretch flex-column flex" }, go = { class: "mn-thin bg-grey pd-medium o-hidden radius-big" }, bo = /* @__PURE__ */ se(() => /* @__PURE__ */ a("h3", { class: "mn-semi" }, "Profile", -1)), vo = { class: "radius-small flex-nowrap flex" }, yo = { class: "w-100 flex-child-grow-1 flex-child" }, wo = { class: "bg-grey pd-medium o-hidden radius-big" }, $o = /* @__PURE__ */ se(() => /* @__PURE__ */ a("h3", { class: "mn-semi" }, "Details", -1)), Co = /* @__PURE__ */ se(() => /* @__PURE__ */ a("p", { class: "p-medium mn-small" }, "Please the available delivery options:", -1)), ko = { class: "mn-medium flex-nowrap flex" }, xo = /* @__PURE__ */ se(() => /* @__PURE__ */ a("p", { class: "p-medium mn-small" }, "Please select the available payment methods:", -1)), Oo = { class: "flex-nowrap flex" }, Lo = { class: "bg-grey pd-medium o-hidden radius-big" }, So = /* @__PURE__ */ se(() => /* @__PURE__ */ a("h3", { class: "mn-semi" }, "Location", -1)), Po = /* @__PURE__ */ se(() => /* @__PURE__ */ a("p", { class: "mn-small p-medium" }, "Or choose on map:", -1)), zo = { class: "flex-nowrap flex pd-thin" }, Mo = {
2441
+ __name: "DepartmentEdit",
2442
+ setup(e) {
2443
+ const t = q(), s = F();
2444
+ v("details"), v(!1);
2445
+ async function n() {
2446
+ s.params.department && await ge.read(s.params.department), v(Re.memberships), await K.read(s.params._id), s.params.department && await K.readOne(s.params.department);
2447
+ }
2448
+ n(), v(_.department.members), v(!1), v(null), v(!1), v(null);
2449
+ async function d() {
2450
+ s.params.department && await K.update(
2451
+ s.params._id,
2452
+ _.department
2453
+ ), s.params.department || await K.create(
2454
+ s.params._id,
2455
+ _.department
2456
+ );
2457
+ }
2458
+ function c() {
2459
+ t.replace({ name: "Department", params: { _id: s.params._id, department: _.department._id } });
2460
+ }
2461
+ async function p() {
2462
+ await K.delete(
2463
+ s.params._id,
2464
+ _.department
2465
+ );
2466
+ }
2467
+ return (l, u) => (o(), r("div", lo, [
2468
+ a("div", ro, [
2469
+ h(lt, { class: "pd-medium bg-grey radius-big" })
2470
+ ]),
2471
+ a("div", co, [
2472
+ a("header", uo, [
2473
+ k(s).params.department ? (o(), r("h1", po, "Edit Spot")) : (o(), r("h1", mo, "Create Spot")),
2474
+ a("section", ho, [
2475
+ h(ce, {
2476
+ submit: d,
2477
+ callback: c
2478
+ }, {
2479
+ default: x(() => [
2480
+ W("Save Spot")
2481
+ ]),
2482
+ _: 1
2483
+ })
2484
+ ])
2485
+ ])
2486
+ ]),
2487
+ a("div", _o, [
2488
+ a("div", fo, [
2489
+ a("div", go, [
2490
+ bo,
2491
+ a("div", vo, [
2492
+ h(ze, {
2493
+ photo: _.department.profile.photo,
2494
+ "onUpdate:photo": u[0] || (u[0] = (i) => _.department.profile.photo = i),
2495
+ uploadPath: "organizations/" + _.department.name + "/avatars",
2496
+ class: "w-8r aspect-1x1 o-hidden mn-r-small radius-extra"
2497
+ }, null, 8, ["photo", "uploadPath"]),
2498
+ a("div", yo, [
2499
+ h(D, {
2500
+ field: _.department.profile.name,
2501
+ "onUpdate:field": u[1] || (u[1] = (i) => _.department.profile.name = i),
2502
+ label: "Name",
2503
+ placeholder: "Spot Name",
2504
+ class: "mn-small bg-white radius-small pd-medium",
2505
+ validation: l.organizationName
2506
+ }, null, 8, ["field", "validation"]),
2507
+ h(D, {
2508
+ field: _.department.profile.description,
2509
+ "onUpdate:field": u[2] || (u[2] = (i) => _.department.profile.description = i),
2510
+ label: "Description",
2511
+ placeholder: "Spot description (max 120 symbols)",
2512
+ class: "bg-white radius-small pd-medium",
2513
+ validation: l.organizationName
2514
+ }, null, 8, ["field", "validation"])
2515
+ ])
2516
+ ])
2517
+ ]),
2518
+ a("div", wo, [
2519
+ $o,
2520
+ Co,
2521
+ a("div", ko, [
2522
+ h(J, {
2523
+ label: "Pickup",
2524
+ name: "Delivery",
2525
+ value: "pickup",
2526
+ class: "w-100 mn-r-small bg-white radius-small pd-small",
2527
+ radio: _.department.delivery
2528
+ }, null, 8, ["radio"]),
2529
+ h(J, {
2530
+ label: "Delivery",
2531
+ name: "Delivery",
2532
+ value: "courier",
2533
+ class: "w-100 mn-r-small bg-white radius-small pd-small",
2534
+ radio: _.department.delivery
2535
+ }, null, 8, ["radio"]),
2536
+ h(J, {
2537
+ label: "Post",
2538
+ name: "Delivery",
2539
+ value: "post",
2540
+ class: "w-100 bg-white radius-small pd-small",
2541
+ radio: _.department.delivery
2542
+ }, null, 8, ["radio"])
2543
+ ]),
2544
+ xo,
2545
+ a("div", Oo, [
2546
+ h(J, {
2547
+ label: "Cash",
2548
+ name: "Payment",
2549
+ value: "cash",
2550
+ class: "w-100 mn-r-small bg-white radius-small pd-small",
2551
+ radio: _.department.payment
2552
+ }, null, 8, ["radio"]),
2553
+ h(J, {
2554
+ label: "Bank Transfer",
2555
+ name: "Payment",
2556
+ value: "bank",
2557
+ class: "w-100 mn-r-small bg-white radius-small pd-small",
2558
+ radio: _.department.payment
2559
+ }, null, 8, ["radio"]),
2560
+ h(J, {
2561
+ label: "Crypto",
2562
+ name: "Payment",
2563
+ value: "crypto",
2564
+ class: "w-100 bg-white radius-small pd-small",
2565
+ radio: _.department.payment
2566
+ }, null, 8, ["radio"])
2567
+ ])
2568
+ ])
2569
+ ]),
2570
+ a("div", Lo, [
2571
+ So,
2572
+ h(Xa, {
2573
+ apiKey: "AIzaSyDDR6WgYB7XMt7yTDDzQNEdF_gTdUiq8dI",
2574
+ address: _.department.address,
2575
+ location: _.department.location,
2576
+ label: "Address",
2577
+ placeholder: "Enter delivery address",
2578
+ class: "bg-white radius-small pd-small mn-small",
2579
+ "onUpdate:location": u[3] || (u[3] = (i) => {
2580
+ _.department.location = i;
2581
+ }),
2582
+ "onUpdate:address": u[4] || (u[4] = (i) => {
2583
+ _.department.address = i;
2584
+ })
2585
+ }, null, 8, ["address", "location"]),
2586
+ Po,
2587
+ h(nn, {
2588
+ address: _.department.address,
2589
+ location: _.department.location,
2590
+ apiKey: "AIzaSyDDR6WgYB7XMt7yTDDzQNEdF_gTdUiq8dI",
2591
+ class: "radius-big o-hidden",
2592
+ "onUpdate:location": u[5] || (u[5] = (i) => {
2593
+ _.department.location = i;
2594
+ }),
2595
+ "onUpdate:address": u[6] || (u[6] = (i) => {
2596
+ _.department.address = i;
2597
+ })
2598
+ }, null, 8, ["address", "location"])
2599
+ ])
2600
+ ]),
2601
+ a("section", zo, [
2602
+ h(ce, {
2603
+ submit: p,
2604
+ callback: l.redirectToDash,
2605
+ class: "bg-grey"
2606
+ }, {
2607
+ default: x(() => [
2608
+ W("Delete Spot")
2609
+ ]),
2610
+ _: 1
2611
+ }, 8, ["callback"])
2612
+ ])
2613
+ ]));
2614
+ }
2615
+ }, Do = /* @__PURE__ */ A(Mo, [["__scopeId", "data-v-195322bd"]]), Se = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2616
+ __proto__: null,
2617
+ default: Do
2618
+ }, Symbol.toStringTag, { value: "Module" })), Ao = { class: "unit" }, Vo = { class: "unit-details" }, Io = { key: 0 }, Uo = { class: "subunits" }, zi = {
2619
+ __name: "Unit",
2620
+ props: {
2621
+ unit: {
2622
+ type: Object,
2623
+ required: !0
2624
+ },
2625
+ editMode: {
2626
+ type: Boolean,
2627
+ required: !0
2628
+ }
2629
+ },
2630
+ setup(e) {
2631
+ const t = e, s = v({ ...t.unit });
2632
+ T(t.unit, () => {
2633
+ s.value = { ...t.unit };
2634
+ });
2635
+ async function n() {
2636
+ emit("unit-updated", s.value);
2637
+ }
2638
+ async function d() {
2639
+ emit("subunit-added", t.unit._id);
2640
+ }
2641
+ return (c, p) => {
2642
+ const l = ue("unit-component");
2643
+ return o(), r("div", Ao, [
2644
+ a("div", Vo, [
2645
+ a("h3", null, f(e.unit.name), 1),
2646
+ a("p", null, f(e.unit.description), 1),
2647
+ e.editMode ? (o(), r("div", Io, [
2648
+ ae(a("input", {
2649
+ "onUpdate:modelValue": p[0] || (p[0] = (u) => s.value.name = u),
2650
+ placeholder: "Название отдела"
2651
+ }, null, 512), [
2652
+ [we, s.value.name]
2653
+ ]),
2654
+ ae(a("input", {
2655
+ "onUpdate:modelValue": p[1] || (p[1] = (u) => s.value.description = u),
2656
+ placeholder: "Описание отдела"
2657
+ }, null, 512), [
2658
+ [we, s.value.description]
2659
+ ]),
2660
+ a("button", { onClick: n }, "Сохранить"),
2661
+ a("button", { onClick: d }, "Добавить подотдел")
2662
+ ])) : g("", !0)
2663
+ ]),
2664
+ a("div", Uo, [
2665
+ (o(!0), r(O, null, L(e.unit.subunits, (u, i) => (o(), $(l, {
2666
+ key: i,
2667
+ unit: u,
2668
+ "edit-mode": e.editMode
2669
+ }, null, 8, ["unit", "edit-mode"]))), 128))
2670
+ ])
2671
+ ]);
2672
+ };
2673
+ }
2674
+ };
2675
+ const Bo = { class: "br-grey radius-small mn-small" }, Eo = {
2676
+ __name: "Places",
2677
+ props: {
2678
+ isPopupOpen: Boolean,
2679
+ place: Number,
2680
+ places: Array
2681
+ },
2682
+ emits: ["callback"],
2683
+ setup(e, { emit: t }) {
2684
+ const s = e, n = v({
2685
+ logo: "",
2686
+ name: "",
2687
+ address: ""
2688
+ });
2689
+ s.place !== null && (n.value = s.places[s.place]);
2690
+ const d = v(null);
2691
+ async function c() {
2692
+ try {
2693
+ await Qe(
2694
+ d,
2695
+ Xe,
2696
+ n.value.name,
2697
+ "Некорректное название"
2698
+ );
2699
+ } catch {
2700
+ throw new Error();
2701
+ }
2702
+ s.place !== null ? (s.places[s.place] = n.value, t("callback")) : (s.places.push(n.value), t("callback"));
2703
+ }
2704
+ return (p, l) => (o(), r("div", null, [
2705
+ a("div", Bo, [
2706
+ h(Me, {
2707
+ options: [
2708
+ { name: "Кафе", value: "cafe" },
2709
+ { name: "Бар", value: "bar" },
2710
+ { name: "Ресторан", value: "restaraunt" },
2711
+ { name: "Пиццерия", value: "pizzeria" },
2712
+ { name: "Ночной клуб", value: "night-club" },
2713
+ { name: "Шаверма", value: "shaverma" },
2714
+ { name: "Кофейня", value: "coffee" }
2715
+ ],
2716
+ prop: n.value,
2717
+ content: "type",
2718
+ label: "Тип",
2719
+ placeholder: "Тип заведения",
2720
+ size: "small"
2721
+ }, null, 8, ["prop"]),
2722
+ h(D, {
2723
+ field: n.value.name,
2724
+ "onUpdate:field": l[0] || (l[0] = (u) => n.value.name = u),
2725
+ label: "Название",
2726
+ validation: d.value,
2727
+ placeholder: "Введите название места"
2728
+ }, null, 8, ["field", "validation"]),
2729
+ h(D, {
2730
+ field: n.value.address,
2731
+ "onUpdate:field": l[1] || (l[1] = (u) => n.value.address = u),
2732
+ label: "Адрес",
2733
+ validation: d.value,
2734
+ placeholder: "Введите адрес места"
2735
+ }, null, 8, ["field", "validation"]),
2736
+ h(D, {
2737
+ field: n.value.phone,
2738
+ "onUpdate:field": l[2] || (l[2] = (u) => n.value.phone = u),
2739
+ label: "Телефон",
2740
+ validation: d.value,
2741
+ placeholder: "Введите телефон места"
2742
+ }, null, 8, ["field", "validation"])
2743
+ ]),
2744
+ a("button", {
2745
+ onClick: c,
2746
+ class: "w-100 button bg-second t-white"
2747
+ }, f(s.place !== null ? "Редактировать заведение" : "Добавить заведение"), 1)
2748
+ ]));
2749
+ }
2750
+ }, Mi = /* @__PURE__ */ A(Eo, [["__scopeId", "data-v-de5143c5"]]);
2751
+ const jo = (e) => (me("data-v-20739d92"), e = e(), he(), e), To = { class: "documents" }, Fo = /* @__PURE__ */ jo(() => /* @__PURE__ */ a("h3", { class: "mn-small" }, "Список документов", -1)), qo = { class: "mn-big cols-4" }, Ro = ["onClick"], Zo = { class: "mn-small" }, Ho = { class: "t-semi t-transp radius-small" }, No = {
2752
+ __name: "Documents",
2753
+ setup(e) {
2754
+ q(), F();
2755
+ let t = [{
2756
+ name: "Паспорт",
2757
+ status: "Не добавлен",
2758
+ inputs: [{
2759
+ type: "text",
2760
+ name: "Номер и серия"
2761
+ }, {
2762
+ type: "text",
2763
+ name: "Место выдачи"
2764
+ }, {
2765
+ type: "text",
2766
+ name: "Дата выдачи"
2767
+ }]
2768
+ }, {
2769
+ name: "ИНН",
2770
+ status: "Не добавлен",
2771
+ inputs: [{
2772
+ type: "text",
2773
+ name: "Дата регистрации"
2774
+ }]
2775
+ }, {
2776
+ name: "СНИЛС",
2777
+ status: "Не добавлен",
2778
+ inputs: [{
2779
+ type: "text",
2780
+ name: "Дата регистрации"
2781
+ }]
2782
+ }, {
2783
+ name: "Военный билет",
2784
+ status: "Не добавлен",
2785
+ inputs: [{
2786
+ type: "text",
2787
+ name: "Дата регистрации"
2788
+ }]
2789
+ }];
2790
+ const s = v(!1), n = v(null), d = (l) => {
2791
+ n.value = l, s.value = !0;
2792
+ }, c = () => {
2793
+ s.value = !1;
2794
+ }, p = () => {
2795
+ c();
2796
+ };
2797
+ return de(() => {
2798
+ }), (l, u) => {
2799
+ const i = ue("Popup");
2800
+ return o(), r("div", To, [
2801
+ Fo,
2802
+ a("div", qo, [
2803
+ (o(!0), r(O, null, L(k(t), (m, w) => (o(), r("div", {
2804
+ key: w,
2805
+ onClick: (P) => d(w),
2806
+ class: "h-100 pd-medium bg-white radius-small"
2807
+ }, [
2808
+ a("h3", Zo, f(m.name), 1),
2809
+ a("p", Ho, f(m.status), 1)
2810
+ ], 8, Ro))), 128))
2811
+ ]),
2812
+ h(i, {
2813
+ title: "Добавить документ",
2814
+ onClosePopup: c,
2815
+ isPopupOpen: s.value
2816
+ }, {
2817
+ default: x(() => [
2818
+ (o(!0), r(O, null, L(k(t)[n.value].inputs, (m) => (o(), r("div", {
2819
+ key: m.name
2820
+ }, [
2821
+ h(D, {
2822
+ field: m.value,
2823
+ "onUpdate:field": (w) => m.value = w,
2824
+ label: m.name,
2825
+ _id: m.name,
2826
+ placeholder: m.name,
2827
+ class: "w-100"
2828
+ }, null, 8, ["field", "onUpdate:field", "label", "_id", "placeholder"])
2829
+ ]))), 128)),
2830
+ a("button", {
2831
+ onClick: p,
2832
+ class: "w-100 mn-small button"
2833
+ }, "Отправить на верификацию")
2834
+ ]),
2835
+ _: 1
2836
+ }, 8, ["isPopupOpen"])
2837
+ ]);
2838
+ };
2839
+ }
2840
+ }, Di = /* @__PURE__ */ A(No, [["__scopeId", "data-v-20739d92"]]);
2841
+ const Ko = { class: "for-transition bg-white radius-big w-100" }, Wo = { class: "" }, Yo = {
2842
+ key: 1,
2843
+ class: "cols-1"
2844
+ }, Ai = {
2845
+ __name: "Organizations",
2846
+ props: {
2847
+ owner: {
2848
+ type: String,
2849
+ default: null
2850
+ },
2851
+ user: {
2852
+ type: [String, Number],
2853
+ default: null
2854
+ },
2855
+ onlyuser: {
2856
+ type: [String, Number],
2857
+ default: null
2858
+ }
2859
+ },
2860
+ async setup(e) {
2861
+ let t, s;
2862
+ const n = e, d = v(null);
2863
+ d.value = ([t, s] = Y(() => R.read({ owner: n.owner, user: n.user, onlyuser: n.onlyuser })), t = await t, s(), t);
2864
+ const c = q(), p = F();
2865
+ let l = p.query.tab ? p.query.tab : "details";
2866
+ const u = v(l);
2867
+ return p.query.tab = u.value, T(u, (i) => {
2868
+ c.replace({ query: { ...p.query, tab: i } });
2869
+ }), (i, m) => (o(), r("div", Ko, [
2870
+ a("div", Wo, [
2871
+ d.value < 1 ? (o(), $(fe, {
2872
+ key: 0,
2873
+ title: "You Haven't Joined Any Organization Yet",
2874
+ description: "Weeder is all about community. Join an organization or maybe you want to create your own?",
2875
+ action: "Create organization",
2876
+ callback: i.a = () => i.$router.push("/app/organization/create/details")
2877
+ }, null, 8, ["callback"])) : (o(), r("div", Yo, [
2878
+ (o(!0), r(O, null, L(d.value, (w) => (o(), $(We, {
2879
+ key: w._id,
2880
+ organization: w,
2881
+ user: S.user,
2882
+ onUpdateMembership: i.handleMembershipUpdate,
2883
+ class: te(["w-100", { "mn-r-small": i.index !== d.value.length - 1 }])
2884
+ }, null, 8, ["organization", "user", "onUpdateMembership", "class"]))), 128))
2885
+ ]))
2886
+ ])
2887
+ ]));
2888
+ }
2889
+ }, Jo = {};
2890
+ function Qo(e, t) {
2891
+ const s = ue("router-view");
2892
+ return o(), $(s, null, {
2893
+ default: x(({ Component: n, route: d }) => [
2894
+ (o(), $(le(n)))
2895
+ ]),
2896
+ _: 1
2897
+ });
2898
+ }
2899
+ const Xo = /* @__PURE__ */ A(Jo, [["render", Qo]]), Vi = [{
2900
+ path: "organizations",
2901
+ component: Xo,
2902
+ meta: {
2903
+ title: {
2904
+ en: "Organizations",
2905
+ ru: "Организации"
2906
+ }
2907
+ },
2908
+ children: [{
2909
+ path: ":_id",
2910
+ name: "Organization",
2911
+ meta: {
2912
+ title: {
2913
+ en: "Organization",
2914
+ ru: "Организация"
2915
+ }
2916
+ },
2917
+ component: () => Promise.resolve().then(() => Hs)
2918
+ }, {
2919
+ path: "create",
2920
+ name: "Create Organization",
2921
+ title: {
2922
+ en: "Create Organization",
2923
+ ru: "Создать Организацию"
2924
+ },
2925
+ component: () => Promise.resolve().then(() => Ce)
2926
+ }, {
2927
+ path: ":_id/edit",
2928
+ name: "Organization Edit",
2929
+ meta: {
2930
+ title: {
2931
+ en: "Edit Organization",
2932
+ ru: "Редактировать Организацию"
2933
+ }
2934
+ },
2935
+ component: () => Promise.resolve().then(() => Ce)
2936
+ }, {
2937
+ path: ":_id/departments/create",
2938
+ name: "Department Creation",
2939
+ meta: {
2940
+ title: "Создание отдела"
2941
+ },
2942
+ component: () => Promise.resolve().then(() => Se)
2943
+ }, {
2944
+ path: ":_id/departments/:deparment",
2945
+ name: "Department",
2946
+ meta: {
2947
+ title: "Отдел"
2948
+ },
2949
+ component: () => Promise.resolve().then(() => la)
2950
+ }, {
2951
+ path: ":_id/departments/:department/edit",
2952
+ name: "Department Edit",
2953
+ meta: {
2954
+ title: "Редактирование отдела"
2955
+ },
2956
+ component: () => Promise.resolve().then(() => Se)
2957
+ }, {
2958
+ path: ":_id/products/:product",
2959
+ name: "Product Organization",
2960
+ meta: {
2961
+ title: {
2962
+ en: "Product",
2963
+ ru: "Продукт"
2964
+ }
2965
+ },
2966
+ component: () => import(
2967
+ /* webpackChunkName: 'Product' */
2968
+ "./Product-2d05acc8.mjs"
2969
+ )
2970
+ }, {
2971
+ path: ":_id/products/:product/edit",
2972
+ name: "ProductEdit",
2973
+ component: () => import(
2974
+ /* webpackChunkName: 'ProductPageEdit' */
2975
+ "./ProductEdit-aca44ef7.mjs"
2976
+ )
2977
+ }, {
2978
+ path: ":_id/products/add",
2979
+ name: "AddProduct",
2980
+ component: () => import(
2981
+ /* webpackChunkName: 'ProductPageEdit' */
2982
+ "./ProductEdit-aca44ef7.mjs"
2983
+ )
2984
+ }]
2985
+ }];
2986
+ export {
2987
+ Vi as A,
2988
+ Do as D,
2989
+ Mi as P,
2990
+ Ae as U,
2991
+ lt as _,
2992
+ wi as a,
2993
+ yi as b,
2994
+ E as c,
2995
+ Zs as d,
2996
+ ia as e,
2997
+ xi as f,
2998
+ Da as g,
2999
+ Oi as h,
3000
+ Li as i,
3001
+ zi as j,
3002
+ De as k,
3003
+ Si as l,
3004
+ Pi as m,
3005
+ fe as n,
3006
+ bi as o,
3007
+ vi as p,
3008
+ xs as q,
3009
+ $i as r,
3010
+ y as s,
3011
+ At as t,
3012
+ ki as u,
3013
+ Di as v,
3014
+ Ts as w,
3015
+ _s as x,
3016
+ Ai as y,
3017
+ Ci as z
3018
+ };