shareneus 1.4.35 → 1.4.37
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/accounting/counter-sales/auto-sales-receipt-pdf.service.d.ts +290 -0
- package/dist/{services → accounting/counter-sales}/auto-sales-receipt-pdf.service.js +26 -26
- package/dist/accounting/counter-sales/pos-receipt-pdf.d.ts +156 -0
- package/dist/{services → accounting/counter-sales}/pos-receipt-pdf.js +20 -20
- package/dist/accounting/counter-sales/sales-receipt-pdf.service.d.ts +272 -0
- package/dist/{services → accounting/counter-sales}/sales-receipt-pdf.service.js +28 -27
- package/dist/accounting/counter-sales/sales-receipt-print.service.d.ts +18 -0
- package/dist/{services → accounting/counter-sales}/sales-receipt-print.service.js +67 -67
- package/dist/accounting/credit-note/cn-print.service.d.ts +14 -0
- package/dist/{services → accounting/credit-note}/cn-print.service.js +37 -37
- package/dist/accounting/credit-note/credit-note-pdf.service.d.ts +272 -0
- package/dist/{services → accounting/credit-note}/credit-note-pdf.service.js +18 -18
- package/dist/accounting/credit-note/credit-note-totals.service.d.ts +25 -0
- package/dist/{services → accounting/credit-note}/credit-note-totals.service.js +32 -32
- package/dist/accounting/debit-note/debit-note-pdf.service.d.ts +331 -0
- package/dist/{services → accounting/debit-note}/debit-note-pdf.service.js +16 -16
- package/dist/accounting/debit-note/debit-note-print.service.d.ts +14 -0
- package/dist/{services → accounting/debit-note}/debit-note-print.service.js +37 -37
- package/dist/accounting/debit-note/debit-note-totals.service.d.ts +22 -0
- package/dist/{services → accounting/debit-note}/debit-note-totals.service.js +29 -29
- package/dist/accounting/invoice/hc-inv-pdf.service.d.ts +357 -0
- package/dist/{services → accounting/invoice}/hc-inv-pdf.service.js +44 -44
- package/dist/accounting/invoice/inv-pdf.service.d.ts +314 -0
- package/dist/{services → accounting/invoice}/inv-pdf.service.js +56 -56
- package/dist/accounting/invoice/inv-print.service.d.ts +16 -0
- package/dist/{services → accounting/invoice}/inv-print.service.js +63 -63
- package/dist/accounting/invoice/invoice-landscape-pdf.service.d.ts +416 -0
- package/dist/{services → accounting/invoice}/invoice-landscape-pdf.service.js +31 -31
- package/dist/accounting/invoice/invoice-letterhead-pdf.service.d.ts +323 -0
- package/dist/{services → accounting/invoice}/invoice-letterhead-pdf.service.js +56 -56
- package/dist/accounting/invoice/invoice-portrait-pdf.d.ts +275 -0
- package/dist/{services → accounting/invoice}/invoice-portrait-pdf.js +53 -53
- package/dist/accounting/invoice/invoice-total.service.d.ts +43 -0
- package/dist/{services → accounting/invoice}/invoice-total.service.js +79 -79
- package/dist/accounting/invoice/shared-inv-pdf.service.d.ts +303 -0
- package/dist/accounting/invoice/shared-inv-pdf.service.js +763 -0
- package/dist/accounting/payment-receive/payment-pdf.service.d.ts +618 -0
- package/dist/{services → accounting/payment-receive}/payment-pdf.service.js +5 -5
- package/dist/accounting/payment-receive/receipt-print.service.d.ts +4 -0
- package/dist/{services → accounting/payment-receive}/receipt-print.service.js +6 -6
- package/dist/accounting/payment-receive/reports/pdf/customer-balances-pdf.service.d.ts +228 -0
- package/dist/{services → accounting/payment-receive/reports/pdf}/customer-balances-pdf.service.js +8 -8
- package/dist/accounting/payment-receive/reports/pdf/payment-report-pdf.service.d.ts +228 -0
- package/dist/{services → accounting/payment-receive/reports/pdf}/payment-report-pdf.service.js +4 -4
- package/dist/aggregation/aggregation.d.ts +4 -0
- package/dist/aggregation/aggregation.js +13 -13
- package/dist/appointments/appointments/appointment-total.service.d.ts +25 -0
- package/dist/{services → appointments/appointments}/appointment-total.service.js +38 -38
- package/dist/appointments/consultations/consultation-fee-receipt.service.d.ts +318 -0
- package/dist/{services → appointments/consultations}/consultation-fee-receipt.service.js +17 -17
- package/dist/appointments/consultations/consultation-full-pdf.service.d.ts +207 -0
- package/dist/{services → appointments/consultations}/consultation-full-pdf.service.js +11 -11
- package/dist/appointments/consultations/consultation-letterhead-pdf.service.d.ts +266 -0
- package/dist/{services → appointments/consultations}/consultation-letterhead-pdf.service.js +16 -16
- package/dist/appointments/consultations/consultation-pdf.service.d.ts +306 -0
- package/dist/{services → appointments/consultations}/consultation-pdf.service.js +16 -16
- package/dist/enums/cache-enums.d.ts +33 -0
- package/dist/enums/code-enums.d.ts +266 -0
- package/dist/enums/enums.d.ts +329 -0
- package/dist/enums/industry-enums.d.ts +16 -0
- package/dist/excel-files/cust-balance-excel.service.d.ts +26 -0
- package/dist/excel-files/cust-balance-excel.service.js +5 -5
- package/dist/excel-files/expiring-drugs-excel.service.d.ts +24 -0
- package/dist/excel-files/expiring-drugs-excel.service.js +7 -7
- package/dist/excel-files/insurance-expire-excel.service.d.ts +23 -0
- package/dist/excel-files/insurance-expire-excel.service.js +4 -4
- package/dist/excel-files/invoice-wise-excel.service.d.ts +26 -0
- package/dist/excel-files/invoice-wise-excel.service.js +3 -3
- package/dist/excel-files/next-service-date-excel.service.d.ts +25 -0
- package/dist/excel-files/next-service-date-excel.service.js +5 -5
- package/dist/excel-files/payment-receive-excel.service.d.ts +25 -0
- package/dist/excel-files/payment-receive-excel.service.js +6 -6
- package/dist/excel-files/payments-made-excel.service.d.ts +25 -0
- package/dist/excel-files/payments-made-excel.service.js +6 -6
- package/dist/excel-files/repair-orders-excel.service.d.ts +24 -0
- package/dist/excel-files/repair-orders-excel.service.js +10 -10
- package/dist/excel-files/sales-by-service-details-excel.service.d.ts +0 -0
- package/dist/excel-files/sales-by-service-summary-excel.service.d.ts +24 -0
- package/dist/excel-files/sales-by-service-summary-excel.service.js +14 -14
- package/dist/excel-files/scheduled-drug-summary-excel.service.d.ts +24 -0
- package/dist/excel-files/scheduled-drug-summary-excel.service.js +8 -8
- package/dist/excel-files/scheduled-drugs-excel.service.d.ts +24 -0
- package/dist/excel-files/scheduled-drugs-excel.service.js +10 -10
- package/dist/excel-files/spares-issue-excel.service.d.ts +26 -0
- package/dist/excel-files/spares-issue-excel.service.js +14 -14
- package/dist/excel-files/stock-excel.service.d.ts +23 -0
- package/dist/excel-files/stock-excel.service.js +3 -3
- package/dist/excel-files/ven-balance-excel.service.d.ts +27 -0
- package/dist/excel-files/ven-balance-excel.service.js +3 -3
- package/dist/gst/excel/GSTR-RO-excel.service.d.ts +27 -0
- package/dist/{excel-files → gst/excel}/GSTR-RO-excel.service.js +3 -3
- package/dist/gst/excel/GSTR1-excel.service.d.ts +16 -0
- package/dist/{excel-files → gst/excel}/GSTR1-excel.service.js +7 -7
- package/dist/gst/excel/GSTR2-excel.service.d.ts +16 -0
- package/dist/{excel-files → gst/excel}/GSTR2-excel.service.js +6 -6
- package/dist/gst/excel/tally-sales-import.service.d.ts +27 -0
- package/dist/{excel-files → gst/excel}/tally-sales-import.service.js +3 -3
- package/dist/index.d.ts +124 -0
- package/dist/index.js +102 -102
- package/dist/inventory/items/issue-parts-pdf.service.d.ts +303 -0
- package/dist/{services → inventory/items}/issue-parts-pdf.service.js +45 -45
- package/dist/inventory/items/item-bar-code-label-pdf.d.ts +127 -0
- package/dist/{services → inventory/items}/item-bar-code-label-pdf.js +3 -3
- package/dist/inventory/items/item-detais-pdf.d.ts +121 -0
- package/dist/{services → inventory/items}/item-detais-pdf.js +1 -1
- package/dist/inventory/items/item-price-for-pricelist.d.ts +1 -0
- package/dist/{services → inventory/items}/item-price-for-pricelist.js +44 -50
- package/dist/inventory/items/reports/excel/item-wise-mout-details.d.ts +23 -0
- package/dist/{excel-files → inventory/items/reports/excel}/item-wise-mout-details.js +4 -4
- package/dist/inventory/items/reports/excel/item-wise-mout-summary.d.ts +23 -0
- package/dist/{excel-files → inventory/items/reports/excel}/item-wise-mout-summary.js +4 -4
- package/dist/inventory/items/reports/pdf/expiring-drugs-pdf.service.d.ts +49 -0
- package/dist/{services → inventory/items/reports/pdf}/expiring-drugs-pdf.service.js +6 -6
- package/dist/inventory/items/reports/pdf/item-wise-mout-details-pdf.d.ts +229 -0
- package/dist/{services → inventory/items/reports/pdf}/item-wise-mout-details-pdf.js +4 -4
- package/dist/inventory/items/reports/pdf/item-wise-mout-summary-pdf.d.ts +228 -0
- package/dist/{services → inventory/items/reports/pdf}/item-wise-mout-summary-pdf.js +3 -3
- package/dist/inventory/items/reports/pdf/reorder-point-pdf.service.d.ts +48 -0
- package/dist/{services → inventory/items/reports/pdf}/reorder-point-pdf.service.js +3 -3
- package/dist/inventory/material-out/mout-pdf.service.d.ts +324 -0
- package/dist/{services → inventory/material-out}/mout-pdf.service.js +19 -19
- package/dist/inventory/transfer-order/transfer-order-pdf.service.d.ts +48 -0
- package/dist/{services → inventory/transfer-order}/transfer-order-pdf.service.js +2 -2
- package/dist/purchases/payment-made/reports/pdf/vendor-balances-pdf.service.d.ts +227 -0
- package/dist/{services → purchases/payment-made/reports/pdf}/vendor-balances-pdf.service.js +7 -7
- package/dist/purchases/purchase-order/po-totals.service.d.ts +24 -0
- package/dist/{services → purchases/purchase-order}/po-totals.service.js +29 -29
- package/dist/purchases/purchase-order/purchase-order-pdf.service.d.ts +526 -0
- package/dist/{services → purchases/purchase-order}/purchase-order-pdf.service.js +42 -42
- package/dist/purchases/purchase-order/purchase-order-print.service.d.ts +8 -0
- package/dist/{services → purchases/purchase-order}/purchase-order-print.service.js +46 -46
- package/dist/purchases/purchase-order/purchase-order-totals.service.d.ts +23 -0
- package/dist/{services → purchases/purchase-order}/purchase-order-totals.service.js +55 -55
- package/dist/purchases/vendor-credit-note/vendor-credit-note-pdf.service.d.ts +491 -0
- package/dist/{services → purchases/vendor-credit-note}/vendor-credit-note-pdf.service.js +29 -29
- package/dist/purchases/vendor-credit-note/vendor-credit-note-print.service.d.ts +6 -0
- package/dist/{services → purchases/vendor-credit-note}/vendor-credit-note-print.service.js +31 -31
- package/dist/purchases/vendor-credit-note/vendor-credit-note-totals.service.d.ts +24 -0
- package/dist/{services → purchases/vendor-credit-note}/vendor-credit-note-totals.service.js +38 -38
- package/dist/purchases/vendor-debit-note/vendor-debit-note-pdf.service.d.ts +271 -0
- package/dist/{services → purchases/vendor-debit-note}/vendor-debit-note-pdf.service.js +18 -18
- package/dist/purchases/vendor-debit-note/vendor-debit-note-print.service.d.ts +14 -0
- package/dist/{services → purchases/vendor-debit-note}/vendor-debit-note-print.service.js +34 -34
- package/dist/purchases/vendor-debit-note/vendor-debit-note-totals.service.d.ts +22 -0
- package/dist/{services → purchases/vendor-debit-note}/vendor-debit-note-totals.service.js +31 -31
- package/dist/sales/delivery-challan/dc-landscape-pdf.service.d.ts +416 -0
- package/dist/{services → sales/delivery-challan}/dc-landscape-pdf.service.js +30 -30
- package/dist/sales/delivery-challan/dc-landscape-without-price-pdf.service.d.ts +400 -0
- package/dist/{services → sales/delivery-challan}/dc-landscape-without-price-pdf.service.js +26 -26
- package/dist/sales/delivery-challan/dc-without-price-pdf.service.d.ts +271 -0
- package/dist/{services → sales/delivery-challan}/dc-without-price-pdf.service.js +17 -17
- package/dist/sales/delivery-challan/delivery-challan-pdf.service.d.ts +269 -0
- package/dist/{services → sales/delivery-challan}/delivery-challan-pdf.service.js +18 -18
- package/dist/sales/delivery-challan/delivery-challan-print.service.d.ts +12 -0
- package/dist/{services → sales/delivery-challan}/delivery-challan-print.service.js +30 -30
- package/dist/sales/delivery-challan/delivery-challan-totals.d.ts +27 -0
- package/dist/{services → sales/delivery-challan}/delivery-challan-totals.js +33 -33
- package/dist/sales/reports/excel/analysis-excel.service.d.ts +23 -0
- package/dist/{excel-files → sales/reports/excel}/analysis-excel.service.js +4 -4
- package/dist/sales/reports/excel/category-wise-item-excel.service.d.ts +23 -0
- package/dist/{excel-files → sales/reports/excel}/category-wise-item-excel.service.js +10 -10
- package/dist/sales/reports/excel/cust-wise-sales-details.d.ts +25 -0
- package/dist/{excel-files → sales/reports/excel}/cust-wise-sales-details.js +5 -5
- package/dist/sales/reports/excel/cust-wise-sales-summary-excel.service.d.ts +24 -0
- package/dist/{excel-files → sales/reports/excel}/cust-wise-sales-summary-excel.service.js +5 -5
- package/dist/sales/reports/excel/item-wise-doctor-sale-excel.service.d.ts +24 -0
- package/dist/{excel-files → sales/reports/excel}/item-wise-doctor-sale-excel.service.js +7 -7
- package/dist/sales/reports/excel/items-wise-sales-excel.service.d.ts +24 -0
- package/dist/{excel-files → sales/reports/excel}/items-wise-sales-excel.service.js +10 -10
- package/dist/sales/reports/excel/manf-wise-sales-excel.service.d.ts +24 -0
- package/dist/{excel-files → sales/reports/excel}/manf-wise-sales-excel.service.js +4 -4
- package/dist/sales/reports/excel/operator-wise-details.d.ts +23 -0
- package/dist/{excel-files → sales/reports/excel}/operator-wise-details.js +4 -4
- package/dist/sales/reports/excel/operator-wise-summary.d.ts +23 -0
- package/dist/{excel-files → sales/reports/excel}/operator-wise-summary.js +4 -4
- package/dist/sales/reports/excel/sa-wise-labor-sales-excel.service.d.ts +23 -0
- package/dist/{excel-files → sales/reports/excel}/sa-wise-labor-sales-excel.service.js +6 -6
- package/dist/sales/reports/excel/sa-wise-part-sales-excel.service.d.ts +23 -0
- package/dist/{excel-files → sales/reports/excel}/sa-wise-part-sales-excel.service.js +6 -6
- package/dist/sales/reports/excel/sale-summary-excel.service.d.ts +25 -0
- package/dist/{excel-files → sales/reports/excel}/sale-summary-excel.service.js +3 -3
- package/dist/sales/reports/pdf/analysis-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/analysis-pdf.service.js +9 -9
- package/dist/sales/reports/pdf/category-wise-item-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/category-wise-item-pdf.service.js +7 -7
- package/dist/sales/reports/pdf/cust-wise-sales-details-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/cust-wise-sales-details-pdf.service.js +9 -9
- package/dist/sales/reports/pdf/cust-wise-sales-summary-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/cust-wise-sales-summary-pdf.service.js +8 -9
- package/dist/sales/reports/pdf/item-wise-doctor-sale-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/item-wise-doctor-sale-pdf.service.js +4 -4
- package/dist/sales/reports/pdf/item-wise-sales-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/item-wise-sales-pdf.service.js +7 -8
- package/dist/sales/reports/pdf/manf-wise-sales-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/manf-wise-sales-pdf.service.js +6 -6
- package/dist/sales/reports/pdf/operator-wise-details-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/operator-wise-details-pdf.service.js +9 -9
- package/dist/sales/reports/pdf/operator-wise-summary-pdf.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/operator-wise-summary-pdf.js +8 -8
- package/dist/sales/reports/pdf/sales-by-service-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/sales-by-service-pdf.service.js +7 -7
- package/dist/sales/reports/pdf/scheduled-drug-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/scheduled-drug-pdf.service.js +8 -8
- package/dist/sales/reports/pdf/scheduled-drug-summary-pdf.service.d.ts +228 -0
- package/dist/{services → sales/reports/pdf}/scheduled-drug-summary-pdf.service.js +5 -5
- package/dist/sales/sales/equipment-design-pdf.service.d.ts +121 -0
- package/dist/{services → sales/sales}/equipment-design-pdf.service.js +12 -12
- package/dist/sales/sales/pack-ship-pdf.service.d.ts +262 -0
- package/dist/{services → sales/sales}/pack-ship-pdf.service.js +5 -5
- package/dist/sales/sales/pack-ship-print.service.d.ts +11 -0
- package/dist/{services → sales/sales}/pack-ship-print.service.js +27 -27
- package/dist/sales/sales/sales-pdf.service.d.ts +275 -0
- package/dist/{services → sales/sales}/sales-pdf.service.js +25 -25
- package/dist/sales/sales/sales-print.service.d.ts +15 -0
- package/dist/{services → sales/sales}/sales-print.service.js +58 -58
- package/dist/sales/sales/sales-totals.service.d.ts +27 -0
- package/dist/{services → sales/sales}/sales-totals.service.js +34 -34
- package/dist/services/checklist-pdf.d.ts +57 -0
- package/dist/services/checklist-pdf.js +5 -5
- package/dist/services/checklists-pdf.d.ts +12 -0
- package/dist/services/checklists-pdf.js +1 -1
- package/dist/services/est.print-service.d.ts +64 -0
- package/dist/services/est.print-service.js +151 -151
- package/dist/services/next-service-date-pdf.service.d.ts +228 -0
- package/dist/services/next-service-date-pdf.service.js +2 -2
- package/dist/services/reports/insurance-expire-pdf.service.d.ts +227 -0
- package/dist/services/{insurance-expire-pdf.service.js → reports/insurance-expire-pdf.service.js} +2 -2
- package/dist/services/reports/repair-orders-pdf.service.d.ts +229 -0
- package/dist/services/{repair-orders-pdf.service.js → reports/repair-orders-pdf.service.js} +4 -4
- package/dist/services/ro-pdf.service.d.ts +1060 -0
- package/dist/services/ro-pdf.service.js +82 -82
- package/dist/services/ro-print-service.d.ts +45 -0
- package/dist/services/ro-print-service.js +88 -88
- package/dist/services/ro-totals.service.d.ts +65 -0
- package/dist/services/ro-totals.service.js +123 -123
- package/dist/services/separate-wo-print.service.d.ts +494 -0
- package/dist/services/separate-wo-print.service.js +10 -10
- package/dist/services/shared-inv-pdf.service.d.ts +303 -0
- package/dist/services/shared-inv-pdf.service.js +46 -46
- package/dist/services/technician-pdf.service.d.ts +221 -0
- package/dist/services/technician-pdf.service.js +11 -11
- package/dist/services/technician-print.service.d.ts +5 -0
- package/dist/services/technician-print.service.js +10 -10
- package/dist/shared/math-operations.d.ts +53 -0
- package/dist/shared/math-operations.js +184 -0
- package/dist/shared/shared-services/shared-pdf.service.d.ts +926 -0
- package/dist/{services → shared/shared-services}/shared-pdf.service.js +120 -120
- package/dist/shared/shared-services/shared-print.service.d.ts +49 -0
- package/dist/{services → shared/shared-services}/shared-print.service.js +68 -68
- package/dist/shared/util.d.ts +3 -0
- package/dist/shared/util.js +15 -0
- package/dist/tasks/meetings/meeting-pdf.d.ts +107 -0
- package/dist/{services → tasks/meetings}/meeting-pdf.js +15 -15
- package/dist/tasks/tasks/task-pdf.service.d.ts +127 -0
- package/dist/{services → tasks/tasks}/task-pdf.service.js +12 -12
- package/dist/tasks/tasks/task-reports-pdf.service.d.ts +94 -0
- package/dist/{services → tasks/tasks}/task-reports-pdf.service.js +11 -11
- package/dist/utils/my-date.d.ts +104 -0
- package/dist/{shared → utils}/my-date.js +31 -31
- package/dist/utils/tr-utils.d.ts +41 -0
- package/dist/{shared/utils.js → utils/tr-utils.js} +0 -8
- package/package.json +2 -1
- package/tsconfig.json +1 -0
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
export declare class ItemBarCodeLabelPdf {
|
|
2
|
+
static PrintFile: any;
|
|
3
|
+
static ItemDetailsPrint(Item: any, win: any, custom: boolean, txt: string): void;
|
|
4
|
+
static GetHeader(Entity: any, HColor: string): any;
|
|
5
|
+
static ChangeTableFormat(Item: any, custom: boolean, txt: string): ({
|
|
6
|
+
svg: any;
|
|
7
|
+
alignment: string;
|
|
8
|
+
marginTop?: undefined;
|
|
9
|
+
columns?: undefined;
|
|
10
|
+
stack?: undefined;
|
|
11
|
+
} | {
|
|
12
|
+
alignment: string;
|
|
13
|
+
marginTop: number;
|
|
14
|
+
columns: ({
|
|
15
|
+
text: string;
|
|
16
|
+
bold: boolean;
|
|
17
|
+
marginTop: number;
|
|
18
|
+
stack?: undefined;
|
|
19
|
+
} | {
|
|
20
|
+
stack: ({
|
|
21
|
+
text: string;
|
|
22
|
+
bold: boolean;
|
|
23
|
+
lineHeight: number;
|
|
24
|
+
} | {
|
|
25
|
+
text: string;
|
|
26
|
+
bold: boolean;
|
|
27
|
+
lineHeight?: undefined;
|
|
28
|
+
})[];
|
|
29
|
+
text?: undefined;
|
|
30
|
+
bold?: undefined;
|
|
31
|
+
marginTop?: undefined;
|
|
32
|
+
})[];
|
|
33
|
+
svg?: undefined;
|
|
34
|
+
stack?: undefined;
|
|
35
|
+
} | {
|
|
36
|
+
alignment: string;
|
|
37
|
+
marginTop: number;
|
|
38
|
+
stack: {
|
|
39
|
+
text: string;
|
|
40
|
+
bold: boolean;
|
|
41
|
+
lineHeight: number;
|
|
42
|
+
}[];
|
|
43
|
+
svg?: undefined;
|
|
44
|
+
columns?: undefined;
|
|
45
|
+
})[] | {
|
|
46
|
+
stack: ({
|
|
47
|
+
style: string;
|
|
48
|
+
fontSize: number;
|
|
49
|
+
table: {
|
|
50
|
+
widths: string[];
|
|
51
|
+
body: ({
|
|
52
|
+
text: any;
|
|
53
|
+
marginTop: number;
|
|
54
|
+
marginBottom: number;
|
|
55
|
+
}[] | ({
|
|
56
|
+
text: string;
|
|
57
|
+
marginTop: number;
|
|
58
|
+
marginBottom: number;
|
|
59
|
+
colSpan?: undefined;
|
|
60
|
+
} | {
|
|
61
|
+
text: any;
|
|
62
|
+
colSpan: number;
|
|
63
|
+
marginTop: number;
|
|
64
|
+
marginBottom: number;
|
|
65
|
+
} | {
|
|
66
|
+
text?: undefined;
|
|
67
|
+
marginTop?: undefined;
|
|
68
|
+
marginBottom?: undefined;
|
|
69
|
+
colSpan?: undefined;
|
|
70
|
+
})[])[];
|
|
71
|
+
};
|
|
72
|
+
} | {
|
|
73
|
+
svg: any;
|
|
74
|
+
alignment: string;
|
|
75
|
+
marginTop: number;
|
|
76
|
+
style?: undefined;
|
|
77
|
+
marginLeft?: undefined;
|
|
78
|
+
fontSize?: undefined;
|
|
79
|
+
table?: undefined;
|
|
80
|
+
} | {
|
|
81
|
+
style: string;
|
|
82
|
+
marginLeft: number;
|
|
83
|
+
marginTop: number;
|
|
84
|
+
fontSize: number;
|
|
85
|
+
table: {
|
|
86
|
+
marginTop: number;
|
|
87
|
+
widths: number[];
|
|
88
|
+
body: {
|
|
89
|
+
text: string;
|
|
90
|
+
marginTop: number;
|
|
91
|
+
marginBottom: number;
|
|
92
|
+
}[][];
|
|
93
|
+
};
|
|
94
|
+
svg?: undefined;
|
|
95
|
+
alignment?: undefined;
|
|
96
|
+
})[];
|
|
97
|
+
};
|
|
98
|
+
static TableCreation(Item: any): {
|
|
99
|
+
style: string;
|
|
100
|
+
fontSize: number;
|
|
101
|
+
table: {
|
|
102
|
+
widths: string[];
|
|
103
|
+
body: ({
|
|
104
|
+
text: any;
|
|
105
|
+
marginTop: number;
|
|
106
|
+
marginBottom: number;
|
|
107
|
+
}[] | ({
|
|
108
|
+
text: string;
|
|
109
|
+
marginTop: number;
|
|
110
|
+
marginBottom: number;
|
|
111
|
+
colSpan?: undefined;
|
|
112
|
+
} | {
|
|
113
|
+
text: any;
|
|
114
|
+
colSpan: number;
|
|
115
|
+
marginTop: number;
|
|
116
|
+
marginBottom: number;
|
|
117
|
+
} | {
|
|
118
|
+
text?: undefined;
|
|
119
|
+
marginTop?: undefined;
|
|
120
|
+
marginBottom?: undefined;
|
|
121
|
+
colSpan?: undefined;
|
|
122
|
+
})[])[];
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
static textToSvgBarcode(text: string): any;
|
|
126
|
+
static textToBase64Barcode(text: any, custom: boolean): string;
|
|
127
|
+
}
|
|
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.ItemBarCodeLabelPdf = void 0;
|
|
7
|
-
const shared_pdf_service_1 = require("./shared-pdf.service");
|
|
8
|
-
const utils_1 = require("../shared/utils");
|
|
9
7
|
const jsbarcode_1 = __importDefault(require("jsbarcode"));
|
|
8
|
+
const shared_pdf_service_1 = require("../../shared/shared-services/shared-pdf.service");
|
|
9
|
+
const tr_utils_1 = require("../../utils/tr-utils");
|
|
10
10
|
class ItemBarCodeLabelPdf {
|
|
11
11
|
static ItemDetailsPrint(Item, win, custom, txt) {
|
|
12
12
|
let dd = {
|
|
@@ -89,7 +89,7 @@ class ItemBarCodeLabelPdf {
|
|
|
89
89
|
{ text: '' + shared_pdf_service_1.SharedPDFService.GetEmail(Entity.Email) + '', style: headerstyle, fontSize: 10 },
|
|
90
90
|
// { text: 'GSTIN:' + Entity.GSTIN + ', ' + 'PAN: ' + Entity.PAN, style: headerstyle },
|
|
91
91
|
];
|
|
92
|
-
if (!
|
|
92
|
+
if (!tr_utils_1.TrUtils.IsEmpty(Entity.Adrs2)) {
|
|
93
93
|
SubHeader.splice(1, 0, { text: '' + Entity.Adrs2 + '', style: [headerstyle], fontSize: 10 });
|
|
94
94
|
}
|
|
95
95
|
// if (!TrUtils.IsEmpty(Entity.TLine)) {
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
export declare class ItemDetaisPdf {
|
|
2
|
+
static PrintFile: any;
|
|
3
|
+
static ItemDetailsPrint(Item: any, win: any, custom: boolean, txt: string): void;
|
|
4
|
+
static ChangeTableFormat(Item: any, custom: boolean, txt: string): ({
|
|
5
|
+
image: string;
|
|
6
|
+
alignment: string;
|
|
7
|
+
marginTop?: undefined;
|
|
8
|
+
columns?: undefined;
|
|
9
|
+
stack?: undefined;
|
|
10
|
+
} | {
|
|
11
|
+
alignment: string;
|
|
12
|
+
marginTop: number;
|
|
13
|
+
columns: ({
|
|
14
|
+
text: string;
|
|
15
|
+
bold: boolean;
|
|
16
|
+
marginTop: number;
|
|
17
|
+
stack?: undefined;
|
|
18
|
+
} | {
|
|
19
|
+
stack: ({
|
|
20
|
+
text: string;
|
|
21
|
+
bold: boolean;
|
|
22
|
+
lineHeight: number;
|
|
23
|
+
} | {
|
|
24
|
+
text: string;
|
|
25
|
+
bold: boolean;
|
|
26
|
+
lineHeight?: undefined;
|
|
27
|
+
})[];
|
|
28
|
+
text?: undefined;
|
|
29
|
+
bold?: undefined;
|
|
30
|
+
marginTop?: undefined;
|
|
31
|
+
})[];
|
|
32
|
+
image?: undefined;
|
|
33
|
+
stack?: undefined;
|
|
34
|
+
} | {
|
|
35
|
+
alignment: string;
|
|
36
|
+
marginTop: number;
|
|
37
|
+
stack: {
|
|
38
|
+
text: string;
|
|
39
|
+
bold: boolean;
|
|
40
|
+
lineHeight: number;
|
|
41
|
+
}[];
|
|
42
|
+
image?: undefined;
|
|
43
|
+
columns?: undefined;
|
|
44
|
+
})[] | {
|
|
45
|
+
stack: ({
|
|
46
|
+
style: string;
|
|
47
|
+
table: {
|
|
48
|
+
widths: string[];
|
|
49
|
+
body: (({
|
|
50
|
+
text: string;
|
|
51
|
+
lineHeight: number;
|
|
52
|
+
} | {
|
|
53
|
+
text: any;
|
|
54
|
+
lineHeight?: undefined;
|
|
55
|
+
})[] | ({
|
|
56
|
+
text: string;
|
|
57
|
+
lineHeight: number;
|
|
58
|
+
colSpan?: undefined;
|
|
59
|
+
} | {
|
|
60
|
+
text: any;
|
|
61
|
+
colSpan: number;
|
|
62
|
+
lineHeight?: undefined;
|
|
63
|
+
} | {
|
|
64
|
+
text?: undefined;
|
|
65
|
+
lineHeight?: undefined;
|
|
66
|
+
colSpan?: undefined;
|
|
67
|
+
})[])[];
|
|
68
|
+
};
|
|
69
|
+
} | {
|
|
70
|
+
image: string;
|
|
71
|
+
alignment: string;
|
|
72
|
+
style?: undefined;
|
|
73
|
+
marginLeft?: undefined;
|
|
74
|
+
marginTop?: undefined;
|
|
75
|
+
table?: undefined;
|
|
76
|
+
} | {
|
|
77
|
+
style: string;
|
|
78
|
+
marginLeft: number;
|
|
79
|
+
marginTop: number;
|
|
80
|
+
table: {
|
|
81
|
+
marginTop: number;
|
|
82
|
+
widths: number[];
|
|
83
|
+
body: ({
|
|
84
|
+
text: string;
|
|
85
|
+
lineHeight: number;
|
|
86
|
+
} | {
|
|
87
|
+
text: string;
|
|
88
|
+
lineHeight?: undefined;
|
|
89
|
+
})[][];
|
|
90
|
+
};
|
|
91
|
+
image?: undefined;
|
|
92
|
+
alignment?: undefined;
|
|
93
|
+
})[];
|
|
94
|
+
};
|
|
95
|
+
static TableCreation(Item: any): {
|
|
96
|
+
style: string;
|
|
97
|
+
table: {
|
|
98
|
+
widths: string[];
|
|
99
|
+
body: (({
|
|
100
|
+
text: string;
|
|
101
|
+
lineHeight: number;
|
|
102
|
+
} | {
|
|
103
|
+
text: any;
|
|
104
|
+
lineHeight?: undefined;
|
|
105
|
+
})[] | ({
|
|
106
|
+
text: string;
|
|
107
|
+
lineHeight: number;
|
|
108
|
+
colSpan?: undefined;
|
|
109
|
+
} | {
|
|
110
|
+
text: any;
|
|
111
|
+
colSpan: number;
|
|
112
|
+
lineHeight?: undefined;
|
|
113
|
+
} | {
|
|
114
|
+
text?: undefined;
|
|
115
|
+
lineHeight?: undefined;
|
|
116
|
+
colSpan?: undefined;
|
|
117
|
+
})[])[];
|
|
118
|
+
};
|
|
119
|
+
};
|
|
120
|
+
static textToBase64Barcode(text: any, custom: boolean): string;
|
|
121
|
+
}
|
|
@@ -5,7 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.ItemDetaisPdf = void 0;
|
|
7
7
|
const jsbarcode_1 = __importDefault(require("jsbarcode"));
|
|
8
|
-
const shared_pdf_service_1 = require("
|
|
8
|
+
const shared_pdf_service_1 = require("../../shared/shared-services/shared-pdf.service");
|
|
9
9
|
class ItemDetaisPdf {
|
|
10
10
|
static ItemDetailsPrint(Item, win, custom, txt) {
|
|
11
11
|
let dd = {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function GetItemPriceForPriceList(item: any, priceList: any, includeMargin: boolean): any;
|
|
@@ -1,34 +1,30 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.GetItemPriceForPriceList = GetItemPriceForPriceList;
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
exports.CalcDiscPrice = CalcDiscPrice;
|
|
7
|
-
exports.GetMarginValue = GetMarginValue;
|
|
8
|
-
const aggregation_1 = require("../aggregation/aggregation");
|
|
9
|
-
const utils_1 = require("../shared/utils");
|
|
4
|
+
const math_operations_1 = require("../../shared/math-operations");
|
|
5
|
+
const util_1 = require("../../shared/util");
|
|
10
6
|
function GetItemPriceForPriceList(item, priceList, includeMargin) {
|
|
11
7
|
let salePricesByPriceListId = [];
|
|
12
|
-
if ((0,
|
|
8
|
+
if ((0, util_1.IsNotNull)(item.SalePrices) && item.SalePrices.length > 0) {
|
|
13
9
|
salePricesByPriceListId = item.SalePrices.filter((price) => priceList._id.toString() == price.PrListId.toString());
|
|
14
10
|
}
|
|
15
11
|
if (salePricesByPriceListId.length > 0) {
|
|
16
12
|
item.SalePrices = salePricesByPriceListId;
|
|
17
13
|
if (item.Track == 'TR' || item.Track == 'SN') {
|
|
18
14
|
item.Sale["MRP"] = item.Sale.Price;
|
|
19
|
-
if ((0,
|
|
20
|
-
const calculatedPrice = CalcDiscPrice(item.SalePrices[0].Price, item.SalePrices[0].Disc);
|
|
15
|
+
if ((0, util_1.IsNotNull)(item.SalePrices[0].Price) && (0, util_1.IsNotNull)(item.SalePrices[0].Disc)) {
|
|
16
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(item.SalePrices[0].Price, item.SalePrices[0].Disc);
|
|
21
17
|
item.Sale.Price = ApplyRounding(calculatedPrice, priceList);
|
|
22
18
|
}
|
|
23
|
-
else if ((0,
|
|
19
|
+
else if ((0, util_1.IsNotNull)(item.SalePrices[0].Price) && (0, util_1.IsNull)(item.SalePrices[0].Disc)) {
|
|
24
20
|
item.Sale.Price = ApplyRounding(item.SalePrices[0].Price, priceList);
|
|
25
21
|
}
|
|
26
|
-
else if ((0,
|
|
27
|
-
const calculatedPrice = CalcDiscPrice(item.Sale.Price, item.SalePrices[0].Disc);
|
|
22
|
+
else if ((0, util_1.IsNull)(item.SalePrices[0].Price) && (0, util_1.IsNotNull)(item.SalePrices[0].Disc)) {
|
|
23
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(item.Sale.Price, item.SalePrices[0].Disc);
|
|
28
24
|
item.Sale.Price = ApplyRounding(calculatedPrice, priceList);
|
|
29
25
|
}
|
|
30
26
|
if (includeMargin) {
|
|
31
|
-
item.Margin = GetMarginValue(item.Sale.Price, item.Pur.Cost);
|
|
27
|
+
item.Margin = (0, math_operations_1.GetMarginValue)(item.Sale.Price, item.Pur.Cost);
|
|
32
28
|
}
|
|
33
29
|
}
|
|
34
30
|
else if (item.Track == 'BN') {
|
|
@@ -40,20 +36,20 @@ function GetItemPriceForPriceList(item, priceList, includeMargin) {
|
|
|
40
36
|
}
|
|
41
37
|
element.MRP = element.Price;
|
|
42
38
|
if (batchSalePrice.length > 0) {
|
|
43
|
-
if ((0,
|
|
44
|
-
const calculatedPrice = CalcDiscPrice(batchSalePrice[0].Price, batchSalePrice[0].Disc);
|
|
39
|
+
if ((0, util_1.IsNotNull)(batchSalePrice[0].Price) && (0, util_1.IsNotNull)(batchSalePrice[0].Disc)) {
|
|
40
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(batchSalePrice[0].Price, batchSalePrice[0].Disc);
|
|
45
41
|
element.Price = ApplyRounding(calculatedPrice, priceList);
|
|
46
42
|
}
|
|
47
|
-
else if ((0,
|
|
43
|
+
else if ((0, util_1.IsNotNull)(batchSalePrice[0].Price) && (0, util_1.IsNull)(batchSalePrice[0].Disc)) {
|
|
48
44
|
element.Price = ApplyRounding(batchSalePrice[0].Price, priceList);
|
|
49
45
|
}
|
|
50
|
-
else if ((0,
|
|
51
|
-
const calculatedPrice = CalcDiscPrice(element.Price, batchSalePrice[0].Disc);
|
|
46
|
+
else if ((0, util_1.IsNull)(batchSalePrice[0].Price) && (0, util_1.IsNotNull)(batchSalePrice[0].Disc)) {
|
|
47
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(element.Price, batchSalePrice[0].Disc);
|
|
52
48
|
element.Price = ApplyRounding(calculatedPrice, priceList);
|
|
53
49
|
}
|
|
54
50
|
}
|
|
55
51
|
if (includeMargin) {
|
|
56
|
-
element.Margin = GetMarginValue(element.Price, element.Cost);
|
|
52
|
+
element.Margin = (0, math_operations_1.GetMarginValue)(element.Price, element.Cost);
|
|
57
53
|
}
|
|
58
54
|
}
|
|
59
55
|
}
|
|
@@ -65,21 +61,34 @@ function CalculatePriceBasedOnPriceList(item, priceList, includeMargin) {
|
|
|
65
61
|
var _a, _b;
|
|
66
62
|
if (priceList != null) {
|
|
67
63
|
if (priceList.PrCalc == "FIXED") {
|
|
68
|
-
if (priceList.Fixed && (0,
|
|
64
|
+
if (priceList.Fixed && (0, util_1.IsNotNull)(priceList.Fixed.Price)) {
|
|
69
65
|
const fixedPrice = priceList.Fixed.Price;
|
|
66
|
+
const fixedDisc = priceList.Fixed.Disc || 0;
|
|
70
67
|
if (item.Track == 'TR' || item.Track == 'SN') {
|
|
71
68
|
item.Sale["MRP"] = item.Sale.Price;
|
|
72
|
-
|
|
69
|
+
if ((0, util_1.IsNotNull)(fixedDisc) && fixedDisc > 0) {
|
|
70
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(fixedPrice, fixedDisc);
|
|
71
|
+
item.Sale.Price = ApplyRounding(calculatedPrice, priceList);
|
|
72
|
+
}
|
|
73
|
+
else {
|
|
74
|
+
item.Sale.Price = ApplyRounding(fixedPrice, priceList);
|
|
75
|
+
}
|
|
73
76
|
if (includeMargin) {
|
|
74
|
-
item.Margin = GetMarginValue(item.Sale.Price, item.Pur.Cost);
|
|
77
|
+
item.Margin = (0, math_operations_1.GetMarginValue)(item.Sale.Price, item.Pur.Cost);
|
|
75
78
|
}
|
|
76
79
|
}
|
|
77
80
|
else if (item.Track == 'BN') {
|
|
78
81
|
for (let batch of item.Batches) {
|
|
79
82
|
batch.MRP = batch.Price;
|
|
80
|
-
|
|
83
|
+
if ((0, util_1.IsNotNull)(fixedDisc) && fixedDisc > 0) {
|
|
84
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(fixedPrice, fixedDisc);
|
|
85
|
+
batch.Price = ApplyRounding(calculatedPrice, priceList);
|
|
86
|
+
}
|
|
87
|
+
else {
|
|
88
|
+
batch.Price = ApplyRounding(fixedPrice, priceList);
|
|
89
|
+
}
|
|
81
90
|
if (includeMargin) {
|
|
82
|
-
batch.Margin = GetMarginValue(batch.Price, batch.Cost);
|
|
91
|
+
batch.Margin = (0, math_operations_1.GetMarginValue)(batch.Price, batch.Cost);
|
|
83
92
|
}
|
|
84
93
|
}
|
|
85
94
|
}
|
|
@@ -92,19 +101,19 @@ function CalculatePriceBasedOnPriceList(item, priceList, includeMargin) {
|
|
|
92
101
|
if (priceList.BasedOn == "SP") {
|
|
93
102
|
if (item.Track == 'TR' || item.Track == 'SN') {
|
|
94
103
|
item.Sale["MRP"] = item.Sale.Price;
|
|
95
|
-
const calculatedPrice = CalcDiscPrice(item.Sale.Price, discPerc, markUp);
|
|
104
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(item.Sale.Price, discPerc, markUp);
|
|
96
105
|
item.Sale.Price = ApplyRounding(calculatedPrice, priceList);
|
|
97
106
|
if (includeMargin) {
|
|
98
|
-
item.Margin = GetMarginValue(item.Sale.Price, item.Pur.Cost);
|
|
107
|
+
item.Margin = (0, math_operations_1.GetMarginValue)(item.Sale.Price, item.Pur.Cost);
|
|
99
108
|
}
|
|
100
109
|
}
|
|
101
110
|
else if (item.Track == 'BN') {
|
|
102
111
|
for (let batch of item.Batches) {
|
|
103
112
|
batch.MRP = batch.Price;
|
|
104
|
-
const calculatedPrice = CalcDiscPrice(batch.Price, discPerc, markUp);
|
|
113
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(batch.Price, discPerc, markUp);
|
|
105
114
|
batch.Price = ApplyRounding(calculatedPrice, priceList);
|
|
106
115
|
if (includeMargin) {
|
|
107
|
-
batch.Margin = GetMarginValue(batch.Price, batch.Cost);
|
|
116
|
+
batch.Margin = (0, math_operations_1.GetMarginValue)(batch.Price, batch.Cost);
|
|
108
117
|
}
|
|
109
118
|
}
|
|
110
119
|
}
|
|
@@ -112,22 +121,22 @@ function CalculatePriceBasedOnPriceList(item, priceList, includeMargin) {
|
|
|
112
121
|
else if (priceList.BasedOn == "PC") {
|
|
113
122
|
if (item.Track == 'TR' || item.Track == 'SN') {
|
|
114
123
|
item.Sale["MRP"] = item.Sale.Price;
|
|
115
|
-
if ((0,
|
|
116
|
-
const calculatedPrice = CalcDiscPrice(item.Pur.Cost, discPerc, markUp);
|
|
124
|
+
if ((0, util_1.IsNotNull)(item.Pur) && (0, util_1.IsNotNull)(item.Pur.Cost)) {
|
|
125
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(item.Pur.Cost, discPerc, markUp);
|
|
117
126
|
item.Sale.Price = ApplyRounding(calculatedPrice, priceList);
|
|
118
127
|
if (includeMargin) {
|
|
119
|
-
item.Margin = GetMarginValue(item.Sale.Price, item.Pur.Cost);
|
|
128
|
+
item.Margin = (0, math_operations_1.GetMarginValue)(item.Sale.Price, item.Pur.Cost);
|
|
120
129
|
}
|
|
121
130
|
}
|
|
122
131
|
}
|
|
123
132
|
else if (item.Track == 'BN') {
|
|
124
133
|
for (let batch of item.Batches) {
|
|
125
134
|
batch.MRP = batch.Price;
|
|
126
|
-
if ((0,
|
|
127
|
-
const calculatedPrice = CalcDiscPrice(batch.Cost, discPerc, markUp);
|
|
135
|
+
if ((0, util_1.IsNotNull)(batch.Cost)) {
|
|
136
|
+
const calculatedPrice = (0, math_operations_1.CalcDiscPrice)(batch.Cost, discPerc, markUp);
|
|
128
137
|
batch.Price = ApplyRounding(calculatedPrice, priceList);
|
|
129
138
|
if (includeMargin) {
|
|
130
|
-
batch.Margin = GetMarginValue(batch.Price, batch.Cost);
|
|
139
|
+
batch.Margin = (0, math_operations_1.GetMarginValue)(batch.Price, batch.Cost);
|
|
131
140
|
}
|
|
132
141
|
}
|
|
133
142
|
}
|
|
@@ -152,7 +161,7 @@ function ApplyRounding(price, priceList) {
|
|
|
152
161
|
case "0.49":
|
|
153
162
|
return Math.floor(price) + 0.49;
|
|
154
163
|
case "Dec":
|
|
155
|
-
if ((0,
|
|
164
|
+
if ((0, util_1.IsNotNull)(priceList.Deci)) {
|
|
156
165
|
const factor = Math.pow(10, priceList.Deci);
|
|
157
166
|
return Math.round(price * factor) / factor;
|
|
158
167
|
}
|
|
@@ -161,18 +170,3 @@ function ApplyRounding(price, priceList) {
|
|
|
161
170
|
return price;
|
|
162
171
|
}
|
|
163
172
|
}
|
|
164
|
-
function CalcDiscPrice(price, disc, markUp = false) {
|
|
165
|
-
let PriceValue = 0;
|
|
166
|
-
if (markUp) {
|
|
167
|
-
PriceValue = (0, aggregation_1.addition)(price, (0, aggregation_1.division)((0, aggregation_1.multiply)(price, disc), 100));
|
|
168
|
-
}
|
|
169
|
-
else {
|
|
170
|
-
PriceValue = (0, aggregation_1.subtraction)(price, (0, aggregation_1.division)((0, aggregation_1.multiply)(price, disc), 100));
|
|
171
|
-
}
|
|
172
|
-
return PriceValue;
|
|
173
|
-
}
|
|
174
|
-
function GetMarginValue(price, cost) {
|
|
175
|
-
let Margin = 0;
|
|
176
|
-
Margin = (0, aggregation_1.multiply)((0, aggregation_1.division)((0, aggregation_1.subtraction)(price, cost), price), 100);
|
|
177
|
-
return Margin;
|
|
178
|
-
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare class ItemWiseMODetailsXlsxFileService {
|
|
2
|
+
static wb: any;
|
|
3
|
+
static Row: any;
|
|
4
|
+
static MergeArray: any[];
|
|
5
|
+
static range: {
|
|
6
|
+
s: {
|
|
7
|
+
c: number;
|
|
8
|
+
r: number;
|
|
9
|
+
};
|
|
10
|
+
e: {
|
|
11
|
+
c: number;
|
|
12
|
+
r: number;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
static ws: any;
|
|
16
|
+
static GetItemWiseMODetailsExcelData(MainData: any, searchValue: any, HeaderName: any): any;
|
|
17
|
+
static setHeadingInCell(HeaderName: any, searchValue: any): void;
|
|
18
|
+
static setInvoiceDetailsInCell(MainData: any): void;
|
|
19
|
+
static SetInvoiceDataInExcel(InvoiceInfo: any): void;
|
|
20
|
+
static ConvertToString(Text: any, IsString: any): any;
|
|
21
|
+
static SetDataInCell(Data: any, ColRange: number, RowNum: any): void;
|
|
22
|
+
static getcelltype(cell: any): any;
|
|
23
|
+
}
|
|
@@ -25,8 +25,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.ItemWiseMODetailsXlsxFileService = void 0;
|
|
27
27
|
const XLSX = __importStar(require("xlsx"));
|
|
28
|
-
const
|
|
29
|
-
const
|
|
28
|
+
const tr_utils_1 = require("../../../../utils/tr-utils");
|
|
29
|
+
const my_date_1 = require("../../../../utils/my-date");
|
|
30
30
|
class ItemWiseMODetailsXlsxFileService {
|
|
31
31
|
static GetItemWiseMODetailsExcelData(MainData, searchValue, HeaderName) {
|
|
32
32
|
this.wb = {};
|
|
@@ -42,7 +42,7 @@ class ItemWiseMODetailsXlsxFileService {
|
|
|
42
42
|
// MainData = this.GetTotals(MainData);
|
|
43
43
|
let showSearch = [];
|
|
44
44
|
for (const key in searchValue) {
|
|
45
|
-
if (!
|
|
45
|
+
if (!tr_utils_1.TrUtils.IsNull(searchValue[key]) && key !== 'Date' && key !== 'DescCntrlId') {
|
|
46
46
|
showSearch.push([{
|
|
47
47
|
text: (key === 'StDate') ? 'Start Date' : (key === 'EnDate') ? 'End Date' : (key === 'DescCntrl') ? 'Item' : key,
|
|
48
48
|
ColRange: 1,
|
|
@@ -256,7 +256,7 @@ class ItemWiseMODetailsXlsxFileService {
|
|
|
256
256
|
}
|
|
257
257
|
}
|
|
258
258
|
if (typeof Text === 'number') {
|
|
259
|
-
return Number(
|
|
259
|
+
return Number(tr_utils_1.TrUtils.FixedTo(Text));
|
|
260
260
|
}
|
|
261
261
|
else {
|
|
262
262
|
return Text;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare class ItemWiseMOSummaryXlsxFileService {
|
|
2
|
+
static wb: any;
|
|
3
|
+
static Row: any;
|
|
4
|
+
static MergeArray: any[];
|
|
5
|
+
static range: {
|
|
6
|
+
s: {
|
|
7
|
+
c: number;
|
|
8
|
+
r: number;
|
|
9
|
+
};
|
|
10
|
+
e: {
|
|
11
|
+
c: number;
|
|
12
|
+
r: number;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
static ws: any;
|
|
16
|
+
static GetItemWiseMOSummaryExcelData(MainData: any, searchValue: any, HeaderName: any): any;
|
|
17
|
+
static setHeadingInCell(HeaderName: any, searchValue: any): void;
|
|
18
|
+
static setInvoiceDetailsInCell(MainData: any): void;
|
|
19
|
+
static SetInvoiceDataInExcel(InvoiceInfo: any): void;
|
|
20
|
+
static ConvertToString(Text: any, IsString: any): any;
|
|
21
|
+
static SetDataInCell(Data: any, ColRange: number, RowNum: any): void;
|
|
22
|
+
static getcelltype(cell: any): any;
|
|
23
|
+
}
|
|
@@ -25,8 +25,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.ItemWiseMOSummaryXlsxFileService = void 0;
|
|
27
27
|
const XLSX = __importStar(require("xlsx"));
|
|
28
|
-
const my_date_1 = require("
|
|
29
|
-
const
|
|
28
|
+
const my_date_1 = require("../../../../utils/my-date");
|
|
29
|
+
const tr_utils_1 = require("../../../../utils/tr-utils");
|
|
30
30
|
class ItemWiseMOSummaryXlsxFileService {
|
|
31
31
|
static GetItemWiseMOSummaryExcelData(MainData, searchValue, HeaderName) {
|
|
32
32
|
this.wb = {};
|
|
@@ -42,7 +42,7 @@ class ItemWiseMOSummaryXlsxFileService {
|
|
|
42
42
|
// MainData = this.GetTotals(MainData);
|
|
43
43
|
let showSearch = [];
|
|
44
44
|
for (const key in searchValue) {
|
|
45
|
-
if (!
|
|
45
|
+
if (!tr_utils_1.TrUtils.IsNull(searchValue[key]) && key !== 'Date' && key !== 'DescCntrlId') {
|
|
46
46
|
showSearch.push([{
|
|
47
47
|
text: (key === 'StDate') ? 'Start Date' : (key === 'EnDate') ? 'End Date' : (key === 'DescCntrl') ? 'Item' : key,
|
|
48
48
|
ColRange: 1,
|
|
@@ -250,7 +250,7 @@ class ItemWiseMOSummaryXlsxFileService {
|
|
|
250
250
|
}
|
|
251
251
|
}
|
|
252
252
|
if (typeof Text === 'number') {
|
|
253
|
-
return Number(
|
|
253
|
+
return Number(tr_utils_1.TrUtils.FixedTo(Text));
|
|
254
254
|
}
|
|
255
255
|
else {
|
|
256
256
|
return Text;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
export declare class ExpiringDrugPDFService {
|
|
2
|
+
static GetPrint(ReOrderPointData: any, DatesDetails: any): any;
|
|
3
|
+
static GetDate(DatesDetails: any): string;
|
|
4
|
+
static CustomerAndVehicleDetailsAfterLine(): {
|
|
5
|
+
canvas: {
|
|
6
|
+
type: string;
|
|
7
|
+
lineColor: string;
|
|
8
|
+
x1: number;
|
|
9
|
+
y1: number;
|
|
10
|
+
x2: number;
|
|
11
|
+
y2: number;
|
|
12
|
+
lineWidth: number;
|
|
13
|
+
}[];
|
|
14
|
+
};
|
|
15
|
+
static GetSignatures(CName: any, For: any, Type: any): {
|
|
16
|
+
columns: {
|
|
17
|
+
stack: {
|
|
18
|
+
style: string;
|
|
19
|
+
text: (string | {
|
|
20
|
+
text: any;
|
|
21
|
+
})[];
|
|
22
|
+
}[];
|
|
23
|
+
}[];
|
|
24
|
+
};
|
|
25
|
+
static CompanyName(CName: any): {
|
|
26
|
+
style: string;
|
|
27
|
+
text: (string | {
|
|
28
|
+
text: any;
|
|
29
|
+
})[];
|
|
30
|
+
};
|
|
31
|
+
static GetItemsTable(Items: any): {
|
|
32
|
+
style: string;
|
|
33
|
+
marginTop: number;
|
|
34
|
+
marginBottom: number;
|
|
35
|
+
table: {
|
|
36
|
+
widths: (string | number)[];
|
|
37
|
+
headerRows: number;
|
|
38
|
+
body: any;
|
|
39
|
+
};
|
|
40
|
+
layout: {
|
|
41
|
+
hLineWidth: (i: any, node: any) => 1 | 0.5;
|
|
42
|
+
vLineWidth: (i: any, node: any) => 1 | 0.5;
|
|
43
|
+
hLineColor: (i: any, node: any) => "gray" | "lightgrey";
|
|
44
|
+
vLineColor: (i: any, node: any) => string;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
static BuildTableBodyForLaborAndParts(Items: any): any;
|
|
48
|
+
static GetHeaderNames(): any;
|
|
49
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ExpiringDrugPDFService = void 0;
|
|
4
|
-
const my_date_1 = require("
|
|
5
|
-
const
|
|
4
|
+
const my_date_1 = require("../../../../utils/my-date");
|
|
5
|
+
const tr_utils_1 = require("../../../../utils/tr-utils");
|
|
6
6
|
class ExpiringDrugPDFService {
|
|
7
7
|
static GetPrint(ReOrderPointData, DatesDetails) {
|
|
8
8
|
// console.log('ReOrderPointData', ReOrderPointData);
|
|
@@ -127,17 +127,17 @@ class ExpiringDrugPDFService {
|
|
|
127
127
|
let body = this.GetHeaderNames();
|
|
128
128
|
let Total = 0;
|
|
129
129
|
Items.forEach((item, index) => {
|
|
130
|
-
Total = Total + (
|
|
130
|
+
Total = Total + (tr_utils_1.TrUtils.SetValueToZeroIfNull(item.Batch.Qty) * tr_utils_1.TrUtils.SetValueToZeroIfNull(item.Batch.Cost));
|
|
131
131
|
let dataRow = [];
|
|
132
132
|
dataRow.push({ text: item.Name, });
|
|
133
133
|
dataRow.push({ text: item.Batch.BN, alignment: 'left', style: ['headerstyle'], });
|
|
134
134
|
dataRow.push({ text: my_date_1.MyDate.ConvertUTCDateToReadableExDateTxt(item.Batch.ExDt), alignment: 'center', style: ['headerstyle'], });
|
|
135
135
|
dataRow.push({ text: item.Batch.Qty, alignment: 'right', style: ['headerstyle'], });
|
|
136
|
-
dataRow.push({ text:
|
|
137
|
-
dataRow.push({ text:
|
|
136
|
+
dataRow.push({ text: tr_utils_1.TrUtils.FixPriceValue(item.Batch.Cost), alignment: 'right', style: ['headerstyle'], });
|
|
137
|
+
dataRow.push({ text: tr_utils_1.TrUtils.FixPriceValue(item.Batch.Qty * item.Batch.Cost), alignment: 'right', style: ['headerstyle'], });
|
|
138
138
|
body.push(dataRow);
|
|
139
139
|
});
|
|
140
|
-
let Row = [{ text: 'Total', alignment: 'right', colSpan: 5, bold: true, fontSize: 12 }, {}, {}, {}, {}, { text:
|
|
140
|
+
let Row = [{ text: 'Total', alignment: 'right', colSpan: 5, bold: true, fontSize: 12 }, {}, {}, {}, {}, { text: tr_utils_1.TrUtils.FixPriceValue(Total), fontSize: 12, alignment: 'right', bold: true }];
|
|
141
141
|
body.push(Row);
|
|
142
142
|
return body;
|
|
143
143
|
}
|