@wisemen/wise-crm-web 2.0.0-alpha.7 → 2.0.0-alpha.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,17 +1,17 @@
1
- import { defineComponent as D, ref as T, useTemplateRef as De, openBlock as m, createElementBlock as M, createBlock as g, unref as e, withCtx as s, createVNode as l, mergeProps as q, createElementVNode as k, toDisplayString as j, nextTick as Ie, computed as P, createCommentVNode as N, Fragment as Z, createTextVNode as ee, renderList as xe, useModel as Ne, mergeModels as Se } from "vue";
2
- import { useRouteParams as ke } from "@vueuse/router";
1
+ import { defineComponent as I, ref as M, useTemplateRef as Ie, openBlock as d, createElementBlock as V, createBlock as g, unref as e, withCtx as r, createVNode as l, mergeProps as E, createElementVNode as k, toDisplayString as j, nextTick as xe, computed as w, createCommentVNode as N, Fragment as W, createTextVNode as ne, renderList as Ne, useModel as Se, mergeModels as ke } from "vue";
2
+ import { useRouteParams as Fe } from "@vueuse/router";
3
3
  import { useI18n as x } from "vue-i18n";
4
- import { aX as ie, b1 as Fe, b3 as $e, b6 as Te } from "./uuid.util-CaePLXHv.js";
5
- import { _ as Me } from "./CrmDetailView.vue_vue_type_script_setup_true_lang-C_-6l66y.js";
6
- import { d as F, e as L, f as Ve, E as re, g as se, h as Le, i as qe, L as Ee, j as Oe, k as K, a as Be, P as Qe, l as Ae, m as ae, n as Ke, I as je, o as ue, p as ze, q as O, r as ce, s as Re, t as Ge, U as He, v as Ye, u as Ze, w as Xe, x as Je, y as We, z as ea, B as aa, F as te, G as de, H as ta, J as ne, K as na, N as la, O as oa, Q as ia, R as ra, S as me, T as sa, V as ua, W as ca, X as da, Y as ma, Z as pa, $ as fa, a0 as _a, a1 as ga, a2 as ya, a3 as ba, A as ha } from "./index-CtsgrPp8.js";
7
- import { UITextField as z, toFormField as E, UIIconButton as pe, UIDropdownMenu as va, UIDropdownMenuGroup as Ua, UIDropdownMenuItem as le, UIPhoneNumberField as oe, UIFormLayout as X, UIFormFieldGroup as B, UIFormFieldGrid as Q, UIFormDialog as fe, UIDialogHeader as _e, UIDialogBody as ge, UIDialogFooter as ye, UIDialogFooterSubmit as be, createAutocompleteOptions as Ca, createSelectOptions as H, UIAutocomplete as Pa, UISelect as Y, useOverlay as J, UIButton as wa, UIBadge as he } from "@wisemen/vue-core-design-system";
4
+ import { aX as ce, b1 as $e, b3 as Te, b6 as Me } from "./uuid.util-CaePLXHv.js";
5
+ import { _ as Ve } from "./CrmDetailView.vue_vue_type_script_setup_true_lang-B6SoADEB.js";
6
+ import { d as F, e as q, f as Le, E as de, g as me, h as qe, i as Ee, L as Oe, j as Be, k as K, a as Qe, P as Ae, l as Ke, m as le, n as je, I as ze, o as pe, p as B, q as Re, r as fe, s as Ge, t as He, U as Ye, v as Ze, u as Xe, w as Je, x as We, y as ea, z as aa, B as ta, F as oe, G as _e, H as na, J as ie, K as la, N as oa, O as ia, Q as ra, R as sa, S as ge, T as ua, V as ca, W as da, X as ma, Y as pa, Z as fa, $ as _a, a0 as ga, a1 as ba, a2 as ya, a3 as ha, A as va } from "./index-CBZyudVC.js";
7
+ import { UITextField as z, toFormField as O, UIIconButton as be, UIDropdownMenu as Ua, UIDropdownMenuGroup as Ca, UIDropdownMenuItem as re, UIPhoneNumberField as se, UIFormLayout as ee, UIFormFieldGroup as Q, UIFormFieldGrid as A, useToast as wa, UIFormDialog as ye, UIDialogHeader as he, UIForm as ue, UIDialogBody as H, UIDialogFooter as Y, UIDialogFooterSubmit as Z, createAutocompleteOptions as Pa, createSelectOptions as X, UIAutocomplete as Da, UISelect as J, useOverlay as ae, UIButton as Ia, UIBadge as ve } from "@wisemen/vue-core-design-system";
8
8
  import { useForm as R } from "formango";
9
9
  import G, { z as S } from "zod";
