truflow 0.0.140 → 0.0.142
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.
- package/dist/IAllmoxy.d.ts +2 -2
- package/dist/IOrder.d.ts +2 -3
- package/package.json +15 -15
- package/src/API/Allmoxy/IAnnouncement.ts +41 -41
- package/src/API/Allmoxy/ICompany.ts +199 -199
- package/src/API/Allmoxy/IGeneric.ts +111 -111
- package/src/API/Allmoxy/IInventoryItem.ts +56 -56
- package/src/API/Allmoxy/IInventoryOrder.ts +43 -43
- package/src/API/Allmoxy/ILocation.ts +19 -19
- package/src/API/Allmoxy/IOrder.ts +89 -89
- package/src/API/Allmoxy/IOrderProductItems.ts +92 -92
- package/src/API/Allmoxy/IOrderProducts.ts +46 -46
- package/src/API/Allmoxy/IProduct.ts +88 -88
- package/src/API/Allmoxy/IProductAttribute.ts +21 -21
- package/src/API/Allmoxy/IProductAttributeOptions.ts +30 -30
- package/src/API/Allmoxy/IProductProductAttribute.ts +23 -23
- package/src/API/Allmoxy/ITrigger.ts +52 -52
- package/src/API/Allmoxy/index.ts +14 -14
- package/src/Classes/ICRUDRouter.ts +6 -6
- package/src/Classes/ILogger.ts +17 -17
- package/src/Events/IDateEntryMoved.ts +13 -13
- package/src/Events/INegativeValue.ts +10 -10
- package/src/Events/IOrderDetails.ts +12 -12
- package/src/Events/IOrderMoved.ts +14 -14
- package/src/Events/IOrderProcessed.ts +6 -6
- package/src/Helpers/IAdministration.ts +9 -9
- package/src/Helpers/IAllmoxy.ts +4 -4
- package/src/Helpers/IEvents.ts +23 -23
- package/src/Helpers/IExporters.ts +45 -45
- package/src/Helpers/IOrders/IMoveDateEntry.ts +21 -21
- package/src/Helpers/IOrders/IMoveOrder.ts +28 -28
- package/src/Helpers/IOrders/IUpdateFullDailyTotal.ts +13 -13
- package/src/Helpers/IOrders/IUpdateIndividualDailyTotal.ts +8 -8
- package/src/Helpers/IOrders/index.ts +10 -10
- package/src/Helpers/ITotals.ts +16 -16
- package/src/Helpers/IZapier/index.ts +54 -54
- package/src/IAllmoxy.ts +12 -12
- package/src/IConfig.ts +11 -11
- package/src/IDailyTotal.ts +9 -9
- package/src/IEvent.ts +21 -21
- package/src/IExporter.ts +20 -20
- package/src/IExpress.ts +14 -14
- package/src/IIntegration.ts +30 -30
- package/src/IJWT.ts +4 -4
- package/src/IMailCache.ts +19 -19
- package/src/INotification.ts +11 -11
- package/src/IOrder.ts +41 -42
- package/src/IScript.ts +10 -10
- package/src/ISetting.ts +83 -83
- package/src/IUser.ts +13 -13
- package/src/IWebsocket.ts +7 -7
- package/src/Routes/IOrderRoutes.ts +37 -37
- package/src/Routes/IZapierRoutes.ts +12 -12
- package/src/Templates/IDailyTotals.ts +4 -4
- package/src/index.ts +28 -28
- package/tsconfig.json +11 -11
package/src/ISetting.ts
CHANGED
|
@@ -1,83 +1,83 @@
|
|
|
1
|
-
import mongoose, { Document } from "mongoose";
|
|
2
|
-
|
|
3
|
-
export interface ILeanSetting {
|
|
4
|
-
_id: mongoose.Types.ObjectId;
|
|
5
|
-
modifiedAt: string;
|
|
6
|
-
_type: string;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
export interface ILeanAPIToken extends ILeanSetting {
|
|
10
|
-
name: string;
|
|
11
|
-
token: string;
|
|
12
|
-
permissions: string[];
|
|
13
|
-
expiry: string;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export interface ILeanGroup extends ILeanSetting {
|
|
17
|
-
name: string;
|
|
18
|
-
permissions: string[];
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export interface ILeanHoliday extends ILeanSetting {
|
|
22
|
-
title: string;
|
|
23
|
-
date: string;
|
|
24
|
-
recurring?: boolean;
|
|
25
|
-
recurs?: string;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export interface ILeanLimit extends ILeanSetting {
|
|
29
|
-
name: string;
|
|
30
|
-
rpd: string;
|
|
31
|
-
limit: string;
|
|
32
|
-
enabled: boolean;
|
|
33
|
-
products?: string[];
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
export interface ILeanOrderFlag extends ILeanSetting {
|
|
37
|
-
name: string;
|
|
38
|
-
highlightColor: string;
|
|
39
|
-
products?: string[];
|
|
40
|
-
tags?: string[];
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export interface ILeanSorting extends ILeanSetting {
|
|
44
|
-
headerList?: string[];
|
|
45
|
-
itemList: string[];
|
|
46
|
-
usage: "totals-groups" | "limits";
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
export interface ICalculation {
|
|
50
|
-
action: "add" | "subtract";
|
|
51
|
-
source: string;
|
|
52
|
-
calculation: "add" | "subtract" | "current";
|
|
53
|
-
days: string;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
export interface ILeanTotalsGroup extends ILeanSetting {
|
|
57
|
-
name: string;
|
|
58
|
-
identifier: string;
|
|
59
|
-
calculations?: ICalculation[];
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
export interface ILeanKeyValue extends ILeanSetting {
|
|
63
|
-
key: string;
|
|
64
|
-
value: string;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export type ISetting = ILeanSetting & Document;
|
|
68
|
-
|
|
69
|
-
export type IAPIToken = ILeanAPIToken & Document;
|
|
70
|
-
|
|
71
|
-
export type IGroup = ILeanGroup & Document;
|
|
72
|
-
|
|
73
|
-
export type IHoliday = ILeanHoliday & Document;
|
|
74
|
-
|
|
75
|
-
export type ILimit = ILeanLimit & Document;
|
|
76
|
-
|
|
77
|
-
export type IOrderFlag = ILeanOrderFlag & Document;
|
|
78
|
-
|
|
79
|
-
export type ISorting = ILeanSorting & Document;
|
|
80
|
-
|
|
81
|
-
export type ITotalsGroup = ILeanTotalsGroup & Document;
|
|
82
|
-
|
|
83
|
-
export type IKeyValue = ILeanKeyValue & Document;
|
|
1
|
+
import mongoose, { Document } from "mongoose";
|
|
2
|
+
|
|
3
|
+
export interface ILeanSetting {
|
|
4
|
+
_id: mongoose.Types.ObjectId;
|
|
5
|
+
modifiedAt: string;
|
|
6
|
+
_type: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export interface ILeanAPIToken extends ILeanSetting {
|
|
10
|
+
name: string;
|
|
11
|
+
token: string;
|
|
12
|
+
permissions: string[];
|
|
13
|
+
expiry: string;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export interface ILeanGroup extends ILeanSetting {
|
|
17
|
+
name: string;
|
|
18
|
+
permissions: string[];
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface ILeanHoliday extends ILeanSetting {
|
|
22
|
+
title: string;
|
|
23
|
+
date: string;
|
|
24
|
+
recurring?: boolean;
|
|
25
|
+
recurs?: string;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface ILeanLimit extends ILeanSetting {
|
|
29
|
+
name: string;
|
|
30
|
+
rpd: string;
|
|
31
|
+
limit: string;
|
|
32
|
+
enabled: boolean;
|
|
33
|
+
products?: string[];
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface ILeanOrderFlag extends ILeanSetting {
|
|
37
|
+
name: string;
|
|
38
|
+
highlightColor: string;
|
|
39
|
+
products?: string[];
|
|
40
|
+
tags?: string[];
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export interface ILeanSorting extends ILeanSetting {
|
|
44
|
+
headerList?: string[];
|
|
45
|
+
itemList: string[];
|
|
46
|
+
usage: "totals-groups" | "limits";
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface ICalculation {
|
|
50
|
+
action: "add" | "subtract";
|
|
51
|
+
source: string;
|
|
52
|
+
calculation: "add" | "subtract" | "current";
|
|
53
|
+
days: string;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export interface ILeanTotalsGroup extends ILeanSetting {
|
|
57
|
+
name: string;
|
|
58
|
+
identifier: string;
|
|
59
|
+
calculations?: ICalculation[];
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export interface ILeanKeyValue extends ILeanSetting {
|
|
63
|
+
key: string;
|
|
64
|
+
value: string;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export type ISetting = ILeanSetting & Document;
|
|
68
|
+
|
|
69
|
+
export type IAPIToken = ILeanAPIToken & Document;
|
|
70
|
+
|
|
71
|
+
export type IGroup = ILeanGroup & Document;
|
|
72
|
+
|
|
73
|
+
export type IHoliday = ILeanHoliday & Document;
|
|
74
|
+
|
|
75
|
+
export type ILimit = ILeanLimit & Document;
|
|
76
|
+
|
|
77
|
+
export type IOrderFlag = ILeanOrderFlag & Document;
|
|
78
|
+
|
|
79
|
+
export type ISorting = ILeanSorting & Document;
|
|
80
|
+
|
|
81
|
+
export type ITotalsGroup = ILeanTotalsGroup & Document;
|
|
82
|
+
|
|
83
|
+
export type IKeyValue = ILeanKeyValue & Document;
|
package/src/IUser.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import mongoose, { Document } from "mongoose";
|
|
2
|
-
|
|
3
|
-
export type IUser = ILeanUser & Document;
|
|
4
|
-
|
|
5
|
-
export interface ILeanUser {
|
|
6
|
-
_id: mongoose.Types.ObjectId;
|
|
7
|
-
firstName: string;
|
|
8
|
-
lastName: string;
|
|
9
|
-
email: string;
|
|
10
|
-
password: string;
|
|
11
|
-
permissions: any[];
|
|
12
|
-
groups: any[];
|
|
13
|
-
}
|
|
1
|
+
import mongoose, { Document } from "mongoose";
|
|
2
|
+
|
|
3
|
+
export type IUser = ILeanUser & Document;
|
|
4
|
+
|
|
5
|
+
export interface ILeanUser {
|
|
6
|
+
_id: mongoose.Types.ObjectId;
|
|
7
|
+
firstName: string;
|
|
8
|
+
lastName: string;
|
|
9
|
+
email: string;
|
|
10
|
+
password: string;
|
|
11
|
+
permissions: any[];
|
|
12
|
+
groups: any[];
|
|
13
|
+
}
|
package/src/IWebsocket.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ILeanMailCache } from "./IMailCache";
|
|
2
|
-
|
|
3
|
-
export interface IPendingOperation {
|
|
4
|
-
exporterID: string;
|
|
5
|
-
mailCacheID: string;
|
|
6
|
-
email: ILeanMailCache;
|
|
7
|
-
}
|
|
1
|
+
import { ILeanMailCache } from "./IMailCache";
|
|
2
|
+
|
|
3
|
+
export interface IPendingOperation {
|
|
4
|
+
exporterID: string;
|
|
5
|
+
mailCacheID: string;
|
|
6
|
+
email: ILeanMailCache;
|
|
7
|
+
}
|
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
// TODO: dissect data pased from move order and date entry
|
|
2
|
-
// create specific types for both varietes of req.body input
|
|
3
|
-
|
|
4
|
-
export interface IOrderEntry {
|
|
5
|
-
id: string;
|
|
6
|
-
orderID: number;
|
|
7
|
-
name: string;
|
|
8
|
-
companyName: string;
|
|
9
|
-
quantity: number;
|
|
10
|
-
type: string;
|
|
11
|
-
startDate: string;
|
|
12
|
-
shipDate: string;
|
|
13
|
-
highlight: boolean;
|
|
14
|
-
rpd: number;
|
|
15
|
-
highlightColor: string | null;
|
|
16
|
-
hasStarted: boolean;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
export interface IUpdateOrderOld {
|
|
20
|
-
id: string;
|
|
21
|
-
orderID: number;
|
|
22
|
-
startDate: string;
|
|
23
|
-
updatedStartDate: string;
|
|
24
|
-
shipDate: string;
|
|
25
|
-
applyToOrder: boolean;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export interface IUpdateOrder {
|
|
29
|
-
id: string;
|
|
30
|
-
orderID: number;
|
|
31
|
-
quantity: number;
|
|
32
|
-
type: string;
|
|
33
|
-
startDate: string;
|
|
34
|
-
shipDate: string;
|
|
35
|
-
updatedStartDate: string;
|
|
36
|
-
applyToOrder: boolean;
|
|
37
|
-
}
|
|
1
|
+
// TODO: dissect data pased from move order and date entry
|
|
2
|
+
// create specific types for both varietes of req.body input
|
|
3
|
+
|
|
4
|
+
export interface IOrderEntry {
|
|
5
|
+
id: string;
|
|
6
|
+
orderID: number;
|
|
7
|
+
name: string;
|
|
8
|
+
companyName: string;
|
|
9
|
+
quantity: number;
|
|
10
|
+
type: string;
|
|
11
|
+
startDate: string;
|
|
12
|
+
shipDate: string;
|
|
13
|
+
highlight: boolean;
|
|
14
|
+
rpd: number;
|
|
15
|
+
highlightColor: string | null;
|
|
16
|
+
hasStarted: boolean;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export interface IUpdateOrderOld {
|
|
20
|
+
id: string;
|
|
21
|
+
orderID: number;
|
|
22
|
+
startDate: string;
|
|
23
|
+
updatedStartDate: string;
|
|
24
|
+
shipDate: string;
|
|
25
|
+
applyToOrder: boolean;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface IUpdateOrder {
|
|
29
|
+
id: string;
|
|
30
|
+
orderID: number;
|
|
31
|
+
quantity: number;
|
|
32
|
+
type: string;
|
|
33
|
+
startDate: string;
|
|
34
|
+
shipDate: string;
|
|
35
|
+
updatedStartDate: string;
|
|
36
|
+
applyToOrder: boolean;
|
|
37
|
+
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export interface IZapierOrder {
|
|
2
|
-
id: number;
|
|
3
|
-
name: string;
|
|
4
|
-
companyName: string;
|
|
5
|
-
date: string;
|
|
6
|
-
shipDate: string;
|
|
7
|
-
requestedShipDate: string;
|
|
8
|
-
companyID: number;
|
|
9
|
-
summary: string;
|
|
10
|
-
orderTags: string;
|
|
11
|
-
companyTags: string;
|
|
12
|
-
}
|
|
1
|
+
export interface IZapierOrder {
|
|
2
|
+
id: number;
|
|
3
|
+
name: string;
|
|
4
|
+
companyName: string;
|
|
5
|
+
date: string;
|
|
6
|
+
shipDate: string;
|
|
7
|
+
requestedShipDate: string;
|
|
8
|
+
companyID: number;
|
|
9
|
+
summary: string;
|
|
10
|
+
orderTags: string;
|
|
11
|
+
companyTags: string;
|
|
12
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export interface IDailyTotalsSchema {
|
|
2
|
-
type: typeof Number;
|
|
3
|
-
required: boolean;
|
|
4
|
-
}
|
|
1
|
+
export interface IDailyTotalsSchema {
|
|
2
|
+
type: typeof Number;
|
|
3
|
+
required: boolean;
|
|
4
|
+
}
|
package/src/index.ts
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
export * from "./IOrder";
|
|
2
|
-
export * from "./IExporter";
|
|
3
|
-
export * from "./IScript";
|
|
4
|
-
export * from "./IUser";
|
|
5
|
-
export * from "./IEvent";
|
|
6
|
-
export * from "./IDailyTotal";
|
|
7
|
-
export * from "./ISetting";
|
|
8
|
-
export * from "./IJWT";
|
|
9
|
-
export * from "./IExpress";
|
|
10
|
-
export * from "./IConfig";
|
|
11
|
-
export * from "./IWebsocket";
|
|
12
|
-
export * from "./Routes/IOrderRoutes";
|
|
13
|
-
export * from "./Helpers/IOrders";
|
|
14
|
-
export * from "./Helpers/IEvents";
|
|
15
|
-
export * from "./Helpers/IExporters";
|
|
16
|
-
export * from "./Helpers/ITotals";
|
|
17
|
-
export * from "./Helpers/IAdministration";
|
|
18
|
-
export * from "./Helpers/IZapier";
|
|
19
|
-
export * from "./Classes/ICRUDRouter";
|
|
20
|
-
export * from "./Classes/ILogger";
|
|
21
|
-
export * from "./Templates/IDailyTotals";
|
|
22
|
-
export * from "./Routes/IZapierRoutes";
|
|
23
|
-
export * from "./IIntegration";
|
|
24
|
-
export * from "./INotification";
|
|
25
|
-
export * from "./Helpers/IAllmoxy";
|
|
26
|
-
export * from "./IMailCache";
|
|
27
|
-
export * from "./API/Allmoxy";
|
|
28
|
-
export * from "./IAllmoxy";
|
|
1
|
+
export * from "./IOrder";
|
|
2
|
+
export * from "./IExporter";
|
|
3
|
+
export * from "./IScript";
|
|
4
|
+
export * from "./IUser";
|
|
5
|
+
export * from "./IEvent";
|
|
6
|
+
export * from "./IDailyTotal";
|
|
7
|
+
export * from "./ISetting";
|
|
8
|
+
export * from "./IJWT";
|
|
9
|
+
export * from "./IExpress";
|
|
10
|
+
export * from "./IConfig";
|
|
11
|
+
export * from "./IWebsocket";
|
|
12
|
+
export * from "./Routes/IOrderRoutes";
|
|
13
|
+
export * from "./Helpers/IOrders";
|
|
14
|
+
export * from "./Helpers/IEvents";
|
|
15
|
+
export * from "./Helpers/IExporters";
|
|
16
|
+
export * from "./Helpers/ITotals";
|
|
17
|
+
export * from "./Helpers/IAdministration";
|
|
18
|
+
export * from "./Helpers/IZapier";
|
|
19
|
+
export * from "./Classes/ICRUDRouter";
|
|
20
|
+
export * from "./Classes/ILogger";
|
|
21
|
+
export * from "./Templates/IDailyTotals";
|
|
22
|
+
export * from "./Routes/IZapierRoutes";
|
|
23
|
+
export * from "./IIntegration";
|
|
24
|
+
export * from "./INotification";
|
|
25
|
+
export * from "./Helpers/IAllmoxy";
|
|
26
|
+
export * from "./IMailCache";
|
|
27
|
+
export * from "./API/Allmoxy";
|
|
28
|
+
export * from "./IAllmoxy";
|
package/tsconfig.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"target": "es5",
|
|
4
|
-
"module": "commonjs",
|
|
5
|
-
"declaration": true,
|
|
6
|
-
"outDir": "./dist",
|
|
7
|
-
"strict": true
|
|
8
|
-
},
|
|
9
|
-
"include": ["src"],
|
|
10
|
-
"exclude": ["node_modules"]
|
|
11
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "es5",
|
|
4
|
+
"module": "commonjs",
|
|
5
|
+
"declaration": true,
|
|
6
|
+
"outDir": "./dist",
|
|
7
|
+
"strict": true
|
|
8
|
+
},
|
|
9
|
+
"include": ["src"],
|
|
10
|
+
"exclude": ["node_modules"]
|
|
11
|
+
}
|