1 package CTO_MANUAL_LINK_CONFIG as
2 /* $Header: CTOLINKS.pls 120.1 2005/06/21 16:17:57 appldev ship $ */
3 /*============================================================================+
4 | Copyright (c) 1993 Oracle Corporation Belmont, California, USA |
5 | All rights reserved. |
6 | Oracle Manufacturing |
7 +=============================================================================+
8 | |
9 | FILE NAME : CTOLINKS.pls |
10 | DESCRIPTION: |
11 | This file creates a package that containst procedures called |
12 | from the Match and Reserve menu from Order Entry's Enter |
13 | Orders form. |
14 | |
15 | match_inquiry - |
16 | This function is called when the Match and Reserve |
17 | menu is invoked. It does the following: |
18 | 1. Checks if the order line is eligible to be matched |
19 | and reserved. |
20 | 2. If it is, it determines if the order line is already |
21 | linked to a configuration item. If it is, it uses that |
22 | config item in the available quantity inquiry. If it |
23 | does not, it attempts to match the configuration from |
24 | oe_order_lines against bom_ato_configurations. |
25 | 3. If a configuration item exists, it calls Inventory's |
26 | API to query available quantity (on-hand and available |
27 | to reserve). If it has any quantity available to reserve |
28 | it returns true. |
29 | |
30 | |
31 | To Do: Handle Errors. Need to discuss with Usha and Girish what |
32 | error information to include in Notification. |
33 | |
34 | HISTORY : |
35 | May 10, 99 Angela Makalintal Initial version |
36 =============================================================================*/
37
38 /*****************************************************************************
39 Function: match_inquiry
40 Parameters: p_model_line_id - line id of the top model in oe_order_lines
41 x_match_config_id - config id of the matching configuration
42 from bom_ato_configurations
43 x_error_message - error message if match function fails
44 x_message_name - name of error message if match
45 function fails
46
47 Description: This function looks for a configuration in
48 bom_ato_configurations that matches the ordered
49 configuration in oe_order_lines.
50
51 *****************************************************************************/
52
53
54 function link_config(
55 p_model_line_id in number,
56 p_config_item_id in number,
57 x_error_message out NOCOPY varchar2,
58 x_message_name out NOCOPY varchar2
59 )
60 RETURN boolean;
61
62 FUNCTION Validate_Link(p_model_line_id in number,
63 p_config_item_id in number,
64 x_error_message out NOCOPY varchar2,
65 x_message_name out NOCOPY varchar2
66 )
67 RETURN integer;
68
69 end CTO_MANUAL_LINK_CONFIG;