waltronics-types 1.0.14 → 1.0.16

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.
@@ -5,19 +5,20 @@ import { Repair } from "./Repair";
5
5
  import { Payment } from "./Payment";
6
6
  import { Service } from "./Service";
7
7
  import { Diagnosis } from "./Diagnosis";
8
+ import { ID, UUID } from "./Types";
8
9
  export type Appointment = {
9
- CustomerID: string;
10
- AppointmentID: string;
10
+ CustomerID: UUID;
11
+ AppointmentID: UUID;
11
12
  FName: string;
12
13
  LName: string;
13
14
  Email: string;
14
15
  Phone: string;
15
16
  CreationDate: Date;
16
17
  UpdationDate: Date;
17
- StartDate: string | null;
18
- EndDate: string | null;
18
+ StartDate: Date | null;
19
+ EndDate: Date | null;
19
20
  Cost: number;
20
- StatusID: number;
21
+ StatusID: ID;
21
22
  Status: string;
22
23
  Make: string;
23
24
  Model: string;
@@ -0,0 +1,27 @@
1
+ import { AppointmentLabels } from "./Label";
2
+ export type AppointmentRow = {
3
+ AppointmentID: string;
4
+ CustomerID: string;
5
+ FName: string;
6
+ LName: string;
7
+ Email: string;
8
+ Phone: string;
9
+ CreationDate: Date;
10
+ UpdationDate: Date;
11
+ StartDate: Date;
12
+ EndDate: Date;
13
+ Cost: number;
14
+ Status: string;
15
+ StatusID: number;
16
+ Make: string;
17
+ Model: string;
18
+ ModelYear: number;
19
+ VIN: string;
20
+ Mileage: number;
21
+ LicensePlate: string;
22
+ Labels: AppointmentLabels;
23
+ };
24
+ export type AppointmentsTable = {
25
+ Appointments: Array<AppointmentRow>;
26
+ Count: number;
27
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,5 +1,6 @@
1
+ import { ID } from "./Types";
1
2
  export type Diagnosis = {
2
- DiagnosisID: number;
3
+ DiagnosisID: ID;
3
4
  Code: string;
4
5
  Message: string;
5
6
  };
@@ -1,16 +1,17 @@
1
+ import { UUID } from "./Types";
1
2
  export type Employee = {
2
- EmployeeID: string;
3
+ EmployeeID: UUID;
3
4
  FName: string;
4
5
  LName: string;
5
6
  Email: string;
6
7
  Phone: string;
7
8
  };
8
9
  export type EmployeeName = {
9
- EmployeeID: string;
10
+ EmployeeID: UUID;
10
11
  FName: string;
11
12
  LName: string;
12
13
  };
13
14
  export type EmployeeFullName = {
14
- EmployeeID: string;
15
+ EmployeeID: UUID;
15
16
  FullName: string;
16
17
  };
package/dist/Event.d.ts CHANGED
@@ -1,17 +1,18 @@
1
+ import { ID, UUID } from "./Types";
1
2
  export type Event = {
2
- EventID: number;
3
- EmployeeID: string;
3
+ EventID: ID;
4
+ EmployeeID: UUID;
4
5
  Name: string;
5
6
  Date: string;
6
7
  Summary: string;
7
- AppointmentID: string | null;
8
+ AppointmentID: UUID | null;
8
9
  Sharees: Array<{
9
- ShareeID: string;
10
- EventID: string;
10
+ ShareeID: UUID;
11
+ EventID: ID;
11
12
  }>;
12
13
  };
13
14
  export type EventSharee = {
15
+ ShareeID: UUID;
14
16
  ShareeFName: string;
15
17
  ShareeLName: string;
16
- ShareeID: string;
17
18
  };
@@ -1,20 +1,21 @@
1
+ import { ID } from "./Types";
1
2
  export type InfoMake = {
2
3
  Make: string;
3
4
  };
4
5
  export type InfoLabel = {
5
- LabelID: number;
6
+ LabelID: ID;
6
7
  Label: string;
7
8
  };
8
9
  export type InfoStatus = {
9
- StatusID: number;
10
+ StatusID: ID;
10
11
  Status: string;
11
12
  Description: string;
12
13
  };
13
14
  export type InfoService = {
14
- ClassID: number;
15
- DivisionID: number;
16
- ServiceID: number;
15
+ ClassID: ID;
17
16
  Class: string;
18
17
  Division: string;
18
+ DivisionID: ID;
19
19
  Service: string;
20
+ ServiceID: ID;
20
21
  };
package/dist/Label.d.ts CHANGED
@@ -1,12 +1,10 @@
1
+ import { ID, UUID } from "./Types";
1
2
  export type Label = {
2
- LabelID: number;
3
+ LabelID: ID;
3
4
  Label: string;
4
- Value: number | null;
5
- AppointmentID: string;
5
+ Value: boolean | null;
6
+ AppointmentID: UUID;
6
7
  };
7
8
  export type AppointmentLabels = {
8
- [LabelName: string]: Label;
9
- };
10
- export type MultipleAppointmentLabels = {
11
- [AppointmentID: string]: AppointmentLabels;
9
+ [Label: string]: Label;
12
10
  };
package/dist/Note.d.ts CHANGED
@@ -1,31 +1,32 @@
1
+ import { ID, UUID } from "./Types";
2
+ export type NoteAttachment = {
3
+ NoteID: ID;
4
+ AttachmentID: ID;
5
+ URL: string;
6
+ Name: string;
7
+ };
1
8
  export type Note = {
2
- NoteID: string;
3
- EmployeeID: string;
4
- AppointmentID: string;
9
+ NoteID: ID;
10
+ EmployeeID: UUID;
11
+ AppointmentID: UUID;
5
12
  Head: string;
6
13
  Body: string;
7
- ShowCustomer: string;
14
+ ShowCustomer: boolean;
8
15
  CreationDate: Date;
9
16
  UpdationDate: Date;
10
17
  Sharees: Array<{
11
- ShareeID: string;
12
- NoteID: string;
18
+ ShareeID: UUID;
19
+ NoteID: ID;
13
20
  }>;
14
21
  Attachments: Array<NoteAttachment>;
15
22
  };
16
- export type NoteAttachment = {
17
- NoteID: number;
18
- AttachmentID: number;
19
- URL: string;
20
- Name: string;
23
+ export type EmployeeNote = Note & {
24
+ OwnerFName: string;
25
+ OwnerLName: string;
26
+ OwnerID: UUID;
21
27
  };
22
28
  export type NoteSharee = {
29
+ ShareeID: UUID;
23
30
  ShareeFName: string;
24
31
  ShareeLName: string;
25
- ShareeID: string;
26
- };
27
- export type EmployeeNote = Note & {
28
- OwnerFName: string;
29
- OwnerLName: string;
30
- OwnerID: string;
31
32
  };
package/dist/Part.d.ts CHANGED
@@ -1,5 +1,6 @@
1
+ import { ID } from "./Types";
1
2
  export type Part = {
2
- PartID: number;
3
+ PartID: ID;
3
4
  PartName: string;
4
5
  PartNumber: string;
5
6
  Quantity: number;
package/dist/Payment.d.ts CHANGED
@@ -1,6 +1,7 @@
1
+ import { ID, UUID } from "./Types";
1
2
  export type Payment = {
2
- PaymentID: string;
3
- AppointmentID: string;
3
+ PaymentID: ID;
4
+ AppointmentID: UUID;
4
5
  Payment: number;
5
6
  PaymentDate: Date;
6
7
  Name: string;
@@ -2,9 +2,10 @@ import { Note } from "./Note";
2
2
  import { Repair } from "./Repair";
3
3
  import { Service } from "./Service";
4
4
  import { Diagnosis } from "./Diagnosis";
5
+ import { UUID } from "./Types";
5
6
  export type ProtectedAppointment = {
6
- AppointmentID: string;
7
- CustomerID: number;
7
+ AppointmentID: UUID;
8
+ CustomerID: UUID;
8
9
  FName: string;
9
10
  LName: string;
10
11
  Email: string;
package/dist/Repair.d.ts CHANGED
@@ -1,4 +1,5 @@
1
+ import { ID } from "./Types";
1
2
  export type Repair = {
2
- RepairID: number;
3
+ RepairID: ID;
3
4
  Repair: string;
4
5
  };
package/dist/Service.d.ts CHANGED
@@ -1,8 +1,9 @@
1
+ import { ID, UUID } from "./Types";
1
2
  export type Service = {
2
- AppointmentServiceID: number;
3
- AppointmentID: string;
3
+ AppointmentID: UUID;
4
+ AppointmentServiceID: ID;
4
5
  Class: string;
5
6
  Division: string;
6
7
  Service: string;
7
- ServiceID: number | null;
8
+ ServiceID: ID | null;
8
9
  };
@@ -0,0 +1,27 @@
1
+ import { AppointmentLabels } from "./Label";
2
+ export type ShortenedAppointment = {
3
+ AppointmentID: string;
4
+ CustomerID: string;
5
+ FName: string;
6
+ LName: string;
7
+ Email: string;
8
+ Phone: string;
9
+ CreationDate: Date;
10
+ UpdationDate: Date;
11
+ StartDate: Date;
12
+ EndDate: Date;
13
+ Cost: number;
14
+ Status: string;
15
+ StatusID: number;
16
+ Make: string;
17
+ Model: string;
18
+ ModelYear: number;
19
+ VIN: string;
20
+ Mileage: number;
21
+ LicensePlate: string;
22
+ Labels: AppointmentLabels;
23
+ };
24
+ export type ShortenedAppointments = {
25
+ Appointments: Array<ShortenedAppointment>;
26
+ Count: number;
27
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,2 @@
1
+ export type ID = number;
2
+ export type UUID = string;
package/dist/Types.js ADDED
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,32 +1,35 @@
1
1
  import { z } from "zod";
2
2
  export declare const VIN: RegExp;
3
- export declare const UUID: RegExp;
4
3
  export declare const SQL_DATE: RegExp;
5
- export declare const isName: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
6
- export declare const isEmail: z.ZodEmail;
7
- export declare const isPhone: z.ZodString;
8
- export declare const isDate: z.ZodString;
9
- export declare const isMoney: z.ZodCoercedNumber<unknown>;
10
- export declare const isVIN: z.ZodString;
4
+ export declare const hasLength: (data: {
5
+ min: number;
6
+ max: number;
7
+ name: string;
8
+ }) => z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
11
9
  export declare const isInteger: z.ZodCoercedNumber<unknown>;
12
10
  export declare const isIntegerArray: z.ZodArray<z.ZodCoercedNumber<unknown>>;
13
11
  export declare const isUUID: z.ZodUUID;
14
- export declare const isUUIDArray: z.ZodArray<z.ZodString>;
12
+ export declare const isUUIDArray: z.ZodArray<z.ZodUUID>;
15
13
  export declare const isBit: z.ZodEnum<{
16
14
  "0, 1": "0, 1";
17
15
  }>;
16
+ export declare const isName: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
17
+ export declare const isEmail: z.ZodEmail;
18
+ export declare const isPhone: z.ZodString;
19
+ export declare const isDate: z.ZodString;
20
+ export declare const isMoney: z.ZodCoercedNumber<unknown>;
21
+ export declare const isVIN: z.ZodString;
18
22
  export declare const isID: z.ZodUnion<readonly [z.ZodLiteral<"">, z.ZodCoercedNumber<unknown>]>;
19
- export declare const hasLengthAndClean: (data: {
20
- min: number;
21
- max: number;
22
- name: string;
23
- }) => z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
24
23
  export declare const isCode: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
25
24
  export declare const isMessage: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
26
25
  export declare const isHead: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
27
26
  export declare const isBody: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
28
27
  export declare const isPartName: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
29
28
  export declare const isPartNumber: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
29
+ export declare const isRepair: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
30
+ export declare const isClass: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
31
+ export declare const isDivision: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
32
+ export declare const isService: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
30
33
  export declare const isCreditCardNumber: z.ZodString;
31
34
  export declare const isExpirationDate: z.ZodString;
32
35
  export declare const isCreditCardType: z.ZodEnum<{
@@ -34,7 +37,3 @@ export declare const isCreditCardType: z.ZodEnum<{
34
37
  MASTERCARD: "MASTERCARD";
35
38
  AMEX: "AMEX";
36
39
  }>;
37
- export declare const isRepair: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
38
- export declare const isClass: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
39
- export declare const isDivision: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
40
- export declare const isService: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
@@ -3,39 +3,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.isService = exports.isDivision = exports.isClass = exports.isRepair = exports.isCreditCardType = exports.isExpirationDate = exports.isCreditCardNumber = exports.isPartNumber = exports.isPartName = exports.isBody = exports.isHead = exports.isMessage = exports.isCode = exports.hasLengthAndClean = exports.isID = exports.isBit = exports.isUUIDArray = exports.isUUID = exports.isIntegerArray = exports.isInteger = exports.isVIN = exports.isMoney = exports.isDate = exports.isPhone = exports.isEmail = exports.isName = exports.SQL_DATE = exports.UUID = exports.VIN = void 0;
6
+ exports.isCreditCardType = exports.isExpirationDate = exports.isCreditCardNumber = exports.isService = exports.isDivision = exports.isClass = exports.isRepair = exports.isPartNumber = exports.isPartName = exports.isBody = exports.isHead = exports.isMessage = exports.isCode = exports.isID = exports.isVIN = exports.isMoney = exports.isDate = exports.isPhone = exports.isEmail = exports.isName = exports.isBit = exports.isUUIDArray = exports.isUUID = exports.isIntegerArray = exports.isInteger = exports.hasLength = exports.SQL_DATE = exports.VIN = void 0;
7
7
  const zod_1 = require("zod");
8
8
  const validator_1 = __importDefault(require("validator"));
9
9
  exports.VIN = /^[A-HJ-NPR-Z0-9]{17}$/;
10
- exports.UUID = /^[A-Z0-9]{8}-[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{12}$/;
11
10
  exports.SQL_DATE = /^[0-9]{4}-[0-9]{2}-[0-9]{2} [0-9]{2}:[0-9]{2}(:[0-9]{2}$|:[0-9]{2}.[0-9]{3}$)/;
12
- exports.isName = zod_1.z.string().trim().min(2, "Must enter a name.").max(50, "Must enter a name less than 50 characters.").regex(/^[A-Za-z\s'-]*$/, "Must enter a name without symbols.").transform(s => {
13
- return s
14
- .replace(/\s+/g, ' ')
15
- .split(/\s/)
16
- .filter(w => w.length > 0)
17
- .map(w => w[0].toUpperCase() + w.slice(1).toLowerCase())
18
- .join(" ");
19
- });
20
- exports.isEmail = zod_1.z.email("Must enter a valid email.").trim().toLowerCase().max(320, "Must enter a valid email.");
21
- exports.isPhone = zod_1.z.string().trim().refine(s => {
22
- const hasFormat = !!s.match(/[0-9]{3}-[0-9]{3}-[0-9]{4}/);
23
- const isMobilePhone = validator_1.default.isMobilePhone("1" + s.replaceAll("-", ""), "en-US");
24
- return hasFormat && isMobilePhone;
25
- }, "Must enter a valid phone number in the format 123-456-7890.");
26
- exports.isDate = zod_1.z.string().trim().regex(/^[0-9]{4}-[0-9]{2}-[0-9]{2} [0-9]{2}:[0-9]{2}(:[0-9]{2}$|:[0-9]{2}.[0-9]{3}$)/, "Must enter a valid date.");
27
- exports.isMoney = zod_1.z.coerce.number("Must enter a valid value.");
28
- exports.isVIN = zod_1.z.string().trim().regex(/^[A-HJ-NPR-Z0-9]{17}$/, "Must enter a valid VIN.");
29
- exports.isInteger = zod_1.z.coerce.number().int();
30
- exports.isIntegerArray = zod_1.z.array(zod_1.z.coerce.number().int());
31
- exports.isUUID = zod_1.z.uuid("Must enter a valid ID.");
32
- exports.isUUIDArray = zod_1.z.array(zod_1.z.string()).refine(ids => ids.every(id => !!id.match(exports.UUID)));
33
- exports.isBit = zod_1.z.enum(["0, 1"], "Must enter a '0' or '1'.");
34
- exports.isID = zod_1.z.union([
35
- zod_1.z.literal(""),
36
- zod_1.z.coerce.number().int()
37
- ]);
38
- const hasLengthAndClean = (data) => {
11
+ const hasLength = (data) => {
39
12
  return zod_1.z
40
13
  .string()
41
14
  .trim()
@@ -44,39 +17,101 @@ const hasLengthAndClean = (data) => {
44
17
  .transform(s => s.replace(/\s+/g, ' '))
45
18
  .refine(s => s.length > 0, `Must enter a ${data.name}.`);
46
19
  };
47
- exports.hasLengthAndClean = hasLengthAndClean;
48
- exports.isCode = (0, exports.hasLengthAndClean)({
20
+ exports.hasLength = hasLength;
21
+ exports.isInteger = zod_1.z.coerce.number().int();
22
+ exports.isIntegerArray = zod_1.z.array(zod_1.z.coerce.number().int());
23
+ exports.isUUID = zod_1.z.uuid("Must enter a valid ID.");
24
+ exports.isUUIDArray = zod_1.z.array(zod_1.z.uuid());
25
+ exports.isBit = zod_1.z.enum(["0, 1"], "Must enter a '0' or '1'.");
26
+ exports.isName = zod_1.z.string()
27
+ .trim()
28
+ .min(2, "Must enter a name.")
29
+ .max(50, "Must enter a name less than 50 characters.")
30
+ .regex(/^[A-Za-z\s'-]*$/, "Must enter a name without symbols.")
31
+ .transform(s => s
32
+ .replace(/\s+/g, ' ')
33
+ .split(/\s/)
34
+ .filter(w => w.length > 0)
35
+ .map(w => w[0].toUpperCase() + w.slice(1).toLowerCase())
36
+ .join(" "))
37
+ .refine(s => s.length > 0, "Must enter a name.");
38
+ exports.isEmail = zod_1.z.email("Must enter a valid email.")
39
+ .trim()
40
+ .toLowerCase()
41
+ .max(320, "Must enter a valid email.");
42
+ exports.isPhone = zod_1.z.string()
43
+ .trim()
44
+ .refine(s => {
45
+ const hasFormat = !!s.match(/[0-9]{3}-[0-9]{3}-[0-9]{4}/);
46
+ const isMobilePhone = validator_1.default.isMobilePhone("1" + s.replaceAll("-", ""), "en-US");
47
+ return hasFormat && isMobilePhone;
48
+ }, "Must enter a valid phone number in the format 123-456-7890.");
49
+ exports.isDate = zod_1.z.string()
50
+ .trim()
51
+ .regex(exports.SQL_DATE, "Must enter a valid date.");
52
+ exports.isMoney = zod_1.z
53
+ .coerce
54
+ .number("Must enter a valid value.");
55
+ exports.isVIN = zod_1.z.string()
56
+ .trim()
57
+ .regex(exports.VIN, "Must enter a valid VIN.");
58
+ exports.isID = zod_1.z.union([
59
+ zod_1.z.literal(""),
60
+ zod_1.z.coerce.number().int()
61
+ ]);
62
+ exports.isCode = (0, exports.hasLength)({
49
63
  min: 1,
50
64
  max: 100,
51
65
  name: "code"
52
66
  });
53
- exports.isMessage = (0, exports.hasLengthAndClean)({
67
+ exports.isMessage = (0, exports.hasLength)({
54
68
  min: 1,
55
69
  max: 500,
56
70
  name: "message"
57
71
  });
58
- exports.isHead = (0, exports.hasLengthAndClean)({
72
+ exports.isHead = (0, exports.hasLength)({
59
73
  min: 1,
60
74
  max: 100,
61
75
  name: "value"
62
76
  });
63
- exports.isBody = (0, exports.hasLengthAndClean)({
77
+ exports.isBody = (0, exports.hasLength)({
64
78
  min: 1,
65
79
  max: 500,
66
80
  name: "value"
67
81
  });
68
- exports.isPartName = (0, exports.hasLengthAndClean)({
82
+ exports.isPartName = (0, exports.hasLength)({
69
83
  min: 1,
70
84
  max: 100,
71
85
  name: "name"
72
86
  });
73
- exports.isPartNumber = (0, exports.hasLengthAndClean)({
87
+ exports.isPartNumber = (0, exports.hasLength)({
74
88
  min: 1,
75
89
  max: 100,
76
90
  name: "name"
77
91
  });
78
- exports.isCreditCardNumber = zod_1.z.string().trim().refine(s => {
79
- const validLength = s.length >= 13 && s.length <= 16;
92
+ exports.isRepair = (0, exports.hasLength)({
93
+ min: 1,
94
+ max: 500,
95
+ name: "repair"
96
+ });
97
+ exports.isClass = (0, exports.hasLength)({
98
+ min: 1,
99
+ max: 500,
100
+ name: "repair"
101
+ });
102
+ exports.isDivision = (0, exports.hasLength)({
103
+ min: 1,
104
+ max: 50,
105
+ name: "value"
106
+ });
107
+ exports.isService = (0, exports.hasLength)({
108
+ min: 1,
109
+ max: 50,
110
+ name: "value"
111
+ });
112
+ exports.isCreditCardNumber = zod_1.z.string()
113
+ .trim()
114
+ .refine(s => {
80
115
  const providers = ["visa", "amex", "mastercard"];
81
116
  let validCreditCardNumber = false;
82
117
  for (const provider of providers) {
@@ -86,9 +121,12 @@ exports.isCreditCardNumber = zod_1.z.string().trim().refine(s => {
86
121
  break;
87
122
  }
88
123
  }
89
- return validLength && validCreditCardNumber;
124
+ return (s.length >= 13 && s.length <= 16) && validCreditCardNumber;
90
125
  }, "Must enter a valid credit card number.");
91
- exports.isExpirationDate = zod_1.z.string().trim().regex(/^(0[1-9]|1[0-2])[0-9]{2}$/, "Must enter a valid expiration date.").refine(s => {
126
+ exports.isExpirationDate = zod_1.z.string()
127
+ .trim()
128
+ .regex(/^(0[1-9]|1[0-2])[0-9]{2}$/, "Must enter a valid expiration date.")
129
+ .refine(s => {
92
130
  const month = parseInt(s.substring(0, 2));
93
131
  const year = 2000 + parseInt(s.substring(2, 4));
94
132
  const now = new Date();
@@ -100,29 +138,4 @@ exports.isExpirationDate = zod_1.z.string().trim().regex(/^(0[1-9]|1[0-2])[0-9]{
100
138
  return month >= currentMonth;
101
139
  return false;
102
140
  }, "Card has expired.");
103
- ;
104
- exports.isCreditCardType = zod_1.z.enum([
105
- 'VISA',
106
- 'MASTERCARD',
107
- 'AMEX'
108
- ]);
109
- exports.isRepair = (0, exports.hasLengthAndClean)({
110
- min: 1,
111
- max: 500,
112
- name: "repair"
113
- });
114
- exports.isClass = (0, exports.hasLengthAndClean)({
115
- min: 1,
116
- max: 500,
117
- name: "repair"
118
- });
119
- exports.isDivision = (0, exports.hasLengthAndClean)({
120
- min: 1,
121
- max: 50,
122
- name: "value"
123
- });
124
- exports.isService = (0, exports.hasLengthAndClean)({
125
- min: 1,
126
- max: 50,
127
- name: "value"
128
- });
141
+ exports.isCreditCardType = zod_1.z.enum(['VISA', 'MASTERCARD', 'AMEX'], "Must use one of the following cards: (VISA, MASTERVARD, AMEX)");
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export * from "./Appointment";
2
- export * from "./AppointmentList";
2
+ export * from "./AppointmentsTable";
3
3
  export * from "./Diagnosis";
4
4
  export * from "./Employee";
5
5
  export * from "./Event";
package/dist/index.js CHANGED
@@ -15,7 +15,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./Appointment"), exports);
18
- __exportStar(require("./AppointmentList"), exports);
18
+ __exportStar(require("./AppointmentsTable"), exports);
19
19
  __exportStar(require("./Diagnosis"), exports);
20
20
  __exportStar(require("./Employee"), exports);
21
21
  __exportStar(require("./Event"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "waltronics-types",
3
- "version": "1.0.14",
3
+ "version": "1.0.16",
4
4
  "description": "Contains the types used in the Waltronics application.",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",