@bookmypuja-tech/bmp-pdf 0.3.1 → 0.3.3
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.
- package/dist/index.d.ts +22 -2
- package/dist/index.js +242 -35
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -85,6 +85,7 @@ interface ITransactionItem {
|
|
|
85
85
|
bookingAmount: number;
|
|
86
86
|
creditedAmount: number;
|
|
87
87
|
status?: string;
|
|
88
|
+
transactionId?: string;
|
|
88
89
|
}
|
|
89
90
|
interface ITransactionReport {
|
|
90
91
|
date: Date;
|
|
@@ -170,6 +171,24 @@ interface IMultiTemplePaymentReport {
|
|
|
170
171
|
data: ITempleData[];
|
|
171
172
|
}
|
|
172
173
|
|
|
174
|
+
interface ISettlementRow {
|
|
175
|
+
srNo: number;
|
|
176
|
+
settlement_amount: string;
|
|
177
|
+
utr: string;
|
|
178
|
+
invoices: {
|
|
179
|
+
number: string;
|
|
180
|
+
amount: string;
|
|
181
|
+
}[];
|
|
182
|
+
transaction_id: string;
|
|
183
|
+
remarks: string;
|
|
184
|
+
}
|
|
185
|
+
interface ISettlementsReport {
|
|
186
|
+
startDate: Date;
|
|
187
|
+
endDate: Date;
|
|
188
|
+
templeName: string;
|
|
189
|
+
settlements: ISettlementRow[];
|
|
190
|
+
}
|
|
191
|
+
|
|
173
192
|
type sizeOptions = "A4" | "2Inch";
|
|
174
193
|
declare const getPrintBlob: ({ size, data, dates, }: {
|
|
175
194
|
size: sizeOptions;
|
|
@@ -181,7 +200,7 @@ declare const printDevoteeReceipt2Inch: (data: IPujaReceipt) => Promise<void>;
|
|
|
181
200
|
declare const printTotalReceipt2Inch: (data: ITotalReceipt) => Promise<void>;
|
|
182
201
|
declare const printePujaReport2Inch: (data: IPujaReport) => Promise<void>;
|
|
183
202
|
declare const printQuickPrintReceipt2Inch: (data: IQuickReport) => Promise<void>;
|
|
184
|
-
type IReportOptions = "kitchen" | "transaction" | "prasad-delivery" | "prasad" | "puja-detailed" | "puja-summary" | "combined-report" | "multi-temple-payment";
|
|
203
|
+
type IReportOptions = "kitchen" | "transaction" | "prasad-delivery" | "prasad" | "puja-detailed" | "puja-summary" | "combined-report" | "multi-temple-payment" | "settlements-report";
|
|
185
204
|
type IReportSize = "A4";
|
|
186
205
|
type ReportDataTypes = {
|
|
187
206
|
kitchen: KitchenReportProps;
|
|
@@ -192,6 +211,7 @@ type ReportDataTypes = {
|
|
|
192
211
|
"puja-summary": ISummaryPujaList;
|
|
193
212
|
"combined-report": CombinedReportData;
|
|
194
213
|
"multi-temple-payment": IMultiTemplePaymentReport;
|
|
214
|
+
"settlements-report": ISettlementsReport;
|
|
195
215
|
};
|
|
196
216
|
declare class reportPrinter<T extends IReportOptions> {
|
|
197
217
|
option: T;
|
|
@@ -201,4 +221,4 @@ declare class reportPrinter<T extends IReportOptions> {
|
|
|
201
221
|
getBlob(data: ReportDataTypes[T]): Promise<Blob>;
|
|
202
222
|
}
|
|
203
223
|
|
|
204
|
-
export { A4Print, type KitchenReportProps as IKitchenReport, type IMultiTemplePaymentReport, type IPrasadDelivery, type IPrasadReport, type IPrintablePuja, type IPujaReceipt, type IPujaList as IPujaReport, type ISummaryPujaList as ISummaryPujaReport, type ITransactionReport, T2Inch, getA4SummaryBlob, getPrintBlob, printDevoteeReceipt2Inch, printQuickPrintReceipt2Inch, printTotalReceipt2Inch, printePujaReport2Inch, reportPrinter };
|
|
224
|
+
export { A4Print, type KitchenReportProps as IKitchenReport, type IMultiTemplePaymentReport, type IPrasadDelivery, type IPrasadReport, type IPrintablePuja, type IPujaReceipt, type IPujaList as IPujaReport, type ISettlementRow, type ISettlementsReport, type ISummaryPujaList as ISummaryPujaReport, type ITransactionReport, T2Inch, getA4SummaryBlob, getPrintBlob, printDevoteeReceipt2Inch, printQuickPrintReceipt2Inch, printTotalReceipt2Inch, printePujaReport2Inch, reportPrinter };
|
package/dist/index.js
CHANGED
|
@@ -216,7 +216,7 @@ var A4Print = ({
|
|
|
216
216
|
var A4Print_default = A4Print;
|
|
217
217
|
|
|
218
218
|
// src/index.tsx
|
|
219
|
-
import
|
|
219
|
+
import React17 from "react";
|
|
220
220
|
|
|
221
221
|
// src/sizes/T2Inch.tsx
|
|
222
222
|
import React2 from "react";
|
|
@@ -875,7 +875,7 @@ var A4TransactionReport = ({
|
|
|
875
875
|
style: {
|
|
876
876
|
padding: 6,
|
|
877
877
|
borderRight: "1px solid black",
|
|
878
|
-
width: "
|
|
878
|
+
width: "8%"
|
|
879
879
|
}
|
|
880
880
|
},
|
|
881
881
|
/* @__PURE__ */ React9.createElement(Text_default, null, "Sr no")
|
|
@@ -886,7 +886,7 @@ var A4TransactionReport = ({
|
|
|
886
886
|
style: {
|
|
887
887
|
padding: 6,
|
|
888
888
|
borderRight: "1px solid black",
|
|
889
|
-
width: "
|
|
889
|
+
width: "23%"
|
|
890
890
|
}
|
|
891
891
|
},
|
|
892
892
|
/* @__PURE__ */ React9.createElement(Text_default, null, "Date")
|
|
@@ -897,10 +897,10 @@ var A4TransactionReport = ({
|
|
|
897
897
|
style: {
|
|
898
898
|
padding: 6,
|
|
899
899
|
borderRight: "1px solid black",
|
|
900
|
-
width: "
|
|
900
|
+
width: "19%"
|
|
901
901
|
}
|
|
902
902
|
},
|
|
903
|
-
/* @__PURE__ */ React9.createElement(Text_default, null, "
|
|
903
|
+
/* @__PURE__ */ React9.createElement(Text_default, null, "Invoice")
|
|
904
904
|
),
|
|
905
905
|
/* @__PURE__ */ React9.createElement(
|
|
906
906
|
View4,
|
|
@@ -908,21 +908,21 @@ var A4TransactionReport = ({
|
|
|
908
908
|
style: {
|
|
909
909
|
padding: 6,
|
|
910
910
|
borderRight: "1px solid black",
|
|
911
|
-
width: "
|
|
911
|
+
width: "15%"
|
|
912
912
|
}
|
|
913
913
|
},
|
|
914
|
-
/* @__PURE__ */ React9.createElement(Text_default, null, "
|
|
914
|
+
/* @__PURE__ */ React9.createElement(Text_default, null, "Booking Amt")
|
|
915
915
|
),
|
|
916
916
|
/* @__PURE__ */ React9.createElement(
|
|
917
917
|
View4,
|
|
918
918
|
{
|
|
919
919
|
style: {
|
|
920
920
|
padding: 6,
|
|
921
|
-
|
|
922
|
-
|
|
921
|
+
width: "15%",
|
|
922
|
+
borderRight: "1px solid black"
|
|
923
923
|
}
|
|
924
924
|
},
|
|
925
|
-
/* @__PURE__ */ React9.createElement(Text_default, null, "
|
|
925
|
+
/* @__PURE__ */ React9.createElement(Text_default, null, "Credited Amt")
|
|
926
926
|
),
|
|
927
927
|
/* @__PURE__ */ React9.createElement(
|
|
928
928
|
View4,
|
|
@@ -932,7 +932,7 @@ var A4TransactionReport = ({
|
|
|
932
932
|
width: "20%"
|
|
933
933
|
}
|
|
934
934
|
},
|
|
935
|
-
/* @__PURE__ */ React9.createElement(Text_default, null, "
|
|
935
|
+
/* @__PURE__ */ React9.createElement(Text_default, null, "Transaction ID")
|
|
936
936
|
)
|
|
937
937
|
),
|
|
938
938
|
data.map((item, index) => {
|
|
@@ -953,7 +953,7 @@ var A4TransactionReport = ({
|
|
|
953
953
|
style: {
|
|
954
954
|
padding: 6,
|
|
955
955
|
borderRight: "1px solid black",
|
|
956
|
-
width: "
|
|
956
|
+
width: "8%"
|
|
957
957
|
}
|
|
958
958
|
},
|
|
959
959
|
/* @__PURE__ */ React9.createElement(Text_default, null, index + 1)
|
|
@@ -964,21 +964,10 @@ var A4TransactionReport = ({
|
|
|
964
964
|
style: {
|
|
965
965
|
padding: 6,
|
|
966
966
|
borderRight: "1px solid black",
|
|
967
|
-
width: "
|
|
968
|
-
}
|
|
969
|
-
},
|
|
970
|
-
/* @__PURE__ */ React9.createElement(Text_default, null, item.date)
|
|
971
|
-
),
|
|
972
|
-
/* @__PURE__ */ React9.createElement(
|
|
973
|
-
View4,
|
|
974
|
-
{
|
|
975
|
-
style: {
|
|
976
|
-
padding: 6,
|
|
977
|
-
borderRight: "1px solid black",
|
|
978
|
-
width: "15%"
|
|
967
|
+
width: "23%"
|
|
979
968
|
}
|
|
980
969
|
},
|
|
981
|
-
/* @__PURE__ */ React9.createElement(Text_default, null, item.time)
|
|
970
|
+
/* @__PURE__ */ React9.createElement(Text_default, null, item.date, " ", item.time)
|
|
982
971
|
),
|
|
983
972
|
/* @__PURE__ */ React9.createElement(
|
|
984
973
|
View4,
|
|
@@ -986,7 +975,7 @@ var A4TransactionReport = ({
|
|
|
986
975
|
style: {
|
|
987
976
|
padding: 6,
|
|
988
977
|
borderRight: "1px solid black",
|
|
989
|
-
width: "
|
|
978
|
+
width: "19%"
|
|
990
979
|
}
|
|
991
980
|
},
|
|
992
981
|
/* @__PURE__ */ React9.createElement(Text_default, null, item.invoiceNumber)
|
|
@@ -996,8 +985,7 @@ var A4TransactionReport = ({
|
|
|
996
985
|
{
|
|
997
986
|
style: {
|
|
998
987
|
padding: 6,
|
|
999
|
-
|
|
1000
|
-
width: "40%"
|
|
988
|
+
width: "50%"
|
|
1001
989
|
}
|
|
1002
990
|
},
|
|
1003
991
|
/* @__PURE__ */ React9.createElement(
|
|
@@ -1015,7 +1003,7 @@ var A4TransactionReport = ({
|
|
|
1015
1003
|
style: {
|
|
1016
1004
|
padding: 6,
|
|
1017
1005
|
borderRight: "1px solid black",
|
|
1018
|
-
width: "
|
|
1006
|
+
width: "15%"
|
|
1019
1007
|
}
|
|
1020
1008
|
},
|
|
1021
1009
|
/* @__PURE__ */ React9.createElement(Text_default, null, item.bookingAmount.toLocaleString("en-IN", {
|
|
@@ -1028,7 +1016,8 @@ var A4TransactionReport = ({
|
|
|
1028
1016
|
{
|
|
1029
1017
|
style: {
|
|
1030
1018
|
padding: 6,
|
|
1031
|
-
width: "
|
|
1019
|
+
width: "15%",
|
|
1020
|
+
borderRight: "1px solid black"
|
|
1032
1021
|
}
|
|
1033
1022
|
},
|
|
1034
1023
|
/* @__PURE__ */ React9.createElement(Text_default, null, item.creditedAmount.toLocaleString("en-IN", {
|
|
@@ -1036,6 +1025,15 @@ var A4TransactionReport = ({
|
|
|
1036
1025
|
style: "currency",
|
|
1037
1026
|
currency: "INR"
|
|
1038
1027
|
}))
|
|
1028
|
+
), /* @__PURE__ */ React9.createElement(
|
|
1029
|
+
View4,
|
|
1030
|
+
{
|
|
1031
|
+
style: {
|
|
1032
|
+
padding: 6,
|
|
1033
|
+
width: "20%"
|
|
1034
|
+
}
|
|
1035
|
+
},
|
|
1036
|
+
/* @__PURE__ */ React9.createElement(Text_default, null, item.transactionId)
|
|
1039
1037
|
))
|
|
1040
1038
|
);
|
|
1041
1039
|
})
|
|
@@ -2819,6 +2817,212 @@ var A4MultiTemplePaymentReport = ({
|
|
|
2819
2817
|
};
|
|
2820
2818
|
var A4MultiTemplePaymentReport_default = A4MultiTemplePaymentReport;
|
|
2821
2819
|
|
|
2820
|
+
// src/sizes/a4/A4SettlementsReport.tsx
|
|
2821
|
+
import React16 from "react";
|
|
2822
|
+
import { Page as Page12, Document as Document12, Image as Image13, View as View11 } from "@react-pdf/renderer";
|
|
2823
|
+
var A4SettlementsReport = ({
|
|
2824
|
+
startDate,
|
|
2825
|
+
endDate,
|
|
2826
|
+
templeName,
|
|
2827
|
+
settlements
|
|
2828
|
+
}) => {
|
|
2829
|
+
return /* @__PURE__ */ React16.createElement(Document12, null, /* @__PURE__ */ React16.createElement(
|
|
2830
|
+
Page12,
|
|
2831
|
+
{
|
|
2832
|
+
size: "A4",
|
|
2833
|
+
style: {
|
|
2834
|
+
padding: 30,
|
|
2835
|
+
fontFamily: "Noto Sans"
|
|
2836
|
+
}
|
|
2837
|
+
},
|
|
2838
|
+
/* @__PURE__ */ React16.createElement(
|
|
2839
|
+
Image13,
|
|
2840
|
+
{
|
|
2841
|
+
fixed: true,
|
|
2842
|
+
style: {
|
|
2843
|
+
height: 15,
|
|
2844
|
+
width: 75,
|
|
2845
|
+
marginBottom: 10
|
|
2846
|
+
},
|
|
2847
|
+
src: bmpLogo
|
|
2848
|
+
}
|
|
2849
|
+
),
|
|
2850
|
+
/* @__PURE__ */ React16.createElement(Text_default, { style: { fontSize: 11, marginTop: 5, textAlign: "right" } }, "Dates: ", startDate.toDateString(), " - ", endDate.toDateString()),
|
|
2851
|
+
/* @__PURE__ */ React16.createElement(Text_default, { style: { fontSize: 14, fontWeight: "bold" } }, "Settlements Report"),
|
|
2852
|
+
/* @__PURE__ */ React16.createElement(Text_default, { style: { fontSize: 12 } }, `${templeName}`),
|
|
2853
|
+
/* @__PURE__ */ React16.createElement(
|
|
2854
|
+
View11,
|
|
2855
|
+
{
|
|
2856
|
+
style: {
|
|
2857
|
+
display: "flex",
|
|
2858
|
+
flexDirection: "column",
|
|
2859
|
+
marginTop: 20
|
|
2860
|
+
}
|
|
2861
|
+
},
|
|
2862
|
+
/* @__PURE__ */ React16.createElement(
|
|
2863
|
+
View11,
|
|
2864
|
+
{
|
|
2865
|
+
style: {
|
|
2866
|
+
display: "flex",
|
|
2867
|
+
flexDirection: "row",
|
|
2868
|
+
border: "1px solid #000",
|
|
2869
|
+
fontSize: 10,
|
|
2870
|
+
fontWeight: "semibold"
|
|
2871
|
+
}
|
|
2872
|
+
},
|
|
2873
|
+
/* @__PURE__ */ React16.createElement(
|
|
2874
|
+
View11,
|
|
2875
|
+
{
|
|
2876
|
+
style: {
|
|
2877
|
+
padding: 6,
|
|
2878
|
+
borderRight: "1px solid #000",
|
|
2879
|
+
width: "10%"
|
|
2880
|
+
}
|
|
2881
|
+
},
|
|
2882
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, "Sr no")
|
|
2883
|
+
),
|
|
2884
|
+
/* @__PURE__ */ React16.createElement(
|
|
2885
|
+
View11,
|
|
2886
|
+
{
|
|
2887
|
+
style: {
|
|
2888
|
+
padding: 6,
|
|
2889
|
+
borderRight: "1px solid #000",
|
|
2890
|
+
width: "15%"
|
|
2891
|
+
}
|
|
2892
|
+
},
|
|
2893
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, "Settlement")
|
|
2894
|
+
),
|
|
2895
|
+
/* @__PURE__ */ React16.createElement(
|
|
2896
|
+
View11,
|
|
2897
|
+
{
|
|
2898
|
+
style: {
|
|
2899
|
+
padding: 6,
|
|
2900
|
+
borderRight: "1px solid #000",
|
|
2901
|
+
width: "20%"
|
|
2902
|
+
}
|
|
2903
|
+
},
|
|
2904
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, "UTR")
|
|
2905
|
+
),
|
|
2906
|
+
/* @__PURE__ */ React16.createElement(
|
|
2907
|
+
View11,
|
|
2908
|
+
{
|
|
2909
|
+
style: {
|
|
2910
|
+
padding: 6,
|
|
2911
|
+
borderRight: "1px solid #000",
|
|
2912
|
+
width: "25%"
|
|
2913
|
+
}
|
|
2914
|
+
},
|
|
2915
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, "Invoice")
|
|
2916
|
+
),
|
|
2917
|
+
/* @__PURE__ */ React16.createElement(
|
|
2918
|
+
View11,
|
|
2919
|
+
{
|
|
2920
|
+
style: {
|
|
2921
|
+
padding: 6,
|
|
2922
|
+
borderRight: "1px solid #000",
|
|
2923
|
+
width: "20%"
|
|
2924
|
+
}
|
|
2925
|
+
},
|
|
2926
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, "Transaction ID")
|
|
2927
|
+
),
|
|
2928
|
+
/* @__PURE__ */ React16.createElement(
|
|
2929
|
+
View11,
|
|
2930
|
+
{
|
|
2931
|
+
style: {
|
|
2932
|
+
padding: 6,
|
|
2933
|
+
// borderRight: "1px solid #000",
|
|
2934
|
+
width: "15%"
|
|
2935
|
+
}
|
|
2936
|
+
},
|
|
2937
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, "Remarks")
|
|
2938
|
+
)
|
|
2939
|
+
),
|
|
2940
|
+
settlements?.map((item, index) => {
|
|
2941
|
+
return /* @__PURE__ */ React16.createElement(
|
|
2942
|
+
View11,
|
|
2943
|
+
{
|
|
2944
|
+
style: {
|
|
2945
|
+
display: "flex",
|
|
2946
|
+
flexDirection: "row",
|
|
2947
|
+
border: "1px solid #000",
|
|
2948
|
+
borderTop: "none",
|
|
2949
|
+
fontSize: 10
|
|
2950
|
+
}
|
|
2951
|
+
},
|
|
2952
|
+
/* @__PURE__ */ React16.createElement(
|
|
2953
|
+
View11,
|
|
2954
|
+
{
|
|
2955
|
+
style: {
|
|
2956
|
+
padding: 6,
|
|
2957
|
+
borderRight: "1px solid #000",
|
|
2958
|
+
width: "10%"
|
|
2959
|
+
}
|
|
2960
|
+
},
|
|
2961
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, index + 1)
|
|
2962
|
+
),
|
|
2963
|
+
/* @__PURE__ */ React16.createElement(
|
|
2964
|
+
View11,
|
|
2965
|
+
{
|
|
2966
|
+
style: {
|
|
2967
|
+
padding: 6,
|
|
2968
|
+
borderRight: "1px solid #000",
|
|
2969
|
+
width: "15%"
|
|
2970
|
+
}
|
|
2971
|
+
},
|
|
2972
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, item.settlement_amount)
|
|
2973
|
+
),
|
|
2974
|
+
/* @__PURE__ */ React16.createElement(
|
|
2975
|
+
View11,
|
|
2976
|
+
{
|
|
2977
|
+
style: {
|
|
2978
|
+
padding: 6,
|
|
2979
|
+
borderRight: "1px solid #000",
|
|
2980
|
+
width: "20%",
|
|
2981
|
+
fontSize: 9
|
|
2982
|
+
}
|
|
2983
|
+
},
|
|
2984
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, item.utr)
|
|
2985
|
+
),
|
|
2986
|
+
/* @__PURE__ */ React16.createElement(
|
|
2987
|
+
View11,
|
|
2988
|
+
{
|
|
2989
|
+
style: {
|
|
2990
|
+
padding: 6,
|
|
2991
|
+
borderRight: "1px solid #000",
|
|
2992
|
+
width: "25%",
|
|
2993
|
+
fontSize: 9
|
|
2994
|
+
}
|
|
2995
|
+
},
|
|
2996
|
+
/* @__PURE__ */ React16.createElement(
|
|
2997
|
+
View11,
|
|
2998
|
+
{
|
|
2999
|
+
style: {
|
|
3000
|
+
display: "flex",
|
|
3001
|
+
flexDirection: "column"
|
|
3002
|
+
}
|
|
3003
|
+
},
|
|
3004
|
+
item.invoices.map((invoice, idx) => /* @__PURE__ */ React16.createElement(Text_default, { key: idx }, invoice.number, " (", invoice.amount, ")"))
|
|
3005
|
+
)
|
|
3006
|
+
),
|
|
3007
|
+
/* @__PURE__ */ React16.createElement(
|
|
3008
|
+
View11,
|
|
3009
|
+
{
|
|
3010
|
+
style: {
|
|
3011
|
+
padding: 6,
|
|
3012
|
+
borderRight: "1px solid #000",
|
|
3013
|
+
width: "20%"
|
|
3014
|
+
}
|
|
3015
|
+
},
|
|
3016
|
+
/* @__PURE__ */ React16.createElement(Text_default, null, item.transaction_id)
|
|
3017
|
+
),
|
|
3018
|
+
/* @__PURE__ */ React16.createElement(View11, { style: { padding: 6, width: "15%", fontSize: 7 } }, /* @__PURE__ */ React16.createElement(Text_default, null, item.remarks))
|
|
3019
|
+
);
|
|
3020
|
+
})
|
|
3021
|
+
)
|
|
3022
|
+
));
|
|
3023
|
+
};
|
|
3024
|
+
var A4SettlementsReport_default = A4SettlementsReport;
|
|
3025
|
+
|
|
2822
3026
|
// src/index.tsx
|
|
2823
3027
|
var getPrintBlob = ({
|
|
2824
3028
|
size,
|
|
@@ -2826,15 +3030,15 @@ var getPrintBlob = ({
|
|
|
2826
3030
|
dates
|
|
2827
3031
|
}) => {
|
|
2828
3032
|
if (size === "A4") {
|
|
2829
|
-
const blob = pdf(/* @__PURE__ */
|
|
3033
|
+
const blob = pdf(/* @__PURE__ */ React17.createElement(A4Print_default, { data, dates })).toBlob();
|
|
2830
3034
|
return blob;
|
|
2831
3035
|
} else {
|
|
2832
|
-
const blob = pdf(/* @__PURE__ */
|
|
3036
|
+
const blob = pdf(/* @__PURE__ */ React17.createElement(T2Inch_default, { data, dates })).toBlob();
|
|
2833
3037
|
return blob;
|
|
2834
3038
|
}
|
|
2835
3039
|
};
|
|
2836
3040
|
var getA4SummaryBlob = async () => {
|
|
2837
|
-
const blob = await pdf(/* @__PURE__ */
|
|
3041
|
+
const blob = await pdf(/* @__PURE__ */ React17.createElement(A4Print_default, { data: [], dates: ["", ""] })).toBlob();
|
|
2838
3042
|
return blob;
|
|
2839
3043
|
};
|
|
2840
3044
|
var printDevoteeReceipt2Inch = async (data) => {
|
|
@@ -2885,6 +3089,9 @@ var options = {
|
|
|
2885
3089
|
},
|
|
2886
3090
|
"multi-temple-payment": {
|
|
2887
3091
|
A4: A4MultiTemplePaymentReport_default
|
|
3092
|
+
},
|
|
3093
|
+
"settlements-report": {
|
|
3094
|
+
A4: A4SettlementsReport_default
|
|
2888
3095
|
}
|
|
2889
3096
|
};
|
|
2890
3097
|
var reportPrinter = class {
|
|
@@ -3099,7 +3306,7 @@ var reportPrinter = class {
|
|
|
3099
3306
|
}
|
|
3100
3307
|
async print(data) {
|
|
3101
3308
|
const ReportComponent = options[this.option][this.size];
|
|
3102
|
-
const document = /* @__PURE__ */
|
|
3309
|
+
const document = /* @__PURE__ */ React17.createElement(ReportComponent, { ...data });
|
|
3103
3310
|
const blob = pdf(document).toBlob();
|
|
3104
3311
|
blob.then((blob2) => {
|
|
3105
3312
|
var blobURL = URL.createObjectURL(blob2);
|
|
@@ -3114,7 +3321,7 @@ var reportPrinter = class {
|
|
|
3114
3321
|
}
|
|
3115
3322
|
async getBlob(data) {
|
|
3116
3323
|
const ReportComponent = options[this.option][this.size];
|
|
3117
|
-
const document = /* @__PURE__ */
|
|
3324
|
+
const document = /* @__PURE__ */ React17.createElement(ReportComponent, { ...data });
|
|
3118
3325
|
const blob = pdf(document).toBlob();
|
|
3119
3326
|
return blob;
|
|
3120
3327
|
}
|
package/package.json
CHANGED