[Home] [Help]
PACKAGE: APPS.PO_DISTRIBUTIONS_SV
Source
1 PACKAGE PO_DISTRIBUTIONS_SV AUTHID CURRENT_USER as
2 /* $Header: POXPOD1S.pls 120.1 2005/08/17 02:20:25 arudas noship $ */
3 /*===========================================================================
4 PACKAGE NAME: PO_DISTRIBUTIONS_SV
5
6 DESCRIPTION: Contains all the server side procedures
7 that access the entity, PO_DISTRIBUTIONS_SV
8
9 CLIENT/SERVER: Server
10
11 LIBRARY NAME None
12
13 OWNER: MCHIHAOU
14
15 PROCEDURE NAMES: check_unique
16 check_max_dist_num
17 select_summary
18 get_dest_type
19 ===========================================================================*/
20
21
22 /*===========================================================================
23 PROCEDURE NAME: check_unique()
24
25 DESCRIPTION:
26
27 PARAMETERS:
28
29 DESIGN REFERENCES:
30
31 ALGORITHM:
32
33 NOTES:
34
35 OPEN ISSUES:
36
37 CLOSED ISSUES:
38
39 CHANGE HISTORY:
40 ===========================================================================*/
41
42 FUNCTION check_unique(x_line_location_id NUMBER,
43 x_distribution_num NUMBER,
44 x_rowid VARCHAR2) RETURN BOOLEAN;
45
46 -- bug3322899 START
47 /*===========================================================================
48
49 FUNCTION NAME: distribution_num_unique()
50
51 ===========================================================================*/
52 FUNCTION distribution_num_unique
53 ( p_line_location_id IN NUMBER,
54 p_distribution_num IN NUMBER,
55 p_rowid IN VARCHAR2 DEFAULT NULL
56 ) RETURN BOOLEAN;
57 -- bug3322899 END
58
59 /*===========================================================================
60 PROCEDURE NAME: get_max_dist_num
61
62 DESCRIPTION: get the maximum number for the distribution lines that
63 have been committed to the Database.
64
65 PARAMETERS:
66
67
68 DESIGN REFERENCES:
69
70 ALGORITHM:
71
72 NOTES:
73
74 OPEN ISSUES:
75
76 CLOSED ISSUES:
77
78 CHANGE HISTORY:
79 ===========================================================================*/
80 FUNCTION get_max_dist_num( X_line_location_id NUMBER)
81 RETURN NUMBER;
82
83 /*===========================================================================
84 PROCEDURE NAME: select_summary
85
86 DESCRIPTION: Running total implementation for quantity_ordered
87 implemented according to standards.
88
89 PARAMETERS:
90
91
92 DESIGN REFERENCES:
93
94 ALGORITHM:
95
96 NOTES:
97
98 OPEN ISSUES:
99
100 CLOSED ISSUES:
101
102 CHANGE HISTORY:
103 ===========================================================================*/
104 PROCEDURE select_summary( X_line_location_id IN OUT NOCOPY NUMBER,
105 X_total IN OUT NOCOPY NUMBER);
106
107
108 /*===========================================================================
109 FUNCTION NAME: post_query
110
111 DESCRIPTION: Returns the deliver_to_location and the
112 deliver_to_person when given the
113 deliver_to_person_id and deliver_to_location_id.
114
115 PARAMETERS:
116
117
118 DESIGN REFERENCES:
119
120 ALGORITHM:
121
122 NOTES:
123
124 OPEN ISSUES:
125
126 CLOSED ISSUES:
127
128 CHANGE HISTORY:
129 ===========================================================================*/
130
131 PROCEDURE post_query(
132 x_deliver_to_location_id NUMBER,
133 x_deliver_to_person_id NUMBER,
134 x_ship_to_org_id NUMBER,
135 x_project_id NUMBER,
136 x_task_id NUMBER,
137 x_org_id NUMBER,
138 x_destination_type_code VARCHAR2,
139 x_deliver_to_location IN OUT NOCOPY VARCHAR2,
140 x_deliver_to_person IN OUT NOCOPY VARCHAR2,
141 x_project_num IN OUT NOCOPY VARCHAR2,
142 x_task_num IN OUT NOCOPY VARCHAR2,
143 x_org_code IN OUT NOCOPY VARCHAR2,
144 --togeorge 10/03/2000
145 -- added to bring oke line info during post query.
146 x_oke_contract_header_id IN NUMBER default null,
147 x_oke_contract_line_id IN NUMBER default null,
148 x_oke_contract_line_num IN OUT NOCOPY VARCHAR2,
149 x_oke_contract_deliverable_id IN NUMBER default null,
150 x_oke_contract_deliverable_num IN OUT NOCOPY VARCHAR2
151 );
152
153 /*===========================================================================
154 FUNCTION NAME: get_dest_type
155
156 DESCRIPTION: Returns the destination_type when given the
157 destination_type_code.
158
159 PARAMETERS:
160
161
162 DESIGN REFERENCES:
163
164 ALGORITHM:
165
166 NOTES:
167
168 OPEN ISSUES:
169
170 CLOSED ISSUES:
171
172 CHANGE HISTORY:
173 ===========================================================================*/
174 FUNCTION get_dest_type( x_destination_type_code VARCHAR2) return VARCHAR2;
175
176
177
178 /*===========================================================================
179 FUNCTION NAME: delete_distributions
180
181 DESCRIPTION: Delete distributions based on entity and id
182
183 PARAMETERS: See below
184
185 DESIGN REFERENCES:
186
187 ALGORITHM:
188
189 NOTES:
190
191 OPEN ISSUES:
192
193 CLOSED ISSUES:
194
195 CHANGE HISTORY: KPOWELL 10/10 CREATED
196 ===========================================================================*/
197 PROCEDURE delete_distributions(x_delete_id NUMBER,
198 x_delete_entity VARCHAR2);
199
200 /*===========================================================================
201 PROCEDURE NAME: get_total_dist_qty()
202 DESCRIPTION: Gets the remaining distribution quantity so
203 it can be defaulted on to the distribution.
204 PARAMETERS: X_po_line_location_id IN NUMBER
205 X_total_quantity IN OUT NUMBER
206 DESIGN REFERENCES:
207 ALGORITHM: Get the total quantity for all distributions
208 against the shipment.
209 NOTES:
210 OPEN ISSUES:
211 CLOSED ISSUES:
212 CHANGE HISTORY: KPOWELL 4/20 Created
213 ===========================================================================*/
214 PROCEDURE test_get_total_dist_qty
215 (X_po_line_location_id IN NUMBER);
216 PROCEDURE get_total_dist_qty
217 (X_po_line_location_id IN NUMBER,
218 X_total_quantity IN OUT NOCOPY NUMBER);
219 /*===========================================================================
220 PROCEDURE NAME: val_distribution_exists()
221 DESCRIPTION: Validates if a distribution exists for a
222 shipment
223 PARAMETERS: X_po_line_location_id IN NUMBER
224 RETURN BOOLEAN
225 DESIGN REFERENCES:
226 ALGORITHM: Validate if a distribution exists for a
227 shipment
228 NOTES:
229 OPEN ISSUES:
230 CLOSED ISSUES:
231 CHANGE HISTORY: KPOWELL 4/20 Created
232 ===========================================================================*/
233 FUNCTION val_distribution_exists
234 (X_po_line_location_id IN NUMBER) RETURN BOOLEAN;
235 PROCEDURE test_val_distribution_exists
236 (X_po_line_location_id IN NUMBER);
237 /*===================================================================
238
239 PROCEDURE NAME : performed_rcv_or_bill_activity (bug 4239813, 4239805)
240
241 =====================================================================*/
242 function performed_rcv_or_bill_activity(p_line_location_id IN NUMBER,
243 p_distribution_id IN NUMBER)
244 RETURN BOOLEAN;
245
246 --<HTML Agreements R12 Start>
247 PROCEDURE validate_delete_distribution(p_po_distribution_id IN NUMBER
248 ,p_line_loc_id IN NUMBER
249 ,p_approved_date IN VARCHAR2
250 ,p_style_disp_name IN VARCHAR2
253 END po_distributions_sv;251 ,x_message_text OUT NOCOPY VARCHAR2);
252 --<HTML Agreements R12 End>