@ozdao/prometheus-framework 0.2.94 → 0.2.95

Sign up to get free protection for your applications and to get access to all the features.
Files changed (192) hide show
  1. package/dist/auth.server.js +15 -14
  2. package/dist/auth.server.mjs +15 -14
  3. package/dist/main-BJvlNekm.mjs +13631 -0
  4. package/dist/main-pGo7JpSP.js +92 -0
  5. package/dist/orders.server.js +26 -22
  6. package/dist/orders.server.mjs +26 -22
  7. package/dist/organizations.server.js +31 -10
  8. package/dist/organizations.server.mjs +31 -10
  9. package/dist/prometheus-framework/src/components/Block/Block.vue.cjs +1 -1
  10. package/dist/prometheus-framework/src/components/Block/Block.vue.js +2 -2
  11. package/dist/prometheus-framework/src/components/Button/Button.vue.cjs +1 -1
  12. package/dist/prometheus-framework/src/components/Button/Button.vue.js +94 -1
  13. package/dist/prometheus-framework/src/components/Button/Button.vue2.cjs +1 -1
  14. package/dist/prometheus-framework/src/components/Button/Button.vue2.js +1 -94
  15. package/dist/prometheus-framework/src/components/EditImages/EditImages.vue.js +19 -19
  16. package/dist/prometheus-framework/src/components/Field/Field.vue.cjs +1 -1
  17. package/dist/prometheus-framework/src/components/Field/Field.vue.js +84 -1
  18. package/dist/prometheus-framework/src/components/Field/Field.vue2.cjs +1 -1
  19. package/dist/prometheus-framework/src/components/Field/Field.vue2.js +1 -84
  20. package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.cjs +1 -1
  21. package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.js +1 -1
  22. package/dist/prometheus-framework/src/components/Popup/Popup.vue.js +12 -12
  23. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.cjs +1 -1
  24. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.js +45 -1
  25. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.cjs +1 -1
  26. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.js +1 -45
  27. package/dist/prometheus-framework/src/components/Upload/Upload.vue.js +21 -21
  28. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.cjs +1 -1
  29. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.js +2 -2
  30. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.cjs +1 -1
  31. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.js +1 -1
  32. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.cjs +1 -1
  33. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.js +2 -2
  34. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.cjs +1 -1
  35. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.js +2 -2
  36. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.cjs +1 -1
  37. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.js +2 -2
  38. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
  39. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +2 -2
  40. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.cjs +1 -1
  41. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.js +2 -2
  42. package/dist/prometheus-framework/src/modules/auth/router/auth.cjs +1 -1
  43. package/dist/prometheus-framework/src/modules/auth/router/auth.js +4 -0
  44. package/dist/prometheus-framework/src/modules/backoffice/router/backoffice.cjs +1 -1
  45. package/dist/prometheus-framework/src/modules/backoffice/router/backoffice.js +8 -8
  46. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +1 -1
  47. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +2 -2
  48. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
  49. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +3 -3
  50. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +1 -1
  51. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +1 -1
  52. package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.cjs +1 -1
  53. package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.js +1 -1
  54. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.cjs +5 -1
  55. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue.js +66 -0
  56. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.cjs +1 -5
  57. package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.js +0 -66
  58. package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.cjs +1 -1
  59. package/dist/prometheus-framework/src/modules/constructor/components/sections/Constructor.vue.js +1 -1
  60. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs +1 -1
  61. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.js +1 -1
  62. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.cjs +1 -1
  63. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.js +1 -1
  64. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +1 -1
  65. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +3 -3
  66. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs +1 -1
  67. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js +2 -2
  68. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
  69. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +60 -60
  70. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.cjs +1 -1
  71. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.js +2 -2
  72. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.cjs +1 -1
  73. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.js +1 -1
  74. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.cjs +1 -1
  75. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.js +2 -2
  76. package/dist/prometheus-framework/src/modules/icons/navigation/IconCross.vue.cjs +1 -1
  77. package/dist/prometheus-framework/src/modules/icons/navigation/IconCross.vue.js +22 -21
  78. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
  79. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +2 -2
  80. package/dist/prometheus-framework/src/modules/orders/components/blocks/StatusHistory.vue.cjs +2 -2
  81. package/dist/prometheus-framework/src/modules/orders/components/blocks/StatusHistory.vue.js +48 -37
  82. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.cjs +1 -1
  83. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.js +160 -167
  84. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +1 -1
  85. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +50 -49
  86. package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.cjs +1 -1
  87. package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.js +113 -110
  88. package/dist/prometheus-framework/src/modules/orders/components/partials/ShopCart.vue.js +14 -14
  89. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.cjs +1 -1
  90. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +2 -2
  91. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.cjs +1 -1
  92. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.js +1 -1
  93. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.cjs +1 -1
  94. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.js +1 -1
  95. package/dist/prometheus-framework/src/modules/orders/store/models/order.cjs +1 -0
  96. package/dist/prometheus-framework/src/modules/orders/store/models/order.js +28 -0
  97. package/dist/prometheus-framework/src/modules/orders/store/orders.cjs +1 -1
  98. package/dist/prometheus-framework/src/modules/orders/store/orders.js +25 -43
  99. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardDepartment.vue.cjs +1 -1
  100. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardDepartment.vue.js +19 -19
  101. package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.cjs +1 -1
  102. package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.js +1 -1
  103. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
  104. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +47 -47
  105. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.cjs +1 -1
  106. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.js +143 -131
  107. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.cjs +1 -1
  108. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.js +1 -1
  109. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +1 -1
  110. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +2 -2
  111. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +1 -1
  112. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.js +3 -3
  113. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +1 -1
  114. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +2 -2
  115. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
  116. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +2 -2
  117. package/dist/prometheus-framework/src/modules/organizations/organizations.client.cjs +1 -1
  118. package/dist/prometheus-framework/src/modules/organizations/organizations.client.js +32 -34
  119. package/dist/prometheus-framework/src/modules/organizations/router/members.router.cjs +1 -1
  120. package/dist/prometheus-framework/src/modules/organizations/router/members.router.js +1 -1
  121. package/dist/prometheus-framework/src/modules/organizations/store/departments.cjs +1 -1
  122. package/dist/prometheus-framework/src/modules/organizations/store/departments.js +1 -1
  123. package/dist/prometheus-framework/src/modules/organizations/store/memberships.cjs +1 -1
  124. package/dist/prometheus-framework/src/modules/organizations/store/memberships.js +30 -32
  125. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +1 -1
  126. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +1 -1
  127. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.cjs +1 -1
  128. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.js +1 -1
  129. package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.cjs +1 -1
  130. package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.js +1 -1
  131. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs +1 -1
  132. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +1 -1
  133. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +1 -1
  134. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +2 -2
  135. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
  136. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +1 -1
  137. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +1 -1
  138. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +155 -187
  139. package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.cjs +1 -1
  140. package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.js +1 -1
  141. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +1 -1
  142. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +19 -19
  143. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.cjs +1 -1
  144. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.js +1 -1
  145. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.cjs +1 -1
  146. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +1 -1
  147. package/dist/prometheus-framework/src/modules/users/components/blocks/CardUser.vue.cjs +1 -1
  148. package/dist/prometheus-framework/src/modules/users/components/blocks/CardUser.vue.js +26 -22
  149. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
  150. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +68 -65
  151. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.cjs +1 -1
  152. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.js +2 -2
  153. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
  154. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +2 -2
  155. package/dist/prometheus-framework.cjs.js +1 -1
  156. package/dist/prometheus-framework.es.js +1 -1
  157. package/dist/style.css +1 -1
  158. package/dist/web-B2xhKZNK.js +1 -0
  159. package/dist/web-DTzbVshr.mjs +54 -0
  160. package/package.json +1 -1
  161. package/src/components/Block/Block.vue +1 -1
  162. package/src/modules/auth/controllers/auth.controller.js +19 -16
  163. package/src/modules/auth/router/auth.js +4 -0
  164. package/src/modules/backoffice/router/backoffice.js +3 -3
  165. package/src/modules/chats/routes/chats.routes.js +1 -2
  166. package/src/modules/gallery/components/sections/BackofficeGallery.vue +2 -1
  167. package/src/modules/icons/navigation/IconCross.vue +11 -7
  168. package/src/modules/orders/components/blocks/StatusHistory.vue +8 -11
  169. package/src/modules/orders/components/pages/OrderBackoffice.vue +37 -50
  170. package/src/modules/orders/components/pages/OrderCreateBackoffice.vue +7 -3
  171. package/src/modules/orders/components/pages/Orders.vue +1 -1
  172. package/src/modules/orders/controllers/orders.controller.js +24 -24
  173. package/src/modules/orders/models/order.model.js +1 -1
  174. package/src/modules/orders/routes/orders.routes.js +6 -0
  175. package/src/modules/orders/store/models/order.js +33 -0
  176. package/src/modules/orders/store/orders.js +7 -28
  177. package/src/modules/organizations/components/blocks/CardDepartment.vue +2 -2
  178. package/src/modules/organizations/components/pages/DepartmentEdit.vue +7 -5
  179. package/src/modules/organizations/components/pages/Members.vue +50 -38
  180. package/src/modules/organizations/components/pages/Organization.vue +1 -1
  181. package/src/modules/organizations/controllers/invites.controller.js +2 -0
  182. package/src/modules/organizations/controllers/memberships.controller.js +35 -11
  183. package/src/modules/organizations/models/invite.model.js +4 -0
  184. package/src/modules/organizations/organizations.client.js +0 -2
  185. package/src/modules/organizations/router/members.router.js +1 -1
  186. package/src/modules/organizations/store/departments.js +0 -1
  187. package/src/modules/organizations/store/memberships.js +1 -8
  188. package/src/modules/products/components/pages/ProductEdit.vue +39 -33
  189. package/src/modules/products/components/sections/EditProductInfo.vue +3 -3
  190. package/src/modules/users/components/blocks/CardUser.vue +9 -5
  191. package/src/modules/users/components/pages/Profile.vue +5 -3
  192. package/src/modules/organizations/components/blocks/DepartmentMemberModify.vue +0 -126
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),t=require("../../../../../_virtual/_plugin-vue_export-helper.cjs"),o={},n={width:"26",height:"26",viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg"},l=e.createElementVNode("rect",{width:"24",height:"24",transform:"translate(1 1)"},null,-1),r=e.createElementVNode("path",{fill:"rgb(var(--black))","fill-rule":"evenodd","clip-rule":"evenodd",d:"M12.9996 10.8L22.8994 0.900244L25.0993 3.1002L15.1995 13L25.0993 22.8998L22.8994 25.0998L12.9996 15.2L3.09976 25.0998L0.899801 22.8998L10.7996 13L0.899801 3.1002L3.09976 0.900244L12.9996 10.8Z"},null,-1),c=[l,r];function s(d,u){return e.openBlock(),e.createElementBlock("svg",n,c)}const i=t.default(o,[["render",s]]);exports.default=i;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),t={width:"26",height:"26",viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg"},o=["fill"],n={__name:"IconCross",props:{fill:{type:String,default:"rgb(var(--black))"}},setup(l){return(r,i)=>(e.openBlock(),e.createElementBlock("svg",t,[e.createElementVNode("path",{fill:l.fill,"fill-rule":"evenodd","clip-rule":"evenodd",d:"M12.9996 10.8L22.8994 0.900244L25.0993 3.1002L15.1995 13L25.0993 22.8998L22.8994 25.0998L12.9996 15.2L3.09976 25.0998L0.899801 22.8998L10.7996 13L0.899801 3.1002L3.09976 0.900244L12.9996 10.8Z"},null,8,o)]))}};exports.default=n;
@@ -1,28 +1,29 @@
1
- import { openBlock as t, createElementBlock as o, createElementVNode as e } from "vue";
2
- import n from "../../../../../_virtual/_plugin-vue_export-helper.js";
3
- const r = {}, c = {
1
+ import { openBlock as l, createElementBlock as t, createElementVNode as o } from "vue";
2
+ const n = {
4
3
  width: "26",
5
4
  height: "26",
6
5
  viewBox: "0 0 26 26",
7
6
  fill: "none",
8
7
  xmlns: "http://www.w3.org/2000/svg"
9
- }, l = /* @__PURE__ */ e("rect", {
10
- width: "24",
11
- height: "24",
12
- transform: "translate(1 1)"
13
- }, null, -1), s = /* @__PURE__ */ e("path", {
14
- fill: "rgb(var(--black))",
15
- "fill-rule": "evenodd",
16
- "clip-rule": "evenodd",
17
- d: "M12.9996 10.8L22.8994 0.900244L25.0993 3.1002L15.1995 13L25.0993 22.8998L22.8994 25.0998L12.9996 15.2L3.09976 25.0998L0.899801 22.8998L10.7996 13L0.899801 3.1002L3.09976 0.900244L12.9996 10.8Z"
18
- }, null, -1), i = [
19
- l,
20
- s
21
- ];
22
- function _(d, h) {
23
- return t(), o("svg", c, i);
24
- }
25
- const f = /* @__PURE__ */ n(r, [["render", _]]);
8
+ }, r = ["fill"], L = {
9
+ __name: "IconCross",
10
+ props: {
11
+ fill: {
12
+ type: String,
13
+ default: "rgb(var(--black))"
14
+ }
15
+ },
16
+ setup(e) {
17
+ return (i, c) => (l(), t("svg", n, [
18
+ o("path", {
19
+ fill: e.fill,
20
+ "fill-rule": "evenodd",
21
+ "clip-rule": "evenodd",
22
+ d: "M12.9996 10.8L22.8994 0.900244L25.0993 3.1002L15.1995 13L25.0993 22.8998L22.8994 25.0998L12.9996 15.2L3.09976 25.0998L0.899801 22.8998L10.7996 13L0.899801 3.1002L3.09976 0.900244L12.9996 10.8Z"
23
+ }, null, 8, r)
24
+ ]));
25
+ }
26
+ };
26
27
  export {
27
- f as default
28
+ L as default
28
29
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");require("../../../../components/Field/Field.vue.cjs");require("../../../../components/Loader/Loader.vue.cjs");require("../../../../components/Button/Button.vue.cjs");const a=require("../../../mobile/components/Menu/Menu.vue.cjs"),r=require("../../../mobile/components/Menu/MenuItem.vue.cjs"),n=require("vue-router");require("../../../auth/store/auth.cjs");require("./Legal.vue2.cjs");const u={class:"for-transition w-100 pd-medium"},l=e.createStaticVNode('<div class="bg-grey radius-medium pd-medium mn-b-small"><h2 class="mn-b-small">About No More Snow CO., LTD.</h2><p class="mn-b-small"> Welcome to NO MORE SNOW CO., LTD.! We are dedicated to providing top-notch services and creating a trustworthy environment for our users. Your trust and safety are our priority, and we are committed to being transparent about our policies and practices. </p><p class="mn-b-small"> If you have any questions, concerns, or feedback, please do not hesitate to contact us through the following details. Our team is always here to assist you! </p><p class="mn-b-small"> Address: 10/3 Laemsai Rd, Karon, Mueang Phuket District, Phuket 83100<br> Telephone: +660803202142<br> Email: <a href="mailto:hello@thecommunephuket.com">hello@thecommunephuket.com</a><br> Website: <a href="https://thecommunephuket.com" target="_blank">https://thecommunephuket.com</a></p></div>',1),i=e.createElementVNode("span",null,"Terms of Use",-1),c=e.createElementVNode("span",null,"Privacy Policy",-1),d=e.createElementVNode("span",null,"Cookie Policy",-1),m=e.createElementVNode("span",null,"EULA",-1),p={__name:"Legal",setup(h){n.useRoute();const o=n.useRouter();return e.ref(!1),(f,t)=>(e.openBlock(),e.createElementBlock("div",u,[l,e.createVNode(a.default,{class:"bg-grey"},{default:e.withCtx(()=>[e.createVNode(r.default,{onClick:t[0]||(t[0]=s=>e.unref(o).push({name:"Terms of Use"})),class:"cursor-pointer"},{default:e.withCtx(()=>[i]),_:1}),e.createVNode(r.default,{onClick:t[1]||(t[1]=s=>e.unref(o).push({name:"Privacy Policy"})),class:"cursor-pointer"},{default:e.withCtx(()=>[c]),_:1}),e.createVNode(r.default,{onClick:t[2]||(t[2]=s=>e.unref(o).push({name:"Cookie Policy"})),class:"cursor-pointer"},{default:e.withCtx(()=>[d]),_:1}),e.createVNode(r.default,{onClick:t[3]||(t[3]=s=>e.unref(o).push({name:"EULA"})),class:"cursor-pointer"},{default:e.withCtx(()=>[m]),_:1})]),_:1})]))}};exports.default=p;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");require("../../../../components/Field/Field.vue2.cjs");require("../../../../components/Loader/Loader.vue.cjs");require("../../../../components/Button/Button.vue2.cjs");const a=require("../../../mobile/components/Menu/Menu.vue.cjs"),r=require("../../../mobile/components/Menu/MenuItem.vue.cjs"),n=require("vue-router");require("../../../auth/store/auth.cjs");require("./Legal.vue2.cjs");const u={class:"for-transition w-100 pd-medium"},l=e.createStaticVNode('<div class="bg-grey radius-medium pd-medium mn-b-small"><h2 class="mn-b-small">About No More Snow CO., LTD.</h2><p class="mn-b-small"> Welcome to NO MORE SNOW CO., LTD.! We are dedicated to providing top-notch services and creating a trustworthy environment for our users. Your trust and safety are our priority, and we are committed to being transparent about our policies and practices. </p><p class="mn-b-small"> If you have any questions, concerns, or feedback, please do not hesitate to contact us through the following details. Our team is always here to assist you! </p><p class="mn-b-small"> Address: 10/3 Laemsai Rd, Karon, Mueang Phuket District, Phuket 83100<br> Telephone: +660803202142<br> Email: <a href="mailto:hello@thecommunephuket.com">hello@thecommunephuket.com</a><br> Website: <a href="https://thecommunephuket.com" target="_blank">https://thecommunephuket.com</a></p></div>',1),i=e.createElementVNode("span",null,"Terms of Use",-1),c=e.createElementVNode("span",null,"Privacy Policy",-1),d=e.createElementVNode("span",null,"Cookie Policy",-1),m=e.createElementVNode("span",null,"EULA",-1),p={__name:"Legal",setup(h){n.useRoute();const o=n.useRouter();return e.ref(!1),(f,t)=>(e.openBlock(),e.createElementBlock("div",u,[l,e.createVNode(a.default,{class:"bg-grey"},{default:e.withCtx(()=>[e.createVNode(r.default,{onClick:t[0]||(t[0]=s=>e.unref(o).push({name:"Terms of Use"})),class:"cursor-pointer"},{default:e.withCtx(()=>[i]),_:1}),e.createVNode(r.default,{onClick:t[1]||(t[1]=s=>e.unref(o).push({name:"Privacy Policy"})),class:"cursor-pointer"},{default:e.withCtx(()=>[c]),_:1}),e.createVNode(r.default,{onClick:t[2]||(t[2]=s=>e.unref(o).push({name:"Cookie Policy"})),class:"cursor-pointer"},{default:e.withCtx(()=>[d]),_:1}),e.createVNode(r.default,{onClick:t[3]||(t[3]=s=>e.unref(o).push({name:"EULA"})),class:"cursor-pointer"},{default:e.withCtx(()=>[m]),_:1})]),_:1})]))}};exports.default=p;
@@ -1,7 +1,7 @@
1
1
  import { ref as l, openBlock as m, createElementBlock as u, createVNode as t, withCtx as o, unref as r, createStaticVNode as c, createElementVNode as a } from "vue";
2
- import "../../../../components/Field/Field.vue.js";
2
+ import "../../../../components/Field/Field.vue2.js";
3
3
  import "../../../../components/Loader/Loader.vue.js";
4
- import "../../../../components/Button/Button.vue.js";
4
+ import "../../../../components/Button/Button.vue2.js";
5
5
  import p from "../../../mobile/components/Menu/Menu.vue.js";
6
6
  import n from "../../../mobile/components/Menu/MenuItem.vue.js";
7
7
  import { useRoute as d, useRouter as h } from "vue-router";
@@ -1,3 +1,3 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),m=require("../../../icons/navigation/IconCheckmark.vue.cjs"),p={class:"bg-grey radius-medium w-100"},y=e.createElementVNode("h3",{class:"pd-medium"},"Tracking History",-1),k={class:"flex-center flex i-big radius-extra br-solid br-2px br-black-transp-10 mn-r-small"},_={class:"h4 w-8r"},b={key:0,class:"h5 w-8r"},f={class:"h5 w-8r"},h=["disabled","onClick"],g={__name:"StatusHistory",props:{statusHistory:{type:Array},statusCurrent:{type:String},edit:{type:Boolean},statuses:{type:Array}},setup(o){const n=o,i=n.statuses.map(s=>{const r=n.statusHistory.find(t=>t.status===s);return{status:s,timestamp:r?r.timestamp:"N/A",inHistory:!!r,_id:r?r._id:null}}),c=e.ref(n.statusCurrent),l=e.ref(n.statusHistory),u=s=>l.value.some(r=>r.status===s),d=s=>{const t=n.statuses.findIndex(a=>a===c.value)+1;return n.statuses[t]&&n.statuses[t]===s};return e.ref("192.168.1.197"),e.ref(9100),e.ref(`This is some text to print
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),u=require("../../../icons/navigation/IconCheckmark.vue.cjs"),m={class:"bg-grey radius-medium w-100"},d=e.createElementVNode("h3",{class:"pd-medium"},"Tracking History",-1),p={class:"flex-center flex i-big radius-extra br-solid br-2px br-black-transp-10 mn-r-small"},k={class:"h4 w-8r"},_={key:0,class:"h5 w-8r"},f={__name:"StatusHistory",props:{statusHistory:{type:Array},statusCurrent:{type:String},edit:{type:Boolean},statuses:{type:Array}},setup(a){const o=a,l=o.statuses.map(s=>{const t=o.statusHistory.find(n=>n.status===s);return console.log(),{status:s,user:(t==null?void 0:t.user)||void 0,timestamp:t?t.timestamp:"N/A",inHistory:!!t,_id:t?t._id:null}});e.ref(o.statusCurrent);const c=e.ref(o.statusHistory),i=s=>c.value.some(t=>t.status===s);return e.ref("192.168.1.197"),e.ref(9100),e.ref(`This is some text to print
2
2
 
3
- `),(s,r)=>(e.openBlock(),e.createElementBlock("div",p,[y,(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(i),t=>(e.openBlock(),e.createElementBlock("div",{key:t,class:"w-100 br-t br-solid br-black-transp-10 pd-medium flex-v-center flex-nowrap flex"},[e.createElementVNode("div",k,[u(t.status)?(e.openBlock(),e.createBlock(m.default,{key:0,class:"i-medium"})):e.createCommentVNode("",!0)]),e.createElementVNode("div",null,[e.createElementVNode("p",_,e.toDisplayString(t.status),1),t.timestamp?(e.openBlock(),e.createElementBlock("p",b,e.toDisplayString(s.formatDate(t.timestamp)),1)):e.createCommentVNode("",!0)]),e.createElementVNode("p",f,e.toDisplayString(t._id),1),o.edit?(e.openBlock(),e.createElementBlock("button",{key:0,disabled:!d(t),onClick:a=>s.setStatus(t),class:"mn-l-auto bg-main button radius-big"},"Set status",8,h)):e.createCommentVNode("",!0)]))),128))]))}};exports.default=g;
3
+ `),(s,t)=>{const n=e.resolveComponent("router-link");return e.openBlock(),e.createElementBlock("div",m,[d,(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(l),r=>(e.openBlock(),e.createElementBlock("div",{key:r,class:"w-100 br-t br-solid br-black-transp-10 pd-medium flex-v-center flex-nowrap flex"},[e.createElementVNode("div",p,[i(r.status)?(e.openBlock(),e.createBlock(u.default,{key:0,class:"i-medium"})):e.createCommentVNode("",!0)]),e.createElementVNode("div",null,[e.createElementVNode("p",k,e.toDisplayString(r.status),1),r.timestamp?(e.openBlock(),e.createElementBlock("p",_,e.toDisplayString(s.formatDate(r.timestamp)),1)):e.createCommentVNode("",!0)]),r.user?(e.openBlock(),e.createBlock(n,{key:0,to:{name:"User Profile",params:{_id:r.user}},class:"pd-small radius-extra bg-second t-white mn-l-auto flex-center uppercase t-semi"},{default:e.withCtx(()=>[e.createTextVNode("Check User")]),_:2},1032,["to"])):e.createCommentVNode("",!0)]))),128))])}}};exports.default=f;
@@ -1,9 +1,9 @@
1
- import { ref as i, openBlock as n, createElementBlock as a, Fragment as f, renderList as h, unref as x, createElementVNode as o, createBlock as k, createCommentVNode as u, toDisplayString as c } from "vue";
2
- import g from "../../../icons/navigation/IconCheckmark.vue.js";
3
- const H = { class: "bg-grey radius-medium w-100" }, v = /* @__PURE__ */ o("h3", { class: "pd-medium" }, "Tracking History", -1), S = { class: "flex-center flex i-big radius-extra br-solid br-2px br-black-transp-10 mn-r-small" }, w = { class: "h4 w-8r" }, C = {
1
+ import { ref as o, resolveComponent as f, openBlock as r, createElementBlock as i, Fragment as k, renderList as x, unref as h, createElementVNode as n, createBlock as u, createCommentVNode as c, toDisplayString as m, withCtx as b, createTextVNode as g } from "vue";
2
+ import H from "../../../icons/navigation/IconCheckmark.vue.js";
3
+ const v = { class: "bg-grey radius-medium w-100" }, w = /* @__PURE__ */ n("h3", { class: "pd-medium" }, "Tracking History", -1), C = { class: "flex-center flex i-big radius-extra br-solid br-2px br-black-transp-10 mn-r-small" }, B = { class: "h4 w-8r" }, N = {
4
4
  key: 0,
5
5
  class: "h5 w-8r"
6
- }, I = { class: "h5 w-8r" }, B = ["disabled", "onClick"], D = {
6
+ }, D = {
7
7
  __name: "StatusHistory",
8
8
  props: {
9
9
  statusHistory: {
@@ -19,46 +19,57 @@ const H = { class: "bg-grey radius-medium w-100" }, v = /* @__PURE__ */ o("h3",
19
19
  type: Array
20
20
  }
21
21
  },
22
- setup(l) {
23
- const r = l, m = r.statuses.map((s) => {
24
- const e = r.statusHistory.find((t) => t.status === s);
25
- return {
22
+ setup(d) {
23
+ const a = d, p = a.statuses.map((s) => {
24
+ const e = a.statusHistory.find((l) => l.status === s);
25
+ return console.log(), {
26
26
  status: s,
27
+ user: (e == null ? void 0 : e.user) || void 0,
27
28
  timestamp: e ? e.timestamp : "N/A",
28
29
  inHistory: !!e,
29
30
  _id: e ? e._id : null
30
31
  };
31
- }), p = i(r.statusCurrent), y = i(r.statusHistory), _ = (s) => y.value.some((e) => e.status === s), b = (s) => {
32
- const t = r.statuses.findIndex((d) => d === p.value) + 1;
33
- return r.statuses[t] && r.statuses[t] === s;
34
- };
35
- return i("192.168.1.197"), i(9100), i(`This is some text to print
32
+ });
33
+ o(a.statusCurrent);
34
+ const _ = o(a.statusHistory), y = (s) => _.value.some((e) => e.status === s);
35
+ return o("192.168.1.197"), o(9100), o(`This is some text to print
36
36
 
37
- `), (s, e) => (n(), a("div", H, [
38
- v,
39
- (n(!0), a(f, null, h(x(m), (t) => (n(), a("div", {
40
- key: t,
41
- class: "w-100 br-t br-solid br-black-transp-10 pd-medium flex-v-center flex-nowrap flex"
42
- }, [
43
- o("div", S, [
44
- _(t.status) ? (n(), k(g, {
37
+ `), (s, e) => {
38
+ const l = f("router-link");
39
+ return r(), i("div", v, [
40
+ w,
41
+ (r(!0), i(k, null, x(h(p), (t) => (r(), i("div", {
42
+ key: t,
43
+ class: "w-100 br-t br-solid br-black-transp-10 pd-medium flex-v-center flex-nowrap flex"
44
+ }, [
45
+ n("div", C, [
46
+ y(t.status) ? (r(), u(H, {
47
+ key: 0,
48
+ class: "i-medium"
49
+ })) : c("", !0)
50
+ ]),
51
+ n("div", null, [
52
+ n("p", B, m(t.status), 1),
53
+ t.timestamp ? (r(), i("p", N, m(s.formatDate(t.timestamp)), 1)) : c("", !0)
54
+ ]),
55
+ t.user ? (r(), u(l, {
45
56
  key: 0,
46
- class: "i-medium"
47
- })) : u("", !0)
48
- ]),
49
- o("div", null, [
50
- o("p", w, c(t.status), 1),
51
- t.timestamp ? (n(), a("p", C, c(s.formatDate(t.timestamp)), 1)) : u("", !0)
52
- ]),
53
- o("p", I, c(t._id), 1),
54
- l.edit ? (n(), a("button", {
55
- key: 0,
56
- disabled: !b(t),
57
- onClick: (d) => s.setStatus(t),
58
- class: "mn-l-auto bg-main button radius-big"
59
- }, "Set status", 8, B)) : u("", !0)
60
- ]))), 128))
61
- ]));
57
+ to: {
58
+ name: "User Profile",
59
+ params: {
60
+ _id: t.user
61
+ }
62
+ },
63
+ class: "pd-small radius-extra bg-second t-white mn-l-auto flex-center uppercase t-semi"
64
+ }, {
65
+ default: b(() => [
66
+ g("Check User")
67
+ ]),
68
+ _: 2
69
+ }, 1032, ["to"])) : c("", !0)
70
+ ]))), 128))
71
+ ]);
72
+ };
62
73
  }
