shareneus 1.4.48 → 1.4.50

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 (109) 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/reports/excel/analysis-excel.service.d.ts +3 -3
  22. package/dist/accounting/invoice/reports/excel/analysis-excel.service.js +8 -7
  23. package/dist/accounting/invoice/reports/excel/category-wise-item-excel.service.d.ts +4 -4
  24. package/dist/accounting/invoice/reports/excel/category-wise-item-excel.service.js +14 -14
  25. package/dist/accounting/invoice/reports/excel/cust-wise-sales-details.d.ts +4 -4
  26. package/dist/accounting/invoice/reports/excel/cust-wise-sales-details.js +8 -8
  27. package/dist/accounting/invoice/reports/excel/cust-wise-sales-summary-excel.service.d.ts +4 -4
  28. package/dist/accounting/invoice/reports/excel/cust-wise-sales-summary-excel.service.js +8 -8
  29. package/dist/accounting/invoice/reports/excel/invoice-wise-excel.service.d.ts +4 -4
  30. package/dist/accounting/invoice/reports/excel/invoice-wise-excel.service.js +8 -8
  31. package/dist/accounting/invoice/reports/excel/item-wise-doctor-sale-excel.service.d.ts +4 -4
  32. package/dist/accounting/invoice/reports/excel/item-wise-doctor-sale-excel.service.js +10 -10
  33. package/dist/accounting/invoice/reports/excel/items-wise-sales-excel.service.d.ts +4 -4
  34. package/dist/accounting/invoice/reports/excel/items-wise-sales-excel.service.js +14 -13
  35. package/dist/accounting/invoice/reports/excel/manf-wise-sales-excel.service.d.ts +4 -4
  36. package/dist/accounting/invoice/reports/excel/manf-wise-sales-excel.service.js +8 -8
  37. package/dist/accounting/invoice/reports/excel/operator-wise-details.d.ts +4 -4
  38. package/dist/accounting/invoice/reports/excel/operator-wise-details.js +8 -8
  39. package/dist/accounting/invoice/reports/excel/operator-wise-summary.d.ts +4 -4
  40. package/dist/accounting/invoice/reports/excel/operator-wise-summary.js +8 -8
  41. package/dist/accounting/invoice/shared-inv-pdf.service.d.ts +6 -6
  42. package/dist/accounting/invoice/shared-inv-pdf.service.js +29 -29
  43. package/dist/appointments/appointments/appointment-total.service.d.ts +6 -6
  44. package/dist/appointments/appointments/appointment-total.service.js +28 -29
  45. package/dist/gst/excel/GSTR-RO-excel.service.d.ts +4 -4
  46. package/dist/gst/excel/GSTR-RO-excel.service.js +8 -8
  47. package/dist/gst/excel/GSTR1-excel.service.d.ts +4 -4
  48. package/dist/gst/excel/GSTR1-excel.service.js +10 -10
  49. package/dist/gst/excel/GSTR2-excel.service.d.ts +4 -4
  50. package/dist/gst/excel/GSTR2-excel.service.js +9 -9
  51. package/dist/gst/excel/tally-sales-import.service.d.ts +4 -4
  52. package/dist/gst/excel/tally-sales-import.service.js +8 -8
  53. package/dist/inventory/items/issue-parts-pdf.service.d.ts +6 -6
  54. package/dist/inventory/items/issue-parts-pdf.service.js +32 -32
  55. package/dist/inventory/items/reports/excel/expiring-drugs-excel.service.d.ts +4 -4
  56. package/dist/inventory/items/reports/excel/expiring-drugs-excel.service.js +11 -10
  57. package/dist/inventory/items/reports/excel/item-wise-mout-details.d.ts +4 -4
  58. package/dist/inventory/items/reports/excel/item-wise-mout-details.js +8 -8
  59. package/dist/inventory/items/reports/excel/item-wise-mout-summary.d.ts +4 -4
  60. package/dist/inventory/items/reports/excel/item-wise-mout-summary.js +8 -8
  61. package/dist/inventory/items/reports/excel/spares-issue-excel.service.d.ts +4 -4
  62. package/dist/inventory/items/reports/excel/spares-issue-excel.service.js +12 -12
  63. package/dist/inventory/items/reports/excel/stock-excel.service.d.ts +4 -4
  64. package/dist/inventory/items/reports/excel/stock-excel.service.js +8 -8
  65. package/dist/purchases/payment-made/reports/excel/payments-made-excel.service.d.ts +4 -4
  66. package/dist/purchases/payment-made/reports/excel/payments-made-excel.service.js +9 -9
  67. package/dist/purchases/payment-made/reports/excel/ven-balance-excel.service.d.ts +6 -6
  68. package/dist/purchases/payment-made/reports/excel/ven-balance-excel.service.js +14 -14
  69. package/dist/purchases/purchase-order/po-totals.service.d.ts +7 -7
  70. package/dist/purchases/purchase-order/po-totals.service.js +24 -25
  71. package/dist/purchases/purchase-order/purchase-order-print.service.js +3 -3
  72. package/dist/purchases/purchase-order/purchase-order-totals.service.d.ts +10 -10
  73. package/dist/purchases/purchase-order/purchase-order-totals.service.js +27 -27
  74. package/dist/purchases/vendor-credit-note/vendor-credit-note-print.service.d.ts +1 -1
  75. package/dist/purchases/vendor-credit-note/vendor-credit-note-print.service.js +20 -20
  76. package/dist/purchases/vendor-credit-note/vendor-credit-note-totals.service.d.ts +8 -8
  77. package/dist/purchases/vendor-credit-note/vendor-credit-note-totals.service.js +31 -32
  78. package/dist/purchases/vendor-debit-note/vendor-debit-note-print.service.d.ts +1 -2
  79. package/dist/purchases/vendor-debit-note/vendor-debit-note-print.service.js +10 -32
  80. package/dist/purchases/vendor-debit-note/vendor-debit-note-totals.service.d.ts +6 -6
  81. package/dist/purchases/vendor-debit-note/vendor-debit-note-totals.service.js +19 -19
  82. package/dist/sales/delivery-challan/delivery-challan-print.service.d.ts +1 -2
  83. package/dist/sales/delivery-challan/delivery-challan-print.service.js +10 -33
  84. package/dist/sales/delivery-challan/delivery-challan-totals.d.ts +6 -6
  85. package/dist/sales/delivery-challan/delivery-challan-totals.js +20 -20
  86. package/dist/sales/sales/sales-print.service.d.ts +2 -2
  87. package/dist/sales/sales/sales-print.service.js +18 -18
  88. package/dist/sales/sales/sales-totals.service.d.ts +6 -6
  89. package/dist/sales/sales/sales-totals.service.js +19 -19
  90. package/dist/services/est.print-service.d.ts +18 -18
  91. package/dist/services/est.print-service.js +133 -133
  92. package/dist/services/reports/excel/insurance-expire-excel.service.d.ts +4 -4
  93. package/dist/services/reports/excel/insurance-expire-excel.service.js +8 -8
  94. package/dist/services/reports/excel/next-service-date-excel.service.d.ts +4 -4
  95. package/dist/services/reports/excel/next-service-date-excel.service.js +8 -8
  96. package/dist/services/reports/excel/repair-orders-excel.service.d.ts +5 -5
  97. package/dist/services/reports/excel/repair-orders-excel.service.js +11 -11
  98. package/dist/services/ro-print-service.d.ts +6 -6
  99. package/dist/services/ro-print-service.js +40 -40
  100. package/dist/services/ro-totals.service.d.ts +11 -11
  101. package/dist/services/ro-totals.service.js +50 -50
  102. package/dist/shared/shared-pdf.service.d.ts +0 -16
  103. package/dist/shared/shared-pdf.service.js +36 -34
  104. package/dist/shared/shared-print.service.js +1 -0
  105. package/dist/utils/tr-utils.d.ts +2 -3
  106. package/dist/utils/tr-utils.js +7 -6
  107. package/package.json +1 -1
  108. package/dist/shared/shared-pdfs/shared-pdf.service.d.ts +0 -926
  109. package/dist/shared/shared-pdfs/shared-pdf.service.js +0 -2608
