shareneus 1.4.48 → 1.4.49

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 (47) hide show
  1. package/dist/accounting/counter-sales/sales-receipt-print.service.d.ts +3 -3
  2. package/dist/accounting/counter-sales/sales-receipt-print.service.js +30 -29
  3. package/dist/accounting/credit-note/cn-print.service.d.ts +1 -2
  4. package/dist/accounting/credit-note/cn-print.service.js +10 -32
  5. package/dist/accounting/credit-note/credit-note-totals.service.d.ts +6 -6
  6. package/dist/accounting/credit-note/credit-note-totals.service.js +19 -19
  7. package/dist/accounting/debit-note/debit-note-print.service.d.ts +2 -2
  8. package/dist/accounting/debit-note/debit-note-print.service.js +15 -15
  9. package/dist/accounting/debit-note/debit-note-totals.service.d.ts +6 -6
  10. package/dist/accounting/debit-note/debit-note-totals.service.js +18 -18
  11. package/dist/accounting/invoice/hc-inv-pdf.service.d.ts +7 -7
  12. package/dist/accounting/invoice/hc-inv-pdf.service.js +36 -36
  13. package/dist/accounting/invoice/inv-pdf.service.d.ts +6 -6
  14. package/dist/accounting/invoice/inv-pdf.service.js +43 -43
  15. package/dist/accounting/invoice/inv-print.service.d.ts +3 -3
  16. package/dist/accounting/invoice/inv-print.service.js +24 -24
  17. package/dist/accounting/invoice/invoice-letterhead-pdf.service.d.ts +6 -6
  18. package/dist/accounting/invoice/invoice-letterhead-pdf.service.js +43 -43
  19. package/dist/accounting/invoice/invoice-total.service.d.ts +11 -11
  20. package/dist/accounting/invoice/invoice-total.service.js +54 -54
  21. package/dist/accounting/invoice/shared-inv-pdf.service.d.ts +6 -6
  22. package/dist/accounting/invoice/shared-inv-pdf.service.js +29 -29
  23. package/dist/appointments/appointments/appointment-total.service.d.ts +6 -6
  24. package/dist/appointments/appointments/appointment-total.service.js +28 -29
  25. package/dist/purchases/purchase-order/po-totals.service.d.ts +7 -7
  26. package/dist/purchases/purchase-order/po-totals.service.js +24 -25
  27. package/dist/purchases/purchase-order/purchase-order-print.service.js +3 -3
  28. package/dist/purchases/purchase-order/purchase-order-totals.service.d.ts +10 -10
  29. package/dist/purchases/purchase-order/purchase-order-totals.service.js +27 -27
  30. package/dist/purchases/vendor-debit-note/vendor-debit-note-print.service.d.ts +1 -2
  31. package/dist/purchases/vendor-debit-note/vendor-debit-note-print.service.js +10 -32
  32. package/dist/sales/delivery-challan/delivery-challan-print.service.d.ts +1 -2
  33. package/dist/sales/delivery-challan/delivery-challan-print.service.js +9 -32
  34. package/dist/sales/sales/sales-print.service.d.ts +2 -2
  35. package/dist/sales/sales/sales-print.service.js +17 -17
  36. package/dist/services/est.print-service.d.ts +18 -18
  37. package/dist/services/est.print-service.js +132 -132
  38. package/dist/services/ro-print-service.d.ts +6 -6
  39. package/dist/services/ro-print-service.js +39 -39
  40. package/dist/shared/shared-pdf.service.d.ts +0 -16
  41. package/dist/shared/shared-pdf.service.js +36 -34
  42. package/dist/shared/shared-print.service.js +1 -0
  43. package/dist/utils/tr-utils.d.ts +2 -3
  44. package/dist/utils/tr-utils.js +5 -5
  45. package/package.json +1 -1
  46. package/dist/shared/shared-pdfs/shared-pdf.service.d.ts +0 -926
  47. package/dist/shared/shared-pdfs/shared-pdf.service.js +0 -2608
