1 PACKAGE psp_wf_adj_pkg AUTHID CURRENT_USER AS
2 /* $Header: PSPWFAJS.pls 115.11 2003/07/24 16:58:55 spchakra ship $ */
3
4 /****************************************************************************************************************/
5 /*Procedure INIT_WORKFLOW is called if user profile option "PSP:Distribution Adj. Enhanced Workflow" is set to */
6 /*"Yes". It is initiated when users submit the distribution adjustment batch. If the workflow process succeeds, */
7 /*0 will be returned; otherwise, -1 or -2 will be returned. */
8 /****************************************************************************************************************/
9 PROCEDURE init_workflow(p_batch_name IN VARCHAR2,
10 p_person_id IN NUMBER,
11 p_display_name IN VARCHAR2,
12 p_assignment IN VARCHAR2,
13 --- p_earnings_element IN VARCHAR2,
14 p_begin_date IN DATE,
15 p_end_date IN DATE,
16 p_currency_code IN VARCHAR2, -- Introduced for bug fix 2916848
17 p_comments IN VARCHAR2,
18 p_time_out IN NUMBER,
19 return_code OUT NOCOPY NUMBER);
20
21 /*********************************************************************************************/
22 /*Procedure SELECT_APPROVER is called by "Select Approver" activity in the distribution adjustment workflow */
23 /*process. By default, the supervisor is the approver. If customization is needed, call */
24 /*PSP_WF_CUSTOM.select_adj_approver to get the approver's person ID. */
25 /*********************************************************************************************/
26 PROCEDURE select_approver(itemtype IN VARCHAR2,
27 itemkey IN VARCHAR2,
28 actid IN NUMBER,
29 funcmode IN VARCHAR2,
30 result OUT NOCOPY VARCHAR2);
31
32 /****************************************************************************************************************/
33 /*Procedure UNDO_DISTRIBUTION_ADJUSTMENT is called by "Undo Distribution Adjustment" activity in the */
34 /*distribution adjustment workflow process. If the adjustment batch is cancelled by the creator or rejected by */
35 /*the approver, the database will be returned to the state that is before the batch is created. */
36 /*Procedure UNDO_DISTRIBUTION_ADJUSTMENT calls a procedure called undo_adjustment(). */
37 /****************************************************************************************************************/
38 PROCEDURE undo_distribution_adjustment(itemtype IN VARCHAR2,
39 itemkey IN VARCHAR2,
40 actid IN NUMBER,
41 funcmode IN VARCHAR2,
42 result OUT NOCOPY VARCHAR2);
43
44 /****************************************************************************************************************/
45 /*Procedure GET_APPROVAL_RESPONDER is called by workflow activity "Get Final Approver" to figure out who is the */
46 /*final approver in the forwarding path. */
47 /****************************************************************************************************************/
48 PROCEDURE get_approval_responder(itemtype in varchar2,
49 itemkey in varchar2,
50 actid in number,
51 funcmode in varchar2,
52 result out NOCOPY varchar2);
53
54 /****************************************************************************************************************/
55 /*Procedure RECORD_APPROVER is called by workflow activity "Record Approver". When the distribution adjustment */
56 /*batch is approved, the approver's user ID is recorded in table PSP_ADJUSTMENT_CONTROL_TABLE. */
57 /****************************************************************************************************************/
58 PROCEDURE record_approver(itemtype IN VARCHAR2,
59 itemkey IN VARCHAR2,
60 actid IN NUMBER,
61 funcmode IN VARCHAR2,
62 result OUT NOCOPY VARCHAR2);
63
64 PROCEDURE omit_approval (itemtype IN VARCHAR2,
65 itemkey IN VARCHAR2,
66 actid IN NUMBER,
67 funcmode IN VARCHAR2,
68 result OUT NOCOPY VARCHAR2);
69 PROCEDURE record_creator(itemtype IN VARCHAR2,
70 itemkey IN VARCHAR2,
71 actid IN NUMBER,
72 funcmode IN VARCHAR2,
73 result OUT NOCOPY VARCHAR2);
74 END psp_wf_adj_pkg;