@quoreadmin/ui 1.6.8 → 1.7.0

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 (189) hide show
  1. package/dist/index.css +1 -1
  2. package/dist/index13.js +7 -7
  3. package/dist/index140.js +559 -409
  4. package/dist/index175.js +4 -4
  5. package/dist/index182.js +7 -7
  6. package/dist/index187.js +17 -17
  7. package/dist/index190.js +21 -21
  8. package/dist/index191.js +1 -1
  9. package/dist/index192.js +1 -1
  10. package/dist/index195.js +2 -2
  11. package/dist/index197.js +14 -14
  12. package/dist/index198.js +1 -1
  13. package/dist/index199.js +1 -1
  14. package/dist/index200.js +3 -3
  15. package/dist/index201.js +6 -6
  16. package/dist/index208.js +2 -2
  17. package/dist/index209.js +1 -1
  18. package/dist/index210.js +1 -1
  19. package/dist/index211.js +1 -1
  20. package/dist/index212.js +1 -1
  21. package/dist/index213.js +4 -4
  22. package/dist/index215.js +4 -4
  23. package/dist/index218.js +1 -1
  24. package/dist/index219.js +1 -1
  25. package/dist/index222.js +1 -1
  26. package/dist/index223.js +1 -1
  27. package/dist/index224.js +1 -1
  28. package/dist/index225.js +1 -1
  29. package/dist/index226.js +1 -1
  30. package/dist/index227.js +159 -159
  31. package/dist/index228.js +228 -20
  32. package/dist/index229.js +36 -21
  33. package/dist/index230.js +9 -198
  34. package/dist/index231.js +140 -49
  35. package/dist/index232.js +20 -34
  36. package/dist/index233.js +21 -39
  37. package/dist/index234.js +198 -21
  38. package/dist/index235.js +69 -21
  39. package/dist/index236.js +34 -20
  40. package/dist/index237.js +27 -823
  41. package/dist/index238.js +21 -701
  42. package/dist/index239.js +22 -176
  43. package/dist/index240.js +13 -15
  44. package/dist/index241.js +836 -20
  45. package/dist/index242.js +701 -19
  46. package/dist/index243.js +176 -3
  47. package/dist/index244.js +21 -186
  48. package/dist/index245.js +19 -132
  49. package/dist/index246.js +20 -1223
  50. package/dist/index247.js +3 -20
  51. package/dist/index248.js +186 -21
  52. package/dist/index249.js +132 -21
  53. package/dist/index250.js +1223 -29
  54. package/dist/index251.js +12 -12
  55. package/dist/index252.js +15 -13
  56. package/dist/index253.js +22 -2
  57. package/dist/index254.js +29 -2
  58. package/dist/index255.js +20 -3632
  59. package/dist/index256.js +20 -55
  60. package/dist/index257.js +2 -77
  61. package/dist/index258.js +2 -52
  62. package/dist/index259.js +3599 -182
  63. package/dist/index260.js +53 -8
  64. package/dist/index261.js +60 -40
  65. package/dist/index262.js +35 -44
  66. package/dist/index263.js +193 -32
  67. package/dist/index264.js +9 -74
  68. package/dist/index265.js +38 -704
  69. package/dist/index266.js +44 -22
  70. package/dist/index267.js +36 -46
  71. package/dist/index268.js +74 -10
  72. package/dist/index269.js +698 -680
  73. package/dist/index270.js +37 -818
  74. package/dist/index271.js +63 -160
  75. package/dist/index272.js +10 -227
  76. package/dist/index273.js +704 -36
  77. package/dist/index274.js +819 -9
  78. package/dist/index279.js +3 -2
  79. package/dist/index280.js +25 -77
  80. package/dist/index281.js +2 -3
  81. package/dist/index282.js +77 -25
  82. package/dist/index283.js +230 -49
  83. package/dist/index284.js +5 -25
  84. package/dist/index285.js +133 -21
  85. package/dist/index286.js +67 -21
  86. package/dist/index287.js +85 -14
  87. package/dist/index288.js +29 -17
  88. package/dist/index289.js +8 -22
  89. package/dist/index290.js +64 -1507
  90. package/dist/index291.js +3 -385
  91. package/dist/index292.js +2 -2731
  92. package/dist/index293.js +77 -80
  93. package/dist/index294.js +53 -3769
  94. package/dist/index295.js +4 -58
  95. package/dist/index296.js +4 -78
  96. package/dist/index297.js +178 -21
  97. package/dist/index298.js +56 -928
  98. package/dist/index299.js +75 -22
  99. package/dist/index300.js +53 -19
  100. package/dist/index301.js +18 -12
  101. package/dist/index302.js +21 -68
  102. package/dist/index303.js +21 -18
  103. package/dist/index304.js +11 -14
  104. package/dist/index305.js +17 -22
  105. package/dist/index306.js +23 -22
  106. package/dist/index307.js +68 -52
  107. package/dist/index308.js +22 -15
  108. package/dist/index309.js +923 -72
  109. package/dist/index310.js +22 -202
  110. package/dist/index311.js +20 -246
  111. package/dist/index312.js +19 -234
  112. package/dist/index313.js +68 -5
  113. package/dist/index314.js +18 -133
  114. package/dist/index315.js +19 -68
  115. package/dist/index316.js +20 -85
  116. package/dist/index317.js +21 -28
  117. package/dist/index318.js +62 -8
  118. package/dist/index319.js +1507 -64
  119. package/dist/index320.js +385 -3
  120. package/dist/index321.js +2731 -2
  121. package/dist/index322.js +80 -77
  122. package/dist/index323.js +3769 -53
  123. package/dist/index324.js +58 -4
  124. package/dist/index325.js +15 -5
  125. package/dist/index326.js +71 -166
  126. package/dist/index327.js +196 -57
  127. package/dist/index328.js +246 -75
  128. package/dist/index329.js +8 -36
  129. package/dist/index330.js +12 -8
  130. package/dist/index331.js +54 -12
  131. package/dist/index332.js +9 -52
  132. package/dist/index333.js +13 -11
  133. package/dist/index334.js +53 -9
  134. package/dist/index335.js +49 -55
  135. package/dist/index336.js +28 -49
  136. package/dist/index337.js +2 -31
  137. package/dist/index338.js +5 -2
  138. package/dist/index339.js +2 -5
  139. package/dist/index340.js +23 -2
  140. package/dist/index341.js +39 -21
  141. package/dist/index342.js +2 -41
  142. package/dist/index343.js +11 -2
  143. package/dist/index344.js +20 -11
  144. package/dist/index345.js +15 -18
  145. package/dist/index346.js +9 -16
  146. package/dist/index347.js +9 -9
  147. package/dist/index348.js +2 -10
  148. package/dist/index349.js +9 -2
  149. package/dist/index350.js +10 -9
  150. package/dist/index351.js +14 -10
  151. package/dist/index352.js +37 -14
  152. package/dist/index353.js +20 -19
  153. package/dist/index354.js +55 -19
  154. package/dist/index355.js +28 -63
  155. package/dist/index356.js +7 -37
  156. package/dist/index357.js +49 -18
  157. package/dist/index358.js +6 -56
  158. package/dist/index359.js +10 -27
  159. package/dist/index360.js +7 -7
  160. package/dist/index361.js +27 -51
  161. package/dist/index362.js +2 -6
  162. package/dist/index363.js +69 -11
  163. package/dist/index364.js +166 -6
  164. package/dist/index365.js +20 -28
  165. package/dist/index366.js +20 -2
  166. package/dist/index367.js +61 -67
  167. package/dist/index368.js +36 -166
  168. package/dist/index369.js +28 -98
  169. package/dist/index370.js +10 -90
  170. package/dist/index371.js +4 -17
  171. package/dist/index372.js +4 -98
  172. package/dist/index373.js +12 -30
  173. package/dist/index374.js +7 -11
  174. package/dist/index375.js +11 -3
  175. package/dist/index376.js +4 -3
  176. package/dist/index377.js +33 -13
  177. package/dist/index378.js +31 -7
  178. package/dist/index379.js +28 -12
  179. package/dist/index380.js +61 -5
  180. package/dist/index381.js +17 -33
  181. package/dist/index382.js +99 -29
  182. package/dist/index383.js +91 -28
  183. package/dist/index384.js +96 -59
  184. package/dist/index385.js +1 -1
  185. package/dist/index390.js +1 -1
  186. package/dist/index391.js +2 -2
  187. package/dist/index43.js +394 -282
  188. package/dist/src/components/room-details-popover/room-details-popover.d.ts +51 -4870
  189. package/package.json +1 -1
package/dist/index140.js CHANGED
@@ -1,31 +1,31 @@
1
- import { defineComponent as Ke, ref as i, computed as h, watch as F, onMounted as Ve, onUnmounted as Ze } from "vue";
2
- import { useI18n as et } from "vue-i18n";
3
- import { DateTime as y } from "./index163.js";
1
+ import { defineComponent as dt, ref as l, computed as y, watch as x, onMounted as mt, onUnmounted as pt } from "vue";
2
+ import { useI18n as vt } from "vue-i18n";
3
+ import { DateTime as w } from "./index163.js";
4
4
  import "./index186.js";
