DBA Data[Home] [Help]

PACKAGE BODY: APPS.WMS_DEVICE_INTEGRATION_PUB

Source


1 PACKAGE BODY WMS_Device_Integration_PUB AS
2 /* $Header: WMSDEVIB.pls 120.1 2005/06/03 09:59:16 appldev  $ */
3 
4 --
5 -- Name
6 --   PROCEDURE SYNC_DEVICE_REQUEST
7 --
8 -- Purpose
9 --    This procedure is meant to initiate a request to a WMS Device.
10 --    It is expected that 3rd party device vendors would extend this
11 --    package to implement the actual logic required to interface with
12 --    the device.
13 --      The primary source of input to this package would be the Temporary
14 --    table WMS_DEVICE_REQUEST.
15 --
16 -- Input Parameters
17 --   p_request_id    : Request ID
18 --   p_device_id     : Device ID of the device this request is initiated for
19 --   p_resubmit_flag : N - Invoked in conjunction with processing transaction
20 --                     Y - Invoked to resubmit a request to device
21 --
22 -- Output Parameters
23 --   x_status_code  :  Status of request. ( S = Success, E = Error)
24 --   x_status_msg   :  Optional status message related to this specific request
25 --   x_device_status: Optional status message related to the device
26 --
27 --
28   PROCEDURE SYNC_DEVICE_REQUEST(
29      p_request_id            IN  NUMBER,
30      p_device_id             IN  NUMBER,
31      p_resubmit_flag         IN  VARCHAR2,
32      x_status_code          OUT NOCOPY VARCHAR2,
33      x_status_msg           OUT NOCOPY VARCHAR2,
34      x_device_status        OUT NOCOPY VARCHAR2 ) IS
35 	BEGIN
36    x_status_msg := 'Success';
37    x_device_status := 'Success';
38    x_status_code := FND_API.g_ret_sts_success;
39 	END;
40 
41 
42 --
43 -- Name
44 --   UPDATE_REQUEST
45 --
46 -- Purpose
47 --    This procedure is provided to update the status of a request
48 --    from a transaction cycle seperate from the one in which the
49 --    request was initiated. This is meant to update a device request
50 --    in an asynchronous mode.
51 --
52 -- Input Parameters
53 --   p_request_id    : Request Id
54 --   p_device_id     : Device Identifier, if data comprising this request was
55 --                       directed to multiple devices
56 --   p_status_code  :  Status of request. ( S = Success, E = Error)
57 --   p_status_msg   :  Optional status message related to this specific request
58 --
59 --
60 	PROCEDURE UPDATE_REQUEST(
61 			p_request_id           IN   NUMBER,
62 			p_device_id            IN   NUMBER := NULL,
63 			p_status_code          IN   VARCHAR2,
64 			p_status_msg           IN   VARCHAR2 := NULL
65 		) IS
66 	BEGIN
67 		UPDATE WMS_DEVICE_REQUESTS_HIST
68 			SET STATUS_CODE = p_status_code,
69 					STATUS_MSG  = p_status_msg
70 			WHERE
71 						REQUEST_ID  = p_request_id
72 				AND DEVICE_ID   = NVL(p_device_id, DEVICE_ID);
73 	END;
74 
75 
76 	--
77 -- Name
78 --   PROCEDURE SYNC_DEVICE
79 --
80 -- Purpose
81 --    This procedure is meant to invoke or terminate a WMS Device.
82 --    It is expected that 3rd party device vendors would extend this
83 --    package to implement the actual logic required to interface with
84 --    the device.
85 --
86 -- Input Parameters
87 --   p_organization_id : Request ID
88 --   p_device_id       : Device ID of the device
89 --   p_employee_id     : Employee ID of the employee who invokes or
90 --	                 terminates the device.
91 --   p_sign_on_flag    : 'Y' when signing on
92 --                       'N' when signing off
93 --
94 -- Output Parameters
95 --   x_status_code  :  Status of request. ( S = Success, E = Error)
96 --   x_device_status:  Optional status message related to the device
97 --
98 --
99   PROCEDURE SYNC_DEVICE(
100 			p_organization_id      IN  NUMBER,
101 			p_device_id            IN  NUMBER,
102 			p_employee_id          IN  NUMBER,
103 			p_sign_on_flag         IN  VARCHAR2,
104 			x_status_code          OUT NOCOPY VARCHAR2,
105 			x_device_status        OUT NOCOPY VARCHAR2 ) IS
106   BEGIN
107      x_device_status := 'Success';
108      x_status_code := FND_API.g_ret_sts_success;
109   END;
110 
111 
112 END WMS_Device_Integration_PUB;