@@ -46,7 +46,7 @@ class ROPrintService {
46
46
  argROData = this.ReverseItemsForROPrint(argROData, isReverse);
47
47
  let finalTotalsData = ro_totals_service_1.ROTotalsService.GetTotalsValue(argROData, TaxCodes, true, true, true, ROPrintData.Entity.Round);
48
48
  finalTotalsData.Settings = tr_utils_1.TrUtils.Stringify(argROData.Settings);
49
- finalTotalsData = this.GetDetailedInfoForItems(finalTotalsData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes);
49
+ finalTotalsData = this.GetDetailedInfoForItems(finalTotalsData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes, ROPrintData.Entity.DecimalsNumber);
50
50
  if (ConsolidateGST) {
51
51
  finalTotalsData.CustLaborTotalBeforeDisc = finalTotalsData.CustLaborAfterTax;
52
52
  finalTotalsData.CustPartsTotalBeforeDisc = finalTotalsData.CustPartAfterTax;
@@ -62,7 +62,7 @@ class ROPrintService {
62
62
  ROPrintData.VehMore = tr_utils_1.TrUtils.Stringify(argROData.VehMore);
63
63
  ROPrintData.SANotes = tr_utils_1.TrUtils.Stringify(argROData.SANotes);
64
64
  ROPrintData.OrdType = tr_utils_1.TrUtils.Stringify(argROData.OrdType);
65
- ROPrintData = this.GetLineTotals(ROPrintData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly);
65
+ ROPrintData = this.GetLineTotals(ROPrintData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly, ROPrintData.Entity.DecimalsNumber);
66
66
  ROPrintData.PrintInfo = this.PrepareFormatForROPrint(ROPrintData, Payee, code_enums_1.ROTypeEnum.RepairOrder);
67
67
  ROPrintData = this.CheckAndCombineDescMPNForAR(ROPrintData.Entity.MPN, ROPrintData);
68
68
  ROPrintData.Vehicle = shared_print_service_1.PrintSharedService.GetVehicleFromServiceAndFormatData(OriginalVehicleData);
@@ -387,12 +387,12 @@ class ROPrintService {
387
387
  });
388
388
  return Colli;
389
389
  }
390
- static GetLineTotals(ROPrintData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly) {
390
+ static GetLineTotals(ROPrintData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly, DecimalsNumber) {
391
391
  ROPrintData.Ops.forEach((Labor) => {
392
- Labor.LineTotal = this.GetLaborLineTotal(Labor, IncludeGST, AsCustomerOnly, AsInsuranceOnly);
392
+ Labor.LineTotal = this.GetLaborLineTotal(Labor, IncludeGST, AsCustomerOnly, AsInsuranceOnly, DecimalsNumber);
393
393
  });
394
394
  ROPrintData.Parts.forEach((Part) => {
395
- Part.LineTotal = this.GetPartLineTotal(Part, IncludeGST, AsCustomerOnly, AsInsuranceOnly);
395
+ Part.LineTotal = this.GetPartLineTotal(Part, IncludeGST, AsCustomerOnly, AsInsuranceOnly, DecimalsNumber);
396
396
  });
397
397
  ROPrintData.Colli.forEach((Collision) => {
398
398
  let LineTotal = 0;
@@ -408,7 +408,7 @@ class ROPrintService {
408
408
  if (!tr_utils_1.TrUtils.IsNull(Collision.DtngData)) {
409
409
  LineTotal = (0, aggregation_1.addition)(LineTotal, this.GetCollisionLaborLineTotal(Collision.DtngData, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly));
410
410
  }
411
- Collision.LineTotal = tr_utils_1.TrUtils.FixPriceValue(LineTotal);
411
+ Collision.LineTotal = tr_utils_1.TrUtils.FixPriceValue(LineTotal, DecimalsNumber);
412
412
  });
413
413
  return ROPrintData;
414
414
  }
@@ -468,7 +468,7 @@ class ROPrintService {
468
468
  }
469
469
  return Number(LineTotal);
470
470
  }
471
- static GetLaborLineTotal(LaborData, IncludeGST, AsCustomerOnly, AsInsuranceOnly) {
471
+ static GetLaborLineTotal(LaborData, IncludeGST, AsCustomerOnly, AsInsuranceOnly, DecimalsNumber) {
472
472
  let LineTotal = 0;
473
473
  if (AsCustomerOnly) {
474
474
  if (IncludeGST) {
@@ -494,9 +494,9 @@ class ROPrintService {
494
494
  LineTotal = (0, aggregation_1.addition)(LaborData.InsAfterLaborDisc, LaborData.CustAfterLaborDisc);
495
495
  }
496
496
  }
497
- return tr_utils_1.TrUtils.FixPriceValue(LineTotal);
497
+ return tr_utils_1.TrUtils.FixPriceValue(LineTotal, DecimalsNumber);
498
498
  }
499
- static GetPartLineTotal(PartData, IncludeGST, AsCustomerOnly, AsInsuranceOnly) {
499
+ static GetPartLineTotal(PartData, IncludeGST, AsCustomerOnly, AsInsuranceOnly, DecimalsNumber) {
500
500
  let LineTotal = 0;
501
501
  if (AsCustomerOnly) {
502
502
  if (IncludeGST) {
@@ -522,7 +522,7 @@ class ROPrintService {
522
522
  LineTotal = (0, aggregation_1.addition)(PartData.InsAfterPartDisc, PartData.CustAfterPartDisc);
523
523
  }
524
524
  }
525
- return tr_utils_1.TrUtils.FixPriceValue(LineTotal);
525
+ return tr_utils_1.TrUtils.FixPriceValue(LineTotal, DecimalsNumber);
526
526
  }
527
527
  static ReverseItemsForROPrint(argROData, isReverse) {
528
528
  if (isReverse) {
@@ -567,9 +567,9 @@ class ROPrintService {
567
567
  argROData.Parts = ReversedParts;
568
568
  return argROData;
569
569
  }
570
- static GetDetailedInfoForItems(ROTotalsData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes) {
571
- ROTotalsData.Ops = this.GetLaborPrintInfo(ROTotalsData.Ops, ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes);
572
- ROTotalsData.Parts = this.GetItemsPrintInfo(tr_utils_1.TrUtils.Stringify(ROTotalsData.Parts), ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes);
570
+ static GetDetailedInfoForItems(ROTotalsData, IncludeGST, ConsolidateGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes, DecimalsNumber) {
571
+ ROTotalsData.Ops = this.GetLaborPrintInfo(ROTotalsData.Ops, ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes, DecimalsNumber);
572
+ ROTotalsData.Parts = this.GetItemsPrintInfo(tr_utils_1.TrUtils.Stringify(ROTotalsData.Parts), ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes, DecimalsNumber);
573
573
  if (IncludeGST && !ConsolidateGST) {
574
574
  ROTotalsData.ShowDetailedLaborTaxInfo = this.CheckLaborTaxItemIndex(ROTotalsData.Ops) !== -1;
575
575
  ROTotalsData.ShowDetailedPartTaxInfo = this.CheckPartTaxItemIndex(ROTotalsData.Parts) !== -1;
@@ -580,23 +580,23 @@ class ROPrintService {
580
580
  }
581
581
  return ROTotalsData;
582
582
  }
583
- static GetLaborPrintInfo(LaborList, ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes) {
583
+ static GetLaborPrintInfo(LaborList, ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes, DecimalsNumber) {
584
584
  LaborList.forEach((Labor) => {
585
585
  Labor.HSN = Labor.SAC;
586
586
  if (AsCustomerOnly) {
587
587
  if (IncludeGST) {
588
588
  if (ConsolidateGST) {
589
- Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.CustAfterTax);
589
+ Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.CustAfterTax, DecimalsNumber);
590
590
  }
591
591
  else {
592
- Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.Pr);
592
+ Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.Pr, DecimalsNumber);
593
593
  }
594
- Labor.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.CCGST);
595
- Labor.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.CSGST);
596
- Labor.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.CIGST);
594
+ Labor.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.CCGST, DecimalsNumber);
595
+ Labor.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.CSGST, DecimalsNumber);
596
+ Labor.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.CIGST, DecimalsNumber);
597
597
  }
598
598
  else {
599
- Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.Pr);
599
+ Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.Pr, DecimalsNumber);
600
600
  Labor.CGSTAmt = 0;
601
601
  Labor.SGSTAmt = 0;
602
602
  Labor.IGSTAmt = 0;
@@ -605,17 +605,17 @@ class ROPrintService {
605
605
  else if (AsInsuranceOnly) {
606
606
  if (IncludeGST) {
607
607
  if (ConsolidateGST) {
608
- Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.InsAfterTax);
608
+ Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.InsAfterTax, DecimalsNumber);
609
609
  }
610
610
  else {
611
- Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.AssPr);
611
+ Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.AssPr, DecimalsNumber);
612
612
  }
613
- Labor.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.ACGST);
614
- Labor.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.ASGST);
615
- Labor.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.AIGST);
613
+ Labor.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.ACGST, DecimalsNumber);
614
+ Labor.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.ASGST, DecimalsNumber);
615
+ Labor.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Labor.AIGST, DecimalsNumber);
616
616
  }
