@wisemen/wise-crm-web 0.2.0 → 0.2.2

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.
Files changed (97) hide show
  1. package/README.md +1037 -0
  2. package/dist/BusinessDetailSidebarProvider-BQMRbGHQ.js +2083 -0
  3. package/dist/{BusinessDetailView-DvhFfuGg.js → BusinessDetailView-BxGxWOme.js} +5 -5
  4. package/dist/{CrmDetailHeaderCard-e5332OkQ.js → CrmDetailHeaderCard-CCNJpMAK.js} +68 -67
  5. package/dist/{CrmDetailView-C-lsAhtD.js → CrmDetailView-ozCpuaX2.js} +14 -14
  6. package/dist/{DealCommunicationTabView-e7NkRy9r.js → DealCommunicationTabView-Df5EeolN.js} +2 -2
  7. package/dist/{DealDetailView-BDCbOBoo.js → DealDetailView-DdWHqaBr.js} +163 -163
  8. package/dist/{DealExternalAttachment-D1PznE3V.js → DealExternalAttachment-qHdh4yMI.js} +1 -1
  9. package/dist/{DealSendMailDialog-DVE2iYQC.js → DealSendMailDialog-BaYcWZP-.js} +65 -69
  10. package/dist/Error-BArv9rNb.js +12650 -0
  11. package/dist/IndividualDetailSidebarProvider-BXZH951l.js +608 -0
  12. package/dist/{IndividualDetailView-B7dX3hZ8.js → IndividualDetailView-DfYS31-e.js} +5 -5
  13. package/dist/LinkBrokenIcon-CTlqmapl.js +17 -0
  14. package/dist/api/mutations/deal/dealCreate.mutation.d.ts +1 -1
  15. package/dist/api/mutations/deal/dealUpdate.mutation.d.ts +3 -3
  16. package/dist/api/mutations/mail-template/mailTemplateUpdate.mutation.d.ts +1 -1
  17. package/dist/client/apiErrorCode.gen.d.ts +2 -2
  18. package/dist/client/sdk.gen.d.ts +20 -17
  19. package/dist/client/types.gen.d.ts +1057 -1376
  20. package/dist/client/zod.gen.d.ts +15453 -17750
  21. package/dist/{client-BP13IBbl.js → client-pCaNxE3C.js} +748 -1047
  22. package/dist/components/app/dialog/AppConfirmDialog.vue.d.ts +2 -2
  23. package/dist/components/crm-detail/CrmDetailHeaderCard.vue.d.ts +2 -0
  24. package/dist/components/crm-detail/CrmDetailSidebarAccordionContactPersonInfo.vue.d.ts +2 -2
  25. package/dist/components/crm-detail/CrmDetailSidebarAccordionGenericContactPersonInfo.vue.d.ts +2 -2
  26. package/dist/components/notes/NoteList.vue.d.ts +2 -2
  27. package/dist/deal/components/DealSendMailForm.vue.d.ts +2 -2
  28. package/dist/deal/components/DealSendMailFormFooter.vue.d.ts +1 -1
  29. package/dist/deal/components/DealSettingsDialogMailTemplateForm.vue.d.ts +2 -2
  30. package/dist/deal/components/DealSettingsDialogMailTemplateFormFields.vue.d.ts +2 -2
  31. package/dist/dialogs/contact-create/ContactCreateDialog.vue.d.ts +1 -1
  32. package/dist/dialogs/contact-create/components/ContactCreateDialogBusinessContactPersonSearch.vue.d.ts +2 -2
  33. package/dist/dialogs/contact-create/components/ContactCreateDialogBusinessGeneralInfo.vue.d.ts +2 -2
  34. package/dist/dialogs/contact-create/components/ContactCreateDialogFooter.vue.d.ts +2 -2
  35. package/dist/dialogs/contact-create/components/ContactCreateDialogFormSection.vue.d.ts +2 -2
  36. package/dist/dialogs/note/CrmDetailSidebarNotesView.vue.d.ts +2 -2
  37. package/dist/icons/LinkBrokenIcon.vue.d.ts +3 -0
  38. package/dist/icons/icon.d.ts +1 -0
  39. package/dist/index.d.ts +4 -0
  40. package/dist/index.js +448 -453
  41. package/dist/models/brand-colors/brandColor.model.d.ts +14 -0
  42. package/dist/models/brand-colors/brandColor.transformer.d.ts +5 -0
  43. package/dist/models/conent-locale/contentLocaleEnum.model.d.ts +3 -3
  44. package/dist/models/deal/create/dealCreateForm.model.d.ts +2 -2
  45. package/dist/models/deal/detail/dealDetail.model.d.ts +2 -2
  46. package/dist/models/deal/index/dealIndex.model.d.ts +2 -2
  47. package/dist/models/deal/update/dealUpdateForm.model.d.ts +2 -2
  48. package/dist/models/mail-template/detail/mailTemplateDetail.model.d.ts +2 -2
  49. package/dist/models/mail-template/update/mailTemplateUpdateForm.model.d.ts +3 -3
  50. package/dist/models/phone-number/phoneNumberForm.model.d.ts +3 -0
  51. package/dist/models/tenant-config/tenantConfig.model.d.ts +3 -0
  52. package/dist/plugins/i18n.plugin.d.ts +4 -0
  53. package/dist/style.css +1 -1
  54. package/dist/testing/factories/business.factory.d.ts +2 -1
  55. package/dist/testing.js +23 -2
  56. package/package.json +2 -1
  57. package/dist/BusinessDetailSidebarProvider-D11bjWFa.js +0 -2081
  58. package/dist/BusinessDetailSidebarProvider-DYY-Uzvx.js +0 -2081
  59. package/dist/BusinessDetailSidebarProvider-ZYGQoNHh.js +0 -2081
  60. package/dist/BusinessDetailView-BOCy7G-w.js +0 -24
  61. package/dist/BusinessDetailView-WaATSNQS.js +0 -24
  62. package/dist/CrmDetailHeaderCard-C-JNdi7s.js +0 -2515
  63. package/dist/CrmDetailHeaderCard-qkNK-2wR.js +0 -2515
  64. package/dist/CrmDetailView-C6Xm1Lp6.js +0 -65
  65. package/dist/CrmDetailView-DQehs8Fb.js +0 -65
  66. package/dist/DealDetailView-BfkDNvK4.js +0 -1021
  67. package/dist/DealDetailView-Cs5TDhih.js +0 -1021
  68. package/dist/DealSendMailDialog-D5Voyhhc.js +0 -1556
  69. package/dist/DealSendMailDialog-OAn6xjLq.js +0 -1556
  70. package/dist/Error-5vt6UD4m.js +0 -3708
  71. package/dist/Error-B4TwHEhb.js +0 -3706
  72. package/dist/Error-BPxDpKcI.js +0 -3706
  73. package/dist/IndividualDetailSidebarProvider-CvZQdjzp.js +0 -606
  74. package/dist/IndividualDetailSidebarProvider-DBITt-9W.js +0 -606
  75. package/dist/IndividualDetailSidebarProvider-vIu7Hv8O.js +0 -606
  76. package/dist/IndividualDetailView-B1vbJXGc.js +0 -24
  77. package/dist/IndividualDetailView-BKEs0XS5.js +0 -24
  78. /package/dist/{LinkExternalIcon-B9Qg55Oa.js → LinkExternalIcon-LOVtSqBT.js} +0 -0
  79. /package/dist/{LinkIcon-DCW5zjbQ.js → LinkIcon-DqBbVrvs.js} +0 -0
  80. /package/dist/{LocationPinIcon-DBc-wt2e.js → LocationPinIcon-Cp-wRgk2.js} +0 -0
  81. /package/dist/{MailIcon-Do4a7S2W.js → MailIcon-CnTrB1k3.js} +0 -0
  82. /package/dist/{MobilePhoneIcon-DSXyKwjd.js → MobilePhoneIcon-B747hmpS.js} +0 -0
  83. /package/dist/{NumberedListIcon-DUaSJSYu.js → NumberedListIcon-amJxDaaD.js} +0 -0
  84. /package/dist/{PhoneIcon-C8Cv1IiW.js → PhoneIcon-94MYVL85.js} +0 -0
  85. /package/dist/{RefreshIcon-CKZgHIZU.js → RefreshIcon-DRe3coBc.js} +0 -0
  86. /package/dist/{SendIcon-B-sQkQ3W.js → SendIcon-MYItp1xI.js} +0 -0
  87. /package/dist/{SettingsIcon-DzP-IQS5.js → SettingsIcon-C0qTAv0w.js} +0 -0
  88. /package/dist/{StarOutlineIcon-c0VfXRdQ.js → StarOutlineIcon-CiFLgepk.js} +0 -0
  89. /package/dist/{StarYellowIcon-CH0CnlSU.js → StarYellowIcon-C0v_XGwI.js} +0 -0
  90. /package/dist/{ThreeDotsIcon-C6PCFq5J.js → ThreeDotsIcon-lujOTU3G.js} +0 -0
  91. /package/dist/{TimeLineMarkerIcon-6B6SbwTN.js → TimeLineMarkerIcon-C4LfErbc.js} +0 -0
  92. /package/dist/{TrashIcon-BTPSVviz.js → TrashIcon-v4L9SEK_.js} +0 -0
  93. /package/dist/{UploadCloudIcon-1aMW5OJq.js → UploadCloudIcon-j1-1Rvqb.js} +0 -0
  94. /package/dist/{UserCircleIcon-D-19dc-2.js → UserCircleIcon-BjUt_2C4.js} +0 -0
  95. /package/dist/{UserIcon-D1H8TGlg.js → UserIcon-Cb2jFKLr.js} +0 -0
  96. /package/dist/{VerticalDotsIcon-DmPza4Jd.js → VerticalDotsIcon-Y3m6tlQ2.js} +0 -0
  97. /package/dist/{WalletIcon-BlI3D3v-.js → WalletIcon-pPsKbzmh.js} +0 -0
