DBA Data[Home] [Help]

PACKAGE: APPS.WIP_COMMON

Source


1 PACKAGE WIP_COMMON AUTHID CURRENT_USER AS
2 /* $Header: wipcomms.pls 120.0 2005/05/25 07:55:46 appldev noship $ */
3 
4 
5 /*=====================================================================+
6  | FUNCTION
7  |   DEFAULT_ACC_CLASS
8  |
9  | PURPOSE
10  |   Defaults the accounting class if one is defined for Product Line
11  |   Accounting.
12  |
13  | ARGUMENTS
14  |   X_ORG_ID : Organization Id .
15  |   X_ITEM_ID : Item Id for which the accounting class is defaulted.
16  |   X_CLASS_TYPE : WIP accounting class type
17  |   X_PROJECT_ID : Project Id if defined, else NULL.
18  |   X_ERR_MESG : The Message_name for the error message.
19  |   X_ERR_CLASS : The class that is disabled.
20  |   Returns NUMBER: Returns the Accounting Class if defined or NULL.
21  |
22  | EXCEPTIONS
23  |
24  | NOTES
25  |
26  +=====================================================================*/
27 function default_acc_class
28          (X_ORG_ID       IN     NUMBER,
29           X_ITEM_ID      IN     NUMBER,
30           X_ENTITY_TYPE  IN     NUMBER,
31           X_PROJECT_ID   IN     NUMBER,
32           X_ERR_MESG_1   OUT NOCOPY    VARCHAR2,
33           X_ERR_CLASS_1  OUT NOCOPY    VARCHAR2,
34           X_ERR_MESG_2   OUT NOCOPY    VARCHAR2,
35           X_ERR_CLASS_2  OUT NOCOPY    VARCHAR2
36          )
37 RETURN VARCHAR2;
38 
39 /*=====================================================================+
40  | FUNCTION
41  |   Bill_Exists
42  |
43  | PURPOSE
44  |   To check whether the Item/Assembly has got a Bill of Material
45  |
46  | ARGUMENTS
47  |   p_item_id: Inventory Item Id.
48  |   p_org_id : Organization Id .
49  |
50  | NOTE
51  |     Returns 1 if Bill Exists
52  |     Returns 0 if Bill does not exist or SQL Error
53  |     Returns -1 if SQLERROR
54  |
55  +=====================================================================*/
56 
57 function Bill_Exists(
58 	 p_item_id in number,
59 	 p_org_id in number) return number ;
60 
61 /*=====================================================================+
62  | FUNCTION
63  |   Revision_Exists
64  |
65  | PURPOSE
66  |   To check whether the Item/Assembly is under Revision Control
67  |
68  | ARGUMENTS
69  |   p_item_id: Inventory Item Id.
70  |   p_org_id : Organization Id .
71  |
72  | NOTE
73  |     Returns 1 if the component is under revision control
74  |     Returns 0 if the component is not under revision control
75  |     Return  -2 if application level error
76  |     Returns -1 if SQLERROR
77  |
78  +=====================================================================*/
79 
80 function Revision_Exists(
81 	 p_item_id in number,
82 	 p_org_id in number) return number ;
83 
84 
85 /*=====================================================================+
86  | FUNCTION
87  |   Routing_Exists
88  |
89  | PURPOSE
90  |   To check whether the Item/Assembly has got a Routing
91  |
92  | ARGUMENTS
93  |   p_item_id: Inventory Item Id
94  |   p_org_id : Organization Id .
95  |
96  | NOTE
97  |     Returns 1 if Routing Exists
98  |     Returns 0 if Routing does not exist
99  |     Returns -1 if SQLERROR
100  |
101  +=====================================================================*/
102 
103 function Routing_Exists(
104          p_item_id in number,
105          p_org_id in number,
106          p_eff_date IN DATE := NULL) return number ;
107 
108 
109 /*=====================================================================+
110  | FUNCTION
111  |   Is_Primary_UOM
112  |
113  | PURPOSE
114  |   To check whether the Txn_Uom specified is the Item's primary UOM
115  |
116  | ARGUMENTS
117  |   p_item_id: Inventory Item Id
118  |   p_org_id : Organization Id
119  |   p_txn_uom: Transaction_UOM
120  |   p_pri_uom: Primary UOM
121  |
122  | NOTE
123  |     Returns 1 if Routing Exists
124  |     Returns 0 if Routing does not exist
125  |     Return  -2 if application level error
126  |     Returns -1 if SQLERROR
127  |
128  +=====================================================================*/
129 
130 function Is_Primary_UOM(
131 	p_item_id in number,
132 	p_org_id in number,
133 	p_txn_uom in varchar2,
134 	p_pri_uom in out nocopy varchar2) return number ;
135 
136 /*=====================================================================+
137  | PROCEDURE
138  |   get_total_quantity
139  |
140  | PURPOSE
141  |    This procedure would return the total quantity in a job/schedule
142  | in an out nocopy variable. The total quantity is the sum of all assemblies in
143  | all the operations, which may be different from the start quantity.
144  |
145  |
146  | ARGUMENTS
147  |
148  | EXCEPTIONS
149  |
150  | NOTES
151  |
152  +=====================================================================*/
153 
154    PROCEDURE get_total_quantity
155    (
156     p_organization_id             IN   NUMBER,
157     p_wip_entity_id               IN   NUMBER,
158     p_repetitive_schedule_id      IN   NUMBER DEFAULT NULL,
159     p_total_quantity              OUT NOCOPY  NUMBER
160     );
161 
162    PROCEDURE Get_Released_Revs_Type_Meaning
163    (
164     x_released_revs_type	OUT NOCOPY NUMBER,
165     x_released_revs_meaning	OUT NOCOPY Varchar2
166    );
167 
168 
169 END WIP_COMMON;