DBA Data[Home] [Help]

PACKAGE BODY: APPS.PO_EDI_INTEGRATION_GRP

Source


1 PACKAGE BODY PO_EDI_INTEGRATION_GRP AS
2 /* $Header: POXGEDIB.pls 115.1 2004/06/30 03:05:49 zxzhang noship $*/
3 
4  --CONSTANTS
5 
6  G_PKG_NAME CONSTANT varchar2(30) := 'PO_EDI_INTEGRATION_GRP';
7 
8  c_log_head    CONSTANT VARCHAR2(50) := 'po.plsql.'|| G_PKG_NAME || '.';
9 
10  -- Read the profile option that enables/disables the debug log
11  g_fnd_debug VARCHAR2(1) := NVL(FND_PROFILE.VALUE('AFLOG_ENABLED'),'N');
12 
13  g_debug_stmt  CONSTANT BOOLEAN := PO_DEBUG.is_debug_stmt_on;
14  g_debug_unexp CONSTANT BOOLEAN := PO_DEBUG.is_debug_unexp_on;
15 
16 /**
17 * Public Procedure: archive_po
18 * Requires:
19 *   IN PARAMETERS:
20 *     p_api_version:       Version number of API that caller expects. It
21 *                          should match the l_api_version defined in the
22 *                          procedure (expected value : 1.0)
23 *     p_document_id:       The id of the document that needs to be archived.
24 *     p_document_type:     The type of the document to archive
25 *                          PO : For Standard/Planned
26 *                          PA : For Blanket/Contract
27 *                          RELEASE : Release
28 *     p_document_subtype:  The subtype of the document.
29 *                          Valid Document types and Document subtypes are
30 *                          Document Type      Document Subtype
31 *                          RELEASE      --->  SCHEDULED/BLANKET
32 *                          PO           --->  PLANNED/STANDARD
33 *                          PA           --->  CONTRACT/BLANKET
34 *
35 * Modifies: Arcives the document. Inserts an copy of the document in the
36 *           archive tables
37 * Effects:  This procedure archives the document that is passed in
38 *
39 * Returns:
40 *  x_return_status:    FND_API.G_RET_STS_SUCCESS if API succeeds
41 *                      FND_API.G_RET_STS_ERROR if API fails
42 *                      FND_API.G_RET_STS_UNEXP_ERROR if unexpected error occurs
43 *  x_msg_data:         Contains error msg in case x_return_status returned
44 *                      FND_API.G_RET_STS_ERROR or FND_API.G_RET_STS_UNEXP_ERROR
45 */
46 PROCEDURE archive_po(p_api_version         IN         NUMBER,
47   		     p_document_id         IN         NUMBER,
48   		     p_document_type       IN         VARCHAR2,
49   		     p_document_subtype    IN         VARCHAR2,
50   		     x_return_status       OUT NOCOPY VARCHAR2,
51                      x_msg_count	   OUT NOCOPY NUMBER,
52   		     x_msg_data            OUT NOCOPY VARCHAR2)
53 IS
54   l_api_name    CONSTANT VARCHAR(30) := 'ARCHIVE_PO';
55   l_api_version CONSTANT NUMBER := 1.0;
56   l_progress    VARCHAR2(3) := '000';
57   l_log_head    CONSTANT VARCHAR2(100) := c_log_head || '.' || l_api_name;
58 BEGIN
59 
60   PO_DOCUMENT_ARCHIVE_GRP.archive_po(
61     p_api_version      => p_api_version,
62     p_document_id      => p_document_id,
63     p_document_type    => p_document_type,
64     p_document_subtype => p_document_subtype,
65     x_return_status    => x_return_status,
66     x_msg_count        => x_msg_count,
67     x_msg_data         => x_msg_data);
68 
69 END archive_po;
70 
71 
72 END PO_EDI_INTEGRATION_GRP;