[Home] [Help]
PACKAGE BODY: APPS.JTF_LOC_TYPES_PVT_W
Source
1 package body jtf_loc_types_pvt_w as
2 /* $Header: jtfwlotb.pls 120.2 2005/08/18 22:56:10 stopiwal ship $ */
3 rosetta_g_mistake_date date := to_date('01/01/+4713', 'MM/DD/SYYYY');
4 rosetta_g_miss_date date := to_date('01/01/-4712', 'MM/DD/SYYYY');
5
6 function rosetta_g_miss_num_map(n number) return number as
7 a number := fnd_api.g_miss_num;
8 b number := 0-1962.0724;
9 begin
10 if n=a then return b; end if;
11 if n=b then return a; end if;
12 return n;
13 end;
14
15 -- this is to workaround the JDBC bug regarding IN DATE of value GMiss
16 function rosetta_g_miss_date_in_map(d date) return date as
17 begin
18 if d = rosetta_g_mistake_date then return fnd_api.g_miss_date; end if;
19 return d;
20 end;
21
22 procedure update_loc_type(p_api_version NUMBER
23 , p_init_msg_list VARCHAR2
24 , p_commit VARCHAR2
25 , p_validation_level NUMBER
26 , x_return_status OUT NOCOPY /* file.sql.39 change */ VARCHAR2
27 , x_msg_count OUT NOCOPY /* file.sql.39 change */ NUMBER
28 , x_msg_data OUT NOCOPY /* file.sql.39 change */ VARCHAR2
29 , p7_a0 NUMBER := 0-1962.0724
30 , p7_a1 DATE := fnd_api.g_miss_date
31 , p7_a2 NUMBER := 0-1962.0724
32 , p7_a3 DATE := fnd_api.g_miss_date
33 , p7_a4 NUMBER := 0-1962.0724
34 , p7_a5 NUMBER := 0-1962.0724
35 , p7_a6 NUMBER := 0-1962.0724
36 , p7_a7 VARCHAR2 := fnd_api.g_miss_char
37 , p7_a8 VARCHAR2 := fnd_api.g_miss_char
38 , p7_a9 VARCHAR2 := fnd_api.g_miss_char
39 )
40 as
41 ddp_loc_type_rec jtf_loc_types_pvt.loc_type_rec_type;
42 ddindx binary_integer; indx binary_integer;
43 begin
44
45 -- copy data to the local IN or IN-OUT args, if any
46
47
48
49
50
51
52
53 ddp_loc_type_rec.location_type_id := rosetta_g_miss_num_map(p7_a0);
54 ddp_loc_type_rec.last_update_date := rosetta_g_miss_date_in_map(p7_a1);
55 ddp_loc_type_rec.last_updated_by := rosetta_g_miss_num_map(p7_a2);
56 ddp_loc_type_rec.creation_date := rosetta_g_miss_date_in_map(p7_a3);
57 ddp_loc_type_rec.created_by := rosetta_g_miss_num_map(p7_a4);
58 ddp_loc_type_rec.last_update_login := rosetta_g_miss_num_map(p7_a5);
59 ddp_loc_type_rec.object_version_number := rosetta_g_miss_num_map(p7_a6);
60 ddp_loc_type_rec.location_type_code := p7_a7;
61 ddp_loc_type_rec.location_type_name := p7_a8;
62 ddp_loc_type_rec.description := p7_a9;
63
64 -- here's the delegated call to the old PL/SQL routine
65 jtf_loc_types_pvt.update_loc_type(p_api_version,
66 p_init_msg_list,
67 p_commit,
68 p_validation_level,
69 x_return_status,
70 x_msg_count,
71 x_msg_data,
72 ddp_loc_type_rec);
73
74 -- copy data back from the local OUT NOCOPY /* file.sql.39 change */ or IN-OUT args, if any
75
76
77
78
79
80
81
82 end;
83
84 procedure check_items(p_validation_mode VARCHAR2
85 , x_return_status OUT NOCOPY /* file.sql.39 change */ VARCHAR2
86 , p2_a0 NUMBER := 0-1962.0724
87 , p2_a1 DATE := fnd_api.g_miss_date
88 , p2_a2 NUMBER := 0-1962.0724
89 , p2_a3 DATE := fnd_api.g_miss_date
90 , p2_a4 NUMBER := 0-1962.0724
91 , p2_a5 NUMBER := 0-1962.0724
92 , p2_a6 NUMBER := 0-1962.0724
93 , p2_a7 VARCHAR2 := fnd_api.g_miss_char
94 , p2_a8 VARCHAR2 := fnd_api.g_miss_char
95 , p2_a9 VARCHAR2 := fnd_api.g_miss_char
96 )
97 as
98 ddp_loc_type_rec jtf_loc_types_pvt.loc_type_rec_type;
99 ddindx binary_integer; indx binary_integer;
100 begin
101
102 -- copy data to the local IN or IN-OUT args, if any
103
104
105 ddp_loc_type_rec.location_type_id := rosetta_g_miss_num_map(p2_a0);
106 ddp_loc_type_rec.last_update_date := rosetta_g_miss_date_in_map(p2_a1);
107 ddp_loc_type_rec.last_updated_by := rosetta_g_miss_num_map(p2_a2);
108 ddp_loc_type_rec.creation_date := rosetta_g_miss_date_in_map(p2_a3);
109 ddp_loc_type_rec.created_by := rosetta_g_miss_num_map(p2_a4);
110 ddp_loc_type_rec.last_update_login := rosetta_g_miss_num_map(p2_a5);
111 ddp_loc_type_rec.object_version_number := rosetta_g_miss_num_map(p2_a6);
112 ddp_loc_type_rec.location_type_code := p2_a7;
113 ddp_loc_type_rec.location_type_name := p2_a8;
114 ddp_loc_type_rec.description := p2_a9;
115
116 -- here's the delegated call to the old PL/SQL routine
117 jtf_loc_types_pvt.check_items(p_validation_mode,
118 x_return_status,
119 ddp_loc_type_rec);
120
121 -- copy data back from the local OUT NOCOPY /* file.sql.39 change */ or IN-OUT args, if any
122
123
124 end;
125
126 procedure check_loc_type_req_items(p_validation_mode VARCHAR2
127 , x_return_status OUT NOCOPY /* file.sql.39 change */ VARCHAR2
128 , p1_a0 NUMBER := 0-1962.0724
129 , p1_a1 DATE := fnd_api.g_miss_date
130 , p1_a2 NUMBER := 0-1962.0724
131 , p1_a3 DATE := fnd_api.g_miss_date
132 , p1_a4 NUMBER := 0-1962.0724
133 , p1_a5 NUMBER := 0-1962.0724
134 , p1_a6 NUMBER := 0-1962.0724
135 , p1_a7 VARCHAR2 := fnd_api.g_miss_char
136 , p1_a8 VARCHAR2 := fnd_api.g_miss_char
137 , p1_a9 VARCHAR2 := fnd_api.g_miss_char
138 )
139 as
140 ddp_loc_type_rec jtf_loc_types_pvt.loc_type_rec_type;
141 ddindx binary_integer; indx binary_integer;
142 begin
143
144 -- copy data to the local IN or IN-OUT args, if any
145
146 ddp_loc_type_rec.location_type_id := rosetta_g_miss_num_map(p1_a0);
147 ddp_loc_type_rec.last_update_date := rosetta_g_miss_date_in_map(p1_a1);
148 ddp_loc_type_rec.last_updated_by := rosetta_g_miss_num_map(p1_a2);
149 ddp_loc_type_rec.creation_date := rosetta_g_miss_date_in_map(p1_a3);
150 ddp_loc_type_rec.created_by := rosetta_g_miss_num_map(p1_a4);
151 ddp_loc_type_rec.last_update_login := rosetta_g_miss_num_map(p1_a5);
152 ddp_loc_type_rec.object_version_number := rosetta_g_miss_num_map(p1_a6);
153 ddp_loc_type_rec.location_type_code := p1_a7;
154 ddp_loc_type_rec.location_type_name := p1_a8;
155 ddp_loc_type_rec.description := p1_a9;
156
157
158 -- here's the delegated call to the old PL/SQL routine
159 jtf_loc_types_pvt.check_loc_type_req_items(p_validation_mode,
160 ddp_loc_type_rec,
161 x_return_status);
162
163 -- copy data back from the local OUT NOCOPY /* file.sql.39 change */ or IN-OUT args, if any
164
165
166 end;
167
168 procedure check_loc_type_uk_items(p_validation_mode VARCHAR2
169 , x_return_status OUT NOCOPY /* file.sql.39 change */ VARCHAR2
170 , p1_a0 NUMBER := 0-1962.0724
171 , p1_a1 DATE := fnd_api.g_miss_date
172 , p1_a2 NUMBER := 0-1962.0724
173 , p1_a3 DATE := fnd_api.g_miss_date
174 , p1_a4 NUMBER := 0-1962.0724
175 , p1_a5 NUMBER := 0-1962.0724
176 , p1_a6 NUMBER := 0-1962.0724
177 , p1_a7 VARCHAR2 := fnd_api.g_miss_char
178 , p1_a8 VARCHAR2 := fnd_api.g_miss_char
179 , p1_a9 VARCHAR2 := fnd_api.g_miss_char
180 )
181 as
182 ddp_loc_type_rec jtf_loc_types_pvt.loc_type_rec_type;
183 ddindx binary_integer; indx binary_integer;
184 begin
185
186 -- copy data to the local IN or IN-OUT args, if any
187
188 ddp_loc_type_rec.location_type_id := rosetta_g_miss_num_map(p1_a0);
189 ddp_loc_type_rec.last_update_date := rosetta_g_miss_date_in_map(p1_a1);
190 ddp_loc_type_rec.last_updated_by := rosetta_g_miss_num_map(p1_a2);
191 ddp_loc_type_rec.creation_date := rosetta_g_miss_date_in_map(p1_a3);
192 ddp_loc_type_rec.created_by := rosetta_g_miss_num_map(p1_a4);
193 ddp_loc_type_rec.last_update_login := rosetta_g_miss_num_map(p1_a5);
194 ddp_loc_type_rec.object_version_number := rosetta_g_miss_num_map(p1_a6);
195 ddp_loc_type_rec.location_type_code := p1_a7;
196 ddp_loc_type_rec.location_type_name := p1_a8;
197 ddp_loc_type_rec.description := p1_a9;
198
199
200 -- here's the delegated call to the old PL/SQL routine
201 jtf_loc_types_pvt.check_loc_type_uk_items(p_validation_mode,
202 ddp_loc_type_rec,
203 x_return_status);
204
205 -- copy data back from the local OUT NOCOPY /* file.sql.39 change */ or IN-OUT args, if any
206
207
208 end;
209
210 end jtf_loc_types_pvt_w;