617
617
  else {
618
- Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.AssPr);
618
+ Labor.UnPr = tr_utils_1.TrUtils.FixedTo(Labor.AssPr, DecimalsNumber);
619
619
  Labor.CGSTAmt = 0;
620
620
  Labor.SGSTAmt = 0;
621
621
  Labor.IGSTAmt = 0;
@@ -627,22 +627,22 @@ class ROPrintService {
627
627
  });
628
628
  return LaborList;
629
629
  }
630
- static GetItemsPrintInfo(Items, ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes) {
630
+ static GetItemsPrintInfo(Items, ConsolidateGST, IncludeGST, AsCustomerOnly, AsInsuranceOnly, TaxCodes, DecimalsNumber) {
631
631
  Items.forEach((Item) => {
632
632
  if (AsCustomerOnly) {
633
633
  if (IncludeGST) {
634
634
  if (ConsolidateGST) {
635
- Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.CustAfterTaxPerItem);
635
+ Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.CustAfterTaxPerItem, DecimalsNumber);
636
636
  }
637
637
  else {
638
- Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.UnPr);
638
+ Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.UnPr, DecimalsNumber);
639
639
  }
640
- Item.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.CCGST);
641
- Item.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.CSGST);
642
- Item.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.CIGST);
640
+ Item.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.CCGST, DecimalsNumber);
641
+ Item.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.CSGST, DecimalsNumber);
642
+ Item.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.CIGST, DecimalsNumber);
643
643
  }