10
- import { useMutation as $, useQuery as ve, useOffsetInfiniteQuery as Da, useKeysetInfiniteQuery as Ia } from "@wisemen/vue-core-api-utils";
11
- import { Motion as xa } from "motion-v";
12
- import { useQueryClient as Na, useMutation as Sa } from "@tanstack/vue-query";
13
- function ka() {
14
- return $({
10
+ import { useMutation as T, useQuery as Ue, useOffsetInfiniteQuery as xa, useKeysetInfiniteQuery as Na } from "@wisemen/vue-core-api-utils";
11
+ import { Motion as Sa } from "motion-v";
12
+ import { useQueryClient as ka, useMutation as Fa } from "@tanstack/vue-query";
13
+ function $a() {
14
+ return T({
15
15
  queryFn: async ({
16
16
  body: t,
17
17
  params: a
@@ -26,8 +26,8 @@ function ka() {
26
26
  }
27
27
  });
28
28
  }
29
- function Fa() {
30
- return $({
29
+ function Ta() {
30
+ return T({
31
31
  queryFn: async ({
32
32
  body: t,
33
33
  params: a
@@ -42,8 +42,8 @@ function Fa() {
42
42
  }
43
43
  });
44
44
  }
45
- function $a() {
46
- return $({
45
+ function Ma() {
46
+ return T({
47
47
  queryFn: async ({
48
48
  body: t,
49
49
  params: a
@@ -58,8 +58,8 @@ function $a() {
58
58
  }
59
59
  });
60
60
  }
61
- function Ta() {
62
- return $({
61
+ function Va() {
62
+ return T({
63
63
  queryFn: async ({
64
64
  body: t,
65
65
  params: a
@@ -74,16 +74,16 @@ function Ta() {
74
74
  }
75
75
  });
76
76
  }
77
- const Ma = {
77
+ const La = {
78
78
  key: 1,
79
79
  class: "flex justify-between"
80
- }, Va = { class: "text-xl font-bold text-primary" }, La = /* @__PURE__ */ D({
80
+ }, qa = { class: "text-xl font-bold text-primary" }, Ea = /* @__PURE__ */ I({
81
81
  __name: "DealDetailSidebarNameField",
82
82
  props: {
83
83
  deal: {}
84
84
  },
85
85
  setup(t) {
86
- const a = t, n = x(), i = L(), o = T(!1), u = De("nameFieldContainerRef"), p = Ta(), f = R({
86
+ const a = t, n = x(), i = q(), o = M(!1), s = Ie("nameFieldContainerRef"), p = Va(), f = R({
87
87
  schema: G.object({
88
88
  name: G.string().min(1)
89
89
  }),
@@ -97,70 +97,70 @@ const Ma = {
97
97
  dealUuid: a.deal.uuid
98
98
  }
99
99
  });
100
- } catch (y) {
101
- i.show(y);
100
+ } catch (b) {
101
+ i.show(b);
102
102
  } finally {
103
103
  o.value = !1;
104
104
  }
105
105
  }
106
- }), d = f.register("name", a.deal.name);
107
- async function c() {
108
- o.value = !0, await Ie(), h();
106
+ }), m = f.register("name", a.deal.name);
107
+ async function u() {
108
+ o.value = !0, await xe(), y();
109
109
  }
110
- function h() {
111
- u.value?.querySelector(
110
+ function y() {
111
+ s.value?.querySelector(
112
112
  "input"
113
113
  )?.focus();
114
114
  }
115
- function v() {
115
+ function h() {
116
116
  if (!f.isDirty.value) {
117
117
  o.value = !1;
118
118
  return;
119
119
  }
120
120
  f.submit();
121
121
  }
122
- return (_, y) => (m(), M("div", {
122
+ return (_, b) => (d(), V("div", {
123
123
  ref_key: "nameFieldContainerRef",
124
- ref: u
124
+ ref: s
125
125
  }, [
126
- o.value ? (m(), g(Ve, {
126
+ o.value ? (d(), g(Le, {
127
127
  key: 0,
128
128
  form: e(f)
129
129
  }, {
130
- default: s(() => [
131
- l(e(z), q(e(E)(e(d)), {
130
+ default: r(() => [
131
+ l(e(z), E(e(O)(e(m)), {
132
132
  "is-loading": e(f).isSubmitting.value,
133
133
  label: e(n).t("wise_crm.deal.detail.sidebar.name_field.label"),
134
134
  class: "[&_input]:text-xl [&_input]:font-bold",
135
- onBlur: v
135
+ onBlur: h
136
136
  }), null, 16, ["is-loading", "label"]),
137
- y[0] || (y[0] = k("button", {
137
+ b[0] || (b[0] = k("button", {
138
138
  type: "submit",
139
139
  class: "sr-only"
140
140
  }, null, -1))
141
141
  ]),
142
142
  _: 1
143
- }, 8, ["form"])) : (m(), M("div", Ma, [
144
- k("h2", Va, j(a.deal.name), 1),
145
- l(e(pe), {
143
+ }, 8, ["form"])) : (d(), V("div", La, [
144
+ k("h2", qa, j(a.deal.name), 1),
145
+ l(e(be), {
146
146
  label: e(n).t("wise_crm.deal.detail.sidebar.name_field.edit_label"),
147
- icon: e(re),
147
+ icon: e(de),
148
148
  variant: "tertiary",
149
149
  class: "shrink-0",
150
- onClick: c
150
+ onClick: u
151
151
  }, null, 8, ["label", "icon"])
152
152
  ]))
153
153
  ], 512));
154
154
  }
155
155
  });
156
- function qa() {
157
- const t = Na(), a = "dealDetail", n = Sa({
156
+ function Oa() {
157
+ const t = ka(), a = "dealDetail", n = Fa({
158
158
  mutationFn: async (i) => {
159
159
  const o = await F.setPrimaryContactPerson(i.dealUuid, i.contactPersonUuid);
160
160
  if (o.isErr())
161
161
  throw o.error;
162
162
  },
163
- onError: (i, o, u) => {
163
+ onError: (i, o, s) => {
164
164
  t.setQueryData(
165
165
  [
166
166
  a,
@@ -168,7 +168,7 @@ function qa() {
168
168
  dealUuid: o.dealUuid
169
169
  }
170
170
  ],
171
- u?.previousData
171
+ s?.previousData
172
172
  );
173
173
  },
174
174
  onMutate: async (i) => {
@@ -195,9 +195,9 @@ function qa() {
195
195
  dealUuid: i.dealUuid
196
196
  }
197
197
  ],
198
- o.map((u) => ({
199
- ...u,
200
- contactPersons: u.contactPersons.map((p) => ({
198
+ o.map((s) => ({
199
+ ...s,
200
+ contactPersons: s.contactPersons.map((p) => ({
201
201
  ...p,
202
202
  isPrimary: p.uuid === i.contactPersonUuid
203
203
  }))
@@ -206,25 +206,25 @@ function qa() {
206
206
  previousData: o
207
207
  });
208
208
  },
209
- onSettled: (i, o, u) => {
210
- u !== void 0 && t.invalidateQueries({
209
+ onSettled: (i, o, s) => {
210
+ s !== void 0 && t.invalidateQueries({
211
211
  queryKey: [
212
212
  a,
213
213
  {
214
- dealUuid: u.dealUuid
214
+ dealUuid: s.dealUuid
215
215
  }
216
216
  ]
217
217
  });
218
218
  }
219
219
  });
220
220
  return {
221
- isLoading: P(() => n.isPending.value),
222
- data: P(() => n.data.value),
221
+ isLoading: w(() => n.isPending.value),
222
+ data: w(() => n.data.value),
223
223
  execute: async (i) => await n.mutateAsync(i.params)
224
224
  };
225
225
  }
226
- function Ea() {
227
- return $({
226
+ function Ba() {
227
+ return T({
228
228
  queryFn: async ({
229
229
  body: t,
230
230
  params: a
@@ -237,10 +237,10 @@ function Ea() {
237
237
  }
238
238
  });
239
239
  }
240
- const Oa = { class: "flex items-start justify-between" }, Ba = { class: "flex flex-col items-start" }, Qa = {
240
+ const Qa = { class: "flex items-start justify-between" }, Aa = { class: "flex flex-col items-start" }, Ka = {
241
241
  key: 1,
242
242
  class: "mt-sm text-brand-700"
243
- }, Aa = { class: "-mt-2 -mr-2 flex items-center justify-end" }, Ka = { class: "grid gap-lg" }, ja = /* @__PURE__ */ D({
243
+ }, ja = { class: "-mt-2 -mr-2 flex items-center justify-end" }, za = { class: "grid gap-lg" }, Ra = /* @__PURE__ */ I({
244
244
  __name: "CrmDetailSidebarAccordionGenericContactPersonInfo",
245
245
  props: {
246
246
  contactPerson: {},
@@ -249,67 +249,67 @@ const Oa = { class: "flex items-start justify-between" }, Ba = { class: "flex fl
249
249
  },
250
250
  emits: ["delete", "update"],
251
251
  setup(t, { emit: a }) {
252
- const n = t, i = a, o = x(), u = n.contactPerson.uuid ?? n.contactPerson.contactPersonUuid, p = {
252
+ const n = t, i = a, o = x(), s = n.contactPerson.uuid ?? n.contactPerson.contactPersonUuid, p = {
253
253
  left: {
254
- icon: re,
254
+ icon: de,
255
255
  type: "icon"
256
256
  }
257
257
  }, f = {
258
258
  left: {
259
- icon: Ee,
259
+ icon: Oe,
260
260
  type: "icon"
261
261
  }
262
262
  };
263
- function d() {
263
+ function m() {
264
264
  i("update");
265
265
  }
266
- function c() {
266
+ function u() {
267
267
  i("delete");
268
268
  }
269
- function h() {
269
+ function y() {
270
270
  n.onToggleIsPrimary();
271
271
  }
272
- return (v, _) => (m(), g(se, { class: "flex flex-col gap-lg" }, {
273
- default: s(() => [
274
- k("div", Oa, [
275
- k("div", Ba, [
276
- e(u) ? (m(), g(Le, {
272
+ return (h, _) => (d(), g(me, { class: "flex flex-col gap-lg" }, {
273
+ default: r(() => [
274
+ k("div", Qa, [
275
+ k("div", Aa, [
276
+ e(s) ? (d(), g(qe, {
277
277
  key: 0,
278
278
  label: `${n.contactPerson.firstName} ${n.contactPerson.lastName}`,
279
- "entity-type": e(ie).INDIVIDUAL,
280
- uuid: e(u),
279
+ "entity-type": e(ce).INDIVIDUAL,
280
+ uuid: e(s),
281
281
  class: "-m-xs"
282
282
  }, null, 8, ["label", "entity-type", "uuid"])) : N("", !0),
283
- n.description ? (m(), M("p", Qa, j(n.description), 1)) : N("", !0)
283
+ n.description ? (d(), V("p", Ka, j(n.description), 1)) : N("", !0)
284
284
  ]),
285
- k("div", Aa, [
286
- l(qe, {
285
+ k("div", ja, [
286
+ l(Ee, {
287
287
  "is-active": n.contactPerson.isPrimary,
288
- onClick: h
288
+ onClick: y
289
289
  }, null, 8, ["is-active"]),
290
- l(e(va), { "popover-align": "end" }, {
291
- trigger: s(() => [
292
- l(e(pe), {
293
- icon: e(Oe),
290
+ l(e(Ua), { "popover-align": "end" }, {
291
+ trigger: r(() => [
292
+ l(e(be), {
293
+ icon: e(Be),
294
294
  variant: "tertiary",
295
295
  size: "sm",
296
296
  label: "actionMenu"
297
297
  }, null, 8, ["icon"])
298
298
  ]),
299
- content: s(() => [
300
- l(e(Ua), null, {
301
- default: s(() => [
302
- l(e(le), {
299
+ content: r(() => [
300
+ l(e(Ca), null, {
301
+ default: r(() => [
302
+ l(e(re), {
303
303
  config: p,
304
304
  label: e(o).t("wise_crm.info_dialog.sidebar.overview.update_contact_person"),
305
- onSelect: d
305
+ onSelect: m
306
306
  }, null, 8, ["label"]),
307
- l(e(le), {
307
+ l(e(re), {
308
308
  "is-destructive": !0,
309
309
  "is-disabled": n.contactPerson.isPrimary,
310
310
  config: f,
311
311
  label: e(o).t("wise_crm.info_dialog.sidebar.overview.delete_contact_person"),
312
- onSelect: c
312
+ onSelect: u
313
313
  }, null, 8, ["is-disabled", "label"])
314
314
  ]),
315
315
  _: 1
@@ -319,21 +319,21 @@ const Oa = { class: "flex items-start justify-between" }, Ba = { class: "flex fl
319
319
  })
320
320
  ])
321
321
  ]),
322
- k("div", Ka, [
323
- n.contactPerson.email !== null ? (m(), g(K, {
322
+ k("div", za, [
323
+ n.contactPerson.email !== null ? (d(), g(K, {
324
324
  key: 0,
325
325
  label: n.contactPerson.email,
326
- icon: e(Be)
326
+ icon: e(Qe)
327
327
  }, null, 8, ["label", "icon"])) : N("", !0),
328
- n.contactPerson.mobilePhone !== null ? (m(), g(K, {
328
+ n.contactPerson.mobilePhone !== null ? (d(), g(K, {
329
329
  key: 1,
330
330
  label: n.contactPerson.mobilePhone,
331
- icon: e(Qe)
331
+ icon: e(Ae)
332
332
  }, null, 8, ["label", "icon"])) : N("", !0),
333
- n.contactPerson.phone !== null ? (m(), g(K, {
333
+ n.contactPerson.phone !== null ? (d(), g(K, {
334
334
  key: 2,
335
335
  label: n.contactPerson.phone,
336
- icon: e(Ae)
336
+ icon: e(Ke)
337
337
  }, null, 8, ["label", "icon"])) : N("", !0)
338
338
  ])
339
339
  ]),
@@ -341,8 +341,8 @@ const Oa = { class: "flex items-start justify-between" }, Ba = { class: "flex fl
341
341
  }));
342
342
  }
343
343
  });
344
- function za() {
345
- return $({
344
+ function Ga() {
345
+ return T({
346
346
  queryFn: async ({
347
347
  body: t,
348
348
  params: a
@@ -359,7 +359,7 @@ function za() {
359
359
  }
360
360
  });
361
361
  }
362
- const W = /* @__PURE__ */ D({
362
+ const te = /* @__PURE__ */ I({
363
363
  __name: "ContactPersonFormContactField",
364
364
  props: {
365
365
  email: {},
@@ -368,79 +368,79 @@ const W = /* @__PURE__ */ D({
368
368
  },
369
369
  setup(t) {
370
370
  const a = t, n = x();
371
- return (i, o) => (m(), M(Z, null, [
372
- l(e(z), q(e(E)(a.email), {
371
+ return (i, o) => (d(), V(W, null, [
372
+ l(e(z), E(e(O)(a.email), {
373
373
  label: e(n).t("wise_crm.contact.create_dialog.form.fields.email"),
374
374
  placeholder: e(n).t("wise_crm.contact.create_dialog.form.fields.email"),
375
375
  class: "col-span-2"
376
376
  }), null, 16, ["label", "placeholder"]),
377
- l(ae, { class: "col-span-2" }, {
378
- default: s(() => [
379
- ee(j(e(n).t("wise_crm.contact.create_dialog.form.seperator_label")), 1)
377
+ l(le, { class: "col-span-2" }, {
378
+ default: r(() => [
379
+ ne(j(e(n).t("wise_crm.contact.create_dialog.form.seperator_label")), 1)
380
380
  ]),
381
381
  _: 1
382
382
  }),
383
- l(e(oe), q(e(E)(a.mobilePhone), {
383
+ l(e(se), E(e(O)(a.mobilePhone), {
384
384
  label: e(n).t("wise_crm.contact.create_dialog.form.fields.mobile_phone"),
385
385
  placeholder: e(n).t("wise_crm.contact.create_dialog.form.fields.mobile_phone"),
386
386
  class: "col-span-2"
387
387
  }), null, 16, ["label", "placeholder"]),
388
- l(ae, { class: "col-span-2" }, {
389
- default: s(() => [
390
- ee(j(e(n).t("wise_crm.contact.create_dialog.form.seperator_label")), 1)
388
+ l(le, { class: "col-span-2" }, {
389
+ default: r(() => [
390
+ ne(j(e(n).t("wise_crm.contact.create_dialog.form.seperator_label")), 1)
391
391
  ]),
392
392
  _: 1
393
393
  }),
394
- l(e(oe), q(e(E)(a.phone), {
394
+ l(e(se), E(e(O)(a.phone), {
395
395
  label: e(n).t("wise_crm.contact.create_dialog.form.fields.phone"),
396
396
  placeholder: e(n).t("wise_crm.contact.create_dialog.form.fields.phone"),
397
397
  class: "col-span-2"
398
398
  }), null, 16, ["label", "placeholder"])
399
399
  ], 64));
400
400
  }
401
- }), Ra = /* @__PURE__ */ D({
401
+ }), Ha = /* @__PURE__ */ I({
402
402
  __name: "DealContactPersonCreateExistingForm",
403
403
  props: {
404
404
  form: {}
405
405
  },
406
406
  emits: ["createNewContactPerson"],
407
407
  setup(t, { emit: a }) {
408
- const n = t, i = a, o = x(), u = n.form.register("email"), p = n.form.register("phone"), f = n.form.register("mobile"), d = n.form.register("existingContactPerson"), c = T(null);
409
- async function h(v) {
410
- if (c.value = v, d.setValue(v?.uuid ?? null), v === null)
408
+ const n = t, i = a, o = x(), s = n.form.register("email"), p = n.form.register("phone"), f = n.form.register("mobile"), m = n.form.register("existingContactPerson"), u = M(null);
409
+ async function y(h) {
410
+ if (u.value = h, m.setValue(h?.uuid ?? null), h === null)
411
411
  return;
412
- const _ = await je.getByUuid(v.uuid);
412
+ const _ = await ze.getByUuid(h.uuid);
413
413
  if (_.isErr())
414
414
  return;
415
- const y = _.value;
416
- u.setValue(y.email), p.setValue(y.phone), f.setValue(y.mobilePhone);
415
+ const b = _.value;
416
+ s.setValue(b.email), p.setValue(b.phone), f.setValue(b.mobilePhone);
417
417
  }
418
- return (v, _) => (m(), g(e(X), null, {
419
- default: s(() => [
420
- l(e(B), null, {
421
- default: s(() => [
422
- l(Ke, {
423
- modelValue: c.value,
418
+ return (h, _) => (d(), g(e(ee), null, {
419
+ default: r(() => [
420
+ l(e(Q), null, {
421
+ default: r(() => [
422
+ l(je, {
423
+ modelValue: u.value,
424
424
  "onUpdate:modelValue": [
425
- _[0] || (_[0] = (y) => c.value = y),
426
- h
425
+ _[0] || (_[0] = (b) => u.value = b),
426
+ y
427
427
  ],
428
428
  label: e(o).t("wise_crm.contact.create_dialog.form.fields.contact_person"),
429
- onCreateNew: _[1] || (_[1] = (y) => i("createNewContactPerson"))
429
+ onCreateNew: _[1] || (_[1] = (b) => i("createNewContactPerson"))
430
430
  }, null, 8, ["modelValue", "label"])
431
431
  ]),
432
432
  _: 1
433
433
  }),
434
- l(e(B), null, {
435
- default: s(() => [
436
- l(e(Q), {
434
+ l(e(Q), null, {
435
+ default: r(() => [
436
+ l(e(A), {
437
437
  sm: 1,
438
438
  lg: 1,
439
439
  variant: "card"
440
440
  }, {
441
- default: s(() => [
442
- l(W, {
443
- email: e(u),
441
+ default: r(() => [
442
+ l(te, {
443
+ email: e(s),
444
444
  "mobile-phone": e(f),
445
445
  phone: e(p)
446
446
  }, null, 8, ["email", "mobile-phone", "phone"])
@@ -454,7 +454,7 @@ const W = /* @__PURE__ */ D({
454
454
  _: 1
455
455
  }));
456
456
  }
457
- }), Ue = /* @__PURE__ */ D({
457
+ }), Ce = /* @__PURE__ */ I({
458
458
  __name: "ContactPersonFormNameField",
459
459
  props: {
460
460
  firstName: {},
@@ -462,34 +462,34 @@ const W = /* @__PURE__ */ D({
462
462
  },
463
463
  setup(t) {
464
464
  const a = t, n = x();
465
- return (i, o) => (m(), M(Z, null, [
466
- l(e(z), q(e(E)(a.firstName), {
465
+ return (i, o) => (d(), V(W, null, [
466
+ l(e(z), E(e(O)(a.firstName), {
467
467
  label: e(n).t("wise_crm.contact.create_dialog.form.fields.first_name"),
468
468
  placeholder: e(n).t("wise_crm.contact.create_dialog.form.fields.first_name")
469
469
  }), null, 16, ["label", "placeholder"]),
470
- l(e(z), q(e(E)(a.lastName), {
470
+ l(e(z), E(e(O)(a.lastName), {
471
471
  label: e(n).t("wise_crm.contact.create_dialog.form.fields.last_name"),
472
472
  placeholder: e(n).t("wise_crm.contact.create_dialog.form.fields.last_name")
473
473
  }), null, 16, ["label", "placeholder"])
474
474
  ], 64));
475
475
  }
476
- }), Ga = /* @__PURE__ */ D({
476
+ }), Ya = /* @__PURE__ */ I({
477
477
  __name: "DealContactPersonCreateNewForm",
478
478
  props: {
479
479
  form: {}
480
480
  },
481
481
  setup(t) {
482
- const a = t, n = a.form.register("firstName"), i = a.form.register("lastName"), o = a.form.register("email"), u = a.form.register("mobilePhone"), p = a.form.register("phone");
483
- return (f, d) => (m(), g(e(X), null, {
484
- default: s(() => [
485
- l(e(B), null, {
486
- default: s(() => [
487
- l(e(Q), {
482
+ const a = t, n = a.form.register("firstName"), i = a.form.register("lastName"), o = a.form.register("email"), s = a.form.register("mobilePhone"), p = a.form.register("phone");
483
+ return (f, m) => (d(), g(e(ee), null, {
484
+ default: r(() => [
485
+ l(e(Q), null, {
486
+ default: r(() => [
487
+ l(e(A), {
488
488
  sm: 1,
489
489
  lg: 2
490
490
  }, {
491
- default: s(() => [
492
- l(Ue, {
491
+ default: r(() => [
492
+ l(Ce, {
493
493
  "first-name": e(n),
494
494
  "last-name": e(i)
495
495
  }, null, 8, ["first-name", "last-name"])
@@ -499,23 +499,23 @@ const W = /* @__PURE__ */ D({
499
499
  ]),
500
500
  _: 1
501
501
  }),
502
- l(e(B), null, {
503
- default: s(() => [
504
- l(e(Q), {
502
+ l(e(Q), null, {
503
+ default: r(() => [
504
+ l(e(A), {
505
505
  sm: 1,
506
506
  lg: 1,
507
507
  variant: "card"
508
508
  }, {
509
- default: s(() => [
510
- l(W, {
509
+ default: r(() => [
510
+ l(te, {
511
511
  email: e(o),
512
- "mobile-phone": e(u),
512
+ "mobile-phone": e(s),
513
513
  phone: e(p)
514
514
  }, null, 8, ["email", "mobile-phone", "phone"])
515
515
  ]),
516
516
  _: 1
517
517
  }),
518
- l(ue, {
518
+ l(pe, {
519
519
  form: a.form
520
520
  }, null, 8, ["form"])
521
521
  ]),
@@ -525,23 +525,23 @@ const W = /* @__PURE__ */ D({
525
525
  _: 1
526
526
  }));
527
527
  }
528
- }), Ha = G.object({
528
+ }), Za = G.object({
529
529
  email: G.email().nullable(),
530
- existingContactPerson: ze,
531
- mobile: O.nullable(),
532
- phone: O.nullable()
533
- }), Ya = S.object({
530
+ existingContactPerson: Re.nullable(),
531
+ mobile: B.nullable(),
532
+ phone: B.nullable()
533
+ }), Xa = S.object({
534
534
  email: S.email().min(1).nullable(),
535
535
  firstName: S.string().min(1),
536
536
  lastName: S.string().min(1),
537
- mobilePhone: O.nullable(),
538
- phone: O.nullable()
537
+ mobilePhone: B.nullable(),
538
+ phone: B.nullable()
539
539
  }).superRefine((t, a) => {
540
540
  t.email !== null && t.email !== "" || t.mobilePhone !== null && t.mobilePhone !== "" || t.phone !== null && t.phone !== "" || a.addIssue({
541
541
  code: S.ZodIssueCode.custom,
542
- message: ce.global.t("wise_crm.form.errors.at_least_one")
542
+ message: fe.global.t("wise_crm.form.errors.at_least_one")
543
543
  });
544
- }), Za = /* @__PURE__ */ D({
544
+ }), Ja = /* @__PURE__ */ I({
545
545
  __name: "DealContactPersonCreateDialog",
546
546
  props: {
547
547
  dealUuid: {},
@@ -549,124 +549,159 @@ const W = /* @__PURE__ */ D({
549
549
  },
550
550
  emits: ["close", "createNewContactPerson"],
551
551
  setup(t, { emit: a }) {
552
- const n = t, i = a, o = x(), u = L(), p = za(), f = Re(), d = T(n.isCreatingNewContactPerson), c = R({
553
- schema: Ya,
554
- onSubmit: async (r) => {
552
+ const n = t, i = a, o = x(), s = q(), p = wa(), f = Ga(), m = Ge(), u = M(n.isCreatingNewContactPerson), y = R({
553
+ schema: Xa,
554
+ onSubmit: async (c) => {
555
555
  try {
556
- const U = await f.execute({
556
+ const P = await m.execute({
557
557
  body: {
558
- email: r.email,
559
- firstName: r.firstName,
560
- lastName: r.lastName,
561
- mobilePhone: r.mobilePhone,
562
- phone: r.phone
558
+ email: c.email,
559
+ firstName: c.firstName,
560
+ lastName: c.lastName,
561
+ mobilePhone: c.mobilePhone,
562
+ phone: c.phone
563
563
  }
564
564
  });
565
- if (U.isErr()) {
566
- u.show(U.error);
565
+ if (P.isErr()) {
566
+ s.show(P.error);
567
567
  return;
568
568
  }
569
- const I = U.value;
570
- n.isCreatingNewContactPerson || await p.execute({
569
+ const $ = P.value;
570
+ n.isCreatingNewContactPerson || await f.execute({
571
571
  body: {
572
- contactPersonUuid: I,
572
+ contactPersonUuid: $,
573
573
  contactInfo: {
574
- email: r.email,
575
- mobilePhone: r.mobilePhone,
576
- phone: r.phone
574
+ email: c.email,
575
+ mobilePhone: c.mobilePhone,
576
+ phone: c.phone
577
577
  }
578
578
  },
579
579
  params: {
580
580
  dealUuid: n.dealUuid
581
581
  }
582
- }), b({
583
- label: `${r.firstName} ${r.lastName}`,
584
- value: I
582
+ }), C({
583
+ label: `${c.firstName} ${c.lastName}`,
584
+ value: $
585
585
  });
586
- } catch (U) {
587
- u.show(U);
586
+ } catch (P) {
587
+ s.show(P);
588
588
  }
589
+ },
590
+ onSubmitError: () => {
591
+ p.unableToSave();
589
592
  }
590
593
  }), h = R({
591
- schema: Ha,
592
- onSubmit: async (r) => {
593
- await y(
594
- r.existingContactPerson,
594
+ schema: Za,
595
+ onSubmit: async (c) => {
596
+ await v(
597
+ c.existingContactPerson,
595
598
  {
596
- email: r.email,
597
- mobilePhone: r.mobile,
598
- phone: r.phone
599
+ email: c.email,
600
+ mobilePhone: c.mobile,
601
+ phone: c.phone
599
602
  }
600
603
  );
604
+ },
605
+ onSubmitError: () => {
606
+ p.unableToSave();
601
607
  }
602
- }), v = P(
603
- () => d.value ? c : h
608
+ }), _ = w(
609
+ () => u.value ? y : h
604
610
  );
605
- function _() {
606
- d.value = !0;
611
+ function b() {
612
+ u.value = !0;
607
613
  }
608
- async function y(r, U) {
609
- if (r !== null)
614
+ async function v(c, P) {
615
+ if (c !== null)
610
616
  try {
611
- await p.execute({
617
+ await f.execute({
612
618
  body: {
613
- contactPersonUuid: r,
614
- contactInfo: U
619
+ contactPersonUuid: c,
620
+ contactInfo: P
615
621
  },
616
622
  params: {
617
623
  dealUuid: n.dealUuid
618
624
  }
619
- }), b();
620
- } catch (I) {
621
- u.show(I);
625
+ }), C();
626
+ } catch ($) {
627
+ s.show($);
622
628
  }
623
629
  }
624
- function b(r) {
625
- if (r === void 0) {
630
+ function C(c) {
631
+ if (c === void 0) {
626
632
  i("close");
627
633
  return;
628
634
  }
629
- i("createNewContactPerson", r), i("close");
635
+ i("createNewContactPerson", c), i("close");
630
636
  }
631
- return (r, U) => (m(), g(e(fe), {
632
- form: v.value,
637
+ return (c, P) => (d(), g(e(ye), {
638
+ form: _.value,
633
639
  size: "md",
634
- onClose: b
640
+ "render-own-form-component": "",
641
+ onClose: C
635
642
  }, {
636
- default: s(() => [
637
- l(e(_e), {
643
+ default: r(() => [
644
+ l(e(he), {
638
645
  title: e(o).t("wise_crm.info_dialog.contact_person_create.title"),
639
646
  description: e(o).t("wise_crm.info_dialog.contact_person_create.description")
640
647
  }, null, 8, ["title", "description"]),
641
- l(e(ge), null, {
642
- default: s(() => [
643
- d.value ? (m(), g(Ga, {
644
- key: 0,
645
- form: e(c)
646
- }, null, 8, ["form"])) : (m(), g(Ra, {
647
- key: 1,
648
- form: e(h),
649
- onCreateNewContactPerson: _
650
- }, null, 8, ["form"]))
648
+ u.value ? (d(), g(e(ue), {
649
+ key: 0,
650
+ form: e(y),
651
+ "prompt-on-unsaved-changes": !1
652
+ }, {
653
+ default: r(() => [
654
+ l(e(H), null, {
655
+ default: r(() => [
656
+ l(Ya, { form: e(y) }, null, 8, ["form"])
657
+ ]),
658
+ _: 1
659
+ }),
660
+ l(e(Y), null, {
661
+ right: r(() => [
662
+ l(e(Z), {
663
+ "is-loading": e(y).isSubmitting.value,
664
+ label: e(o).t("wise_crm.shared.create")
665
+ }, null, 8, ["is-loading", "label"])
666
+ ]),
667
+ _: 1
668
+ })
651
669
  ]),
652
670
  _: 1
653
- }),
654
- l(e(ye), null, {
655
- right: s(() => [
656
- l(e(be), {
657
- "is-loading": v.value.isSubmitting.value,
658
- label: e(o).t("wise_crm.shared.create")
659
- }, null, 8, ["is-loading", "label"])
671
+ }, 8, ["form"])) : (d(), g(e(ue), {
672
+ key: 1,
673
+ form: e(h),
674
+ "prompt-on-unsaved-changes": !1
675
+ }, {
676
+ default: r(() => [
677
+ l(e(H), null, {
678
+ default: r(() => [
679
+ l(Ha, {
680
+ form: e(h),
681
+ onCreateNewContactPerson: b
682
+ }, null, 8, ["form"])
683
+ ]),
684
+ _: 1
685
+ }),
686
+ l(e(Y), null, {
687
+ right: r(() => [
688
+ l(e(Z), {
689
+ "is-loading": e(h).isSubmitting.value,
690
+ label: e(o).t("wise_crm.shared.create")
691
+ }, null, 8, ["is-loading", "label"])
692
+ ]),
693
+ _: 1
694
+ })
660
695
  ]),
661
696
  _: 1
662
- })
697
+ }, 8, ["form"]))
663
698
  ]),
664
699
  _: 1
665
700
  }, 8, ["form"]));
666
701
  }
667
702
  });
668
- function Xa() {
669
- return $({
703
+ function Wa() {
704
+ return T({
670
705
  queryFn: async ({
671
706
  body: t,
672
707
  params: a
@@ -683,8 +718,8 @@ function Xa() {
683
718
  }
684
719
  });
685
720
  }
686
- function Ja(t, a) {
687
- return ve("dealContactPersonDetail", {
721
+ function et(t, a) {
722
+ return Ue("dealContactPersonDetail", {
688
723
  params: {
689
724
  contactPersonUuid: a,
690
725
  dealUuid: t
@@ -692,18 +727,18 @@ function Ja(t, a) {
692
727
  queryFn: () => F.getContactPerson(t.value, a.value)
693
728
  });
694
729
  }
695
- const Wa = S.object({
730
+ const at = S.object({
696
731
  email: S.email().min(1).nullable(),
697
732
  firstName: S.string().min(1),
698
733
  lastName: S.string().min(1),
699
- mobilePhone: O.nullable(),
700
- phone: O.nullable()
734
+ mobilePhone: B.nullable(),
735
+ phone: B.nullable()
701
736
  }).superRefine((t, a) => {
702
737
  t.email !== null && t.email !== "" || t.mobilePhone !== null && t.mobilePhone !== "" || t.phone !== null && t.phone !== "" || a.addIssue({
703
738
  code: S.ZodIssueCode.custom,
704
- message: ce.global.t("wise_crm.form.errors.at_least_one")
739
+ message: fe.global.t("wise_crm.form.errors.at_least_one")
705
740
  });
706
- }), et = /* @__PURE__ */ D({
741
+ }), tt = /* @__PURE__ */ I({
707
742
  __name: "DealContactPersonUpdateDialog",
708
743
  props: {
709
744
  contactPersonUuid: {},
@@ -711,64 +746,64 @@ const Wa = S.object({
711
746
  },
712
747
  emits: ["close"],
713
748
  setup(t, { emit: a }) {
714
- const n = t, i = a, o = x(), u = L(), p = Xa(), f = Ja(
715
- P(() => n.dealUuid),
716
- P(() => n.contactPersonUuid)
717
- ), d = P(() => f.result.value.isOk() ? f.result.value.getValue() : null), c = R({
718
- initialState: P(() => d.value === null ? null : {
719
- email: d.value.email,
720
- firstName: d.value.firstName,
721
- lastName: d.value.lastName,
722
- mobilePhone: d.value.mobilePhone,
723
- phone: d.value.phone
749
+ const n = t, i = a, o = x(), s = q(), p = Wa(), f = et(
750
+ w(() => n.dealUuid),
751
+ w(() => n.contactPersonUuid)
752
+ ), m = w(() => f.result.value.isOk() ? f.result.value.getValue() : null), u = R({
753
+ initialState: w(() => m.value === null ? null : {
754
+ email: m.value.email,
755
+ firstName: m.value.firstName,
756
+ lastName: m.value.lastName,
757
+ mobilePhone: m.value.mobilePhone,
758
+ phone: m.value.phone
724
759
  }),
725
- schema: Wa,
726
- onSubmit: async (I) => {
727
- await r(I);
760
+ schema: at,
761
+ onSubmit: async (P) => {
762
+ await C(P);
728
763
  }
729
- }), h = c.register("firstName"), v = c.register("lastName"), _ = c.register("email"), y = c.register("mobilePhone"), b = c.register("phone");
730
- async function r(I) {
764
+ }), y = u.register("firstName"), h = u.register("lastName"), _ = u.register("email"), b = u.register("mobilePhone"), v = u.register("phone");
765
+ async function C(P) {
731
766
  try {
732
767
  await p.execute({
733
768
  body: {
734
- form: I
769
+ form: P
735
770
  },
736
771
  params: {
737
772
  contactPersonUuid: n.contactPersonUuid,
738
773
  dealUuid: n.dealUuid
739
774
  }
740
775
  }), i("close");
741
- } catch (A) {
742
- u.show(A);
776
+ } catch ($) {
777
+ s.show($);
743
778
  }
744
779
  }
745
- function U() {
780
+ function c() {
746
781
  i("close");
747
782
  }
748
- return (I, A) => (m(), g(e(fe), {
749
- form: e(c),
783
+ return (P, $) => (d(), g(e(ye), {
784
+ form: e(u),
750
785
  size: "md",
751
- onClose: U
786
+ onClose: c
752
787
  }, {
753
- default: s(() => [
754
- l(e(_e), {
788
+ default: r(() => [
789
+ l(e(he), {
755
790
  title: e(o).t("wise_crm.info_dialog.contact_person_update.title"),
756
791
  description: e(o).t("wise_crm.info_dialog.contact_person_create.description")
757
792
  }, null, 8, ["title", "description"]),
758
- d.value !== null ? (m(), g(e(ge), { key: 0 }, {
759
- default: s(() => [
760
- l(e(X), null, {
761
- default: s(() => [
762
- l(e(B), null, {
763
- default: s(() => [
764
- l(e(Q), {
793
+ m.value !== null ? (d(), g(e(H), { key: 0 }, {
794
+ default: r(() => [
795
+ l(e(ee), null, {
796
+ default: r(() => [
797
+ l(e(Q), null, {
798
+ default: r(() => [
799
+ l(e(A), {
765
800
  sm: 1,
766
801
  lg: 2
767
802
  }, {
768
- default: s(() => [
769
- l(Ue, {
770
- "first-name": e(h),
771
- "last-name": e(v)
803
+ default: r(() => [
804
+ l(Ce, {
805
+ "first-name": e(y),
806
+ "last-name": e(h)
772
807
  }, null, 8, ["first-name", "last-name"])
773
808
  ]),
774
809
  _: 1
@@ -776,25 +811,25 @@ const Wa = S.object({
776
811
  ]),
777
812
  _: 1
778
813
  }),
779
- l(Ge, {
814
+ l(He, {
780
815
  title: e(o).t("wise_crm.shared.contact_info")
781
816
  }, {
782
- default: s(() => [
783
- l(e(Q), {
817
+ default: r(() => [
818
+ l(e(A), {
784
819
  sm: 1,
785
820
  lg: 1,
786
821
  variant: "card"
787
822
  }, {
788
- default: s(() => [
789
- l(W, {
823
+ default: r(() => [
824
+ l(te, {
790
825
  email: e(_),
791
- "mobile-phone": e(y),
792
- phone: e(b)
826
+ "mobile-phone": e(b),
827
+ phone: e(v)
793
828
  }, null, 8, ["email", "mobile-phone", "phone"])
794
829
  ]),
795
830
  _: 1
796
831
  }),
797
- l(ue, { form: e(c) }, null, 8, ["form"])
832
+ l(pe, { form: e(u) }, null, 8, ["form"])
798
833
  ]),
799
834
  _: 1
800
835
  }, 8, ["title"])
@@ -804,10 +839,10 @@ const Wa = S.object({
804
839
  ]),
805
840
  _: 1
806
841
  })) : N("", !0),
807
- l(e(ye), null, {
808
- right: s(() => [
809
- l(e(be), {
810
- "is-loading": e(c).isSubmitting.value,
842
+ l(e(Y), null, {
843
+ right: r(() => [
844
+ l(e(Z), {
845
+ "is-loading": e(u).isSubmitting.value,
811
846
  label: e(o).t("wise_crm.shared.save_changes")
812
847
  }, null, 8, ["is-loading", "label"])
813
848
  ]),
@@ -818,137 +853,137 @@ const Wa = S.object({
818
853
  }, 8, ["form"]));
819
854
  }
820
855
  });
821
- function at(t) {
822
- return Da("userIndex", {
856
+ function nt(t) {
857
+ return xa("userIndex", {
823
858
  params: t,
824
- queryFn: (a) => He.getAll({
859
+ queryFn: (a) => Ye.getAll({
825
860
  pagination: a,
826
861
  search: t.params.search?.value
827
862
  })
828
863
  });
829
864
  }
830
- const tt = { class: "p-lg" }, nt = /* @__PURE__ */ D({
865
+ const lt = { class: "p-lg" }, ot = /* @__PURE__ */ I({
831
866
  __name: "DealDetailSidebarGeneralInfo",
832
867
  props: {
833
868
  deal: {}
834
869
  },
835
870
  setup(t) {
836
- const a = t, n = x(), i = L(), o = ka(), u = Fa(), p = $a(), f = Ye({
871
+ const a = t, n = x(), i = q(), o = $a(), s = Ta(), p = Ma(), f = Ze({
837
872
  persistInUrl: !1
838
- }), d = at({
873
+ }), m = nt({
839
874
  params: {
840
875
  search: f.debouncedSearch
841
876
  }
842
- }), c = T(a.deal.dealLanguage), h = T(a.deal.dealSource), v = T(
877
+ }), u = M(a.deal.dealLanguage), y = M(a.deal.dealSource), h = M(
843
878
  a.deal.owner ? {
844
879
  uuid: a.deal.owner.uuid,
845
880
  name: a.deal.owner.name
846
881
  } : null
847
- ), _ = P(() => {
848
- const C = (d.result.value.isOk() ? d.result.value.getValue().data : []).map((w) => ({
849
- uuid: w.uuid,
850
- name: `${w.firstName} ${w.lastName}`
882
+ ), _ = w(() => {
883
+ const U = (m.result.value.isOk() ? m.result.value.getValue().data : []).map((D) => ({
884
+ uuid: D.uuid,
885
+ name: `${D.firstName} ${D.lastName}`
851
886
  }));
852
- return Ca(C);
887
+ return Pa(U);
853
888
  });
854
- function y(C) {
855
- return n.t(We.getI18nKey(C));
889
+ function b(U) {
890
+ return n.t(ea.getI18nKey(U));
856
891
  }
857
- function b(C) {
858
- return n.t(ea.getI18nKey(C));
892
+ function v(U) {
893
+ return n.t(aa.getI18nKey(U));
859
894
  }
860
- const r = H(Object.values(Fe)), U = H(Object.values($e)), I = Ze();
861
- function A(C) {
862
- f.updateSearch(C);
895
+ const C = X(Object.values($e)), c = X(Object.values(Te)), P = Xe();
896
+ function $(U) {
897
+ f.updateSearch(U);
863
898
  }
864
- async function Ce(C) {
865
- if (c.value = C, C !== null)
899
+ async function we(U) {
900
+ if (u.value = U, U !== null)
866
901
  try {
867
902
  await o.execute({
868
903
  body: {
869
- dealLanguage: C
904
+ dealLanguage: U
870
905
  },
871
906
  params: {
872
907
  dealUuid: a.deal.uuid
873
908
  }
874
909
  });
875
- } catch (w) {
876
- i.show(w);
910
+ } catch (D) {
911
+ i.show(D);
877
912
  }
878
913
  }
879
- async function Pe(C) {
880
- if (h.value = C, C !== null)
914
+ async function Pe(U) {
915
+ if (y.value = U, U !== null)
881
916
  try {
882
- await u.execute({
917
+ await s.execute({
883
918
  body: {
884
- dealSource: C
919
+ dealSource: U
885
920
  },
886
921
  params: {
887
922
  dealUuid: a.deal.uuid
888
923
  }
889
924
  });
890
- } catch (w) {
891
- i.show(w);
925
+ } catch (D) {
926
+ i.show(D);
892
927
  }
893
928
  }
894
- async function we(C) {
895
- if (v.value = C, C !== null)
929
+ async function De(U) {
930
+ if (h.value = U, U !== null)
896
931
  try {
897
932
  await p.execute({
898
933
  body: {
899
- dealOwner: C
934
+ dealOwner: U
900
935
  },
901
936
  params: {
902
937
  dealUuid: a.deal.uuid
903
938
  }
904
939
  });
905
- } catch (w) {
906
- i.show(w);
940
+ } catch (D) {
941
+ i.show(D);
907
942
  }
908
943
  }
909
- return (C, w) => (m(), M("div", null, [
910
- l(se, null, {
911
- default: s(() => [
944
+ return (U, D) => (d(), V("div", null, [
945
+ l(me, null, {
946
+ default: r(() => [
912
947
  k("form", null, [
913
- l(Xe, { cols: 1 }, {
914
- default: s(() => [
915
- l(e(Pa), {
916
- modelValue: v.value,
948
+ l(Je, { cols: 1 }, {
949
+ default: r(() => [
950
+ l(e(Da), {
951
+ modelValue: h.value,
917
952
  "onUpdate:modelValue": [
918
- w[0] || (w[0] = (V) => v.value = V),
919
- we
953
+ D[0] || (D[0] = (L) => h.value = L),
954
+ De
920
955
  ],
921
956
  items: _.value,
922
- "display-fn": (V) => V.name,
923
- "is-loading": e(d).isLoading.value || e(p).isLoading.value,
957
+ "display-fn": (L) => L.name,
958
+ "is-loading": e(m).isLoading.value || e(p).isLoading.value,
924
959
  "search-mode": "remote",
925
960
  placeholder: "Select deal owner",
926
961
  label: "Deal owner",
927
- "onUpdate:search": A
962
+ "onUpdate:search": $
928
963
  }, null, 8, ["modelValue", "items", "display-fn", "is-loading"]),
929
- l(e(Y), {
930
- modelValue: c.value,
964
+ l(e(J), {
965
+ modelValue: u.value,
931
966
  "onUpdate:modelValue": [
932
- w[1] || (w[1] = (V) => c.value = V),
933
- Ce
967
+ D[1] || (D[1] = (L) => u.value = L),
968
+ we
934
969
  ],
935
970
  label: e(n).t("wise_crm.deal.form.fields.language"),
936
971
  placeholder: e(n).t("wise_crm.deal.form.fields.language_placeholder"),
937
- "display-fn": y,
972
+ "display-fn": b,
938
973
  "is-loading": e(o).isLoading.value,
939
- items: e(r)
974
+ items: e(C)
940
975
  }, null, 8, ["modelValue", "label", "placeholder", "is-loading", "items"]),
941
- l(e(Y), {
942
- modelValue: h.value,
976
+ l(e(J), {
977
+ modelValue: y.value,
943
978
  "onUpdate:modelValue": [
944
- w[2] || (w[2] = (V) => h.value = V),
979
+ D[2] || (D[2] = (L) => y.value = L),
945
980
  Pe
946
981
  ],
947
- "display-fn": b,
982
+ "display-fn": v,
948
983
  label: e(n).t("wise_crm.deal.form.fields.source"),
949
984
  placeholder: e(n).t("wise_crm.deal.form.fields.source_placeholder"),
950
- "is-loading": e(u).isLoading.value,
951
- items: e(U)
985
+ "is-loading": e(s).isLoading.value,
986
+ items: e(c)
952
987
  }, null, 8, ["modelValue", "label", "placeholder", "is-loading", "items"])
953
988
  ]),
954
989
  _: 1
@@ -957,111 +992,111 @@ const tt = { class: "p-lg" }, nt = /* @__PURE__ */ D({
957
992
  ]),
958
993
  _: 1
959
994
  }),
960
- k("div", tt, [
995
+ k("div", lt, [
961
996
  l(K, {
962
997
  label: e(n).t("wise_crm.deal.sidebar.created_at", {
963
- date: e(I).toDate(a.deal.createdAt.toPlainDate())
998
+ date: e(P).toDate(a.deal.createdAt.toPlainDate())
964
999
  }),
965
- icon: e(Je),
1000
+ icon: e(We),
966
1001
  "text-color": "text-quaternary",
967
1002
  class: "text-sm"
968
1003
  }, null, 8, ["label", "icon"])
969
1004
  ])
970
1005
  ]));
971
1006
  }
972
- }), lt = /* @__PURE__ */ D({
1007
+ }), it = /* @__PURE__ */ I({
973
1008
  __name: "DealDetailSidebarOverviewContent",
974
1009
  props: {
975
1010
  deal: {}
976
1011
  },
977
1012
  setup(t) {
978
- const a = t, n = x(), i = L(), o = qa(), u = Ea(), p = J(), f = p.create(Za), d = p.create(et), c = P(() => a.deal.contactPersons.length > 0);
979
- function h() {
1013
+ const a = t, n = x(), i = q(), o = Oa(), s = Ba(), p = ae(), f = p.create(Ja), m = p.create(tt), u = w(() => a.deal.contactPersons.length > 0);
1014
+ function y() {
980
1015
  f.open({
981
1016
  dealUuid: a.deal.uuid
982
1017
  });
983
1018
  }
984
- function v(b) {
985
- d.open({
986
- contactPersonUuid: b,
1019
+ function h(v) {
1020
+ m.open({
1021
+ contactPersonUuid: v,
987
1022
  dealUuid: a.deal.uuid
988
1023
  });
989
1024
  }
990
- async function _(b) {
1025
+ async function _(v) {
991
1026
  try {
992
- await u.execute({
1027
+ await s.execute({
993
1028
  body: {
994
- contactPersonUuid: b
1029
+ contactPersonUuid: v
995
1030
  },
996
1031
  params: {
997
1032
  dealUuid: a.deal.uuid
998
1033
  }
999
1034
  });
1000
- } catch (r) {
1001
- i.show(r);
1035
+ } catch (C) {
1036
+ i.show(C);
1002
1037
  }
1003
1038
  }
1004
- function y(b) {
1039
+ function b(v) {
1005
1040
  o.execute({
1006
1041
  params: {
1007
- contactPersonUuid: b,
1042
+ contactPersonUuid: v,
1008
1043
  dealUuid: a.deal.uuid
1009
1044
  }
1010
1045
  });
1011
1046
  }
1012
- return (b, r) => (m(), g(aa, { "default-values": ["general-info", "contact-persons"] }, {
1013
- default: s(() => [
1014
- l(te, {
1047
+ return (v, C) => (d(), g(ta, { "default-values": ["general-info", "contact-persons"] }, {
1048
+ default: r(() => [
1049
+ l(oe, {
1015
1050
  label: e(n).t("wise_crm.deal.detail.sidebar.accordion.general_info"),
1016
- icon: e(de),
1051
+ icon: e(_e),
1017
1052
  value: "general-info"
1018
1053
  }, {
1019
- default: s(() => [
1020
- l(nt, {
1054
+ default: r(() => [
1055
+ l(ot, {
1021
1056
  deal: a.deal
1022
1057
  }, null, 8, ["deal"])
1023
1058
  ]),
1024
1059
  _: 1
1025
1060
  }, 8, ["label", "icon"]),
1026
- l(te, {
1027
- "is-empty": !c.value,
1061
+ l(oe, {
1062
+ "is-empty": !u.value,
1028
1063
  label: e(n).t("wise_crm.info_dialog.sidebar.overview.contact_persons_label"),
1029
- icon: e(ta),
1064
+ icon: e(na),
1030
1065
  value: "contact-persons",
1031
- onAdd: h
1066
+ onAdd: y
1032
1067
  }, {
1033
- actions: s(() => [
1034
- c.value ? N("", !0) : (m(), g(na, {
1068
+ actions: r(() => [
1069
+ u.value ? N("", !0) : (d(), g(la, {
1035
1070
  key: 0,
1036
1071
  label: e(n).t("wise_crm.info_dialog.sidebar.overview.contact_persons_label"),
1037
- icon: e(ne),
1072
+ icon: e(ie),
1038
1073
  class: "z-1",
1039
- onClick: h
1074
+ onClick: y
1040
1075
  }, null, 8, ["label", "icon"]))
1041
1076
  ]),
1042
- default: s(() => [
1043
- (m(!0), M(Z, null, xe(a.deal.contactPersons, (U) => (m(), g(e(xa), {
1044
- key: U.uuid,
1045
- "layout-id": U.uuid
1077
+ default: r(() => [
1078
+ (d(!0), V(W, null, Ne(a.deal.contactPersons, (c) => (d(), g(e(Sa), {
1079
+ key: c.uuid,
1080
+ "layout-id": c.uuid
1046
1081
  }, {
1047
- default: s(() => [
1048
- l(ja, {
1049
- "contact-person": U,
1050
- "on-toggle-is-primary": () => y(U.uuid),
1051
- description: U.phone,
1052
- onUpdate: (I) => v(U.uuid),
1053
- onDelete: (I) => _(U.uuid)
1082
+ default: r(() => [
1083
+ l(Ra, {
1084
+ "contact-person": c,
1085
+ "on-toggle-is-primary": () => b(c.uuid),
1086
+ description: c.phone,
1087
+ onUpdate: (P) => h(c.uuid),
1088
+ onDelete: (P) => _(c.uuid)
1054
1089
  }, null, 8, ["contact-person", "on-toggle-is-primary", "description", "onUpdate", "onDelete"])
1055
1090
  ]),
1056
1091
  _: 2
1057
1092
  }, 1032, ["layout-id"]))), 128)),
1058
- c.value ? (m(), g(e(wa), {
1093
+ u.value ? (d(), g(e(Ia), {
1059
1094
  key: 0,
1060
- "icon-left": e(ne),
1095
+ "icon-left": e(ie),
1061
1096
  label: e(n).t("wise_crm.shared.add"),
1062
1097
  variant: "tertiary",
1063
1098
  size: "sm",
1064
- onClick: h
1099
+ onClick: y
1065
1100
  }, null, 8, ["icon-left", "label"])) : N("", !0)
1066
1101
  ]),
1067
1102
  _: 1
@@ -1071,8 +1106,8 @@ const tt = { class: "p-lg" }, nt = /* @__PURE__ */ D({
1071
1106
  }));
1072
1107
  }
1073
1108
  });
1074
- function ot() {
1075
- return $({
1109
+ function rt() {
1110
+ return T({
1076
1111
  queryFn: async ({
1077
1112
  body: t,
1078
1113
  params: a
@@ -1085,17 +1120,17 @@ function ot() {
1085
1120
  }
1086
1121
  });
1087
1122
  }
1088
- function it(t, a) {
1089
- return ve("boardColumnsTransition", {
1123
+ function st(t, a) {
1124
+ return Ue("boardColumnsTransition", {
1090
1125
  params: {
1091
1126
  boardColumnUuid: t
1092
1127
  },
1093
- queryFn: () => la.getTransitions(t.value, a.value)
1128
+ queryFn: () => oa.getTransitions(t.value, a.value)
1094
1129
  });
1095
1130
  }
1096
- const rt = /* @__PURE__ */ D({
1131
+ const ut = /* @__PURE__ */ I({
1097
1132
  __name: "DealDetailSidebarTransitionSelect",
1098
- props: /* @__PURE__ */ Se({
1133
+ props: /* @__PURE__ */ ke({
1099
1134
  deal: {}
1100
1135
  }, {
1101
1136
  modelValue: {
@@ -1105,55 +1140,54 @@ const rt = /* @__PURE__ */ D({
1105
1140
  }),
1106
1141
  emits: ["update:modelValue"],
1107
1142
  setup(t) {
1108
- const a = t, n = x(), i = oa(), u = J().create(ia), p = Ne(t, "modelValue"), f = L(), d = ot(), c = it(
1109
- P(() => p.value.toColumnUuid),
1110
- P(() => i.getOptions().deals?.allowedTransitionTriggerTypes ?? [])
1111
- ), h = P(() => (c.result.value.isOk() ? c.result.value.getValue() : []).flatMap((r) => r.triggers.length === 0 ? [
1112
- r
1113
- ] : r.triggers.map((U) => ({
1114
- ...r,
1115
- toColumnDisplayName: r.toColumnDisplayName,
1143
+ const a = t, n = x(), i = ia(), s = ae().create(ra), p = Se(t, "modelValue"), f = q(), m = rt(), u = st(
1144
+ w(() => p.value.toColumnUuid),
1145
+ w(() => i.getOptions().deals?.allowedTransitionTriggerTypes ?? [])
1146
+ ), y = w(() => (u.result.value.isOk() ? u.result.value.getValue() : []).flatMap((C) => C.triggers.length === 0 ? [
1147
+ C
1148
+ ] : C.triggers.map((c) => ({
1149
+ ...C,
1150
+ toColumnDisplayName: C.toColumnDisplayName,
1116
1151
  triggers: [
1117
- U
1152
+ c
1118
1153
  ]
1119
1154
  }))));
1120
- function v(b) {
1121
- return b?.toColumnDisplayName ?? "-";
1155
+ function h(v) {
1156
+ return v?.toColumnDisplayName ?? "-";
1122
1157
  }
1123
- const _ = P(() => H(h.value));
1124
- async function y(b) {
1125
- if (b.triggers.length !== 0) {
1126
- if (b.triggers[0]?.triggerType === Te.EMAIL) {
1127
- u.open({
1158
+ const _ = w(() => X(y.value));
1159
+ async function b(v) {
1160
+ if (v.triggers.length !== 0) {
1161
+ if (v.triggers[0]?.triggerType === Me.EMAIL) {
1162
+ s.open({
1128
1163
  dealUuid: a.deal.uuid,
1129
1164
  client: {
1130
1165
  uuid: a.deal.client.uuid,
1131
1166
  type: a.deal.client.type
1132
1167
  },
1133
- defaultSenderEmails: a.deal.contactPersons.map((r) => r.email).filter((r) => r !== null),
1134
- templateKey: b.triggers[0].config.mailTemplateKey
1168
+ templateKey: v.triggers[0].config.mailTemplateKey
1135
1169
  });
1136
1170
  return;
1137
1171
  }
1138
1172
  try {
1139
- p.value = b, await d.execute({
1173
+ p.value = v, await m.execute({
1140
1174
  body: {
1141
- toBoardColumnUuid: b.toColumnUuid
1175
+ toBoardColumnUuid: v.toColumnUuid
1142
1176
  },
1143
1177
  params: {
1144
1178
  dealUuid: a.deal.uuid
1145
1179
  }
1146
1180
  });
1147
- } catch (r) {
1148
- f.show(r);
1181
+ } catch (C) {
1182
+ f.show(C);
1149
1183
  }
1150
1184
  }
1151
1185
  }
1152
- return (b, r) => (m(), g(ra, {
1186
+ return (v, C) => (d(), g(sa, {
1153
1187
  color: p.value?.toColumnColor ?? null
1154
1188
  }, {
1155
- default: s(() => [
1156
- h.value.length === 0 ? (m(), g(e(he), {
1189
+ default: r(() => [
1190
+ y.value.length === 0 ? (d(), g(e(ve), {
1157
1191
  key: 0,
1158
1192
  "class-config": {
1159
1193
  root: "text-nowrap"
@@ -1161,30 +1195,30 @@ const rt = /* @__PURE__ */ D({
1161
1195
  label: p.value.toColumnDisplayName,
1162
1196
  variant: "translucent",
1163
1197
  color: "brand"
1164
- }, null, 8, ["label"])) : (m(), g(e(Y), {
1198
+ }, null, 8, ["label"])) : (d(), g(e(J), {
1165
1199
  key: 1,
1166
1200
  "model-value": p.value,
1167
- "is-loading": e(d).isLoading.value,
1168
- "display-fn": v,
1201
+ "is-loading": e(m).isLoading.value,
1202
+ "display-fn": h,
1169
1203
  items: _.value,
1170
1204
  "is-label-hidden": !0,
1171
1205
  placeholder: e(n).t("wise_crm.deal.transition.placeholder"),
1172
1206
  label: e(n).t("wise_crm.deal.transition.label"),
1173
1207
  class: "w-20",
1174
1208
  size: "sm",
1175
- "onUpdate:modelValue": y
1209
+ "onUpdate:modelValue": b
1176
1210
  }, null, 8, ["model-value", "is-loading", "items", "placeholder", "label"]))
1177
1211
  ]),
1178
1212
  _: 1
1179
1213
  }, 8, ["color"]));
1180
1214
  }
1181
1215
  });
1182
- function st() {
1183
- return $({
1216
+ function ct() {
1217
+ return T({
1184
1218
  queryFn: async ({
1185
1219
  body: t,
1186
1220
  params: a
1187
- }) => await me.create(t, {
1221
+ }) => await ge.create(t, {
1188
1222
  dealUuid: a.dealUuid
1189
1223
  }),
1190
1224
  queryKeysToInvalidate: {
@@ -1192,69 +1226,69 @@ function st() {
1192
1226
  }
1193
1227
  });
1194
1228
  }
1195
- function ut(t, a) {
1196
- return Ia("noteDealIndex", {
1229
+ function dt(t, a) {
1230
+ return Na("noteDealIndex", {
1197
1231
  params: {
1198
1232
  params: a?.params
1199
1233
  },
1200
- queryFn: (n) => me.getDealNotes({
1234
+ queryFn: (n) => ge.getDealNotes({
1201
1235
  pagination: n
1202
1236
  }, t.value)
1203
1237
  });
1204
1238
  }
1205
- const ct = /* @__PURE__ */ D({
1239
+ const mt = /* @__PURE__ */ I({
1206
1240
  __name: "DealDialogSidebarNotesContent",
1207
1241
  props: {
1208
1242
  deal: {}
1209
1243
  },
1210
1244
  setup(t) {
1211
- const a = t, i = J().create(sa), o = L(), u = st(), p = ua(), f = ut(
1212
- P(() => a.deal.uuid)
1213
- ), d = P(() => f.result.value.isOk() ? f.result.value.getValue().data : []);
1214
- async function c(_) {
1215
- await u.execute({
1245
+ const a = t, i = ae().create(ua), o = q(), s = ct(), p = ca(), f = dt(
1246
+ w(() => a.deal.uuid)
1247
+ ), m = w(() => f.result.value.isOk() ? f.result.value.getValue().data : []);
1248
+ async function u(_) {
1249
+ await s.execute({
1216
1250
  body: _,
1217
1251
  params: {
1218
1252
  dealUuid: a.deal.uuid
1219
1253
  }
1220
1254
  });
1221
1255
  }
1222
- async function h(_) {
1256
+ async function y(_) {
1223
1257
  try {
1224
1258
  await p.execute({
1225
1259
  params: {
1226
1260
  noteUuid: _
1227
1261
  }
1228
1262
  });
1229
- } catch (y) {
1230
- o.show(y);
1263
+ } catch (b) {
1264
+ o.show(b);
1231
1265
  }
1232
1266
  }
1233
- function v(_) {
1267
+ function h(_) {
1234
1268
  i.open({
1235
1269
  note: _
1236
1270
  });
1237
1271
  }
1238
- return (_, y) => (m(), g(ca, {
1272
+ return (_, b) => (d(), g(da, {
1239
1273
  "is-loading": e(f).isLoading.value,
1240
- notes: d.value,
1241
- "on-submit": c,
1274
+ notes: m.value,
1275
+ "on-submit": u,
1242
1276
  "has-next-page": e(f).hasNextPage.value,
1243
- onNext: y[0] || (y[0] = (b) => e(f).fetchNextPage()),
1244
- onDelete: h,
1245
- onUpdate: v
1277
+ onNext: b[0] || (b[0] = (v) => e(f).fetchNextPage()),
1278
+ onDelete: y,
1279
+ onUpdate: h
1246
1280
  }, null, 8, ["is-loading", "notes", "has-next-page"]));
1247
1281
  }
1248
- }), dt = { class: "flex h-full flex-1 flex-col" }, mt = { class: "flex flex-col gap-xl rounded-2xl border border-primary p-xl" }, pt = { class: "flex w-full flex-wrap items-center justify-between gap-sm" }, ft = /* @__PURE__ */ D({
1282
+ }), pt = { class: "flex h-full flex-1 flex-col" }, ft = { class: "flex flex-col gap-xl rounded-2xl border border-primary p-xl" }, _t = { class: "flex w-full flex-wrap items-center justify-between gap-sm" }, gt = /* @__PURE__ */ I({
1249
1283
  __name: "DealDetailSidebar",
1250
1284
  props: {
1251
1285
  deal: {}
1252
1286
  },
1253
1287
  setup(t) {
1254
- const a = t, n = x(), i = da(), o = T(
1288
+ const a = t, n = x(), i = ma(), o = M(
1255
1289
  "overview"
1256
1290
  /* OVERVIEW */
1257
- ), u = T({
1291
+ ), s = M({
1258
1292
  // There is no uuid available for the initial value, so a placeholder is used
1259
1293
  uuid: "",
1260
1294
  toColumnUuid: a.deal.boardColumn.uuid,
@@ -1262,34 +1296,34 @@ const ct = /* @__PURE__ */ D({
1262
1296
  toColumnDisplayName: a.deal.boardColumn.displayName,
1263
1297
  toColumnKey: "",
1264
1298
  triggers: []
1265
- }), p = P(() => [
1299
+ }), p = w(() => [
1266
1300
  {
1267
- icon: de,
1301
+ icon: _e,
1268
1302
  label: n.t("wise_crm.shared.overview"),
1269
1303
  value: "overview"
1270
1304
  /* OVERVIEW */
1271
1305
  },
1272
1306
  {
1273
- icon: ma,
1307
+ icon: pa,
1274
1308
  label: n.t("wise_crm.shared.notes"),
1275
1309
  value: "notes"
1276
1310
  /* NOTES */
1277
1311
  }
1278
1312
  ]);
1279
- return (f, d) => (m(), M("div", dt, [
1280
- k("div", mt, [
1281
- l(La, {
1313
+ return (f, m) => (d(), V("div", pt, [
1314
+ k("div", ft, [
1315
+ l(Ea, {
1282
1316
  deal: a.deal
1283
1317
  }, null, 8, ["deal"]),
1284
- k("div", pt, [
1285
- l(pa, {
1286
- onClick: d[0] || (d[0] = (c) => e(i).openBusinessDetail(
1318
+ k("div", _t, [
1319
+ l(fa, {
1320
+ onClick: m[0] || (m[0] = (u) => e(i).openBusinessDetail(
1287
1321
  a.deal.client.uuid
1288
1322
  ))
1289
1323
  }, {
1290
- default: s(() => [
1291
- l(e(he), {
1292
- icon: e(fa),
1324
+ default: r(() => [
1325
+ l(e(ve), {
1326
+ icon: e(_a),
1293
1327
  label: a.deal.client.name,
1294
1328
  variant: "translucent",
1295
1329
  color: "brand"
@@ -1297,23 +1331,23 @@ const ct = /* @__PURE__ */ D({
1297
1331
  ]),
1298
1332
  _: 1
1299
1333
  }),
1300
- l(rt, {
1301
- modelValue: u.value,
1302
- "onUpdate:modelValue": d[1] || (d[1] = (c) => u.value = c),
1334
+ l(ut, {
1335
+ modelValue: s.value,
1336
+ "onUpdate:modelValue": m[1] || (m[1] = (u) => s.value = u),
1303
1337
  deal: a.deal
1304
1338
  }, null, 8, ["modelValue", "deal"])
1305
1339
  ])
1306
1340
  ]),
1307
- l(_a, {
1341
+ l(ga, {
1308
1342
  modelValue: o.value,
1309
- "onUpdate:modelValue": d[2] || (d[2] = (c) => o.value = c),
1343
+ "onUpdate:modelValue": m[2] || (m[2] = (u) => o.value = u),
1310
1344
  tabs: p.value
1311
1345
  }, {
1312
- default: s(() => [
1313
- o.value === "overview" ? (m(), g(lt, {
1346
+ default: r(() => [
1347
+ o.value === "overview" ? (d(), g(it, {
1314
1348
  key: 0,
1315
1349
  deal: a.deal
1316
- }, null, 8, ["deal"])) : o.value === "notes" ? (m(), g(ct, {
1350
+ }, null, 8, ["deal"])) : o.value === "notes" ? (d(), g(mt, {
1317
1351
  key: 1,
1318
1352
  deal: a.deal
1319
1353
  }, null, 8, ["deal"])) : N("", !0)
@@ -1322,25 +1356,25 @@ const ct = /* @__PURE__ */ D({
1322
1356
  }, 8, ["modelValue", "tabs"])
1323
1357
  ]));
1324
1358
  }
1325
- }), _t = /* @__PURE__ */ D({
1359
+ }), bt = /* @__PURE__ */ I({
1326
1360
  __name: "DealDetailSidebarProvider",
1327
1361
  props: {
1328
1362
  dealUuid: {}
1329
1363
  },
1330
1364
  setup(t) {
1331
- const a = t, n = ga(
1332
- P(() => a.dealUuid)
1365
+ const a = t, n = ba(
1366
+ w(() => a.dealUuid)
1333
1367
  ), i = x();
1334
- return (o, u) => (m(), g(ya, null, {
1335
- default: s(() => [
1336
- e(n).isError.value ? (m(), g(ba, {
1368
+ return (o, s) => (d(), g(ya, null, {
1369
+ default: r(() => [
1370
+ e(n).isError.value ? (d(), g(ha, {
1337
1371
  key: 0,
1338
1372
  message: e(i).t("error.deal_details.description"),
1339
1373
  title: e(i).t("error.deal_details.title")
1340
- }, null, 8, ["message", "title"])) : e(n).isLoading.value ? (m(), g(ha, {
1374
+ }, null, 8, ["message", "title"])) : e(n).isLoading.value ? (d(), g(va, {
1341
1375
  key: 1,
1342
1376
  class: "h-full"
1343
- })) : e(n).result.value.isOk() ? (m(), g(ft, {
1377
+ })) : e(n).result.value.isOk() ? (d(), g(gt, {
1344
1378
  key: e(n).result.value.getValue().boardColumn.uuid,
1345
1379
  deal: e(n).result.value.getValue()
1346
1380
  }, null, 8, ["deal"])) : N("", !0)
@@ -1348,31 +1382,31 @@ const ct = /* @__PURE__ */ D({
1348
1382
  _: 1
1349
1383
  }));
1350
1384
  }
1351
- }), Nt = /* @__PURE__ */ D({
1385
+ }), kt = /* @__PURE__ */ I({
1352
1386
  __name: "DealDetailView",
1353
1387
  props: {
1354
1388
  tabs: {}
1355
1389
  },
1356
1390
  setup(t) {
1357
- const a = t, n = x(), i = ke("dealUuid"), o = P(() => [
1391
+ const a = t, n = x(), i = Fe("dealUuid"), o = w(() => [
1358
1392
  ...a.tabs,
1359
1393
  {
1360
- label: P(() => n.t("wise_crm.deal.detail_view.communication_tab_label")),
1394
+ label: w(() => n.t("wise_crm.deal.detail_view.communication_tab_label")),
1361
1395
  to: "deal-communication"
1362
1396
  }
1363
1397
  ]);
1364
- return (u, p) => (m(), g(Me, {
1398
+ return (s, p) => (d(), g(Ve, {
1365
1399
  key: e(i),
1366
- "entity-type": e(ie).BUSINESS,
1400
+ "entity-type": e(ce).BUSINESS,
1367
1401
  tabs: o.value
1368
1402
  }, {
1369
- sidebar: s(() => [
1370
- l(_t, { "deal-uuid": e(i) }, null, 8, ["deal-uuid"])
1403
+ sidebar: r(() => [
1404
+ l(bt, { "deal-uuid": e(i) }, null, 8, ["deal-uuid"])
1371
1405
  ]),
1372
1406
  _: 1
1373
1407
  }, 8, ["entity-type", "tabs"]));
1374
1408
  }
1375
1409
  });
1376
1410
  export {
1377
- Nt as default
1411
+ kt as default
1378
1412
  };