@@ -1,5 +1,5 @@
1
1
  import { s as ZonedDateTimeTransformer } from "./AppSkeletonLoader-BAhoOmFD.js";
2
- import { et as viewMailIndexV1, o as createMailV1, yt as MimeType } from "./client-BP13IBbl.js";
2
+ import { et as viewMailIndexV1, o as createMailV1, vt as MimeType } from "./client-pCaNxE3C.js";
3
3
  import { t as __plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-BSi1g3Lh.js";
4
4
  import { createBlock, createElementBlock, createElementVNode, createVNode, defineComponent, openBlock, renderSlot, toDisplayString, unref, withCtx } from "vue";
5
5
  import { VcIcon, VcIconButton } from "@wisemen/vue-core-components";
@@ -1,8 +1,8 @@
1
- import { B as AppForm_default, F as useOffsetInfiniteQuery, G as AppDialogActionPrimary_default, K as AppDialogActionCancel_default, L as AppDialogHeader_default, U as AppDialogContainer_default, W as AppDialogActions_default, Y as createI18nKeyMap, p as AppUnstyledButton_default, q as useApiErrorToast, rt as StringUtil, z as toFormField } from "./Error-BPxDpKcI.js";
1
+ import { B as toFormField, G as AppDialogActions_default, I as useOffsetInfiniteQuery, J as useApiErrorToast, K as AppDialogActionPrimary_default, R as AppDialogHeader_default, V as AppForm_default, W as AppDialogContainer_default, X as createI18nKeyMap, it as StringUtil, p as AppUnstyledButton_default, q as AppDialogActionCancel_default } from "./Error-BArv9rNb.js";
2
2
  import { a as AppGroup_default, l as He, s as ZonedDateTimeTransformer, t as AppSkeletonLoader_default, u as ze } from "./AppSkeletonLoader-BAhoOmFD.js";
3
- import { C as unlinkContactPersonFromDealV1, D as updateDealContactPersonV1, G as viewDealIndexV1, O as updateDealV1, U as viewDealContactPersonDetailV1, W as viewDealDetailV1, _ as makeDealContactPersonPrimaryV1, dt as ClientType, f as linkContactPersonToDealV1, ft as ContentLocale, h as listBoardColumnsV1, i as createFileV1, j as updateMailTemplateV1, m as listBoardColumnTransitionsV1, nt as viewMailTemplateDetailV1, ot as viewUserIndexV1, r as createDealV1, rt as viewMailTemplateIndexV1, t as confirmFileUploadV1, tt as viewMailTemplateDetailByKeyV1, x as transitionDealColumnV1 } from "./client-BP13IBbl.js";
3
+ import { C as unlinkContactPersonFromDealV1, D as updateDealContactPersonV1, G as viewDealIndexV1, O as updateDealV1, U as viewDealContactPersonDetailV1, W as viewDealDetailV1, _ as makeDealContactPersonPrimaryV1, dt as ClientType, f as linkContactPersonToDealV1, h as listBoardColumnsV1, i as createFileV1, j as updateMailTemplateV1, m as listBoardColumnTransitionsV1, nt as viewMailTemplateDetailV1, ot as viewUserIndexV1, r as createDealV1, rt as viewMailTemplateIndexV1, t as confirmFileUploadV2, tt as viewMailTemplateDetailByKeyV1, x as transitionDealColumnV1, yt as SdkContentLocale } from "./client-pCaNxE3C.js";
4
4
  import { t as __plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-BSi1g3Lh.js";
5
- import { a as RevealOnHoverOrFocus_default, i as FileUtil, n as DealCommunicationMailListSectionContainer_default, o as FileReferenceTransformer, r as MailService, t as DealExternalAttachment_default } from "./DealExternalAttachment-D1PznE3V.js";
5
+ import { a as RevealOnHoverOrFocus_default, i as FileUtil, n as DealCommunicationMailListSectionContainer_default, o as FileReferenceTransformer, r as MailService, t as DealExternalAttachment_default } from "./DealExternalAttachment-qHdh4yMI.js";
6
6
  import z$1, { z } from "zod";
7
7
  import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, mergeModels, mergeProps, normalizeClass, onBeforeUnmount, onMounted, openBlock, ref, renderList, renderSlot, toDisplayString, unref, useAttrs, useId, useModel, useTemplateRef, watch, withCtx } from "vue";
8
8
  import { useI18n } from "vue-i18n";
@@ -10,7 +10,7 @@ import { FileUploadStatus, PaginationParamsBuilder, VcButton, VcDialog, VcDialog
10
10
  import { useElementSize } from "@vueuse/core";
11
11
  import { useForm } from "formango";
12
12
  import { AnimatePresence, Motion, MotionConfig, motion } from "motion-v";
13
- import { ListboxContent, ListboxItem, ListboxRoot, Primitive, TagsInputClear, TagsInputInput, TagsInputItem, TagsInputItemDelete, TagsInputItemText, TagsInputRoot } from "reka-ui";
13
+ import { ListboxContent, ListboxItem, ListboxRoot, Primitive, TagsInputInput, TagsInputItem, TagsInputItemDelete, TagsInputItemText, TagsInputRoot } from "reka-ui";
14
14
  import Link from "@tiptap/extension-link";
15
15
  import { StarterKit } from "@tiptap/starter-kit";
16
16
  import { EditorContent, useEditor } from "@tiptap/vue-3";
@@ -50,28 +50,24 @@ var AppTagsInputField_default = /* @__PURE__ */ defineComponent({
50
50
  delimiter: ";",
51
51
  class: "gap-sm border-secondary bg-primary px-sm py-xxs flex max-h-50 min-h-10 w-full flex-wrap items-center overflow-y-auto rounded-md border"
52
52
  }, {
53
- default: withCtx(() => [
54
- (openBlock(!0), createElementBlock(Fragment, null, renderList(R.value, (i) => (openBlock(), createBlock(unref(TagsInputItem), {
55
- key: i,
56
- value: i,
57
- class: "gap-xs border-primary px-xs text-secondary my-[0.18rem] flex items-center justify-center rounded-sm border text-xs aria-[current=true]:bg-brand-500"
58
- }, {
59
- default: withCtx(() => [createVNode(unref(TagsInputItemText), { class: "pl-sm text-xs" }), createVNode(unref(TagsInputItemDelete), { class: "group p-xs rounded-full bg-transparent" }, {
60
- default: withCtx(() => [createVNode(unref(VcIcon), {
61
- icon: "close",
62
- class: "size-3 duration-200 group-hover:scale-110"
63
- })]),
64
- _: 1
53
+ default: withCtx(() => [(openBlock(!0), createElementBlock(Fragment, null, renderList(R.value, (i) => (openBlock(), createBlock(unref(TagsInputItem), {
54
+ key: i,
55
+ value: i,
56
+ class: "gap-xs border-primary px-xs text-secondary my-[0.18rem] flex items-center justify-center rounded-sm border text-xs aria-[current=true]:bg-brand-500"
57
+ }, {
58
+ default: withCtx(() => [createVNode(unref(TagsInputItemText), { class: "pl-sm text-xs" }), createVNode(unref(TagsInputItemDelete), { class: "group p-xs rounded-full bg-transparent" }, {
59
+ default: withCtx(() => [createVNode(unref(VcIcon), {
60
+ icon: "close",
61
+ class: "size-3 duration-200 group-hover:scale-110"
65
62
  })]),
66
63
  _: 1
67
- }, 8, ["value"]))), 128)),
68
- createVNode(unref(TagsInputClear)),
69
- createVNode(unref(TagsInputInput), {
70
- placeholder: P.placeholder,
71
- class: "px-sm h-8 flex-1 rounded-full bg-transparent text-sm placeholder:text-placeholder focus:outline-none",
72
- onBlur: N[0] ||= (i) => I("blur")
73
- }, null, 8, ["placeholder"])
74
- ]),
64
+ })]),
65
+ _: 1
66
+ }, 8, ["value"]))), 128)), createVNode(unref(TagsInputInput), {
67
+ placeholder: P.placeholder,
68
+ class: "px-sm h-8 flex-1 rounded-full bg-transparent text-sm placeholder:text-placeholder focus:outline-none",
69
+ onBlur: N[0] ||= (i) => I("blur")
70
+ }, null, 8, ["placeholder"])]),
75
71
  _: 1
76
72
  }, 8, ["id", "modelValue"])]),
77
73
  _: 3
@@ -482,7 +478,7 @@ var _hoisted_1$11 = {
482
478
  });
483
479
  }
484
480
  };
485
- z.enum(ContentLocale);
481
+ z.enum(SdkContentLocale);
486
482
  var ContentLocaleUtil = class {
487
483
  static i18nKeys = createI18nKeyMap({
488
484
  "de-DE": "wise_crm.language.de",
@@ -589,8 +585,8 @@ function useMailTemplateDetailByKeyQuery(i) {
589
585
  var _hoisted_1$10 = { class: "p-xl w-96 max-w-full" }, AppRichTextFieldLinkDialog_default = /* @__PURE__ */ defineComponent({
590
586
  __name: "AppRichTextFieldLinkDialog",
591
587
  emits: ["close", "confirm"],
592
- setup(N, { emit: B }) {
593
- let H = B, U = useI18n(), W = useForm({
588
+ setup(P, { emit: I }) {
589
+ let H = I, U = useI18n(), W = useForm({
594
590
  schema: z.object({ url: z.string().url() }),
595
591
  onSubmit: (i) => {
596
592
  H("confirm", i.url);
@@ -599,7 +595,7 @@ var _hoisted_1$10 = { class: "p-xl w-96 max-w-full" }, AppRichTextFieldLinkDialo
599
595
  function J() {
600
596
  H("close");
601
597
  }
602
- return (N, B) => (openBlock(), createBlock(unref(VcDialog), { onClose: J }, {
598
+ return (P, I) => (openBlock(), createBlock(unref(VcDialog), { onClose: J }, {
603
599
  default: withCtx(() => [createElementVNode("div", _hoisted_1$10, [createVNode(AppDialogHeader_default, {
604
600
  title: unref(U).t("rich_text.link_dialog.title"),
605
601
  icon: "link"
@@ -610,7 +606,7 @@ var _hoisted_1$10 = { class: "p-xl w-96 max-w-full" }, AppRichTextFieldLinkDialo
610
606
  default: withCtx(() => [createVNode(unref(VcTextField), mergeProps({ label: unref(U).t("rich_text.link_dialog.url") }, unref(toFormField)(unref(G))), null, 16, ["label"]), createVNode(AppDialogActions_default, null, {
611
607
  default: withCtx(() => [createVNode(AppDialogActionCancel_default, { label: unref(U).t("shared.cancel") }, null, 8, ["label"]), createVNode(AppDialogActionPrimary_default, {
612
608
  label: unref(U).t("shared.confirm"),
613
- onClick: B[0] ||= (i) => unref(W).submit()
609
+ onClick: I[0] ||= (i) => unref(W).submit()
614
610
  }, null, 8, ["label"])]),
615
611
  _: 1
616
612
  })]),
@@ -653,7 +649,7 @@ var _hoisted_1$10 = { class: "p-xl w-96 max-w-full" }, AppRichTextFieldLinkDialo
653
649
  onUpdate({ editor: i }) {
654
650
  R.value = i.getHTML();
655
651
  }
656
- }), H = useDialog(AppRichTextFieldLinkDialog_default), W = computed(() => [
652
+ }), H = useDialog(AppRichTextFieldLinkDialog_default), U = computed(() => [
657
653
  {
658
654
  id: "bold",
659
655
  icon: "bold",
@@ -722,7 +718,7 @@ var _hoisted_1$10 = { class: "p-xl w-96 max-w-full" }, AppRichTextFieldLinkDialo
722
718
  }, "bg-primary flex flex-col overflow-hidden rounded-lg border"])
723
719
  }, [createVNode(unref(ListboxRoot), { orientation: "horizontal" }, {
724
720
  default: withCtx(() => [createVNode(unref(ListboxContent), { class: "gap-sm p-sm border-secondary flex border-b" }, {
725
- default: withCtx(() => [(openBlock(!0), createElementBlock(Fragment, null, renderList(W.value, (i, N) => (openBlock(), createBlock(unref(ListboxItem), {
721
+ default: withCtx(() => [(openBlock(!0), createElementBlock(Fragment, null, renderList(U.value, (i, N) => (openBlock(), createBlock(unref(ListboxItem), {
726
722
  key: N,
727
723
  value: N,
728
724
  class: normalizeClass([{
@@ -760,7 +756,7 @@ var _hoisted_1$10 = { class: "p-xl w-96 max-w-full" }, AppRichTextFieldLinkDialo
760
756
  }
761
757
  }), FileUploadService = class {
762
758
  static async confirmUpload(i, N) {
763
- await confirmFileUploadV1({
759
+ await confirmFileUploadV2({
764
760
  body: { blurHash: N },
765
761
  path: { file: i }
766
762
  });
@@ -1349,14 +1345,14 @@ var _hoisted_1$3 = { class: "w-full overflow-hidden" }, _hoisted_2$1 = { class:
1349
1345
  emits: ["cancel"],
1350
1346
  setup(i, { emit: N }) {
1351
1347
  let P = i, I = N, R = useI18n();
1352
- function V() {
1348
+ function B() {
1353
1349
  I("cancel");
1354
1350
  }
1355
1351
  return (N, I) => (openBlock(), createBlock(AppDialogContainer_default, { class: "pt-lg gap-md border-secondary flex justify-between border-t" }, {
1356
1352
  default: withCtx(() => [createVNode(unref(VcButton), {
1357
1353
  variant: "secondary",
1358
1354
  size: "lg",
1359
- onClick: V
1355
+ onClick: B
1360
1356
  }, {
1361
1357
  default: withCtx(() => [createTextVNode(toDisplayString(unref(R).t("wise_crm.form.cancel")), 1)]),
1362
1358
  _: 1
@@ -1402,45 +1398,45 @@ var _hoisted_1$1 = { class: "flex-1 overflow-y-auto" }, DealSendMailForm_default
1402
1398
  },
1403
1399
  emits: ["close"],
1404
1400
  setup(N, { emit: P }) {
1405
- let I = N, R = P, B = useI18n(), V = useApiErrorToast(), H = useMailCreateMutation(), U = computed(() => I.template.locales.findIndex((i) => i.language === I.dealLanguage)), G = useForm({
1401
+ let R = N, B = P, H = useI18n(), U = useApiErrorToast(), W = useMailCreateMutation(), G = computed(() => R.template.locales.findIndex((i) => i.language === R.dealLanguage)), K = useForm({
1406
1402
  initialState: {
1407
1403
  clientId: {
1408
- uuid: I.client.uuid,
1409
- type: I.client.type
1404
+ uuid: R.client.uuid,
1405
+ type: R.client.type
1410
1406
  },
1411
- dealUuid: I.dealUuid,
1412
- mailTemplateUuid: I.template.uuid,
1413
- attachments: [...I.template.locales[U.value]?.attachments.map(FileReferenceTransformer.toForm) ?? []],
1414
- bcc: I.template.defaultBCC,
1415
- cc: I.template.defaultCC,
1407
+ dealUuid: R.dealUuid,
1408
+ mailTemplateUuid: R.template.uuid,
1409
+ attachments: [...R.template.locales[G.value]?.attachments.map(FileReferenceTransformer.toForm) ?? []],
1410
+ bcc: R.template.defaultBCC,
1411
+ cc: R.template.defaultCC,
1416
1412
  from: null,
1417
1413
  replyTo: null,
1418
- subject: I.template.locales[U.value]?.subject ?? null,
1419
- text: I.template.locales[U.value]?.message ?? null,
1420
- to: I.defaultSenderEmails ?? []
1414
+ subject: R.template.locales[G.value]?.subject ?? null,
1415
+ text: R.template.locales[G.value]?.message ?? null,
1416
+ to: R.defaultSenderEmails ?? []
1421
1417
  },
1422
1418
  schema: mailCreateFormSchema,
1423
1419
  onSubmit: async (i) => {
1424
1420
  try {
1425
- await H.execute({
1421
+ await W.execute({
1426
1422
  body: i,
1427
1423
  params: {
1428
- dealUuid: I.dealUuid,
1429
- externalAttachments: I.externalAttachments
1424
+ dealUuid: R.dealUuid,
1425
+ externalAttachments: R.externalAttachments
1430
1426
  }
1431
1427
  }), $();
1432
1428
  } catch (i) {
1433
- V.show(i);
1429
+ U.show(i);
1434
1430
  }
1435
1431
  }
1436
1432
  });
1437
- G.register("bcc"), G.register("cc"), G.register("replyTo"), G.register("from"), G.register("dealUuid", I.dealUuid), G.register("clientId", I.client);
1438
- let Y = G.register("subject"), X = G.register("to"), Z = G.register("attachments", []), Q = G.register("text");
1433
+ K.register("bcc"), K.register("cc"), K.register("replyTo"), K.register("from"), K.register("dealUuid", R.dealUuid), K.register("clientId", R.client);
1434
+ let Y = K.register("subject"), X = K.register("to"), Z = K.register("attachments", []), Q = K.register("text");
1439
1435
  function $() {
1440
- R("close");
1436
+ B("close");
1441
1437
  }
1442
1438
  return (N, P) => (openBlock(), createBlock(AppForm_default, {
1443
- form: unref(G),
1439
+ form: unref(K),
1444
1440
  class: "flex h-full flex-col"
1445
1441
  }, {
1446
1442
  default: withCtx(() => [createElementVNode("div", _hoisted_1$1, [
@@ -1450,15 +1446,15 @@ var _hoisted_1$1 = { class: "flex-1 overflow-y-auto" }, DealSendMailForm_default
1450
1446
  input: "text-xl",
1451
1447
  root: "border-none shadow-none text-md"
1452
1448
  },
1453
- placeholder: unref(B).t("wise_crm.deal.send_mail_form.subject_placeholder")
1449
+ placeholder: unref(H).t("wise_crm.deal.send_mail_form.subject_placeholder")
1454
1450
  }), null, 16, ["placeholder"])]),
1455
1451
  _: 1
1456
1452
  }),
1457
1453
  createVNode(DealCommunicationMailListSectionContainer_default, null, {
1458
1454
  default: withCtx(() => [createVNode(AppGroup_default, null, {
1459
1455
  default: withCtx(() => [createVNode(AppTagsInputField_default, mergeProps(unref(toFormField)(unref(X)), {
1460
- label: unref(B).t("wise_crm.deal.send_mail_form.to_label"),
1461
- placeholder: unref(B).t("wise_crm.deal.send_mail_form.email_placeholder")
1456
+ label: unref(H).t("wise_crm.deal.send_mail_form.to_label"),
1457
+ placeholder: unref(H).t("wise_crm.deal.send_mail_form.email_placeholder")
1462
1458
  }), {
1463
1459
  label: withCtx(() => [createVNode(unref(VcFormFieldLabel), { class: "sr-only" })]),
1464
1460
  _: 1
@@ -1468,19 +1464,19 @@ var _hoisted_1$1 = { class: "flex-1 overflow-y-auto" }, DealSendMailForm_default
1468
1464
  _: 1
1469
1465
  }),
1470
1466
  createVNode(DealCommunicationMailListSectionContainer_default, null, {
1471
- default: withCtx(() => [createVNode(DealSendMailFormAttachmentField_default, mergeProps({ "external-attachments": I.externalAttachments }, unref(toFormField)(unref(Z)), { accept: ["application/pdf", "image/*"] }), null, 16, ["external-attachments"])]),
1467
+ default: withCtx(() => [createVNode(DealSendMailFormAttachmentField_default, mergeProps({ "external-attachments": R.externalAttachments }, unref(toFormField)(unref(Z)), { accept: ["application/pdf", "image/*"] }), null, 16, ["external-attachments"])]),
1472
1468
  _: 1
1473
1469
  }),
1474
1470
  createVNode(DealCommunicationMailListSectionContainer_default, { class: "flex-1 border-b-0" }, {
1475
- default: withCtx(() => [createVNode(AppRichTextField_default, mergeProps(unref(toFormField)(unref(Q)), { label: unref(B).t("wise_crm.deal.send_mail_form.message_label") }), {
1471
+ default: withCtx(() => [createVNode(AppRichTextField_default, mergeProps(unref(toFormField)(unref(Q)), { label: unref(H).t("wise_crm.deal.send_mail_form.message_label") }), {
1476
1472
  label: withCtx(() => [createVNode(unref(VcFormFieldLabel), { class: "sr-only" })]),
1477
1473
  _: 1
1478
1474
  }, 16, ["label"])]),
1479
1475
  _: 1
1480
1476
  })
1481
1477
  ]), createVNode(DealSendMailFormFooter_default, {
1482
- "is-generating-pdf": I.isGeneratingPdf,
1483
- "is-submitting": unref(G).isSubmitting.value,
1478
+ "is-generating-pdf": R.isGeneratingPdf,
1479
+ "is-submitting": unref(K).isSubmitting.value,
1484
1480
  onCancel: $
1485
1481
  }, null, 8, ["is-generating-pdf", "is-submitting"])]),
1486
1482
  _: 1
@@ -1501,17 +1497,17 @@ var _hoisted_1$1 = { class: "flex-1 overflow-y-auto" }, DealSendMailForm_default
1501
1497
  },
1502
1498
  emits: ["close"],
1503
1499
  setup(i, { emit: N }) {
1504
- let P = i, I = N, R = useApiErrorToast(), B = ref(P.generatePdfFile !== void 0), V = ref(null), H = computed(() => V.value === null ? P.externalAttachments : [...P.externalAttachments, V.value]), U = useDealDetailQuery(computed(() => P.dealUuid)), G = computed(() => U.data.value?.dealLanguage ?? ContentLocale.NL_BE), K = useMailTemplateDetailByKeyQuery(computed(() => P.templateKey));
1500
+ let P = i, R = N, B = useApiErrorToast(), V = ref(P.generatePdfFile !== void 0), H = ref(null), U = computed(() => H.value === null ? P.externalAttachments : [...P.externalAttachments, H.value]), W = useDealDetailQuery(computed(() => P.dealUuid)), G = computed(() => W.data.value?.dealLanguage ?? SdkContentLocale.NL_BE), K = useMailTemplateDetailByKeyQuery(computed(() => P.templateKey));
1505
1501
  function Y() {
1506
- I("close");
1502
+ R("close");
1507
1503
  }
1508
1504
  async function X() {
1509
1505
  if (P.generatePdfFile !== void 0) try {
1510
- V.value = await P.generatePdfFile;
1506
+ H.value = await P.generatePdfFile;
1511
1507
  } catch (i) {
1512
- R.show(i);
1508
+ B.show(i);
1513
1509
  } finally {
1514
- B.value = !1;
1510
+ V.value = !1;
1515
1511
  }
1516
1512
  }
1517
1513
  return onMounted(async () => {
@@ -1528,15 +1524,15 @@ var _hoisted_1$1 = { class: "flex-1 overflow-y-auto" }, DealSendMailForm_default
1528
1524
  }, {
1529
1525
  default: withCtx(() => [createVNode(AppSkeletonLoader_default, { class: "h-40 w-full" }), createVNode(AppSkeletonLoader_default, { class: "mt-xl w-full flex-1" })]),
1530
1526
  _: 1
1531
- })])) : unref(K).data.value !== null && unref(U).data.value !== null ? (openBlock(), createBlock(DealSendMailForm_default, {
1527
+ })])) : unref(K).data.value !== null && unref(W).data.value !== null ? (openBlock(), createBlock(DealSendMailForm_default, {
1532
1528
  key: 1,
1533
- "default-sender-emails": unref(U).data.value.contactPersons.map((i) => i.email).filter((i) => i !== null),
1529
+ "default-sender-emails": unref(W).data.value.contactPersons.map((i) => i.email).filter((i) => i !== null),
1534
1530
  "deal-language": G.value,
1535
1531
  template: unref(K).data.value,
1536
1532
  client: P.client,
1537
1533
  "deal-uuid": P.dealUuid,
1538
- "external-attachments": H.value,
1539
- "is-generating-pdf": B.value,
1534
+ "external-attachments": U.value,
1535
+ "is-generating-pdf": V.value,
1540
1536
  onClose: Y
1541
1537
  }, null, 8, [
1542
1538
  "default-sender-emails",