644
644
  else {
645
- Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.UnPr);
645
+ Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.UnPr, DecimalsNumber);
646
646
  Item.CGSTAmt = 0;
647
647
  Item.SGSTAmt = 0;
648
648
  Item.IGSTAmt = 0;
@@ -651,17 +651,17 @@ class ROPrintService {
651
651
  else if (AsInsuranceOnly) {
652
652
  if (IncludeGST) {
653
653
  if (ConsolidateGST) {
654
- Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.InsAfterTaxPerItem);
654
+ Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.InsAfterTaxPerItem, DecimalsNumber);
655
655
  }
656
656
  else {
657
- Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.AssPr);
657
+ Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.AssPr, DecimalsNumber);
658
658
  }
659
- Item.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.ACGST);
660
- Item.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.ASGST);
661
- Item.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.AIGST);
659
+ Item.CGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.ACGST, DecimalsNumber);
660
+ Item.SGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.ASGST, DecimalsNumber);
661
+ Item.IGSTAmt = tr_utils_1.TrUtils.FixedTo(Item.AIGST, DecimalsNumber);
662
662
  }
663
663
  else {
664
- Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.AssPr);
664
+ Item.UnPr = tr_utils_1.TrUtils.FixedTo(Item.AssPr, DecimalsNumber);
665
665
  Item.CGSTAmt = 0;
666
666
  Item.SGSTAmt = 0;
667
667
  Item.IGSTAmt = 0;
@@ -465,22 +465,6 @@ export declare class SharedPDFService {
465
465
  }[];
466
466
  static CreateHSNTaxTable1(PartsTaxInfo: any, ShowAccParts: any, ShowIGST: any, ShowTaxColumn: any): any;
