DBA Data[Home] [Help]

PACKAGE: APPS.PO_HEADERS_SV2

Source


1 PACKAGE PO_HEADERS_SV2 AUTHID CURRENT_USER AS
2 /* $Header: POXPOH2S.pls 115.5 2003/11/01 00:05:04 dxie ship $*/
3 
4 /*===========================================================================
5   PROCEDURE NAME:	val_approval_status()
6 
7   DESCRIPTION:
8                 Verify if any of the values have changed from their
9                 old values ( by selecting from  the db for the same rowid)
10                            Agent Id
11                            Vendor Site Id
12                            Contact Id
13                            confirming_order_flag
14                            bill_to_location_id
15                            terms_id
16                            ship_via_lookup_code
17                            fob_lookup_code
18                            freight_terms_lookup_code
19                            note_to_vendor
20                            acceptance_required_flag
21                            acceptance_due_date
22                            blanket_total_amount
23                            start_date
24                            end_date
25                            amount_limit
26 			   conterms_articles_upd_date   --<CONTERMS FPJ>
27 			   conterms_deliv_upd_date      --<CONTERMS FPJ>
28          				 - Refresh the document status.
29 			  PARAMETERS:
30 
31   DESIGN REFERENCES:	../POXPOMPO.doc
32 
33   ALGORITHM:
34 
35   NOTES:
36 
37   OPEN ISSUES:
38 
39   CLOSED ISSUES:
40 
41   CHANGE HISTORY:
42 ===========================================================================*/
43 
44  FUNCTION  val_approval_status(X_po_header_id             IN NUMBER,
45 		               X_agent_id                 IN NUMBER,
46                                X_vendor_site_id           IN NUMBER,
47                                X_vendor_contact_id        IN NUMBER,
48                                X_confirming_order_flag    IN VARCHAR2,
49                                X_ship_to_location_id      IN NUMBER,
50                                X_bill_to_location_id      IN NUMBER,
51                                X_terms_id                 IN NUMBER,
52                                X_ship_via_lookup_code     IN VARCHAR2,
53                                X_fob_lookup_code          IN VARCHAR2,
54                                X_freight_terms_lookup_code IN VARCHAR2,
55                                X_note_to_vendor            IN VARCHAR2,
56                                X_acceptance_required_flag  IN VARCHAR2,
57                                X_acceptance_due_date       IN DATE,
58                                X_blanket_total_amount      IN NUMBER,
59                                X_start_date                IN DATE,
60                                X_end_date                  IN DATE,
61                                X_amount_limit             IN NUMBER
62 			       ,p_kterms_art_upd_date       IN DATE --<CONTERMS FPJ>
63 			       ,p_kterms_deliv_upd_date     IN DATE --<CONTERMS FPJ>
64                                ,p_shipping_control           IN VARCHAR2 -- <INBOUND LOGISTICS FPJ>
65 )
66            RETURN BOOLEAN;
67 
68 /*===========================================================================
69   PROCEDURE NAME:	update_children()
70 
71   DESCRIPTION:
72 	 - Refresh the document status.
73 			  PARAMETERS:
74 
75   DESIGN REFERENCES:	../POXPOMPO.doc
76 
77   ALGORITHM:
78 
79   NOTES:
80 
81   OPEN ISSUES:
82 
83   CLOSED ISSUES:
84 
85   CHANGE HISTORY:
86 ===========================================================================*/
87 
88 --PROCEDURE update_children();
89 
90 
91 /*===========================================================================
92   FUNCTION NAME:	val_release_date()
93 
94   DESCRIPTION:
95 
96 	If the end date is not null we check if there has a release
97 	against this po (for planned pos/blankets only) after the end date.
98 	if yes we give the user the message PO_ALL_DATE_BETWEEN_START_END
99 	Check the notification controls when this field is changed.
100         If there are any date based controls , display the error message
101         PO_PO_NFC_DATE_CONTROLS_EXIST.  This returns failure.
102 
103   PARAMETERS:
104 
105   RETURN VALUE:
106 
107   DESIGN REFERENCES:	../POXPOMPO.doc
108 
109   ALGORITHM:
110 
111   NOTES:
112 
113   OPEN ISSUES:
114 
115   CLOSED ISSUES:
116 
117   CHANGE HISTORY:
118 ===========================================================================*/
119 
120  FUNCTION val_release_date(X_po_header_id number,
121                            X_start_date date,
122                            X_end_date  date,
123                            X_type_lookup_code varchar2,
124                            X_menu_path varchar2)
125             return boolean;
126 
127 /*===========================================================================
128   FUNCTION NAME:	val_start_date()
129 
130   DESCRIPTION: This function checks if there are any releases that have been
131                made prior to the start date ( for a PLANNED PO/BLANKET)
132 
133 
134   PARAMETERS:
135 
136   RETURN VALUE:
137 
138   DESIGN REFERENCES:	../POXPOMPO.doc
139 
140   ALGORITHM:
141 
142   NOTES:
143 
144   OPEN ISSUES:
145 
146   CLOSED ISSUES:
147 
148   CHANGE HISTORY:
149 ===========================================================================*/
150 
151 function  val_start_date(X_Po_Header_Id                     NUMBER,
152                             X_start_date                       DATE  )
153              return boolean;
154 
155 /*===========================================================================
156   FUNCTION NAME:	val_end_date()
157 
158   DESCRIPTION:  Check that there is no release against this PO after the date
159                 specified.
160 
161 
162   PARAMETERS:
163 
164   RETURN VALUE:
165 
166   DESIGN REFERENCES:	../POXPOMPO.doc
167 
168   ALGORITHM:
169 
170   NOTES:
171 
172   OPEN ISSUES:
173 
174   CLOSED ISSUES:
175 
176   CHANGE HISTORY:
177 ===========================================================================*/
178 
179 FUNCTION  val_end_date(X_Po_Header_Id                   NUMBER,
180                        X_end_date                       DATE  )
181 
182          return boolean;
183 
184 /*==========================================================================
185 
186   PROCEDURE NAME : update_req_link()
187 
188 
189   DESCRIPTION:  This procedure removes the link to a PO in the Requisition_Lines
190                 Table when the PO is being deleted.
191 
192   PARAMETERS:
193 
194   DESIGN REFERENCES:	../POXPOMPO.doc
195 
196   ALGORITHM:
197 
198   NOTES:
199 
200   OPEN ISSUES:
201 
202   CLOSED ISSUES:
203 
204   CHANGE HISTORY:
205 
206 ===========================================================================*/
207 
208  PROCEDURE update_req_link(X_po_header_id IN NUMBER);
209 
210 /*===========================================================================
211   PROCEDURE NAME:	get_po_details()
212 
213   DESCRIPTION:   Get the purchase order details that are associated with
214       the purchase order header id.  This routine is called
215       from the Enter Releases Form after picking the PO Number
216       that you would like to create a release against.
217 
218   PARAMETERS:
219 
220   DESIGN REFERENCES:	../POXPOREL.doc
221 
222   ALGORITHM:
223 
224   NOTES:
225 
226   OPEN ISSUES:
227 
228   CLOSED ISSUES:
229 
230   CHANGE HISTORY:
231 ===========================================================================*/
232 
233 PROCEDURE get_po_details(X_po_header_id IN NUMBER,
234 		         X_type_lookup_code    IN OUT NOCOPY VARCHAR2,
235                          X_revision_num        IN OUT NOCOPY NUMBER,
236 		         X_currency_code       IN OUT NOCOPY VARCHAR2,
237                          X_supplier_id         IN OUT NOCOPY NUMBER,
238                          X_supplier_site_id    IN OUT NOCOPY NUMBER,
239                          X_ship_to_location_id IN OUT NOCOPY NUMBER);
240 
241 /*===========================================================================
242   PROCEDURE NAME:	get_segment1_details()
243 
244   DESCRIPTION:
245   PARAMETERS:
246 
247   DESIGN REFERENCES:	../POXPOREL.doc
248 
249   ALGORITHM:
250 
251   NOTES:
252 
253   OPEN ISSUES:
254 
255   CLOSED ISSUES:
256 
257   CHANGE HISTORY:
258 ===========================================================================*/
259 
260 -- PROCEDURE get_segment1_details();
261 
262 procedure test_start_date ( X_po_header_id IN number, X_start_date IN date);
263 procedure test_get_po_encumbered (X_po_header_id IN number);
264 
265 /*===========================================================================
266   PROCEDURE NAME:	get_document_status()
267 
268   DESCRIPTION:   This procedure gets the displayed value for the document status
269                  for a given lookup_code ( for eg. INCOMPLETE)
270 
271   PARAMETERS:
272 
273   DESIGN REFERENCES:	../POXPOMPO.doc
274 			../POXSCERQ.dd
275 
276   ALGORITHM:
277 
278   NOTES:
279 
280   OPEN ISSUES:
281 
282   CLOSED ISSUES:
283 
284   CHANGE HISTORY:
285 ===========================================================================*/
286 
287   procedure get_document_status(X_lookup_code IN varchar2,
288 				X_document_type IN varchar2,
289 				X_document_status IN OUT NOCOPY varchar2);
290 
291 
292 -- <GC FPJ START>
293 
294 /**=========================================================================
295 * Procedure: val_contract_eff_date                  <GC FPJ>
296 * Effects:   Check whether there is any standard PO line that is not created
297 *            within the effective dates of the contract
298 * Requires:  None
299 * Modifies:  None
300 * Returns:   x_result: FND_API.G_TRUE if all lines are within the effective
301 *                      dates
302 *                      FND_API.G_FALSE if there exists a line not being
303 *                      created within the effective dates of the contract it
304 *                      is referecing
305 ==========================================================================**/
306 
307 PROCEDURE val_contract_eff_date
308 ( p_po_header_id     IN         NUMBER,
309   p_start_date       IN         DATE,
310   p_end_date         IN         DATE,
311   x_result           OUT NOCOPY VARCHAR2
312 );
313 
314 -- <GC FPJ END>
315 
316 END PO_HEADERS_SV2;