63
74
  };
64
75
  export {
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),q=require("vue-router"),z=require("../../../globals/components/sections/SectionPageTitle.vue.cjs"),T=require("../../../../components/Popup/Popup.vue.cjs"),F=require("../../../icons/entities/IconTime.vue.cjs"),P=require("../blocks/CardOrderItem.vue.cjs"),L=require("../../../organizations/components/blocks/CardOrganization.vue.cjs"),R=require("../../../chats/components/pages/ChatPage.vue.cjs"),A=require("../blocks/StatusHistory.vue.cjs"),H=require("../../../globals/store/globals.cjs"),c=require("../../store/orders.cjs"),U=require("../../../products/store/products.cjs"),W=require("../../../organizations/store/organizations.cjs");require("./OrderBackoffice.vue2.cjs");const j=require("../../../../../../_virtual/_plugin-vue_export-helper.cjs"),r=b=>(e.pushScopeId("data-v-36d45d04"),b=b(),e.popScopeId(),b),Q={key:0,class:"pd-thin"},Y={key:0,class:"mn-b-thin pos-relative w-100 bg-main radius-big pd-big"},$={class:"mn-b-small flex-nowrap flex"},G=r(()=>e.createElementVNode("p",{class:"t-medium p-medium mn-r-auto"}," Progress ",-1)),J={class:"t-medium p-medium"},K={class:"p-small t-transp"},X=r(()=>e.createElementVNode("h2",{class:"mn-b-small"},null,-1)),Z={class:"radius-extra mn-b-medium flex-nowrap flex pos-relative"},ee={class:"flex-nowrap flex"},te={class:"w-max flex-v-center gap-thin flex-nowrap flex pd-thin radius-small bg-white-transp-20"},se={class:"t-medium mn-r-auto"},ae={class:"bg-grey radius-small pd-small mn-b-thin"},re={class:"bg-grey pd-small radius-small flex gap-thin flex-column mn-b-semi"},le={key:1,class:"gap-thin cols-2"},ne={class:"w-100"},oe={class:"mn-b-thin bg-grey w-100 o-hidden radius-medium"},ie={class:"pd-small flex-nowrap flex"},ce={class:"mn-r-auto"},de=r(()=>e.createElementVNode("span",{class:"d-block t-medium p-medium"},"Your order is",-1)),ue={class:"t-lh-075 h2 d-block mn-b-small"},me=r(()=>e.createElementVNode("p",{class:"pd-t-nano pd-b-nano pd-r-thin pd-l-thin radius-extra bg-black t-white w-max"},"as on 29 aug 2021, Friday",-1)),pe=r(()=>e.createElementVNode("div",{class:"t-right"},[e.createTextVNode(" Cancel order"),e.createElementVNode("br"),e.createTextVNode(" Exchange item "),e.createElementVNode("hr",{class:"mn-b-thin mn-t-thin"}),e.createTextVNode(" For Delivery Queries Contact Us ")],-1)),_e={class:"pd-small cols-2 br-t br-black-transp-10 br-solid"},he=r(()=>e.createElementVNode("p",{class:"w-100 t-medium p-medium"}," Phone ",-1)),be={class:"w-100 t-right"},ge={key:0,class:"pd-small cols-2 br-t br-black-transp-10 br-solid"},ve={class:"w-100 t-medium p-medium"},Ne={class:"w-100 t-right"},fe=r(()=>e.createElementVNode("div",{class:"pd-small cols-2 br-t br-black-transp-10 br-solid"},[e.createElementVNode("p",{class:"t-medium p-medium"}," Address "),e.createElementVNode("p",{class:"w-100 t-right"})],-1)),Ve={class:"pd-small cols-2 br-t br-black-transp-10 br-solid"},Ee=r(()=>e.createElementVNode("p",{class:"mn-b-small t-medium p-medium"}," Delivery ",-1)),ye={class:"w-100 t-right mn-b-small"},ke={key:2,class:"t-transp"},we={class:"bg-grey radius-big pd-medium mn-r-bold pd-r-big br-right-dark w-100"},Se=r(()=>e.createElementVNode("h3",{class:"mn-b-small"},"Order Summary",-1)),xe={class:"flex gap-thin flex-column mn-b-semi"},Ce={class:"mn-b-medium radius-small br-solid br-1px br-black-transp-10 w-100"},Be={class:"pd-small br-solid br-b br-black-transp-10 flex"},De=r(()=>e.createElementVNode("p",{class:"mn-r-auto t-transp"},"In total",-1)),Oe={class:"pd-small br-solid br-b br-black-transp-10 flex"},qe=r(()=>e.createElementVNode("p",{class:"mn-r-auto t-transp"},"Delivery",-1)),Pe={class:"pd-small flex-bottom flex"},Ie=r(()=>e.createElementVNode("p",{class:"mn-r-auto t-transp"},"In total to pay",-1)),Me={class:"p-big t-semi"},ze=r(()=>e.createElementVNode("h3",{class:"mn-b-small"},"Chat With Us",-1)),Te={__name:"OrderBackoffice",setup(b){q.useRouter();const _=q.useRoute(),s=e.ref(null),g=e.ref(null),n=e.ref(null),o=["created","confirmed","packing","in delivery","delivered"],V=["Order Confirming","Order Confirmed","Packing","In Delivery","Delivered"],v=t=>o.slice(t).includes(s.value.status),N=e.ref(!1),E=e.ref(null),f=e.ref([]);function I(t){N.value=!0,typeof t=="number"&&(E.value=t)}function y(){N.value=!1,E.value=null}e.onMounted(async()=>{var a,l;s.value=await c.actions.read({_id:_.params.order}),s.value=s.value[0],g.value=await U.actions.read({organization:s.value.owner.target._id,limit:1e3}),console.log(g.value);const t=g.value.reduce((d,u)=>(d[u._id]=u,d),{});console.log(t),f.value=s.value.positions.map(({_id:d,quantity:u})=>{const m=t[d];return{name:m.name,images:m.images,price:m.price,_id:m._id,quantity:u}}),n.value=await W.actions.read({_id:(a=s.value)==null?void 0:a.owner.target._id,location:(l=H.state.position)==null?void 0:l.location})});let k=e.computed(()=>{var t;return Number((t=s.value)==null?void 0:t.positions.reduce((a,l)=>a+l.price*l.quantity,0))});e.computed(()=>{var t;return Number((t=s.value)==null?void 0:t.positions.reduce((a,l)=>a+l.quantity,0))});function h(t){const a=o.indexOf(t);return a!==-1&&a+1<o.length?o[a+1]:null}function w(t){const a=o.indexOf(t);return t?V[a]:""}async function M(){const t=h(c.state.current.status);t?(c.state.current.status=t,await c.actions.update(c.state.current)):console.error("Next status is void. Must handle somehow."),y()}return(t,a)=>{var l,d,u,m,S,x,C,B,D,O;return s.value&&n.value?(e.openBlock(),e.createElementBlock("div",Q,[e.createVNode(z.default,{title:`Order is ${s.value.status}`,class:"mn-b-small bg-grey bg-grey radius-big"},null,8,["title"]),s.value?(e.openBlock(),e.createElementBlock("div",Y,[e.createElementVNode("div",$,[G,e.createElementVNode("p",J,[e.createTextVNode(" Order No: "),e.createElementVNode("span",K,"#"+e.toDisplayString(s.value._id),1)])]),X,e.createElementVNode("div",Z,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(o,(p,i)=>e.createElementVNode("div",{key:i,class:"mn-r-thin w-20"},[e.createElementVNode("div",{class:e.normalizeClass(["bg-grey br-anim br-glow radius-extra h-1r w-100",{"br-glow-anim":v(i)},{"t-transp":!v(i)},{blink:s.value.status===o[i]&&h(s.value.status)}])},null,2),e.createElementVNode("div",{class:e.normalizeClass([{"t-transp":!v(i)},"mn-t-thin t-medium uppercase"])},e.toDisplayString(V[i]),3)])),64))]),e.createElementVNode("div",ee,[e.createElementVNode("div",te,[e.createVNode(F.default,{class:"i-semi t-transp",fill:"rgb(var(--black)"}),e.createElementVNode("p",se,"Estimated Arrival "+e.toDisplayString(t.formatDate(s.value.deadline)),1)]),h(s.value.status)&&e.unref(_).name==="Order Edit"?(e.openBlock(),e.createElementBlock("button",{key:0,onClick:I,class:"mn-l-auto bg-black t-white button"}," Mark as "+e.toDisplayString(w(h(s.value.status))),1)):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createVNode(T.default,{title:"Change status",onClosePopup:y,isPopupOpen:N.value,class:"bg-white w-min-30r w-max-30r radius-big pd-big"},{default:e.withCtx(()=>[e.createElementVNode("p",ae,"Estimated Arrival "+e.toDisplayString(t.formatDate(s.value.deadline)),1),e.createElementVNode("ul",re,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(p,i)=>(e.openBlock(),e.createBlock(P.default,{key:p._id,editable:!1,product:p},null,8,["product"]))),128))]),e.createElementVNode("button",{onClick:M,class:"w-100 bg-black-small t-white button"},e.toDisplayString("Confirm Changing to "+w(h(s.value.status))),1)]),_:1},8,["isPopupOpen"]),s.value?(e.openBlock(),e.createElementBlock("div",le,[e.createElementVNode("div",ne,[n.value[0]?(e.openBlock(),e.createBlock(L.default,{key:0,organization:n.value[0],showRating:!0,showFollowers:!1,showProducts:!1,class:"bg-grey mn-b-thin w-100 o-hidden radius-big pd-small"},null,8,["organization"])):e.createCommentVNode("",!0),e.createElementVNode("div",oe,[e.createElementVNode("div",ie,[e.createElementVNode("div",ce,[de,e.createElementVNode("span",ue,e.toDisplayString(s.value.status),1),me]),pe]),e.createElementVNode("div",_e,[he,e.createElementVNode("p",be,e.toDisplayString((l=s.value.user)==null?void 0:l.number),1)]),(d=s.value.user)!=null&&d.messenger.type?(e.openBlock(),e.createElementBlock("div",ge,[e.createElementVNode("p",ve,e.toDisplayString((u=s.value.user)==null?void 0:u.messenger.type),1),e.createElementVNode("p",Ne,e.toDisplayString((m=s.value.user)==null?void 0:m.messenger.value),1)])):e.createCommentVNode("",!0),fe,e.createElementVNode("div",Ve,[Ee,e.createElementVNode("p",ye,e.toDisplayString((S=s.value.delivery)==null?void 0:S.type),1)])]),c.state.current.status_history?(e.openBlock(),e.createBlock(A.default,{key:1,statuses:o,statusHistory:c.state.current.status_history,statusCurrent:c.state.current.status,edit:e.unref(_).name==="Order Edit"},null,8,["statusHistory","statusCurrent","edit"])):e.createCommentVNode("",!0),t.payment&&t.payment.Status==="CONFIRMED"?(e.openBlock(),e.createElementBlock("span",ke,"Paid")):e.createCommentVNode("",!0)]),e.createElementVNode("div",we,[Se,e.createElementVNode("ul",xe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(p,i)=>(e.openBlock(),e.createBlock(P.default,{key:p._id,editable:!1,product:p},null,8,["product"]))),128))]),e.createElementVNode("div",Ce,[e.createElementVNode("div",Be,[De,e.createElementVNode("p",null,e.toDisplayString(e.unref(k))+" "+e.toDisplayString(t.returnCurrency()),1)]),e.createElementVNode("div",Oe,[qe,e.createElementVNode("p",null,e.toDisplayString(t.returnCurrency())+" "+e.toDisplayString(Math.trunc(100+20*((x=n.value[0])==null?void 0:x.distance)-7,5*(((C=n.value[0])==null?void 0:C.distance)/10))),1)]),e.createElementVNode("div",Pe,[Ie,e.createElementVNode("p",Me,e.toDisplayString(t.returnCurrency())+" "+e.toDisplayString(Math.trunc(100+20*((B=n.value[0])==null?void 0:B.distance)-7,5*(((D=n.value[0])==null?void 0:D.distance)/10))+e.unref(k)),1)])]),ze,e.createVNode(R.default,{username:e.unref(_).name==="Order Status"?((O=s.value.user)==null?void 0:O.name)||"User":"Weeder Support",chatID:e.unref(_).params.order,class:"radius-semi bg-white o-hidden"},null,8,["username","chatID"])])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},Fe=j.default(Te,[["__scopeId","data-v-36d45d04"]]);exports.default=Fe;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),C=require("vue-router"),O=require("../../../../../node_modules/@vuepic/vue-datepicker/dist/vue-datepicker.cjs");require("../../../../../node_modules/@vuepic/vue-datepicker/dist/main.css.cjs");require("../../../../components/Tab/Tab.vue.cjs");const P=require("../../../../components/Popup/Popup.vue.cjs"),I=require("../../../icons/entities/IconTime.vue.cjs"),B=require("../blocks/CardOrderItem.vue.cjs"),z=require("../../../organizations/components/blocks/CardOrganization.vue.cjs"),M=require("../../../chats/components/pages/ChatPage.vue.cjs"),F=require("../blocks/StatusHistory.vue.cjs"),L=require("../../../globals/store/globals.cjs"),d=require("../../store/orders.cjs"),R=require("../../../products/store/products.cjs"),T=require("../../../organizations/store/organizations.cjs");require("./OrderBackoffice.vue2.cjs");const A=require("../../../../../../_virtual/_plugin-vue_export-helper.cjs"),r=b=>(e.pushScopeId("data-v-ec5fc79c"),b=b(),e.popScopeId(),b),H={key:0,class:"pd-thin"},U={key:0,class:"mn-b-thin pos-relative w-100 bg-main radius-big pd-medium"},W={class:"mn-b-small flex-nowrap flex"},j={class:"t-medium p-medium"},G={class:"p-small t-transp"},J={class:"flex-nowrap flex gap-thin pos-relative"},K={class:"bg-grey mn-b-thin pd-thin radius-extra flex-nowrap flex"},Q={class:"w-max flex-v-center gap-thin flex-nowrap flex pd-thin radius-small bg-white-transp-20"},X={class:"t-medium mn-r-auto"},Y=r(()=>e.createElementVNode("span",{class:"p-small t-transp"},"Estimated Arrival",-1)),Z=r(()=>e.createElementVNode("br",null,null,-1)),$=r(()=>e.createElementVNode("p",{class:"t-medium p-medium mn-b-thin"}," Positions ",-1)),ee={class:"bg-grey pd-small radius-small flex gap-thin flex-column mn-b-semi"},te={key:1,class:"gap-thin cols-2"},se={class:"w-100"},ae={class:"mn-b-thin bg-grey w-100 o-hidden radius-medium"},re={class:"pd-small flex-nowrap flex"},le={class:"mn-r-auto"},ne=r(()=>e.createElementVNode("span",{class:"d-block t-medium p-medium"},"Order is",-1)),oe=r(()=>e.createElementVNode("span",{class:"t-lh-075 h2 d-block mn-b-small"},"created",-1)),ie={class:"pd-t-nano pd-b-nano pd-r-thin pd-l-thin radius-extra bg-black t-white w-max"},ce={class:"pd-small cols-2 br-t br-black-transp-10 br-solid"},de=r(()=>e.createElementVNode("p",{class:"w-100 t-medium p-medium"}," Phone ",-1)),ue={class:"w-100 t-right"},me={class:"pd-small cols-2 br-t br-black-transp-10 br-solid"},pe=r(()=>e.createElementVNode("p",{class:"t-medium p-medium"}," Address ",-1)),_e={class:"w-100 t-right"},he={class:"pd-small cols-2 br-t br-black-transp-10 br-solid"},be=r(()=>e.createElementVNode("p",{class:"mn-b-small t-medium p-medium"}," Delivery ",-1)),ve={class:"w-100 t-right mn-b-small"},ge={key:2,class:"t-transp"},fe={class:"bg-grey radius-big pd-medium mn-r-bold pd-r-big br-right-dark w-100"},Ne=r(()=>e.createElementVNode("h3",{class:"mn-b-small"},"Order Summary",-1)),Ve={class:"flex gap-thin flex-column mn-b-semi"},ye={class:"mn-b-medium radius-small br-solid br-1px br-black-transp-10 w-100"},Ee={class:"pd-small br-solid br-b br-black-transp-10 flex"},ke=r(()=>e.createElementVNode("p",{class:"mn-r-auto t-transp"},"In total",-1)),we={class:"pd-small br-solid br-b br-black-transp-10 flex"},Se=r(()=>e.createElementVNode("p",{class:"mn-r-auto t-transp"},"Delivery",-1)),xe={class:"pd-small flex-bottom flex"},Ce=r(()=>e.createElementVNode("p",{class:"mn-r-auto t-transp"},"In total to pay",-1)),Be={class:"p-big t-semi"},De=r(()=>e.createElementVNode("h3",{class:"mn-b-small"},"Chat With Us",-1)),qe={__name:"OrderBackoffice",setup(b){C.useRouter();const _=C.useRoute(),s=e.ref(null),v=e.ref(null),n=e.ref(null),o=["created","confirmed","packing","in delivery","delivered"],V=["Created","Confirmed","Packing","In Delivery","Delivered"],g=t=>o.slice(t).includes(s.value.status),f=e.ref(!1),y=e.ref(null),N=e.ref([]);function D(t){f.value=!0,typeof t=="number"&&(y.value=t)}function E(){f.value=!1,y.value=null}e.onMounted(async()=>{var a,l;s.value=await d.actions.read({_id:_.params.order}),s.value=s.value[0],v.value=await R.actions.read({organization:s.value.owner.target._id,limit:1e3}),console.log(v.value);const t=v.value.reduce((u,m)=>(u[m._id]=m,u),{});console.log(t),N.value=s.value.positions.map(({_id:u,quantity:m})=>{const p=t[u];return{name:p.name,images:p.images,price:p.price,_id:p._id,quantity:m}}),n.value=await T.actions.read({_id:(a=s.value)==null?void 0:a.owner.target._id,location:(l=L.state.position)==null?void 0:l.location})});let k=e.computed(()=>{var t;return Number((t=s.value)==null?void 0:t.positions.reduce((a,l)=>a+l.price*l.quantity,0))});e.computed(()=>{var t;return Number((t=s.value)==null?void 0:t.positions.reduce((a,l)=>a+l.quantity,0))});function h(t){const a=o.indexOf(t);return a!==-1&&a+1<o.length?o[a+1]:null}function w(t){const a=o.indexOf(t);return t?V[a]:""}async function q(){const t=h(d.state.current.status);t?(d.state.current.status=t,await d.actions.update(d.state.current)):console.error("Next status is void. Must handle somehow."),E()}return(t,a)=>{var l,u,m,p,S,x;return s.value&&n.value?(e.openBlock(),e.createElementBlock("div",H,[s.value?(e.openBlock(),e.createElementBlock("div",U,[e.createElementVNode("div",W,[e.createElementVNode("p",j,[e.createTextVNode(" Order No: "),e.createElementVNode("span",G,"#"+e.toDisplayString(s.value._id),1)])]),e.createElementVNode("div",J,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(o,(i,c)=>e.createElementVNode("div",{key:c,class:"w-20"},[e.createElementVNode("div",{class:e.normalizeClass(["bg-grey br-anim br-glow radius-extra h-1r w-100",{"br-glow-anim":g(c)},{"t-transp":!g(c)},{blink:s.value.status===o[c]&&h(s.value.status)}])},null,2),e.createElementVNode("div",{class:e.normalizeClass([{"t-transp":!g(c)},"mn-t-thin p-small t-medium uppercase"])},e.toDisplayString(V[c]),3)])),64))])])):e.createCommentVNode("",!0),e.createElementVNode("div",K,[e.createElementVNode("div",Q,[e.createVNode(I.default,{class:"i-semi t-transp",fill:"rgb(var(--black)"}),e.createElementVNode("p",X,[Y,Z,e.createTextVNode(e.toDisplayString(t.formatDate(s.value.deadline)),1)])]),h(s.value.status)&&e.unref(_).name==="Order Edit"?(e.openBlock(),e.createElementBlock("button",{key:0,onClick:D,class:"mn-l-auto bg-black t-white button"}," Mark as "+e.toDisplayString(w(h(s.value.status))),1)):e.createCommentVNode("",!0)]),e.createVNode(P.default,{title:"Change status",onClosePopup:E,isPopupOpen:f.value,class:"bg-white w-min-30r w-max-30r radius-big pd-big"},{default:e.withCtx(()=>[e.createVNode(e.unref(O.default),{modelValue:s.value.deadline,"onUpdate:modelValue":a[0]||(a[0]=i=>s.value.deadline=i),"hide-navigation":["calendar"],flow:["time"],class:"z-index-3 bg-grey radius-small pd-small mn-b-thin mn-b-semi"},null,8,["modelValue"]),$,e.createElementVNode("ul",ee,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(N.value,(i,c)=>(e.openBlock(),e.createBlock(B.default,{key:i._id,editable:!1,product:i},null,8,["product"]))),128))]),e.createElementVNode("button",{onClick:q,class:"w-100 bg-black-small t-white button"},e.toDisplayString("Confirm Changing to "+w(h(s.value.status))),1)]),_:1},8,["isPopupOpen"]),s.value?(e.openBlock(),e.createElementBlock("div",te,[e.createElementVNode("div",se,[n.value[0]?(e.openBlock(),e.createBlock(z.default,{key:0,organization:n.value[0],showRating:!0,showFollowers:!1,showProducts:!1,class:"bg-grey mn-b-thin w-100 o-hidden radius-big pd-small"},null,8,["organization"])):e.createCommentVNode("",!0),e.createElementVNode("div",ae,[e.createElementVNode("div",re,[e.createElementVNode("div",le,[ne,oe,e.createElementVNode("p",ie,e.toDisplayString(t.formatDate(s.value.createdAt)),1)])]),e.createElementVNode("div",ce,[de,e.createElementVNode("p",ue,e.toDisplayString(((l=s.value.customer.target)==null?void 0:l.number)||"Not specified"),1)]),e.createElementVNode("div",me,[pe,e.createElementVNode("p",_e,e.toDisplayString(s.value.delivery.address?s.value.delivery.address.slice(0,64):"Not specified"),1)]),e.createElementVNode("div",he,[be,e.createElementVNode("p",ve,e.toDisplayString(s.value.delivery.type?s.value.delivery.type:"Not specified"),1)])]),d.state.current.status_history?(e.openBlock(),e.createBlock(F.default,{key:1,statuses:o,statusHistory:d.state.current.status_history,statusCurrent:d.state.current.status,edit:e.unref(_).name==="Order Edit"},null,8,["statusHistory","statusCurrent","edit"])):e.createCommentVNode("",!0),t.payment&&t.payment.Status==="CONFIRMED"?(e.openBlock(),e.createElementBlock("span",ge,"Paid")):e.createCommentVNode("",!0)]),e.createElementVNode("div",fe,[Ne,e.createElementVNode("ul",Ve,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(N.value,(i,c)=>(e.openBlock(),e.createBlock(B.default,{key:i._id,editable:!1,product:i},null,8,["product"]))),128))]),e.createElementVNode("div",ye,[e.createElementVNode("div",Ee,[ke,e.createElementVNode("p",null,e.toDisplayString(e.unref(k))+" "+e.toDisplayString(t.returnCurrency()),1)]),e.createElementVNode("div",we,[Se,e.createElementVNode("p",null,e.toDisplayString(t.returnCurrency())+" "+e.toDisplayString(Math.trunc(100+20*((u=n.value[0])==null?void 0:u.distance)-7,5*(((m=n.value[0])==null?void 0:m.distance)/10))),1)]),e.createElementVNode("div",xe,[Ce,e.createElementVNode("p",Be,e.toDisplayString(t.returnCurrency())+" "+e.toDisplayString(Math.trunc(100+20*((p=n.value[0])==null?void 0:p.distance)-7,5*(((S=n.value[0])==null?void 0:S.distance)/10))+e.unref(k)),1)])]),De,e.createVNode(M.default,{username:e.unref(_).name==="Order Status"?((x=s.value.user)==null?void 0:x.name)||"User":"Weeder Support",chatID:e.unref(_).params.order,class:"radius-semi bg-white o-hidden"},null,8,["username","chatID"])])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},Oe=A.default(qe,[["__scopeId","data-v-ec5fc79c"]]);exports.default=Oe;