@@ -27,7 +27,7 @@ exports.GSTR1ExcelService = void 0;
27
27
  const XLSX = __importStar(require("xlsx"));
28
28
  const tr_utils_1 = require("../../utils/tr-utils");
29
29
  class GSTR1ExcelService {
30
- static GetGSTR1ExcelData(MainData) {
30
+ static GetGSTR1ExcelData(MainData, EntitySettings) {
31
31
  this.wb = {};
32
32
  this.ws = {};
33
33
  this.Row = 0;
@@ -40,7 +40,7 @@ class GSTR1ExcelService {
40
40
  this.wb.SheetNames = [];
41
41
  MainData = this.GetTotals(MainData);
42
42
  this.setHeadingInCell();
43
- this.setInvoiceDetailsInCell(MainData);
43
+ this.setInvoiceDetailsInCell(MainData, EntitySettings.DecimalsNumber);
44
44
  this.ws['!ref'] = XLSX.utils.encode_range(this.range);
45
45
  this.ws['!merges'] = this.MergeArray;
46
46
  this.wb.SheetNames.push(ws_name);
@@ -124,12 +124,12 @@ class GSTR1ExcelService {
124
124
  });
125
125
  this.Row += 2;
126
126
  }
127
- static setInvoiceDetailsInCell(MainData) {
127
+ static setInvoiceDetailsInCell(MainData, DecimalsNumber) {
128
128
  MainData.forEach((InvoiceList) => {
129
- this.SetInvoiceDataInExcel(InvoiceList);
129
+ this.SetInvoiceDataInExcel(InvoiceList, DecimalsNumber);
130
130
  });
131
131
  }
132
- static SetInvoiceDataInExcel(InvoiceList) {
132
+ static SetInvoiceDataInExcel(InvoiceList, DecimalsNumber) {
133
133
  InvoiceList.Invoices.forEach((InvoiceInfo, index) => {
134
134
  // let InvoiceInfo = InvoiceInfoData.Inv;
135
135
  InvoiceInfo.CrDate = this.ConvertDateToReadableFormat(InvoiceInfo.CrDate);
@@ -160,7 +160,7 @@ class GSTR1ExcelService {
160
160
  ];
161
161
  let ColStart = 0;
162
162
  InvoiceData.forEach((InvData) => {
163
- InvData.text = this.ConvertToString(InvData.text, InvData.IsString);
163
+ InvData.text = this.ConvertToString(InvData.text, InvData.IsString, DecimalsNumber);
164
164
  this.SetDataInCell(InvData.text, ColStart, this.Row);
165
165
  this.MergeArray.push({ s: { r: this.Row, c: ColStart }, e: { r: this.Row, c: ColStart + InvData.ColRange - 1 } });
166
166
  ColStart += InvData.ColRange;
@@ -180,7 +180,7 @@ class GSTR1ExcelService {
180
180
  ];
181
181
  let PartColStart = TotalsColStart + 1;
182
182
  PartData.forEach((PartInfo) => {
183
- PartInfo.text = this.ConvertToString(PartInfo.text, PartInfo.IsString);
183
+ PartInfo.text = this.ConvertToString(PartInfo.text, PartInfo.IsString, DecimalsNumber);
184
184
  this.SetDataInCell(PartInfo.text, PartColStart, this.Row);
185
185
  this.MergeArray.push({ s: { r: this.Row, c: PartColStart }, e: { r: this.Row, c: PartColStart + PartInfo.ColRange - 1 } });
186
186
  PartColStart += PartInfo.ColRange;
@@ -203,7 +203,7 @@ class GSTR1ExcelService {
203
203
  ];
204
204
  let LaborColStart = TotalsColStart + 1;
205
205
  ServiceData.forEach((ServiceInfo) => {
206
- ServiceInfo.text = this.ConvertToString(ServiceInfo.text, ServiceInfo.IsString);
206
+ ServiceInfo.text = this.ConvertToString(ServiceInfo.text, ServiceInfo.IsString, DecimalsNumber);
207
207
  this.SetDataInCell(ServiceInfo.text, LaborColStart, this.Row);
208
208
  this.MergeArray.push({ s: { r: this.Row, c: LaborColStart }, e: { r: this.Row, c: LaborColStart + ServiceInfo.ColRange - 1 } });
209
209
  LaborColStart += ServiceInfo.ColRange;
@@ -215,7 +215,7 @@ class GSTR1ExcelService {
215
215
  this.Row += 1;
216
216
  });
217
217
  }
218
- static ConvertToString(Text, IsString) {
218
+ static ConvertToString(Text, IsString, DecimalsNumber) {
219
219
  if (IsString) {
220
220
  if (tr_utils_1.TrUtils.IsNull(Text)) {
221
221
  Text = '';
@@ -227,7 +227,7 @@ class GSTR1ExcelService {
227
227
  }
228
228
  }
229
229
  if (typeof (Text) === 'number') {
230
- return Number(tr_utils_1.TrUtils.FixedTo(Text));
230
+ return Number(tr_utils_1.TrUtils.FixedTo(Text, DecimalsNumber));
231
231
  }
232
232
  else {
233
233
  return Text;
@@ -4,12 +4,12 @@ export declare class GSTR2ExcelService {
4
4
  static MergeArray: any[];
5
5
  static range: any;
6
6
  static ws: any;
7
- static GetGSTR1ExcelData(MainData: any): any;
7
+ static GetGSTR1ExcelData(MainData: any, EntitySettings: any): any;
8
8
  static GetTotals(MainData: any): any;
9
9
  static setHeadingInCell(): void;
10
- static setInvoiceDetailsInCell(MainData: any): void;
11
- static SetInvoiceDataInExcel(InvoiceList: any): void;
12
- static ConvertToString(Text: any, IsString: any): any;
10
+ static setInvoiceDetailsInCell(MainData: any, DecimalsNumber: number): void;
11
+ static SetInvoiceDataInExcel(InvoiceList: any, DecimalsNumber: number): void;
12
+ static ConvertToString(Text: any, IsString: any, DecimalsNumber: number): any;
13
13
  static SetDataInCell(Data: any, ColRange: number, RowNum: any): void;
14
14
  static getcelltype(cell: any): any;
15
15
  static ConvertDateToReadableFormat(DateObject: any): any;
@@ -27,7 +27,7 @@ exports.GSTR2ExcelService = void 0;
27
27
  const XLSX = __importStar(require("xlsx"));
28
28
  const tr_utils_1 = require("../../utils/tr-utils");
29
29
  class GSTR2ExcelService {
30
- static GetGSTR1ExcelData(MainData) {
30
+ static GetGSTR1ExcelData(MainData, EntitySettings) {
31
31
  this.wb = {};
32
32
  this.ws = {};
33
33
  this.Row = 0;
@@ -40,7 +40,7 @@ class GSTR2ExcelService {
40
40
  this.wb.SheetNames = [];
41
41
  MainData = this.GetTotals(MainData);
42
42
  this.setHeadingInCell();
43
- this.setInvoiceDetailsInCell(MainData);
43
+ this.setInvoiceDetailsInCell(MainData, EntitySettings.DecimalsNumber);
44
44
  this.ws['!ref'] = XLSX.utils.encode_range(this.range);
45
45
  this.ws['!merges'] = this.MergeArray;
46
46
  this.wb.SheetNames.push(ws_name);
@@ -124,12 +124,12 @@ class GSTR2ExcelService {
124
124
  });
125
125
  this.Row += 2;
126
126
  }
127
- static setInvoiceDetailsInCell(MainData) {
127
+ static setInvoiceDetailsInCell(MainData, DecimalsNumber) {
128
128
  MainData.forEach((InvoiceList) => {
129
- this.SetInvoiceDataInExcel(InvoiceList);
129
+ this.SetInvoiceDataInExcel(InvoiceList, DecimalsNumber);
130
130
  });
131
131
  }
132
- static SetInvoiceDataInExcel(InvoiceList) {
132
+ static SetInvoiceDataInExcel(InvoiceList, DecimalsNumber) {
133
133
  InvoiceList.Bills.forEach((InvoiceInfo, index) => {
134
134
  // let InvoiceInfo = InvoiceInfoData.Inv;
135
135
  InvoiceInfo.CrDate = this.ConvertDateToReadableFormat(InvoiceInfo.CrDate);
@@ -160,7 +160,7 @@ class GSTR2ExcelService {
160
160
  ];
161
161
  let ColStart = 0;
162
162
  InvoiceData.forEach((InvData) => {
163
- InvData.text = this.ConvertToString(InvData.text, InvData.IsString);
163
+ InvData.text = this.ConvertToString(InvData.text, InvData.IsString, DecimalsNumber);
164
164
  this.SetDataInCell(InvData.text, ColStart, this.Row);
165
165
  this.MergeArray.push({ s: { r: this.Row, c: ColStart }, e: { r: this.Row, c: ColStart + InvData.ColRange - 1 } });
166
166
  ColStart += InvData.ColRange;
@@ -180,7 +180,7 @@ class GSTR2ExcelService {
180
180
  ];
181
181
  let PartColStart = TotalsColStart + 1;
182
182
  PartData.forEach((PartInfo) => {
183
- PartInfo.text = this.ConvertToString(PartInfo.text, PartInfo.IsString);
183
+ PartInfo.text = this.ConvertToString(PartInfo.text, PartInfo.IsString, DecimalsNumber);
184
184
  this.SetDataInCell(PartInfo.text, PartColStart, this.Row);
185
185
  this.MergeArray.push({ s: { r: this.Row, c: PartColStart }, e: { r: this.Row, c: PartColStart + PartInfo.ColRange - 1 } });
186
186
  PartColStart += PartInfo.ColRange;
@@ -215,7 +215,7 @@ class GSTR2ExcelService {
215
215
  this.Row += 1;
216
216
  });
217
217
  }
218
- static ConvertToString(Text, IsString) {
218
+ static ConvertToString(Text, IsString, DecimalsNumber) {
219
219
  if (IsString) {
220
220
  if (tr_utils_1.TrUtils.IsNull(Text)) {
221
221
  Text = '';
@@ -227,7 +227,7 @@ class GSTR2ExcelService {
227
227
  }
228
228
  }
229
229
  if (typeof (Text) === 'number') {
230
- return Number(tr_utils_1.TrUtils.FixedTo(Text));
230
+ return Number(tr_utils_1.TrUtils.FixedTo(Text, DecimalsNumber));
231
231
  }
232
232
  else {
233
233
  return Text;
@@ -14,13 +14,13 @@ export declare class TallySalesImportXlsxFileService {
14
14
  };
15
15
  static ws: any;
16
16
  static MainHeadings: any[];
17
- static GetGSTROExcelData(MainData: any, WOTypes: any): any;
17
+ static GetGSTROExcelData(MainData: any, WOTypes: any, EntitySettings: any): any;
18
18
  static GetTotals(MainData: any, WOTypes: any): any;
19
19
  static GetWOTypeName(Type: any, WOTypes: any): any;
20
20
  static setHeadingInCell(MainData: any): void;
21
- static setInvoiceDetailsInCell(MainData: any): void;
22
- static SetInvoiceDataInExcel(InvoiceInfo: any, Index: any): void;
23
- static ConvertToString(Text: any, IsString: any): any;
21
+ static setInvoiceDetailsInCell(MainData: any, DecimalsNumber: number): void;
22
+ static SetInvoiceDataInExcel(InvoiceInfo: any, Index: any, DecimalsNumber: number): void;
23
+ static ConvertToString(Text: any, IsString: any, DecimalsNumber: number): any;
24
24
  static SetDataInCell(Data: any, ColRange: number, RowNum: any): void;
25
25
  static getcelltype(cell: any): any;
26
26
  static ConvertDateToReadableFormat(DateObject: any): any;
@@ -27,7 +27,7 @@ exports.TallySalesImportXlsxFileService = void 0;
27
27
  const XLSX = __importStar(require("xlsx"));
28
28
  const tr_utils_1 = require("../../utils/tr-utils");
29
29
  class TallySalesImportXlsxFileService {
30
- static GetGSTROExcelData(MainData, WOTypes) {
30
+ static GetGSTROExcelData(MainData, WOTypes, EntitySettings) {
31
31
  this.wb = {};
32
32
  this.ws = {};
33
33
  this.Row = 0;
@@ -40,7 +40,7 @@ class TallySalesImportXlsxFileService {
40
40
  this.wb.SheetNames = [];
41
41
  MainData = this.GetTotals(MainData, WOTypes);
42
42
  this.setHeadingInCell(MainData);
43
- this.setInvoiceDetailsInCell(MainData);
43
+ this.setInvoiceDetailsInCell(MainData, EntitySettings.DecimalsNumber);
44
44
  this.ws['!ref'] = XLSX.utils.encode_range(this.range);
45
45
  this.ws['!merges'] = this.MergeArray;
46
46
  this.ws["!cols"] = [{ wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 50 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 },
@@ -596,16 +596,16 @@ class TallySalesImportXlsxFileService {
596
596
  });
597
597
  this.Row += 2;
598
598
  }
599
- static setInvoiceDetailsInCell(MainData) {
599
+ static setInvoiceDetailsInCell(MainData, DecimalsNumber) {
600
600
  let SNO = 0;
601
601
  MainData.forEach((InvoiceList) => {
602
602
  InvoiceList.Invoices.forEach((invoice, Index) => {
603
603
  SNO = SNO + 1;
604
- this.SetInvoiceDataInExcel(invoice, SNO);
604
+ this.SetInvoiceDataInExcel(invoice, SNO, DecimalsNumber);
605
605
  });
606
606
  });
607
607
  }
608
- static SetInvoiceDataInExcel(InvoiceInfo, Index) {
608
+ static SetInvoiceDataInExcel(InvoiceInfo, Index, DecimalsNumber) {
609
609
  // console.log(InvoiceInfo);
610
610
  InvoiceInfo.CrDate = this.ConvertDateToReadableFormat(InvoiceInfo.CrDate);
611
611
  let InvoiceData = [];
@@ -673,7 +673,7 @@ class TallySalesImportXlsxFileService {
673
673
  });
674
674
  let ColStart = 0;
675
675
  InvoiceData.forEach((InvData) => {
676
- InvData.text = this.ConvertToString(InvData.text, InvData.IsString);
676
+ InvData.text = this.ConvertToString(InvData.text, InvData.IsString, DecimalsNumber);
677
677
  this.SetDataInCell(InvData.text, ColStart, this.Row);
678
678
  this.MergeArray.push({
679
679
  s: { r: this.Row, c: ColStart },
@@ -683,7 +683,7 @@ class TallySalesImportXlsxFileService {
683
683
  });
684
684
  this.Row += 1;
685
685
  }
686
- static ConvertToString(Text, IsString) {
686
+ static ConvertToString(Text, IsString, DecimalsNumber) {
687
687
  if (IsString) {
688
688
  if (Text == null) {
689
689
  Text = '';
@@ -695,7 +695,7 @@ class TallySalesImportXlsxFileService {
695
695
  }
696
696
  }
697
697
  if (typeof Text === 'number') {
698
- return Number(tr_utils_1.TrUtils.FixedTo(Text));
698
+ return Number(tr_utils_1.TrUtils.FixedTo(Text, DecimalsNumber));
699
699
  }
700
700
  else {
701
701
  return Text;
@@ -225,10 +225,10 @@ export declare class IssuePartsprintService {
225
225
  })[];
226
226
  static PreparesparePartsTable(ROPrintData: any, isAuto: boolean): any;
227
227
  static GetLaborPartsTableForView(Parts: any, Ops: any, PrintPartNo: any): any;
228
- static WithOutDiscountFieldTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean): any;
229
- static BuildTableBodyForLaborAndParts(Parts: any, Labor: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean): any;
230
- static GetWithOutDiscAndTaxFieldHeader(Parts: any, Ops: any, ShowTaxColumn: any, PrintPartNo: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean): any;
231
- static TaxDataTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean): {
228
+ static WithOutDiscountFieldTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean, DecimalsNumber: number): any;
229
+ static BuildTableBodyForLaborAndParts(Parts: any, Labor: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean, DecimalsNumber: number): any;
230
+ static GetWithOutDiscAndTaxFieldHeader(Parts: any, Ops: any, ShowTaxColumn: any, PrintPartNo: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean, DecimalsNumber: number): any;
231
+ static TaxDataTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean, DecimalsNumber: number): {
232
232
  style: string;
233
233
  table: {
234
234
  widths: (string | number)[];
@@ -241,7 +241,7 @@ export declare class IssuePartsprintService {
241
241
  vLineColor: (i: any, node: any) => string;
242
242
  };
243
243
  };
244
- static ConsolidateDataTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean): {
244
+ static ConsolidateDataTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean, DecimalsNumber: number): {
245
245
  style: string;
246
246
  table: {
247
247
  widths: number[];
@@ -254,7 +254,7 @@ export declare class IssuePartsprintService {
254
254
  vLineColor: (i: any, node: any) => string;
255
255
  };
256
256
  };
257
- static NoTaxDataTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean): {
257
+ static NoTaxDataTable(Parts: any, Ops: any, PrintPartNo: any, ShowTaxColumn: any, Body: any, ShowIGST: any, ConsolidateGST: any, ShowDiscountColumn: any, isAuto: boolean, DecimalsNumber: number): {
258
258
  style: string;
259
259
  table: {
260
260
  widths: number[];
@@ -78,7 +78,7 @@ class IssuePartsprintService {
78
78
  if (tr_utils_1.TrUtils.IsNull(ROPrintData.PrintInfo[i].Text)) {
79
79
  ROPrintData.PrintInfo[i].Text = '';
80
80
  }
81
- List.push(ROPrintData.PrintInfo[i].Text, this.WithOutDiscountFieldTable(tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Items), tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Ops), ROPrintData.ShowTaxColumn, ROPrintData.Entity.MPN, ROPrintData.Entity.Body, ROPrintData.ShowIGST, ROPrintData.ConsolidateGST, ROPrintData.ShowDiscountColumn, isAuto));
81
+ List.push(ROPrintData.PrintInfo[i].Text, this.WithOutDiscountFieldTable(tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Items), tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Ops), ROPrintData.ShowTaxColumn, ROPrintData.Entity.MPN, ROPrintData.Entity.Body, ROPrintData.ShowIGST, ROPrintData.ConsolidateGST, ROPrintData.ShowDiscountColumn, isAuto, ROPrintData.Entity.DecimalsNumber));
82
82
  }
83
83
  }
84
84
  else {
@@ -90,7 +90,7 @@ class IssuePartsprintService {
90
90
  if (tr_utils_1.TrUtils.IsNull(ROPrintData.PrintInfo[i].Text)) {
91
91
  ROPrintData.PrintInfo[i].Text = '';
92
92
  }
93
- List.push(ROPrintData.PrintInfo[i].Text, this.GetWithOutDiscAndTaxFieldHeader(tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Items), tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Ops), ROPrintData.ShowTaxColumn, ROPrintData.Entity.MPN, ROPrintData.Entity.Body, ROPrintData.ShowIGST, ROPrintData.ConsolidateGST, ROPrintData.ShowDiscountColumn, isAuto));
93
+ List.push(ROPrintData.PrintInfo[i].Text, this.GetWithOutDiscAndTaxFieldHeader(tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Items), tr_utils_1.TrUtils.Stringify(ROPrintData.PrintInfo[i].Ops), ROPrintData.ShowTaxColumn, ROPrintData.Entity.MPN, ROPrintData.Entity.Body, ROPrintData.ShowIGST, ROPrintData.ConsolidateGST, ROPrintData.ShowDiscountColumn, isAuto, ROPrintData.Entity.DecimalsNumber));
94
94
  }
95
95
  }
96
96
  }
@@ -129,7 +129,7 @@ class IssuePartsprintService {
129
129
  return a;
130
130
  }
131
131
  }
132
- static WithOutDiscountFieldTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto) {
132
+ static WithOutDiscountFieldTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber) {
133
133
  if (Parts.length !== 0 || Ops.length !== 0) {
134
134
  if (PrintPartNo) {
135
135
  return {
@@ -138,7 +138,7 @@ class IssuePartsprintService {
138
138
  table: {
139
139
  widths: [25, 60, 155, 30, 50, 60, 30, 50],
140
140
  headerRows: 1,
141
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
141
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
142
142
  },
143
143
  layout: shared_print_service_1.PrintSharedService.LayOutStyleanother()
144
144
  };
@@ -150,7 +150,7 @@ class IssuePartsprintService {
150
150
  table: {
151
151
  widths: [25, 215, 25, 50, 60, 45, 50],
152
152
  headerRows: 1,
153
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
153
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
154
154
  },
155
155
  layout: shared_print_service_1.PrintSharedService.LayOutStyleanother()
156
156
  };
@@ -161,7 +161,7 @@ class IssuePartsprintService {
161
161
  return a;
162
162
  }
163
163
  }
164
- static BuildTableBodyForLaborAndParts(Parts, Labor, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto) {
164
+ static BuildTableBodyForLaborAndParts(Parts, Labor, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber) {
165
165
  var body = [];
166
166
  let columns = shared_print_service_1.PrintSharedService.GetWithOutDiscountFieldHeader(PrintPartNo, ShowTaxColumn, Body, ShowIGST, ShowDiscountColumn);
167
167
  // if (ShowTaxColumn) {
@@ -194,14 +194,14 @@ class IssuePartsprintService {
194
194
  let dpartadding1 = {};
195
195
  dpartadding1.SNo = '';
196
196
  dpartadding1.Desc = 'Spare Total';
197
- dpartadding1.QtyAndUoM = tr_utils_1.TrUtils.FixedTo(Qty);
197
+ dpartadding1.QtyAndUoM = tr_utils_1.TrUtils.FixedTo(Qty, DecimalsNumber);
198
198
  dpartadding1.bold = true;
199
- dpartadding1.UnPr = tr_utils_1.TrUtils.FixedTo(Taxable);
200
- dpartadding1.SGSTAmt = tr_utils_1.TrUtils.FixedTo(SGSTAMT);
201
- dpartadding1.IGSTAmt = tr_utils_1.TrUtils.FixedTo(IGSTAMT);
202
- dpartadding1.CGSTAmt = tr_utils_1.TrUtils.FixedTo(CGSTAMT);
199
+ dpartadding1.UnPr = tr_utils_1.TrUtils.FixedTo(Taxable, DecimalsNumber);
200
+ dpartadding1.SGSTAmt = tr_utils_1.TrUtils.FixedTo(SGSTAMT, DecimalsNumber);
201
+ dpartadding1.IGSTAmt = tr_utils_1.TrUtils.FixedTo(IGSTAMT, DecimalsNumber);
202
+ dpartadding1.CGSTAmt = tr_utils_1.TrUtils.FixedTo(CGSTAMT, DecimalsNumber);
203
203
  dpartadding1.TCode = ShowTaxColumn ? 114 : undefined;
204
- dpartadding1.LineTotal = tr_utils_1.TrUtils.FixPriceValue(FinalTotal);
204
+ dpartadding1.LineTotal = tr_utils_1.TrUtils.FixPriceValue(FinalTotal, DecimalsNumber);
205
205
  Parts.push({ SNo: '' });
206
206
  Parts.push(dpartadding1);
207
207
  }
@@ -313,13 +313,13 @@ class IssuePartsprintService {
313
313
  dpartadding1.SNo = '';
314
314
  dpartadding1.Desc = 'Labor Total';
315
315
  // dpartadding1.QtyAndUoM = Qty;
316
- dpartadding1.UnPr = tr_utils_1.TrUtils.FixedTo(Taxable);
317
- dpartadding1.SGSTAmt = tr_utils_1.TrUtils.FixedTo(SGSTAMT);
318
- dpartadding1.IGSTAmt = tr_utils_1.TrUtils.FixedTo(IGSTAMT);
319
- dpartadding1.CGSTAmt = tr_utils_1.TrUtils.FixedTo(CGSTAMT);
316
+ dpartadding1.UnPr = tr_utils_1.TrUtils.FixedTo(Taxable, DecimalsNumber);
317
+ dpartadding1.SGSTAmt = tr_utils_1.TrUtils.FixedTo(SGSTAMT, DecimalsNumber);
318
+ dpartadding1.IGSTAmt = tr_utils_1.TrUtils.FixedTo(IGSTAMT, DecimalsNumber);
319
+ dpartadding1.CGSTAmt = tr_utils_1.TrUtils.FixedTo(CGSTAMT, DecimalsNumber);
320
320
  dpartadding1.TCode = ShowTaxColumn ? 114 : undefined;
321
321
  dpartadding1.bold = true;
322
- dpartadding1.LineTotal = tr_utils_1.TrUtils.FixPriceValue(FinalTotal);
322
+ dpartadding1.LineTotal = tr_utils_1.TrUtils.FixPriceValue(FinalTotal, DecimalsNumber);
323
323
  Labor.push({ SNo: '' });
324
324
  Labor.push(dpartadding1);
325
325
  }
@@ -405,17 +405,17 @@ class IssuePartsprintService {
405
405
  });
406
406
  return body;
407
407
  }
408
- static GetWithOutDiscAndTaxFieldHeader(Parts, Ops, ShowTaxColumn, PrintPartNo, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto) {
408
+ static GetWithOutDiscAndTaxFieldHeader(Parts, Ops, ShowTaxColumn, PrintPartNo, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber) {
409
409
  if (Parts.length !== 0 || Ops.length !== 0) {
410
410
  if (ShowTaxColumn) {
411
- return this.TaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto);
411
+ return this.TaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber);
412
412
  }
413
413
  else {
414
414
  if (ConsolidateGST) {
415
- return this.ConsolidateDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto);
415
+ return this.ConsolidateDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber);
416
416
  }
417
417
  else {
418
- return this.NoTaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto);
418
+ return this.NoTaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber);
419
419
  }
420
420
  }
421
421
  }
@@ -424,7 +424,7 @@ class IssuePartsprintService {
424
424
  return a;
425
425
  }
426
426
  }
427
- static TaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto) {
427
+ static TaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber) {
428
428
  if (PrintPartNo) {
429
429
  if (ShowIGST) {
430
430
  return {
@@ -432,7 +432,7 @@ class IssuePartsprintService {
432
432
  table: {
433
433
  widths: shared_print_service_1.PrintSharedService.TaxTableWidths(PrintPartNo, ShowIGST, ShowDiscountColumn),
434
434
  // headerRows: 2,
435
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
435
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
436
436
  },
437
437
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
438
438
  };
@@ -443,7 +443,7 @@ class IssuePartsprintService {
443
443
  table: {
444
444
  widths: shared_print_service_1.PrintSharedService.TaxTableWidths(PrintPartNo, ShowIGST, ShowDiscountColumn),
445
445
  // headerRows: 2,
446
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
446
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
447
447
  },
448
448
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
449
449
  };
@@ -456,7 +456,7 @@ class IssuePartsprintService {
456
456
  table: {
457
457
  widths: shared_print_service_1.PrintSharedService.TaxTableWidths(PrintPartNo, ShowIGST, ShowDiscountColumn),
458
458
  // headerRows: 2,
459
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
459
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
460
460
  },
461
461
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
462
462
  };
@@ -467,21 +467,21 @@ class IssuePartsprintService {
467
467
  table: {
468
468
  widths: shared_print_service_1.PrintSharedService.TaxTableWidths(PrintPartNo, ShowIGST, ShowDiscountColumn),
469
469
  // headerRows: 2,
470
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
470
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
471
471
  },
472
472
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
473
473
  };
474
474
  }
475
475
  }
476
476
  }
477
- static ConsolidateDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto) {
477
+ static ConsolidateDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber) {
478
478
  if (PrintPartNo) {
479
479
  return {
480
480
  style: 'tableExample',
481
481
  table: {
482
482
  widths: [25, 70, 263, 25, 60, 80, 10, 40],
483
483
  // headerRows: 1,
484
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
484
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
485
485
  },
486
486
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
487
487
  };
@@ -492,20 +492,20 @@ class IssuePartsprintService {
492
492
  table: {
493
493
  widths: [25, 295, 50, 80, 80, 10, 40],
494
494
  // headerRows: 1,
495
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
495
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
496
496
  },
497
497
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
498
498
  };
499
499
  }
500
500
  }
501
- static NoTaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto) {
501
+ static NoTaxDataTable(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber) {
502
502
  if (PrintPartNo) {
503
503
  return {
504
504
  style: 'tableExample',
505
505
  table: {
506
506
  widths: shared_print_service_1.PrintSharedService.WidthForInsuranceOrNot(ShowDiscountColumn, PrintPartNo),
507
507
  // headerRows: 1,
508
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
508
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
509
509
  },
510
510
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
511
511
  };
@@ -516,7 +516,7 @@ class IssuePartsprintService {
516
516
  table: {
517
517
  widths: shared_print_service_1.PrintSharedService.WidthForInsuranceOrNot(ShowDiscountColumn, PrintPartNo),
518
518
  // headerRows: 1,
519
- body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto)
519
+ body: this.BuildTableBodyForLaborAndParts(Parts, Ops, PrintPartNo, ShowTaxColumn, Body, ShowIGST, ConsolidateGST, ShowDiscountColumn, isAuto, DecimalsNumber)
520
520
  },
521
521
  layout: shared_print_service_1.PrintSharedService.LayOutStyle()
522
522
  };
@@ -13,11 +13,11 @@ export declare class ExpiringDrugsXlsxFileService {
13
13
  };
14
14
  };
15
15
  static ws: any;
16
- static GetExpiringDrugsExcelData(MainData: any, isSale: boolean, searchValue: any, HeaderName: any): any;
16
+ static GetExpiringDrugsExcelData(MainData: any, isSale: boolean, searchValue: any, HeaderName: any, EntitySettings: any): any;
17
17
  static setHeadingInCell(HeaderName: any, showSearch: any): void;
18
- static setInvoiceDetailsInCell(MainData: any, isSale: boolean): void;
19
- static SetInvoiceDataInExcel(InvoiceInfo: any, isSale: boolean): void;
20
- static ConvertToString(Text: any, IsString: any): any;
18
+ static setInvoiceDetailsInCell(MainData: any, isSale: boolean, DecimalsNumber: number): void;
19
+ static SetInvoiceDataInExcel(InvoiceInfo: any, isSale: boolean, DecimalsNumber: number): void;
20
+ static ConvertToString(Text: any, IsString: any, DecimalsNumber: number): any;
21
21
  static SetDataInCell(Data: any, ColRange: number, RowNum: any): void;
22
22
  static getcelltype(cell: any): any;
23
23
  static ConvertDateToReadableFormat(DateObject: any): any;
@@ -27,8 +27,9 @@ exports.ExpiringDrugsXlsxFileService = void 0;
27
27
  const XLSX = __importStar(require("xlsx"));
28
28
  const my_date_1 = require("../../../../utils/my-date");
29
29
  const tr_utils_1 = require("../../../../utils/tr-utils");
30
+ const math_operations_1 = require("../../../../shared/math-operations");
30
31
  class ExpiringDrugsXlsxFileService {
31
- static GetExpiringDrugsExcelData(MainData, isSale, searchValue, HeaderName) {
32
+ static GetExpiringDrugsExcelData(MainData, isSale, searchValue, HeaderName, EntitySettings) {
32
33
  this.wb = {};
33
34
  this.ws = {};
34
35
  this.Row = 0;
@@ -66,7 +67,7 @@ class ExpiringDrugsXlsxFileService {
66
67
  // console.log(`${key}: ${searchValue[key]}`);
67
68
  }
68
69
  this.setHeadingInCell(HeaderName, showSearch);
69
- this.setInvoiceDetailsInCell(MainData, isSale);
70
+ this.setInvoiceDetailsInCell(MainData, isSale, EntitySettings.DecimalsNumber);
70
71
  this.ws['!ref'] = XLSX.utils.encode_range(this.range);
71
72
  this.ws['!merges'] = this.MergeArray;
72
73
  this.ws["!cols"] = [{ wch: 50 }, { wch: 10 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }, { wch: 15 }];
@@ -182,26 +183,26 @@ class ExpiringDrugsXlsxFileService {
182
183
  });
183
184
  this.Row += 2;
184
185
  }
185
- static setInvoiceDetailsInCell(MainData, isSale) {
186
+ static setInvoiceDetailsInCell(MainData, isSale, DecimalsNumber) {
186
187
  MainData.forEach((InvoiceList) => {
187
- this.SetInvoiceDataInExcel(InvoiceList, isSale);
188
+ this.SetInvoiceDataInExcel(InvoiceList, isSale, DecimalsNumber);
188
189
  });
189
190
  }
190
- static SetInvoiceDataInExcel(InvoiceInfo, isSale) {
191
+ static SetInvoiceDataInExcel(InvoiceInfo, isSale, DecimalsNumber) {
191
192
  InvoiceInfo.CrDate = this.ConvertDateToReadableFormat(InvoiceInfo.CrDate);
192
193
  let InvoiceData = [
193
194
  { text: InvoiceInfo.Name, ColRange: 1, IsString: true },
194
195
  { text: InvoiceInfo.Batch.BN, ColRange: 1, IsString: true },
195
196
  { text: my_date_1.MyDate.ConvertUTCDateToReadableExDateTxt(InvoiceInfo.Batch.ExDt), ColRange: 1, IsString: true },
196
197
  { text: InvoiceInfo.Batch.Qty, ColRange: 1, IsString: true },
197
- { text: tr_utils_1.TrUtils.FixPriceValue(InvoiceInfo.Batch.Cost), ColRange: 1, IsString: true },
198
- { text: tr_utils_1.TrUtils.FixPriceValue(InvoiceInfo.Batch.Qty * InvoiceInfo.Batch.Cost), ColRange: 1, IsString: true },
198
+ { text: tr_utils_1.TrUtils.FixPriceValue(InvoiceInfo.Batch.Cost, DecimalsNumber), ColRange: 1, IsString: true },
199
+ { text: tr_utils_1.TrUtils.FixPriceValue((0, math_operations_1.Multiply)(InvoiceInfo.Batch.Qty, InvoiceInfo.Batch.Cost), DecimalsNumber), ColRange: 1, IsString: true },
199
200
  // { text: InvoiceInfo.Round, ColRange: 1, IsString: true },
200
201
  // { text: InvoiceInfo.Total, ColRange: 1, IsString: false }
201
202
  ];
202
203
  let ColStart = 0;
203
204
  InvoiceData.forEach((InvData) => {
204
- InvData.text = this.ConvertToString(InvData.text, InvData.IsString);
205
+ InvData.text = this.ConvertToString(InvData.text, InvData.IsString, DecimalsNumber);
205
206
  this.SetDataInCell(InvData.text, ColStart, this.Row);
206
207
  this.MergeArray.push({
207
208
  s: { r: this.Row, c: ColStart },
@@ -211,7 +212,7 @@ class ExpiringDrugsXlsxFileService {
211
212
  });
212
213
  this.Row += 1;
213
214
  }
214
- static ConvertToString(Text, IsString) {
215
+ static ConvertToString(Text, IsString, DecimalsNumber) {
215
216
  if (IsString) {
216
217
  if (Text == null) {
217
218
  Text = '';
@@ -223,7 +224,7 @@ class ExpiringDrugsXlsxFileService {
223
224
  }
224
225
  }
225
226
  if (typeof Text === 'number') {
226
- return Number(tr_utils_1.TrUtils.FixedTo(Text));
227
+ return Number(tr_utils_1.TrUtils.FixedTo(Text, DecimalsNumber));
227
228
  }
228
229
  else {
229
230
  return Text;
@@ -13,11 +13,11 @@ export declare class ItemWiseMODetailsXlsxFileService {
13
13
  };
14
14
  };
15
15
  static ws: any;
16
- static GetItemWiseMODetailsExcelData(MainData: any, searchValue: any, HeaderName: any): any;
16
+ static GetItemWiseMODetailsExcelData(MainData: any, searchValue: any, HeaderName: any, EntitySettings: any): any;
17
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;
18
+ static setInvoiceDetailsInCell(MainData: any, DecimalsNumber: any): void;
19
+ static SetInvoiceDataInExcel(InvoiceInfo: any, DecimalsNumber: number): void;
20
+ static ConvertToString(Text: any, IsString: any, DecimalsNumber: number): any;
21
21
  static SetDataInCell(Data: any, ColRange: number, RowNum: any): void;
22
22
  static getcelltype(cell: any): any;
23
23
  }