taxtank-core 0.12.0 → 0.12.1

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.
@@ -7671,6 +7671,16 @@
7671
7671
  PdfOrientationEnum["LANDSCAPE"] = "landscape";
7672
7672
  })(exports.PdfOrientationEnum || (exports.PdfOrientationEnum = {}));
7673
7673
 
7674
+ /**
7675
+ * Class with entities for generated PDF file
7676
+ */
7677
+ var PdfSettings = /** @class */ (function () {
7678
+ function PdfSettings() {
7679
+ this.orientation = exports.PdfOrientationEnum.PORTRAIT;
7680
+ }
7681
+ return PdfSettings;
7682
+ }());
7683
+
7674
7684
  /**
7675
7685
  * Calculation form control types
7676
7686
  */
@@ -11548,21 +11558,21 @@
11548
11558
  /**
11549
11559
  * Export file from provided HTML tables
11550
11560
  */
11551
- PdfService.prototype.exportTables = function (tables, title, fileName, orientation) {
11552
- var document = this.generateFromTables(orientation, tables, title);
11553
- document.save(fileName + ".pdf");
11561
+ PdfService.prototype.exportTables = function (tables, fileSettings) {
11562
+ var document = this.generateFromTables(tables, fileSettings);
11563
+ document.save(fileSettings.filename + ".pdf");
11554
11564
  };
11555
11565
  /**
11556
11566
  * Export file from provided array-like table data
11557
11567
  */
11558
- PdfService.prototype.exportFromDataTables = function (dataTables, title, fileName) {
11559
- var document = this.generateFromDataTables(title, dataTables);
11560
- document.save(fileName + ".pdf");
11568
+ PdfService.prototype.exportFromDataTables = function (dataTables, fileSettings) {
11569
+ var document = this.generateFromDataTables(dataTables, fileSettings.title);
11570
+ document.save(fileSettings.filename + ".pdf");
11561
11571
  };
11562
11572
  /**
11563
11573
  * Generate file from array-like table data
11564
11574
  */
11565
- PdfService.prototype.generateFromDataTables = function (title, dataTables) {
11575
+ PdfService.prototype.generateFromDataTables = function (dataTables, title) {
11566
11576
  var _this = this;
11567
11577
  var pdf = new jsPDF__default["default"]();
11568
11578
  this.setDocumentTitle(pdf, title);
@@ -11572,10 +11582,10 @@
11572
11582
  });
11573
11583
  return pdf;
11574
11584
  };
11575
- PdfService.prototype.generateFromTables = function (orientation, tables, title) {
11585
+ PdfService.prototype.generateFromTables = function (tables, fileSettings) {
11576
11586
  var _this = this;
11577
- var pdf = new jsPDF__default["default"](orientation);
11578
- this.setDocumentTitle(pdf, title);
11587
+ var pdf = new jsPDF__default["default"](fileSettings.orientation);
11588
+ this.setDocumentTitle(pdf, fileSettings.title);
11579
11589
  this.setDocumentLogo(pdf);
11580
11590
  tables.forEach(function (table) {
11581
11591
  // Add table caption if not provided
@@ -13790,6 +13800,7 @@
13790
13800
  exports.OccupationService = OccupationService;
13791
13801
  exports.PasswordForm = PasswordForm;
13792
13802
  exports.PdfService = PdfService;
13803
+ exports.PdfSettings = PdfSettings;
13793
13804
  exports.Phone = Phone;
13794
13805
  exports.PreloaderService = PreloaderService;
13795
13806
  exports.Property = Property;