DBA Data[Home] [Help]

PACKAGE: APPS.WMS_DEPLOY

Source


1 PACKAGE WMS_DEPLOY AUTHID CURRENT_USER AS
2 /* $Header: WMSDEPLS.pls 120.0.12010000.8 2010/01/25 14:31:26 abasheer noship $ */
3 /*#
4  * This package provides routine to obtain the Oracle Warehouse Management
5  * (WMS) deployment mode and related Standalone and LSP installation utilities
6  * @rep:scope public
7  * @rep:product WMS
8  * @rep:lifecycle active
9  * @rep:displayname WMS Deploy
10  * @rep:category BUSINESS_ENTITY WMS_DEPLOY
11  */
12 /*
13 ** -------------------------------------------------------------------------
14 ** To prevent requery of database as much as possible within the same session,
15 ** the following global variables are cached and used suitably:
16 **
17 ** -------------------------------------------------------------------------
18 */
19 
20 
21 /* function returns the deployment mode based on the profile WMS_DEPLOYMENT_MODE
22  * 'I' - Integrated Deployment
23  * 'D' - Distributed (Standalone) Deployment
24  * 'L' - LSP Deployment
25  */
26 function wms_deployment_mode return varchar2;
27 
28 /* Returns the Item flex field delimiters.             */
29 FUNCTION get_item_flex_delimiter
30   RETURN VARCHAR2;
31 
32 /* Returns the Item flex field segment count.          */
33 FUNCTION get_item_flex_segment_count
34   RETURN NUMBER;
35 
36 TYPE t_in_txn_rec IS RECORD (
37                               inventory_item_id  NUMBER,
38                               organization_id    NUMBER
39                             );
40 
41 TYPE t_client_rec IS RECORD (
42                               client_id      NUMBER,
43                               client_name    hz_parties.party_name%type
44                             );
45 
46 /*
47 ** -------------------------------------------------------------------------
48 ** To prevent requery of database as much as possible within the same session,
49 ** the following global variables are cached and used suitably:
50 **
51 ** g_wms_deployment_mode :
52 ** 	Can be I/D/L based on WMS_DEPLOYMENT_MODE profile option
53 ** -------------------------------------------------------------------------
54 */
55 g_wms_deployment_mode VARCHAR2(2);
56 
57 /* function returns whether the item / transaction can be costed or not (Y/N)
58  * Takes input a record structure with inventory_item_id and organization_id
59  */
60 function Costed_Txn ( p_in_txn_rec IN t_in_txn_rec ) return varchar2;
61 
62 /* Wrapper of Costed_Txn to obtain whether the item / transaction can be costed or not (Y/N)
63  * given Item_id and Org_id
64 */
65 FUNCTION Costed_Txn_For_Item (p_organization_id			NUMBER,
66 							  p_inventory_item_id		NUMBER
67 				              ) RETURN VARCHAR2;
68 
69 /* procedure returns the outsourcer/client information pertaining to transaction details provided
70  * Takes input a record structure with inventory_item_id and organization_id
71  */
72 procedure Get_Client_Info ( p_in_txn_rec    IN         t_in_txn_rec,
73                             x_client_rec    OUT NOCOPY t_client_rec,
74                             x_return_status OUT NOCOPY VARCHAR2,
75                             x_msg_count     OUT NOCOPY NUMBER,
76                             x_msg_data      OUT NOCOPY VARCHAR2
77                           );
78 
79 
80 /* Wrapper of Get_Client_Info to obtain Outsourcer_id for a
81  * given Item_id and Org_id
82 */
83 procedure Get_Client_Info_For_Item (x_return_status 		OUT NOCOPY VARCHAR2,
84 				                            x_msg_count     		OUT NOCOPY NUMBER,
85 				                            x_msg_data      		OUT NOCOPY VARCHAR2,
86 				                            p_organization_id		NUMBER,
87 				                            p_inventory_item_id	NUMBER,
88 																		x_outsourcer_id			OUT NOCOPY NUMBER
89 				                          );
90 
91 /* Returns the Item Category Id for a given outsourcer_id
92 */
93 procedure Get_Category_Info (x_return_status        OUT NOCOPY VARCHAR2,
94 		                    x_msg_count           OUT NOCOPY NUMBER,
95 		                    x_msg_data            OUT NOCOPY VARCHAR2,
96 		                    p_outsourcer_id       NUMBER,
97 		                    x_item_category_id    OUT NOCOPY NUMBER
98                         );
99 
100  /* Added for LSP Project */
101 
102 function get_client_code
103     (
104       p_item_id number)
105     return VARCHAR2;
106 
107 
108 PROCEDURE get_client_details
109     (
110           x_client_id            IN   OUT NOCOPY MTL_CLIENT_PARAMETERS.CLIENT_ID%TYPE
111         , x_client_code          IN   OUT NOCOPY MTL_CLIENT_PARAMETERS.CLIENT_CODE%TYPE
112         , x_client_name          OUT NOCOPY HZ_PARTIES.PARTY_NAME%TYPE
113         , x_return_status        OUT NOCOPY VARCHAR2
114     );
115 
116 procedure Get_Client_item_Name ( x_item_id    NUMBER,
117                                  x_org_id     NUMBER,
118                                  x_item_name OUT NOCOPY VARCHAR2
119                                  );
120 
121 procedure Get_Client_PONum_Info ( x_po_header_id      NUMBER,
122                                   x_po_num OUT NOCOPY VARCHAR2) ;
123 
124 /* Returns PO Number excluding the Client Code */
125 FUNCTION get_client_po_num
126    (
127      p_po_header_id  NUMBER)
128     RETURN VARCHAR2;
129 
130 
131 /* Returns the Client Item Name.                       */
132 FUNCTION GET_CLIENT_ITEM
133   (
134     P_ORG_ID  NUMBER,
135     P_ITEM_ID NUMBER)
136   RETURN VARCHAR2;
137 
138 /* Returns the Client Name to which the Item belongs.  */
139 FUNCTION get_item_client_name
140   (
141     p_item_id NUMBER)
142   RETURN VARCHAR2;
143 
144 /* Returns the Item appending logic for LSP Deployment */
145 FUNCTION get_item_suffix_for_lov
146   (
147     p_concatenated_segments VARCHAR2)
148   RETURN VARCHAR2;
149 
150 /* Returns the Client Code to which the PO belongs.    */
151 FUNCTION get_po_client_code
152     (
153           p_po_header_id NUMBER)
154     RETURN VARCHAR2;
155 
156 /* Returns the Client Code to which the PO belongs.    */
157 FUNCTION get_po_client_name
158     (
159           p_po_header_id NUMBER)
160     RETURN VARCHAR2;
161 
162 /* End of changes for LSP Project */
163 
164 /*
165 **  Added function for bug 9274233
166 */
167 FUNCTION get_po_number
168    (
169           p_segment1 VARCHAR2)
170     RETURN NUMBER;
171 /*
172 **End of bug 9274233
173 */
174 
175 end WMS_DEPLOY;