DBA Data[Home] [Help]

PACKAGE: APPS.WSH_EXCEPTIONS_PUB

Source


1 PACKAGE WSH_EXCEPTIONS_PUB AUTHID CURRENT_USER AS
2 /* $Header: WSHXCPBS.pls 120.0 2005/05/26 17:59:26 appldev noship $ */
3 /*#
4  * This package provides the APIs to create Exceptions for delivery lines, deliveries, trips
5  * and to perform various actions on Exceptions.
6  * @rep:scope public
7  * @rep:product WSH
8  * @rep:displayname Exceptions
9  * @rep:lifecycle active
10  * @rep:compatibility S
11  * @rep:category BUSINESS_ENTITY  WSH_DELIVERY_LINE
12  * @rep:category BUSINESS_ENTITY  WSH_DELIVERY
13  * @rep:category BUSINESS_ENTITY  WSH_TRIP
14  */
15 
16 TYPE XC_REC_TYPE IS RECORD
17      (exception_id	NUMBER,
18      exception_name	VARCHAR2(30),
19      status		VARCHAR2(30)
20      );
21 
22 TYPE XC_ACTION_REC_TYPE IS RECORD
23         (
24         -- The following fields are used for Logging exceptions
25         request_id           NUMBER,           -- Also used for Purge
26         batch_id             NUMBER,
27         exception_id         NUMBER,
28         exception_name       VARCHAR2(30),     -- Also used for Purge, Change_Status
29         logging_entity       VARCHAR2(30),     -- Also used for Purge, Change_Status
30         logging_entity_id    NUMBER,           -- Also used for Change_Status
31         manually_logged      VARCHAR2(1),
32         message              VARCHAR2(2000),
33         logged_at_location_code       VARCHAR2(50),  -- Also used for Purge
34         exception_location_code       VARCHAR2(50),  -- Also used for Purge
35         severity             VARCHAR2(10),           -- Also used for Purge
36         delivery_name        VARCHAR2(30),           -- Also used for Purge
37         trip_name            VARCHAR2(30),
38         stop_location_id     NUMBER,
39         delivery_detail_id   NUMBER,
40         container_name       VARCHAR2(50),
41         org_id               NUMBER,
42         inventory_item_id    NUMBER,
43 -- HW OPMCONV. Need to expand length of lot_number to 80
44         lot_number           VARCHAR2(80),
45 -- HW OPMCONV. No need for sublot anymore
46 --      sublot_number        VARCHAR2(32),
47         revision             VARCHAR2(3),
48         serial_number        VARCHAR2(30),
49         unit_of_measure      VARCHAR2(5),
50         quantity             NUMBER,
51         unit_of_measure2     VARCHAR2(3),
52         quantity2            NUMBER,
53         subinventory         VARCHAR2(10),
54         locator_id           NUMBER,
55         error_message        VARCHAR2(500),
56         attribute_category   VARCHAR2(150),
57         attribute1           VARCHAR2(150),
58         attribute2           VARCHAR2(150),
59         attribute3           VARCHAR2(150),
60         attribute4           VARCHAR2(150),
61         attribute5           VARCHAR2(150),
62         attribute6           VARCHAR2(150),
63         attribute7           VARCHAR2(150),
64         attribute8           VARCHAR2(150),
65         attribute9           VARCHAR2(150),
66         attribute10          VARCHAR2(150),
67         attribute11          VARCHAR2(150),
68         attribute12          VARCHAR2(150),
69         attribute13          VARCHAR2(150),
70         attribute14          VARCHAR2(150),
71         attribute15          VARCHAR2(150),
72         departure_date       DATE,             -- Also used for Purge
73         arrival_date         DATE,             -- Also used for Purge
74 
75         -- These fields are used for the Purge action.
76         exception_type       VARCHAR2(25),
77         status               VARCHAR2(30),
78         departure_date_to    DATE,
79         arrival_date_to      DATE,
80         creation_date        DATE,
81         creation_date_to     DATE,
82         data_older_no_of_days    NUMBER,
83 
84         -- This field is used for Change_Status action.
85         new_status           VARCHAR2(30),
86 
87         caller          VARCHAR2(100),
88         phase           NUMBER
89         );
90 
91 TYPE XC_TAB_TYPE IS TABLE OF XC_REC_TYPE INDEX BY BINARY_INTEGER;
92 
93 ------------------------------------------------------------------------------
94 -- Procedure:	Get_Exceptions
95 --
96 -- Parameters:  1) p_logging_entity_id - entity id for a particular entity name
97 --              2) p_logging_entity_name - can be 'TRIP', 'STOP', 'DELIVERY',
98 --                                       'DETAIL', or 'CONTAINER'
99 --              3) x_exceptions_tab - list of exceptions
100 --
101 -- Description: This procedure takes in a logging entity id and logging entity
102 --              name and create an exception table.
103 ------------------------------------------------------------------------------
104 /*#
105  * This procedure takes in a logging entity id and logging entity
106  * name and create an exception table.
107  * @param p_api_version           Version number of the API
108  * @param p_init_msg_list         Messages will be initialized, if set as true
109  * @param x_return_status         Return Status of the API
110  * @param x_msg_count             Number of Messages, if any
111  * @param x_msg_data              Message Text, if any
112  * @param p_logging_entity_id     ID of Logging Entity
113  * @param p_logging_entity_name   Name of Logging Entity
114  * @param x_exceptions_tab        Exceptions Table
115  * @rep:scope public
116  * @rep:lifecycle active
117  * @rep:displayname Get Exceptions
118  */
119 
120 PROCEDURE Get_Exceptions (
121         -- Standard parameters
122         p_api_version           IN      NUMBER,
123         p_init_msg_list         IN      VARCHAR2  DEFAULT FND_API.G_FALSE,
124         x_return_status         OUT NOCOPY      VARCHAR2,
125         x_msg_count             OUT NOCOPY      NUMBER,
126         x_msg_data              OUT NOCOPY      VARCHAR2,
127 
128         -- program specific parameters
129         p_logging_entity_id	IN 	NUMBER,
130 	p_logging_entity_name	IN	VARCHAR2,
131 
132         -- program specific out parameters
133         x_exceptions_tab	OUT NOCOPY 	WSH_EXCEPTIONS_PUB.XC_TAB_TYPE
134 	);
135 
136 
137 ------------------------------------------------------------------------------
138 -- Procedure:   Exception_Action
139 --
140 -- Parameters:
141 --
142 -- Description:  This procedure calls the corresponding procedures to Log,
143 --               Purge and Change_Status of the exceptions based on the action
144 --               code it receives through the parameter p_action.
145 ------------------------------------------------------------------------------
146 /*#
147  * This procedure calls the corresponding procedures to Log,
148  * Purge and Change_Status of the exceptions based on the action
149  * code it receives through the parameter p_action.
150  * @param p_api_version           Version number of the API
151  * @param p_init_msg_list         Messages will be initialized, if set as true
152  * @param p_validation_level      Level of Validation
153  * @param p_commit                commits the transaction, if set as true
154  * @param x_msg_count             Number of Messages, if any
155  * @param x_msg_data              Message Text, if any
156  * @param x_return_status         Return Status of the API
157  * @param p_exception_rec         Exception Record
158  * @param p_action                Action Code
159  * @rep:scope public
160  * @rep:lifecycle active
161  * @rep:displayname Exception Actions
162  */
163 
164 PROCEDURE Exception_Action (
165 	p_api_version	        IN	NUMBER,
166 	p_init_msg_list		IN      VARCHAR2  DEFAULT FND_API.G_FALSE,
167 	p_validation_level      IN      NUMBER    DEFAULT FND_API.G_VALID_LEVEL_FULL,
168         p_commit                IN      VARCHAR2  DEFAULT FND_API.G_FALSE,
169         x_msg_count             OUT NOCOPY      NUMBER,
170         x_msg_data              OUT NOCOPY      VARCHAR2,
171         x_return_status         OUT NOCOPY      VARCHAR2,
172 
173 	p_exception_rec         IN OUT  NOCOPY WSH_EXCEPTIONS_PUB.XC_ACTION_REC_TYPE,
174         p_action                IN              VARCHAR2
175 	);
176 
177 END WSH_EXCEPTIONS_PUB;