@bookmypuja-tech/bmp-pdf 0.3.46 → 0.3.48

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 (2) hide show
  1. package/dist/index.js +2 -4732
  2. package/package.json +16 -23
package/dist/index.js CHANGED
@@ -1,4732 +1,2 @@
1
- // src/index.tsx
2
- import { pdf } from "@react-pdf/renderer";
3
-
4
- // src/sizes/A4Print.tsx
5
- import React from "react";
6
- import {
7
- Document,
8
- Font,
9
- Image,
10
- Page,
11
- StyleSheet,
12
- Text,
13
- View
14
- } from "@react-pdf/renderer";
15
-
16
- // src/functions.ts
17
- var formatDate = (date) => {
18
- if (typeof date === "string") {
19
- date = new Date(date);
20
- }
21
- const options2 = {
22
- day: "2-digit",
23
- month: "short",
24
- year: "numeric"
25
- };
26
- return date.toLocaleDateString("en-GB", options2).replace(",", "");
27
- };
28
-
29
- // src/constants.ts
30
- var bmpLogo = "https://res.cloudinary.com/dpaigt2bx/image/upload/f_auto,q_auto/v1/General%20BMP%20assets/vkesyodnuxuwevdwrk6m";
31
- var robotoNormal = "https://res.cloudinary.com/dpaigt2bx/raw/upload/v1742817493/fonts/ntbri6mclms8cfx3dk2e.ttf";
32
- var robotoBold = "https://res.cloudinary.com/dpaigt2bx/raw/upload/v1742817493/fonts/ojiymraiiuw7juzkmmu8.ttf";
33
- var notoSansRegular = "https://res.cloudinary.com/dpaigt2bx/raw/upload/v1743420993/NotoSans-Regular_pmvebt.ttf";
34
- var notoSansBold = "https://res.cloudinary.com/dpaigt2bx/raw/upload/v1743431605/NotoSans-Bold_kagtvd.ttf";
35
- var notoSansSemiBold = "https://res.cloudinary.com/dpaigt2bx/raw/upload/v1743431765/NotoSans-SemiBold_o96oas.ttf";
36
- var bmpLogo2 = "https://res.cloudinary.com/dpaigt2bx/image/upload/v1752653165/BookMyPuja_1_1_bd1xa0.png";
37
- var paidIcon = "https://res.cloudinary.com/dpaigt2bx/image/upload/v1752669810/paid-5025785_1280_afg4ob_gcacmg.png";
38
- var reportTimingsObj = {
39
- morning: "Morning",
40
- evening: "Evening"
41
- };
42
-
43
- // src/sizes/A4Print.tsx
44
- Font.register({
45
- family: "Roboto",
46
- fontWeight: "normal",
47
- src: robotoNormal
48
- });
49
- Font.register({
50
- family: "Roboto",
51
- fontWeight: "bold",
52
- src: robotoBold
53
- });
54
- var styles = StyleSheet.create({
55
- page: {
56
- padding: 30,
57
- fontFamily: "Roboto"
58
- },
59
- pujaTile: {
60
- padding: 10,
61
- fontSize: 9,
62
- border: "1px solid rgb(100,100,100)",
63
- borderRadius: 5,
64
- width: "100%",
65
- display: "flex",
66
- flexDirection: "row"
67
- }
68
- });
69
- var A4Print = ({
70
- data,
71
- dates
72
- }) => {
73
- const isSingleDate = formatDate(dates[0]) === formatDate(dates[1]);
74
- return /* @__PURE__ */ React.createElement(Document, null, /* @__PURE__ */ React.createElement(Page, { size: "A4", style: styles.page }, /* @__PURE__ */ React.createElement(
75
- Image,
76
- {
77
- fixed: true,
78
- style: {
79
- height: 15,
80
- width: 75,
81
- marginBottom: 10
82
- },
83
- src: bmpLogo
84
- }
85
- ), /* @__PURE__ */ React.createElement(Text, { style: { fontSize: 13, marginBottom: 2 } }, "Puja List"), /* @__PURE__ */ React.createElement(Text, { style: { fontSize: 10, marginBottom: 10 } }, "Date", ":", " ", isSingleDate ? formatDate(dates[0]) : `${formatDate(dates[0])} - ${formatDate(dates[1])}`), /* @__PURE__ */ React.createElement(
86
- View,
87
- {
88
- style: {
89
- display: "flex",
90
- flexDirection: "row",
91
- flexWrap: "wrap",
92
- justifyContent: "space-between",
93
- gap: 8
94
- }
95
- },
96
- data ? data.map((item, index) => {
97
- return /* @__PURE__ */ React.createElement(View, { wrap: false, key: index, style: styles.pujaTile }, /* @__PURE__ */ React.createElement(View, { style: { display: "flex", flexDirection: "row" } }, /* @__PURE__ */ React.createElement(
98
- Text,
99
- {
100
- style: {
101
- opacity: 0.6,
102
- marginRight: 10
103
- }
104
- },
105
- "#",
106
- (index + 1).toString().padStart(2, "0")
107
- )), /* @__PURE__ */ React.createElement(
108
- View,
109
- {
110
- style: {
111
- flexGrow: 1
112
- }
113
- },
114
- /* @__PURE__ */ React.createElement(
115
- View,
116
- {
117
- style: {
118
- display: "flex",
119
- flexDirection: "row",
120
- marginBottom: 3,
121
- gap: 3
122
- }
123
- },
124
- /* @__PURE__ */ React.createElement(Text, { style: { fontSize: 10, fontWeight: "bold" } }, item.participantName),
125
- /* @__PURE__ */ React.createElement(Text, { style: { fontSize: 10, fontWeight: "bold" } }, "-"),
126
- /* @__PURE__ */ React.createElement(Text, { style: { fontSize: 10, fontWeight: "bold" } }, item.participantNakshatra)
127
- ),
128
- /* @__PURE__ */ React.createElement(
129
- View,
130
- {
131
- style: {
132
- display: "flex",
133
- flexDirection: "row",
134
- alignContent: "flex-end",
135
- gap: 10
136
- }
137
- },
138
- /* @__PURE__ */ React.createElement(
139
- View,
140
- {
141
- style: {
142
- display: "flex",
143
- flexDirection: "row",
144
- alignContent: "flex-end"
145
- }
146
- },
147
- /* @__PURE__ */ React.createElement(Text, null, "Puja name : "),
148
- /* @__PURE__ */ React.createElement(Text, { style: { fontSize: 10, fontWeight: "bold" } }, item.pujaName)
149
- ),
150
- isSingleDate ? null : /* @__PURE__ */ React.createElement(
151
- View,
152
- {
153
- style: {
154
- display: "flex",
155
- flexDirection: "row",
156
- alignContent: "flex-end"
157
- }
158
- },
159
- /* @__PURE__ */ React.createElement(Text, null, "Date: "),
160
- /* @__PURE__ */ React.createElement(Text, { style: { fontWeight: "bold" } }, formatDate(item.date))
161
- )
162
- ),
163
- /* @__PURE__ */ React.createElement(
164
- View,
165
- {
166
- style: {
167
- display: "flex",
168
- flexDirection: "row",
169
- alignContent: "flex-end",
170
- gap: 10
171
- }
172
- }
173
- ),
174
- item.priestNote !== "" && item.priestNote !== null && item.priestNote !== void 0 ? /* @__PURE__ */ React.createElement(
175
- View,
176
- {
177
- style: {
178
- display: "flex",
179
- flexDirection: "row",
180
- justifyContent: "space-between",
181
- marginTop: 3
182
- }
183
- },
184
- /* @__PURE__ */ React.createElement(Text, null, "Priest Note: ", item.priestNote)
185
- ) : null
186
- ), /* @__PURE__ */ React.createElement(
187
- View,
188
- {
189
- style: {
190
- display: "flex",
191
- flexDirection: "column",
192
- alignItems: "flex-end"
193
- }
194
- },
195
- /* @__PURE__ */ React.createElement(Text, { style: { fontWeight: "bold", fontSize: 10 } }, "Rs ", item.amount),
196
- item.paymentStatus == "pending" ? /* @__PURE__ */ React.createElement(
197
- View,
198
- {
199
- style: {
200
- backgroundColor: "#000000",
201
- paddingVertical: 3,
202
- paddingHorizontal: 5,
203
- borderRadius: 5,
204
- marginTop: 3
205
- }
206
- },
207
- /* @__PURE__ */ React.createElement(
208
- Text,
209
- {
210
- style: {
211
- color: "#ffffff",
212
- fontSize: 8
213
- }
214
- },
215
- "Pending"
216
- )
217
- ) : null
218
- ));
219
- }) : null
220
- )));
221
- };
222
- var A4Print_default = A4Print;
223
-
224
- // src/index.tsx
225
- import React20 from "react";
226
-
227
- // src/sizes/T2Inch.tsx
228
- import React2 from "react";
229
- import {
230
- Document as Document2,
231
- Font as Font2,
232
- Image as Image2,
233
- Page as Page2,
234
- StyleSheet as StyleSheet2,
235
- Text as Text2,
236
- View as View2
237
- } from "@react-pdf/renderer";
238
- Font2.register({
239
- family: "Roboto",
240
- fontWeight: "normal",
241
- src: robotoNormal
242
- });
243
- Font2.register({
244
- family: "Roboto",
245
- fontWeight: "bold",
246
- src: robotoBold
247
- });
248
- var scalingFactor = 1;
249
- var globalFontSize = 25 * scalingFactor;
250
- var styles2 = StyleSheet2.create({
251
- page: {
252
- padding: 10 * scalingFactor,
253
- fontFamily: "Roboto"
254
- },
255
- pujaTile: {
256
- paddingVertical: 10 * scalingFactor,
257
- paddingHorizontal: 10 * scalingFactor,
258
- fontSize: globalFontSize,
259
- border: `${5 * scalingFactor}px solid black`,
260
- borderRadius: 5 * scalingFactor,
261
- width: "100%",
262
- display: "flex",
263
- flexDirection: "column"
264
- }
265
- });
266
- var T2Inch = ({
267
- data,
268
- dates
269
- }) => {
270
- const isSingleDate = formatDate(dates[0]) === formatDate(dates[1]);
271
- return /* @__PURE__ */ React2.createElement(Document2, null, /* @__PURE__ */ React2.createElement(Page2, { dpi: 200, size: [457 * scalingFactor], style: styles2.page }, /* @__PURE__ */ React2.createElement(
272
- Image2,
273
- {
274
- fixed: true,
275
- style: {
276
- height: 55 * scalingFactor,
277
- width: 274 * scalingFactor,
278
- marginBottom: 10 * scalingFactor,
279
- marginHorizontal: "auto"
280
- },
281
- src: bmpLogo
282
- }
283
- ), /* @__PURE__ */ React2.createElement(Text2, { style: { fontSize: 25 * scalingFactor, marginBottom: 5 * scalingFactor, marginHorizontal: "auto" } }, "Puja List"), /* @__PURE__ */ React2.createElement(Text2, { style: { fontSize: 20 * scalingFactor, marginBottom: 5 * scalingFactor, marginHorizontal: "auto", fontWeight: "bold" } }, "Date", ":", " ", isSingleDate ? formatDate(dates[0]) : `${formatDate(dates[0])} - ${formatDate(dates[1])}`), /* @__PURE__ */ React2.createElement(Text2, { style: { fontSize: 17 * scalingFactor, marginBottom: 20 * scalingFactor, marginHorizontal: "auto" } }, "Printed at : ", (/* @__PURE__ */ new Date()).toLocaleString()), /* @__PURE__ */ React2.createElement(
284
- View2,
285
- {
286
- style: {
287
- display: "flex",
288
- flexDirection: "row",
289
- flexWrap: "wrap",
290
- justifyContent: "space-between",
291
- gap: 15 * scalingFactor
292
- }
293
- },
294
- data ? data.map((item, index) => {
295
- return /* @__PURE__ */ React2.createElement(View2, { wrap: false, key: index, style: styles2.pujaTile }, /* @__PURE__ */ React2.createElement(View2, { style: { display: "flex", flexDirection: "row", justifyContent: "space-between", marginBottom: 5 * scalingFactor } }, /* @__PURE__ */ React2.createElement(
296
- Text2,
297
- {
298
- style: {
299
- opacity: 0.6,
300
- marginRight: 10 * scalingFactor
301
- }
302
- },
303
- "#",
304
- (index + 1).toString().padStart(2, "0")
305
- ), /* @__PURE__ */ React2.createElement(
306
- View2,
307
- {
308
- style: {
309
- display: "flex",
310
- flexDirection: "row",
311
- alignItems: "flex-end",
312
- gap: 10 * scalingFactor
313
- }
314
- },
315
- item.paymentStatus == "pending" ? /* @__PURE__ */ React2.createElement(
316
- View2,
317
- {
318
- style: {
319
- backgroundColor: "#000000",
320
- paddingVertical: 3 * scalingFactor,
321
- paddingHorizontal: 5 * scalingFactor,
322
- borderRadius: 5 * scalingFactor,
323
- marginTop: 3 * scalingFactor
324
- }
325
- },
326
- /* @__PURE__ */ React2.createElement(
327
- Text2,
328
- {
329
- style: {
330
- color: "#ffffff",
331
- fontSize: globalFontSize
332
- }
333
- },
334
- "Pending"
335
- )
336
- ) : null,
337
- /* @__PURE__ */ React2.createElement(Text2, { style: { fontWeight: "bold", fontSize: globalFontSize } }, "Rs ", item.amount)
338
- )), /* @__PURE__ */ React2.createElement(
339
- View2,
340
- {
341
- style: {
342
- flexGrow: 1
343
- }
344
- },
345
- /* @__PURE__ */ React2.createElement(
346
- View2,
347
- {
348
- style: {
349
- display: "flex",
350
- flexDirection: "row",
351
- flexWrap: "wrap",
352
- marginBottom: 3 * scalingFactor,
353
- gap: 3 * scalingFactor
354
- }
355
- },
356
- /* @__PURE__ */ React2.createElement(Text2, { style: { fontSize: globalFontSize, fontWeight: "bold" } }, item.participantName),
357
- /* @__PURE__ */ React2.createElement(Text2, { style: { fontSize: globalFontSize, fontWeight: "bold" } }, "-"),
358
- /* @__PURE__ */ React2.createElement(Text2, { style: { fontSize: globalFontSize, fontWeight: "bold" } }, item.participantNakshatra)
359
- ),
360
- /* @__PURE__ */ React2.createElement(
361
- View2,
362
- {
363
- style: {
364
- display: "flex",
365
- flexDirection: "column",
366
- alignContent: "flex-end",
367
- gap: 10 * scalingFactor
368
- }
369
- },
370
- /* @__PURE__ */ React2.createElement(
371
- View2,
372
- {
373
- style: {
374
- display: "flex",
375
- flexDirection: "row",
376
- flexWrap: "wrap",
377
- alignContent: "flex-end"
378
- }
379
- },
380
- /* @__PURE__ */ React2.createElement(Text2, null, "Puja name : "),
381
- /* @__PURE__ */ React2.createElement(Text2, { style: { fontSize: globalFontSize, fontWeight: "bold" } }, item.pujaName)
382
- ),
383
- isSingleDate ? null : /* @__PURE__ */ React2.createElement(
384
- View2,
385
- {
386
- style: {
387
- display: "flex",
388
- flexDirection: "row",
389
- alignContent: "flex-end"
390
- }
391
- },
392
- /* @__PURE__ */ React2.createElement(Text2, null, "Date: "),
393
- /* @__PURE__ */ React2.createElement(Text2, { style: { fontWeight: "bold" } }, formatDate(item.date))
394
- )
395
- ),
396
- /* @__PURE__ */ React2.createElement(
397
- View2,
398
- {
399
- style: {
400
- display: "flex",
401
- flexDirection: "row",
402
- alignContent: "flex-end",
403
- gap: 10 * scalingFactor
404
- }
405
- }
406
- ),
407
- item.priestNote !== "" && item.priestNote !== null && item.priestNote !== void 0 ? /* @__PURE__ */ React2.createElement(
408
- View2,
409
- {
410
- style: {
411
- display: "flex",
412
- flexDirection: "row",
413
- justifyContent: "space-between",
414
- marginTop: 3 * scalingFactor
415
- }
416
- },
417
- /* @__PURE__ */ React2.createElement(Text2, null, "Priest Note: ", item.priestNote)
418
- ) : null
419
- ));
420
- }) : null
421
- )));
422
- };
423
- var T2Inch_default = T2Inch;
424
-
425
- // src/sizes/a4/A4KitchenReport.tsx
426
- import { Document as Document4, Page as Page4, View as View3 } from "@react-pdf/renderer";
427
-
428
- // src/components/Text.tsx
429
- import { Text as Text3 } from "@react-pdf/renderer";
430
- import { maxBy } from "lodash";
431
- import React3 from "react";
432
- var majorLanguagesRanges = {
433
- Latin: /[A-Za-z\u00AA\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02B8\u02E0-\u02E4\u1D00-\u1D25\u1D2C-\u1D5C\u1D62-\u1D65\u1D6B-\u1D77\u1D79-\u1DBE\u1E00-\u1EFF\u2071\u207F\u2090-\u209C\u212A\u212B\u2132\u214E\u2160-\u2188\u2C60-\u2C7F\uA722-\uA787\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA7FF\uAB30-\uAB5A\uAB5C-\uAB64\uAB66-\uAB69\uFB00-\uFB06\uFF21-\uFF3A\uFF41-z]|\uD801[\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD837[\uDF00-\uDF1E\uDF25-\uDF2A]/g,
434
- SC: /[\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u3005\u3007\u3021-\u3029\u3038-\u303B\u3400-\u4DBF\u4E00-\u9FFF\uF900-\uFA6D\uFA70-\uFAD9]|\uD81B[\uDFE2\uDFE3\uDFF0\uDFF1]|[\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883\uD885-\uD887][\uDC00-\uDFFF]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF39\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A\uDF50-\uDFFF]|\uD888[\uDC00-\uDFAF]/g,
435
- Cyrillic: /[\u0400-\u0484\u0487-\u052F\u1C80-\u1C88\u1D2B\u1D78\u2DE0-\u2DFF\uA640-\uA69F\uFE2E\uFE2F]|\uD838[\uDC30-\uDC6D\uDC8F]/g,
436
- Arabic: /[\u0600-\u0604\u0606-\u060B\u060D-\u061A\u061C-\u061E\u0620-\u063F\u0641-\u064A\u0656-\u066F\u0671-\u06DC\u06DE-\u06FF\u0750-\u077F\u0870-\u088E\u0890\u0891\u0898-\u08E1\u08E3-\u08FF\uFB50-\uFBC2\uFBD3-\uFD3D\uFD40-\uFD8F\uFD92-\uFDC7\uFDCF\uFDF0-\uFDFF\uFE70-\uFE74\uFE76-\uFEFC]|\uD803[\uDE60-\uDE7E\uDEFD-\uDEFF]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB\uDEF0\uDEF1]/g,
437
- Bengali: /[\u0980-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09FE]/g,
438
- Devanagari: /[\u0900-\u0950\u0955-\u0963\u0966-\u097F\uA8E0-\uA8FF]|\uD806[\uDF00-\uDF09]/g,
439
- JP: /[\u3041-\u3096\u309D-\u309F]|\uD82C[\uDC01-\uDD1F\uDD32\uDD50-\uDD52]|\uD83C\uDE00|[\u30A1-\u30FA\u30FD-\u30FF\u31F0-\u31FF\u32D0-\u32FE\u3300-\u3357\uFF66-\uFF6F\uFF71-\uFF9D]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00\uDD20-\uDD22\uDD55\uDD64-\uDD67]|[\u3400-\u4DB5\u4E00-\u9FAF]/g,
440
- KR: /[\u1100-\u11FF\u302E\u302F\u3131-\u318E\u3200-\u321E\u3260-\u327E\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uFFA0-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/g,
441
- Tamil: /[\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BFA]|\uD807[\uDFC0-\uDFF1\uDFFF]/g,
442
- Kannada: /[\u0C80-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1-\u0CF3]/g,
443
- Myanmar: /[\u1000-\u109F\uA9E0-\uA9FE\uAA60-\uAA7F]/g,
444
- Ethiopic: /[\u1200-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u137C\u1380-\u1399\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]/g,
445
- Thai: /[\u0E01-\u0E3A\u0E40-\u0E5B]/g,
446
- Greek: /[\u0370-\u0373\u0375-\u0377\u037A-\u037D\u037F\u0384\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03E1\u03F0-\u03FF\u1D26-\u1D2A\u1D5D-\u1D61\u1D66-\u1D6A\u1DBF\u1F00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FC4\u1FC6-\u1FD3\u1FD6-\u1FDB\u1FDD-\u1FEF\u1FF2-\u1FF4\u1FF6-\u1FFE\u2126\uAB65]|\uD800[\uDD40-\uDD8E\uDDA0]|\uD834[\uDE00-\uDE45]/g,
447
- Khmer: /[\u1780-\u17DD\u17E0-\u17E9\u17F0-\u17F9\u19E0-\u19FF]/g,
448
- Armenian: /[\u0531-\u0556\u0559-\u058A\u058D-\u058F\uFB13-\uFB17]/g,
449
- Hebrew: /[\u0591-\u05C7\u05D0-\u05EA\u05EF-\u05F4\uFB1D-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFB4F]/g,
450
- Georgian: /[\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u10FF\u1C90-\u1CBA\u1CBD-\u1CBF\u2D00-\u2D25\u2D27\u2D2D]/g,
451
- Lao: /[\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECE\u0ED0-\u0ED9\u0EDC-\u0EDF]/g,
452
- "Canadian Aboriginal": /[\u1400-\u167F\u18B0-\u18F5]|\uD806[\uDEB0-\uDEBF]/g,
453
- Sinhala: /[\u0D81-\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4]|\uD804[\uDDE1-\uDDF4]/g,
454
- "Ol Chiki": /[\u1C50-\u1C7F]/g,
455
- Tibetan: /[\u0F00-\u0F47\u0F49-\u0F6C\u0F71-\u0F97\u0F99-\u0FBC\u0FBE-\u0FCC\u0FCE-\u0FD4\u0FD9\u0FDA]/g,
456
- Tifinagh: /[\u2D30-\u2D67\u2D6F\u2D70\u2D7F]/g,
457
- Yi: /[\uA000-\uA48C\uA490-\uA4C6]/g,
458
- Syriac: /[\u0700-\u070D\u070F-\u074A\u074D-\u074F\u0860-\u086A]/g,
459
- Thaana: /[\u0780-\u07B1]/g,
460
- Vai: /[\uA500-\uA62B]/g,
461
- Cherokee: /[\u13A0-\u13F5\u13F8-\u13FD\uAB70-\uABBF]/g,
462
- "Tai Tham": /[\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD]/g,
463
- "Tai Viet": /[\uAA80-\uAAC2\uAADB-\uAADF]/g,
464
- Javanese: /[\uA980-\uA9CD\uA9D0-\uA9D9\uA9DE\uA9DF]/g,
465
- Telugu: /[\u0C00-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3C-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C5D\u0C60-\u0C63\u0C66-\u0C6F\u0C77-\u0C7F]/g,
466
- Gujarati: /[\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AF1\u0AF9-\u0AFF]/g,
467
- Malayalam: /[\u0D00-\u0D03\u0D05-\u0D39\u0D3A\u0D3B\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D60-\u0D63\u0D66-\u0D6F\u0D70-\u0D7F]/g,
468
- Gurmukhi: /[\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A76]/g
469
- };
470
- var TextParsedAfterDetectingLanguage = ({ style = {}, children }) => {
471
- const detectScript = (char) => {
472
- const entry = maxBy(
473
- Object.entries(majorLanguagesRanges),
474
- ([_, test]) => {
475
- const match = char.match(test);
476
- return match ? match.length : 0;
477
- }
478
- );
479
- return entry ? entry[0] : "Latin";
480
- };
481
- const containsDate = (str) => {
482
- const datePatterns = [
483
- /\b\d{2}\/\d{2}\/\d{4}\b/,
484
- // DD/MM/YYYY
485
- /\b\d{2}\s\w{3}\s\d{4}\b/
486
- // DD MMM YYYY (e.g., 14 Aug 2024)
487
- ];
488
- return datePatterns.some((pattern) => pattern.test(str));
489
- };
490
- function replaceFullWidthChars(text) {
491
- return text.replace(/[\uFF01-\uFF5E]/g, (char) => {
492
- return `${String.fromCharCode(char.charCodeAt(0) - 65248)} `;
493
- });
494
- }
495
- const splitTextByScript = (text) => {
496
- const parts = [];
497
- let currentScript = null;
498
- let currentPart = "";
499
- for (let char of text) {
500
- char = replaceFullWidthChars(char);
501
- const script = detectScript(char);
502
- if (script !== currentScript) {
503
- if (currentPart)
504
- parts.push({ text: currentPart, script: currentScript });
505
- currentScript = script;
506
- currentPart = char;
507
- } else {
508
- currentPart += char;
509
- }
510
- }
511
- if (currentPart) parts.push({ text: currentPart, script: currentScript });
512
- return parts;
513
- };
514
- let finalText = [];
515
- if (children && typeof children === "string" && !Array.isArray(children) && !containsDate(children)) {
516
- const textParts = splitTextByScript(children);
517
- textParts.forEach((part, index) => {
518
- const fontFamily = part.script === "Latin" || !part.script ? "Noto Sans" : `Noto Sans ${part.script}`;
519
- finalText.push(
520
- /* @__PURE__ */ React3.createElement(Text3, { key: index, style: { fontFamily } }, part.text)
521
- );
522
- });
523
- }
524
- let finalStyles = [];
525
- const defaultStyle = { fontFamily: "Noto Sans" };
526
- if (Array.isArray(style)) {
527
- finalStyles = [...style, defaultStyle];
528
- } else if (style && Object.keys(style).length > 0) {
529
- finalStyles = [style, defaultStyle];
530
- } else {
531
- finalStyles = [defaultStyle];
532
- }
533
- return /* @__PURE__ */ React3.createElement(Text3, { style: finalStyles }, finalText?.length ? finalText : children);
534
- };
535
- var Text_default = TextParsedAfterDetectingLanguage;
536
-
537
- // src/sizes/a4/A4KitchenReport.tsx
538
- import React5 from "react";
539
-
540
- // src/components/ReportHeader.tsx
541
- import React4 from "react";
542
- import { Image as Image3 } from "@react-pdf/renderer";
543
- var ReportHeader = ({
544
- startDate,
545
- endDate,
546
- reportTiming,
547
- templeName,
548
- reportName
549
- }) => {
550
- return /* @__PURE__ */ React4.createElement(React4.Fragment, null, /* @__PURE__ */ React4.createElement(
551
- Image3,
552
- {
553
- fixed: true,
554
- style: {
555
- height: 15,
556
- width: 75,
557
- marginBottom: 10
558
- },
559
- src: bmpLogo
560
- }
561
- ), endDate ? /* @__PURE__ */ React4.createElement(Text_default, { style: { fontSize: 11, marginTop: 5, textAlign: "right" } }, "Dates: ", startDate.toDateString(), " - ", endDate.toDateString()) : /* @__PURE__ */ React4.createElement(Text_default, { style: { fontSize: 11, marginTop: 5, textAlign: "right" } }, "Date: ", startDate.toDateString()), reportTiming && Object.keys(reportTimingsObj).includes(reportTiming) ? /* @__PURE__ */ React4.createElement(Text_default, { style: { fontSize: 11, marginTop: 5, textAlign: "right" } }, reportTimingsObj[reportTiming], " Report") : null, /* @__PURE__ */ React4.createElement(Text_default, { style: { fontSize: 14, fontWeight: "bold" } }, reportName), /* @__PURE__ */ React4.createElement(Text_default, { style: { fontSize: 12 } }, `${templeName}`));
562
- };
563
- var ReportHeader_default = ReportHeader;
564
-
565
- // src/sizes/a4/A4KitchenReport.tsx
566
- var A4KitchenReport = ({
567
- date,
568
- templeName,
569
- data,
570
- reportTiming
571
- }) => {
572
- return /* @__PURE__ */ React5.createElement(React5.Fragment, null, /* @__PURE__ */ React5.createElement(Document4, null, /* @__PURE__ */ React5.createElement(Page4, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React5.createElement(
573
- ReportHeader_default,
574
- {
575
- startDate: date,
576
- templeName,
577
- reportTiming,
578
- reportName: "Temple Prasad (Kitchen) Report"
579
- }
580
- ), data.length > 0 ? /* @__PURE__ */ React5.createElement(
581
- View3,
582
- {
583
- style: {
584
- display: "flex",
585
- flexDirection: "column",
586
- marginTop: 20
587
- }
588
- },
589
- /* @__PURE__ */ React5.createElement(
590
- View3,
591
- {
592
- style: {
593
- display: "flex",
594
- flexDirection: "row",
595
- border: "1px solid #000",
596
- fontSize: 10,
597
- fontWeight: "semibold"
598
- }
599
- },
600
- /* @__PURE__ */ React5.createElement(
601
- View3,
602
- {
603
- style: {
604
- padding: 6,
605
- borderRight: "1px solid #000",
606
- width: "20%"
607
- }
608
- },
609
- /* @__PURE__ */ React5.createElement(Text_default, null, "Sr no")
610
- ),
611
- /* @__PURE__ */ React5.createElement(
612
- View3,
613
- {
614
- style: {
615
- padding: 6,
616
- borderRight: "1px solid #000",
617
- width: "60%"
618
- }
619
- },
620
- /* @__PURE__ */ React5.createElement(Text_default, null, "Prasad Name")
621
- ),
622
- /* @__PURE__ */ React5.createElement(
623
- View3,
624
- {
625
- style: {
626
- padding: 6,
627
- borderRight: "none",
628
- width: "20%"
629
- }
630
- },
631
- /* @__PURE__ */ React5.createElement(Text_default, null, "Quantity")
632
- )
633
- ),
634
- data.map((item, index) => {
635
- return /* @__PURE__ */ React5.createElement(
636
- View3,
637
- {
638
- style: {
639
- display: "flex",
640
- flexDirection: "row",
641
- border: "1px solid #000",
642
- borderTop: "none",
643
- fontSize: 10
644
- }
645
- },
646
- /* @__PURE__ */ React5.createElement(
647
- View3,
648
- {
649
- style: {
650
- padding: 6,
651
- borderRight: "1px solid #000",
652
- width: "20%"
653
- }
654
- },
655
- /* @__PURE__ */ React5.createElement(Text_default, null, index + 1)
656
- ),
657
- /* @__PURE__ */ React5.createElement(
658
- View3,
659
- {
660
- style: {
661
- padding: 6,
662
- borderRight: "1px solid #000",
663
- width: "60%"
664
- }
665
- },
666
- /* @__PURE__ */ React5.createElement(Text_default, null, item.name)
667
- ),
668
- /* @__PURE__ */ React5.createElement(
669
- View3,
670
- {
671
- style: {
672
- padding: 6,
673
- borderRight: "none",
674
- width: "20%"
675
- }
676
- },
677
- /* @__PURE__ */ React5.createElement(Text_default, null, item.quantity)
678
- )
679
- );
680
- })
681
- ) : /* @__PURE__ */ React5.createElement(
682
- Text_default,
683
- {
684
- style: {
685
- fontSize: 18,
686
- textAlign: "center",
687
- marginTop: 100
688
- }
689
- },
690
- "No data available for the selected date range"
691
- ))));
692
- };
693
- var A4KitchenReport_default = A4KitchenReport;
694
-
695
- // src/sizes/a4/A4TransactionReport.tsx
696
- import { Document as Document5, Page as Page5, View as View4 } from "@react-pdf/renderer";
697
- import React6 from "react";
698
- var A4TransactionReport = ({
699
- date,
700
- templeName,
701
- data
702
- }) => {
703
- const totalAmount = data.reduce((acc, item) => {
704
- if (item.status === "cancelled") {
705
- return acc;
706
- }
707
- return acc + item.bookingAmount;
708
- }, 0);
709
- const totalCreditedAmount = data.reduce((acc, item) => {
710
- if (item.status === "cancelled") {
711
- return acc;
712
- }
713
- return acc + item.creditedAmount;
714
- }, 0);
715
- return /* @__PURE__ */ React6.createElement(React6.Fragment, null, /* @__PURE__ */ React6.createElement(Document5, null, /* @__PURE__ */ React6.createElement(Page5, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React6.createElement(
716
- ReportHeader_default,
717
- {
718
- startDate: date,
719
- reportName: "Transactions Report",
720
- templeName
721
- }
722
- ), data.length > 0 ? /* @__PURE__ */ React6.createElement(React6.Fragment, null, /* @__PURE__ */ React6.createElement(Text_default, { style: { fontSize: 10, marginTop: 10 } }, "Total Bookings: ", totalAmount.toLocaleString("en-IN", {
723
- maximumFractionDigits: 2,
724
- style: "currency",
725
- currency: "INR"
726
- })), /* @__PURE__ */ React6.createElement(Text_default, { style: { fontSize: 10 } }, "Total Credited Amount: ", totalCreditedAmount.toLocaleString("en-IN", {
727
- maximumFractionDigits: 2,
728
- style: "currency",
729
- currency: "INR"
730
- })), /* @__PURE__ */ React6.createElement(
731
- View4,
732
- {
733
- style: {
734
- display: "flex",
735
- flexDirection: "column",
736
- marginTop: 20
737
- }
738
- },
739
- /* @__PURE__ */ React6.createElement(
740
- View4,
741
- {
742
- style: {
743
- display: "flex",
744
- flexDirection: "row",
745
- border: "1px solid black",
746
- fontWeight: "semibold",
747
- fontSize: 10
748
- }
749
- },
750
- /* @__PURE__ */ React6.createElement(
751
- View4,
752
- {
753
- style: {
754
- padding: 6,
755
- borderRight: "1px solid black",
756
- width: "8%"
757
- }
758
- },
759
- /* @__PURE__ */ React6.createElement(Text_default, null, "Sr no")
760
- ),
761
- /* @__PURE__ */ React6.createElement(
762
- View4,
763
- {
764
- style: {
765
- padding: 6,
766
- borderRight: "1px solid black",
767
- width: "23%"
768
- }
769
- },
770
- /* @__PURE__ */ React6.createElement(Text_default, null, "Date")
771
- ),
772
- /* @__PURE__ */ React6.createElement(
773
- View4,
774
- {
775
- style: {
776
- padding: 6,
777
- borderRight: "1px solid black",
778
- width: "19%"
779
- }
780
- },
781
- /* @__PURE__ */ React6.createElement(Text_default, null, "Invoice")
782
- ),
783
- /* @__PURE__ */ React6.createElement(
784
- View4,
785
- {
786
- style: {
787
- padding: 6,
788
- borderRight: "1px solid black",
789
- width: "15%"
790
- }
791
- },
792
- /* @__PURE__ */ React6.createElement(Text_default, null, "Booking Amt")
793
- ),
794
- /* @__PURE__ */ React6.createElement(
795
- View4,
796
- {
797
- style: {
798
- padding: 6,
799
- width: "15%",
800
- borderRight: "1px solid black"
801
- }
802
- },
803
- /* @__PURE__ */ React6.createElement(Text_default, null, "Credited Amt")
804
- ),
805
- /* @__PURE__ */ React6.createElement(
806
- View4,
807
- {
808
- style: {
809
- padding: 6,
810
- width: "20%"
811
- }
812
- },
813
- /* @__PURE__ */ React6.createElement(Text_default, null, "Transaction ID")
814
- )
815
- ),
816
- data.map((item, index) => {
817
- return /* @__PURE__ */ React6.createElement(
818
- View4,
819
- {
820
- style: {
821
- display: "flex",
822
- flexDirection: "row",
823
- border: "1px solid black",
824
- borderTop: "none",
825
- fontSize: 10
826
- }
827
- },
828
- /* @__PURE__ */ React6.createElement(
829
- View4,
830
- {
831
- style: {
832
- padding: 6,
833
- borderRight: "1px solid black",
834
- width: "8%"
835
- }
836
- },
837
- /* @__PURE__ */ React6.createElement(Text_default, null, index + 1)
838
- ),
839
- /* @__PURE__ */ React6.createElement(
840
- View4,
841
- {
842
- style: {
843
- padding: 6,
844
- borderRight: "1px solid black",
845
- width: "23%"
846
- }
847
- },
848
- /* @__PURE__ */ React6.createElement(Text_default, null, item.date, " ", item.time)
849
- ),
850
- /* @__PURE__ */ React6.createElement(
851
- View4,
852
- {
853
- style: {
854
- padding: 6,
855
- borderRight: "1px solid black",
856
- width: "19%"
857
- }
858
- },
859
- /* @__PURE__ */ React6.createElement(Text_default, null, item.invoiceNumber)
860
- ),
861
- item.status == "cancelled" ? /* @__PURE__ */ React6.createElement(React6.Fragment, null, /* @__PURE__ */ React6.createElement(
862
- View4,
863
- {
864
- style: {
865
- padding: 6,
866
- width: "50%"
867
- }
868
- },
869
- /* @__PURE__ */ React6.createElement(
870
- Text_default,
871
- {
872
- style: {
873
- textAlign: "center"
874
- }
875
- },
876
- "CANCELLED"
877
- )
878
- )) : /* @__PURE__ */ React6.createElement(React6.Fragment, null, /* @__PURE__ */ React6.createElement(
879
- View4,
880
- {
881
- style: {
882
- padding: 6,
883
- borderRight: "1px solid black",
884
- width: "15%"
885
- }
886
- },
887
- /* @__PURE__ */ React6.createElement(Text_default, null, item.bookingAmount.toLocaleString("en-IN", {
888
- maximumFractionDigits: 2,
889
- style: "currency",
890
- currency: "INR"
891
- }))
892
- ), /* @__PURE__ */ React6.createElement(
893
- View4,
894
- {
895
- style: {
896
- padding: 6,
897
- width: "15%",
898
- borderRight: "1px solid black"
899
- }
900
- },
901
- /* @__PURE__ */ React6.createElement(Text_default, null, item.creditedAmount.toLocaleString("en-IN", {
902
- maximumFractionDigits: 2,
903
- style: "currency",
904
- currency: "INR"
905
- }))
906
- ), /* @__PURE__ */ React6.createElement(
907
- View4,
908
- {
909
- style: {
910
- padding: 6,
911
- width: "20%"
912
- }
913
- },
914
- /* @__PURE__ */ React6.createElement(Text_default, null, item.transactionId)
915
- ))
916
- );
917
- })
918
- )) : /* @__PURE__ */ React6.createElement(
919
- Text_default,
920
- {
921
- style: {
922
- fontSize: 18,
923
- textAlign: "center",
924
- marginTop: 100
925
- }
926
- },
927
- "No data available for the selected date range"
928
- ))));
929
- };
930
- var A4TransactionReport_default = A4TransactionReport;
931
-
932
- // src/sizes/a4/A4PrasadDelivery.tsx
933
- import { Document as Document6, Page as Page6, View as View5 } from "@react-pdf/renderer";
934
- import React7 from "react";
935
- var A4PrasadDelivery = ({
936
- date,
937
- templeName,
938
- data
939
- }) => {
940
- data = data.map((item) => {
941
- let address = "";
942
- try {
943
- const parsedAddress = JSON.parse(item.address);
944
- address = `${parsedAddress.address}, ${parsedAddress.locality}, ${parsedAddress.state} - ${parsedAddress.pincode}`;
945
- } catch (e) {
946
- console.error("Error parsing address:", e);
947
- address = item.address;
948
- }
949
- return {
950
- ...item,
951
- address
952
- };
953
- });
954
- return /* @__PURE__ */ React7.createElement(Document6, null, /* @__PURE__ */ React7.createElement(Page6, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React7.createElement(
955
- ReportHeader_default,
956
- {
957
- startDate: date,
958
- reportName: "Prasad Delivery Address",
959
- templeName
960
- }
961
- ), data.length > 0 ? /* @__PURE__ */ React7.createElement(
962
- View5,
963
- {
964
- style: {
965
- display: "flex",
966
- flexDirection: "column",
967
- marginTop: 20
968
- }
969
- },
970
- /* @__PURE__ */ React7.createElement(
971
- View5,
972
- {
973
- style: {
974
- display: "flex",
975
- flexDirection: "row",
976
- border: "1px solid black",
977
- fontWeight: "semibold",
978
- fontSize: 10
979
- }
980
- },
981
- /* @__PURE__ */ React7.createElement(
982
- View5,
983
- {
984
- style: {
985
- padding: 6,
986
- borderRight: "1px solid black",
987
- width: "10%"
988
- }
989
- },
990
- /* @__PURE__ */ React7.createElement(Text_default, null, "Date")
991
- ),
992
- /* @__PURE__ */ React7.createElement(
993
- View5,
994
- {
995
- style: {
996
- padding: 6,
997
- borderRight: "1px solid black",
998
- width: "13%"
999
- }
1000
- },
1001
- /* @__PURE__ */ React7.createElement(Text_default, null, "Invoice")
1002
- ),
1003
- /* @__PURE__ */ React7.createElement(
1004
- View5,
1005
- {
1006
- style: {
1007
- padding: 6,
1008
- borderRight: "1px solid black",
1009
- width: "18%"
1010
- }
1011
- },
1012
- /* @__PURE__ */ React7.createElement(Text_default, null, "Devotee Name")
1013
- ),
1014
- /* @__PURE__ */ React7.createElement(
1015
- View5,
1016
- {
1017
- style: {
1018
- padding: 6,
1019
- borderRight: "1px solid black",
1020
- width: "25%"
1021
- }
1022
- },
1023
- /* @__PURE__ */ React7.createElement(Text_default, null, "Address")
1024
- ),
1025
- /* @__PURE__ */ React7.createElement(
1026
- View5,
1027
- {
1028
- style: {
1029
- padding: 6,
1030
- borderRight: "1px solid black",
1031
- width: "20%"
1032
- }
1033
- },
1034
- /* @__PURE__ */ React7.createElement(Text_default, null, "Puja Name")
1035
- ),
1036
- /* @__PURE__ */ React7.createElement(
1037
- View5,
1038
- {
1039
- style: {
1040
- padding: 6,
1041
- width: "15%"
1042
- }
1043
- },
1044
- /* @__PURE__ */ React7.createElement(Text_default, null, "Amount")
1045
- )
1046
- ),
1047
- data.map((item, index) => {
1048
- return /* @__PURE__ */ React7.createElement(
1049
- View5,
1050
- {
1051
- style: {
1052
- display: "flex",
1053
- flexDirection: "row",
1054
- border: "1px solid black",
1055
- borderTop: "none",
1056
- fontSize: 10
1057
- }
1058
- },
1059
- /* @__PURE__ */ React7.createElement(
1060
- View5,
1061
- {
1062
- style: {
1063
- padding: 6,
1064
- borderRight: "1px solid black",
1065
- width: "10%"
1066
- }
1067
- },
1068
- /* @__PURE__ */ React7.createElement(Text_default, null, new Date(item.date).toLocaleDateString("en-GB", {
1069
- day: "2-digit",
1070
- month: "2-digit",
1071
- year: "2-digit"
1072
- }))
1073
- ),
1074
- /* @__PURE__ */ React7.createElement(
1075
- View5,
1076
- {
1077
- style: {
1078
- padding: 6,
1079
- borderRight: "1px solid black",
1080
- width: "13%"
1081
- }
1082
- },
1083
- /* @__PURE__ */ React7.createElement(Text_default, null, item.invoiceNumber)
1084
- ),
1085
- /* @__PURE__ */ React7.createElement(
1086
- View5,
1087
- {
1088
- style: {
1089
- padding: 6,
1090
- borderRight: "1px solid black",
1091
- width: "18%"
1092
- }
1093
- },
1094
- /* @__PURE__ */ React7.createElement(Text_default, null, item.devoteeName)
1095
- ),
1096
- /* @__PURE__ */ React7.createElement(
1097
- View5,
1098
- {
1099
- style: {
1100
- padding: 6,
1101
- borderRight: "1px solid black",
1102
- width: "25%"
1103
- }
1104
- },
1105
- /* @__PURE__ */ React7.createElement(Text_default, null, item.address)
1106
- ),
1107
- /* @__PURE__ */ React7.createElement(
1108
- View5,
1109
- {
1110
- style: {
1111
- padding: 6,
1112
- borderRight: "1px solid black",
1113
- width: "20%"
1114
- }
1115
- },
1116
- /* @__PURE__ */ React7.createElement(Text_default, null, item.pujaName)
1117
- ),
1118
- /* @__PURE__ */ React7.createElement(
1119
- View5,
1120
- {
1121
- style: {
1122
- padding: 6,
1123
- width: "15%"
1124
- }
1125
- },
1126
- /* @__PURE__ */ React7.createElement(Text_default, null, item.amount.toLocaleString("en-IN", {
1127
- maximumFractionDigits: 2,
1128
- style: "currency",
1129
- currency: "INR"
1130
- }))
1131
- )
1132
- );
1133
- })
1134
- ) : /* @__PURE__ */ React7.createElement(
1135
- Text_default,
1136
- {
1137
- style: {
1138
- fontSize: 18,
1139
- textAlign: "center",
1140
- marginTop: 100
1141
- }
1142
- },
1143
- "No data available for the selected date range"
1144
- )));
1145
- };
1146
- var A4PrasadDelivery_default = A4PrasadDelivery;
1147
-
1148
- // src/sizes/a4/A4PrasadReport.tsx
1149
- import { Document as Document7, Page as Page7, View as View6 } from "@react-pdf/renderer";
1150
- import React8 from "react";
1151
- var A4PrasadReport = ({
1152
- date,
1153
- templeName,
1154
- data,
1155
- reportTiming
1156
- }) => {
1157
- const sortedPrasadItems = data.sort((a, b) => {
1158
- return a.invoiceNumber.localeCompare(b.invoiceNumber);
1159
- });
1160
- return /* @__PURE__ */ React8.createElement(Document7, null, /* @__PURE__ */ React8.createElement(Page7, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React8.createElement(
1161
- ReportHeader_default,
1162
- {
1163
- startDate: date,
1164
- reportName: "Prasad Report",
1165
- templeName,
1166
- reportTiming
1167
- }
1168
- ), data.length > 0 ? /* @__PURE__ */ React8.createElement(
1169
- View6,
1170
- {
1171
- style: {
1172
- display: "flex",
1173
- flexDirection: "column",
1174
- marginTop: 20
1175
- }
1176
- },
1177
- /* @__PURE__ */ React8.createElement(
1178
- View6,
1179
- {
1180
- style: {
1181
- display: "flex",
1182
- flexDirection: "row",
1183
- border: "1px solid black",
1184
- fontWeight: "semibold",
1185
- fontSize: 10
1186
- }
1187
- },
1188
- /* @__PURE__ */ React8.createElement(
1189
- View6,
1190
- {
1191
- style: {
1192
- padding: 6,
1193
- borderRight: "1px solid black",
1194
- width: "10%"
1195
- }
1196
- },
1197
- /* @__PURE__ */ React8.createElement(Text_default, null, "Sr no")
1198
- ),
1199
- /* @__PURE__ */ React8.createElement(
1200
- View6,
1201
- {
1202
- style: {
1203
- padding: 6,
1204
- borderRight: "1px solid black",
1205
- width: "20%"
1206
- }
1207
- },
1208
- /* @__PURE__ */ React8.createElement(Text_default, null, "Invoice Number")
1209
- ),
1210
- /* @__PURE__ */ React8.createElement(
1211
- View6,
1212
- {
1213
- style: {
1214
- padding: 6,
1215
- borderRight: "1px solid black",
1216
- width: "23%"
1217
- }
1218
- },
1219
- /* @__PURE__ */ React8.createElement(Text_default, null, "Devotee Name")
1220
- ),
1221
- /* @__PURE__ */ React8.createElement(
1222
- View6,
1223
- {
1224
- style: {
1225
- padding: 6,
1226
- borderRight: "1px solid black",
1227
- width: "30%"
1228
- }
1229
- },
1230
- /* @__PURE__ */ React8.createElement(Text_default, null, "Prasad Name")
1231
- ),
1232
- /* @__PURE__ */ React8.createElement(
1233
- View6,
1234
- {
1235
- style: {
1236
- padding: 6,
1237
- width: "10%",
1238
- borderRight: "1px solid black"
1239
- }
1240
- },
1241
- /* @__PURE__ */ React8.createElement(Text_default, null, "Qty")
1242
- ),
1243
- /* @__PURE__ */ React8.createElement(
1244
- View6,
1245
- {
1246
- style: {
1247
- padding: 6,
1248
- width: "7%"
1249
- }
1250
- },
1251
- /* @__PURE__ */ React8.createElement(Text_default, null, "Mode")
1252
- )
1253
- ),
1254
- data.map((item, index) => {
1255
- return /* @__PURE__ */ React8.createElement(
1256
- View6,
1257
- {
1258
- style: {
1259
- display: "flex",
1260
- flexDirection: "row",
1261
- border: "1px solid black",
1262
- borderTop: "none",
1263
- fontSize: 10
1264
- }
1265
- },
1266
- /* @__PURE__ */ React8.createElement(
1267
- View6,
1268
- {
1269
- style: {
1270
- padding: 6,
1271
- borderRight: "1px solid black",
1272
- width: "10%"
1273
- }
1274
- },
1275
- /* @__PURE__ */ React8.createElement(Text_default, null, index + 1)
1276
- ),
1277
- /* @__PURE__ */ React8.createElement(
1278
- View6,
1279
- {
1280
- style: {
1281
- padding: 6,
1282
- borderRight: "1px solid black",
1283
- width: "20%"
1284
- }
1285
- },
1286
- /* @__PURE__ */ React8.createElement(Text_default, null, item.invoiceNumber)
1287
- ),
1288
- /* @__PURE__ */ React8.createElement(
1289
- View6,
1290
- {
1291
- style: {
1292
- padding: 6,
1293
- borderRight: "1px solid black",
1294
- width: "23%",
1295
- fontSize: 9,
1296
- flexWrap: "wrap"
1297
- }
1298
- },
1299
- /* @__PURE__ */ React8.createElement(Text_default, null, item.devoteeName)
1300
- ),
1301
- /* @__PURE__ */ React8.createElement(
1302
- View6,
1303
- {
1304
- style: {
1305
- padding: 6,
1306
- borderRight: "1px solid black",
1307
- width: "30%"
1308
- }
1309
- },
1310
- /* @__PURE__ */ React8.createElement(Text_default, null, item.prasadName)
1311
- ),
1312
- /* @__PURE__ */ React8.createElement(
1313
- View6,
1314
- {
1315
- style: {
1316
- padding: 6,
1317
- width: "10%",
1318
- borderRight: "1px solid black"
1319
- }
1320
- },
1321
- /* @__PURE__ */ React8.createElement(Text_default, null, item.quantity)
1322
- ),
1323
- /* @__PURE__ */ React8.createElement(
1324
- View6,
1325
- {
1326
- style: {
1327
- padding: 6,
1328
- width: "7%"
1329
- }
1330
- },
1331
- /* @__PURE__ */ React8.createElement(Text_default, null, item.collectionMode)
1332
- )
1333
- );
1334
- })
1335
- ) : /* @__PURE__ */ React8.createElement(
1336
- Text_default,
1337
- {
1338
- style: {
1339
- fontSize: 18,
1340
- textAlign: "center",
1341
- marginTop: 100
1342
- }
1343
- },
1344
- "No data available for the selected date range"
1345
- )));
1346
- };
1347
- var A4PrasadReport_default = A4PrasadReport;
1348
-
1349
- // src/sizes/a4/A4PujaList.tsx
1350
- import { Document as Document8, Image as Image8, Page as Page8, View as View7 } from "@react-pdf/renderer";
1351
- import React9 from "react";
1352
- var A4PujaList = ({
1353
- date,
1354
- templeName,
1355
- pujas,
1356
- reportTiming
1357
- }) => {
1358
- let serialOfNormalPujas = 0;
1359
- let serialOfEarlyReminders = 0;
1360
- let pujasRequiresCoupon = pujas.some(
1361
- (puja) => puja.bookings.some((booking) => booking.requires_coupon)
1362
- );
1363
- if (!pujas || pujas.length === 0) {
1364
- return /* @__PURE__ */ React9.createElement(Document8, null, /* @__PURE__ */ React9.createElement(Page8, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React9.createElement(
1365
- ReportHeader_default,
1366
- {
1367
- startDate: date,
1368
- reportName: "Puja List",
1369
- templeName,
1370
- reportTiming
1371
- }
1372
- ), /* @__PURE__ */ React9.createElement(Text_default, { style: { fontSize: 12, marginTop: 100, textAlign: "center" } }, "No data available for the selected date range")));
1373
- }
1374
- return /* @__PURE__ */ React9.createElement(React9.Fragment, null, /* @__PURE__ */ React9.createElement(Document8, null, /* @__PURE__ */ React9.createElement(Page8, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React9.createElement(
1375
- ReportHeader_default,
1376
- {
1377
- startDate: date,
1378
- reportTiming,
1379
- reportName: "",
1380
- templeName: ""
1381
- }
1382
- ), pujas.some(
1383
- (puja) => puja.bookings.some((booking) => booking.is_early_reminder)
1384
- ) && /* @__PURE__ */ React9.createElement(React9.Fragment, null, /* @__PURE__ */ React9.createElement(Text_default, { style: { fontSize: 14, fontWeight: "bold", marginTop: 10 } }, "Early Reminders for Upcoming Pujas"), /* @__PURE__ */ React9.createElement(View7, { wrap: false, style: { marginTop: 10 } }, /* @__PURE__ */ React9.createElement(
1385
- View7,
1386
- {
1387
- style: {
1388
- display: "flex",
1389
- flexDirection: "row",
1390
- border: "1px solid black"
1391
- }
1392
- },
1393
- /* @__PURE__ */ React9.createElement(
1394
- View7,
1395
- {
1396
- style: {
1397
- padding: 6,
1398
- fontSize: 10,
1399
- borderRight: "1px solid black",
1400
- fontWeight: "semibold",
1401
- width: "10%"
1402
- }
1403
- },
1404
- /* @__PURE__ */ React9.createElement(Text_default, null, "Sr No")
1405
- ),
1406
- /* @__PURE__ */ React9.createElement(
1407
- View7,
1408
- {
1409
- style: {
1410
- padding: 6,
1411
- fontSize: 10,
1412
- borderRight: "1px solid black",
1413
- fontWeight: "semibold",
1414
- width: "60%"
1415
- }
1416
- },
1417
- /* @__PURE__ */ React9.createElement(Text_default, null, "Puja Name")
1418
- ),
1419
- /* @__PURE__ */ React9.createElement(
1420
- View7,
1421
- {
1422
- style: {
1423
- padding: 6,
1424
- fontSize: 10,
1425
- borderRight: "1px solid black",
1426
- fontWeight: "semibold",
1427
- width: "10%"
1428
- }
1429
- },
1430
- /* @__PURE__ */ React9.createElement(Text_default, null, "Qty")
1431
- ),
1432
- /* @__PURE__ */ React9.createElement(
1433
- View7,
1434
- {
1435
- style: {
1436
- padding: 6,
1437
- fontSize: 10,
1438
- borderRight: "none",
1439
- fontWeight: "semibold",
1440
- width: "20%"
1441
- }
1442
- },
1443
- /* @__PURE__ */ React9.createElement(Text_default, null, "Date")
1444
- )
1445
- ))), pujas.some(
1446
- (puja) => puja.bookings.some(
1447
- (booking) => booking.is_early_reminder && !booking.requires_coupon
1448
- )
1449
- ) ? pujas.flatMap(
1450
- (puja, pujaIndex) => puja.bookings.filter(
1451
- (booking) => booking.is_early_reminder && !booking.requires_coupon
1452
- ).map((booking, bookingIndex) => {
1453
- serialOfEarlyReminders++;
1454
- return /* @__PURE__ */ React9.createElement(
1455
- View7,
1456
- {
1457
- key: `${pujaIndex}-${bookingIndex}`,
1458
- style: {
1459
- display: "flex",
1460
- flexDirection: "row",
1461
- border: "1px solid black",
1462
- borderTop: "none"
1463
- }
1464
- },
1465
- /* @__PURE__ */ React9.createElement(
1466
- View7,
1467
- {
1468
- style: {
1469
- padding: 6,
1470
- fontSize: 10,
1471
- borderRight: "1px solid black",
1472
- width: "10%"
1473
- }
1474
- },
1475
- /* @__PURE__ */ React9.createElement(Text_default, null, serialOfEarlyReminders)
1476
- ),
1477
- /* @__PURE__ */ React9.createElement(
1478
- View7,
1479
- {
1480
- style: {
1481
- padding: 6,
1482
- fontSize: 10,
1483
- borderRight: "1px solid black",
1484
- width: "60%"
1485
- }
1486
- },
1487
- /* @__PURE__ */ React9.createElement(Text_default, null, puja.name)
1488
- ),
1489
- /* @__PURE__ */ React9.createElement(
1490
- View7,
1491
- {
1492
- style: {
1493
- padding: 6,
1494
- fontSize: 10,
1495
- borderRight: "1px solid black",
1496
- width: "10%"
1497
- }
1498
- },
1499
- /* @__PURE__ */ React9.createElement(Text_default, null, booking.quantity)
1500
- ),
1501
- /* @__PURE__ */ React9.createElement(
1502
- View7,
1503
- {
1504
- style: {
1505
- padding: 6,
1506
- fontSize: 10,
1507
- borderRight: "none",
1508
- width: "20%"
1509
- }
1510
- },
1511
- /* @__PURE__ */ React9.createElement(Text_default, null, booking.date ? new Date(booking.date).toDateString() : "")
1512
- )
1513
- );
1514
- })
1515
- ) : null, /* @__PURE__ */ React9.createElement(Text_default, { style: { fontSize: 14, fontWeight: "bold", marginTop: 20 } }, "Puja List"), /* @__PURE__ */ React9.createElement(Text_default, { style: { fontSize: 12 } }, `${templeName}`), /* @__PURE__ */ React9.createElement(
1516
- View7,
1517
- {
1518
- style: {
1519
- display: "flex",
1520
- flexDirection: "column",
1521
- marginTop: 10
1522
- }
1523
- },
1524
- pujas.map((puja, pujaIndex) => {
1525
- if (puja.bookings.every(
1526
- (booking) => booking.is_early_reminder || booking.requires_coupon
1527
- ))
1528
- return null;
1529
- serialOfNormalPujas = 0;
1530
- return /* @__PURE__ */ React9.createElement(React9.Fragment, null, /* @__PURE__ */ React9.createElement(View7, { wrap: false, style: { marginBottom: 25 } }, /* @__PURE__ */ React9.createElement(View7, null, /* @__PURE__ */ React9.createElement(
1531
- Text_default,
1532
- {
1533
- style: {
1534
- fontSize: 10,
1535
- fontWeight: "bold",
1536
- border: "1px solid black",
1537
- padding: 6,
1538
- textAlign: "center",
1539
- borderBottom: "none"
1540
- }
1541
- },
1542
- `${puja.name} - ${puja.bookings.length}`
1543
- )), /* @__PURE__ */ React9.createElement(
1544
- View7,
1545
- {
1546
- style: {
1547
- display: "flex",
1548
- flexDirection: "row",
1549
- border: "1px solid black"
1550
- }
1551
- },
1552
- /* @__PURE__ */ React9.createElement(
1553
- View7,
1554
- {
1555
- style: {
1556
- padding: 6,
1557
- fontSize: 10,
1558
- borderRight: "1px solid black",
1559
- fontWeight: "semibold",
1560
- width: "10%"
1561
- }
1562
- },
1563
- /* @__PURE__ */ React9.createElement(Text_default, null, "Sr No")
1564
- ),
1565
- /* @__PURE__ */ React9.createElement(
1566
- View7,
1567
- {
1568
- style: {
1569
- padding: 6,
1570
- fontSize: 10,
1571
- borderRight: "1px solid black",
1572
- fontWeight: "semibold",
1573
- width: "20%"
1574
- }
1575
- },
1576
- /* @__PURE__ */ React9.createElement(Text_default, null, "Invoice No")
1577
- ),
1578
- /* @__PURE__ */ React9.createElement(
1579
- View7,
1580
- {
1581
- style: {
1582
- padding: 6,
1583
- fontSize: 10,
1584
- borderRight: "1px solid black",
1585
- fontWeight: "semibold",
1586
- width: "35%"
1587
- }
1588
- },
1589
- /* @__PURE__ */ React9.createElement(Text_default, null, "Devotee Name")
1590
- ),
1591
- /* @__PURE__ */ React9.createElement(
1592
- View7,
1593
- {
1594
- style: {
1595
- padding: 6,
1596
- fontSize: 10,
1597
- borderRight: "1px solid black",
1598
- fontWeight: "semibold",
1599
- width: "25%"
1600
- }
1601
- },
1602
- /* @__PURE__ */ React9.createElement(Text_default, null, "Nakshatra")
1603
- ),
1604
- /* @__PURE__ */ React9.createElement(
1605
- View7,
1606
- {
1607
- style: {
1608
- padding: 6,
1609
- fontSize: 10,
1610
- borderRight: "none",
1611
- fontWeight: "semibold",
1612
- width: "10%"
1613
- }
1614
- },
1615
- /* @__PURE__ */ React9.createElement(Text_default, null, "Qty")
1616
- )
1617
- ), puja.bookings.map((booking, bookingIndex) => {
1618
- if (booking.is_early_reminder || booking.requires_coupon)
1619
- return null;
1620
- serialOfNormalPujas++;
1621
- return /* @__PURE__ */ React9.createElement(React9.Fragment, null, /* @__PURE__ */ React9.createElement(
1622
- View7,
1623
- {
1624
- style: {
1625
- display: "flex",
1626
- flexDirection: "row",
1627
- border: "1px solid black",
1628
- borderTop: "none",
1629
- width: "100%"
1630
- }
1631
- },
1632
- /* @__PURE__ */ React9.createElement(
1633
- View7,
1634
- {
1635
- style: {
1636
- padding: 6,
1637
- fontSize: 10,
1638
- borderRight: "1px solid black",
1639
- width: "10%"
1640
- }
1641
- },
1642
- /* @__PURE__ */ React9.createElement(Text_default, null, serialOfNormalPujas)
1643
- ),
1644
- /* @__PURE__ */ React9.createElement(
1645
- View7,
1646
- {
1647
- style: {
1648
- display: "flex",
1649
- flexDirection: "column",
1650
- width: "90%"
1651
- }
1652
- },
1653
- /* @__PURE__ */ React9.createElement(
1654
- View7,
1655
- {
1656
- style: {
1657
- display: "flex",
1658
- flexDirection: "row"
1659
- }
1660
- },
1661
- /* @__PURE__ */ React9.createElement(
1662
- View7,
1663
- {
1664
- style: {
1665
- padding: 6,
1666
- fontSize: 10,
1667
- borderRight: "1px solid black",
1668
- width: `${20 * 1.11111}%`
1669
- }
1670
- },
1671
- /* @__PURE__ */ React9.createElement(Text_default, null, booking.invoiceNumber)
1672
- ),
1673
- /* @__PURE__ */ React9.createElement(
1674
- View7,
1675
- {
1676
- style: {
1677
- padding: 6,
1678
- fontSize: 10,
1679
- borderRight: "1px solid black",
1680
- width: `${35 * 1.11111}%`
1681
- }
1682
- },
1683
- /* @__PURE__ */ React9.createElement(Text_default, null, booking.devoteeName)
1684
- ),
1685
- /* @__PURE__ */ React9.createElement(
1686
- View7,
1687
- {
1688
- style: {
1689
- padding: 6,
1690
- fontSize: 10,
1691
- borderRight: "1px solid black",
1692
- width: `${25 * 1.11111}%`
1693
- }
1694
- },
1695
- /* @__PURE__ */ React9.createElement(Text_default, null, booking.nakshatra)
1696
- ),
1697
- /* @__PURE__ */ React9.createElement(
1698
- View7,
1699
- {
1700
- style: {
1701
- padding: 6,
1702
- fontSize: 10,
1703
- borderRight: "none",
1704
- width: `${10 * 1.11111}%`
1705
- }
1706
- },
1707
- /* @__PURE__ */ React9.createElement(Text_default, null, booking.quantity)
1708
- )
1709
- ),
1710
- booking.priestNote && /* @__PURE__ */ React9.createElement(
1711
- View7,
1712
- {
1713
- style: {
1714
- padding: 6,
1715
- fontSize: 10,
1716
- borderTop: "1px solid black",
1717
- width: "100%"
1718
- }
1719
- },
1720
- /* @__PURE__ */ React9.createElement(Text_default, null, booking.priestNote)
1721
- )
1722
- )
1723
- ));
1724
- })));
1725
- })
1726
- )), pujasRequiresCoupon ? /* @__PURE__ */ React9.createElement(Page8, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React9.createElement(
1727
- Image8,
1728
- {
1729
- fixed: true,
1730
- style: {
1731
- height: 15,
1732
- width: 75,
1733
- marginBottom: 10
1734
- },
1735
- src: bmpLogo
1736
- }
1737
- ), /* @__PURE__ */ React9.createElement(
1738
- View7,
1739
- {
1740
- style: {
1741
- display: "flex",
1742
- flexDirection: "column",
1743
- marginTop: 10,
1744
- gap: 15
1745
- }
1746
- },
1747
- (() => {
1748
- const allCouponBookings = pujas.flatMap(
1749
- (puja) => puja.bookings.filter((booking) => booking.requires_coupon).map((booking) => ({ ...booking, pujaName: puja.name }))
1750
- );
1751
- const grouped = {};
1752
- for (const booking of allCouponBookings) {
1753
- if (!grouped[booking.invoiceNumber])
1754
- grouped[booking.invoiceNumber] = [];
1755
- grouped[booking.invoiceNumber].push(booking);
1756
- }
1757
- return Object.entries(grouped).map(
1758
- ([invoiceNumber, bookings], groupIdx) => {
1759
- const bookingsArr = bookings;
1760
- const first = bookingsArr[0];
1761
- return /* @__PURE__ */ React9.createElement(
1762
- View7,
1763
- {
1764
- key: invoiceNumber,
1765
- style: {
1766
- marginBottom: 10,
1767
- fontSize: 18,
1768
- padding: 10,
1769
- border: "1px dotted black",
1770
- position: "relative"
1771
- },
1772
- wrap: false
1773
- },
1774
- /* @__PURE__ */ React9.createElement(
1775
- View7,
1776
- {
1777
- style: {
1778
- display: "flex",
1779
- flexDirection: "row",
1780
- justifyContent: "space-between",
1781
- gap: 10
1782
- }
1783
- },
1784
- /* @__PURE__ */ React9.createElement(
1785
- View7,
1786
- {
1787
- style: {
1788
- display: "flex",
1789
- flexDirection: "row",
1790
- gap: 10
1791
- }
1792
- },
1793
- /* @__PURE__ */ React9.createElement(Text_default, { style: { fontWeight: "semibold" } }, invoiceNumber),
1794
- /* @__PURE__ */ React9.createElement(Text_default, null, first.date ? new Date(first.date).toDateString() : date.toDateString())
1795
- ),
1796
- /* @__PURE__ */ React9.createElement(Text_default, null, first.phone_number)
1797
- ),
1798
- /* @__PURE__ */ React9.createElement(View7, { style: { height: 15, width: "100%" } }),
1799
- bookingsArr.map(
1800
- (booking, idx) => /* @__PURE__ */ React9.createElement(
1801
- View7,
1802
- {
1803
- key: idx,
1804
- style: {
1805
- display: "flex",
1806
- flexDirection: "row",
1807
- marginTop: 25
1808
- }
1809
- },
1810
- /* @__PURE__ */ React9.createElement(Text_default, null, `${booking.devoteeName} ----- ${booking.nakshatra} ----- ${booking.pujaName}`)
1811
- )
1812
- ),
1813
- /* @__PURE__ */ React9.createElement(View7, null, /* @__PURE__ */ React9.createElement(
1814
- Text_default,
1815
- {
1816
- style: {
1817
- textAlign: "center",
1818
- marginTop: 10,
1819
- fontSize: 10,
1820
- opacity: 0.5
1821
- }
1822
- },
1823
- `~~~ bookmypuja.app - Your Puja, Our Commitment ~~~`
1824
- ))
1825
- );
1826
- }
1827
- );
1828
- })()
1829
- )) : null));
1830
- };
1831
- var A4PujaList_default = A4PujaList;
1832
-
1833
- // src/sizes/a4/A4Summary.tsx
1834
- import React10 from "react";
1835
- import { Page as Page9, Document as Document9, View as View8 } from "@react-pdf/renderer";
1836
- var A4Summary = ({
1837
- templeName,
1838
- date,
1839
- pujas,
1840
- reportTiming
1841
- }) => {
1842
- const sortedPujaList = pujas.sort((a, b) => {
1843
- const aTotalCount = a.nakshatras.length;
1844
- const bTotalCount = b.nakshatras.length;
1845
- return bTotalCount - aTotalCount;
1846
- });
1847
- return /* @__PURE__ */ React10.createElement(Document9, null, /* @__PURE__ */ React10.createElement(
1848
- Page9,
1849
- {
1850
- size: "A4",
1851
- style: {
1852
- padding: 30,
1853
- fontFamily: "Noto Sans"
1854
- }
1855
- },
1856
- /* @__PURE__ */ React10.createElement(
1857
- ReportHeader_default,
1858
- {
1859
- startDate: date,
1860
- reportTiming,
1861
- reportName: "Puja Summary",
1862
- templeName
1863
- }
1864
- ),
1865
- pujas.length > 0 ? /* @__PURE__ */ React10.createElement(
1866
- View8,
1867
- {
1868
- style: {
1869
- display: "flex",
1870
- flexDirection: "column",
1871
- marginTop: 20
1872
- }
1873
- },
1874
- sortedPujaList.map((item, index) => {
1875
- return /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(View8, { wrap: false, style: { marginBottom: 25 } }, /* @__PURE__ */ React10.createElement(View8, null, /* @__PURE__ */ React10.createElement(
1876
- Text_default,
1877
- {
1878
- style: {
1879
- fontSize: 10,
1880
- fontWeight: "bold",
1881
- border: "1px solid black",
1882
- padding: 6,
1883
- textAlign: "center",
1884
- borderBottom: "none"
1885
- }
1886
- },
1887
- `${item.name} - ${item.totalCount}`
1888
- )), /* @__PURE__ */ React10.createElement(
1889
- View8,
1890
- {
1891
- style: {
1892
- display: "flex",
1893
- flexDirection: "row",
1894
- border: "1px solid black"
1895
- }
1896
- },
1897
- /* @__PURE__ */ React10.createElement(
1898
- View8,
1899
- {
1900
- style: {
1901
- padding: 6,
1902
- fontSize: 10,
1903
- borderRight: "1px solid black",
1904
- fontWeight: "semibold",
1905
- width: "20%"
1906
- }
1907
- },
1908
- /* @__PURE__ */ React10.createElement(Text_default, null, "Sr No")
1909
- ),
1910
- /* @__PURE__ */ React10.createElement(
1911
- View8,
1912
- {
1913
- style: {
1914
- padding: 6,
1915
- fontSize: 10,
1916
- borderRight: "1px solid black",
1917
- fontWeight: "semibold",
1918
- width: "60%"
1919
- }
1920
- },
1921
- /* @__PURE__ */ React10.createElement(Text_default, null, "Nakshatra")
1922
- ),
1923
- /* @__PURE__ */ React10.createElement(
1924
- View8,
1925
- {
1926
- style: {
1927
- padding: 6,
1928
- fontSize: 10,
1929
- width: "20%",
1930
- fontWeight: "semibold"
1931
- }
1932
- },
1933
- /* @__PURE__ */ React10.createElement(Text_default, null, "Quantity")
1934
- )
1935
- ), item.nakshatras.map((nakshatra, nakshatraIndex) => {
1936
- return /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(
1937
- View8,
1938
- {
1939
- style: {
1940
- display: "flex",
1941
- flexDirection: "row",
1942
- border: "1px solid black",
1943
- borderTop: "none"
1944
- }
1945
- },
1946
- /* @__PURE__ */ React10.createElement(
1947
- View8,
1948
- {
1949
- style: {
1950
- padding: 6,
1951
- fontSize: 10,
1952
- borderRight: "1px solid black",
1953
- width: "20%"
1954
- }
1955
- },
1956
- /* @__PURE__ */ React10.createElement(Text_default, null, nakshatraIndex + 1)
1957
- ),
1958
- /* @__PURE__ */ React10.createElement(
1959
- View8,
1960
- {
1961
- style: {
1962
- padding: 6,
1963
- fontSize: 10,
1964
- borderRight: "1px solid black",
1965
- width: "60%"
1966
- }
1967
- },
1968
- /* @__PURE__ */ React10.createElement(Text_default, null, nakshatra.name)
1969
- ),
1970
- /* @__PURE__ */ React10.createElement(
1971
- View8,
1972
- {
1973
- style: {
1974
- padding: 6,
1975
- fontSize: 10,
1976
- width: "20%"
1977
- }
1978
- },
1979
- /* @__PURE__ */ React10.createElement(Text_default, null, nakshatra.count)
1980
- )
1981
- ));
1982
- })));
1983
- })
1984
- ) : /* @__PURE__ */ React10.createElement(
1985
- Text_default,
1986
- {
1987
- style: {
1988
- fontSize: 18,
1989
- textAlign: "center",
1990
- marginTop: 100
1991
- }
1992
- },
1993
- "No data available for the selected date range"
1994
- )
1995
- ));
1996
- };
1997
- var A4Summary_default = A4Summary;
1998
-
1999
- // src/index.tsx
2000
- import { Font as Font5 } from "@react-pdf/renderer";
2001
-
2002
- // src/sizes/a4/A4CombinedReport.tsx
2003
- import { Document as Document10, Image as Image10, Page as Page10, View as View9 } from "@react-pdf/renderer";
2004
- import React11 from "react";
2005
- var A4CombinedReport = ({
2006
- date,
2007
- templeName,
2008
- pujaData,
2009
- prasadData,
2010
- deliveryData,
2011
- reportTiming
2012
- }) => {
2013
- deliveryData = deliveryData.map((item) => {
2014
- let address = "";
2015
- try {
2016
- const parsedAddress = JSON.parse(item.address);
2017
- address = `${parsedAddress.address}, ${parsedAddress.locality}, ${parsedAddress.state} - ${parsedAddress.pincode}`;
2018
- } catch (e) {
2019
- console.error("Error parsing address:", e);
2020
- address = item.address;
2021
- }
2022
- return {
2023
- ...item,
2024
- address
2025
- };
2026
- });
2027
- let serialOfNormalPujas = 0;
2028
- let serialOfEarlyReminders = 0;
2029
- const pujasRequiresCoupon = pujaData.some(
2030
- (puja) => puja.bookings.some((booking) => booking.requires_coupon)
2031
- );
2032
- if (pujaData.length == 0 && prasadData.length == 0 && deliveryData.length == 0) {
2033
- return /* @__PURE__ */ React11.createElement(Document10, null, /* @__PURE__ */ React11.createElement(Page10, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React11.createElement(
2034
- ReportHeader_default,
2035
- {
2036
- startDate: date,
2037
- reportTiming,
2038
- reportName: "Combined Report",
2039
- templeName
2040
- }
2041
- ), /* @__PURE__ */ React11.createElement(Text_default, { style: { fontSize: 12, marginTop: 100, textAlign: "center" } }, "No data available for the selected date range")));
2042
- }
2043
- return /* @__PURE__ */ React11.createElement(React11.Fragment, null, /* @__PURE__ */ React11.createElement(Document10, null, pujaData.length > 0 && /* @__PURE__ */ React11.createElement(Page10, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React11.createElement(
2044
- ReportHeader_default,
2045
- {
2046
- startDate: date,
2047
- reportTiming,
2048
- reportName: "",
2049
- templeName: ""
2050
- }
2051
- ), pujaData.some(
2052
- (puja) => puja.bookings.some((booking) => booking.is_early_reminder)
2053
- ) && /* @__PURE__ */ React11.createElement(React11.Fragment, null, /* @__PURE__ */ React11.createElement(
2054
- Text_default,
2055
- {
2056
- style: { fontSize: 14, fontWeight: "bold", marginTop: 10 }
2057
- },
2058
- "Early Reminders for Upcoming Pujas"
2059
- ), /* @__PURE__ */ React11.createElement(View9, { wrap: false, style: { marginTop: 10 } }, /* @__PURE__ */ React11.createElement(
2060
- View9,
2061
- {
2062
- style: {
2063
- display: "flex",
2064
- flexDirection: "row",
2065
- border: "1px solid black"
2066
- }
2067
- },
2068
- /* @__PURE__ */ React11.createElement(
2069
- View9,
2070
- {
2071
- style: {
2072
- padding: 6,
2073
- fontSize: 10,
2074
- borderRight: "1px solid black",
2075
- fontWeight: "semibold",
2076
- width: "10%"
2077
- }
2078
- },
2079
- /* @__PURE__ */ React11.createElement(Text_default, null, "Sr No")
2080
- ),
2081
- /* @__PURE__ */ React11.createElement(
2082
- View9,
2083
- {
2084
- style: {
2085
- padding: 6,
2086
- fontSize: 10,
2087
- borderRight: "1px solid black",
2088
- fontWeight: "semibold",
2089
- width: "60%"
2090
- }
2091
- },
2092
- /* @__PURE__ */ React11.createElement(Text_default, null, "Puja Name")
2093
- ),
2094
- /* @__PURE__ */ React11.createElement(
2095
- View9,
2096
- {
2097
- style: {
2098
- padding: 6,
2099
- fontSize: 10,
2100
- borderRight: "1px solid black",
2101
- fontWeight: "semibold",
2102
- width: "10%"
2103
- }
2104
- },
2105
- /* @__PURE__ */ React11.createElement(Text_default, null, "Qty")
2106
- ),
2107
- /* @__PURE__ */ React11.createElement(
2108
- View9,
2109
- {
2110
- style: {
2111
- padding: 6,
2112
- fontSize: 10,
2113
- borderRight: "none",
2114
- fontWeight: "semibold",
2115
- width: "20%"
2116
- }
2117
- },
2118
- /* @__PURE__ */ React11.createElement(Text_default, null, "Date")
2119
- )
2120
- ))), pujaData.some(
2121
- (puja) => puja.bookings.some(
2122
- (booking) => booking.is_early_reminder && !booking.requires_coupon
2123
- )
2124
- ) ? pujaData.flatMap(
2125
- (puja, pujaIndex) => puja.bookings.filter(
2126
- (booking) => booking.is_early_reminder && !booking.requires_coupon
2127
- ).map((booking, bookingIndex) => {
2128
- serialOfEarlyReminders++;
2129
- return /* @__PURE__ */ React11.createElement(
2130
- View9,
2131
- {
2132
- key: `${pujaIndex}-${bookingIndex}`,
2133
- style: {
2134
- display: "flex",
2135
- flexDirection: "row",
2136
- border: "1px solid black",
2137
- borderTop: "none"
2138
- }
2139
- },
2140
- /* @__PURE__ */ React11.createElement(
2141
- View9,
2142
- {
2143
- style: {
2144
- padding: 6,
2145
- fontSize: 10,
2146
- borderRight: "1px solid black",
2147
- width: "10%"
2148
- }
2149
- },
2150
- /* @__PURE__ */ React11.createElement(Text_default, null, serialOfEarlyReminders)
2151
- ),
2152
- /* @__PURE__ */ React11.createElement(
2153
- View9,
2154
- {
2155
- style: {
2156
- padding: 6,
2157
- fontSize: 10,
2158
- borderRight: "1px solid black",
2159
- width: "60%"
2160
- }
2161
- },
2162
- /* @__PURE__ */ React11.createElement(Text_default, null, puja.name)
2163
- ),
2164
- /* @__PURE__ */ React11.createElement(
2165
- View9,
2166
- {
2167
- style: {
2168
- padding: 6,
2169
- fontSize: 10,
2170
- borderRight: "1px solid black",
2171
- width: "10%"
2172
- }
2173
- },
2174
- /* @__PURE__ */ React11.createElement(Text_default, null, booking.quantity)
2175
- ),
2176
- /* @__PURE__ */ React11.createElement(
2177
- View9,
2178
- {
2179
- style: {
2180
- padding: 6,
2181
- fontSize: 10,
2182
- borderRight: "none",
2183
- width: "20%"
2184
- }
2185
- },
2186
- /* @__PURE__ */ React11.createElement(Text_default, null, booking.date ? new Date(booking.date).toDateString() : "")
2187
- )
2188
- );
2189
- })
2190
- ) : null, /* @__PURE__ */ React11.createElement(Text_default, { style: { fontSize: 14, fontWeight: "bold", marginTop: 20 } }, "Puja List"), /* @__PURE__ */ React11.createElement(Text_default, { style: { fontSize: 12 } }, `${templeName}`), /* @__PURE__ */ React11.createElement(
2191
- View9,
2192
- {
2193
- style: {
2194
- display: "flex",
2195
- flexDirection: "column",
2196
- marginTop: 10
2197
- }
2198
- },
2199
- pujaData.map((puja, pujaIndex) => {
2200
- if (puja.bookings.every(
2201
- (booking) => booking.is_early_reminder || booking.requires_coupon
2202
- ))
2203
- return null;
2204
- serialOfNormalPujas = 0;
2205
- return /* @__PURE__ */ React11.createElement(React11.Fragment, null, /* @__PURE__ */ React11.createElement(View9, { wrap: false, style: { marginBottom: 25 } }, /* @__PURE__ */ React11.createElement(View9, null, /* @__PURE__ */ React11.createElement(
2206
- Text_default,
2207
- {
2208
- style: {
2209
- fontSize: 10,
2210
- fontWeight: "bold",
2211
- border: "1px solid black",
2212
- padding: 6,
2213
- textAlign: "center",
2214
- borderBottom: "none"
2215
- }
2216
- },
2217
- `${puja.name} - ${puja.bookings.length}`
2218
- )), /* @__PURE__ */ React11.createElement(
2219
- View9,
2220
- {
2221
- style: {
2222
- display: "flex",
2223
- flexDirection: "row",
2224
- border: "1px solid black"
2225
- }
2226
- },
2227
- /* @__PURE__ */ React11.createElement(
2228
- View9,
2229
- {
2230
- style: {
2231
- padding: 6,
2232
- fontSize: 10,
2233
- borderRight: "1px solid black",
2234
- fontWeight: "semibold",
2235
- width: "10%"
2236
- }
2237
- },
2238
- /* @__PURE__ */ React11.createElement(Text_default, null, "Sr No")
2239
- ),
2240
- /* @__PURE__ */ React11.createElement(
2241
- View9,
2242
- {
2243
- style: {
2244
- padding: 6,
2245
- fontSize: 10,
2246
- borderRight: "1px solid black",
2247
- fontWeight: "semibold",
2248
- width: "20%"
2249
- }
2250
- },
2251
- /* @__PURE__ */ React11.createElement(Text_default, null, "Invoice No")
2252
- ),
2253
- /* @__PURE__ */ React11.createElement(
2254
- View9,
2255
- {
2256
- style: {
2257
- padding: 6,
2258
- fontSize: 10,
2259
- borderRight: "1px solid black",
2260
- fontWeight: "semibold",
2261
- width: "35%"
2262
- }
2263
- },
2264
- /* @__PURE__ */ React11.createElement(Text_default, null, "Devotee Name")
2265
- ),
2266
- /* @__PURE__ */ React11.createElement(
2267
- View9,
2268
- {
2269
- style: {
2270
- padding: 6,
2271
- fontSize: 10,
2272
- borderRight: "1px solid black",
2273
- fontWeight: "semibold",
2274
- width: "25%"
2275
- }
2276
- },
2277
- /* @__PURE__ */ React11.createElement(Text_default, null, "Nakshatra")
2278
- ),
2279
- /* @__PURE__ */ React11.createElement(
2280
- View9,
2281
- {
2282
- style: {
2283
- padding: 6,
2284
- fontSize: 10,
2285
- borderRight: "none",
2286
- fontWeight: "semibold",
2287
- width: "10%"
2288
- }
2289
- },
2290
- /* @__PURE__ */ React11.createElement(Text_default, null, "Qty")
2291
- )
2292
- ), puja.bookings.map((booking, bookingIndex) => {
2293
- if (booking.is_early_reminder || booking.requires_coupon)
2294
- return null;
2295
- serialOfNormalPujas++;
2296
- return /* @__PURE__ */ React11.createElement(React11.Fragment, null, /* @__PURE__ */ React11.createElement(
2297
- View9,
2298
- {
2299
- style: {
2300
- display: "flex",
2301
- flexDirection: "row",
2302
- border: "1px solid black",
2303
- borderTop: "none",
2304
- width: "100%"
2305
- }
2306
- },
2307
- /* @__PURE__ */ React11.createElement(
2308
- View9,
2309
- {
2310
- style: {
2311
- padding: 6,
2312
- fontSize: 10,
2313
- borderRight: "1px solid black",
2314
- width: "10%"
2315
- }
2316
- },
2317
- /* @__PURE__ */ React11.createElement(Text_default, null, serialOfNormalPujas)
2318
- ),
2319
- /* @__PURE__ */ React11.createElement(
2320
- View9,
2321
- {
2322
- style: {
2323
- display: "flex",
2324
- flexDirection: "column",
2325
- width: "90%"
2326
- }
2327
- },
2328
- /* @__PURE__ */ React11.createElement(
2329
- View9,
2330
- {
2331
- style: {
2332
- display: "flex",
2333
- flexDirection: "row"
2334
- }
2335
- },
2336
- /* @__PURE__ */ React11.createElement(
2337
- View9,
2338
- {
2339
- style: {
2340
- padding: 6,
2341
- fontSize: 10,
2342
- borderRight: "1px solid black",
2343
- width: `${20 * 1.11111}%`
2344
- }
2345
- },
2346
- /* @__PURE__ */ React11.createElement(Text_default, null, booking.invoiceNumber)
2347
- ),
2348
- /* @__PURE__ */ React11.createElement(
2349
- View9,
2350
- {
2351
- style: {
2352
- padding: 6,
2353
- fontSize: 10,
2354
- borderRight: "1px solid black",
2355
- width: `${35 * 1.11111}%`
2356
- }
2357
- },
2358
- /* @__PURE__ */ React11.createElement(Text_default, null, booking.devoteeName)
2359
- ),
2360
- /* @__PURE__ */ React11.createElement(
2361
- View9,
2362
- {
2363
- style: {
2364
- padding: 6,
2365
- fontSize: 10,
2366
- borderRight: "1px solid black",
2367
- width: `${25 * 1.11111}%`
2368
- }
2369
- },
2370
- /* @__PURE__ */ React11.createElement(Text_default, null, booking.nakshatra)
2371
- ),
2372
- /* @__PURE__ */ React11.createElement(
2373
- View9,
2374
- {
2375
- style: {
2376
- padding: 6,
2377
- fontSize: 10,
2378
- borderRight: "none",
2379
- width: `${10 * 1.11111}%`
2380
- }
2381
- },
2382
- /* @__PURE__ */ React11.createElement(Text_default, null, booking.quantity)
2383
- )
2384
- ),
2385
- booking.priestNote && /* @__PURE__ */ React11.createElement(
2386
- View9,
2387
- {
2388
- style: {
2389
- padding: 6,
2390
- fontSize: 10,
2391
- borderTop: "1px solid black",
2392
- width: "100%"
2393
- }
2394
- },
2395
- /* @__PURE__ */ React11.createElement(Text_default, null, booking.priestNote)
2396
- )
2397
- )
2398
- ));
2399
- })));
2400
- })
2401
- )), pujaData.length > 0 && pujasRequiresCoupon && /* @__PURE__ */ React11.createElement(Page10, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React11.createElement(
2402
- Image10,
2403
- {
2404
- fixed: true,
2405
- style: {
2406
- height: 15,
2407
- width: 75,
2408
- marginBottom: 10
2409
- },
2410
- src: bmpLogo
2411
- }
2412
- ), /* @__PURE__ */ React11.createElement(
2413
- View9,
2414
- {
2415
- style: {
2416
- display: "flex",
2417
- flexDirection: "column",
2418
- marginTop: 10,
2419
- gap: 15
2420
- }
2421
- },
2422
- (() => {
2423
- const allCouponBookings = pujaData.flatMap(
2424
- (puja) => puja.bookings.filter((booking) => booking.requires_coupon).map((booking) => ({ ...booking, pujaName: puja.name }))
2425
- );
2426
- const grouped = {};
2427
- for (const booking of allCouponBookings) {
2428
- if (!grouped[booking.invoiceNumber])
2429
- grouped[booking.invoiceNumber] = [];
2430
- grouped[booking.invoiceNumber].push(booking);
2431
- }
2432
- return Object.entries(grouped).map(
2433
- ([invoiceNumber, bookings], groupIdx) => {
2434
- const bookingsArr = bookings;
2435
- const first = bookingsArr[0];
2436
- return /* @__PURE__ */ React11.createElement(
2437
- View9,
2438
- {
2439
- key: invoiceNumber,
2440
- style: {
2441
- marginBottom: 10,
2442
- fontSize: 18,
2443
- padding: 10,
2444
- border: "1px dotted black"
2445
- },
2446
- wrap: false
2447
- },
2448
- /* @__PURE__ */ React11.createElement(
2449
- View9,
2450
- {
2451
- style: {
2452
- display: "flex",
2453
- flexDirection: "row",
2454
- justifyContent: "space-between",
2455
- gap: 10
2456
- }
2457
- },
2458
- /* @__PURE__ */ React11.createElement(
2459
- View9,
2460
- {
2461
- style: {
2462
- display: "flex",
2463
- flexDirection: "row",
2464
- gap: 10
2465
- }
2466
- },
2467
- /* @__PURE__ */ React11.createElement(Text_default, { style: { fontWeight: "semibold" } }, invoiceNumber),
2468
- /* @__PURE__ */ React11.createElement(Text_default, null, first.date ? new Date(first.date).toDateString() : date.toDateString())
2469
- ),
2470
- /* @__PURE__ */ React11.createElement(Text_default, null, first.phone_number)
2471
- ),
2472
- /* @__PURE__ */ React11.createElement(View9, { style: { height: 15, width: "100%" } }),
2473
- bookingsArr.map(
2474
- (booking, idx) => /* @__PURE__ */ React11.createElement(
2475
- View9,
2476
- {
2477
- key: idx,
2478
- style: {
2479
- display: "flex",
2480
- flexDirection: "row",
2481
- marginTop: 25
2482
- }
2483
- },
2484
- /* @__PURE__ */ React11.createElement(Text_default, null, `${booking.devoteeName} ----- ${booking.nakshatra} ----- ${booking.pujaName}`)
2485
- )
2486
- )
2487
- );
2488
- }
2489
- );
2490
- })()
2491
- )), prasadData.length > 0 && /* @__PURE__ */ React11.createElement(Page10, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React11.createElement(
2492
- ReportHeader_default,
2493
- {
2494
- startDate: date,
2495
- reportTiming,
2496
- reportName: "Prasad Report",
2497
- templeName
2498
- }
2499
- ), /* @__PURE__ */ React11.createElement(
2500
- View9,
2501
- {
2502
- style: {
2503
- display: "flex",
2504
- flexDirection: "column",
2505
- marginTop: 20
2506
- }
2507
- },
2508
- /* @__PURE__ */ React11.createElement(
2509
- View9,
2510
- {
2511
- style: {
2512
- display: "flex",
2513
- flexDirection: "row",
2514
- border: "1px solid black",
2515
- fontWeight: "semibold",
2516
- fontSize: 10
2517
- }
2518
- },
2519
- /* @__PURE__ */ React11.createElement(
2520
- View9,
2521
- {
2522
- style: {
2523
- padding: 6,
2524
- borderRight: "1px solid black",
2525
- width: "10%"
2526
- }
2527
- },
2528
- /* @__PURE__ */ React11.createElement(Text_default, null, "Sr no")
2529
- ),
2530
- /* @__PURE__ */ React11.createElement(
2531
- View9,
2532
- {
2533
- style: {
2534
- padding: 6,
2535
- borderRight: "1px solid black",
2536
- width: "20%"
2537
- }
2538
- },
2539
- /* @__PURE__ */ React11.createElement(Text_default, null, "Invoice Number")
2540
- ),
2541
- /* @__PURE__ */ React11.createElement(
2542
- View9,
2543
- {
2544
- style: {
2545
- padding: 6,
2546
- borderRight: "1px solid black",
2547
- width: "30%"
2548
- }
2549
- },
2550
- /* @__PURE__ */ React11.createElement(Text_default, null, "Devotee Name")
2551
- ),
2552
- /* @__PURE__ */ React11.createElement(
2553
- View9,
2554
- {
2555
- style: {
2556
- padding: 6,
2557
- borderRight: "1px solid black",
2558
- width: "30%"
2559
- }
2560
- },
2561
- /* @__PURE__ */ React11.createElement(Text_default, null, "Prasad Name")
2562
- ),
2563
- /* @__PURE__ */ React11.createElement(
2564
- View9,
2565
- {
2566
- style: {
2567
- padding: 6,
2568
- width: "10%"
2569
- }
2570
- },
2571
- /* @__PURE__ */ React11.createElement(Text_default, null, "Qty")
2572
- )
2573
- ),
2574
- prasadData.map((item, index) => {
2575
- return /* @__PURE__ */ React11.createElement(
2576
- View9,
2577
- {
2578
- style: {
2579
- display: "flex",
2580
- flexDirection: "row",
2581
- border: "1px solid black",
2582
- borderTop: "none",
2583
- fontSize: 10
2584
- }
2585
- },
2586
- /* @__PURE__ */ React11.createElement(
2587
- View9,
2588
- {
2589
- style: {
2590
- padding: 6,
2591
- borderRight: "1px solid black",
2592
- width: "10%"
2593
- }
2594
- },
2595
- /* @__PURE__ */ React11.createElement(Text_default, null, index + 1)
2596
- ),
2597
- /* @__PURE__ */ React11.createElement(
2598
- View9,
2599
- {
2600
- style: {
2601
- padding: 6,
2602
- borderRight: "1px solid black",
2603
- width: "20%"
2604
- }
2605
- },
2606
- /* @__PURE__ */ React11.createElement(Text_default, null, item.invoiceNumber)
2607
- ),
2608
- /* @__PURE__ */ React11.createElement(
2609
- View9,
2610
- {
2611
- style: {
2612
- padding: 6,
2613
- borderRight: "1px solid black",
2614
- width: "30%"
2615
- }
2616
- },
2617
- /* @__PURE__ */ React11.createElement(Text_default, null, item.devoteeName)
2618
- ),
2619
- /* @__PURE__ */ React11.createElement(
2620
- View9,
2621
- {
2622
- style: {
2623
- padding: 6,
2624
- borderRight: "1px solid black",
2625
- width: "30%"
2626
- }
2627
- },
2628
- /* @__PURE__ */ React11.createElement(Text_default, null, item.prasadName)
2629
- ),
2630
- /* @__PURE__ */ React11.createElement(
2631
- View9,
2632
- {
2633
- style: {
2634
- padding: 6,
2635
- width: "10%"
2636
- }
2637
- },
2638
- /* @__PURE__ */ React11.createElement(Text_default, null, item.quantity)
2639
- )
2640
- );
2641
- })
2642
- )), deliveryData.length > 0 && /* @__PURE__ */ React11.createElement(Page10, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React11.createElement(
2643
- ReportHeader_default,
2644
- {
2645
- startDate: date,
2646
- reportTiming,
2647
- reportName: "Prasad Delivery Postal Report",
2648
- templeName
2649
- }
2650
- ), /* @__PURE__ */ React11.createElement(
2651
- View9,
2652
- {
2653
- style: {
2654
- display: "flex",
2655
- flexDirection: "row",
2656
- marginTop: 20,
2657
- width: "100%",
2658
- gap: 20,
2659
- flexWrap: "wrap"
2660
- }
2661
- },
2662
- deliveryData && deliveryData.map((item) => {
2663
- return /* @__PURE__ */ React11.createElement(
2664
- View9,
2665
- {
2666
- key: item.id,
2667
- style: {
2668
- width: "46%",
2669
- display: "flex",
2670
- flexDirection: "column",
2671
- border: "1px solid black",
2672
- borderStyle: "dotted",
2673
- borderWidth: 1.5,
2674
- padding: 6
2675
- }
2676
- },
2677
- /* @__PURE__ */ React11.createElement(
2678
- View9,
2679
- {
2680
- style: {
2681
- flexGrow: 1
2682
- }
2683
- },
2684
- /* @__PURE__ */ React11.createElement(Text_default, { style: { fontSize: 10, fontWeight: "bold" } }, item.name),
2685
- /* @__PURE__ */ React11.createElement(Text_default, { style: { fontSize: 10 } }, item.address),
2686
- /* @__PURE__ */ React11.createElement(Text_default, { style: { fontSize: 10 } }, item.phone)
2687
- ),
2688
- /* @__PURE__ */ React11.createElement(
2689
- View9,
2690
- {
2691
- style: {
2692
- borderTop: "1px solid black",
2693
- marginTop: 5,
2694
- paddingTop: 3,
2695
- borderStyle: "dotted"
2696
- }
2697
- }
2698
- ),
2699
- /* @__PURE__ */ React11.createElement(Text_default, { style: { fontSize: 9, marginTop: 3 } }, "Note: ", item.pujaDetails)
2700
- );
2701
- })
2702
- ))));
2703
- };
2704
- var A4CombinedReport_default = A4CombinedReport;
2705
-
2706
- // src/sizes/a4/A4MultiTemplePaymentReport.tsx
2707
- import { Document as Document11, Page as Page11, View as View10 } from "@react-pdf/renderer";
2708
- import React12 from "react";
2709
- var A4MultiTemplePaymentReport = ({
2710
- startDate,
2711
- endDate,
2712
- data
2713
- }) => {
2714
- return /* @__PURE__ */ React12.createElement(Document11, null, /* @__PURE__ */ React12.createElement(Page11, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React12.createElement(
2715
- ReportHeader_default,
2716
- {
2717
- startDate,
2718
- endDate,
2719
- reportName: "Temple Payment Report",
2720
- templeName: ""
2721
- }
2722
- ), /* @__PURE__ */ React12.createElement(
2723
- View10,
2724
- {
2725
- style: {
2726
- display: "flex",
2727
- flexDirection: "column",
2728
- marginTop: 20
2729
- }
2730
- },
2731
- /* @__PURE__ */ React12.createElement(
2732
- View10,
2733
- {
2734
- style: {
2735
- display: "flex",
2736
- flexDirection: "row",
2737
- border: "1px solid black",
2738
- fontWeight: "semibold",
2739
- fontSize: 10
2740
- }
2741
- },
2742
- /* @__PURE__ */ React12.createElement(
2743
- View10,
2744
- {
2745
- style: {
2746
- padding: 6,
2747
- borderRight: "1px solid black",
2748
- width: "10%"
2749
- }
2750
- },
2751
- /* @__PURE__ */ React12.createElement(Text_default, null, "S.No.")
2752
- ),
2753
- /* @__PURE__ */ React12.createElement(
2754
- View10,
2755
- {
2756
- style: {
2757
- padding: 6,
2758
- borderRight: "1px solid black",
2759
- width: "55%"
2760
- }
2761
- },
2762
- /* @__PURE__ */ React12.createElement(Text_default, null, "Temple Name")
2763
- ),
2764
- /* @__PURE__ */ React12.createElement(
2765
- View10,
2766
- {
2767
- style: {
2768
- padding: 6,
2769
- borderRight: "1px solid black",
2770
- width: "15%"
2771
- }
2772
- },
2773
- /* @__PURE__ */ React12.createElement(Text_default, null, "Bookings")
2774
- ),
2775
- /* @__PURE__ */ React12.createElement(
2776
- View10,
2777
- {
2778
- style: {
2779
- padding: 6,
2780
- width: "20%"
2781
- }
2782
- },
2783
- /* @__PURE__ */ React12.createElement(Text_default, null, "Revenue")
2784
- )
2785
- ),
2786
- data?.map((temple, index) => {
2787
- return /* @__PURE__ */ React12.createElement(
2788
- View10,
2789
- {
2790
- key: index,
2791
- style: {
2792
- display: "flex",
2793
- flexDirection: "row",
2794
- border: "1px solid black",
2795
- borderTop: "none",
2796
- fontSize: 10
2797
- }
2798
- },
2799
- /* @__PURE__ */ React12.createElement(
2800
- View10,
2801
- {
2802
- style: {
2803
- padding: 6,
2804
- borderRight: "1px solid black",
2805
- width: "10%"
2806
- }
2807
- },
2808
- /* @__PURE__ */ React12.createElement(Text_default, null, index + 1)
2809
- ),
2810
- /* @__PURE__ */ React12.createElement(
2811
- View10,
2812
- {
2813
- style: {
2814
- padding: 6,
2815
- borderRight: "1px solid black",
2816
- width: "55%"
2817
- }
2818
- },
2819
- /* @__PURE__ */ React12.createElement(Text_default, null, temple.name)
2820
- ),
2821
- /* @__PURE__ */ React12.createElement(
2822
- View10,
2823
- {
2824
- style: {
2825
- padding: 6,
2826
- borderRight: "1px solid black",
2827
- width: "15%"
2828
- }
2829
- },
2830
- /* @__PURE__ */ React12.createElement(Text_default, null, temple.bookings)
2831
- ),
2832
- /* @__PURE__ */ React12.createElement(
2833
- View10,
2834
- {
2835
- style: {
2836
- padding: 6,
2837
- width: "20%"
2838
- }
2839
- },
2840
- /* @__PURE__ */ React12.createElement(Text_default, null, "\u20B9", temple.revenue)
2841
- )
2842
- );
2843
- })
2844
- )));
2845
- };
2846
- var A4MultiTemplePaymentReport_default = A4MultiTemplePaymentReport;
2847
-
2848
- // src/sizes/a4/A4SettlementsReport.tsx
2849
- import React13 from "react";
2850
- import { Page as Page12, Document as Document12, View as View11 } from "@react-pdf/renderer";
2851
- var A4SettlementsReport = ({
2852
- startDate,
2853
- endDate,
2854
- templeName,
2855
- data
2856
- }) => {
2857
- return /* @__PURE__ */ React13.createElement(Document12, null, /* @__PURE__ */ React13.createElement(
2858
- Page12,
2859
- {
2860
- size: "A4",
2861
- style: {
2862
- padding: 30,
2863
- fontFamily: "Noto Sans"
2864
- }
2865
- },
2866
- /* @__PURE__ */ React13.createElement(
2867
- ReportHeader_default,
2868
- {
2869
- startDate,
2870
- endDate,
2871
- reportName: "Settlements Report",
2872
- templeName
2873
- }
2874
- ),
2875
- /* @__PURE__ */ React13.createElement(Text_default, { style: { fontSize: 10, marginTop: 10 } }, "Total Credited Amount: ", data.totalCreditedAmount),
2876
- data.settlements.length > 0 ? /* @__PURE__ */ React13.createElement(
2877
- View11,
2878
- {
2879
- style: {
2880
- display: "flex",
2881
- flexDirection: "column",
2882
- marginTop: 20
2883
- }
2884
- },
2885
- /* @__PURE__ */ React13.createElement(
2886
- View11,
2887
- {
2888
- style: {
2889
- display: "flex",
2890
- flexDirection: "row",
2891
- border: "1px solid #000",
2892
- fontSize: 10,
2893
- fontWeight: "semibold"
2894
- }
2895
- },
2896
- /* @__PURE__ */ React13.createElement(
2897
- View11,
2898
- {
2899
- style: {
2900
- padding: 6,
2901
- borderRight: "1px solid #000",
2902
- width: "10%"
2903
- }
2904
- },
2905
- /* @__PURE__ */ React13.createElement(Text_default, null, "Sr no")
2906
- ),
2907
- /* @__PURE__ */ React13.createElement(
2908
- View11,
2909
- {
2910
- style: {
2911
- padding: 6,
2912
- borderRight: "1px solid #000",
2913
- width: "15%"
2914
- }
2915
- },
2916
- /* @__PURE__ */ React13.createElement(Text_default, null, "Date")
2917
- ),
2918
- /* @__PURE__ */ React13.createElement(
2919
- View11,
2920
- {
2921
- style: {
2922
- padding: 6,
2923
- borderRight: "1px solid #000",
2924
- width: "15%"
2925
- }
2926
- },
2927
- /* @__PURE__ */ React13.createElement(Text_default, null, "Settlement")
2928
- ),
2929
- /* @__PURE__ */ React13.createElement(
2930
- View11,
2931
- {
2932
- style: {
2933
- padding: 6,
2934
- borderRight: "1px solid #000",
2935
- width: "20%"
2936
- }
2937
- },
2938
- /* @__PURE__ */ React13.createElement(Text_default, null, "UTR")
2939
- ),
2940
- /* @__PURE__ */ React13.createElement(
2941
- View11,
2942
- {
2943
- style: {
2944
- padding: 6,
2945
- borderRight: "1px solid #000",
2946
- width: "25%"
2947
- }
2948
- },
2949
- /* @__PURE__ */ React13.createElement(Text_default, null, "Invoice")
2950
- ),
2951
- /* @__PURE__ */ React13.createElement(
2952
- View11,
2953
- {
2954
- style: {
2955
- padding: 6,
2956
- // borderRight: "1px solid #000",
2957
- width: "20%"
2958
- }
2959
- },
2960
- /* @__PURE__ */ React13.createElement(Text_default, null, "Settlement ID")
2961
- )
2962
- ),
2963
- data.settlements?.map((item, index) => {
2964
- return /* @__PURE__ */ React13.createElement(
2965
- View11,
2966
- {
2967
- style: {
2968
- display: "flex",
2969
- flexDirection: "row",
2970
- border: "1px solid #000",
2971
- borderTop: "none",
2972
- fontSize: 10
2973
- }
2974
- },
2975
- /* @__PURE__ */ React13.createElement(
2976
- View11,
2977
- {
2978
- style: {
2979
- padding: 6,
2980
- borderRight: "1px solid #000",
2981
- width: "10%"
2982
- }
2983
- },
2984
- /* @__PURE__ */ React13.createElement(Text_default, null, index + 1)
2985
- ),
2986
- /* @__PURE__ */ React13.createElement(
2987
- View11,
2988
- {
2989
- style: {
2990
- padding: 6,
2991
- width: "15%",
2992
- // fontSize: 7,
2993
- borderRight: "1px solid #000"
2994
- }
2995
- },
2996
- /* @__PURE__ */ React13.createElement(Text_default, null, item.date)
2997
- ),
2998
- /* @__PURE__ */ React13.createElement(
2999
- View11,
3000
- {
3001
- style: {
3002
- padding: 6,
3003
- borderRight: "1px solid #000",
3004
- width: "15%"
3005
- }
3006
- },
3007
- /* @__PURE__ */ React13.createElement(Text_default, null, item.settlement_amount)
3008
- ),
3009
- /* @__PURE__ */ React13.createElement(
3010
- View11,
3011
- {
3012
- style: {
3013
- padding: 6,
3014
- borderRight: "1px solid #000",
3015
- width: "20%",
3016
- fontSize: 9
3017
- }
3018
- },
3019
- /* @__PURE__ */ React13.createElement(Text_default, null, item.utr.split("").map((line, index2) => /* @__PURE__ */ React13.createElement(Text_default, { key: index2 }, line)))
3020
- ),
3021
- /* @__PURE__ */ React13.createElement(
3022
- View11,
3023
- {
3024
- style: {
3025
- padding: 6,
3026
- borderRight: "1px solid #000",
3027
- width: "25%",
3028
- fontSize: 9
3029
- }
3030
- },
3031
- /* @__PURE__ */ React13.createElement(
3032
- View11,
3033
- {
3034
- style: {
3035
- display: "flex",
3036
- flexDirection: "column"
3037
- }
3038
- },
3039
- item.invoices.map((invoice, idx) => /* @__PURE__ */ React13.createElement(Text_default, { key: idx }, invoice.number, " (", invoice.amount, ")"))
3040
- )
3041
- ),
3042
- /* @__PURE__ */ React13.createElement(
3043
- View11,
3044
- {
3045
- style: {
3046
- padding: 6,
3047
- // borderRight: "1px solid #000",
3048
- width: "20%"
3049
- }
3050
- },
3051
- /* @__PURE__ */ React13.createElement(Text_default, null, item.settlement_id)
3052
- )
3053
- );
3054
- })
3055
- ) : /* @__PURE__ */ React13.createElement(
3056
- Text_default,
3057
- {
3058
- style: {
3059
- fontSize: 18,
3060
- textAlign: "center",
3061
- marginTop: 100
3062
- }
3063
- },
3064
- "No data available for the selected date range"
3065
- )
3066
- ));
3067
- };
3068
- var A4SettlementsReport_default = A4SettlementsReport;
3069
-
3070
- // src/sizes/a4/A4Invoice.tsx
3071
- import React14 from "react";
3072
- import { Document as Document13, Image as Image13, Page as Page13, View as View12 } from "@react-pdf/renderer";
3073
- var A4Invoice = ({ data }) => {
3074
- return /* @__PURE__ */ React14.createElement(Document13, null, /* @__PURE__ */ React14.createElement(Page13, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React14.createElement(
3075
- View12,
3076
- {
3077
- style: {
3078
- display: "flex",
3079
- flexDirection: "row"
3080
- }
3081
- },
3082
- /* @__PURE__ */ React14.createElement(
3083
- View12,
3084
- {
3085
- style: {
3086
- backgroundColor: "#FFA823",
3087
- width: 20,
3088
- height: "100%"
3089
- }
3090
- }
3091
- ),
3092
- /* @__PURE__ */ React14.createElement(View12, { style: { marginLeft: 15, marginTop: 10, marginBottom: 0 } }, /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 16, fontWeight: "bold" } }, data.templeName), /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 10 } }, data.templeAddress), /* @__PURE__ */ React14.createElement(
3093
- View12,
3094
- {
3095
- style: {
3096
- display: "flex",
3097
- flexDirection: "row",
3098
- gap: 5,
3099
- marginTop: 10,
3100
- alignItems: "center"
3101
- }
3102
- },
3103
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 10, marginTop: -5 } }, "Powered by"),
3104
- /* @__PURE__ */ React14.createElement(
3105
- Image13,
3106
- {
3107
- style: {
3108
- height: 25,
3109
- width: 95,
3110
- // marginBottom: 5,
3111
- objectFit: "contain"
3112
- },
3113
- src: bmpLogo2
3114
- }
3115
- )
3116
- ))
3117
- ), /* @__PURE__ */ React14.createElement(
3118
- View12,
3119
- {
3120
- style: {
3121
- display: "flex",
3122
- flexDirection: "column",
3123
- alignItems: "center",
3124
- marginTop: 20,
3125
- position: "relative"
3126
- }
3127
- },
3128
- data.status === "confirmed" ? /* @__PURE__ */ React14.createElement(
3129
- Image13,
3130
- {
3131
- style: {
3132
- height: 85,
3133
- width: 85,
3134
- marginBottom: 5,
3135
- objectFit: "contain",
3136
- position: "absolute",
3137
- right: "0",
3138
- bottom: "0"
3139
- },
3140
- src: paidIcon
3141
- }
3142
- ) : null,
3143
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 12, marginTop: 5, fontWeight: "semibold" } }, "INVOICE #", data.invoiceNumber),
3144
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 10, marginTop: 2 } }, "Status: ", data.status == "confirmed" ? "PAID" : "PENDING")
3145
- ), /* @__PURE__ */ React14.createElement(
3146
- View12,
3147
- {
3148
- style: {
3149
- marginTop: 10
3150
- }
3151
- },
3152
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 11 } }, "Bill to:"),
3153
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 11 } }, data.devoteeDetails.name),
3154
- data.devoteeDetails.phone ? /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 11 } }, data.devoteeDetails.phone) : null,
3155
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 11 } }, data.bookingDate)
3156
- ), /* @__PURE__ */ React14.createElement(
3157
- View12,
3158
- {
3159
- style: {
3160
- display: "flex",
3161
- flexDirection: "column",
3162
- marginTop: 20
3163
- }
3164
- },
3165
- /* @__PURE__ */ React14.createElement(
3166
- View12,
3167
- {
3168
- style: {
3169
- display: "flex",
3170
- flexDirection: "row",
3171
- borderBottom: "1px solid #757575",
3172
- fontSize: 10,
3173
- fontWeight: "semibold"
3174
- }
3175
- },
3176
- /* @__PURE__ */ React14.createElement(
3177
- View12,
3178
- {
3179
- style: {
3180
- padding: 6,
3181
- borderRight: "1px solid #b5b5b5",
3182
- width: "50%"
3183
- }
3184
- },
3185
- /* @__PURE__ */ React14.createElement(Text_default, null, "Item Description")
3186
- ),
3187
- /* @__PURE__ */ React14.createElement(
3188
- View12,
3189
- {
3190
- style: {
3191
- padding: 6,
3192
- borderRight: "1px solid #b5b5b5",
3193
- width: "15%",
3194
- textAlign: "center"
3195
- }
3196
- },
3197
- /* @__PURE__ */ React14.createElement(Text_default, null, "Price")
3198
- ),
3199
- /* @__PURE__ */ React14.createElement(
3200
- View12,
3201
- {
3202
- style: {
3203
- padding: 6,
3204
- borderRight: "1px solid #b5b5b5",
3205
- width: "15%",
3206
- textAlign: "center"
3207
- }
3208
- },
3209
- /* @__PURE__ */ React14.createElement(Text_default, null, "Quantity")
3210
- ),
3211
- /* @__PURE__ */ React14.createElement(
3212
- View12,
3213
- {
3214
- style: {
3215
- padding: 6,
3216
- // borderRight: "1px solid #b5b5b5",
3217
- width: "20%",
3218
- textAlign: "center"
3219
- }
3220
- },
3221
- /* @__PURE__ */ React14.createElement(Text_default, null, "Total")
3222
- )
3223
- ),
3224
- data.items.map((item, index) => {
3225
- return /* @__PURE__ */ React14.createElement(
3226
- View12,
3227
- {
3228
- wrap: false,
3229
- style: {
3230
- display: "flex",
3231
- flexDirection: "row",
3232
- borderBottom: "1px solid #757575",
3233
- fontSize: 10
3234
- }
3235
- },
3236
- /* @__PURE__ */ React14.createElement(
3237
- View12,
3238
- {
3239
- style: {
3240
- padding: 6,
3241
- borderRight: "1px solid #b5b5b5",
3242
- width: "50%"
3243
- }
3244
- },
3245
- item.pujaName ? /* @__PURE__ */ React14.createElement(
3246
- Text_default,
3247
- {
3248
- style: {
3249
- fontSize: 11
3250
- }
3251
- },
3252
- item.pujaName
3253
- ) : null,
3254
- item.devoteesName ? /* @__PURE__ */ React14.createElement(
3255
- Text_default,
3256
- {
3257
- style: {
3258
- fontSize: 9,
3259
- color: "#333333"
3260
- }
3261
- },
3262
- item.devoteesName
3263
- ) : null,
3264
- item.pujaDate ? /* @__PURE__ */ React14.createElement(
3265
- Text_default,
3266
- {
3267
- style: {
3268
- fontSize: 9,
3269
- color: "#333333"
3270
- }
3271
- },
3272
- item.pujaDate,
3273
- " ",
3274
- item.timing ? `- ${item.timing}` : null
3275
- ) : null,
3276
- item.repeatEndDate && item.repeatStartDate ? /* @__PURE__ */ React14.createElement(
3277
- Text_default,
3278
- {
3279
- style: {
3280
- fontSize: 9,
3281
- color: "#333333"
3282
- }
3283
- },
3284
- item.repeatStartDate,
3285
- " to ",
3286
- item.repeatEndDate,
3287
- " ",
3288
- item.timing ? `- ${item.timing}` : null
3289
- ) : null
3290
- ),
3291
- /* @__PURE__ */ React14.createElement(
3292
- View12,
3293
- {
3294
- style: {
3295
- padding: 6,
3296
- borderRight: "1px solid #b5b5b5",
3297
- width: "15%",
3298
- textAlign: "center",
3299
- display: "flex",
3300
- alignItems: "center",
3301
- justifyContent: "center"
3302
- }
3303
- },
3304
- /* @__PURE__ */ React14.createElement(Text_default, { style: {} }, item.basePujPrice)
3305
- ),
3306
- /* @__PURE__ */ React14.createElement(
3307
- View12,
3308
- {
3309
- style: {
3310
- padding: 6,
3311
- borderRight: "1px solid #b5b5b5",
3312
- width: "15%",
3313
- textAlign: "center",
3314
- display: "flex",
3315
- alignItems: "center",
3316
- justifyContent: "center"
3317
- }
3318
- },
3319
- /* @__PURE__ */ React14.createElement(Text_default, { style: {} }, `${item.quantity ? item.quantity : ""}${item.repeatCount ? ` x ${item.repeatCount}` : ""}`)
3320
- ),
3321
- /* @__PURE__ */ React14.createElement(
3322
- View12,
3323
- {
3324
- style: {
3325
- padding: 6,
3326
- width: "20%",
3327
- textAlign: "center",
3328
- display: "flex",
3329
- alignItems: "center",
3330
- justifyContent: "center"
3331
- }
3332
- },
3333
- /* @__PURE__ */ React14.createElement(Text_default, { style: {} }, item.totalPrice)
3334
- )
3335
- );
3336
- })
3337
- ), /* @__PURE__ */ React14.createElement(
3338
- View12,
3339
- {
3340
- style: {
3341
- display: "flex",
3342
- flexDirection: "row",
3343
- marginVertical: 40,
3344
- marginHorizontal: 20
3345
- }
3346
- },
3347
- /* @__PURE__ */ React14.createElement(
3348
- View12,
3349
- {
3350
- style: {
3351
- width: "50%",
3352
- display: "flex",
3353
- flexDirection: "column",
3354
- justifyContent: "center",
3355
- fontSize: 11
3356
- }
3357
- },
3358
- /* @__PURE__ */ React14.createElement(
3359
- Text_default,
3360
- {
3361
- style: {
3362
- fontWeight: "bold"
3363
- }
3364
- },
3365
- "Payment Method:"
3366
- ),
3367
- /* @__PURE__ */ React14.createElement(Text_default, null, data.paymentMethod)
3368
- ),
3369
- /* @__PURE__ */ React14.createElement(
3370
- View12,
3371
- {
3372
- style: {
3373
- width: "50%",
3374
- display: "flex",
3375
- flexDirection: "column",
3376
- justifyContent: "center",
3377
- alignItems: "flex-end"
3378
- }
3379
- },
3380
- /* @__PURE__ */ React14.createElement(
3381
- View12,
3382
- {
3383
- style: {
3384
- display: "flex",
3385
- flexDirection: "row",
3386
- gap: 10,
3387
- fontSize: 10
3388
- }
3389
- },
3390
- /* @__PURE__ */ React14.createElement(
3391
- View12,
3392
- {
3393
- style: {
3394
- width: "50%",
3395
- textAlign: "right"
3396
- }
3397
- },
3398
- /* @__PURE__ */ React14.createElement(Text_default, null, "Subtotal: ")
3399
- ),
3400
- /* @__PURE__ */ React14.createElement(
3401
- View12,
3402
- {
3403
- style: {
3404
- width: "30%",
3405
- textAlign: "right"
3406
- }
3407
- },
3408
- /* @__PURE__ */ React14.createElement(Text_default, null, data.subTotal)
3409
- )
3410
- ),
3411
- data.postalCharges ? /* @__PURE__ */ React14.createElement(
3412
- View12,
3413
- {
3414
- style: {
3415
- display: "flex",
3416
- flexDirection: "row",
3417
- gap: 10,
3418
- fontSize: 10
3419
- }
3420
- },
3421
- /* @__PURE__ */ React14.createElement(
3422
- View12,
3423
- {
3424
- style: {
3425
- width: "70%",
3426
- textAlign: "right"
3427
- }
3428
- },
3429
- /* @__PURE__ */ React14.createElement(Text_default, null, "Postal Charges: ")
3430
- ),
3431
- /* @__PURE__ */ React14.createElement(
3432
- View12,
3433
- {
3434
- style: {
3435
- width: "30%",
3436
- textAlign: "right"
3437
- }
3438
- },
3439
- /* @__PURE__ */ React14.createElement(Text_default, null, data.postalCharges)
3440
- )
3441
- ) : null,
3442
- /* @__PURE__ */ React14.createElement(
3443
- View12,
3444
- {
3445
- style: {
3446
- display: "flex",
3447
- flexDirection: "row",
3448
- gap: 10,
3449
- fontSize: 10
3450
- }
3451
- },
3452
- /* @__PURE__ */ React14.createElement(
3453
- View12,
3454
- {
3455
- style: {
3456
- width: "70%",
3457
- textAlign: "right"
3458
- }
3459
- },
3460
- /* @__PURE__ */ React14.createElement(Text_default, null, "Payment Gateway Charges: ")
3461
- ),
3462
- /* @__PURE__ */ React14.createElement(
3463
- View12,
3464
- {
3465
- style: {
3466
- width: "30%",
3467
- textAlign: "right"
3468
- }
3469
- },
3470
- /* @__PURE__ */ React14.createElement(Text_default, null, data.paymentGatewayCharges)
3471
- )
3472
- ),
3473
- /* @__PURE__ */ React14.createElement(
3474
- View12,
3475
- {
3476
- style: {
3477
- display: "flex",
3478
- flexDirection: "row",
3479
- gap: 10,
3480
- fontSize: 10
3481
- }
3482
- },
3483
- /* @__PURE__ */ React14.createElement(
3484
- View12,
3485
- {
3486
- style: {
3487
- width: "70%",
3488
- textAlign: "right"
3489
- }
3490
- },
3491
- /* @__PURE__ */ React14.createElement(Text_default, null, "Platform Charges: ")
3492
- ),
3493
- /* @__PURE__ */ React14.createElement(
3494
- View12,
3495
- {
3496
- style: {
3497
- width: "30%",
3498
- textAlign: "right"
3499
- }
3500
- },
3501
- /* @__PURE__ */ React14.createElement(Text_default, null, data.platformCharges)
3502
- )
3503
- ),
3504
- /* @__PURE__ */ React14.createElement(
3505
- View12,
3506
- {
3507
- style: {
3508
- display: "flex",
3509
- flexDirection: "row",
3510
- gap: 10,
3511
- fontSize: 10
3512
- }
3513
- },
3514
- /* @__PURE__ */ React14.createElement(
3515
- View12,
3516
- {
3517
- style: {
3518
- width: "70%",
3519
- textAlign: "right"
3520
- }
3521
- },
3522
- /* @__PURE__ */ React14.createElement(Text_default, null, "GST (18%): ")
3523
- ),
3524
- /* @__PURE__ */ React14.createElement(
3525
- View12,
3526
- {
3527
- style: {
3528
- width: "30%",
3529
- textAlign: "right"
3530
- }
3531
- },
3532
- /* @__PURE__ */ React14.createElement(Text_default, null, data.gst)
3533
- )
3534
- ),
3535
- /* @__PURE__ */ React14.createElement(
3536
- View12,
3537
- {
3538
- style: {
3539
- width: "60%",
3540
- height: 1,
3541
- backgroundColor: "#757575",
3542
- marginVertical: 5
3543
- }
3544
- }
3545
- ),
3546
- /* @__PURE__ */ React14.createElement(
3547
- View12,
3548
- {
3549
- style: {
3550
- display: "flex",
3551
- flexDirection: "row",
3552
- gap: 10,
3553
- fontSize: 10,
3554
- fontWeight: "bold"
3555
- }
3556
- },
3557
- /* @__PURE__ */ React14.createElement(
3558
- View12,
3559
- {
3560
- style: {
3561
- width: "70%",
3562
- textAlign: "right"
3563
- }
3564
- },
3565
- /* @__PURE__ */ React14.createElement(Text_default, null, "Total: ")
3566
- ),
3567
- /* @__PURE__ */ React14.createElement(
3568
- View12,
3569
- {
3570
- style: {
3571
- width: "30%",
3572
- textAlign: "right"
3573
- }
3574
- },
3575
- /* @__PURE__ */ React14.createElement(Text_default, null, data.totalAmount)
3576
- )
3577
- )
3578
- )
3579
- ), data.prasads && (data.prasads.morning.length > 0 || data.prasads.afternoon.length > 0 || data.prasads.evening.length > 0) ? /* @__PURE__ */ React14.createElement(
3580
- View12,
3581
- {
3582
- style: {
3583
- display: "flex",
3584
- flexDirection: "column",
3585
- marginBottom: 30
3586
- }
3587
- },
3588
- /* @__PURE__ */ React14.createElement(
3589
- View12,
3590
- {
3591
- style: {
3592
- backgroundColor: "#FF266F",
3593
- padding: 5
3594
- }
3595
- },
3596
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 10, fontWeight: "bold", color: "white" } }, "Prasadsam Details")
3597
- ),
3598
- data.prasads.morning.length > 0 ? /* @__PURE__ */ React14.createElement(
3599
- View12,
3600
- {
3601
- wrap: false,
3602
- style: {
3603
- display: "flex",
3604
- flexDirection: "column",
3605
- paddingHorizontal: 10,
3606
- paddingVertical: 5,
3607
- borderBottom: "1px solid #757575",
3608
- borderRight: "1px solid #757575",
3609
- borderLeft: "1px solid #757575"
3610
- }
3611
- },
3612
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 9, fontWeight: "bold" } }, "Morning:"),
3613
- data.prasads.morning.map((prasad, index) => /* @__PURE__ */ React14.createElement(Text_default, { key: index, style: { fontSize: 10 } }, index + 1, ". ", prasad.name, " (", prasad.timings, ")"))
3614
- ) : null,
3615
- data.prasads.afternoon.length > 0 ? /* @__PURE__ */ React14.createElement(
3616
- View12,
3617
- {
3618
- wrap: false,
3619
- style: {
3620
- display: "flex",
3621
- flexDirection: "column",
3622
- paddingHorizontal: 10,
3623
- paddingVertical: 5,
3624
- borderBottom: "1px solid #757575",
3625
- borderRight: "1px solid #757575",
3626
- borderLeft: "1px solid #757575"
3627
- }
3628
- },
3629
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 9, fontWeight: "bold" } }, "Afternoon:"),
3630
- data.prasads.afternoon.map((prasad, index) => /* @__PURE__ */ React14.createElement(Text_default, { key: index, style: { fontSize: 10 } }, index + 1, ". ", prasad.name, " (", prasad.timings, ")"))
3631
- ) : null,
3632
- data.prasads.evening.length > 0 ? /* @__PURE__ */ React14.createElement(
3633
- View12,
3634
- {
3635
- wrap: false,
3636
- style: {
3637
- display: "flex",
3638
- flexDirection: "column",
3639
- paddingHorizontal: 10,
3640
- paddingVertical: 5,
3641
- borderBottom: "1px solid #757575",
3642
- borderRight: "1px solid #757575",
3643
- borderLeft: "1px solid #757575"
3644
- }
3645
- },
3646
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 9, fontWeight: "bold" } }, "Evening:"),
3647
- data.prasads.evening.map((prasad, index) => /* @__PURE__ */ React14.createElement(Text_default, { key: index, style: { fontSize: 10 } }, index + 1, ". ", prasad.name, " (", prasad.timings, ")"))
3648
- ) : null
3649
- ) : null, data.instructions.length > 0 ? /* @__PURE__ */ React14.createElement(
3650
- View12,
3651
- {
3652
- style: {
3653
- display: "flex",
3654
- flexDirection: "column",
3655
- marginHorizontal: 20,
3656
- fontSize: 8,
3657
- border: "1px solid #757575"
3658
- }
3659
- },
3660
- /* @__PURE__ */ React14.createElement(
3661
- View12,
3662
- {
3663
- style: {
3664
- backgroundColor: "#FFA823",
3665
- paddingHorizontal: 10,
3666
- paddingVertical: 5
3667
- }
3668
- },
3669
- /* @__PURE__ */ React14.createElement(Text_default, null, "IMPORTANT INSTRUCTIONS:")
3670
- ),
3671
- /* @__PURE__ */ React14.createElement(
3672
- View12,
3673
- {
3674
- style: {
3675
- display: "flex",
3676
- flexDirection: "column",
3677
- gap: 5,
3678
- marginVertical: 10,
3679
- paddingHorizontal: 10
3680
- }
3681
- },
3682
- data.instructions.map((instruction, index) => /* @__PURE__ */ React14.createElement(Text_default, { key: index, style: { fontSize: 8 } }, index + 1, ") ", instruction.instruction))
3683
- )
3684
- ) : null, /* @__PURE__ */ React14.createElement(
3685
- View12,
3686
- {
3687
- style: {
3688
- display: "flex",
3689
- flexDirection: "row",
3690
- marginTop: 20
3691
- }
3692
- },
3693
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 8, fontWeight: "bold" } }, "Terms and Conditions:"),
3694
- /* @__PURE__ */ React14.createElement(Text_default, { style: { fontSize: 8, marginLeft: 5 } }, "https://www.bookmypuja.app/terms-and-condition")
3695
- )));
3696
- };
3697
- var A4Invoice_default = A4Invoice;
3698
-
3699
- // src/sizes/a4/A4PostalReport.tsx
3700
- import { Document as Document14, Page as Page14, View as View13 } from "@react-pdf/renderer";
3701
- import React15 from "react";
3702
- var A4PostalReport = ({ date, templeName, data }) => {
3703
- return /* @__PURE__ */ React15.createElement(Document14, null, /* @__PURE__ */ React15.createElement(Page14, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React15.createElement(
3704
- ReportHeader_default,
3705
- {
3706
- startDate: date,
3707
- reportName: "Prasad Delivery Postal Report",
3708
- templeName
3709
- }
3710
- ), data && data.length > 0 ? /* @__PURE__ */ React15.createElement(
3711
- View13,
3712
- {
3713
- style: {
3714
- display: "flex",
3715
- flexDirection: "row",
3716
- marginTop: 20,
3717
- width: "100%",
3718
- gap: 20,
3719
- flexWrap: "wrap"
3720
- }
3721
- },
3722
- data.map((item) => {
3723
- return /* @__PURE__ */ React15.createElement(
3724
- View13,
3725
- {
3726
- key: item.id,
3727
- style: {
3728
- width: "46%",
3729
- display: "flex",
3730
- flexDirection: "column",
3731
- border: "1px solid black",
3732
- borderStyle: "dotted",
3733
- borderWidth: 1.5,
3734
- padding: 6
3735
- }
3736
- },
3737
- /* @__PURE__ */ React15.createElement(
3738
- View13,
3739
- {
3740
- style: {
3741
- flexGrow: 1
3742
- }
3743
- },
3744
- /* @__PURE__ */ React15.createElement(Text_default, { style: { fontSize: 10, fontWeight: "bold" } }, item.name),
3745
- /* @__PURE__ */ React15.createElement(Text_default, { style: { fontSize: 10 } }, item.address),
3746
- /* @__PURE__ */ React15.createElement(Text_default, { style: { fontSize: 10 } }, item.phone)
3747
- ),
3748
- /* @__PURE__ */ React15.createElement(
3749
- View13,
3750
- {
3751
- style: {
3752
- borderTop: "1px solid black",
3753
- marginTop: 5,
3754
- paddingTop: 3,
3755
- borderStyle: "dotted"
3756
- }
3757
- }
3758
- ),
3759
- /* @__PURE__ */ React15.createElement(Text_default, { style: { fontSize: 9, marginTop: 3 } }, "Note: ", item.pujaDetails)
3760
- );
3761
- })
3762
- ) : /* @__PURE__ */ React15.createElement(
3763
- Text_default,
3764
- {
3765
- style: {
3766
- fontSize: 18,
3767
- textAlign: "center",
3768
- marginTop: 100
3769
- }
3770
- },
3771
- "No data available for the selected date range"
3772
- )));
3773
- };
3774
- var A4PostalReport_default = A4PostalReport;
3775
-
3776
- // src/sizes/a4/A4PaymentSettlementReport.tsx
3777
- import { Document as Document15, Page as Page15, View as View15 } from "@react-pdf/renderer";
3778
- import React17 from "react";
3779
-
3780
- // src/components/BrokenText.tsx
3781
- import React16 from "react";
3782
- import { View as View14 } from "@react-pdf/renderer";
3783
- var BrokenText = ({ children }) => {
3784
- if (!children || typeof children !== "string") return null;
3785
- return /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(
3786
- View14,
3787
- {
3788
- style: {
3789
- display: "flex",
3790
- flexDirection: "row",
3791
- flexWrap: "wrap"
3792
- }
3793
- },
3794
- children.split("").map((char, charIndex) => /* @__PURE__ */ React16.createElement(Text_default, { key: charIndex }, char))
3795
- ));
3796
- };
3797
- var BrokenText_default = BrokenText;
3798
-
3799
- // src/sizes/a4/A4PaymentSettlementReport.tsx
3800
- var A4PaymentSettlementReport = ({
3801
- startDate,
3802
- endDate,
3803
- templeName,
3804
- data
3805
- }) => {
3806
- return /* @__PURE__ */ React17.createElement(React17.Fragment, null, /* @__PURE__ */ React17.createElement(Document15, null, /* @__PURE__ */ React17.createElement(Page15, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React17.createElement(
3807
- ReportHeader_default,
3808
- {
3809
- startDate,
3810
- endDate,
3811
- reportName: "Payment Settlement Report",
3812
- templeName
3813
- }
3814
- ), data.length > 0 ? /* @__PURE__ */ React17.createElement(
3815
- View15,
3816
- {
3817
- style: {
3818
- display: "flex",
3819
- flexDirection: "column",
3820
- marginTop: 20
3821
- }
3822
- },
3823
- /* @__PURE__ */ React17.createElement(
3824
- View15,
3825
- {
3826
- style: {
3827
- display: "flex",
3828
- flexDirection: "row",
3829
- border: "1px solid #000",
3830
- fontSize: 10,
3831
- fontWeight: "semibold"
3832
- }
3833
- },
3834
- /* @__PURE__ */ React17.createElement(
3835
- View15,
3836
- {
3837
- style: {
3838
- padding: 6,
3839
- borderRight: "1px solid #000",
3840
- width: "10%"
3841
- }
3842
- },
3843
- /* @__PURE__ */ React17.createElement(Text_default, null, "Sr no")
3844
- ),
3845
- /* @__PURE__ */ React17.createElement(
3846
- View15,
3847
- {
3848
- style: {
3849
- padding: 6,
3850
- borderRight: "1px solid #000",
3851
- width: "15%"
3852
- }
3853
- },
3854
- /* @__PURE__ */ React17.createElement(Text_default, null, "Invoice No")
3855
- ),
3856
- /* @__PURE__ */ React17.createElement(
3857
- View15,
3858
- {
3859
- style: {
3860
- padding: 6,
3861
- borderRight: "1px solid #000",
3862
- width: "15%"
3863
- }
3864
- },
3865
- /* @__PURE__ */ React17.createElement(Text_default, null, "Amount")
3866
- ),
3867
- /* @__PURE__ */ React17.createElement(
3868
- View15,
3869
- {
3870
- style: {
3871
- padding: 6,
3872
- borderRight: "1px solid #000",
3873
- width: "20%"
3874
- }
3875
- },
3876
- /* @__PURE__ */ React17.createElement(Text_default, null, "Payment Date")
3877
- ),
3878
- /* @__PURE__ */ React17.createElement(
3879
- View15,
3880
- {
3881
- style: {
3882
- padding: 6,
3883
- borderRight: "1px solid #000",
3884
- width: "20%"
3885
- }
3886
- },
3887
- /* @__PURE__ */ React17.createElement(Text_default, null, "Settlement Date")
3888
- ),
3889
- /* @__PURE__ */ React17.createElement(
3890
- View15,
3891
- {
3892
- style: {
3893
- padding: 6,
3894
- // borderRight: "1px solid #000",
3895
- borderRight: "none",
3896
- width: "25%"
3897
- }
3898
- },
3899
- /* @__PURE__ */ React17.createElement(Text_default, null, "Bank UTR No")
3900
- )
3901
- ),
3902
- data.map((item, index) => {
3903
- return /* @__PURE__ */ React17.createElement(
3904
- View15,
3905
- {
3906
- style: {
3907
- display: "flex",
3908
- flexDirection: "row",
3909
- border: "1px solid #000",
3910
- borderTop: "none",
3911
- fontSize: 10
3912
- }
3913
- },
3914
- /* @__PURE__ */ React17.createElement(
3915
- View15,
3916
- {
3917
- style: {
3918
- padding: 6,
3919
- borderRight: "1px solid #000",
3920
- width: "10%"
3921
- }
3922
- },
3923
- /* @__PURE__ */ React17.createElement(Text_default, null, index + 1)
3924
- ),
3925
- /* @__PURE__ */ React17.createElement(
3926
- View15,
3927
- {
3928
- style: {
3929
- padding: 6,
3930
- borderRight: "1px solid #000",
3931
- width: "15%"
3932
- }
3933
- },
3934
- /* @__PURE__ */ React17.createElement(BrokenText_default, null, item.invoiceNo)
3935
- ),
3936
- /* @__PURE__ */ React17.createElement(
3937
- View15,
3938
- {
3939
- style: {
3940
- padding: 6,
3941
- borderRight: "1px solid #000",
3942
- width: "15%"
3943
- }
3944
- },
3945
- /* @__PURE__ */ React17.createElement(BrokenText_default, null, item.amount)
3946
- ),
3947
- /* @__PURE__ */ React17.createElement(
3948
- View15,
3949
- {
3950
- style: {
3951
- padding: 6,
3952
- borderRight: "1px solid #000",
3953
- width: "20%"
3954
- }
3955
- },
3956
- /* @__PURE__ */ React17.createElement(BrokenText_default, null, item.paymentDate)
3957
- ),
3958
- /* @__PURE__ */ React17.createElement(
3959
- View15,
3960
- {
3961
- style: {
3962
- padding: 6,
3963
- borderRight: "1px solid #000",
3964
- width: "20%"
3965
- }
3966
- },
3967
- /* @__PURE__ */ React17.createElement(BrokenText_default, null, item.settlementDate)
3968
- ),
3969
- /* @__PURE__ */ React17.createElement(
3970
- View15,
3971
- {
3972
- style: {
3973
- padding: 6,
3974
- // borderRight: "1px solid #000",
3975
- borderRight: "none",
3976
- width: "25%"
3977
- }
3978
- },
3979
- /* @__PURE__ */ React17.createElement(BrokenText_default, null, item.bankUtrNo)
3980
- )
3981
- );
3982
- })
3983
- ) : /* @__PURE__ */ React17.createElement(
3984
- Text_default,
3985
- {
3986
- style: {
3987
- fontSize: 18,
3988
- textAlign: "center",
3989
- marginTop: 100
3990
- }
3991
- },
3992
- "No data available for the selected date range"
3993
- ))));
3994
- };
3995
- var A4PaymentSettlementReport_default = A4PaymentSettlementReport;
3996
-
3997
- // src/sizes/a4/A4InvoiceLevelBreakup.tsx
3998
- import { Document as Document16, Page as Page16, View as View16 } from "@react-pdf/renderer";
3999
- import React18 from "react";
4000
- var A4InvoiceLevelBreakup = ({
4001
- startDate,
4002
- endDate,
4003
- templeName,
4004
- data
4005
- }) => {
4006
- return /* @__PURE__ */ React18.createElement(React18.Fragment, null, /* @__PURE__ */ React18.createElement(Document16, null, /* @__PURE__ */ React18.createElement(Page16, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React18.createElement(
4007
- ReportHeader_default,
4008
- {
4009
- startDate,
4010
- endDate,
4011
- reportName: "Invoice Level Breakup",
4012
- templeName
4013
- }
4014
- ), data.length > 0 ? /* @__PURE__ */ React18.createElement(
4015
- View16,
4016
- {
4017
- style: {
4018
- display: "flex",
4019
- flexDirection: "column",
4020
- marginTop: 20
4021
- }
4022
- },
4023
- /* @__PURE__ */ React18.createElement(
4024
- View16,
4025
- {
4026
- style: {
4027
- display: "flex",
4028
- flexDirection: "row",
4029
- border: "1px solid #000",
4030
- fontSize: 8,
4031
- fontWeight: "semibold"
4032
- }
4033
- },
4034
- /* @__PURE__ */ React18.createElement(
4035
- View16,
4036
- {
4037
- style: {
4038
- padding: 3,
4039
- borderRight: "1px solid #000",
4040
- width: "4%"
4041
- }
4042
- },
4043
- /* @__PURE__ */ React18.createElement(Text_default, null, "Sr no")
4044
- ),
4045
- /* @__PURE__ */ React18.createElement(
4046
- View16,
4047
- {
4048
- style: {
4049
- padding: 3,
4050
- borderRight: "1px solid #000",
4051
- width: "9%"
4052
- }
4053
- },
4054
- /* @__PURE__ */ React18.createElement(Text_default, null, "Invoice Number")
4055
- ),
4056
- /* @__PURE__ */ React18.createElement(
4057
- View16,
4058
- {
4059
- style: {
4060
- padding: 3,
4061
- borderRight: "1px solid #000",
4062
- width: "9%"
4063
- }
4064
- },
4065
- /* @__PURE__ */ React18.createElement(Text_default, null, "Base Amount")
4066
- ),
4067
- /* @__PURE__ */ React18.createElement(
4068
- View16,
4069
- {
4070
- style: {
4071
- padding: 3,
4072
- borderRight: "1px solid #000",
4073
- width: "9%"
4074
- }
4075
- },
4076
- /* @__PURE__ */ React18.createElement(Text_default, null, "Platform Fees")
4077
- ),
4078
- /* @__PURE__ */ React18.createElement(
4079
- View16,
4080
- {
4081
- style: {
4082
- padding: 3,
4083
- borderRight: "1px solid #000",
4084
- width: "9%"
4085
- }
4086
- },
4087
- /* @__PURE__ */ React18.createElement(Text_default, null, "Platform Fees GST")
4088
- ),
4089
- /* @__PURE__ */ React18.createElement(
4090
- View16,
4091
- {
4092
- style: {
4093
- padding: 3,
4094
- borderRight: "1px solid #000",
4095
- width: "9%"
4096
- }
4097
- },
4098
- /* @__PURE__ */ React18.createElement(Text_default, null, "Gateway Charges")
4099
- ),
4100
- /* @__PURE__ */ React18.createElement(
4101
- View16,
4102
- {
4103
- style: {
4104
- padding: 3,
4105
- borderRight: "1px solid #000",
4106
- width: "9%"
4107
- }
4108
- },
4109
- /* @__PURE__ */ React18.createElement(Text_default, null, "Gateway GST")
4110
- ),
4111
- /* @__PURE__ */ React18.createElement(
4112
- View16,
4113
- {
4114
- style: {
4115
- padding: 3,
4116
- borderRight: "1px solid #000",
4117
- width: "9%"
4118
- }
4119
- },
4120
- /* @__PURE__ */ React18.createElement(Text_default, null, "Payment Mode")
4121
- ),
4122
- /* @__PURE__ */ React18.createElement(
4123
- View16,
4124
- {
4125
- style: {
4126
- padding: 3,
4127
- borderRight: "1px solid #000",
4128
- width: "9%"
4129
- }
4130
- },
4131
- /* @__PURE__ */ React18.createElement(Text_default, null, "Booking Date")
4132
- ),
4133
- /* @__PURE__ */ React18.createElement(
4134
- View16,
4135
- {
4136
- style: {
4137
- padding: 3,
4138
- borderRight: "1px solid #000",
4139
- width: "9%"
4140
- }
4141
- },
4142
- /* @__PURE__ */ React18.createElement(Text_default, null, "Settlement Date")
4143
- ),
4144
- /* @__PURE__ */ React18.createElement(
4145
- View16,
4146
- {
4147
- style: {
4148
- padding: 3,
4149
- borderRight: "none",
4150
- width: "12%"
4151
- }
4152
- },
4153
- /* @__PURE__ */ React18.createElement(Text_default, null, "UTR Number")
4154
- )
4155
- ),
4156
- data.map((item, index) => {
4157
- return /* @__PURE__ */ React18.createElement(
4158
- View16,
4159
- {
4160
- key: index,
4161
- style: {
4162
- display: "flex",
4163
- flexDirection: "row",
4164
- border: "1px solid #000",
4165
- borderTop: "none",
4166
- fontSize: 8
4167
- }
4168
- },
4169
- /* @__PURE__ */ React18.createElement(
4170
- View16,
4171
- {
4172
- style: {
4173
- padding: 3,
4174
- borderRight: "1px solid #000",
4175
- width: "4%"
4176
- }
4177
- },
4178
- /* @__PURE__ */ React18.createElement(Text_default, null, index + 1)
4179
- ),
4180
- /* @__PURE__ */ React18.createElement(
4181
- View16,
4182
- {
4183
- style: {
4184
- padding: 3,
4185
- borderRight: "1px solid #000",
4186
- width: "9%"
4187
- }
4188
- },
4189
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.invoiceNumber)
4190
- ),
4191
- /* @__PURE__ */ React18.createElement(
4192
- View16,
4193
- {
4194
- style: {
4195
- padding: 3,
4196
- borderRight: "1px solid #000",
4197
- width: "9%"
4198
- }
4199
- },
4200
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.baseAmount)
4201
- ),
4202
- /* @__PURE__ */ React18.createElement(
4203
- View16,
4204
- {
4205
- style: {
4206
- padding: 3,
4207
- borderRight: "1px solid #000",
4208
- width: "9%"
4209
- }
4210
- },
4211
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.platformFees)
4212
- ),
4213
- /* @__PURE__ */ React18.createElement(
4214
- View16,
4215
- {
4216
- style: {
4217
- padding: 3,
4218
- borderRight: "1px solid #000",
4219
- width: "9%"
4220
- }
4221
- },
4222
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.platformFeesGST)
4223
- ),
4224
- /* @__PURE__ */ React18.createElement(
4225
- View16,
4226
- {
4227
- style: {
4228
- padding: 3,
4229
- borderRight: "1px solid #000",
4230
- width: "9%"
4231
- }
4232
- },
4233
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.gatewayCharges)
4234
- ),
4235
- /* @__PURE__ */ React18.createElement(
4236
- View16,
4237
- {
4238
- style: {
4239
- padding: 3,
4240
- borderRight: "1px solid #000",
4241
- width: "9%"
4242
- }
4243
- },
4244
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.gatewayChargesGST)
4245
- ),
4246
- /* @__PURE__ */ React18.createElement(
4247
- View16,
4248
- {
4249
- style: {
4250
- padding: 3,
4251
- borderRight: "1px solid #000",
4252
- width: "9%"
4253
- }
4254
- },
4255
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.paymentMode)
4256
- ),
4257
- /* @__PURE__ */ React18.createElement(
4258
- View16,
4259
- {
4260
- style: {
4261
- padding: 3,
4262
- borderRight: "1px solid #000",
4263
- width: "9%",
4264
- fontSize: 7
4265
- }
4266
- },
4267
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.bookingDate)
4268
- ),
4269
- /* @__PURE__ */ React18.createElement(
4270
- View16,
4271
- {
4272
- style: {
4273
- padding: 3,
4274
- borderRight: "1px solid #000",
4275
- width: "9%",
4276
- fontSize: 7
4277
- }
4278
- },
4279
- /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.settlementDate)
4280
- ),
4281
- /* @__PURE__ */ React18.createElement(View16, { style: { padding: 3, width: "12%" } }, /* @__PURE__ */ React18.createElement(BrokenText_default, null, item.utrNumber))
4282
- );
4283
- })
4284
- ) : /* @__PURE__ */ React18.createElement(
4285
- Text_default,
4286
- {
4287
- style: {
4288
- fontSize: 18,
4289
- textAlign: "center",
4290
- marginTop: 100
4291
- }
4292
- },
4293
- "No data available for the selected date range"
4294
- ))));
4295
- };
4296
- var A4InvoiceLevelBreakup_default = A4InvoiceLevelBreakup;
4297
-
4298
- // src/sizes/a4/A4PujaCountReport.tsx
4299
- import { Document as Document17, Page as Page17, View as View17 } from "@react-pdf/renderer";
4300
- import React19 from "react";
4301
- var A4PujaCountReport = ({
4302
- startDate,
4303
- endDate,
4304
- templeName,
4305
- data
4306
- }) => {
4307
- return /* @__PURE__ */ React19.createElement(React19.Fragment, null, /* @__PURE__ */ React19.createElement(Document17, null, /* @__PURE__ */ React19.createElement(Page17, { size: "A4", style: { padding: 30, fontFamily: "Noto Sans" } }, /* @__PURE__ */ React19.createElement(
4308
- ReportHeader_default,
4309
- {
4310
- startDate,
4311
- endDate,
4312
- reportName: "Total Puja Count Report",
4313
- templeName
4314
- }
4315
- ), data.length > 0 ? /* @__PURE__ */ React19.createElement(
4316
- View17,
4317
- {
4318
- style: {
4319
- display: "flex",
4320
- flexDirection: "column",
4321
- marginTop: 20
4322
- }
4323
- },
4324
- /* @__PURE__ */ React19.createElement(
4325
- View17,
4326
- {
4327
- style: {
4328
- display: "flex",
4329
- flexDirection: "row",
4330
- border: "1px solid #000",
4331
- fontSize: 10,
4332
- fontWeight: "semibold"
4333
- }
4334
- },
4335
- /* @__PURE__ */ React19.createElement(
4336
- View17,
4337
- {
4338
- style: {
4339
- padding: 6,
4340
- borderRight: "1px solid #000",
4341
- width: "10%"
4342
- }
4343
- },
4344
- /* @__PURE__ */ React19.createElement(Text_default, null, "Sr no")
4345
- ),
4346
- /* @__PURE__ */ React19.createElement(
4347
- View17,
4348
- {
4349
- style: {
4350
- padding: 6,
4351
- borderRight: "1px solid #000",
4352
- width: "40%"
4353
- }
4354
- },
4355
- /* @__PURE__ */ React19.createElement(Text_default, null, "Puja Name")
4356
- ),
4357
- /* @__PURE__ */ React19.createElement(
4358
- View17,
4359
- {
4360
- style: {
4361
- padding: 6,
4362
- borderRight: "1px solid #000",
4363
- width: "15%"
4364
- }
4365
- },
4366
- /* @__PURE__ */ React19.createElement(Text_default, null, "Total Count")
4367
- ),
4368
- /* @__PURE__ */ React19.createElement(
4369
- View17,
4370
- {
4371
- style: {
4372
- padding: 6,
4373
- borderRight: "none",
4374
- width: "35%"
4375
- }
4376
- },
4377
- /* @__PURE__ */ React19.createElement(Text_default, null, "Remarks")
4378
- )
4379
- ),
4380
- data.map((item, index) => {
4381
- return /* @__PURE__ */ React19.createElement(
4382
- View17,
4383
- {
4384
- style: {
4385
- display: "flex",
4386
- flexDirection: "row",
4387
- border: "1px solid #000",
4388
- borderTop: "none",
4389
- fontSize: 10
4390
- }
4391
- },
4392
- /* @__PURE__ */ React19.createElement(
4393
- View17,
4394
- {
4395
- style: {
4396
- padding: 6,
4397
- borderRight: "1px solid #000",
4398
- width: "10%"
4399
- }
4400
- },
4401
- /* @__PURE__ */ React19.createElement(Text_default, null, index + 1)
4402
- ),
4403
- /* @__PURE__ */ React19.createElement(
4404
- View17,
4405
- {
4406
- style: {
4407
- padding: 6,
4408
- borderRight: "1px solid #000",
4409
- width: "40%"
4410
- }
4411
- },
4412
- /* @__PURE__ */ React19.createElement(Text_default, null, item.name)
4413
- ),
4414
- /* @__PURE__ */ React19.createElement(
4415
- View17,
4416
- {
4417
- style: {
4418
- padding: 6,
4419
- borderRight: "1px solid #000",
4420
- width: "15%"
4421
- }
4422
- },
4423
- /* @__PURE__ */ React19.createElement(Text_default, null, item.quantity)
4424
- ),
4425
- /* @__PURE__ */ React19.createElement(
4426
- View17,
4427
- {
4428
- style: {
4429
- padding: 6,
4430
- borderRight: "none",
4431
- width: "35%"
4432
- }
4433
- }
4434
- )
4435
- );
4436
- })
4437
- ) : /* @__PURE__ */ React19.createElement(
4438
- Text_default,
4439
- {
4440
- style: {
4441
- fontSize: 18,
4442
- textAlign: "center",
4443
- marginTop: 100
4444
- }
4445
- },
4446
- "No data available for the selected date range"
4447
- ))));
4448
- };
4449
- var A4PujaCountReport_default = A4PujaCountReport;
4450
-
4451
- // src/index.tsx
4452
- var options = {
4453
- kitchen: {
4454
- A4: A4KitchenReport_default
4455
- },
4456
- transaction: {
4457
- A4: A4TransactionReport_default
4458
- },
4459
- "prasad-delivery": {
4460
- A4: A4PrasadDelivery_default
4461
- },
4462
- prasad: {
4463
- A4: A4PrasadReport_default
4464
- },
4465
- "puja-detailed": {
4466
- A4: A4PujaList_default
4467
- },
4468
- "puja-summary": {
4469
- A4: A4Summary_default
4470
- },
4471
- "combined-report": {
4472
- A4: A4CombinedReport_default
4473
- },
4474
- "multi-temple-payment": {
4475
- A4: A4MultiTemplePaymentReport_default
4476
- },
4477
- "settlements-report": {
4478
- A4: A4SettlementsReport_default
4479
- },
4480
- "invoice": {
4481
- A4: A4Invoice_default
4482
- },
4483
- "postal-report": {
4484
- A4: A4PostalReport_default
4485
- },
4486
- "payment-settlement-report": {
4487
- A4: A4PaymentSettlementReport_default
4488
- },
4489
- "invoice-breakup": {
4490
- A4: A4InvoiceLevelBreakup_default
4491
- },
4492
- "puja-count": {
4493
- A4: A4PujaCountReport_default
4494
- }
4495
- };
4496
- var reportPrinter = class {
4497
- option;
4498
- size;
4499
- constructor(option, size) {
4500
- this.option = option;
4501
- this.size = size;
4502
- const fontFamilies = [
4503
- {
4504
- family: "Noto Sans SC",
4505
- // Simplified Chinese
4506
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-serif-sc@latest/chinese-simplified-400-normal.ttf"
4507
- },
4508
- {
4509
- family: "Noto Sans Arabic",
4510
- // arabic , urdu
4511
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-arabic@latest/arabic-400-normal.ttf"
4512
- },
4513
- {
4514
- family: "Noto Sans Devanagari",
4515
- //hindi
4516
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-devanagari@latest/devanagari-400-normal.ttf"
4517
- },
4518
- {
4519
- family: "Noto Sans Kannada",
4520
- //kannada
4521
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-kannada@latest/kannada-400-normal.ttf"
4522
- },
4523
- {
4524
- family: "Noto Sans Tamil",
4525
- //tamil
4526
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tamil@latest/tamil-400-normal.ttf"
4527
- },
4528
- {
4529
- family: "Noto Sans Gurmukhi",
4530
- //punjabi
4531
- src: "https://cdn.jsdelivr.net/fontsource/fonts/anek-gurmukhi@latest/gurmukhi-400-normal.ttf"
4532
- },
4533
- {
4534
- family: "Noto Sans Lao",
4535
- //lao
4536
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-lao@latest/lao-400-normal.ttf"
4537
- },
4538
- {
4539
- family: "Noto Sans Thai",
4540
- //thai
4541
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-thai@latest/thai-400-normal.ttf"
4542
- },
4543
- {
4544
- family: "Noto Sans Kr",
4545
- //korean
4546
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-kr@latest/korean-400-normal.ttf"
4547
- },
4548
- {
4549
- family: "Noto Sans Bengali",
4550
- //bengali
4551
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-bengali@latest/bengali-400-normal.ttf"
4552
- },
4553
- {
4554
- family: "Noto Sans Cyrillic",
4555
- //russian
4556
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-kr@latest/cyrillic-400-normal.ttf"
4557
- },
4558
- {
4559
- family: "Noto Sans JP",
4560
- //japanese
4561
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-jp@latest/japanese-400-normal.ttf"
4562
- },
4563
- {
4564
- family: "Noto Sans Greek",
4565
- //greek
4566
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans@latest/greek-400-normal.ttf"
4567
- },
4568
- {
4569
- family: "Noto Sans Latin",
4570
- //latin
4571
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans@latest/latin-400-normal.ttf"
4572
- },
4573
- {
4574
- family: "Noto Sans Myanmar",
4575
- //Myanmar
4576
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-myanmar@latest/myanmar-400-normal.ttf"
4577
- },
4578
- {
4579
- family: "Noto Sans Ethiopic",
4580
- //Ethiopic
4581
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-ethiopic@latest/ethiopic-400-normal.ttf"
4582
- },
4583
- {
4584
- family: "Noto Sans Khmer",
4585
- //Khmer
4586
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-khmer@latest/khmer-400-normal.ttf"
4587
- },
4588
- {
4589
- family: "Noto Sans Armenian",
4590
- //Armenian
4591
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-armenian@latest/armenian-400-normal.ttf"
4592
- },
4593
- {
4594
- family: "Noto Sans Hebrew",
4595
- //Hebrew
4596
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-hebrew@latest/hebrew-400-normal.ttf"
4597
- },
4598
- {
4599
- family: "Noto Sans Georgian",
4600
- //Georgian
4601
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-georgian@latest/georgian-400-normal.ttf"
4602
- },
4603
- {
4604
- family: "Noto Sans Canadian Aboriginal",
4605
- //Canadian Aboriginal
4606
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-canadian-aboriginal@latest/canadian-aboriginal-400-normal.ttf"
4607
- },
4608
- {
4609
- family: "Noto Sans Sinhala",
4610
- //Sinhala
4611
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-sinhala@latest/sinhala-400-normal.ttf"
4612
- },
4613
- {
4614
- family: "Noto Sans Ol Chiki",
4615
- //Ol Chiki
4616
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-ol-chiki@latest/ol-chiki-400-normal.ttf"
4617
- },
4618
- {
4619
- family: "Noto Sans Tibetan",
4620
- //Tibetan
4621
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-serif-tibetan@latest/tibetan-400-normal.ttf"
4622
- },
4623
- {
4624
- family: "Noto Sans Tifinagh",
4625
- //Tifinagh
4626
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tifinagh@latest/tifinagh-400-normal.ttf"
4627
- },
4628
- {
4629
- family: "Noto Sans Yi",
4630
- //Yi
4631
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-yi@latest/yi-400-normal.ttf"
4632
- },
4633
- {
4634
- family: "Noto Sans Syriac",
4635
- //Syriac
4636
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-syriac@latest/syriac-400-normal.ttf"
4637
- },
4638
- {
4639
- family: "Noto Sans Thaana",
4640
- //Thaana
4641
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-thaana@latest/thaana-400-normal.ttf"
4642
- },
4643
- {
4644
- family: "Noto Sans Vai",
4645
- //Vai
4646
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-vai@latest/vai-400-normal.ttf"
4647
- },
4648
- {
4649
- family: "Noto Sans Cherokee",
4650
- //Cherokee
4651
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-cherokee@latest/cherokee-400-normal.ttf"
4652
- },
4653
- {
4654
- family: "Noto Sans Tai Tham",
4655
- //Tai Tham
4656
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tai-tham@latest/tai-tham-400-normal.ttf"
4657
- },
4658
- {
4659
- family: "Noto Sans Tai Viet",
4660
- //Tai Viet
4661
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tai-viet@latest/tai-viet-400-normal.ttf"
4662
- },
4663
- {
4664
- family: "Noto Sans Javanese",
4665
- //Javanese
4666
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-javanese@latest/javanese-400-normal.ttf"
4667
- },
4668
- {
4669
- family: "Noto Sans Gujarati",
4670
- //Gujarati
4671
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-gujarati@latest/gujarati-400-normal.ttf"
4672
- },
4673
- {
4674
- family: "Noto Sans Malayalam",
4675
- //Malayalam
4676
- src: "https://res.cloudinary.com/dpaigt2bx/raw/upload/v1748450359/Manjari-Regular_nrgfti.ttf"
4677
- },
4678
- {
4679
- family: "Noto Sans Telugu",
4680
- //Telugu
4681
- src: "https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-telugu@latest/telugu-400-normal.ttf"
4682
- }
4683
- ];
4684
- fontFamilies.forEach(
4685
- ({ family, src }) => Font5.register({
4686
- family,
4687
- src
4688
- })
4689
- );
4690
- Font5.register({
4691
- family: "Noto Sans",
4692
- fontWeight: "normal",
4693
- src: notoSansRegular
4694
- });
4695
- Font5.register({
4696
- family: "Noto Sans",
4697
- fontWeight: "bold",
4698
- src: notoSansBold
4699
- });
4700
- Font5.register({
4701
- family: "Noto Sans",
4702
- fontWeight: "semibold",
4703
- src: notoSansSemiBold
4704
- });
4705
- }
4706
- async print(data) {
4707
- const ReportComponent = options[this.option][this.size];
4708
- const document = /* @__PURE__ */ React20.createElement(ReportComponent, { ...data });
4709
- const blob = pdf(document).toBlob();
4710
- blob.then((blob2) => {
4711
- var blobURL = URL.createObjectURL(blob2);
4712
- if (window != null) {
4713
- const printWindow = window.open(blobURL, "_blank");
4714
- setTimeout(() => {
4715
- printWindow?.print();
4716
- }, 1e3);
4717
- }
4718
- });
4719
- return blob;
4720
- }
4721
- async getBlob(data) {
4722
- const ReportComponent = options[this.option][this.size];
4723
- const document = /* @__PURE__ */ React20.createElement(ReportComponent, { ...data });
4724
- const blob = pdf(document).toBlob();
4725
- return blob;
4726
- }
4727
- };
4728
- export {
4729
- A4Print_default as A4Print,
4730
- T2Inch_default as T2Inch,
4731
- reportPrinter
4732
- };
1
+ import {Font,StyleSheet,Document,Page,Image,Text,View,pdf}from'@react-pdf/renderer';import t from'react';import {maxBy}from'lodash';var Ke=Object.defineProperty;var Ue=(r,i,n)=>i in r?Ke(r,i,{enumerable:true,configurable:true,writable:true,value:n}):r[i]=n;var ue=(r,i,n)=>Ue(r,typeof i!="symbol"?i+"":i,n);var M=r=>{typeof r=="string"&&(r=new Date(r));let i={day:"2-digit",month:"short",year:"numeric"};return r.toLocaleDateString("en-GB",i).replace(",","")};var Z="https://res.cloudinary.com/dpaigt2bx/image/upload/f_auto,q_auto/v1/General%20BMP%20assets/vkesyodnuxuwevdwrk6m",re="https://res.cloudinary.com/dpaigt2bx/raw/upload/v1742817493/fonts/ntbri6mclms8cfx3dk2e.ttf",ne="https://res.cloudinary.com/dpaigt2bx/raw/upload/v1742817493/fonts/ojiymraiiuw7juzkmmu8.ttf",ge="https://res.cloudinary.com/dpaigt2bx/raw/upload/v1743420993/NotoSans-Regular_pmvebt.ttf",fe="https://res.cloudinary.com/dpaigt2bx/raw/upload/v1743431605/NotoSans-Bold_kagtvd.ttf",ye="https://res.cloudinary.com/dpaigt2bx/raw/upload/v1743431765/NotoSans-SemiBold_o96oas.ttf";var xe="https://res.cloudinary.com/dpaigt2bx/image/upload/v1752653165/BookMyPuja_1_1_bd1xa0.png",De="https://res.cloudinary.com/dpaigt2bx/image/upload/v1752669810/paid-5025785_1280_afg4ob_gcacmg.png",pe={morning:"Morning",evening:"Evening"};Font.register({family:"Roboto",fontWeight:"normal",src:re});Font.register({family:"Roboto",fontWeight:"bold",src:ne});var he=StyleSheet.create({page:{padding:30,fontFamily:"Roboto"},pujaTile:{padding:10,fontSize:9,border:"1px solid rgb(100,100,100)",borderRadius:5,width:"100%",display:"flex",flexDirection:"row"}}),Xe=({data:r,dates:i})=>{let n=M(i[0])===M(i[1]);return t.createElement(Document,null,t.createElement(Page,{size:"A4",style:he.page},t.createElement(Image,{fixed:true,style:{height:15,width:75,marginBottom:10},src:Z}),t.createElement(Text,{style:{fontSize:13,marginBottom:2}},"Puja List"),t.createElement(Text,{style:{fontSize:10,marginBottom:10}},"Date",":"," ",n?M(i[0]):`${M(i[0])} - ${M(i[1])}`),t.createElement(View,{style:{display:"flex",flexDirection:"row",flexWrap:"wrap",justifyContent:"space-between",gap:8}},r?r.map((l,a)=>t.createElement(View,{wrap:false,key:a,style:he.pujaTile},t.createElement(View,{style:{display:"flex",flexDirection:"row"}},t.createElement(Text,{style:{opacity:.6,marginRight:10}},"#",(a+1).toString().padStart(2,"0"))),t.createElement(View,{style:{flexGrow:1}},t.createElement(View,{style:{display:"flex",flexDirection:"row",marginBottom:3,gap:3}},t.createElement(Text,{style:{fontSize:10,fontWeight:"bold"}},l.participantName),t.createElement(Text,{style:{fontSize:10,fontWeight:"bold"}},"-"),t.createElement(Text,{style:{fontSize:10,fontWeight:"bold"}},l.participantNakshatra)),t.createElement(View,{style:{display:"flex",flexDirection:"row",alignContent:"flex-end",gap:10}},t.createElement(View,{style:{display:"flex",flexDirection:"row",alignContent:"flex-end"}},t.createElement(Text,null,"Puja name : "),t.createElement(Text,{style:{fontSize:10,fontWeight:"bold"}},l.pujaName)),n?null:t.createElement(View,{style:{display:"flex",flexDirection:"row",alignContent:"flex-end"}},t.createElement(Text,null,"Date: "),t.createElement(Text,{style:{fontWeight:"bold"}},M(l.date)))),t.createElement(View,{style:{display:"flex",flexDirection:"row",alignContent:"flex-end",gap:10}}),l.priestNote!==""&&l.priestNote!==null&&l.priestNote!==void 0?t.createElement(View,{style:{display:"flex",flexDirection:"row",justifyContent:"space-between",marginTop:3}},t.createElement(Text,null,"Priest Note: ",l.priestNote)):null),t.createElement(View,{style:{display:"flex",flexDirection:"column",alignItems:"flex-end"}},t.createElement(Text,{style:{fontWeight:"bold",fontSize:10}},"Rs ",l.amount),l.paymentStatus=="pending"?t.createElement(View,{style:{backgroundColor:"#000000",paddingVertical:3,paddingHorizontal:5,borderRadius:5,marginTop:3}},t.createElement(Text,{style:{color:"#ffffff",fontSize:8}},"Pending")):null))):null)))},Re=Xe;Font.register({family:"Roboto",fontWeight:"normal",src:re});Font.register({family:"Roboto",fontWeight:"bold",src:ne});var C=1,te=25*C,be=StyleSheet.create({page:{padding:10*C,fontFamily:"Roboto"},pujaTile:{paddingVertical:10*C,paddingHorizontal:10*C,fontSize:te,border:`${5*C}px solid black`,borderRadius:5*C,width:"100%",display:"flex",flexDirection:"column"}}),rt=({data:r,dates:i})=>{let n=M(i[0])===M(i[1]);return t.createElement(Document,null,t.createElement(Page,{dpi:200,size:[457*C],style:be.page},t.createElement(Image,{fixed:true,style:{height:55*C,width:274*C,marginBottom:10*C,marginHorizontal:"auto"},src:Z}),t.createElement(Text,{style:{fontSize:25*C,marginBottom:5*C,marginHorizontal:"auto"}},"Puja List"),t.createElement(Text,{style:{fontSize:20*C,marginBottom:5*C,marginHorizontal:"auto",fontWeight:"bold"}},"Date",":"," ",n?M(i[0]):`${M(i[0])} - ${M(i[1])}`),t.createElement(Text,{style:{fontSize:17*C,marginBottom:20*C,marginHorizontal:"auto"}},"Printed at : ",new Date().toLocaleString()),t.createElement(View,{style:{display:"flex",flexDirection:"row",flexWrap:"wrap",justifyContent:"space-between",gap:15*C}},r?r.map((l,a)=>t.createElement(View,{wrap:false,key:a,style:be.pujaTile},t.createElement(View,{style:{display:"flex",flexDirection:"row",justifyContent:"space-between",marginBottom:5*C}},t.createElement(Text,{style:{opacity:.6,marginRight:10*C}},"#",(a+1).toString().padStart(2,"0")),t.createElement(View,{style:{display:"flex",flexDirection:"row",alignItems:"flex-end",gap:10*C}},l.paymentStatus=="pending"?t.createElement(View,{style:{backgroundColor:"#000000",paddingVertical:3*C,paddingHorizontal:5*C,borderRadius:5*C,marginTop:3*C}},t.createElement(Text,{style:{color:"#ffffff",fontSize:te}},"Pending")):null,t.createElement(Text,{style:{fontWeight:"bold",fontSize:te}},"Rs ",l.amount))),t.createElement(View,{style:{flexGrow:1}},t.createElement(View,{style:{display:"flex",flexDirection:"row",flexWrap:"wrap",marginBottom:3*C,gap:3*C}},t.createElement(Text,{style:{fontSize:te,fontWeight:"bold"}},l.participantName),t.createElement(Text,{style:{fontSize:te,fontWeight:"bold"}},"-"),t.createElement(Text,{style:{fontSize:te,fontWeight:"bold"}},l.participantNakshatra)),t.createElement(View,{style:{display:"flex",flexDirection:"column",alignContent:"flex-end",gap:10*C}},t.createElement(View,{style:{display:"flex",flexDirection:"row",flexWrap:"wrap",alignContent:"flex-end"}},t.createElement(Text,null,"Puja name : "),t.createElement(Text,{style:{fontSize:te,fontWeight:"bold"}},l.pujaName)),n?null:t.createElement(View,{style:{display:"flex",flexDirection:"row",alignContent:"flex-end"}},t.createElement(Text,null,"Date: "),t.createElement(Text,{style:{fontWeight:"bold"}},M(l.date)))),t.createElement(View,{style:{display:"flex",flexDirection:"row",alignContent:"flex-end",gap:10*C}}),l.priestNote!==""&&l.priestNote!==null&&l.priestNote!==void 0?t.createElement(View,{style:{display:"flex",flexDirection:"row",justifyContent:"space-between",marginTop:3*C}},t.createElement(Text,null,"Priest Note: ",l.priestNote)):null))):null)))},nt=rt;var lt={Latin:/[A-Za-z\u00AA\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02B8\u02E0-\u02E4\u1D00-\u1D25\u1D2C-\u1D5C\u1D62-\u1D65\u1D6B-\u1D77\u1D79-\u1DBE\u1E00-\u1EFF\u2071\u207F\u2090-\u209C\u212A\u212B\u2132\u214E\u2160-\u2188\u2C60-\u2C7F\uA722-\uA787\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA7FF\uAB30-\uAB5A\uAB5C-\uAB64\uAB66-\uAB69\uFB00-\uFB06\uFF21-\uFF3A\uFF41-z]|\uD801[\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD837[\uDF00-\uDF1E\uDF25-\uDF2A]/g,SC:/[\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u3005\u3007\u3021-\u3029\u3038-\u303B\u3400-\u4DBF\u4E00-\u9FFF\uF900-\uFA6D\uFA70-\uFAD9]|\uD81B[\uDFE2\uDFE3\uDFF0\uDFF1]|[\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883\uD885-\uD887][\uDC00-\uDFFF]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF39\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A\uDF50-\uDFFF]|\uD888[\uDC00-\uDFAF]/g,Cyrillic:/[\u0400-\u0484\u0487-\u052F\u1C80-\u1C88\u1D2B\u1D78\u2DE0-\u2DFF\uA640-\uA69F\uFE2E\uFE2F]|\uD838[\uDC30-\uDC6D\uDC8F]/g,Arabic:/[\u0600-\u0604\u0606-\u060B\u060D-\u061A\u061C-\u061E\u0620-\u063F\u0641-\u064A\u0656-\u066F\u0671-\u06DC\u06DE-\u06FF\u0750-\u077F\u0870-\u088E\u0890\u0891\u0898-\u08E1\u08E3-\u08FF\uFB50-\uFBC2\uFBD3-\uFD3D\uFD40-\uFD8F\uFD92-\uFDC7\uFDCF\uFDF0-\uFDFF\uFE70-\uFE74\uFE76-\uFEFC]|\uD803[\uDE60-\uDE7E\uDEFD-\uDEFF]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB\uDEF0\uDEF1]/g,Bengali:/[\u0980-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09FE]/g,Devanagari:/[\u0900-\u0950\u0955-\u0963\u0966-\u097F\uA8E0-\uA8FF]|\uD806[\uDF00-\uDF09]/g,JP:/[\u3041-\u3096\u309D-\u309F]|\uD82C[\uDC01-\uDD1F\uDD32\uDD50-\uDD52]|\uD83C\uDE00|[\u30A1-\u30FA\u30FD-\u30FF\u31F0-\u31FF\u32D0-\u32FE\u3300-\u3357\uFF66-\uFF6F\uFF71-\uFF9D]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00\uDD20-\uDD22\uDD55\uDD64-\uDD67]|[\u3400-\u4DB5\u4E00-\u9FAF]/g,KR:/[\u1100-\u11FF\u302E\u302F\u3131-\u318E\u3200-\u321E\u3260-\u327E\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uFFA0-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/g,Tamil:/[\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BFA]|\uD807[\uDFC0-\uDFF1\uDFFF]/g,Kannada:/[\u0C80-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1-\u0CF3]/g,Myanmar:/[\u1000-\u109F\uA9E0-\uA9FE\uAA60-\uAA7F]/g,Ethiopic:/[\u1200-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u137C\u1380-\u1399\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]/g,Thai:/[\u0E01-\u0E3A\u0E40-\u0E5B]/g,Greek:/[\u0370-\u0373\u0375-\u0377\u037A-\u037D\u037F\u0384\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03E1\u03F0-\u03FF\u1D26-\u1D2A\u1D5D-\u1D61\u1D66-\u1D6A\u1DBF\u1F00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FC4\u1FC6-\u1FD3\u1FD6-\u1FDB\u1FDD-\u1FEF\u1FF2-\u1FF4\u1FF6-\u1FFE\u2126\uAB65]|\uD800[\uDD40-\uDD8E\uDDA0]|\uD834[\uDE00-\uDE45]/g,Khmer:/[\u1780-\u17DD\u17E0-\u17E9\u17F0-\u17F9\u19E0-\u19FF]/g,Armenian:/[\u0531-\u0556\u0559-\u058A\u058D-\u058F\uFB13-\uFB17]/g,Hebrew:/[\u0591-\u05C7\u05D0-\u05EA\u05EF-\u05F4\uFB1D-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFB4F]/g,Georgian:/[\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u10FF\u1C90-\u1CBA\u1CBD-\u1CBF\u2D00-\u2D25\u2D27\u2D2D]/g,Lao:/[\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECE\u0ED0-\u0ED9\u0EDC-\u0EDF]/g,"Canadian Aboriginal":/[\u1400-\u167F\u18B0-\u18F5]|\uD806[\uDEB0-\uDEBF]/g,Sinhala:/[\u0D81-\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4]|\uD804[\uDDE1-\uDDF4]/g,"Ol Chiki":/[\u1C50-\u1C7F]/g,Tibetan:/[\u0F00-\u0F47\u0F49-\u0F6C\u0F71-\u0F97\u0F99-\u0FBC\u0FBE-\u0FCC\u0FCE-\u0FD4\u0FD9\u0FDA]/g,Tifinagh:/[\u2D30-\u2D67\u2D6F\u2D70\u2D7F]/g,Yi:/[\uA000-\uA48C\uA490-\uA4C6]/g,Syriac:/[\u0700-\u070D\u070F-\u074A\u074D-\u074F\u0860-\u086A]/g,Thaana:/[\u0780-\u07B1]/g,Vai:/[\uA500-\uA62B]/g,Cherokee:/[\u13A0-\u13F5\u13F8-\u13FD\uAB70-\uABBF]/g,"Tai Tham":/[\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD]/g,"Tai Viet":/[\uAA80-\uAAC2\uAADB-\uAADF]/g,Javanese:/[\uA980-\uA9CD\uA9D0-\uA9D9\uA9DE\uA9DF]/g,Telugu:/[\u0C00-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3C-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C5D\u0C60-\u0C63\u0C66-\u0C6F\u0C77-\u0C7F]/g,Gujarati:/[\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AF1\u0AF9-\u0AFF]/g,Malayalam:/[\u0D00-\u0D03\u0D05-\u0D39\u0D3A\u0D3B\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D60-\u0D63\u0D66-\u0D6F\u0D70-\u0D7F]/g,Gurmukhi:/[\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A76]/g},dt=({style:r={},children:i})=>{let n=d=>{let y=maxBy(Object.entries(lt),([f,c])=>{let O=d.match(c);return O?O.length:0});return y?y[0]:"Latin"},l=d=>[/\b\d{2}\/\d{2}\/\d{4}\b/,/\b\d{2}\s\w{3}\s\d{4}\b/].some(f=>f.test(d));function a(d){return d.replace(/[\uFF01-\uFF5E]/g,y=>`${String.fromCharCode(y.charCodeAt(0)-65248)} `)}let u=d=>{let y=[],f=null,c="";for(let O of d){O=a(O);let X=n(O);X!==f?(c&&y.push({text:c,script:f}),f=X,c=O):c+=O;}return c&&y.push({text:c,script:f}),y},T=[];i&&typeof i=="string"&&!Array.isArray(i)&&!l(i)&&u(i).forEach((y,f)=>{let c=y.script==="Latin"||!y.script?"Noto Sans":`Noto Sans ${y.script}`;T.push(t.createElement(Text,{key:f,style:{fontFamily:c}},y.text));});let h=[],k={fontFamily:"Noto Sans"};return Array.isArray(r)?h=[...r,k]:r&&Object.keys(r).length>0?h=[r,k]:h=[k],t.createElement(Text,{style:h},T?.length?T:i)},e=dt;var ut=({startDate:r,endDate:i,reportTiming:n,templeName:l,reportName:a})=>t.createElement(t.Fragment,null,t.createElement(Image,{fixed:true,style:{height:15,width:75,marginBottom:10},src:Z}),i?t.createElement(e,{style:{fontSize:11,marginTop:5,textAlign:"right"}},"Dates: ",r.toDateString()," - ",i.toDateString()):t.createElement(e,{style:{fontSize:11,marginTop:5,textAlign:"right"}},"Date: ",r.toDateString()),n&&Object.keys(pe).includes(n)?t.createElement(e,{style:{fontSize:11,marginTop:5,textAlign:"right"}},pe[n]," Report"):null,t.createElement(e,{style:{fontSize:14,fontWeight:"bold"}},a),t.createElement(e,{style:{fontSize:12}},`${l}`)),S=ut;var gt=({date:r,templeName:i,data:n,reportTiming:l})=>t.createElement(t.Fragment,null,t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,templeName:i,reportTiming:l,reportName:"Temple Prasad (Kitchen) Report"}),n.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",fontSize:10,fontWeight:"semibold"}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"60%"}},t.createElement(e,null,"Prasad Name")),t.createElement(View,{style:{padding:6,borderRight:"none",width:"20%"}},t.createElement(e,null,"Quantity"))),n.map((a,u)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%"}},t.createElement(e,null,u+1)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"60%"}},t.createElement(e,null,a.name)),t.createElement(View,{style:{padding:6,borderRight:"none",width:"20%"}},t.createElement(e,null,a.quantity))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range")))),Se=gt;var xt=({date:r,templeName:i,data:n})=>{let l=n.reduce((u,T)=>T.status==="cancelled"?u:u+T.bookingAmount,0),a=n.reduce((u,T)=>T.status==="cancelled"?u:u+T.creditedAmount,0);return t.createElement(t.Fragment,null,t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportName:"Transactions Report",templeName:i}),n.length>0?t.createElement(t.Fragment,null,t.createElement(e,{style:{fontSize:10,marginTop:10}},"Total Bookings: ",l.toLocaleString("en-IN",{maximumFractionDigits:2,style:"currency",currency:"INR"})),t.createElement(e,{style:{fontSize:10}},"Total Credited Amount: ",a.toLocaleString("en-IN",{maximumFractionDigits:2,style:"currency",currency:"INR"})),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",fontWeight:"semibold",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"8%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"23%"}},t.createElement(e,null,"Date")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"19%"}},t.createElement(e,null,"Invoice")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"15%"}},t.createElement(e,null,"Booking Amt")),t.createElement(View,{style:{padding:6,width:"15%",borderRight:"1px solid black"}},t.createElement(e,null,"Credited Amt")),t.createElement(View,{style:{padding:6,width:"20%"}},t.createElement(e,null,"Transaction ID"))),n.map((u,T)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"8%"}},t.createElement(e,null,T+1)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"23%"}},t.createElement(e,null,u.date," ",u.time)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"19%"}},t.createElement(e,null,u.invoiceNumber)),u.status=="cancelled"?t.createElement(t.Fragment,null,t.createElement(View,{style:{padding:6,width:"50%"}},t.createElement(e,{style:{textAlign:"center"}},"CANCELLED"))):t.createElement(t.Fragment,null,t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"15%"}},t.createElement(e,null,u.bookingAmount.toLocaleString("en-IN",{maximumFractionDigits:2,style:"currency",currency:"INR"}))),t.createElement(View,{style:{padding:6,width:"15%",borderRight:"1px solid black"}},t.createElement(e,null,u.creditedAmount.toLocaleString("en-IN",{maximumFractionDigits:2,style:"currency",currency:"INR"}))),t.createElement(View,{style:{padding:6,width:"20%"}},t.createElement(e,null,u.transactionId))))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range"))))},Ve=xt;var wt=({date:r,templeName:i,data:n})=>(n=n.map(l=>{let a="";try{let u=JSON.parse(l.address);a=`${u.address}, ${u.locality}, ${u.state} - ${u.pincode}`;}catch(u){console.error("Error parsing address:",u),a=l.address;}return {...l,address:a}}),t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportName:"Prasad Delivery Address",templeName:i}),n.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",fontWeight:"semibold",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,"Date")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"13%"}},t.createElement(e,null,"Invoice")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"18%"}},t.createElement(e,null,"Devotee Name")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"25%"}},t.createElement(e,null,"Address")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"20%"}},t.createElement(e,null,"Puja Name")),t.createElement(View,{style:{padding:6,width:"15%"}},t.createElement(e,null,"Amount"))),n.map((l,a)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,new Date(l.date).toLocaleDateString("en-GB",{day:"2-digit",month:"2-digit",year:"2-digit"}))),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"13%"}},t.createElement(e,null,l.invoiceNumber)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"18%"}},t.createElement(e,null,l.devoteeName)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"25%"}},t.createElement(e,null,l.address)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"20%"}},t.createElement(e,null,l.pujaName)),t.createElement(View,{style:{padding:6,width:"15%"}},t.createElement(e,null,l.amount.toLocaleString("en-IN",{maximumFractionDigits:2,style:"currency",currency:"INR"})))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range")))),Ce=wt;var Ft=({date:r,templeName:i,data:n,reportTiming:l})=>{n.sort((u,T)=>u.invoiceNumber.localeCompare(T.invoiceNumber));return t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportName:"Prasad Report",templeName:i,reportTiming:l}),n.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",fontWeight:"semibold",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"20%"}},t.createElement(e,null,"Invoice Number")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"23%"}},t.createElement(e,null,"Devotee Name")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"30%"}},t.createElement(e,null,"Prasad Name")),t.createElement(View,{style:{padding:6,width:"10%",borderRight:"1px solid black"}},t.createElement(e,null,"Qty")),t.createElement(View,{style:{padding:6,width:"7%"}},t.createElement(e,null,"Mode"))),n.map((u,T)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,T+1)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"20%"}},t.createElement(e,null,u.invoiceNumber)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"23%",fontSize:9,flexWrap:"wrap"}},t.createElement(e,null,u.devoteeName)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"30%"}},t.createElement(e,null,u.prasadName)),t.createElement(View,{style:{padding:6,width:"10%",borderRight:"1px solid black"}},t.createElement(e,null,u.quantity)),t.createElement(View,{style:{padding:6,width:"7%"}},t.createElement(e,null,u.collectionMode))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range")))},Ne=Ft;var St=({date:r,templeName:i,pujas:n,reportTiming:l})=>{let a=0,u=0,T=n.some(h=>h.bookings.some(k=>k.requires_coupon));return !n||n.length===0?t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportName:"Puja List",templeName:i,reportTiming:l}),t.createElement(e,{style:{fontSize:12,marginTop:100,textAlign:"center"}},"No data available for the selected date range"))):t.createElement(t.Fragment,null,t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportTiming:l,reportName:"",templeName:""}),n.some(h=>h.bookings.some(k=>k.is_early_reminder))&&t.createElement(t.Fragment,null,t.createElement(e,{style:{fontSize:14,fontWeight:"bold",marginTop:10}},"Early Reminders for Upcoming Pujas"),t.createElement(View,{wrap:false,style:{marginTop:10}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Sr No")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"60%"}},t.createElement(e,null,"Puja Name")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Qty")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",fontWeight:"semibold",width:"20%"}},t.createElement(e,null,"Date"))))),n.some(h=>h.bookings.some(k=>k.is_early_reminder&&!k.requires_coupon))?n.flatMap((h,k)=>h.bookings.filter(d=>d.is_early_reminder&&!d.requires_coupon).map((d,y)=>(u++,t.createElement(View,{key:`${k}-${y}`,style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,u)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"60%"}},t.createElement(e,null,h.name)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,d.quantity)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",width:"20%"}},t.createElement(e,null,d.date?new Date(d.date).toDateString():"")))))):null,t.createElement(e,{style:{fontSize:14,fontWeight:"bold",marginTop:20}},"Puja List"),t.createElement(e,{style:{fontSize:12}},`${i}`),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:10}},n.map((h,k)=>h.bookings.every(d=>d.is_early_reminder||d.requires_coupon)?null:(a=0,t.createElement(t.Fragment,null,t.createElement(View,{wrap:false,style:{marginBottom:25}},t.createElement(View,null,t.createElement(e,{style:{fontSize:10,fontWeight:"bold",border:"1px solid black",padding:6,textAlign:"center",borderBottom:"none"}},`${h.name} - ${h.bookings.length}`)),t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Sr No")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"20%"}},t.createElement(e,null,"Invoice No")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"35%"}},t.createElement(e,null,"Devotee Name")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"25%"}},t.createElement(e,null,"Nakshatra")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Qty"))),h.bookings.map((d,y)=>d.is_early_reminder||d.requires_coupon?null:(a++,t.createElement(t.Fragment,null,t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none",width:"100%"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,a)),t.createElement(View,{style:{display:"flex",flexDirection:"column",width:"90%"}},t.createElement(View,{style:{display:"flex",flexDirection:"row"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:`${20*1.11111}%`}},t.createElement(e,null,d.invoiceNumber)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:`${35*1.11111}%`}},t.createElement(e,null,d.devoteeName)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:`${25*1.11111}%`}},t.createElement(e,null,d.nakshatra)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",width:`${10*1.11111}%`}},t.createElement(e,null,d.quantity))),d.priestNote&&t.createElement(View,{style:{padding:6,fontSize:10,borderTop:"1px solid black",width:"100%"}},t.createElement(e,null,d.priestNote))))))))))))),T?t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(Image,{fixed:true,style:{height:15,width:75,marginBottom:10},src:Z}),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:10,gap:15}},(()=>{let h=n.flatMap(d=>d.bookings.filter(y=>y.requires_coupon).map(y=>({...y,pujaName:d.name}))),k={};for(let d of h)k[d.invoiceNumber]||(k[d.invoiceNumber]=[]),k[d.invoiceNumber].push(d);return Object.entries(k).map(([d,y],f)=>{let c=y,O=c[0];return t.createElement(View,{key:d,style:{marginBottom:10,fontSize:18,padding:10,border:"1px dotted black",position:"relative"},wrap:false},t.createElement(View,{style:{display:"flex",flexDirection:"row",justifyContent:"space-between",gap:10}},t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10}},t.createElement(e,{style:{fontWeight:"semibold"}},d),t.createElement(e,null,O.date?new Date(O.date).toDateString():r.toDateString())),t.createElement(e,null,O.phone_number)),t.createElement(View,{style:{height:15,width:"100%"}}),c.map((X,ie)=>t.createElement(View,{key:ie,style:{display:"flex",flexDirection:"row",marginTop:25}},t.createElement(e,null,`${X.devoteeName} ----- ${X.nakshatra} ----- ${X.pujaName}`))),t.createElement(View,null,t.createElement(e,{style:{textAlign:"center",marginTop:10,fontSize:10,opacity:.5}},"~~~ bookmypuja.app - Your Puja, Our Commitment ~~~")))})})())):null))},Ie=St;var Nt=({templeName:r,date:i,pujas:n,reportTiming:l})=>{let a=n.sort((u,T)=>{let h=u.nakshatras.length;return T.nakshatras.length-h});return t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:i,reportTiming:l,reportName:"Puja Summary",templeName:r}),n.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},a.map((u,T)=>t.createElement(t.Fragment,null,t.createElement(View,{wrap:false,style:{marginBottom:25}},t.createElement(View,null,t.createElement(e,{style:{fontSize:10,fontWeight:"bold",border:"1px solid black",padding:6,textAlign:"center",borderBottom:"none"}},`${u.name} - ${u.totalCount}`)),t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"20%"}},t.createElement(e,null,"Sr No")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"60%"}},t.createElement(e,null,"Nakshatra")),t.createElement(View,{style:{padding:6,fontSize:10,width:"20%",fontWeight:"semibold"}},t.createElement(e,null,"Quantity"))),u.nakshatras.map((h,k)=>t.createElement(t.Fragment,null,t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"20%"}},t.createElement(e,null,k+1)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"60%"}},t.createElement(e,null,h.name)),t.createElement(View,{style:{padding:6,fontSize:10,width:"20%"}},t.createElement(e,null,h.count))))))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range")))},Be=Nt;var It=({date:r,templeName:i,pujaData:n,prasadData:l,deliveryData:a,reportTiming:u})=>{a=a.map(d=>{let y="";try{let f=JSON.parse(d.address);y=`${f.address}, ${f.locality}, ${f.state} - ${f.pincode}`;}catch(f){console.error("Error parsing address:",f),y=d.address;}return {...d,address:y}});let T=0,h=0,k=n.some(d=>d.bookings.some(y=>y.requires_coupon));return n.length==0&&l.length==0&&a.length==0?t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportTiming:u,reportName:"Combined Report",templeName:i}),t.createElement(e,{style:{fontSize:12,marginTop:100,textAlign:"center"}},"No data available for the selected date range"))):t.createElement(t.Fragment,null,t.createElement(Document,null,n.length>0&&t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportTiming:u,reportName:"",templeName:""}),n.some(d=>d.bookings.some(y=>y.is_early_reminder))&&t.createElement(t.Fragment,null,t.createElement(e,{style:{fontSize:14,fontWeight:"bold",marginTop:10}},"Early Reminders for Upcoming Pujas"),t.createElement(View,{wrap:false,style:{marginTop:10}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Sr No")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"60%"}},t.createElement(e,null,"Puja Name")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Qty")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",fontWeight:"semibold",width:"20%"}},t.createElement(e,null,"Date"))))),n.some(d=>d.bookings.some(y=>y.is_early_reminder&&!y.requires_coupon))?n.flatMap((d,y)=>d.bookings.filter(f=>f.is_early_reminder&&!f.requires_coupon).map((f,c)=>(h++,t.createElement(View,{key:`${y}-${c}`,style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,h)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"60%"}},t.createElement(e,null,d.name)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,f.quantity)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",width:"20%"}},t.createElement(e,null,f.date?new Date(f.date).toDateString():"")))))):null,t.createElement(e,{style:{fontSize:14,fontWeight:"bold",marginTop:20}},"Puja List"),t.createElement(e,{style:{fontSize:12}},`${i}`),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:10}},n.map((d,y)=>d.bookings.every(f=>f.is_early_reminder||f.requires_coupon)?null:(T=0,t.createElement(t.Fragment,null,t.createElement(View,{wrap:false,style:{marginBottom:25}},t.createElement(View,null,t.createElement(e,{style:{fontSize:10,fontWeight:"bold",border:"1px solid black",padding:6,textAlign:"center",borderBottom:"none"}},`${d.name} - ${d.bookings.length}`)),t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Sr No")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"20%"}},t.createElement(e,null,"Invoice No")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"35%"}},t.createElement(e,null,"Devotee Name")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",fontWeight:"semibold",width:"25%"}},t.createElement(e,null,"Nakshatra")),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",fontWeight:"semibold",width:"10%"}},t.createElement(e,null,"Qty"))),d.bookings.map((f,c)=>f.is_early_reminder||f.requires_coupon?null:(T++,t.createElement(t.Fragment,null,t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none",width:"100%"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,T)),t.createElement(View,{style:{display:"flex",flexDirection:"column",width:"90%"}},t.createElement(View,{style:{display:"flex",flexDirection:"row"}},t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:`${20*1.11111}%`}},t.createElement(e,null,f.invoiceNumber)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:`${35*1.11111}%`}},t.createElement(e,null,f.devoteeName)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"1px solid black",width:`${25*1.11111}%`}},t.createElement(e,null,f.nakshatra)),t.createElement(View,{style:{padding:6,fontSize:10,borderRight:"none",width:`${10*1.11111}%`}},t.createElement(e,null,f.quantity))),f.priestNote&&t.createElement(View,{style:{padding:6,fontSize:10,borderTop:"1px solid black",width:"100%"}},t.createElement(e,null,f.priestNote))))))))))))),n.length>0&&k&&t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(Image,{fixed:true,style:{height:15,width:75,marginBottom:10},src:Z}),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:10,gap:15}},(()=>{let d=n.flatMap(f=>f.bookings.filter(c=>c.requires_coupon).map(c=>({...c,pujaName:f.name}))),y={};for(let f of d)y[f.invoiceNumber]||(y[f.invoiceNumber]=[]),y[f.invoiceNumber].push(f);return Object.entries(y).map(([f,c],O)=>{let X=c,ie=X[0];return t.createElement(View,{key:f,style:{marginBottom:10,fontSize:18,padding:10,border:"1px dotted black"},wrap:false},t.createElement(View,{style:{display:"flex",flexDirection:"row",justifyContent:"space-between",gap:10}},t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10}},t.createElement(e,{style:{fontWeight:"semibold"}},f),t.createElement(e,null,ie.date?new Date(ie.date).toDateString():r.toDateString())),t.createElement(e,null,ie.phone_number)),t.createElement(View,{style:{height:15,width:"100%"}}),X.map((ae,Ge)=>t.createElement(View,{key:Ge,style:{display:"flex",flexDirection:"row",marginTop:25}},t.createElement(e,null,`${ae.devoteeName} ----- ${ae.nakshatra} ----- ${ae.pujaName}`))))})})())),l.length>0&&t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportTiming:u,reportName:"Prasad Report",templeName:i}),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",fontWeight:"semibold",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"20%"}},t.createElement(e,null,"Invoice Number")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"30%"}},t.createElement(e,null,"Devotee Name")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"30%"}},t.createElement(e,null,"Prasad Name")),t.createElement(View,{style:{padding:6,width:"10%"}},t.createElement(e,null,"Qty"))),l.map((d,y)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,y+1)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"20%"}},t.createElement(e,null,d.invoiceNumber)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"30%"}},t.createElement(e,null,d.devoteeName)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"30%"}},t.createElement(e,null,d.prasadName)),t.createElement(View,{style:{padding:6,width:"10%"}},t.createElement(e,null,d.quantity)))))),a.length>0&&t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportTiming:u,reportName:"Prasad Delivery Postal Report",templeName:i}),t.createElement(View,{style:{display:"flex",flexDirection:"row",marginTop:20,width:"100%",gap:20,flexWrap:"wrap"}},a&&a.map(d=>t.createElement(View,{key:d.id,style:{width:"46%",display:"flex",flexDirection:"column",border:"1px solid black",borderStyle:"dotted",borderWidth:1.5,padding:6}},t.createElement(View,{style:{flexGrow:1}},t.createElement(e,{style:{fontSize:10,fontWeight:"bold"}},d.name),t.createElement(e,{style:{fontSize:10}},d.address),t.createElement(e,{style:{fontSize:10}},d.phone)),t.createElement(View,{style:{borderTop:"1px solid black",marginTop:5,paddingTop:3,borderStyle:"dotted"}}),t.createElement(e,{style:{fontSize:9,marginTop:3}},"Note: ",d.pujaDetails)))))))},ce=It;var ct=({startDate:r,endDate:i,data:n})=>t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,endDate:i,reportName:"Temple Payment Report",templeName:""}),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid black",fontWeight:"semibold",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,"S.No.")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"55%"}},t.createElement(e,null,"Temple Name")),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"15%"}},t.createElement(e,null,"Bookings")),t.createElement(View,{style:{padding:6,width:"20%"}},t.createElement(e,null,"Revenue"))),n?.map((l,a)=>t.createElement(View,{key:a,style:{display:"flex",flexDirection:"row",border:"1px solid black",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"10%"}},t.createElement(e,null,a+1)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"55%"}},t.createElement(e,null,l.name)),t.createElement(View,{style:{padding:6,borderRight:"1px solid black",width:"15%"}},t.createElement(e,null,l.bookings)),t.createElement(View,{style:{padding:6,width:"20%"}},t.createElement(e,null,"\u20B9",l.revenue))))))),Ee=ct;var vt=({startDate:r,endDate:i,templeName:n,data:l})=>t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,endDate:i,reportName:"Settlements Report",templeName:n}),t.createElement(e,{style:{fontSize:10,marginTop:10}},"Total Credited Amount: ",l.totalCreditedAmount),l.settlements.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",fontSize:10,fontWeight:"semibold"}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"10%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(e,null,"Date")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(e,null,"Settlement")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%"}},t.createElement(e,null,"UTR")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"25%"}},t.createElement(e,null,"Invoice")),t.createElement(View,{style:{padding:6,width:"20%"}},t.createElement(e,null,"Settlement ID"))),l.settlements?.map((a,u)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"10%"}},t.createElement(e,null,u+1)),t.createElement(View,{style:{padding:6,width:"15%",borderRight:"1px solid #000"}},t.createElement(e,null,a.date)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(e,null,a.settlement_amount)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%",fontSize:9}},t.createElement(e,null,a.utr.split("").map((T,h)=>t.createElement(e,{key:h},T)))),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"25%",fontSize:9}},t.createElement(View,{style:{display:"flex",flexDirection:"column"}},a.invoices.map((T,h)=>t.createElement(e,{key:h},T.number," (",T.amount,")")))),t.createElement(View,{style:{padding:6,width:"20%"}},t.createElement(e,null,a.settlement_id))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range"))),ze=vt;var Lt=({data:r})=>t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(View,{style:{display:"flex",flexDirection:"row"}},t.createElement(View,{style:{backgroundColor:"#FFA823",width:20,height:"100%"}}),t.createElement(View,{style:{marginLeft:15,marginTop:10,marginBottom:0}},t.createElement(e,{style:{fontSize:16,fontWeight:"bold"}},r.templeName),t.createElement(e,{style:{fontSize:10}},r.templeAddress),t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:5,marginTop:10,alignItems:"center"}},t.createElement(e,{style:{fontSize:10,marginTop:-5}},"Powered by"),t.createElement(Image,{style:{height:25,width:95,objectFit:"contain"},src:xe})))),t.createElement(View,{style:{display:"flex",flexDirection:"column",alignItems:"center",marginTop:20,position:"relative"}},r.status==="confirmed"?t.createElement(Image,{style:{height:85,width:85,marginBottom:5,objectFit:"contain",position:"absolute",right:"0",bottom:"0"},src:De}):null,t.createElement(e,{style:{fontSize:12,marginTop:5,fontWeight:"semibold"}},"INVOICE #",r.invoiceNumber),t.createElement(e,{style:{fontSize:10,marginTop:2}},"Status: ",r.status=="confirmed"?"PAID":"PENDING")),t.createElement(View,{style:{marginTop:10}},t.createElement(e,{style:{fontSize:11}},"Bill to:"),t.createElement(e,{style:{fontSize:11}},r.devoteeDetails.name),r.devoteeDetails.phone?t.createElement(e,{style:{fontSize:11}},r.devoteeDetails.phone):null,t.createElement(e,{style:{fontSize:11}},r.bookingDate)),t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",borderBottom:"1px solid #757575",fontSize:10,fontWeight:"semibold"}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #b5b5b5",width:"50%"}},t.createElement(e,null,"Item Description")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #b5b5b5",width:"15%",textAlign:"center"}},t.createElement(e,null,"Price")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #b5b5b5",width:"15%",textAlign:"center"}},t.createElement(e,null,"Quantity")),t.createElement(View,{style:{padding:6,width:"20%",textAlign:"center"}},t.createElement(e,null,"Total"))),r.items.map((i,n)=>t.createElement(View,{wrap:false,style:{display:"flex",flexDirection:"row",borderBottom:"1px solid #757575",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #b5b5b5",width:"50%"}},i.pujaName?t.createElement(e,{style:{fontSize:11}},i.pujaName):null,i.devoteesName?t.createElement(e,{style:{fontSize:9,color:"#333333"}},i.devoteesName):null,i.pujaDate?t.createElement(e,{style:{fontSize:9,color:"#333333"}},i.pujaDate," ",i.timing?`- ${i.timing}`:null):null,i.repeatEndDate&&i.repeatStartDate?t.createElement(e,{style:{fontSize:9,color:"#333333"}},i.repeatStartDate," to ",i.repeatEndDate," ",i.timing?`- ${i.timing}`:null):null),t.createElement(View,{style:{padding:6,borderRight:"1px solid #b5b5b5",width:"15%",textAlign:"center",display:"flex",alignItems:"center",justifyContent:"center"}},t.createElement(e,{style:{}},i.basePujPrice)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #b5b5b5",width:"15%",textAlign:"center",display:"flex",alignItems:"center",justifyContent:"center"}},t.createElement(e,{style:{}},`${i.quantity?i.quantity:""}${i.repeatCount?` x ${i.repeatCount}`:""}`)),t.createElement(View,{style:{padding:6,width:"20%",textAlign:"center",display:"flex",alignItems:"center",justifyContent:"center"}},t.createElement(e,{style:{}},i.totalPrice))))),t.createElement(View,{style:{display:"flex",flexDirection:"row",marginVertical:40,marginHorizontal:20}},t.createElement(View,{style:{width:"50%",display:"flex",flexDirection:"column",justifyContent:"center",fontSize:11}},t.createElement(e,{style:{fontWeight:"bold"}},"Payment Method:"),t.createElement(e,null,r.paymentMethod)),t.createElement(View,{style:{width:"50%",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"flex-end"}},t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10,fontSize:10}},t.createElement(View,{style:{width:"50%",textAlign:"right"}},t.createElement(e,null,"Subtotal: ")),t.createElement(View,{style:{width:"30%",textAlign:"right"}},t.createElement(e,null,r.subTotal))),r.postalCharges?t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10,fontSize:10}},t.createElement(View,{style:{width:"70%",textAlign:"right"}},t.createElement(e,null,"Postal Charges: ")),t.createElement(View,{style:{width:"30%",textAlign:"right"}},t.createElement(e,null,r.postalCharges))):null,t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10,fontSize:10}},t.createElement(View,{style:{width:"70%",textAlign:"right"}},t.createElement(e,null,"Payment Gateway Charges: ")),t.createElement(View,{style:{width:"30%",textAlign:"right"}},t.createElement(e,null,r.paymentGatewayCharges))),t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10,fontSize:10}},t.createElement(View,{style:{width:"70%",textAlign:"right"}},t.createElement(e,null,"Platform Charges: ")),t.createElement(View,{style:{width:"30%",textAlign:"right"}},t.createElement(e,null,r.platformCharges))),t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10,fontSize:10}},t.createElement(View,{style:{width:"70%",textAlign:"right"}},t.createElement(e,null,"GST (18%): ")),t.createElement(View,{style:{width:"30%",textAlign:"right"}},t.createElement(e,null,r.gst))),t.createElement(View,{style:{width:"60%",height:1,backgroundColor:"#757575",marginVertical:5}}),t.createElement(View,{style:{display:"flex",flexDirection:"row",gap:10,fontSize:10,fontWeight:"bold"}},t.createElement(View,{style:{width:"70%",textAlign:"right"}},t.createElement(e,null,"Total: ")),t.createElement(View,{style:{width:"30%",textAlign:"right"}},t.createElement(e,null,r.totalAmount))))),r.prasads&&(r.prasads.morning.length>0||r.prasads.afternoon.length>0||r.prasads.evening.length>0)?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginBottom:30}},t.createElement(View,{style:{backgroundColor:"#FF266F",padding:5}},t.createElement(e,{style:{fontSize:10,fontWeight:"bold",color:"white"}},"Prasadsam Details")),r.prasads.morning.length>0?t.createElement(View,{wrap:false,style:{display:"flex",flexDirection:"column",paddingHorizontal:10,paddingVertical:5,borderBottom:"1px solid #757575",borderRight:"1px solid #757575",borderLeft:"1px solid #757575"}},t.createElement(e,{style:{fontSize:9,fontWeight:"bold"}},"Morning:"),r.prasads.morning.map((i,n)=>t.createElement(e,{key:n,style:{fontSize:10}},n+1,". ",i.name," (",i.timings,")"))):null,r.prasads.afternoon.length>0?t.createElement(View,{wrap:false,style:{display:"flex",flexDirection:"column",paddingHorizontal:10,paddingVertical:5,borderBottom:"1px solid #757575",borderRight:"1px solid #757575",borderLeft:"1px solid #757575"}},t.createElement(e,{style:{fontSize:9,fontWeight:"bold"}},"Afternoon:"),r.prasads.afternoon.map((i,n)=>t.createElement(e,{key:n,style:{fontSize:10}},n+1,". ",i.name," (",i.timings,")"))):null,r.prasads.evening.length>0?t.createElement(View,{wrap:false,style:{display:"flex",flexDirection:"column",paddingHorizontal:10,paddingVertical:5,borderBottom:"1px solid #757575",borderRight:"1px solid #757575",borderLeft:"1px solid #757575"}},t.createElement(e,{style:{fontSize:9,fontWeight:"bold"}},"Evening:"),r.prasads.evening.map((i,n)=>t.createElement(e,{key:n,style:{fontSize:10}},n+1,". ",i.name," (",i.timings,")"))):null):null,r.instructions.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginHorizontal:20,fontSize:8,border:"1px solid #757575"}},t.createElement(View,{style:{backgroundColor:"#FFA823",paddingHorizontal:10,paddingVertical:5}},t.createElement(e,null,"IMPORTANT INSTRUCTIONS:")),t.createElement(View,{style:{display:"flex",flexDirection:"column",gap:5,marginVertical:10,paddingHorizontal:10}},r.instructions.map((i,n)=>t.createElement(e,{key:n,style:{fontSize:8}},n+1,") ",i.instruction)))):null,t.createElement(View,{style:{display:"flex",flexDirection:"row",marginTop:20}},t.createElement(e,{style:{fontSize:8,fontWeight:"bold"}},"Terms and Conditions:"),t.createElement(e,{style:{fontSize:8,marginLeft:5}},"https://www.bookmypuja.app/terms-and-condition")))),je=Lt;var Mt=({date:r,templeName:i,data:n})=>t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,reportName:"Prasad Delivery Postal Report",templeName:i}),n&&n.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"row",marginTop:20,width:"100%",gap:20,flexWrap:"wrap"}},n.map(l=>t.createElement(View,{key:l.id,style:{width:"46%",display:"flex",flexDirection:"column",border:"1px solid black",borderStyle:"dotted",borderWidth:1.5,padding:6}},t.createElement(View,{style:{flexGrow:1}},t.createElement(e,{style:{fontSize:10,fontWeight:"bold"}},l.name),t.createElement(e,{style:{fontSize:10}},l.address),t.createElement(e,{style:{fontSize:10}},l.phone)),t.createElement(View,{style:{borderTop:"1px solid black",marginTop:5,paddingTop:3,borderStyle:"dotted"}}),t.createElement(e,{style:{fontSize:9,marginTop:3}},"Note: ",l.pujaDetails)))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range"))),We=Mt;var Ot=({children:r})=>!r||typeof r!="string"?null:t.createElement(t.Fragment,null,t.createElement(View,{style:{display:"flex",flexDirection:"row",flexWrap:"wrap"}},r.split("").map((i,n)=>t.createElement(e,{key:n},i)))),v=Ot;var Kt=({startDate:r,endDate:i,templeName:n,data:l})=>t.createElement(t.Fragment,null,t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,endDate:i,reportName:"Payment Settlement Report",templeName:n}),l.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",fontSize:10,fontWeight:"semibold"}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"10%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(e,null,"Invoice No")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(e,null,"Amount")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%"}},t.createElement(e,null,"Payment Date")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%"}},t.createElement(e,null,"Settlement Date")),t.createElement(View,{style:{padding:6,borderRight:"none",width:"25%"}},t.createElement(e,null,"Bank UTR No"))),l.map((a,u)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"10%"}},t.createElement(e,null,u+1)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(v,null,a.invoiceNo)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(v,null,a.amount)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%"}},t.createElement(v,null,a.paymentDate)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"20%"}},t.createElement(v,null,a.settlementDate)),t.createElement(View,{style:{padding:6,borderRight:"none",width:"25%"}},t.createElement(v,null,a.bankUtrNo))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range")))),Le=Kt;var Jt=({startDate:r,endDate:i,templeName:n,data:l})=>t.createElement(t.Fragment,null,t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,endDate:i,reportName:"Invoice Level Breakup",templeName:n}),l.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",fontSize:8,fontWeight:"semibold"}},t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"4%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Invoice Number")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Base Amount")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Platform Fees")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Platform Fees GST")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Gateway Charges")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Gateway GST")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Payment Mode")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Booking Date")),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(e,null,"Settlement Date")),t.createElement(View,{style:{padding:3,borderRight:"none",width:"12%"}},t.createElement(e,null,"UTR Number"))),l.map((a,u)=>t.createElement(View,{key:u,style:{display:"flex",flexDirection:"row",border:"1px solid #000",borderTop:"none",fontSize:8}},t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"4%"}},t.createElement(e,null,u+1)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(v,null,a.invoiceNumber)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(v,null,a.baseAmount)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(v,null,a.platformFees)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(v,null,a.platformFeesGST)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(v,null,a.gatewayCharges)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(v,null,a.gatewayChargesGST)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%"}},t.createElement(v,null,a.paymentMode)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%",fontSize:7}},t.createElement(v,null,a.bookingDate)),t.createElement(View,{style:{padding:3,borderRight:"1px solid #000",width:"9%",fontSize:7}},t.createElement(v,null,a.settlementDate)),t.createElement(View,{style:{padding:3,width:"12%"}},t.createElement(v,null,a.utrNumber))))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range")))),_e=Jt;var Xt=({startDate:r,endDate:i,templeName:n,data:l})=>t.createElement(t.Fragment,null,t.createElement(Document,null,t.createElement(Page,{size:"A4",style:{padding:30,fontFamily:"Noto Sans"}},t.createElement(S,{startDate:r,endDate:i,reportName:"Total Puja Count Report",templeName:n}),l.length>0?t.createElement(View,{style:{display:"flex",flexDirection:"column",marginTop:20}},t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",fontSize:10,fontWeight:"semibold"}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"10%"}},t.createElement(e,null,"Sr no")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"40%"}},t.createElement(e,null,"Puja Name")),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(e,null,"Total Count")),t.createElement(View,{style:{padding:6,borderRight:"none",width:"35%"}},t.createElement(e,null,"Remarks"))),l.map((a,u)=>t.createElement(View,{style:{display:"flex",flexDirection:"row",border:"1px solid #000",borderTop:"none",fontSize:10}},t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"10%"}},t.createElement(e,null,u+1)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"40%"}},t.createElement(e,null,a.name)),t.createElement(View,{style:{padding:6,borderRight:"1px solid #000",width:"15%"}},t.createElement(e,null,a.quantity)),t.createElement(View,{style:{padding:6,borderRight:"none",width:"35%"}})))):t.createElement(e,{style:{fontSize:18,textAlign:"center",marginTop:100}},"No data available for the selected date range")))),$e=Xt;var Oe={kitchen:{A4:Se},transaction:{A4:Ve},"prasad-delivery":{A4:Ce},prasad:{A4:Ne},"puja-detailed":{A4:Ie},"puja-summary":{A4:Be},"combined-report":{A4:ce},"multi-temple-payment":{A4:Ee},"settlements-report":{A4:ze},invoice:{A4:je},"postal-report":{A4:We},"payment-settlement-report":{A4:Le},"invoice-breakup":{A4:_e},"puja-count":{A4:$e}},He=class{constructor(i,n){ue(this,"option");ue(this,"size");this.option=i,this.size=n,[{family:"Noto Sans SC",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-serif-sc@latest/chinese-simplified-400-normal.ttf"},{family:"Noto Sans Arabic",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-arabic@latest/arabic-400-normal.ttf"},{family:"Noto Sans Devanagari",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-devanagari@latest/devanagari-400-normal.ttf"},{family:"Noto Sans Kannada",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-kannada@latest/kannada-400-normal.ttf"},{family:"Noto Sans Tamil",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tamil@latest/tamil-400-normal.ttf"},{family:"Noto Sans Gurmukhi",src:"https://cdn.jsdelivr.net/fontsource/fonts/anek-gurmukhi@latest/gurmukhi-400-normal.ttf"},{family:"Noto Sans Lao",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-lao@latest/lao-400-normal.ttf"},{family:"Noto Sans Thai",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-thai@latest/thai-400-normal.ttf"},{family:"Noto Sans Kr",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-kr@latest/korean-400-normal.ttf"},{family:"Noto Sans Bengali",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-bengali@latest/bengali-400-normal.ttf"},{family:"Noto Sans Cyrillic",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-kr@latest/cyrillic-400-normal.ttf"},{family:"Noto Sans JP",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-jp@latest/japanese-400-normal.ttf"},{family:"Noto Sans Greek",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans@latest/greek-400-normal.ttf"},{family:"Noto Sans Latin",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans@latest/latin-400-normal.ttf"},{family:"Noto Sans Myanmar",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-myanmar@latest/myanmar-400-normal.ttf"},{family:"Noto Sans Ethiopic",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-ethiopic@latest/ethiopic-400-normal.ttf"},{family:"Noto Sans Khmer",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-khmer@latest/khmer-400-normal.ttf"},{family:"Noto Sans Armenian",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-armenian@latest/armenian-400-normal.ttf"},{family:"Noto Sans Hebrew",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-hebrew@latest/hebrew-400-normal.ttf"},{family:"Noto Sans Georgian",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-georgian@latest/georgian-400-normal.ttf"},{family:"Noto Sans Canadian Aboriginal",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-canadian-aboriginal@latest/canadian-aboriginal-400-normal.ttf"},{family:"Noto Sans Sinhala",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-sinhala@latest/sinhala-400-normal.ttf"},{family:"Noto Sans Ol Chiki",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-ol-chiki@latest/ol-chiki-400-normal.ttf"},{family:"Noto Sans Tibetan",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-serif-tibetan@latest/tibetan-400-normal.ttf"},{family:"Noto Sans Tifinagh",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tifinagh@latest/tifinagh-400-normal.ttf"},{family:"Noto Sans Yi",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-yi@latest/yi-400-normal.ttf"},{family:"Noto Sans Syriac",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-syriac@latest/syriac-400-normal.ttf"},{family:"Noto Sans Thaana",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-thaana@latest/thaana-400-normal.ttf"},{family:"Noto Sans Vai",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-vai@latest/vai-400-normal.ttf"},{family:"Noto Sans Cherokee",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-cherokee@latest/cherokee-400-normal.ttf"},{family:"Noto Sans Tai Tham",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tai-tham@latest/tai-tham-400-normal.ttf"},{family:"Noto Sans Tai Viet",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-tai-viet@latest/tai-viet-400-normal.ttf"},{family:"Noto Sans Javanese",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-javanese@latest/javanese-400-normal.ttf"},{family:"Noto Sans Gujarati",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-gujarati@latest/gujarati-400-normal.ttf"},{family:"Noto Sans Malayalam",src:"https://res.cloudinary.com/dpaigt2bx/raw/upload/v1748450359/Manjari-Regular_nrgfti.ttf"},{family:"Noto Sans Telugu",src:"https://cdn.jsdelivr.net/fontsource/fonts/noto-sans-telugu@latest/telugu-400-normal.ttf"}].forEach(({family:a,src:u})=>Font.register({family:a,src:u})),Font.register({family:"Noto Sans",fontWeight:"normal",src:ge}),Font.register({family:"Noto Sans",fontWeight:"bold",src:fe}),Font.register({family:"Noto Sans",fontWeight:"semibold",src:ye});}async print(i){let n=Oe[this.option][this.size],l=t.createElement(n,{...i}),a=pdf(l).toBlob();return a.then(u=>{var T=URL.createObjectURL(u);if(window!=null){let h=window.open(T,"_blank");setTimeout(()=>{h?.print();},1e3);}}),a}async getBlob(i){let n=Oe[this.option][this.size],l=t.createElement(n,{...i});return pdf(l).toBlob()}};
2
+ export{Re as A4Print,nt as T2Inch,He as reportPrinter};