scheduler-node-models 1.2.54 → 1.2.56

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.
@@ -1,4 +1,4 @@
1
- import { RichText, Style, Worksheet } from "@zurmokeeper/exceljs";
1
+ import { RichText, Style, Worksheet } from "exceljs";
2
2
  export declare class Formula {
3
3
  formula: string;
4
4
  constructor(formula: string);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scheduler-node-models",
3
- "version": "1.2.54",
3
+ "version": "1.2.56",
4
4
  "main": "index.js",
5
5
  "types": "index.d.ts",
6
6
  "files": [
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ExcelRowIngest = void 0;
4
- const exceljs_1 = require("@zurmokeeper/exceljs");
4
+ const exceljs_1 = require("exceljs");
5
5
  const sites_1 = require("../sites");
6
6
  const teams_1 = require("../teams");
7
7
  const excelRow_1 = require("./excelRow");
@@ -33,13 +33,6 @@ class ExcelRowIngest {
33
33
  }
34
34
  async processFile(file) {
35
35
  const result = [];
36
- // get the company password from the team database object's company list
37
- let password = '';
38
- this.team.companies.forEach(co => {
39
- if (this.company.toLowerCase() === co.id.toLowerCase()) {
40
- password = co.ingestPwd;
41
- }
42
- });
43
36
  // create test patterns for hours, if value doesn't match the hours pattern, it will
44
37
  // be assumed to be a leave code
45
38
  const hPattern = "^[0-9]{1,2}(\.[0-9]+)?$";
@@ -56,17 +49,13 @@ class ExcelRowIngest {
56
49
  }
57
50
  const fileBinary = Buffer.from(fileDataU8);
58
51
  const workbook = new exceljs_1.Workbook();
59
- console.log(`password = ${password}`);
60
- await workbook.xlsx.load(fileBinary.buffer, { password: password });
61
- workbook.eachSheet((sheet, s) => {
62
- console.log(sheet.name);
63
- });
52
+ await workbook.xlsx.load(fileBinary.buffer);
64
53
  const worksheet = workbook.getWorksheet('Sheet1');
65
54
  if (worksheet) {
66
55
  worksheet.eachRow((row, r) => {
67
- console.log(r);
68
56
  const name = row.getCell(1).toString().trim();
69
57
  if (name !== '' && name !== 'Name' && name.toLowerCase() !== 'remarks') {
58
+ console.log(name);
70
59
  if (this.site.employees) {
71
60
  this.site.employees.forEach(emp => {
72
61
  if (emp.name.getLastFirst().toLowerCase() === name.toLowerCase()) {
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SAPIngest = void 0;
4
4
  const teams_1 = require("../teams");
5
5
  const excelRow_1 = require("./excelRow");
6
- const exceljs_1 = require("@zurmokeeper/exceljs");
6
+ const exceljs_1 = require("exceljs");
7
7
  class SAPIngest {
8
8
  files;
9
9
  team;