DBA Data[Home] [Help]

PACKAGE: APPS.PON_PRINTING_PKG

Source


1 PACKAGE PON_PRINTING_PKG AUTHID CURRENT_USER as
2 /* $Header: PONPRNS.pls 120.9.12010000.3 2009/02/20 03:22:02 jianliu ship $ */
3 ----------------------------------------------------------------
4 -- Creates a xml file for negotiation emd report              --
5 -- it as a clob                                               --
6 ----------------------------------------------------------------
7   FUNCTION generate_emd_xml(p_auction_header_id          IN NUMBER)
8   RETURN CLOB;
9 ----------------------------------------------------------------
10 -- Creates a xml file for individual supplier report          --
11 -- it as a clob                                               --
12 ----------------------------------------------------------------
13   FUNCTION generate_supplier_xml(p_auction_header_id          IN NUMBER,
14                                  p_supplier_sequence         IN NUMBER
15                                 )
16   RETURN CLOB;
17 
18 ----------------------------------------------------------------
19 -- Creates a  xml file for receipt of individual supplier report          --
20 -- it as a clob                                               --
21 ----------------------------------------------------------------
22   FUNCTION generate_receipt_xml(p_auction_header_id          IN NUMBER,
23                                  p_supplier_sequence         IN NUMBER
24                                 )
25   RETURN CLOB;
26 
27 ----------------------------------------------------------------
28 -- Creates a xml file for the auction id and returns          --
29 -- it as a clob                                               --
30 ----------------------------------------------------------------
31   FUNCTION generate_auction_xml(p_auction_header_id          IN NUMBER,
32                                 p_client_time_zone           IN VARCHAR2,
33                                 p_server_time_zone           IN VARCHAR2,
34                                 p_date_format                IN VARCHAR2,
35                                 p_trading_partner_id         IN NUMBER,
36                                 p_trading_partner_name       IN VARCHAR2,
37                                 p_vendor_site_id             IN NUMBER,
38                                 p_user_view_type             IN VARCHAR2,
39                                 p_printing_warning_flag      IN VARCHAR2  DEFAULT 'N',
40                                 p_neg_printed_with_contracts IN VARCHAR2  DEFAULT 'N',
41                                 p_requested_supplier_id      IN NUMBER,
42                                 p_requested_supplier_name    IN VARCHAR2,
43 				p_trading_partner_contact_id IN NUMBER)
44   RETURN CLOB;
45 
46 -------------------------------------------------------------------------------
47 -- If p_bid_number > 0 , Creates a xml file for the bid number and returns   --
48 -- it as a clob. If p_bid_number <= 0, creates a xml file for the auction id --
49 -------------------------------------------------------------------------------
50   FUNCTION generate_auction_xml(p_auction_header_id          IN NUMBER,
51                                 p_client_time_zone           IN VARCHAR2,
52                                 p_server_time_zone           IN VARCHAR2,
53                                 p_date_format                IN VARCHAR2,
54                                 p_trading_partner_id         IN NUMBER,
55                                 p_trading_partner_name       IN VARCHAR2,
56                                 p_vendor_site_id             IN NUMBER,
57                                 p_user_view_type             IN VARCHAR2,
58                                 p_printing_warning_flag      IN VARCHAR2  DEFAULT 'N',
59                                 p_neg_printed_with_contracts IN VARCHAR2  DEFAULT 'N',
60                                 p_requested_supplier_id      IN NUMBER,
61                                 p_requested_supplier_name    IN VARCHAR2,
62 				p_trading_partner_contact_id IN NUMBER,
63                                 p_bid_number                 IN NUMBER,
64                                 p_user_id                    IN NUMBER)
65   RETURN CLOB;
66 
67 --  Overloaded version of the above procedure without trading_partner_contact_id
68 --  Kept here for backward compatibility - can be removed once all the dependent
69 --  changes are done.
70 
71   FUNCTION generate_auction_xml(p_auction_header_id          IN NUMBER,
72                                 p_client_time_zone           IN VARCHAR2,
73                                 p_server_time_zone           IN VARCHAR2,
74                                 p_date_format                IN VARCHAR2,
75                                 p_trading_partner_id         IN NUMBER,
76                                 p_trading_partner_name       IN VARCHAR2,
77                                 p_vendor_site_id             IN NUMBER,
78                                 p_user_view_type             IN VARCHAR2,
79                                 p_printing_warning_flag      IN VARCHAR2  DEFAULT 'N',
80                                 p_neg_printed_with_contracts IN VARCHAR2  DEFAULT 'N',
81                                 p_requested_supplier_id      IN NUMBER,
82                                 p_requested_supplier_name    IN VARCHAR2)
83   RETURN CLOB;
84 ----------------------------------------------------------------
85 -- Gets the message after substituting the token values       --
86 ----------------------------------------------------------------
87 FUNCTION GET_MESSAGES(p_message_name in VARCHAR2,
88                       p_token_name in VARCHAR2,
89                       p_token_value in VARCHAR2) return VARCHAR2;
90 
91 ----------------------------------------------------------------
92 -- Returns the corresponding value of the message name after  --
93 -- substituting it with the the two token                   --
94 ----------------------------------------------------------------
95   FUNCTION GET_MESSAGES(p_message_name in VARCHAR2,
96                         p_token_name1 in VARCHAR2,
97                         p_token_value1 in VARCHAR2,
98                         p_token_name2 in VARCHAR2,
99                         p_token_value2 in VARCHAR2) return VARCHAR2;
100 
101 ----------------------------------------------------------------
102 -- Returns the corresponding value of the message name after  --
103 -- substituting it with the the three token                   --
104 ----------------------------------------------------------------
105   FUNCTION GET_MESSAGES(p_message_name in VARCHAR2,
106                         p_token_name1 in VARCHAR2,
107                         p_token_value1 in VARCHAR2,
108                         p_token_name2 in VARCHAR2,
109                         p_token_value2 in VARCHAR2,
110                         p_token_name3 in VARCHAR2,
111                         p_token_value3 in VARCHAR2) return VARCHAR2;
112 
113 ----------------------------------------------------------------
114 -- Returns the corresponding value of the mesage name after   --
115 -- substituting it with the token. The message name is formed --
116 -- by joining the message name and message suffix parameters  --
117 ----------------------------------------------------------------
118 FUNCTION GET_MESSAGES(p_message_name in VARCHAR2,
119                         p_message_suffix in VARCHAR2,
120                         p_token_name in VARCHAR2,
121                         p_token_value in VARCHAR2) return VARCHAR2;
122 
123 ----------------------------------------------------------------
124 -- Adds the suffix to the message to generate the  document   --
125 -- specific messages name                                     --
126 ----------------------------------------------------------------
127 FUNCTION GET_DOCUMENT_MESSAGE_NAME(p_message_name in VARCHAR2,
128                                    p_message_suffix in VARCHAR2) return VARCHAR2;
129 
130 ----------------------------------------------------------------
131 -- Returns Y if XDO is installed                              --
132 ----------------------------------------------------------------
133 
134 FUNCTION is_xdo_installed RETURN VARCHAR2;
135 
136 ---------------------------------------------------------------
137 -- Returns the rate to be displayed                           --
138 ----------------------------------------------------------------
139 FUNCTION GET_DISPLAY_RATE(p_rate_dsp in NUMBER,
140 	                        p_rate_type in VARCHAR2,
141                           p_rate_date in DATE,
142                           p_auction_currency_code in VARCHAR2,
143                           p_bid_currency_code in VARCHAR2) return VARCHAR2;
144 
145 -----------------------------------------------------------------
146 -- Returns the email of the user. Creating this method instead --
147 -- of an outer join as in hz contact points table same email   --
148 -- record with active status of type MAILHTML existed. This was--
149 -- leading 2 records for all the queries.                      --
150 -----------------------------------------------------------------
151 FUNCTION GET_USER_EMAIL(p_user_party_id in NUMBER) return VARCHAR2;
152 
153 ----------------------------------------------------------------
154 -- Formats the number based passed. If the number does not    --
155 -- decimal part then the decimal separator will not be        --
156 -- displayed. If the number is less that 0 then 0 will        --
157 -- be displayed before the decimal separator                  --
158 ----------------------------------------------------------------
159 FUNCTION FORMAT_NUMBER(p_number in NUMBER) return VARCHAR2;
160 
161  ----------------------------------------------------------------
162   -- Formats the number which is a varchar.                 --
163   ----------------------------------------------------------------
164 FUNCTION FORMAT_NUMBER_STRING(p_value in VARCHAR2) return VARCHAR2;
165 ----------------------------------------------------------------
166 -- Formats the price passed based on the format passed.       --
167 -- If the price does have a decimal part then the decimal     --
168 -- separator will not be displayed. If the price is less      --
169 -- that 0 then 0 will be displayed before the decimal         --
170 -- separator                                                  --
171 ----------------------------------------------------------------
172 FUNCTION FORMAT_PRICE(p_price in NUMBER,
173                       p_format_mask in VARCHAR2,
174                       p_precision IN NUMBER)
175                       return VARCHAR2;
176 
177   ----------------------------------------------------------------
178 	-- Formats the response value of the attributes         --
179   ----------------------------------------------------------------
180   FUNCTION PRINT_ATTRIBUTE_RESPONSE_VALUE(
181                                         p_value in VARCHAR2,
182                                         p_datatype in VARCHAR2,
183                                         p_client_time_zone in VARCHAR2,
184                                         p_server_time_zone in VARCHAR2,
185                                         p_date_format in VARCHAR2,
186                                         p_attribute_sequence_number in NUMBER
187                                         )
188                                         RETURN VARCHAR2;
189 ----------------------------------------------------------------
190 -- Formats the target value of the attributes                 --
191 ----------------------------------------------------------------
192 FUNCTION PRINT_ATTRIBUTE_TARGET_VALUE(p_show_target_value  in VARCHAR2,
193                                       p_value in VARCHAR2,
194                                       p_datatype in VARCHAR2,
195                                       p_sequence_number in VARCHAR2,
196                                       p_client_time_zone in VARCHAR2,
197                                       p_server_time_zone in VARCHAR2,
198                                       p_date_format in VARCHAR2,
199                                       p_user_view_type IN VARCHAR2) RETURN VARCHAR2;
200 
201   ----------------------------------------------------------------
202   -- Retunrs the range / value of a for an attribute along with --
203   -- the score. The score will be displayed only if             --
204   -- p_show_bidder_scores is 'Y'                                --
205   ----------------------------------------------------------------
206 FUNCTION GET_ACCEPTABLE_VALUE(p_show_bidder_scores  in VARCHAR2,
207                               p_attribute_sequence_number NUMBER,
208                               p_score_data_type  in VARCHAR2,
209                               p_from_range  in VARCHAR2,
210                               p_to_range  in VARCHAR2,
211                               p_value  in VARCHAR2,
212                               p_score  in VARCHAR2,
213                               p_client_time_zone in VARCHAR2,
214                               p_server_time_zone in VARCHAR2,
215                               p_date_format in VARCHAR2,
216                               p_user_view_score IN VARCHAR2) RETURN VARCHAR2;
217 
218  -----------------------------------------------------------------
219  -- For Bug 4373655
223  -----------------------------------------------------------------
220  -- Returns the carrier name based on the carrier code and      --
221  -- inventory org id corresponding to the org_id passed a       --
222  -- parameter                                                   --
224  FUNCTION GET_CARRIER_DESCRIPTION(p_org_id in NUMBER,
225                                   p_carrier_code in VARCHAR2)
226                                   return VARCHAR2;
227 
228 ----------------------------------------------------------------
229 -- Calculate Response Total for supplier view.                --
230 ----------------------------------------------------------------
231 FUNCTION get_supplier_bid_total
232              (p_auction_header_id    IN NUMBER,
233               p_bid_number           IN NUMBER,
234               p_buyer_bid_total           IN NUMBER,
235               p_outcome              IN pon_auction_headers_all.contract_type%TYPE,
236               p_doctype_group_name   IN VARCHAR2,
237               p_bid_status           IN VARCHAR2
238               ) RETURN NUMBER;
239 
240 ----------------------------------------------------------------------
241 -- Returns whether the buyer has price visibility in scoring team   --
242 ----------------------------------------------------------------------
243  FUNCTION is_price_visible( p_auction_header_id          IN NUMBER,
244                              p_user_id             IN NUMBER
245                            ) RETURN VARCHAR2;
246 END PON_PRINTING_PKG;
247