5
- import tt from "./index2.js";
6
- import at from "./index3.js";
7
- import ot from "./index13.js";
8
- import st from "./index21.js";
9
- import nt from "./index28.js";
10
- import lt from "./index39.js";
11
- import rt from "./index20.js";
12
- import ut from "./index46.js";
13
- import it from "./index47.js";
14
- import ct from "./index49.js";
15
- import G from "./index187.js";
16
- const Ot = Ke({
5
+ import ft from "./index2.js";
6
+ import ht from "./index3.js";
7
+ import yt from "./index4.js";
8
+ import gt from "./index21.js";
9
+ import wt from "./index28.js";
10
+ import _t from "./index39.js";
11
+ import It from "./index20.js";
12
+ import kt from "./index46.js";
13
+ import Dt from "./index47.js";
14
+ import Tt from "./index49.js";
15
+ import z from "./index187.js";
16
+ const Ft = dt({
17
17
  name: "QRoomDetailsPopover",
18
18
  components: {
19
- QAccordion: tt,
20
- QActivityItem: at,
21
- QCommentSection: ot,
22
- QDatePicker: rt,
23
- QDivider: st,
24
- QIcon: nt,
25
- QPopover: lt,
26
- QTag: ut,
27
- QTextarea: it,
28
- QTooltip: ct
19
+ QAccordion: ft,
20
+ QActivityItem: ht,
21
+ QAvatar: yt,
22
+ QDatePicker: It,
23
+ QDivider: gt,
24
+ QIcon: wt,
25
+ QPopover: _t,
26
+ QTag: kt,
27
+ QTextarea: Dt,
28
+ QTooltip: Tt
29
29
  },
30
30
  props: {
31
31
  id: {
@@ -128,6 +128,11 @@ const Ot = Ke({
128
128
  type: Array,
129
129
  default: () => []
130
130
  },
131
+ /** Whether this is a test environment (enables simulation features) */
132
+ isTestEnvironment: {
133
+ type: Boolean,
134
+ default: !1
135
+ },
131
136
  /** Set if the popover is teleported to the body (escapes overflow clipping) */
132
137
  teleport: {
133
138
  type: Boolean,
@@ -139,25 +144,25 @@ const Ot = Ke({
139
144
  default: "body"
140
145
  }
141
146
  },
142
- emits: ["create:callback", "create:todo", "refresh:pms", "toggle"],
143
- setup(s, { emit: I }) {
144
- const { t: v } = et(), r = i(null), K = i(!1), V = i("left"), j = i([
147
+ emits: ["create:callback", "create:todo", "refresh:pms", "show:toast", "toggle"],
148
+ setup(n, { emit: h }) {
149
+ const { t: p } = vt(), u = l(null), ue = l(!1), ie = l("left"), K = l([
145
150
  {
146
151
  id: 1,
147
- label: v("HC_DEPARTMENT")
152
+ label: p("HC_DEPARTMENT")
148
153
  // need to localize
149
154
  },
150
155
  {
151
156
  id: 2,
152
- label: v("HC_PERSON")
157
+ label: p("HC_PERSON")
153
158
  // need to localize
154
159
  },
155
160
  {
156
161
  id: 0,
157
- label: v("HC_ANYONE")
162
+ label: p("HC_ANYONE")
158
163
  // need to localize
159
164
  }
160
- ]), T = i(""), p = i({
165
+ ]), S = l(""), v = l({
161
166
  checkInDate: /* @__PURE__ */ new Date(),
162
167
  checkOutDate: /* @__PURE__ */ new Date(),
163
168
  guestEmail: "",
@@ -165,19 +170,19 @@ const Ot = Ke({
165
170
  guestMood: null,
166
171
  guestName: "",
167
172
  guestPhone: "",
168
- inHouse: !!r.value?.tokenId || !1,
173
+ inHouse: !!u.value?.tokenId || !1,
169
174
  problem: null,
170
175
  notes: "",
171
- tokenId: r.value?.tokenId
172
- }), H = i(250), B = i(290), C = i([]), ce = i([]), Z = i(!0), U = i(!0), E = i({
176
+ tokenId: u.value?.tokenId
177
+ }), F = l(250), G = l(290), N = l([]), _e = l([]), X = l(!0), Z = l(!0), A = l({
173
178
  info: !0,
174
179
  tickets: !0,
175
180
  comments: !0
176
- }), Q = i(!0), we = i(s.guestDetails), w = i([]), b = i({
181
+ }), ee = l(!0), Se = l(n.guestDetails), D = l([]), M = l({
177
182
  pms: !1,
178
183
  roomNotices: !1,
179
184
  tickets: !1
180
- }), ee = i([]), te = i([]), ae = i("bottom"), R = i(null), S = i(!1), N = i(!1), O = i(null), u = i({
185
+ }), C = l([]), ce = l([]), de = l("bottom"), te = l(null), R = l(!1), W = l(!1), U = l(""), me = l(!1), E = l(!1), T = l(null), j = l(null), Me = 3e4, i = l({
181
186
  assignType: null,
182
187
  department: null,
183
188
  due: /* @__PURE__ */ new Date(),
@@ -187,40 +192,40 @@ const Ot = Ke({
187
192
  requestedBy: null,
188
193
  when: null,
189
194
  where: null
190
- }), P = i([
195
+ }), $ = l([
191
196
  {
192
197
  id: 0,
193
- label: v("HC_STAFF_MEMBER")
198
+ label: p("HC_STAFF_MEMBER")
194
199
  // need to localize
195
200
  },
196
201
  {
197
202
  id: 1,
198
- label: v("HC_HOTEL_GUEST")
203
+ label: p("HC_HOTEL_GUEST")
199
204
  // need to localize
200
205
  }
201
- ]), _e = i(!1), k = i(null), g = i({
206
+ ]), Ce = l(!1), b = l(null), _ = l({
202
207
  endDate: /* @__PURE__ */ new Date(),
203
208
  issue: null,
204
209
  notes: "",
205
210
  startDate: /* @__PURE__ */ new Date()
206
- }), $ = i([]), J = i(!1), D = i([]), L = i([]), ke = i([
211
+ }), ae = l([]), se = l(!1), O = l([]), H = l([]), Ne = l([
207
212
  {
208
- label: v("HC_COMPLAINT"),
213
+ label: p("HC_COMPLAINT"),
209
214
  id: "complaint"
210
215
  },
211
216
  {
212
- label: v("HC_REQUEST"),
217
+ label: p("HC_REQUEST"),
213
218
  id: "request"
214
219
  },
215
220
  {
216
- label: v("HC_ROOM_NOTICE"),
221
+ label: p("HC_ROOM_NOTICE"),
217
222
  id: "room_notice"
218
223
  },
219
224
  {
220
- label: v("HC_WORK_ORDER"),
225
+ label: p("HC_WORK_ORDER"),
221
226
  id: "work_order"
222
227
  }
223
- ]), x = i(), M = i(null), d = i({
228
+ ]), Q = l(), P = l(null), m = l({
224
229
  assignType: null,
225
230
  department: null,
226
231
  due: /* @__PURE__ */ new Date(),
@@ -229,8 +234,8 @@ const Ot = Ke({
229
234
  notes: "",
230
235
  person: null,
231
236
  requestedBy: null
232
- }), oe = i([]), q = i([]), A = i([]), se = h(() => {
233
- switch (r.value.cleaning?.name) {
237
+ }), pe = l([]), q = l([]), L = l([]), ve = y(() => {
238
+ switch (u.value.cleaning?.name) {
234
239
  case "CLEAN":
235
240
  case "INSPECTED":
236
241
  return "CLEAN";
@@ -242,124 +247,178 @@ const Ot = Ke({
242
247
  default:
243
248
  return "";
244
249
  }
245
- }), De = h(() => se.value === "CLEAN" ? "blue-10" : se.value === "DIRTY" ? "red-10" : "gray-30"), Ie = h(() => v(`HC_${r.value.cleaning?.name}`) || ""), Te = h(() => {
246
- const e = T.value.toLowerCase();
247
- return s.quickReplies.filter((a) => a.toLowerCase().match(e));
248
- }), de = h(() => D.value.length ? !!D.value.find(
250
+ }), Ae = y(() => ve.value === "CLEAN" ? "blue-10" : ve.value === "DIRTY" ? "red-10" : "gray-30"), Re = y(() => p(`HC_${u.value.cleaning?.name}`) || ""), He = y(() => {
251
+ const e = S.value.toLowerCase();
252
+ return n.quickReplies.filter((a) => a.toLowerCase().match(e));
253
+ }), Pe = y(() => {
254
+ if (!C.value.length) return [];
255
+ const e = [];
256
+ let a = null;
257
+ return C.value.forEach((t) => {
258
+ const s = w.fromFormat(
259
+ t.dateUtc,
260
+ "yyyy-MM-dd HH:mm:ss",
261
+ { zone: "utc" }
262
+ ).setZone(n.propertyTimeZone), o = s.toFormat("yyyy-MM-dd-HH");
263
+ o !== a && (e.push({
264
+ type: "separator",
265
+ label: s.toFormat("ccc, LLL d 'at' h:mma").replace("AM", "am").replace("PM", "pm"),
266
+ hourKey: o
267
+ }), a = o), e.push({
268
+ type: "message",
269
+ ...t,
270
+ formattedTime: s.toFormat("h:mma").replace("AM", "am").replace("PM", "pm")
271
+ });
272
+ }), e;
273
+ }), Ie = y(() => O.value.length ? !!O.value.find(
249
274
  (a) => a.type === "complaint"
250
- ) : !1), be = h(() => D.value.length ? !!D.value.find(
275
+ ) : !1), qe = y(() => O.value.length ? !!O.value.find(
251
276
  (a) => a.type === "callback"
252
- ) : !1), Oe = h(() => {
277
+ ) : !1), Le = y(() => {
253
278
  let e = [];
254
- return w.value[0] && w.value[0].options === void 0 ? w.value.forEach((a) => {
279
+ return D.value[0] && D.value[0].options === void 0 ? D.value.forEach((a) => {
255
280
  e.push({
256
281
  id: parseInt(a.id),
257
282
  label: a.display_name
258
283
  });
259
- }) : e = w.value, e;
260
- }), me = h(() => r.value.occupancy?.name === "OCCUPIED"), Ce = h(() => me.value && de.value ? "HK_ROOM_STATUS_Occupied_Complaint" : "HK_ROOM_STATUS_Occupied"), Ee = h(() => {
261
- switch (k.value?.id) {
284
+ }) : e = D.value, e;
285
+ }), ke = y(() => u.value.occupancy?.name === "OCCUPIED"), Be = y(() => ke.value && Ie.value ? "HK_ROOM_STATUS_Occupied_Complaint" : "HK_ROOM_STATUS_Occupied"), xe = y(() => {
286
+ switch (b.value?.id) {
262
287
  case "request":
263
288
  case "work_order":
264
- return j.value[0];
289
+ return K.value[0];
265
290
  default:
266
291
  return null;
267
292
  }
268
- }), Me = h(() => {
269
- if (C.value)
270
- switch (k.value?.id) {
293
+ }), Fe = y(() => {
294
+ if (N.value)
295
+ switch (b.value?.id) {
271
296
  case "request":
272
- return C.value.find((e) => parseInt(e.id) === 4);
297
+ return N.value.find((e) => parseInt(e.id) === 4);
273
298
  case "work_order":
274
- return C.value.find((e) => parseInt(e.id) === 2);
299
+ return N.value.find((e) => parseInt(e.id) === 2);
275
300
  default:
276
301
  return null;
277
302
  }
278
303
  return null;
279
- }), Re = h(() => {
280
- switch (k.value?.id) {
304
+ }), Ge = y(() => {
305
+ switch (b.value?.id) {
281
306
  case "request":
282
- return P.value[1];
307
+ return $.value[1];
283
308
  case "work_order":
284
- return P.value[0];
309
+ return $.value[0];
285
310
  default:
286
311
  return null;
287
312
  }
288
- }), Se = h(() => {
313
+ }), We = y(() => {
289
314
  let e = "";
290
- if (r.value && r.value.reservations[0]) {
291
- const a = y.fromISO(
292
- r.value.reservations[0].arrivalDate
293
- ), t = a.toFormat("MMM"), o = a.day, n = a.year, l = y.fromISO(
294
- r.value.reservations[0].departureDate
295
- ), c = l.toFormat("MMM"), m = l.day, f = l.year;
296
- e += t + " " + o, n !== f && (e += ", " + n), t === c ? e += "-" + m : e += " - " + c + " " + m, e += ", " + f;
315
+ if (u.value && u.value.reservations[0]) {
316
+ const a = w.fromISO(
317
+ u.value.reservations[0].arrivalDate
318
+ ), t = a.toFormat("MMM"), s = a.day, o = a.year, r = w.fromISO(
319
+ u.value.reservations[0].departureDate
320
+ ), c = r.toFormat("MMM"), d = r.day, f = r.year;
321
+ e += t + " " + s, o !== f && (e += ", " + o), t === c ? e += "-" + d : e += " - " + c + " " + d, e += ", " + f;
297
322
  }
298
323
  return e;
299
- }), Ne = h(() => {
300
- let e = $.value;
324
+ }), Ue = y(() => {
325
+ let e = ae.value;
301
326
  return e = [...new Set(e)], e;
302
- }), qe = h(() => {
303
- const e = k.value?.id;
327
+ }), je = y(() => {
328
+ const e = b.value?.id;
304
329
  if (!e)
305
330
  return !1;
306
331
  switch (e) {
307
332
  case "room_notice":
308
- return g.value.issue && g.value.startDate && g.value.endDate;
333
+ return _.value.issue && _.value.startDate && _.value.endDate;
309
334
  case "complaint":
310
- return p.value.problem && p.value.guestName && p.value.guestMood;
335
+ return v.value.problem && v.value.guestName && v.value.guestMood;
311
336
  case "work_order":
312
- return d.value.item && d.value.issue && d.value.requestedBy && d.value.due && (d.value.assignType && d.value.assignType.id === 0 || d.value.assignType && d.value.assignType.id === 1 && d.value.department || d.value.assignType && d.value.assignType.id === 2 && d.value.person);
337
+ return m.value.item && m.value.issue && m.value.requestedBy && m.value.due && (m.value.assignType && m.value.assignType.id === 0 || m.value.assignType && m.value.assignType.id === 1 && m.value.department || m.value.assignType && m.value.assignType.id === 2 && m.value.person);
313
338
  case "request": {
314
- const a = u.value.item && u.value.requestedBy && u.value.due && (u.value.assignType && u.value.assignType.id === 0 || u.value.assignType && u.value.assignType.id === 1 && u.value.department || u.value.assignType && u.value.assignType.id === 2 && u.value.person), t = s.allowWhenWhere ? u.value.when && u.value.where : !0;
339
+ const a = i.value.item && i.value.requestedBy && i.value.due && (i.value.assignType && i.value.assignType.id === 0 || i.value.assignType && i.value.assignType.id === 1 && i.value.department || i.value.assignType && i.value.assignType.id === 2 && i.value.person), t = n.allowWhenWhere ? i.value.when && i.value.where : !0;
315
340
  return a && t;
316
341
  }
317
342
  default:
318
343
  return !1;
319
344
  }
320
- }), pe = () => {
321
- J.value = !1, S.value = !1, K.value = !1, w.value = [], te.value = [], oe.value = [], q.value = [], A.value = [], k.value = null, g.value.issue = null, g.value.startDate = /* @__PURE__ */ new Date(), g.value.endDate = /* @__PURE__ */ new Date(), g.value.notes = "", p.value.guestName = "", p.value.guestEmail = "", p.value.guestPhone = "", p.value.guestMood = null, p.value.guestLoyalty = "", p.value.problem = null, p.value.checkInDate = /* @__PURE__ */ new Date(), p.value.checkOutDate = /* @__PURE__ */ new Date(), p.value.notes = "", d.value.assignType = null, d.value.department = null, d.value.person = null, d.value.due = /* @__PURE__ */ new Date(), d.value.item = null, d.value.issue = null, d.value.notes = "", u.value.assignType = null, u.value.department = null, u.value.person = null, u.value.due = /* @__PURE__ */ new Date(), u.value.item = null, u.value.notes = "", u.value.when = null, u.value.where = null;
322
- }, Ae = async () => {
323
- I("create:callback", r.value), I("toggle", !1);
324
- }, Y = (e) => {
345
+ }), De = () => {
346
+ se.value = !1, R.value = !1, ue.value = !1, D.value = [], ce.value = [], pe.value = [], q.value = [], L.value = [], b.value = null, _.value.issue = null, _.value.startDate = /* @__PURE__ */ new Date(), _.value.endDate = /* @__PURE__ */ new Date(), _.value.notes = "", v.value.guestName = "", v.value.guestEmail = "", v.value.guestPhone = "", v.value.guestMood = null, v.value.guestLoyalty = "", v.value.problem = null, v.value.checkInDate = /* @__PURE__ */ new Date(), v.value.checkOutDate = /* @__PURE__ */ new Date(), v.value.notes = "", m.value.assignType = null, m.value.department = null, m.value.person = null, m.value.due = /* @__PURE__ */ new Date(), m.value.item = null, m.value.issue = null, m.value.notes = "", i.value.assignType = null, i.value.department = null, i.value.person = null, i.value.due = /* @__PURE__ */ new Date(), i.value.item = null, i.value.notes = "", i.value.when = null, i.value.where = null;
347
+ }, $e = async () => {
348
+ h("create:callback", u.value), h("toggle", !1);
349
+ }, B = (e) => {
325
350
  const a = [];
326
- (Array.isArray(e) ? e : Object.values(e)).forEach((o) => {
327
- const n = o.senderType || o.sender_type, l = o.senderName || "", c = o.senderId || o.sender_id, m = o.profileImg || o.profile_img, f = l ? l.split(" ") : ["", ""], X = o.user_first_name || o.guest_first_name || f[0] || "", Xe = o.user_last_name || o.guest_last_name || f.slice(1).join(" ") || "";
328
- let _ = {
329
- id: o.id,
330
- isPropertyEmployee: n === "user",
331
- isSent: !!o.sent,
332
- isSystemMessage: n === "system",
333
- message: o.content,
334
- timestamp: o.sent || o.created,
351
+ (Array.isArray(e) ? e : Object.values(e)).forEach((s) => {
352
+ const o = s.senderType || s.sender_type, r = s.senderName || "", c = s.senderId || s.sender_id, d = s.profileImg || s.profile_img, f = r ? r.split(" ") : ["", ""], g = s.user_first_name || s.guest_first_name || f[0] || "", V = s.user_last_name || s.guest_last_name || f.slice(1).join(" ") || "", re = g && V ? `${g} ${V}` : g || "Auto-Reply", le = o === "system" || o === "user", I = o === "guest";
353
+ let k = {
354
+ id: s.id,
355
+ isPropertyEmployee: o === "user",
356
+ isSent: !!s.sent,
357
+ isSystemMessage: o === "system",
358
+ isStaffMessage: le,
359
+ isGuestMessage: I,
360
+ comment: s.content,
361
+ dateUtc: s.sent || s.created,
335
362
  user: {
336
- firstName: X || "Auto-Reply",
363
+ firstName: g || "Auto-Reply",
337
364
  icon: "",
338
365
  id: c || "system-message",
339
366
  initials: "",
340
- lastName: Xe || "",
341
- src: m || ""
367
+ lastName: V || "",
368
+ name: re,
369
+ src: d || ""
342
370
  }
343
371
  };
344
- _.user.firstName && _.user.lastName ? _.user.initials = _.user.firstName[0] + _.user.lastName[0] : _.user.firstName && (_.user.initials = _.user.firstName[0]), _.isSystemMessage && (_.user.icon = "property-fill"), a.push(_);
345
- }), ee.value = a;
346
- }, ve = async () => {
347
- if (s.showComments && r.value.tokenId)
372
+ k.user.firstName && k.user.lastName ? k.user.initials = k.user.firstName[0] + k.user.lastName[0] : k.user.firstName && (k.user.initials = k.user.firstName[0]), le && (k.user.icon = "property-fill"), a.push(k);
373
+ }), C.value = a;
374
+ }, Qe = (e) => {
375
+ if (!e || e.length === 0) return;
376
+ (Array.isArray(e) ? e : Object.values(e)).forEach((t) => {
377
+ if (C.value.some((k) => k.id === t.id))
378
+ return;
379
+ const s = t.senderType || t.sender_type, o = t.senderName || "", r = t.senderId || t.sender_id, c = t.profileImg || t.profile_img, d = o ? o.split(" ") : ["", ""], f = t.user_first_name || t.guest_first_name || d[0] || "", g = t.user_last_name || t.guest_last_name || d.slice(1).join(" ") || "", V = f && g ? `${f} ${g}` : f || "Auto-Reply", re = s === "system" || s === "user", le = s === "guest";
380
+ let I = {
381
+ id: t.id,
382
+ isPropertyEmployee: s === "user",
383
+ isSent: !!t.sent,
384
+ isSystemMessage: s === "system",
385
+ isStaffMessage: re,
386
+ isGuestMessage: le,
387
+ comment: t.content,
388
+ dateUtc: t.sent || t.created,
389
+ user: {
390
+ firstName: f || "Auto-Reply",
391
+ icon: "",
392
+ id: r || "system-message",
393
+ initials: "",
394
+ lastName: g || "",
395
+ name: V,
396
+ src: c || ""
397
+ }
398
+ };
399
+ I.user.firstName && I.user.lastName ? I.user.initials = I.user.firstName[0] + I.user.lastName[0] : I.user.firstName && (I.user.initials = I.user.firstName[0]), re && (I.user.icon = "property-fill"), C.value.push(I);
400
+ });
401
+ }, fe = async (e = !1) => {
402
+ if (n.showComments && u.value.tokenId)
348
403
  try {
349
- let e = `/api/client/connect/getMessages.php?tokenId=${r.value.tokenId}`;
350
- O.value !== null && (e += `&lastMsgId=${O.value}`);
351
- const t = await (await fetch(e, {
404
+ let a = `/api/client/connect/getMessages.php?tokenId=${u.value.tokenId}`;
405
+ e && T.value !== null && (a += `&lastMsgId=${T.value}`);
406
+ const s = await (await fetch(a, {
352
407
  method: "GET",
353
408
  credentials: "include"
354
409
  })).json();
355
- if (t.status === "error")
356
- throw new Error(t.message || "Failed to get messages");
357
- N.value = !t.closed, t.messages && t.messages.length > 0 && (O.value = t.messages[t.messages.length - 1].id), Y(t.messages || []);
358
- } catch (e) {
359
- console.error("getChatMessages error:", e);
410
+ if (s.status === "error")
411
+ throw new Error(s.message || "Failed to get messages");
412
+ if (E.value = !s.closed, s.messages && s.messages.length > 0) {
413
+ T.value = s.messages[s.messages.length - 1].id, e ? Qe(s.messages) : B(s.messages);
414
+ const o = setTimeout(Y, 100);
415
+ H.value.push(o);
416
+ } else e || B(s.messages || []);
417
+ } catch (a) {
418
+ console.error("getChatMessages error:", a);
360
419
  }
361
- }, He = (e) => {
362
- const a = y.utc(), t = y.fromFormat(e, "yyyy-MM-dd HH:mm:ss", { zone: "utc" }), o = a.diff(
420
+ }, Je = (e) => {
421
+ const a = w.utc(), t = w.fromFormat(e, "yyyy-MM-dd HH:mm:ss", { zone: "utc" }), s = a.diff(
363
422
  t,
364
423
  [
365
424
  "years",
@@ -368,69 +427,71 @@ const Ot = Ke({
368
427
  "hours",
369
428
  "minutes"
370
429
  ]
371
- ), n = Math.floor(o.years), l = Math.floor(o.months), c = Math.floor(o.days), m = Math.floor(o.hours), f = Math.floor(o.minutes);
372
- if (n)
373
- return n === 1 ? v("HC_ONE_YEAR_AGO") : v("HC_X_YEARS_AGO", { years: n });
374
- if (l)
375
- return l === 1 ? v("HC_ONE_MONTH_AGO") : v("HC_X_MONTHS_AGO", { months: l });
430
+ ), o = Math.floor(s.years), r = Math.floor(s.months), c = Math.floor(s.days), d = Math.floor(s.hours), f = Math.floor(s.minutes);
431
+ if (o)
432
+ return o === 1 ? p("HC_ONE_YEAR_AGO") : p("HC_X_YEARS_AGO", { years: o });
433
+ if (r)
434
+ return r === 1 ? p("HC_ONE_MONTH_AGO") : p("HC_X_MONTHS_AGO", { months: r });
376
435
  if (c)
377
- return c === 1 ? v("HC_ONE_DAY_AGO") : v("HC_X_DAYS_AGO", { days: c });
378
- if (m)
379
- return m === 1 ? v("HC_ONE_HOUR_AGO") : v("HC_X_HOURS_AGO", { hours: m });
436
+ return c === 1 ? p("HC_ONE_DAY_AGO") : p("HC_X_DAYS_AGO", { days: c });
437
+ if (d)
438
+ return d === 1 ? p("HC_ONE_HOUR_AGO") : p("HC_X_HOURS_AGO", { hours: d });
380
439
  if (f)
381
- return f === 1 ? v("HC_ONE_MINUTE_AGO") : v("HC_X_MINUTES_AGO", { minutes: f });
440
+ return f === 1 ? p("HC_ONE_MINUTE_AGO") : p("HC_X_MINUTES_AGO", { minutes: f });
382
441
  if (f === 0)
383
- return v("HC_A_MOMENT_AGO");
384
- }, Be = async () => {
385
- s.showGuestDetails && ne(), z(), W(), I("refresh:pms", r.value);
386
- }, ne = async () => {
442
+ return p("HC_A_MOMENT_AGO");
443
+ }, Ye = async () => {
444
+ n.showGuestDetails && oe(), ne(), J(), h("refresh:pms", u.value);
445
+ }, oe = async () => {
387
446
  try {
388
- b.value.pms = !0;
447
+ M.value.pms = !0;
389
448
  const e = new AbortController(), a = setTimeout(() => e.abort(), 45e3);
390
- L.value.push(a);
391
- const t = s.pmsBaseUrl;
449
+ H.value.push(a);
450
+ const t = n.pmsBaseUrl;
392
451
  if (!t)
393
452
  throw new Error("PMS base URL is required");
394
- const o = {
453
+ const s = {
395
454
  Authorization: "Bearer " + (() => {
396
- const m = `; ${document.cookie}`.split("; QV2Auth=");
397
- return m.length === 2 && m.pop()?.split(";").shift() || "";
455
+ const g = `; ${document.cookie}`.split("; QV2Auth=");
456
+ return g.length === 2 && g.pop()?.split(";").shift() || "";
398
457
  })(),
399
458
  "Content-Type": "application/json"
400
- }, n = await fetch(
401
- `${t}/vendors/properties/statuses/${s.propertyId}/rooms`,
459
+ }, o = u.value?.qv2Rooms?.qRoomId || u.value?.id || n.room.id, r = await fetch(
460
+ `${t}/vendors/properties/statuses/${n.propertyId}/rooms`,
402
461
  {
403
- method: "GET",
404
- headers: o,
405
- signal: e.signal
462
+ method: "POST",
463
+ headers: s,
464
+ signal: e.signal,
465
+ body: JSON.stringify({ roomsIds: [o] })
406
466
  }
407
467
  );
408
- clearTimeout(a), n.ok || he(n);
409
- const l = await n.json();
410
- R.value = l.data.pmsRooms, r.value = R.value.find(
411
- (c) => c.qv2Rooms.qRoomId === s.room.id
412
- ), r.value || (r.value = s.room), b.value.pms = !1;
468
+ clearTimeout(a), r.ok || be(r);
469
+ const c = await r.json(), d = c.data?.rooms || c.rooms || [];
470
+ te.value = d, d.length > 0 ? u.value = {
471
+ ...d[0],
472
+ tokenId: d[0].tokenId || n.room.tokenId
473
+ } : u.value = n.room, M.value.pms = !1;
413
474
  } catch (e) {
414
- return b.value.pms = !1, e;
475
+ return M.value.pms = !1, e;
415
476
  }
416
- }, z = async () => {
477
+ }, ne = async () => {
417
478
  try {
418
- b.value.roomNotices = !0;
479
+ M.value.roomNotices = !0;
419
480
  const e = await fetch(
420
- "/api/client/common/getRoomNotices.php?propertyId=" + s.propertyId + "&roomIds=[" + s.room.id + "]"
481
+ "/api/client/common/getRoomNotices.php?propertyId=" + n.propertyId + "&roomIds=[" + n.room.id + "]"
421
482
  );
422
483
  if (!e.ok)
423
484
  throw new Error(`HTTP error! status: ${e.status}`);
424
485
  const a = await e.json();
425
- $.value = a.notices;
486
+ ae.value = a.notices;
426
487
  } catch (e) {
427
- console.error("Error getting room notices:", e), $.value = [];
488
+ console.error("Error getting room notices:", e), ae.value = [];
428
489
  } finally {
429
- b.value.roomNotices = !1;
490
+ M.value.roomNotices = !1;
430
491
  }
431
- }, le = async () => {
492
+ }, he = async () => {
432
493
  const e = new FormData();
433
- e.append("property_id", s.propertyId), e.append("filter", "tasks_new");
494
+ e.append("property_id", n.propertyId), e.append("filter", "tasks_new");
434
495
  const [a, t] = await Promise.all([
435
496
  fetch("/api/client/common/getDepartments.php", {
436
497
  method: "POST"
@@ -439,38 +500,39 @@ const Ot = Ke({
439
500
  method: "POST",
440
501
  body: e
441
502
  })
442
- ]), o = await a.json(), n = await t.json();
443
- if (o.departments && (o.departments.forEach((l) => {
444
- l.label = l.display_name;
445
- }), C.value = o.departments), n.users) {
446
- const l = [];
503
+ ]), s = await a.json(), o = await t.json();
504
+ if (s.departments && (s.departments.forEach((r) => {
505
+ r.label = r.display_name;
506
+ }), N.value = s.departments), o.users) {
507
+ const r = [];
447
508
  let c = {
448
509
  group: "",
449
510
  options: []
450
511
  };
451
- n.users.forEach((m) => {
452
- m.translated_department !== c.group && (c.group && l.push({ ...c }), c.group = m.translated_department, c.options = []), c.options.push(m);
453
- }), c.group && l.push({ ...c }), ce.value = l;
512
+ o.users.forEach((d) => {
513
+ d.translated_department !== c.group && (c.group && r.push({ ...c }), c.group = d.translated_department, c.options = []), c.options.push(d);
514
+ }), c.group && r.push({ ...c }), _e.value = r;
454
515
  }
455
- }, fe = async () => {
516
+ }, Te = async () => {
456
517
  try {
457
- const e = new FormData();
458
- e.append("funcname", "get_stay_details"), e.append("token_id", r.value.tokenId);
459
- const t = (await G.post(
460
- "/includes/chat_api.php",
461
- e
462
- )).data.result;
463
- if (t !== void 0 && t.error_message)
464
- throw new Error(t.error_message);
465
- t && t.user_name && (p.value.guestName = t.user_name), t && t.cell_phone && (p.value.guestPhone = t.cell_phone), t && t.email && (p.value.guestEmail = t.email), t && t.check_in && (p.value.checkInDate = y.fromISO(
466
- t.check_in
467
- ).toJSDate()), t && t.check_out && (p.value.checkOutDate = y.fromISO(
468
- t.check_out
518
+ const a = await (await fetch(
519
+ `/api/client/connect/getStayDetails.php?tokenId=${u.value.tokenId}`,
520
+ {
521
+ method: "GET",
522
+ credentials: "include"
523
+ }
524
+ )).json();
525
+ if (a.status === "error")
526
+ throw new Error(a.message || "Failed to get stay details");
527
+ a.userName && (v.value.guestName = a.userName), a.cellPhone && (v.value.guestPhone = a.cellPhone), a.email && (v.value.guestEmail = a.email), a.checkIn && (v.value.checkInDate = w.fromISO(
528
+ a.checkIn
529
+ ).toJSDate()), a.checkOut && (v.value.checkOutDate = w.fromISO(
530
+ a.checkOut
469
531
  ).toJSDate());
470
532
  } catch (e) {
471
- console.log(e);
533
+ console.error("getStayDetails error:", e);
472
534
  }
473
- }, Pe = (e) => {
535
+ }, Ve = (e) => {
474
536
  switch (e) {
475
537
  case "complaint":
476
538
  return "red-30";
@@ -483,7 +545,7 @@ const Ot = Ke({
483
545
  case "task":
484
546
  return "green-20";
485
547
  }
486
- }, Le = (e) => {
548
+ }, ze = (e) => {
487
549
  switch (e) {
488
550
  case "complaint":
489
551
  return "face-frown";
@@ -496,22 +558,22 @@ const Ot = Ke({
496
558
  case "task":
497
559
  return "check";
498
560
  }
499
- }, W = async () => {
561
+ }, J = async () => {
500
562
  try {
501
- b.value.tickets = !0;
563
+ M.value.tickets = !0;
502
564
  const e = await fetch(
503
- "/api/client/common/getAllToDos.php?propertyId=" + s.propertyId + "&roomIds=[" + s.room.id + "]"
565
+ "/api/client/common/getAllToDos.php?propertyId=" + n.propertyId + "&roomIds=[" + n.room.id + "]"
504
566
  );
505
567
  if (!e.ok)
506
568
  throw new Error(`HTTP error! status: ${e.status}`);
507
569
  const a = await e.json();
508
- D.value = a.tickets;
570
+ O.value = a.tickets;
509
571
  } catch (e) {
510
- console.error("Error getting tickets:", e), D.value = [];
572
+ console.error("Error getting tickets:", e), O.value = [];
511
573
  } finally {
512
- b.value.tickets = !1;
574
+ M.value.tickets = !1;
513
575
  }
514
- }, he = async (e) => {
576
+ }, be = async (e) => {
515
577
  const a = await e.text();
516
578
  let t;
517
579
  try {
@@ -520,34 +582,34 @@ const Ot = Ke({
520
582
  t = { code: e.status, message: a };
521
583
  }
522
584
  return t.code === 401 ? (window.location.href = "/logout.php?unauthorized=1", { error: t }) : t;
523
- }, xe = (e) => {
585
+ }, Ke = (e) => {
524
586
  const a = document.querySelectorAll(".pulse");
525
587
  if (a && a.length) {
526
- const t = r.value?.qv2Rooms?.qRoomId || r.value?.id || s.room?.id, o = document.getElementById("room-" + t), n = o?.classList;
588
+ const t = u.value?.qv2Rooms?.qRoomId || u.value?.id || n.room?.id, s = document.getElementById("room-" + t), o = s?.classList;
527
589
  switch (e) {
528
590
  case "room_notice":
529
- (n?.contains("roombox_unsel") || n?.contains("roombox_unsel_active")) && (o?.classList.remove(), o?.classList.add("roomnoticeroombox_sel"));
591
+ (o?.contains("roombox_unsel") || o?.contains("roombox_unsel_active")) && (s?.classList.remove(), s?.classList.add("roomnoticeroombox_sel"));
530
592
  break;
531
593
  case "complaint":
532
- !n?.contains("smsroombox_sel") && !n?.contains("callbackroombox_sel") && (o?.classList.remove(), o?.classList.add("complaintsroombox_sel"));
594
+ !o?.contains("smsroombox_sel") && !o?.contains("callbackroombox_sel") && (s?.classList.remove(), s?.classList.add("complaintsroombox_sel"));
533
595
  break;
534
596
  case "request":
535
- !n?.contains("smsroombox_sel") && !n?.contains("callbackroombox_sel") && !n?.contains("complaintsroombox_sel") && (o?.classList.remove(), o?.classList.add("guestrequestroombox_sel"));
597
+ !o?.contains("smsroombox_sel") && !o?.contains("callbackroombox_sel") && !o?.contains("complaintsroombox_sel") && (s?.classList.remove(), s?.classList.add("guestrequestroombox_sel"));
536
598
  break;
537
599
  case "work_order":
538
- !n?.contains("smsroombox_sel") && !n?.contains("callbackroombox_sel") && !n?.contains("complaintsroombox_sel") && !n?.contains("guestrequestroombox_sel") && (o?.classList.remove(), o?.classList.add("workordersroombox_sel"));
600
+ !o?.contains("smsroombox_sel") && !o?.contains("callbackroombox_sel") && !o?.contains("complaintsroombox_sel") && !o?.contains("guestrequestroombox_sel") && (s?.classList.remove(), s?.classList.add("workordersroombox_sel"));
539
601
  break;
540
602
  }
541
- const l = setTimeout(() => {
603
+ const r = setTimeout(() => {
542
604
  a.forEach((c) => {
543
605
  c.classList.remove("pulse");
544
606
  });
545
607
  }, 4500);
546
- L.value.push(l);
608
+ H.value.push(r);
547
609
  }
548
- }, We = () => {
610
+ }, Xe = () => {
549
611
  window.open("/guest/overview.php", "_blank");
550
- }, Fe = (e) => {
612
+ }, Ze = (e) => {
551
613
  let a = "";
552
614
  switch (e.type) {
553
615
  case "complaint":
@@ -569,328 +631,416 @@ const Ot = Ke({
569
631
  return "#";
570
632
  }
571
633
  window.open(a, "_blank");
572
- }, Ge = async () => {
573
- const e = r.value?.qv2Rooms?.qRoomId || r.value?.id || s.room?.id, a = r.value?.qv2Rooms?.qRoomName || r.value?.name || s.room?.name, t = {
574
- type: k.value?.id,
575
- propertyId: s.propertyId,
576
- userId: M.value,
634
+ }, et = async () => {
635
+ const e = u.value?.qv2Rooms?.qRoomId || u.value?.id || n.room?.id, a = u.value?.qv2Rooms?.qRoomName || u.value?.name || n.room?.name, t = {
636
+ type: b.value?.id,
637
+ propertyId: n.propertyId,
638
+ userId: P.value,
577
639
  areaId: e,
578
640
  areaName: a
579
641
  };
580
- switch (k.value?.id) {
642
+ switch (b.value?.id) {
581
643
  case "complaint":
582
- t.tokenId = r.value.tokenId, t.problemId = p.value.problem.id, t.guestName = p.value.guestName, t.guestPhone = p.value.guestPhone, t.guestEmail = p.value.guestEmail, t.guestLoyalty = p.value.guestLoyalty, t.guestMood = p.value.guestMood.id, t.checkInDate = y.fromJSDate(p.value.checkInDate).toFormat(
644
+ t.tokenId = u.value.tokenId, t.problemId = v.value.problem.id, t.guestName = v.value.guestName, t.guestPhone = v.value.guestPhone, t.guestEmail = v.value.guestEmail, t.guestLoyalty = v.value.guestLoyalty, t.guestMood = v.value.guestMood.id, t.checkInDate = w.fromJSDate(v.value.checkInDate).toFormat(
583
645
  "yyyy-MM-dd"
584
- ), t.notes = p.value.notes, t.inHouse = "2", t.source = "dashboard", I("create:todo", t);
646
+ ), t.checkOutDate = w.fromJSDate(v.value.checkOutDate).toFormat(
647
+ "yyyy-MM-dd"
648
+ ), t.notes = v.value.notes, t.inHouse = 2, t.source = "dashboard", h("create:todo", t);
585
649
  break;
586
650
  case "request":
587
- t.itemId = u.value.item.id, t.assignType = u.value.assignType.id, t.occupied = u.value.requestedBy.id, t.notes = u.value.notes, t.dueDate = y.fromJSDate(u.value.due).toFormat("yyyy-MM-dd"), u.value.assignType.id === 1 && (t.department = u.value.department.id), u.value.assignType.id === 2 && (t.person = u.value.person.id), s.allowWhenWhere && (t.requestWhen = u.value.when ? u.value.when.id : "", t.requestWhere = u.value.where ? u.value.where.id : ""), I("create:todo", t);
651
+ t.itemId = i.value.item.id, t.assignType = i.value.assignType.id, t.occupied = i.value.requestedBy.id, t.notes = i.value.notes, t.dueDate = w.fromJSDate(i.value.due).toFormat("yyyy-MM-dd"), i.value.assignType.id === 1 && (t.department = i.value.department.id), i.value.assignType.id === 2 && (t.person = i.value.person.id), n.allowWhenWhere && (t.requestWhen = i.value.when ? i.value.when.id : "", t.requestWhere = i.value.where ? i.value.where.id : ""), h("create:todo", t);
588
652
  break;
589
653
  case "room_notice":
590
- t.issueId = g.value.issue.id, t.startDate = y.fromJSDate(g.value.startDate).toFormat("yyyy-MM-dd"), t.endDate = y.fromJSDate(g.value.endDate).toFormat("yyyy-MM-dd"), t.notes = g.value.notes, t.sendPush = "1", I("create:todo", t);
654
+ t.issueId = _.value.issue.id, t.startDate = w.fromJSDate(_.value.startDate).toFormat("yyyy-MM-dd"), t.endDate = w.fromJSDate(_.value.endDate).toFormat("yyyy-MM-dd"), t.notes = _.value.notes, t.sendPush = "1", h("create:todo", t);
591
655
  break;
592
656
  case "work_order":
593
- t.itemId = d.value.item.id, t.issueId = d.value.issue.id, t.assignType = d.value.assignType.id, t.occupied = d.value.requestedBy.id, t.notes = d.value.notes, t.dueDate = y.fromJSDate(d.value.due).toFormat("yyyy-MM-dd"), d.value.assignType.id === 1 && (t.department = d.value.department.id), d.value.assignType.id === 2 && (t.person = d.value.person.id), I("create:todo", t);
657
+ t.itemId = m.value.item.id, t.issueId = m.value.issue.id, t.assignType = m.value.assignType.id, t.occupied = m.value.requestedBy.id, t.notes = m.value.notes, t.dueDate = w.fromJSDate(m.value.due).toFormat("yyyy-MM-dd"), m.value.assignType.id === 1 && (t.department = m.value.department.id), m.value.assignType.id === 2 && (t.person = m.value.person.id), h("create:todo", t);
594
658
  break;
595
659
  }
596
- }, je = (e) => {
597
- ue(), ie(), s.hover && I("toggle", e);
598
- }, Ue = (e) => {
599
- ye(), T.value = e;
600
- }, Qe = async (e) => {
601
- if (console.log("selected:", e), k.value = e, w.value = [], g.value.issue = null, p.value.problem = null, d.value.item = null, d.value.issue = null, u.value.item = null, !k.value)
660
+ }, tt = (e) => {
661
+ ge(), we(), n.hover && h("toggle", e);
662
+ }, at = (e) => {
663
+ Ee(), S.value = e;
664
+ }, st = async (e) => {
665
+ if (console.log("selected:", e), b.value = e, D.value = [], _.value.issue = null, v.value.problem = null, m.value.item = null, m.value.issue = null, i.value.item = null, !b.value)
602
666
  return;
603
- const a = r.value?.qv2Rooms?.qRoomId || r.value?.id || s.room?.id, t = new FormData();
604
- switch (t.append("property_id", s.propertyId), t.append("area_id", a), e.id) {
667
+ const a = u.value?.qv2Rooms?.qRoomId || u.value?.id || n.room?.id, t = new FormData();
668
+ switch (t.append("property_id", n.propertyId), t.append("area_id", a), e.id) {
605
669
  case "complaint":
606
670
  try {
607
- r.value.tokenId && await fe();
608
- const n = await (await fetch("/api/client/common/getComplaintProblemsByPropertyId.php", {
671
+ u.value.tokenId && await Te();
672
+ const o = await (await fetch("/api/client/common/getComplaintProblemsByPropertyId.php", {
609
673
  method: "POST",
610
674
  body: t
611
675
  })).json();
612
- n.items && (w.value = n.items);
613
- const l = await G.post(
676
+ o.items && (D.value = o.items);
677
+ const r = await z.post(
614
678
  "/api/client/common/getComplaintMoods.php"
615
679
  );
616
- l.data.items.forEach((c) => {
680
+ r.data.items.forEach((c) => {
617
681
  c.label = c.display_name;
618
- }), te.value = l.data.items;
619
- } catch (o) {
620
- console.log(o);
682
+ }), ce.value = r.data.items;
683
+ } catch (s) {
684
+ console.log(s);
621
685
  }
622
686
  break;
623
687
  case "room_notice":
624
688
  try {
625
- const n = await (await fetch("/api/client/common/getRoomNoticeIssuesByPropertyId.php", {
689
+ const o = await (await fetch("/api/client/common/getRoomNoticeIssuesByPropertyId.php", {
626
690
  method: "POST",
627
691
  body: t
628
692
  })).json();
629
- n.items && (w.value = n.items);
630
- } catch (o) {
631
- console.log(o);
693
+ o.items && (D.value = o.items);
694
+ } catch (s) {
695
+ console.log(s);
632
696
  }
633
697
  break;
634
698
  case "request":
635
699
  try {
636
- u.value.requestedBy = P.value[1], u.value.assignType = j.value[0];
637
- const n = await (await fetch("/api/client/common/getHousekeepingItemsByPropertyId.php", {
700
+ i.value.requestedBy = $.value[1], i.value.assignType = K.value[0];
701
+ const o = await (await fetch("/api/client/common/getHousekeepingItemsByPropertyId.php", {
638
702
  method: "POST",
639
703
  body: t
640
704
  })).json();
641
- if (n.items && (w.value = n.items), await le(), u.value.department = C.value.find(
642
- (l) => parseInt(l.id) === 4
643
- ), s.allowWhenWhere)
705
+ if (o.items && (D.value = o.items), await he(), i.value.department = N.value.find(
706
+ (r) => parseInt(r.id) === 4
707
+ ), n.allowWhenWhere)
644
708
  try {
645
- const l = new FormData();
646
- l.append("property_id", s.propertyId);
647
- const m = await (await fetch(
709
+ const r = new FormData();
710
+ r.append("property_id", n.propertyId);
711
+ const d = await (await fetch(
648
712
  "/api/client/common/getWhenWhereOptions.php",
649
713
  {
650
714
  method: "POST",
651
- body: l
715
+ body: r
652
716
  }
653
717
  )).json();
654
- m.when && Array.isArray(m.when) ? q.value = m.when.map((f) => ({
718
+ d.when && Array.isArray(d.when) ? q.value = d.when.map((f) => ({
655
719
  id: f.id,
656
720
  label: f.name,
657
721
  value: f.id
658
- })) : q.value = [], m.where && Array.isArray(m.where) ? A.value = m.where.map((f) => ({
722
+ })) : q.value = [], d.where && Array.isArray(d.where) ? L.value = d.where.map((f) => ({
659
723
  id: f.id,
660
724
  label: f.name,
661
725
  value: f.id
662
- })) : A.value = [];
663
- } catch (l) {
664
- console.log("Error loading When/Where options:", l), q.value = [], A.value = [];
726
+ })) : L.value = [];
727
+ } catch (r) {
728
+ console.log("Error loading When/Where options:", r), q.value = [], L.value = [];
665
729
  }
666
- } catch (o) {
667
- console.log(o);
730
+ } catch (s) {
731
+ console.log(s);
668
732
  }
669
733
  break;
670
734
  case "work_order":
671
735
  try {
672
- d.value.requestedBy = P.value[0], d.value.assignType = j.value[0];
673
- const n = await (await fetch("/api/client/common/getItemsByRoomId.php", {
736
+ m.value.requestedBy = $.value[0], m.value.assignType = K.value[0];
737
+ const o = await (await fetch("/api/client/common/getItemsByRoomId.php", {
674
738
  method: "POST",
675
739
  body: t
676
- })).json(), l = [];
740
+ })).json(), r = [];
677
741
  let c = {
678
742
  group: "",
679
743
  options: []
680
744
  };
681
- n.items && (n.items.forEach((m) => {
682
- m.section_name !== c.group && (c.group && l.push({ ...c }), c.group = m.section_name, c.options = []), m.label && c.options.push(m);
683
- }), c.group && l.push({ ...c })), w.value = l, await Promise.all([
684
- G.post(
745
+ o.items && (o.items.forEach((d) => {
746
+ d.section_name !== c.group && (c.group && r.push({ ...c }), c.group = d.section_name, c.options = []), d.label && c.options.push(d);
747
+ }), c.group && r.push({ ...c })), D.value = r, await Promise.all([
748
+ z.post(
685
749
  "/api/client/common/getWorkOrderIssues.php"
686
750
  ),
687
- le()
688
- ]).then((m) => {
689
- const f = m[0];
690
- f.data.issues.forEach((X) => {
691
- X.label = X.display_name;
692
- }), oe.value = f.data.issues;
693
- }), d.value.department = C.value.find(
694
- (m) => parseInt(m.id) === 2
751
+ he()
752
+ ]).then((d) => {
753
+ const f = d[0];
754
+ f.data.issues.forEach((g) => {
755
+ g.label = g.display_name;
756
+ }), pe.value = f.data.issues;
757
+ }), m.value.department = N.value.find(
758
+ (d) => parseInt(d.id) === 2
695
759
  );
696
- } catch (o) {
697
- console.log(o);
760
+ } catch (s) {
761
+ console.log(s);
698
762
  }
699
763
  break;
700
764
  default:
701
765
  return;
702
766
  }
703
- }, $e = () => {
704
- J.value = !J.value, K.value = !1;
705
- }, ge = () => {
767
+ }, ot = () => {
768
+ se.value = !se.value, ue.value = !1;
769
+ }, Oe = () => {
706
770
  const e = document.getElementById("comment-field"), a = document.getElementById("hidden-text");
707
771
  e.style.height = a?.offsetHeight + "px";
708
- }, re = () => {
772
+ }, Y = () => {
709
773
  const e = document.getElementById("comments-container");
710
774
  e?.scroll({
711
775
  top: e.scrollHeight,
712
776
  behavior: "smooth"
713
777
  });
714
- }, Je = async (e) => {
715
- if (e && e.type === "keydown" && e.preventDefault(), r.value.tokenId && T.value && !S.value)
778
+ }, nt = async (e) => {
779
+ if (e && e.type === "keydown" && e.preventDefault(), u.value.tokenId && S.value && !R.value)
716
780
  try {
717
781
  const a = new FormData();
718
- a.append("tokenId", r.value.tokenId), a.append("content", T.value), a.append("senderId", M.value || "");
719
- const t = await G.post(
782
+ a.append("tokenId", u.value.tokenId), a.append("content", S.value), a.append("senderId", P.value || "");
783
+ const t = await z.post(
720
784
  "/api/client/connect/sendMessage.php",
721
785
  a
722
786
  );
723
- if (t.data.status === "error")
724
- throw new Error(t.data.message || "Failed to send message");
725
- T.value = "", N.value = !t.data.closed, t.data.messages && (Y(t.data.messages), t.data.messages.length > 0 && (O.value = t.data.messages[t.data.messages.length - 1].id)), re();
787
+ if (t.data.status === "error") {
788
+ h("show:toast", {
789
+ show: !0,
790
+ message: t.data.message || p("HC_FAILED_TO_SEND_MESSAGE"),
791
+ variant: "error",
792
+ icon: "exclamation-circle"
793
+ });
794
+ return;
795
+ }
796
+ S.value = "", E.value = !t.data.closed, t.data.messages && (B(t.data.messages), t.data.messages.length > 0 && (T.value = t.data.messages[t.data.messages.length - 1].id)), Y();
726
797
  } catch (a) {
727
- console.error("sendChatMessage error:", a);
798
+ console.error("sendChatMessage error:", a), h("show:toast", {
799
+ show: !0,
800
+ message: a.message || p("HC_FAILED_TO_SEND_MESSAGE"),
801
+ variant: "error",
802
+ icon: "exclamation-circle"
803
+ });
728
804
  }
729
- }, Ye = async () => {
730
- if (!(!r.value.tokenId || !M.value))
805
+ }, rt = async () => {
806
+ if (!(!u.value.tokenId || !P.value))
731
807
  try {
732
- const e = N.value ? "/api/client/connect/closeConversation.php" : "/api/client/connect/openConversation.php", a = new FormData();
733
- a.append("tokenId", r.value.tokenId), a.append("userId", M.value), N.value && O.value !== null && a.append("lastMsgId", O.value.toString());
734
- const t = await G.post(e, a);
735
- if (t.data.status === "error")
736
- throw new Error(t.data.message || "Failed to update conversation status");
737
- N.value = !t.data.closed, t.data.messages && (Y(t.data.messages), t.data.messages.length > 0 && (O.value = t.data.messages[t.data.messages.length - 1].id));
808
+ const e = E.value ? "/api/client/connect/closeConversation.php" : "/api/client/connect/openConversation.php", a = new FormData();
809
+ a.append("tokenId", u.value.tokenId), a.append("userId", P.value), E.value && T.value !== null && a.append("lastMsgId", T.value.toString());
810
+ const t = await z.post(e, a);
811
+ if (t.data.status === "error") {
812
+ h("show:toast", {
813
+ show: !0,
814
+ message: t.data.message || p("HC_FAILED_TO_UPDATE_CONVERSATION"),
815
+ variant: "error",
816
+ icon: "exclamation-circle"
817
+ });
818
+ return;
819
+ }
820
+ E.value = !t.data.closed, t.data.messages && (B(t.data.messages), t.data.messages.length > 0 && (T.value = t.data.messages[t.data.messages.length - 1].id)), h("show:toast", {
821
+ show: !0,
822
+ message: E.value ? p("HC_CONVERSATION_REOPENED") : p("HC_CONVERSATION_CLOSED"),
823
+ variant: "success",
824
+ icon: "check-circle"
825
+ });
738
826
  } catch (e) {
739
- console.error("toggleMarkOpenClose error:", e);
827
+ console.error("toggleMarkOpenClose error:", e), h("show:toast", {
828
+ show: !0,
829
+ message: e.message || p("HC_FAILED_TO_UPDATE_CONVERSATION"),
830
+ variant: "error",
831
+ icon: "exclamation-circle"
832
+ });
740
833
  }
741
- }, ue = () => {
742
- if (s.align === "left" || s.align === "right") {
743
- const e = x.value?.getBoundingClientRect().left, a = window.innerWidth;
744
- V.value = a - e < B.value ? "right" : "left";
834
+ }, lt = async () => {
835
+ if (n.isTestEnvironment && !(!u.value?.tokenId || !U.value.trim())) {
836
+ me.value = !0;
837
+ try {
838
+ const e = new FormData();
839
+ e.append("tokenId", u.value.tokenId), e.append("content", U.value.trim());
840
+ const a = await z.post(
841
+ "/api/client/connect/simulateInbound.php",
842
+ e
843
+ );
844
+ if (a.data.status === "error") {
845
+ h("show:toast", {
846
+ show: !0,
847
+ message: a.data.message || p("HC_FAILED_TO_SIMULATE_MESSAGE"),
848
+ variant: "error",
849
+ icon: "exclamation-circle"
850
+ });
851
+ return;
852
+ }
853
+ a.data.messages && (B(a.data.messages), E.value = !a.data.closed, a.data.messages.length > 0 && (T.value = a.data.messages[a.data.messages.length - 1].id)), U.value = "", W.value = !1, Y(), h("show:toast", {
854
+ show: !0,
855
+ message: p("HC_SIMULATED_GUEST_REPLY"),
856
+ variant: "success",
857
+ icon: "check-circle"
858
+ });
859
+ } catch (e) {
860
+ console.error("simulateGuestReply error:", e), h("show:toast", {
861
+ show: !0,
862
+ message: e.message || p("HC_FAILED_TO_SIMULATE_MESSAGE"),
863
+ variant: "error",
864
+ icon: "exclamation-circle"
865
+ });
866
+ } finally {
867
+ me.value = !1;
868
+ }
869
+ }
870
+ }, ut = () => {
871
+ W.value = !W.value, W.value || (U.value = "");
872
+ }, it = () => {
873
+ j.value || (j.value = setInterval(() => {
874
+ document.visibilityState === "visible" && fe(!0);
875
+ }, Me));
876
+ }, ye = () => {
877
+ j.value && (clearInterval(j.value), j.value = null);
878
+ }, ge = () => {
879
+ if (n.align === "left" || n.align === "right") {
880
+ const e = Q.value?.getBoundingClientRect().left, a = window.innerWidth;
881
+ ie.value = a - e < G.value ? "right" : "left";
745
882
  } else {
746
- const e = x.value?.getBoundingClientRect().top, a = window.innerHeight;
747
- V.value = a - e < H.value ? "bottom" : "top";
883
+ const e = Q.value?.getBoundingClientRect().top, a = window.innerHeight;
884
+ ie.value = a - e < F.value ? "bottom" : "top";
748
885
  }
749
- }, ie = () => {
750
- if (s.position === "top" || s.position === "bottom") {
751
- const e = x.value?.getBoundingClientRect().top, a = window.innerHeight;
752
- ae.value = a - e < H.value ? "top" : "bottom";
886
+ }, we = () => {
887
+ if (n.position === "top" || n.position === "bottom") {
888
+ const e = Q.value?.getBoundingClientRect().top, a = window.innerHeight;
889
+ de.value = a - e < F.value ? "top" : "bottom";
753
890
  } else {
754
- const e = x.value?.getBoundingClientRect().left, a = window.innerWidth;
755
- ae.value = a - e < B.value ? "left" : "right";
891
+ const e = Q.value?.getBoundingClientRect().left, a = window.innerWidth;
892
+ de.value = a - e < G.value ? "left" : "right";
756
893
  }
757
- }, ye = () => {
758
- S.value = !S.value, S.value ? (T.value = "", E.value.info = U.value, E.value.tickets = Q.value, E.value.comments = Z.value, U.value = !1, Q.value = !1, document.getElementById("comment-field")?.focus()) : (U.value = E.value.info, Q.value = E.value.tickets, Z.value = E.value.comments);
759
- }, ze = async (e, a) => {
760
- const t = r.value?.qv2Rooms?.qRoomId || r.value?.id || s.room?.id, o = new FormData();
761
- if (o.append("property_id", s.propertyId), o.append("room_ids", JSON.stringify([t])), await W(), D.value) {
762
- const n = [];
763
- D.value.forEach((l) => {
764
- l.id === e && l.type === a ? n.unshift({
765
- ...l,
894
+ }, Ee = () => {
895
+ R.value = !R.value, R.value ? (S.value = "", A.value.info = Z.value, A.value.tickets = ee.value, A.value.comments = X.value, Z.value = !1, ee.value = !1, document.getElementById("comment-field")?.focus()) : (Z.value = A.value.info, ee.value = A.value.tickets, X.value = A.value.comments);
896
+ }, ct = async (e, a) => {
897
+ const t = u.value?.qv2Rooms?.qRoomId || u.value?.id || n.room?.id, s = new FormData();
898
+ if (s.append("property_id", n.propertyId), s.append("room_ids", JSON.stringify([t])), await J(), O.value) {
899
+ const o = [];
900
+ O.value.forEach((r) => {
901
+ r.id === e && r.type === a ? o.unshift({
902
+ ...r,
766
903
  isNew: !0
767
- }) : n.push({
768
- ...l,
904
+ }) : o.push({
905
+ ...r,
769
906
  isNew: !1
770
907
  });
771
- }), n.sort((l, c) => l.id === e ? -1 : c.id === e ? 1 : 0), D.value = [...n];
908
+ }), o.sort((r, c) => r.id === e ? -1 : c.id === e ? 1 : 0), O.value = [...o];
772
909
  }
773
910
  };
774
- return F(() => s.open, () => {
775
- if (s.open && s.showComments && ee.value.length) {
776
- const e = setTimeout(re, 500);
777
- L.value.push(e);
911
+ return x(() => n.open, () => {
912
+ if (n.open && n.showComments && C.value.length) {
913
+ const e = setTimeout(Y, 500);
914
+ H.value.push(e);
778
915
  }
779
- s.open || pe();
780
- }), F(T, () => {
781
- const e = setTimeout(ge, 100);
782
- L.value.push(e);
783
- }), F(() => s.allowWhenWhere, (e, a) => {
784
- a === !0 && e === !1 && (u.value.when = null, u.value.where = null, q.value = [], A.value = []);
785
- }), F(() => s.open, async (e, a) => {
786
- e && !a && (s.showGuestDetails && !R.value ? await ne() : r.value || (r.value = s.room), W(), z(), s.showComments && ve());
787
- }), F(
788
- () => s.room.id,
916
+ n.open || (De(), ye(), T.value = null, C.value = [], E.value = !1);
917
+ }), x(
918
+ () => [n.open, n.showComments, X.value, u.value?.tokenId],
919
+ ([e, a, t, s]) => {
920
+ e && a && t && s ? it() : ye();
921
+ }
922
+ ), x(S, () => {
923
+ const e = setTimeout(Oe, 100);
924
+ H.value.push(e);
925
+ }), x(() => n.allowWhenWhere, (e, a) => {
926
+ a === !0 && e === !1 && (i.value.when = null, i.value.where = null, q.value = [], L.value = []);
927
+ }), x(() => n.open, async (e, a) => {
928
+ e && !a && (n.showGuestDetails && !te.value ? await oe() : u.value || (u.value = n.room), J(), ne(), n.showComments && fe());
929
+ }), x(
930
+ () => n.room.id,
789
931
  (e, a) => {
790
- e !== a && (R.value ? (r.value = R.value.find((t) => t.qv2Rooms.qRoomId === s.room.id), r.value || (r.value = s.room)) : r.value = s.room, s.open && (W(), z()));
932
+ e !== a && (u.value = n.room, te.value = null, n.open && (n.showGuestDetails && oe(), J(), ne()));
791
933
  }
792
- ), Ve(async () => {
934
+ ), mt(async () => {
793
935
  const e = JSON.parse(
794
936
  window.localStorage.getItem("authenticated")
795
937
  );
796
- M.value = e?.user?.id || "", console.log("userId:", M.value), r.value = s.room, s.size === "sm" && (H.value = 140, B.value = 160), s.size === "lg" && (H.value = 250, B.value = 440), ue(), ie();
797
- }), Ze(() => {
798
- L.value.forEach((e) => {
938
+ P.value = e?.user?.id || window.userId || "", u.value = n.room, n.size === "sm" && (F.value = 140, G.value = 160), n.size === "lg" && (F.value = 250, G.value = 440), ge(), we();
939
+ }), pt(() => {
940
+ H.value.forEach((e) => {
799
941
  clearTimeout(e);
800
- });
942
+ }), ye();
801
943
  }), {
802
- DateTime: y,
944
+ DateTime: w,
803
945
  // Refs
804
- actionMenuOpen: K,
805
- alignment: V,
806
- assignTypes: j,
807
- comment: T,
808
- complaint: p,
809
- componentHeight: H,
810
- componentWidth: B,
811
- departments: C,
812
- departmentUsers: ce,
813
- expandComments: Z,
814
- expandGuestInfo: U,
815
- expandedStates: E,
816
- expandTickets: Q,
817
- guestDetailsData: we,
818
- itemOptions: w,
819
- loading: b,
820
- messages: ee,
821
- moodOptions: te,
822
- pmsData: R,
823
- positioning: ae,
824
- quickReplyOpen: S,
825
- request: u,
826
- requestedByOptions: P,
827
- requestLoading: _e,
828
- requestType: k,
829
- roomDetailsData: r,
830
- roomNotice: g,
831
- roomNotices: $,
832
- showCreateRequest: J,
833
- ticketsList: D,
834
- todoOptions: ke,
835
- trigger: x,
836
- userId: M,
837
- workOrder: d,
838
- workOrderIssues: oe,
946
+ actionMenuOpen: ue,
947
+ alignment: ie,
948
+ assignTypes: K,
949
+ comment: S,
950
+ complaint: v,
951
+ componentHeight: F,
952
+ componentWidth: G,
953
+ departments: N,
954
+ departmentUsers: _e,
955
+ expandComments: X,
956
+ expandGuestInfo: Z,
957
+ expandedStates: A,
958
+ expandTickets: ee,
959
+ guestDetailsData: Se,
960
+ itemOptions: D,
961
+ loading: M,
962
+ messages: C,
963
+ moodOptions: ce,
964
+ pmsData: te,
965
+ positioning: de,
966
+ quickReplyOpen: R,
967
+ request: i,
968
+ requestedByOptions: $,
969
+ requestLoading: Ce,
970
+ requestType: b,
971
+ roomDetailsData: u,
972
+ roomNotice: _,
973
+ roomNotices: ae,
974
+ showCreateRequest: se,
975
+ ticketsList: O,
976
+ todoOptions: Ne,
977
+ trigger: Q,
978
+ userId: P,
979
+ workOrder: m,
980
+ workOrderIssues: pe,
839
981
  whenOptions: q,
840
- whereOptions: A,
982
+ whereOptions: L,
841
983
  // Guest Connect state
842
- isConversationOpen: N,
843
- lastMessageId: O,
984
+ isConversationOpen: E,
985
+ lastMessageId: T,
986
+ // Simulate Guest Reply state (test environments only)
987
+ simulateOpen: W,
988
+ simulateContent: U,
989
+ simulateLoading: me,
844
990
  // Computed
845
- cleanliness: se,
846
- cleanlinessColor: De,
847
- cleanlinessTooltipContent: Ie,
848
- filteredReplies: Te,
849
- hasGuestCallback: be,
850
- hasComplaint: de,
851
- itemOptionsList: Oe,
852
- occupied: me,
853
- occupancyTooltipContent: Ce,
854
- selectedAssignType: Ee,
855
- selectedDepartment: Me,
856
- selectedRequestedBy: Re,
857
- stayDetails: Se,
858
- tagsList: Ne,
859
- validateToDo: qe,
991
+ cleanliness: ve,
992
+ cleanlinessColor: Ae,
993
+ cleanlinessTooltipContent: Re,
994
+ filteredReplies: He,
995
+ groupedMessages: Pe,
996
+ hasGuestCallback: qe,
997
+ hasComplaint: Ie,
998
+ itemOptionsList: Le,
999
+ occupied: ke,
1000
+ occupancyTooltipContent: Be,
1001
+ selectedAssignType: xe,
1002
+ selectedDepartment: Fe,
1003
+ selectedRequestedBy: Ge,
1004
+ stayDetails: We,
1005
+ tagsList: Ue,
1006
+ validateToDo: je,
860
1007
  // Methods
861
- closeRequest: pe,
862
- createCallback: Ae,
863
- createMessageList: Y,
864
- getChatMessages: ve,
865
- getHowLongAgo: He,
866
- getPMSData: ne,
867
- getRoomNotices: z,
868
- getSharedData: le,
869
- getStayDetails: fe,
870
- getTicketColor: Pe,
871
- getTicketIcon: Le,
872
- getTickets: W,
873
- handleFailedResponse: he,
874
- handlePulse: xe,
875
- onClickEditConnectGuest: We,
876
- onClickTicket: Fe,
877
- onCreateRequestSubmit: Ge,
878
- onHoverToggle: je,
879
- onSelectQuickReply: Ue,
880
- onSelectToDo: Qe,
881
- openRequest: $e,
882
- refreshPMSData: Be,
883
- resizeTextarea: ge,
884
- scrollToConnectBottom: re,
885
- sendChatMessage: Je,
886
- setAlignment: ue,
887
- setPositioning: ie,
888
- toggleMarkOpenClose: Ye,
889
- toggleQuickReply: ye,
890
- updateTickets: ze
1008
+ closeRequest: De,
1009
+ createCallback: $e,
1010
+ createMessageList: B,
1011
+ getChatMessages: fe,
1012
+ getHowLongAgo: Je,
1013
+ getPMSData: oe,
1014
+ getRoomNotices: ne,
1015
+ getSharedData: he,
1016
+ getStayDetails: Te,
1017
+ getTicketColor: Ve,
1018
+ getTicketIcon: ze,
1019
+ getTickets: J,
1020
+ handleFailedResponse: be,
1021
+ handlePulse: Ke,
1022
+ onClickEditConnectGuest: Xe,
1023
+ onClickTicket: Ze,
1024
+ onCreateRequestSubmit: et,
1025
+ onHoverToggle: tt,
1026
+ onSelectQuickReply: at,
1027
+ onSelectToDo: st,
1028
+ openRequest: ot,
1029
+ refreshPMSData: Ye,
1030
+ resizeTextarea: Oe,
1031
+ scrollToConnectBottom: Y,
1032
+ sendChatMessage: nt,
1033
+ setAlignment: ge,
1034
+ setPositioning: we,
1035
+ toggleMarkOpenClose: rt,
1036
+ toggleQuickReply: Ee,
1037
+ updateTickets: ct,
1038
+ // Simulate Guest Reply methods (test environments only)
1039
+ simulateGuestReply: lt,
1040
+ toggleSimulateOpen: ut
891
1041
  };
892
1042
  }
893
1043
  });
894
1044
  export {
895
- Ot as default
1045
+ Ft as default
896
1046
  };