467
467
  static CreateHSNTaxTable(PartsTaxInfo: any, ShowAccParts: any, ShowIGST: any, ShowTaxColumn: any): any;
468
- static GetHCFinalTotalDetails(RecordData: any, BasicLaborTotal: any, OverAllMainLaborDiscount: any, LCGST: any, LSGST: any, LIGST: any, PIGST: any, ShowIGST: any, ShowTaxColumn: any, BasicPartsTotal: any, OverAllMainPartsDiscount: any, PCGST: any, PSGST: any, PartsTaxInfo: any, ShowAccParts: any, LaborAfterGST: any, PartsAfterGST: any, OverAllRecordDiscount: any, For: any, OverAllRecordTotal: any, Rounded: any, GrandTotal: any, ShowDetailedLaborTaxInfo: any, ShowDetailedPartTaxInfo: any, istaxable: boolean, LaborTotalTax: any, PartTotalTax: any, Consolidate: boolean, From: string, Adj: any, STotal: any, moreDiscDetails: boolean): {
469
- columns: ({
470
- style: string[];
471
- lineHeight: number;
472
- marginBottom: number;
473
- width: string;
474
- table: {
475
- body: any;
476
- };
477
- layout: string;
478
- } | {
479
- text: string;
480
- width: number;
481
- })[];
482
- marginLeft: number;
483
- };
484
468
  static GetFinalTotalDetails1(RecordData: any, BasicLaborTotal: any, OverAllMainLaborDiscount: any, LCGST: any, LSGST: any, LIGST: any, PIGST: any, ShowIGST: any, ShowTaxColumn: any, BasicPartsTotal: any, OverAllMainPartsDiscount: any, PCGST: any, PSGST: any, PartsTaxInfo: any, ShowAccParts: any, LaborAfterGST: any, PartsAfterGST: any, OverAllRecordDiscount: any, For: any, OverAllRecordTotal: any, Rounded: any, GrandTotal: any, ShowDetailedLaborTaxInfo: any, ShowDetailedPartTaxInfo: any, istaxable: boolean, LaborTotalTax: any, PartTotalTax: any, Consolidate: boolean, From: string, Adj: any, CustLaborTaxGroupDataByPerc: any, STotal: any, isAuto: boolean, moreDiscDetails: boolean): {
485
469
  columns: ({
486
470
  style: string[];
@@ -1536,40 +1536,42 @@ class SharedPDFService {
1536
1536
  return [{}];
1537
1537
  }
1538
1538
  }
1539
- static GetHCFinalTotalDetails(RecordData, BasicLaborTotal, OverAllMainLaborDiscount, LCGST, LSGST, LIGST, PIGST, ShowIGST, ShowTaxColumn, BasicPartsTotal, OverAllMainPartsDiscount, PCGST, PSGST, PartsTaxInfo, ShowAccParts, LaborAfterGST, PartsAfterGST, OverAllRecordDiscount, For, OverAllRecordTotal, Rounded, GrandTotal, ShowDetailedLaborTaxInfo, ShowDetailedPartTaxInfo, istaxable, LaborTotalTax, PartTotalTax, Consolidate, From, Adj, STotal, moreDiscDetails) {
1540
- let totalDisc;
1541
- let totalTax;
1542
- if (!Consolidate) {
1543
- totalTax = tr_utils_1.TrUtils.FixPriceValue(Number(LaborTotalTax) + Number(PartTotalTax));
1544
- if (istaxable) {
1545
- totalDisc = tr_utils_1.TrUtils.FixPriceValue(Number(OverAllMainLaborDiscount) + Number(OverAllMainPartsDiscount));
1546
- }
1547
- else {
1548
- totalDisc = tr_utils_1.TrUtils.FixPriceValue(Number(OverAllMainLaborDiscount) + Number(OverAllMainPartsDiscount) + Number(OverAllRecordDiscount));
1549
- }
1550
- }
1551
- return {
1552
- columns: [
1553
- // this.GetTaxOnLabor(BasicLaborTotal, OverAllMainLaborDiscount, LCGST,
1554
- // LSGST, LIGST, ShowIGST, ShowTaxColumn, ShowDetailedLaborTaxInfo),
1555
- { text: '', width: 225 },
1556
- // {
1557
- // stack: [
1558
- // this.GetTaxOnParts(BasicPartsTotal, OverAllMainPartsDiscount, PCGST,
1559
- // PSGST, ShowAccParts, PIGST, ShowIGST, ShowTaxColumn, ShowDetailedPartTaxInfo, From),
1560
- // this.PartsTaxAmounts(PartsTaxInfo, ShowAccParts, ShowIGST,
1561
- // ShowTaxColumn)
1562
- // ]
1563
- // },
1564
- { text: '', width: 230 },
1565
- // this.GrandTotal(LaborAfterGST, PartsAfterGST, totalDisc, For, OverAllRecordTotal, Rounded, GrandTotal)
1566
- this.GrandTotal(RecordData, BasicLaborTotal, BasicPartsTotal, totalDisc, totalTax, For, OverAllRecordTotal, Rounded, GrandTotal, Adj, Consolidate, STotal, moreDiscDetails)
1567
- ]
1568
- // columnGap: 40
1569
- ,
1570
- marginLeft: 10
1571
- };
1572
- }
1539
+ // static GetHCFinalTotalDetails(RecordData: any, BasicLaborTotal: any, OverAllMainLaborDiscount: any, LCGST: any, LSGST: any, LIGST: any, PIGST: any, ShowIGST: any, ShowTaxColumn: any,
1540
+ // BasicPartsTotal: any, OverAllMainPartsDiscount: any, PCGST: any, PSGST: any, PartsTaxInfo: any,
1541
+ // ShowAccParts: any, LaborAfterGST: any, PartsAfterGST: any, OverAllRecordDiscount: any, For: any,
1542
+ // OverAllRecordTotal: any, Rounded: any, GrandTotal: any, ShowDetailedLaborTaxInfo: any,
1543
+ // ShowDetailedPartTaxInfo: any, istaxable: boolean, LaborTotalTax: any, PartTotalTax: any, Consolidate: boolean, From: string, Adj: any, STotal: any, moreDiscDetails: boolean) {
1544
+ // let totalDisc: any;
1545
+ // let totalTax: any;
1546
+ // if (!Consolidate) {
1547
+ // totalTax = TrUtils.FixPriceValue(Number(LaborTotalTax) + Number(PartTotalTax));
1548
+ // if (istaxable) {
1549
+ // totalDisc = TrUtils.FixPriceValue(Number(OverAllMainLaborDiscount) + Number(OverAllMainPartsDiscount));
1550
+ // } else {
1551
+ // totalDisc = TrUtils.FixPriceValue(Number(OverAllMainLaborDiscount) + Number(OverAllMainPartsDiscount) + Number(OverAllRecordDiscount));
1552
+ // }
1553
+ // }
1554
+ // return {
1555
+ // columns: [
1556
+ // // this.GetTaxOnLabor(BasicLaborTotal, OverAllMainLaborDiscount, LCGST,
1557
+ // // LSGST, LIGST, ShowIGST, ShowTaxColumn, ShowDetailedLaborTaxInfo),
1558
+ // { text: '', width: 225 },
1559
+ // // {
1560
+ // // stack: [
1561
+ // // this.GetTaxOnParts(BasicPartsTotal, OverAllMainPartsDiscount, PCGST,
1562
+ // // PSGST, ShowAccParts, PIGST, ShowIGST, ShowTaxColumn, ShowDetailedPartTaxInfo, From),
1563
+ // // this.PartsTaxAmounts(PartsTaxInfo, ShowAccParts, ShowIGST,
1564
+ // // ShowTaxColumn)
1565
+ // // ]
1566
+ // // },
1567
+ // { text: '', width: 230 },
1568
+ // // this.GrandTotal(LaborAfterGST, PartsAfterGST, totalDisc, For, OverAllRecordTotal, Rounded, GrandTotal)
1569
+ // this.GrandTotal(RecordData, BasicLaborTotal, BasicPartsTotal, totalDisc, totalTax, For, OverAllRecordTotal, Rounded, GrandTotal, Adj, Consolidate, STotal, moreDiscDetails)
1570
+ // ]
1571
+ // // columnGap: 40
1572
+ // , marginLeft: 10
1573
+ // };
1574
+ // }
1573
1575
  static GetFinalTotalDetails1(RecordData, BasicLaborTotal, OverAllMainLaborDiscount, LCGST, LSGST, LIGST, PIGST, ShowIGST, ShowTaxColumn, BasicPartsTotal, OverAllMainPartsDiscount, PCGST, PSGST, PartsTaxInfo, ShowAccParts, LaborAfterGST, PartsAfterGST, OverAllRecordDiscount, For, OverAllRecordTotal, Rounded, GrandTotal, ShowDetailedLaborTaxInfo, ShowDetailedPartTaxInfo, istaxable, LaborTotalTax, PartTotalTax, Consolidate, From, Adj, CustLaborTaxGroupDataByPerc, STotal, isAuto, moreDiscDetails) {
1574
1576
  let totalDisc;
1575
1577
  let totalTax;
@@ -22,6 +22,7 @@ class PrintSharedService {
22
22
  // MyDate.UserTimeZone = EntityData.User.TZ;
23
23
  let Entity = {};
24
24
  Entity.User = EntityData.User;
25
+ Entity.DecimalsNumber = 2;
25
26
  if (tr_utils_1.TrUtils.IsNull(tempEntity.Settings.Common)) {
26
27
  tempEntity.Settings.Common = {};
27
28
  }
@@ -1,5 +1,4 @@
1
1
  export declare class TrUtils {
2
- static DecimalsNumber: number;
3
2
  static IsNull(Value: any): boolean;
4
3
  static IsEmpty(Value: any): boolean;
5
4
  static IsZero(Value: any): boolean;
@@ -7,8 +6,8 @@ export declare class TrUtils {
7
6
  static Stringify(RecordData: any): any;
8
7
  static ConcatObjects(obj1: any, obj2: any): any;
9
8
  static ConvertPercToVal(Discount: any, Total: any): number | null;
10
- static FixedTo(value: any): number;
11
- static FixPriceValue(Value: any): string;
9
+ static FixedTo(value: any, DecimalsNumber?: number): number;
10
+ static FixPriceValue(Value: any, DecimalsNumber?: number): string;
12
11
  static SetValueToZeroIfNull(Value: any): any;
13
12
  static SetPercToStringIfNull(Value: any): any;
14
13
  static SetPercToTrueIfNull(Value: any): any;
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.TrUtils = void 0;
4
4
  class TrUtils {
5
+ // static DecimalsNumber:number=2;
5
6
  static IsNull(Value) {
6
7
  return Value === null || typeof Value === 'undefined';
7
8
  }
@@ -46,22 +47,22 @@ class TrUtils {
46
47
  return value;
47
48
  }
48
49
  }
49
- static FixedTo(value) {
50
+ static FixedTo(value, DecimalsNumber = 2) {
50
51
  if (this.IsNull(value)) {
51
52
  value = 0;
52
53
  }
53
54
  value = Number(value);
54
- let Result = value.toFixed(this.DecimalsNumber);
55
+ let Result = value.toFixed(DecimalsNumber);
55
56
  return Number(Result);
56
57
  }
57
- static FixPriceValue(Value) {
58
+ static FixPriceValue(Value, DecimalsNumber = 2) {
58
59
  if (this.IsNull(Value)) {
59
60
  Value = 0;
60
61
  }
61
62
  if (typeof Value === 'string') {
62
63
  Value = Number(Value);
63
64
  }
64
- let Result = Value.toFixed(this.DecimalsNumber);
65
+ let Result = Value.toFixed(DecimalsNumber);
65
66
  return Result;
66
67
  }
67
68
  static SetValueToZeroIfNull(Value) {
@@ -90,4 +91,3 @@ class TrUtils {
90
91
  }
91
92
  }
92
93
  exports.TrUtils = TrUtils;
93
- TrUtils.DecimalsNumber = 2;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shareneus",
3
- "version": "1.4.48",
3
+ "version": "1.4.49",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",