@smartsides/oracle-ebs-sdk 1.0.6 → 1.0.7
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/README.md +86 -9
- package/dist/{OracleEBSClient-BE9XZUi1.d.mts → OracleEBSClient-C2zQ1MaD.d.mts} +116 -13
- package/dist/{OracleEBSClient-BE9XZUi1.d.ts → OracleEBSClient-C2zQ1MaD.d.ts} +116 -13
- package/dist/hooks/index.d.mts +1 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +36 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +36 -5
- package/dist/index.mjs.map +1 -1
- package/dist/server/index.d.mts +1 -1
- package/dist/server/index.d.ts +1 -1
- package/dist/server/index.js +36 -5
- package/dist/server/index.js.map +1 -1
- package/dist/server/index.mjs +36 -5
- package/dist/server/index.mjs.map +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -6,6 +6,8 @@ TypeScript SDK for Oracle EBS API - Optimized for Next.js 15+
|
|
|
6
6
|
|
|
7
7
|
- ✅ **Full TypeScript Support** - Complete type safety with autocomplete
|
|
8
8
|
- ✅ **All API Endpoints** - 9 modules covering all Oracle EBS functionality
|
|
9
|
+
- ✅ **Auto User Context** - Stores full user object from login automatically
|
|
10
|
+
- ✅ **Smart Defaults** - Employee number auto-extracted for payslip/leave requests
|
|
9
11
|
- ✅ **Error Handling** - Typed errors with automatic retry logic
|
|
10
12
|
- ✅ **React Query Integration** - Built-in hooks for Next.js
|
|
11
13
|
- ✅ **Server Components** - Optimized for Next.js App Router
|
|
@@ -34,16 +36,17 @@ const client = new OracleEBSClient({
|
|
|
34
36
|
logging: { enabled: true },
|
|
35
37
|
});
|
|
36
38
|
|
|
37
|
-
// Login
|
|
38
|
-
const
|
|
39
|
+
// Login - automatically stores user object
|
|
40
|
+
const response = await client.auth.login({
|
|
39
41
|
username: 'your-username',
|
|
40
42
|
password: 'your-password',
|
|
41
43
|
});
|
|
44
|
+
// User info (EMPLOYEE_NUMBER, USER_ID, etc.) now available to all modules
|
|
42
45
|
|
|
43
46
|
// Get leave types
|
|
44
47
|
const types = await client.leaves.getRestrictedTypes();
|
|
45
48
|
|
|
46
|
-
// Create leave request
|
|
49
|
+
// Create leave request - employee number auto-extracted
|
|
47
50
|
const request = await client.leaves.createRequest({
|
|
48
51
|
absenceTypeId: '71',
|
|
49
52
|
startDate: '2026-01-20',
|
|
@@ -51,6 +54,11 @@ const request = await client.leaves.createRequest({
|
|
|
51
54
|
days: 3,
|
|
52
55
|
comments: 'Family vacation',
|
|
53
56
|
});
|
|
57
|
+
|
|
58
|
+
// Get payslip - employee number auto-extracted
|
|
59
|
+
const header = await client.payslip.getHeader({
|
|
60
|
+
periodName: '6 2025'
|
|
61
|
+
});
|
|
54
62
|
```
|
|
55
63
|
|
|
56
64
|
### Next.js App Router (Client Component)
|
|
@@ -123,8 +131,12 @@ export default async function Page() {
|
|
|
123
131
|
### Authentication
|
|
124
132
|
|
|
125
133
|
```typescript
|
|
126
|
-
// Login
|
|
127
|
-
await client.auth.login({ username, password });
|
|
134
|
+
// Login - automatically stores full user object
|
|
135
|
+
const response = await client.auth.login({ username, password });
|
|
136
|
+
// User object now available to all modules:
|
|
137
|
+
// - userName, ebsVersion
|
|
138
|
+
// - USER_ID, PERSON_ID, EMPLOYEE_NUMBER
|
|
139
|
+
// - responsibilities
|
|
128
140
|
|
|
129
141
|
// Get user context
|
|
130
142
|
const user = await client.auth.getUserContext();
|
|
@@ -133,6 +145,8 @@ const user = await client.auth.getUserContext();
|
|
|
133
145
|
await client.auth.logout();
|
|
134
146
|
```
|
|
135
147
|
|
|
148
|
+
**User Storage**: The SDK automatically stores the complete user object from the login response, making user information available to all modules without additional API calls.
|
|
149
|
+
|
|
136
150
|
### Leaves & Absences
|
|
137
151
|
|
|
138
152
|
```typescript
|
|
@@ -183,13 +197,40 @@ await client.notifications.processApproval({
|
|
|
183
197
|
### Payslip
|
|
184
198
|
|
|
185
199
|
```typescript
|
|
186
|
-
// Get header
|
|
187
|
-
const header = await client.payslip.getHeader({
|
|
200
|
+
// Get header - employee number auto-extracted from login
|
|
201
|
+
const header = await client.payslip.getHeader({
|
|
202
|
+
periodName: '6 2025'
|
|
203
|
+
});
|
|
188
204
|
|
|
189
|
-
// Get details
|
|
190
|
-
const details = await client.payslip.getDetails({
|
|
205
|
+
// Get details (earnings/deductions)
|
|
206
|
+
const details = await client.payslip.getDetails({
|
|
207
|
+
periodName: '6 2025'
|
|
208
|
+
});
|
|
209
|
+
|
|
210
|
+
// Get leave details
|
|
211
|
+
const leaveDetails = await client.payslip.getLeaveDetails({
|
|
212
|
+
periodName: '6 2025'
|
|
213
|
+
});
|
|
214
|
+
|
|
215
|
+
// Get run balances
|
|
216
|
+
const runBalances = await client.payslip.getRunBalances({
|
|
217
|
+
periodName: '6 2025'
|
|
218
|
+
});
|
|
219
|
+
|
|
220
|
+
// Get accrual balances
|
|
221
|
+
const accrualBalances = await client.accrualBalances.getBalances({
|
|
222
|
+
calculationDate: '2025-06-30'
|
|
223
|
+
});
|
|
224
|
+
|
|
225
|
+
// Optional: Override employee number (for admin/HR use)
|
|
226
|
+
const header = await client.payslip.getHeader({
|
|
227
|
+
employeeNumber: '12345',
|
|
228
|
+
periodName: '6 2025'
|
|
229
|
+
});
|
|
191
230
|
```
|
|
192
231
|
|
|
232
|
+
**Auto Employee Number**: All payslip methods automatically use the employee number from the logged-in user. No need to pass it explicitly unless you're querying for a different employee.
|
|
233
|
+
|
|
193
234
|
### Employee
|
|
194
235
|
|
|
195
236
|
```typescript
|
|
@@ -282,6 +323,10 @@ All hooks are available from `@smartsides/oracle-ebs-sdk/hooks`:
|
|
|
282
323
|
- `useSitSegments(client, params, options)`
|
|
283
324
|
- `useNotifications(client, options)`
|
|
284
325
|
- `usePayslipHeader(client, params, options)`
|
|
326
|
+
- `usePayslipDetails(client, params, options)`
|
|
327
|
+
- `usePayslipLeaveDetails(client, params, options)`
|
|
328
|
+
- `usePayslipRunBalances(client, params, options)`
|
|
329
|
+
- `useAccrualBalances(client, params, options)`
|
|
285
330
|
- `usePersonalInfo(client, options)`
|
|
286
331
|
- `useHealthCheck(client, options)`
|
|
287
332
|
- And more...
|
|
@@ -305,6 +350,38 @@ const client = createServerClientFromCookies(cookies());
|
|
|
305
350
|
const client = createServerClientFromHeaders(headers());
|
|
306
351
|
```
|
|
307
352
|
|
|
353
|
+
## Key Improvements (v1.0.6)
|
|
354
|
+
|
|
355
|
+
### Automatic User Context Storage
|
|
356
|
+
The SDK now automatically stores the complete user object from the login response, eliminating the need to:
|
|
357
|
+
- Make additional API calls for user information
|
|
358
|
+
- Pass employee number to every payslip/leave request
|
|
359
|
+
- Manually manage user context in your application
|
|
360
|
+
|
|
361
|
+
### Smart Employee Number Extraction
|
|
362
|
+
All payslip and leave methods automatically use the employee number from the logged-in user:
|
|
363
|
+
```typescript
|
|
364
|
+
// Before (v1.0.2)
|
|
365
|
+
await client.payslip.getHeader({
|
|
366
|
+
employeeNumber: '4446', // Had to pass manually
|
|
367
|
+
periodName: '6 2025'
|
|
368
|
+
});
|
|
369
|
+
|
|
370
|
+
// After (v1.0.6)
|
|
371
|
+
await client.payslip.getHeader({
|
|
372
|
+
periodName: '6 2025' // Employee number auto-extracted!
|
|
373
|
+
});
|
|
374
|
+
```
|
|
375
|
+
|
|
376
|
+
### Full User Object Access
|
|
377
|
+
All modules can now access the complete user object:
|
|
378
|
+
- `userName` - Username
|
|
379
|
+
- `ebsVersion` - Oracle EBS version
|
|
380
|
+
- `USER_ID` - User ID
|
|
381
|
+
- `PERSON_ID` - Person ID
|
|
382
|
+
- `EMPLOYEE_NUMBER` - Employee number
|
|
383
|
+
- `responsibilities` - User responsibilities
|
|
384
|
+
|
|
308
385
|
## License
|
|
309
386
|
|
|
310
387
|
PROPRIETARY - SmartSides Development Team
|
|
@@ -240,46 +240,149 @@ declare class SitRequestsModule extends BaseClient {
|
|
|
240
240
|
interface Notification {
|
|
241
241
|
notificationId: string;
|
|
242
242
|
subject: string;
|
|
243
|
-
status
|
|
244
|
-
createdDate
|
|
243
|
+
status?: string;
|
|
244
|
+
createdDate?: string;
|
|
245
|
+
fromUser?: string;
|
|
246
|
+
beginDate?: string;
|
|
247
|
+
dueDate?: string | null;
|
|
248
|
+
notificationType?: 'FYI' | 'ACTION_REQUIRED';
|
|
245
249
|
itemKey?: string;
|
|
246
250
|
analysisCriteriaId?: string;
|
|
251
|
+
userId?: string;
|
|
252
|
+
[key: string]: any;
|
|
247
253
|
}
|
|
248
254
|
interface GetNotificationsResponse {
|
|
249
|
-
notifications
|
|
255
|
+
notifications?: Notification[];
|
|
256
|
+
[key: string]: any;
|
|
250
257
|
}
|
|
251
258
|
interface NotificationDetails {
|
|
252
|
-
notificationId
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
259
|
+
notificationId?: string;
|
|
260
|
+
itemKey?: string;
|
|
261
|
+
analysisCriteriaId?: string;
|
|
262
|
+
idFlexNum?: string;
|
|
263
|
+
title?: string;
|
|
264
|
+
description?: string;
|
|
265
|
+
status?: string;
|
|
266
|
+
createdDate?: string;
|
|
257
267
|
dueDate?: string;
|
|
268
|
+
userId?: string;
|
|
269
|
+
userName?: string;
|
|
270
|
+
action?: string;
|
|
271
|
+
lastUpdatedDate?: string;
|
|
272
|
+
comments?: string;
|
|
258
273
|
priority?: string;
|
|
274
|
+
notificationType?: string;
|
|
275
|
+
[key: string]: any;
|
|
259
276
|
}
|
|
260
277
|
interface GetNotificationDetailsParams {
|
|
261
278
|
notificationId: string;
|
|
262
279
|
}
|
|
280
|
+
interface GetAllDetailsParams {
|
|
281
|
+
notificationId: string;
|
|
282
|
+
itemKey: string;
|
|
283
|
+
analysisCriteriaId: string;
|
|
284
|
+
idFlexNum: string;
|
|
285
|
+
}
|
|
286
|
+
interface AllDetailsResponse {
|
|
287
|
+
itemKeyDetails?: {
|
|
288
|
+
itemType?: string;
|
|
289
|
+
itemKey?: string;
|
|
290
|
+
};
|
|
291
|
+
headerDetails?: {
|
|
292
|
+
transactionId?: string;
|
|
293
|
+
creatorPersonId?: string;
|
|
294
|
+
creatorPersonName?: string;
|
|
295
|
+
selectedPersonId?: string;
|
|
296
|
+
selectedPersonName?: string;
|
|
297
|
+
createdBy?: string;
|
|
298
|
+
createdByUserName?: string;
|
|
299
|
+
createdByPersonName?: string;
|
|
300
|
+
creationDate?: string;
|
|
301
|
+
lastUpdateDate?: string;
|
|
302
|
+
lastUpdatedBy?: string;
|
|
303
|
+
functionId?: string;
|
|
304
|
+
transactionRefTable?: string;
|
|
305
|
+
assignmentId?: string;
|
|
306
|
+
processName?: string;
|
|
307
|
+
};
|
|
308
|
+
stepDetails?: {
|
|
309
|
+
transactionStepId?: string;
|
|
310
|
+
transactionId?: string;
|
|
311
|
+
apiName?: string;
|
|
312
|
+
itemType?: string;
|
|
313
|
+
itemKey?: string;
|
|
314
|
+
activityId?: string;
|
|
315
|
+
};
|
|
316
|
+
segmentDetails?: Array<{
|
|
317
|
+
segmentNum?: string;
|
|
318
|
+
segmentName?: string;
|
|
319
|
+
segmentValue?: string;
|
|
320
|
+
}>;
|
|
321
|
+
[key: string]: any;
|
|
322
|
+
}
|
|
323
|
+
interface GetAbsenceDetailsParams {
|
|
324
|
+
itemKey: string;
|
|
325
|
+
}
|
|
326
|
+
interface AbsenceDetailsResponse {
|
|
327
|
+
absenceAttendanceId?: string;
|
|
328
|
+
businessGroupId?: string;
|
|
329
|
+
absenceAttendanceTypeId?: string;
|
|
330
|
+
absenceTypeName?: string;
|
|
331
|
+
personId?: string;
|
|
332
|
+
absenceDays?: string;
|
|
333
|
+
dateEnd?: string;
|
|
334
|
+
dateNotification?: string;
|
|
335
|
+
dateStart?: string;
|
|
336
|
+
attribute1?: string;
|
|
337
|
+
attribute2?: string;
|
|
338
|
+
attribute3?: string;
|
|
339
|
+
attribute4?: string;
|
|
340
|
+
[key: string]: any;
|
|
341
|
+
}
|
|
342
|
+
interface GetActionHistoryParams {
|
|
343
|
+
notificationId: string;
|
|
344
|
+
}
|
|
345
|
+
interface ActionHistoryItem {
|
|
346
|
+
notificationId?: string;
|
|
347
|
+
action?: string;
|
|
348
|
+
actionDescription?: string;
|
|
349
|
+
performedBy?: string;
|
|
350
|
+
performedByName?: string;
|
|
351
|
+
actionDate?: string;
|
|
352
|
+
comments?: string;
|
|
353
|
+
[key: string]: any;
|
|
354
|
+
}
|
|
355
|
+
interface ActionHistoryResponse {
|
|
356
|
+
history?: ActionHistoryItem[];
|
|
357
|
+
[key: string]: any;
|
|
358
|
+
}
|
|
263
359
|
interface ProcessApprovalInput {
|
|
264
360
|
notificationId: string;
|
|
265
|
-
action: 'APPROVE' | '
|
|
361
|
+
action: 'APPROVE' | 'DECLINE';
|
|
266
362
|
comments?: string;
|
|
363
|
+
responderUserName?: string;
|
|
267
364
|
}
|
|
268
365
|
interface ProcessApprovalResponse {
|
|
269
|
-
status
|
|
270
|
-
message
|
|
366
|
+
status?: string;
|
|
367
|
+
message?: string;
|
|
368
|
+
errorMessage?: string;
|
|
369
|
+
[key: string]: any;
|
|
271
370
|
}
|
|
272
371
|
interface CloseFyiParams {
|
|
273
372
|
notificationId: string;
|
|
274
373
|
}
|
|
275
374
|
interface CloseFyiResponse {
|
|
276
|
-
status
|
|
277
|
-
message
|
|
375
|
+
status?: string;
|
|
376
|
+
message?: string;
|
|
377
|
+
[key: string]: any;
|
|
278
378
|
}
|
|
279
379
|
|
|
280
380
|
declare class NotificationsModule extends BaseClient {
|
|
281
381
|
getList(): Promise<GetNotificationsResponse>;
|
|
282
382
|
getDetails(params: GetNotificationDetailsParams): Promise<NotificationDetails>;
|
|
383
|
+
getAllDetails(params: GetAllDetailsParams): Promise<AllDetailsResponse>;
|
|
384
|
+
getAbsenceDetails(params: GetAbsenceDetailsParams): Promise<AbsenceDetailsResponse>;
|
|
385
|
+
getActionHistory(params: GetActionHistoryParams): Promise<ActionHistoryResponse>;
|
|
283
386
|
processApproval(input: ProcessApprovalInput): Promise<ProcessApprovalResponse>;
|
|
284
387
|
closeFyi(params: CloseFyiParams): Promise<CloseFyiResponse>;
|
|
285
388
|
}
|
|
@@ -240,46 +240,149 @@ declare class SitRequestsModule extends BaseClient {
|
|
|
240
240
|
interface Notification {
|
|
241
241
|
notificationId: string;
|
|
242
242
|
subject: string;
|
|
243
|
-
status
|
|
244
|
-
createdDate
|
|
243
|
+
status?: string;
|
|
244
|
+
createdDate?: string;
|
|
245
|
+
fromUser?: string;
|
|
246
|
+
beginDate?: string;
|
|
247
|
+
dueDate?: string | null;
|
|
248
|
+
notificationType?: 'FYI' | 'ACTION_REQUIRED';
|
|
245
249
|
itemKey?: string;
|
|
246
250
|
analysisCriteriaId?: string;
|
|
251
|
+
userId?: string;
|
|
252
|
+
[key: string]: any;
|
|
247
253
|
}
|
|
248
254
|
interface GetNotificationsResponse {
|
|
249
|
-
notifications
|
|
255
|
+
notifications?: Notification[];
|
|
256
|
+
[key: string]: any;
|
|
250
257
|
}
|
|
251
258
|
interface NotificationDetails {
|
|
252
|
-
notificationId
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
259
|
+
notificationId?: string;
|
|
260
|
+
itemKey?: string;
|
|
261
|
+
analysisCriteriaId?: string;
|
|
262
|
+
idFlexNum?: string;
|
|
263
|
+
title?: string;
|
|
264
|
+
description?: string;
|
|
265
|
+
status?: string;
|
|
266
|
+
createdDate?: string;
|
|
257
267
|
dueDate?: string;
|
|
268
|
+
userId?: string;
|
|
269
|
+
userName?: string;
|
|
270
|
+
action?: string;
|
|
271
|
+
lastUpdatedDate?: string;
|
|
272
|
+
comments?: string;
|
|
258
273
|
priority?: string;
|
|
274
|
+
notificationType?: string;
|
|
275
|
+
[key: string]: any;
|
|
259
276
|
}
|
|
260
277
|
interface GetNotificationDetailsParams {
|
|
261
278
|
notificationId: string;
|
|
262
279
|
}
|
|
280
|
+
interface GetAllDetailsParams {
|
|
281
|
+
notificationId: string;
|
|
282
|
+
itemKey: string;
|
|
283
|
+
analysisCriteriaId: string;
|
|
284
|
+
idFlexNum: string;
|
|
285
|
+
}
|
|
286
|
+
interface AllDetailsResponse {
|
|
287
|
+
itemKeyDetails?: {
|
|
288
|
+
itemType?: string;
|
|
289
|
+
itemKey?: string;
|
|
290
|
+
};
|
|
291
|
+
headerDetails?: {
|
|
292
|
+
transactionId?: string;
|
|
293
|
+
creatorPersonId?: string;
|
|
294
|
+
creatorPersonName?: string;
|
|
295
|
+
selectedPersonId?: string;
|
|
296
|
+
selectedPersonName?: string;
|
|
297
|
+
createdBy?: string;
|
|
298
|
+
createdByUserName?: string;
|
|
299
|
+
createdByPersonName?: string;
|
|
300
|
+
creationDate?: string;
|
|
301
|
+
lastUpdateDate?: string;
|
|
302
|
+
lastUpdatedBy?: string;
|
|
303
|
+
functionId?: string;
|
|
304
|
+
transactionRefTable?: string;
|
|
305
|
+
assignmentId?: string;
|
|
306
|
+
processName?: string;
|
|
307
|
+
};
|
|
308
|
+
stepDetails?: {
|
|
309
|
+
transactionStepId?: string;
|
|
310
|
+
transactionId?: string;
|
|
311
|
+
apiName?: string;
|
|
312
|
+
itemType?: string;
|
|
313
|
+
itemKey?: string;
|
|
314
|
+
activityId?: string;
|
|
315
|
+
};
|
|
316
|
+
segmentDetails?: Array<{
|
|
317
|
+
segmentNum?: string;
|
|
318
|
+
segmentName?: string;
|
|
319
|
+
segmentValue?: string;
|
|
320
|
+
}>;
|
|
321
|
+
[key: string]: any;
|
|
322
|
+
}
|
|
323
|
+
interface GetAbsenceDetailsParams {
|
|
324
|
+
itemKey: string;
|
|
325
|
+
}
|
|
326
|
+
interface AbsenceDetailsResponse {
|
|
327
|
+
absenceAttendanceId?: string;
|
|
328
|
+
businessGroupId?: string;
|
|
329
|
+
absenceAttendanceTypeId?: string;
|
|
330
|
+
absenceTypeName?: string;
|
|
331
|
+
personId?: string;
|
|
332
|
+
absenceDays?: string;
|
|
333
|
+
dateEnd?: string;
|
|
334
|
+
dateNotification?: string;
|
|
335
|
+
dateStart?: string;
|
|
336
|
+
attribute1?: string;
|
|
337
|
+
attribute2?: string;
|
|
338
|
+
attribute3?: string;
|
|
339
|
+
attribute4?: string;
|
|
340
|
+
[key: string]: any;
|
|
341
|
+
}
|
|
342
|
+
interface GetActionHistoryParams {
|
|
343
|
+
notificationId: string;
|
|
344
|
+
}
|
|
345
|
+
interface ActionHistoryItem {
|
|
346
|
+
notificationId?: string;
|
|
347
|
+
action?: string;
|
|
348
|
+
actionDescription?: string;
|
|
349
|
+
performedBy?: string;
|
|
350
|
+
performedByName?: string;
|
|
351
|
+
actionDate?: string;
|
|
352
|
+
comments?: string;
|
|
353
|
+
[key: string]: any;
|
|
354
|
+
}
|
|
355
|
+
interface ActionHistoryResponse {
|
|
356
|
+
history?: ActionHistoryItem[];
|
|
357
|
+
[key: string]: any;
|
|
358
|
+
}
|
|
263
359
|
interface ProcessApprovalInput {
|
|
264
360
|
notificationId: string;
|
|
265
|
-
action: 'APPROVE' | '
|
|
361
|
+
action: 'APPROVE' | 'DECLINE';
|
|
266
362
|
comments?: string;
|
|
363
|
+
responderUserName?: string;
|
|
267
364
|
}
|
|
268
365
|
interface ProcessApprovalResponse {
|
|
269
|
-
status
|
|
270
|
-
message
|
|
366
|
+
status?: string;
|
|
367
|
+
message?: string;
|
|
368
|
+
errorMessage?: string;
|
|
369
|
+
[key: string]: any;
|
|
271
370
|
}
|
|
272
371
|
interface CloseFyiParams {
|
|
273
372
|
notificationId: string;
|
|
274
373
|
}
|
|
275
374
|
interface CloseFyiResponse {
|
|
276
|
-
status
|
|
277
|
-
message
|
|
375
|
+
status?: string;
|
|
376
|
+
message?: string;
|
|
377
|
+
[key: string]: any;
|
|
278
378
|
}
|
|
279
379
|
|
|
280
380
|
declare class NotificationsModule extends BaseClient {
|
|
281
381
|
getList(): Promise<GetNotificationsResponse>;
|
|
282
382
|
getDetails(params: GetNotificationDetailsParams): Promise<NotificationDetails>;
|
|
383
|
+
getAllDetails(params: GetAllDetailsParams): Promise<AllDetailsResponse>;
|
|
384
|
+
getAbsenceDetails(params: GetAbsenceDetailsParams): Promise<AbsenceDetailsResponse>;
|
|
385
|
+
getActionHistory(params: GetActionHistoryParams): Promise<ActionHistoryResponse>;
|
|
283
386
|
processApproval(input: ProcessApprovalInput): Promise<ProcessApprovalResponse>;
|
|
284
387
|
closeFyi(params: CloseFyiParams): Promise<CloseFyiResponse>;
|
|
285
388
|
}
|
package/dist/hooks/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import { UseMutationOptions, UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
-
import { G as GetAbsenceTypesParams, j as GetSitSegmentsParams, Q as GetDffSegmentsParams, O as OracleEBSClient, b as LoginResponse, L as LoginCredentials, U as UserContext, e as GetAbsenceTypesResponse, g as GetLeaveHistoryResponse, i as CreateLeaveRequestResponse, h as CreateLeaveRequestInput, k as GetSitSegmentsResponse, m as SaveAndPreviewSitRequestResponse, l as SaveAndPreviewSitRequestInput, o as SubmitSitRequestResponse, n as SubmitSitRequestInput, s as GetNotificationsResponse, u as GetNotificationDetailsParams, t as NotificationDetails, v as ProcessApprovalResponse, P as ProcessApprovalInput, y as GetPayslipHeaderParams, z as PayslipHeader, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, F as PersonalInformation, I as GetEmployeeHierarchyResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, V as GetDffSegmentsResponse, W as HealthCheckResponse } from '../OracleEBSClient-
|
|
3
|
+
import { G as GetAbsenceTypesParams, j as GetSitSegmentsParams, Q as GetDffSegmentsParams, O as OracleEBSClient, b as LoginResponse, L as LoginCredentials, U as UserContext, e as GetAbsenceTypesResponse, g as GetLeaveHistoryResponse, i as CreateLeaveRequestResponse, h as CreateLeaveRequestInput, k as GetSitSegmentsResponse, m as SaveAndPreviewSitRequestResponse, l as SaveAndPreviewSitRequestInput, o as SubmitSitRequestResponse, n as SubmitSitRequestInput, s as GetNotificationsResponse, u as GetNotificationDetailsParams, t as NotificationDetails, v as ProcessApprovalResponse, P as ProcessApprovalInput, y as GetPayslipHeaderParams, z as PayslipHeader, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, F as PersonalInformation, I as GetEmployeeHierarchyResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, V as GetDffSegmentsResponse, W as HealthCheckResponse } from '../OracleEBSClient-C2zQ1MaD.mjs';
|
|
4
4
|
import 'ky';
|
|
5
5
|
|
|
6
6
|
declare const queryKeys: {
|
package/dist/hooks/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import { UseMutationOptions, UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
-
import { G as GetAbsenceTypesParams, j as GetSitSegmentsParams, Q as GetDffSegmentsParams, O as OracleEBSClient, b as LoginResponse, L as LoginCredentials, U as UserContext, e as GetAbsenceTypesResponse, g as GetLeaveHistoryResponse, i as CreateLeaveRequestResponse, h as CreateLeaveRequestInput, k as GetSitSegmentsResponse, m as SaveAndPreviewSitRequestResponse, l as SaveAndPreviewSitRequestInput, o as SubmitSitRequestResponse, n as SubmitSitRequestInput, s as GetNotificationsResponse, u as GetNotificationDetailsParams, t as NotificationDetails, v as ProcessApprovalResponse, P as ProcessApprovalInput, y as GetPayslipHeaderParams, z as PayslipHeader, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, F as PersonalInformation, I as GetEmployeeHierarchyResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, V as GetDffSegmentsResponse, W as HealthCheckResponse } from '../OracleEBSClient-
|
|
3
|
+
import { G as GetAbsenceTypesParams, j as GetSitSegmentsParams, Q as GetDffSegmentsParams, O as OracleEBSClient, b as LoginResponse, L as LoginCredentials, U as UserContext, e as GetAbsenceTypesResponse, g as GetLeaveHistoryResponse, i as CreateLeaveRequestResponse, h as CreateLeaveRequestInput, k as GetSitSegmentsResponse, m as SaveAndPreviewSitRequestResponse, l as SaveAndPreviewSitRequestInput, o as SubmitSitRequestResponse, n as SubmitSitRequestInput, s as GetNotificationsResponse, u as GetNotificationDetailsParams, t as NotificationDetails, v as ProcessApprovalResponse, P as ProcessApprovalInput, y as GetPayslipHeaderParams, z as PayslipHeader, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, F as PersonalInformation, I as GetEmployeeHierarchyResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, V as GetDffSegmentsResponse, W as HealthCheckResponse } from '../OracleEBSClient-C2zQ1MaD.js';
|
|
4
4
|
import 'ky';
|
|
5
5
|
|
|
6
6
|
declare const queryKeys: {
|
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as APIResponse, d as AbsenceType, X as AccrualBalance, C as CacheOptions, w as CloseFyiParams, x as CloseFyiResponse, h as CreateLeaveRequestInput, i as CreateLeaveRequestResponse, M as DffSegment, H as EmployeeHierarchyNode, G as GetAbsenceTypesParams, e as GetAbsenceTypesResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, Q as GetDffSegmentsParams, V as GetDffSegmentsResponse, I as GetEmployeeHierarchyResponse, g as GetLeaveHistoryResponse, u as GetNotificationDetailsParams, s as GetNotificationsResponse, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, y as GetPayslipHeaderParams, p as GetSitHistoryParams, r as GetSitHistoryResponse, j as GetSitSegmentsParams, k as GetSitSegmentsResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, W as HealthCheckResponse, f as LeaveHistoryRecord, L as LoginCredentials, b as LoginResponse, N as Notification, t as NotificationDetails, O as OracleEBSClient, a as OracleEBSConfig, D as PayslipDetail, z as PayslipHeader, F as PersonalInformation, P as ProcessApprovalInput, v as ProcessApprovalResponse, c as Responsibility, R as RetryOptions, l as SaveAndPreviewSitRequestInput, m as SaveAndPreviewSitRequestResponse, q as SitHistoryRecord, S as SitSegment, n as SubmitSitRequestInput, o as SubmitSitRequestResponse, T as TableColumn, U as UserContext } from './OracleEBSClient-
|
|
1
|
+
export { A as APIResponse, d as AbsenceType, X as AccrualBalance, C as CacheOptions, w as CloseFyiParams, x as CloseFyiResponse, h as CreateLeaveRequestInput, i as CreateLeaveRequestResponse, M as DffSegment, H as EmployeeHierarchyNode, G as GetAbsenceTypesParams, e as GetAbsenceTypesResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, Q as GetDffSegmentsParams, V as GetDffSegmentsResponse, I as GetEmployeeHierarchyResponse, g as GetLeaveHistoryResponse, u as GetNotificationDetailsParams, s as GetNotificationsResponse, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, y as GetPayslipHeaderParams, p as GetSitHistoryParams, r as GetSitHistoryResponse, j as GetSitSegmentsParams, k as GetSitSegmentsResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, W as HealthCheckResponse, f as LeaveHistoryRecord, L as LoginCredentials, b as LoginResponse, N as Notification, t as NotificationDetails, O as OracleEBSClient, a as OracleEBSConfig, D as PayslipDetail, z as PayslipHeader, F as PersonalInformation, P as ProcessApprovalInput, v as ProcessApprovalResponse, c as Responsibility, R as RetryOptions, l as SaveAndPreviewSitRequestInput, m as SaveAndPreviewSitRequestResponse, q as SitHistoryRecord, S as SitSegment, n as SubmitSitRequestInput, o as SubmitSitRequestResponse, T as TableColumn, U as UserContext } from './OracleEBSClient-C2zQ1MaD.mjs';
|
|
2
2
|
import 'ky';
|
|
3
3
|
|
|
4
4
|
declare class APIError extends Error {
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as APIResponse, d as AbsenceType, X as AccrualBalance, C as CacheOptions, w as CloseFyiParams, x as CloseFyiResponse, h as CreateLeaveRequestInput, i as CreateLeaveRequestResponse, M as DffSegment, H as EmployeeHierarchyNode, G as GetAbsenceTypesParams, e as GetAbsenceTypesResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, Q as GetDffSegmentsParams, V as GetDffSegmentsResponse, I as GetEmployeeHierarchyResponse, g as GetLeaveHistoryResponse, u as GetNotificationDetailsParams, s as GetNotificationsResponse, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, y as GetPayslipHeaderParams, p as GetSitHistoryParams, r as GetSitHistoryResponse, j as GetSitSegmentsParams, k as GetSitSegmentsResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, W as HealthCheckResponse, f as LeaveHistoryRecord, L as LoginCredentials, b as LoginResponse, N as Notification, t as NotificationDetails, O as OracleEBSClient, a as OracleEBSConfig, D as PayslipDetail, z as PayslipHeader, F as PersonalInformation, P as ProcessApprovalInput, v as ProcessApprovalResponse, c as Responsibility, R as RetryOptions, l as SaveAndPreviewSitRequestInput, m as SaveAndPreviewSitRequestResponse, q as SitHistoryRecord, S as SitSegment, n as SubmitSitRequestInput, o as SubmitSitRequestResponse, T as TableColumn, U as UserContext } from './OracleEBSClient-
|
|
1
|
+
export { A as APIResponse, d as AbsenceType, X as AccrualBalance, C as CacheOptions, w as CloseFyiParams, x as CloseFyiResponse, h as CreateLeaveRequestInput, i as CreateLeaveRequestResponse, M as DffSegment, H as EmployeeHierarchyNode, G as GetAbsenceTypesParams, e as GetAbsenceTypesResponse, Y as GetAccrualBalancesParams, Z as GetAccrualBalancesResponse, Q as GetDffSegmentsParams, V as GetDffSegmentsResponse, I as GetEmployeeHierarchyResponse, g as GetLeaveHistoryResponse, u as GetNotificationDetailsParams, s as GetNotificationsResponse, B as GetPayslipDetailsParams, E as GetPayslipDetailsResponse, y as GetPayslipHeaderParams, p as GetSitHistoryParams, r as GetSitHistoryResponse, j as GetSitSegmentsParams, k as GetSitSegmentsResponse, J as GetTableColumnsParams, K as GetTableColumnsResponse, W as HealthCheckResponse, f as LeaveHistoryRecord, L as LoginCredentials, b as LoginResponse, N as Notification, t as NotificationDetails, O as OracleEBSClient, a as OracleEBSConfig, D as PayslipDetail, z as PayslipHeader, F as PersonalInformation, P as ProcessApprovalInput, v as ProcessApprovalResponse, c as Responsibility, R as RetryOptions, l as SaveAndPreviewSitRequestInput, m as SaveAndPreviewSitRequestResponse, q as SitHistoryRecord, S as SitSegment, n as SubmitSitRequestInput, o as SubmitSitRequestResponse, T as TableColumn, U as UserContext } from './OracleEBSClient-C2zQ1MaD.js';
|
|
2
2
|
import 'ky';
|
|
3
3
|
|
|
4
4
|
declare class APIError extends Error {
|
package/dist/index.js
CHANGED
|
@@ -395,19 +395,50 @@ var NotificationsModule = class extends BaseClient {
|
|
|
395
395
|
return response.data;
|
|
396
396
|
}
|
|
397
397
|
/**
|
|
398
|
-
*
|
|
398
|
+
* Get all notification details (SSHR_SIT_REQDTLS)
|
|
399
|
+
* All parameters are required
|
|
400
|
+
*/
|
|
401
|
+
async getAllDetails(params) {
|
|
402
|
+
const searchParams = new URLSearchParams();
|
|
403
|
+
searchParams.set("notificationId", params.notificationId);
|
|
404
|
+
searchParams.set("itemKey", params.itemKey);
|
|
405
|
+
searchParams.set("analysisCriteriaId", params.analysisCriteriaId);
|
|
406
|
+
searchParams.set("idFlexNum", params.idFlexNum);
|
|
407
|
+
const response = await this.get(`notifications/all-details?${searchParams}`);
|
|
408
|
+
return response.data;
|
|
409
|
+
}
|
|
410
|
+
/**
|
|
411
|
+
* Get absence details for FYI notifications
|
|
412
|
+
*/
|
|
413
|
+
async getAbsenceDetails(params) {
|
|
414
|
+
const searchParams = new URLSearchParams();
|
|
415
|
+
searchParams.set("itemKey", params.itemKey);
|
|
416
|
+
const response = await this.get(`notifications/absence-details?${searchParams}`);
|
|
417
|
+
return response.data;
|
|
418
|
+
}
|
|
419
|
+
/**
|
|
420
|
+
* Get action history for a notification
|
|
421
|
+
*/
|
|
422
|
+
async getActionHistory(params) {
|
|
423
|
+
const searchParams = new URLSearchParams();
|
|
424
|
+
searchParams.set("notificationId", params.notificationId);
|
|
425
|
+
const response = await this.get(`notifications/action-history?${searchParams}`);
|
|
426
|
+
return response.data;
|
|
427
|
+
}
|
|
428
|
+
/**
|
|
429
|
+
* Process approval action (APPROVE/DECLINE)
|
|
399
430
|
*/
|
|
400
431
|
async processApproval(input) {
|
|
401
|
-
const response = await this.post("notifications/process-approval", input);
|
|
432
|
+
const response = await this.post("notifications/process-approval-action", input);
|
|
402
433
|
return response.data;
|
|
403
434
|
}
|
|
404
435
|
/**
|
|
405
436
|
* Close FYI notification
|
|
406
437
|
*/
|
|
407
438
|
async closeFyi(params) {
|
|
408
|
-
const
|
|
409
|
-
|
|
410
|
-
|
|
439
|
+
const response = await this.post("notifications/close-fyi", {
|
|
440
|
+
notificationId: params.notificationId
|
|
441
|
+
});
|
|
411
442
|
return response.data;
|
|
412
443
|
}
|
|
413
444
|
};
|