@fabriktor/client 0.0.34 → 0.0.35
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/src/billable/billable.d.ts +1 -25
- package/dist/src/billable/billable.js +0 -36
- package/dist/src/calls/calls.d.ts +1 -3
- package/dist/src/calls/calls.js +0 -3
- package/dist/src/chat/chat.d.ts +6 -23
- package/dist/src/chat/chat.js +2 -34
- package/dist/src/core/crud.d.ts +0 -5
- package/dist/src/core/crud.js +0 -14
- package/dist/src/feed/feed.d.ts +1 -7
- package/dist/src/feed/feed.js +0 -9
- package/dist/src/fulfillments/fulfillments.d.ts +1 -3
- package/dist/src/fulfillments/fulfillments.js +0 -3
- package/dist/src/jobs/jobs.d.ts +1 -7
- package/dist/src/jobs/jobs.js +0 -9
- package/dist/src/marketplace/marketplace.d.ts +1 -5
- package/dist/src/marketplace/marketplace.js +0 -6
- package/dist/src/memos/memos.d.ts +1 -5
- package/dist/src/memos/memos.js +0 -6
- package/dist/src/payments/payments.d.ts +1 -17
- package/dist/src/payments/payments.js +0 -24
- package/dist/src/payrolls/payrolls.d.ts +1 -21
- package/dist/src/payrolls/payrolls.js +0 -30
- package/dist/src/preferences/preferences.d.ts +1 -19
- package/dist/src/preferences/preferences.js +0 -27
- package/dist/src/privacy/privacy.d.ts +1 -5
- package/dist/src/privacy/privacy.js +0 -6
- package/dist/src/routes/routes.d.ts +1 -11
- package/dist/src/routes/routes.js +0 -15
- package/dist/src/storage/storage.d.ts +1 -23
- package/dist/src/storage/storage.js +0 -33
- package/dist/src/timesheets/timesheets.d.ts +1 -5
- package/dist/src/timesheets/timesheets.js +0 -6
- package/package.json +1 -1
|
@@ -73,9 +73,6 @@ export class StorageClient {
|
|
|
73
73
|
async deleteOne(col, opts) {
|
|
74
74
|
return await this.object(col).deleteOne(opts);
|
|
75
75
|
}
|
|
76
|
-
async deleteMany(col, opts) {
|
|
77
|
-
return await this.object(col).deleteMany(opts);
|
|
78
|
-
}
|
|
79
76
|
async uploadCalls(opts) {
|
|
80
77
|
return await this.upload(ColStorageCalls, opts);
|
|
81
78
|
}
|
|
@@ -85,9 +82,6 @@ export class StorageClient {
|
|
|
85
82
|
async deleteOneCallObject(opts) {
|
|
86
83
|
return await this.deleteOne(ColStorageCalls, opts);
|
|
87
84
|
}
|
|
88
|
-
async deleteManyCallObjects(opts) {
|
|
89
|
-
return await this.deleteMany(ColStorageCalls, opts);
|
|
90
|
-
}
|
|
91
85
|
async uploadChat(opts) {
|
|
92
86
|
return await this.upload(ColStorageChat, opts);
|
|
93
87
|
}
|
|
@@ -97,9 +91,6 @@ export class StorageClient {
|
|
|
97
91
|
async deleteOneChatObject(opts) {
|
|
98
92
|
return await this.deleteOne(ColStorageChat, opts);
|
|
99
93
|
}
|
|
100
|
-
async deleteManyChatObjects(opts) {
|
|
101
|
-
return await this.deleteMany(ColStorageChat, opts);
|
|
102
|
-
}
|
|
103
94
|
async uploadContacts(opts) {
|
|
104
95
|
return await this.upload(ColStorageContacts, opts);
|
|
105
96
|
}
|
|
@@ -109,9 +100,6 @@ export class StorageClient {
|
|
|
109
100
|
async deleteOneContactObject(opts) {
|
|
110
101
|
return await this.deleteOne(ColStorageContacts, opts);
|
|
111
102
|
}
|
|
112
|
-
async deleteManyContactObjects(opts) {
|
|
113
|
-
return await this.deleteMany(ColStorageContacts, opts);
|
|
114
|
-
}
|
|
115
103
|
async uploadJobs(opts) {
|
|
116
104
|
return await this.upload(ColStorageJobs, opts);
|
|
117
105
|
}
|
|
@@ -121,9 +109,6 @@ export class StorageClient {
|
|
|
121
109
|
async deleteOneJobObject(opts) {
|
|
122
110
|
return await this.deleteOne(ColStorageJobs, opts);
|
|
123
111
|
}
|
|
124
|
-
async deleteManyJobObjects(opts) {
|
|
125
|
-
return await this.deleteMany(ColStorageJobs, opts);
|
|
126
|
-
}
|
|
127
112
|
async uploadLocations(opts) {
|
|
128
113
|
return await this.upload(ColStorageLocations, opts);
|
|
129
114
|
}
|
|
@@ -133,9 +118,6 @@ export class StorageClient {
|
|
|
133
118
|
async deleteOneLocationObject(opts) {
|
|
134
119
|
return await this.deleteOne(ColStorageLocations, opts);
|
|
135
120
|
}
|
|
136
|
-
async deleteManyLocationObjects(opts) {
|
|
137
|
-
return await this.deleteMany(ColStorageLocations, opts);
|
|
138
|
-
}
|
|
139
121
|
async uploadMemos(opts) {
|
|
140
122
|
return await this.upload(ColStorageMemos, opts);
|
|
141
123
|
}
|
|
@@ -145,9 +127,6 @@ export class StorageClient {
|
|
|
145
127
|
async deleteOneMemoObject(opts) {
|
|
146
128
|
return await this.deleteOne(ColStorageMemos, opts);
|
|
147
129
|
}
|
|
148
|
-
async deleteManyMemoObjects(opts) {
|
|
149
|
-
return await this.deleteMany(ColStorageMemos, opts);
|
|
150
|
-
}
|
|
151
130
|
async uploadQR(opts) {
|
|
152
131
|
return await this.upload(ColStorageQR, opts);
|
|
153
132
|
}
|
|
@@ -157,9 +136,6 @@ export class StorageClient {
|
|
|
157
136
|
async deleteOneQRObject(opts) {
|
|
158
137
|
return await this.deleteOne(ColStorageQR, opts);
|
|
159
138
|
}
|
|
160
|
-
async deleteManyQRObjects(opts) {
|
|
161
|
-
return await this.deleteMany(ColStorageQR, opts);
|
|
162
|
-
}
|
|
163
139
|
async uploadReports(opts) {
|
|
164
140
|
return await this.upload(ColStorageReports, opts);
|
|
165
141
|
}
|
|
@@ -169,9 +145,6 @@ export class StorageClient {
|
|
|
169
145
|
async deleteOneReportObject(opts) {
|
|
170
146
|
return await this.deleteOne(ColStorageReports, opts);
|
|
171
147
|
}
|
|
172
|
-
async deleteManyReportObjects(opts) {
|
|
173
|
-
return await this.deleteMany(ColStorageReports, opts);
|
|
174
|
-
}
|
|
175
148
|
async uploadTickets(opts) {
|
|
176
149
|
return await this.upload(ColStorageTickets, opts);
|
|
177
150
|
}
|
|
@@ -181,9 +154,6 @@ export class StorageClient {
|
|
|
181
154
|
async deleteOneTicketObject(opts) {
|
|
182
155
|
return await this.deleteOne(ColStorageTickets, opts);
|
|
183
156
|
}
|
|
184
|
-
async deleteManyTicketObjects(opts) {
|
|
185
|
-
return await this.deleteMany(ColStorageTickets, opts);
|
|
186
|
-
}
|
|
187
157
|
async uploadUsers(opts) {
|
|
188
158
|
return await this.upload(ColStorageUsers, opts);
|
|
189
159
|
}
|
|
@@ -193,9 +163,6 @@ export class StorageClient {
|
|
|
193
163
|
async deleteOneUserObject(opts) {
|
|
194
164
|
return await this.deleteOne(ColStorageUsers, opts);
|
|
195
165
|
}
|
|
196
|
-
async deleteManyUserObjects(opts) {
|
|
197
|
-
return await this.deleteMany(ColStorageUsers, opts);
|
|
198
|
-
}
|
|
199
166
|
object(col) {
|
|
200
167
|
const c = this.objects.get(col);
|
|
201
168
|
if (c === undefined) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type InSummary, type InWeekSheet, type OperationResult, type PLTimesheetsApprove, type PLTimesheetsSync, type Punch, type Summary, type WeekSheet } from "@fabriktor/schema";
|
|
2
2
|
import type { TokenProvider } from "../core/auth.js";
|
|
3
|
-
import type {
|
|
3
|
+
import type { DeleteOneOptionsCRUD, FindOneOptionsCRUD, OperationResultOf, QueryOptionsCRUD, ReplaceOneOptionsCRUD } from "../core/crud.js";
|
|
4
4
|
import type { HTTPDoer } from "../core/http.js";
|
|
5
5
|
export type ApproveTimesheetsOptions = PLTimesheetsApprove;
|
|
6
6
|
export type SyncTimesheetsOptions = PLTimesheetsSync;
|
|
@@ -15,12 +15,10 @@ export interface TimesheetsOperator {
|
|
|
15
15
|
findOneWeekSheet(opts: FindOneOptionsCRUD): Promise<OperationResultOf<WeekSheet>>;
|
|
16
16
|
replaceOneWeekSheet(opts: ReplaceOneOptionsCRUD<InWeekSheet>): Promise<OperationResult>;
|
|
17
17
|
deleteOneWeekSheet(opts: DeleteOneOptionsCRUD): Promise<OperationResult>;
|
|
18
|
-
deleteManyWeekSheets(opts?: DeleteManyOptionsCRUD): Promise<OperationResultOf<number>>;
|
|
19
18
|
querySummaries(opts?: QueryOptionsCRUD): Promise<OperationResultOf<Summary[]>>;
|
|
20
19
|
findOneSummary(opts: FindOneOptionsCRUD): Promise<OperationResultOf<Summary>>;
|
|
21
20
|
replaceOneSummary(opts: ReplaceOneOptionsCRUD<InSummary>): Promise<OperationResult>;
|
|
22
21
|
deleteOneSummary(opts: DeleteOneOptionsCRUD): Promise<OperationResult>;
|
|
23
|
-
deleteManySummaries(opts?: DeleteManyOptionsCRUD): Promise<OperationResultOf<number>>;
|
|
24
22
|
approve(opts: ApproveTimesheetsOptions): Promise<void>;
|
|
25
23
|
sync(opts: SyncTimesheetsOptions): Promise<void>;
|
|
26
24
|
punch(opts: PunchTimesheetOptions): Promise<OperationResult>;
|
|
@@ -36,12 +34,10 @@ export declare class TimesheetsClient implements TimesheetsOperator {
|
|
|
36
34
|
findOneWeekSheet(opts: FindOneOptionsCRUD): Promise<OperationResultOf<WeekSheet>>;
|
|
37
35
|
replaceOneWeekSheet(opts: ReplaceOneOptionsCRUD<InWeekSheet>): Promise<OperationResult>;
|
|
38
36
|
deleteOneWeekSheet(opts: DeleteOneOptionsCRUD): Promise<OperationResult>;
|
|
39
|
-
deleteManyWeekSheets(opts?: DeleteManyOptionsCRUD): Promise<OperationResultOf<number>>;
|
|
40
37
|
querySummaries(opts?: QueryOptionsCRUD): Promise<OperationResultOf<Summary[]>>;
|
|
41
38
|
findOneSummary(opts: FindOneOptionsCRUD): Promise<OperationResultOf<Summary>>;
|
|
42
39
|
replaceOneSummary(opts: ReplaceOneOptionsCRUD<InSummary>): Promise<OperationResult>;
|
|
43
40
|
deleteOneSummary(opts: DeleteOneOptionsCRUD): Promise<OperationResult>;
|
|
44
|
-
deleteManySummaries(opts?: DeleteManyOptionsCRUD): Promise<OperationResultOf<number>>;
|
|
45
41
|
approve(opts: ApproveTimesheetsOptions): Promise<void>;
|
|
46
42
|
sync(opts: SyncTimesheetsOptions): Promise<void>;
|
|
47
43
|
punch(opts: PunchTimesheetOptions): Promise<OperationResult>;
|
|
@@ -44,9 +44,6 @@ export class TimesheetsClient {
|
|
|
44
44
|
async deleteOneWeekSheet(opts) {
|
|
45
45
|
return await this.weeksheets.deleteOne(opts);
|
|
46
46
|
}
|
|
47
|
-
async deleteManyWeekSheets(opts) {
|
|
48
|
-
return await this.weeksheets.deleteMany(opts);
|
|
49
|
-
}
|
|
50
47
|
async querySummaries(opts) {
|
|
51
48
|
return await this.summaries.query(opts);
|
|
52
49
|
}
|
|
@@ -59,9 +56,6 @@ export class TimesheetsClient {
|
|
|
59
56
|
async deleteOneSummary(opts) {
|
|
60
57
|
return await this.summaries.deleteOne(opts);
|
|
61
58
|
}
|
|
62
|
-
async deleteManySummaries(opts) {
|
|
63
|
-
return await this.summaries.deleteMany(opts);
|
|
64
|
-
}
|
|
65
59
|
async approve(opts) {
|
|
66
60
|
const token = await requiredToken(this.get_token);
|
|
67
61
|
return await this.http.do({
|