DBA Data[Home] [Help]

APPS.OKL_VP_CHANGE_REQUEST_PVT dependencies on OKL_API

Line 87: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

83: ,x_msg_data => x_msg_data
84: ,p_copy_rec => lv_vagr_hdr_rec
85: ,x_new_contract_id => lx_new_agr_id
86: );
87: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
88: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
89: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
90: RAISE OKL_API.G_EXCEPTION_ERROR;
91: END IF;

Line 88: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

84: ,p_copy_rec => lv_vagr_hdr_rec
85: ,x_new_contract_id => lx_new_agr_id
86: );
87: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
88: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
89: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
90: RAISE OKL_API.G_EXCEPTION_ERROR;
91: END IF;
92: okl_contract_status_pub.update_contract_status(p_api_version => p_api_version

Line 89: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

85: ,x_new_contract_id => lx_new_agr_id
86: );
87: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
88: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
89: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
90: RAISE OKL_API.G_EXCEPTION_ERROR;
91: END IF;
92: okl_contract_status_pub.update_contract_status(p_api_version => p_api_version
93: ,p_init_msg_list => p_init_msg_list

Line 90: RAISE OKL_API.G_EXCEPTION_ERROR;

86: );
87: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
88: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
89: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
90: RAISE OKL_API.G_EXCEPTION_ERROR;
91: END IF;
92: okl_contract_status_pub.update_contract_status(p_api_version => p_api_version
93: ,p_init_msg_list => p_init_msg_list
94: ,x_return_status => x_return_status

Line 100: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

96: ,x_msg_data => x_msg_data
97: ,p_khr_status => G_ABANDONED_STS_CODE
98: ,p_chr_id => lx_new_agr_id -- this is the id of the backup copy agmnt
99: );
100: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
101: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
102: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
103: RAISE OKL_API.G_EXCEPTION_ERROR;
104: END IF;

Line 101: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

97: ,p_khr_status => G_ABANDONED_STS_CODE
98: ,p_chr_id => lx_new_agr_id -- this is the id of the backup copy agmnt
99: );
100: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
101: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
102: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
103: RAISE OKL_API.G_EXCEPTION_ERROR;
104: END IF;
105: -- construct other parameters for the change request. the chr_id of this change request is the parent agreement

Line 102: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

98: ,p_chr_id => lx_new_agr_id -- this is the id of the backup copy agmnt
99: );
100: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
101: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
102: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
103: RAISE OKL_API.G_EXCEPTION_ERROR;
104: END IF;
105: -- construct other parameters for the change request. the chr_id of this change request is the parent agreement
106: -- the new agreement can be derived via the crs_id value in the okl_k_headers table

Line 103: RAISE OKL_API.G_EXCEPTION_ERROR;

99: );
100: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
101: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
102: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
103: RAISE OKL_API.G_EXCEPTION_ERROR;
104: END IF;
105: -- construct other parameters for the change request. the chr_id of this change request is the parent agreement
106: -- the new agreement can be derived via the crs_id value in the okl_k_headers table
107: lv_vcrv_rec.chr_id := p_vcrv_rec.chr_id;

Line 121: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

117: ,x_msg_data => x_msg_data
118: ,p_vcrv_rec => lv_vcrv_rec
119: ,x_vcrv_rec => x_vcrv_rec
120: );
121: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
122: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
123: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
124: RAISE OKL_API.G_EXCEPTION_ERROR;
125: END IF;

Line 122: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

118: ,p_vcrv_rec => lv_vcrv_rec
119: ,x_vcrv_rec => x_vcrv_rec
120: );
121: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
122: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
123: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
124: RAISE OKL_API.G_EXCEPTION_ERROR;
125: END IF;
126:

Line 123: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

119: ,x_vcrv_rec => x_vcrv_rec
120: );
121: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
122: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
123: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
124: RAISE OKL_API.G_EXCEPTION_ERROR;
125: END IF;
126:
127: -- since this is a system back up copy of the agreement, we need to mark this agreement as a SYSTEM copy

Line 124: RAISE OKL_API.G_EXCEPTION_ERROR;

120: );
121: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
122: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
123: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
124: RAISE OKL_API.G_EXCEPTION_ERROR;
125: END IF;
126:
127: -- since this is a system back up copy of the agreement, we need to mark this agreement as a SYSTEM copy
128: -- to achieve this, we create a reason code on the backed up change request and put the notes as

Line 145: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

141: ,x_msg_data => x_msg_data
142: ,p_vrrv_rec => lv_vrrv_rec
143: ,x_vrrv_rec => x_vrrv_rec
144: );
145: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
146: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
147: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
148: RAISE OKL_API.G_EXCEPTION_ERROR;
149: END IF;

Line 146: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

142: ,p_vrrv_rec => lv_vrrv_rec
143: ,x_vrrv_rec => x_vrrv_rec
144: );
145: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
146: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
147: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
148: RAISE OKL_API.G_EXCEPTION_ERROR;
149: END IF;
150:

Line 147: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

143: ,x_vrrv_rec => x_vrrv_rec
144: );
145: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
146: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
147: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
148: RAISE OKL_API.G_EXCEPTION_ERROR;
149: END IF;
150:
151: -- now that the agreement copy is created, set the change request id in the okl_k_headers to the created change request

Line 148: RAISE OKL_API.G_EXCEPTION_ERROR;

144: );
145: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
146: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
147: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
148: RAISE OKL_API.G_EXCEPTION_ERROR;
149: END IF;
150:
151: -- now that the agreement copy is created, set the change request id in the okl_k_headers to the created change request
152: lv_khrv_rec.id := lx_new_agr_id;

Line 161: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

157: ,x_msg_count => x_msg_count
158: ,x_msg_data => x_msg_data
159: ,p_khrv_rec => lv_khrv_rec
160: ,x_khrv_rec => x_khrv_rec);
161: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
162: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
163: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
164: RAISE OKL_API.G_EXCEPTION_ERROR;
165: END IF;

Line 162: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

158: ,x_msg_data => x_msg_data
159: ,p_khrv_rec => lv_khrv_rec
160: ,x_khrv_rec => x_khrv_rec);
161: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
162: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
163: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
164: RAISE OKL_API.G_EXCEPTION_ERROR;
165: END IF;
166:

Line 163: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

159: ,p_khrv_rec => lv_khrv_rec
160: ,x_khrv_rec => x_khrv_rec);
161: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
162: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
163: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
164: RAISE OKL_API.G_EXCEPTION_ERROR;
165: END IF;
166:
167: END historize_agreement;

Line 164: RAISE OKL_API.G_EXCEPTION_ERROR;

160: ,x_khrv_rec => x_khrv_rec);
161: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
162: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
163: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
164: RAISE OKL_API.G_EXCEPTION_ERROR;
165: END IF;
166:
167: END historize_agreement;
168:

Line 185: x_return_status := OKL_API.G_RET_STS_SUCCESS;

181: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.CREATE_CHANGE_REQUEST_HEADER';
182: l_debug_enabled VARCHAR2(10);
183:
184: BEGIN
185: x_return_status := OKL_API.G_RET_STS_SUCCESS;
186:
187: l_debug_enabled := okl_debug_pub.check_log_enabled;
188:
189: IF(l_debug_enabled='Y') THEN

Line 194: x_return_status := OKL_API.START_ACTIVITY(

190: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call create_change_request_header');
191: END IF;
192:
193: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
194: x_return_status := OKL_API.START_ACTIVITY(
195: p_api_name => l_api_name
196: ,p_pkg_name => G_PKG_NAME
197: ,p_init_msg_list => p_init_msg_list
198: ,l_api_version => l_api_version

Line 203: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

199: ,p_api_version => p_api_version
200: ,p_api_type => g_api_type
201: ,x_return_status => x_return_status);
202: -- check if activity started successfully
203: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
204: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
205: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
206: RAISE OKL_API.G_EXCEPTION_ERROR;
207: END IF;

Line 204: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

200: ,p_api_type => g_api_type
201: ,x_return_status => x_return_status);
202: -- check if activity started successfully
203: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
204: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
205: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
206: RAISE OKL_API.G_EXCEPTION_ERROR;
207: END IF;
208:

Line 205: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

201: ,x_return_status => x_return_status);
202: -- check if activity started successfully
203: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
204: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
205: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
206: RAISE OKL_API.G_EXCEPTION_ERROR;
207: END IF;
208:
209: okl_vcr_pvt.insert_row(p_api_version => p_api_version

Line 206: RAISE OKL_API.G_EXCEPTION_ERROR;

202: -- check if activity started successfully
203: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
204: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
205: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
206: RAISE OKL_API.G_EXCEPTION_ERROR;
207: END IF;
208:
209: okl_vcr_pvt.insert_row(p_api_version => p_api_version
210: ,p_init_msg_list => p_init_msg_list

Line 224: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

220: l_module,
221: 'okl_vcr_pvt.insert_row returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
222: );
223: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
224: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
225: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
226: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
227: RAISE OKL_API.G_EXCEPTION_ERROR;
228: END IF;

Line 225: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

221: 'okl_vcr_pvt.insert_row returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
222: );
223: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
224: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
225: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
226: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
227: RAISE OKL_API.G_EXCEPTION_ERROR;
228: END IF;
229:

Line 226: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

222: );
223: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
224: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
225: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
226: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
227: RAISE OKL_API.G_EXCEPTION_ERROR;
228: END IF;
229:
230: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

Line 227: RAISE OKL_API.G_EXCEPTION_ERROR;

223: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
224: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
225: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
226: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
227: RAISE OKL_API.G_EXCEPTION_ERROR;
228: END IF;
229:
230: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
231:

Line 230: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

226: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
227: RAISE OKL_API.G_EXCEPTION_ERROR;
228: END IF;
229:
230: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
231:
232: IF(l_debug_enabled='Y') THEN
233: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request_header');
234: END IF;

Line 236: WHEN OKL_API.G_EXCEPTION_ERROR THEN

232: IF(l_debug_enabled='Y') THEN
233: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request_header');
234: END IF;
235: EXCEPTION
236: WHEN OKL_API.G_EXCEPTION_ERROR THEN
237: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
238: p_api_name => l_api_name,
239: p_pkg_name => G_PKG_NAME,
240: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 237: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

233: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request_header');
234: END IF;
235: EXCEPTION
236: WHEN OKL_API.G_EXCEPTION_ERROR THEN
237: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
238: p_api_name => l_api_name,
239: p_pkg_name => G_PKG_NAME,
240: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
241: x_msg_count => x_msg_count,

Line 240: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

236: WHEN OKL_API.G_EXCEPTION_ERROR THEN
237: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
238: p_api_name => l_api_name,
239: p_pkg_name => G_PKG_NAME,
240: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
241: x_msg_count => x_msg_count,
242: x_msg_data => x_msg_data,
243: p_api_type => g_api_type);
244:

Line 245: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

241: x_msg_count => x_msg_count,
242: x_msg_data => x_msg_data,
243: p_api_type => g_api_type);
244:
245: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
246: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
247: p_api_name => l_api_name,
248: p_pkg_name => G_PKG_NAME,
249: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 246: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

242: x_msg_data => x_msg_data,
243: p_api_type => g_api_type);
244:
245: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
246: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
247: p_api_name => l_api_name,
248: p_pkg_name => G_PKG_NAME,
249: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
250: x_msg_count => x_msg_count,

Line 249: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

245: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
246: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
247: p_api_name => l_api_name,
248: p_pkg_name => G_PKG_NAME,
249: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
250: x_msg_count => x_msg_count,
251: x_msg_data => x_msg_data,
252: p_api_type => g_api_type);
253:

Line 255: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

251: x_msg_data => x_msg_data,
252: p_api_type => g_api_type);
253:
254: WHEN OTHERS THEN
255: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
256: p_api_name => l_api_name,
257: p_pkg_name => G_PKG_NAME,
258: p_exc_name => 'OTHERS',
259: x_msg_count => x_msg_count,

Line 288: x_return_status := OKL_API.G_RET_STS_SUCCESS;

284: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.UPDATE_CHANGE_REQUEST_HEADER';
285: l_debug_enabled VARCHAR2(10);
286:
287: BEGIN
288: x_return_status := OKL_API.G_RET_STS_SUCCESS;
289:
290: l_debug_enabled := okl_debug_pub.check_log_enabled;
291:
292: IF(l_debug_enabled='Y') THEN

Line 297: x_return_status := OKL_API.START_ACTIVITY(

293: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call update_change_request_header');
294: END IF;
295:
296: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
297: x_return_status := OKL_API.START_ACTIVITY(
298: p_api_name => l_api_name
299: ,p_pkg_name => G_PKG_NAME
300: ,p_init_msg_list => p_init_msg_list
301: ,l_api_version => l_api_version

Line 306: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

302: ,p_api_version => p_api_version
303: ,p_api_type => g_api_type
304: ,x_return_status => x_return_status);
305: -- check if activity started successfully
306: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
307: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
308: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
309: RAISE OKL_API.G_EXCEPTION_ERROR;
310: END IF;

Line 307: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

303: ,p_api_type => g_api_type
304: ,x_return_status => x_return_status);
305: -- check if activity started successfully
306: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
307: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
308: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
309: RAISE OKL_API.G_EXCEPTION_ERROR;
310: END IF;
311:

Line 308: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

304: ,x_return_status => x_return_status);
305: -- check if activity started successfully
306: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
307: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
308: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
309: RAISE OKL_API.G_EXCEPTION_ERROR;
310: END IF;
311:
312: lv_vcrv_rec := p_vcrv_rec;

Line 309: RAISE OKL_API.G_EXCEPTION_ERROR;

305: -- check if activity started successfully
306: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
307: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
308: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
309: RAISE OKL_API.G_EXCEPTION_ERROR;
310: END IF;
311:
312: lv_vcrv_rec := p_vcrv_rec;
313: -- get the chr_id if not passed

Line 335: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

331: 'okl_vcr_pvt.update_row returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
332: );
333: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
334:
335: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
336: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
337: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
338: RAISE OKL_API.G_EXCEPTION_ERROR;
339: END IF;

Line 336: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

332: );
333: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
334:
335: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
336: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
337: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
338: RAISE OKL_API.G_EXCEPTION_ERROR;
339: END IF;
340:

Line 337: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

333: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
334:
335: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
336: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
337: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
338: RAISE OKL_API.G_EXCEPTION_ERROR;
339: END IF;
340:
341: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

Line 338: RAISE OKL_API.G_EXCEPTION_ERROR;

334:
335: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
336: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
337: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
338: RAISE OKL_API.G_EXCEPTION_ERROR;
339: END IF;
340:
341: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
342:

Line 341: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

337: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
338: RAISE OKL_API.G_EXCEPTION_ERROR;
339: END IF;
340:
341: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
342:
343: IF(l_debug_enabled='Y') THEN
344: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call update_change_request_header');
345: END IF;

Line 347: WHEN OKL_API.G_EXCEPTION_ERROR THEN

343: IF(l_debug_enabled='Y') THEN
344: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call update_change_request_header');
345: END IF;
346: EXCEPTION
347: WHEN OKL_API.G_EXCEPTION_ERROR THEN
348: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
349: p_api_name => l_api_name,
350: p_pkg_name => G_PKG_NAME,
351: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 348: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

344: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call update_change_request_header');
345: END IF;
346: EXCEPTION
347: WHEN OKL_API.G_EXCEPTION_ERROR THEN
348: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
349: p_api_name => l_api_name,
350: p_pkg_name => G_PKG_NAME,
351: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
352: x_msg_count => x_msg_count,

Line 351: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

347: WHEN OKL_API.G_EXCEPTION_ERROR THEN
348: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
349: p_api_name => l_api_name,
350: p_pkg_name => G_PKG_NAME,
351: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
352: x_msg_count => x_msg_count,
353: x_msg_data => x_msg_data,
354: p_api_type => g_api_type);
355:

Line 356: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

352: x_msg_count => x_msg_count,
353: x_msg_data => x_msg_data,
354: p_api_type => g_api_type);
355:
356: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
357: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
358: p_api_name => l_api_name,
359: p_pkg_name => G_PKG_NAME,
360: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 357: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

353: x_msg_data => x_msg_data,
354: p_api_type => g_api_type);
355:
356: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
357: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
358: p_api_name => l_api_name,
359: p_pkg_name => G_PKG_NAME,
360: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
361: x_msg_count => x_msg_count,

Line 360: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

356: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
357: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
358: p_api_name => l_api_name,
359: p_pkg_name => G_PKG_NAME,
360: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
361: x_msg_count => x_msg_count,
362: x_msg_data => x_msg_data,
363: p_api_type => g_api_type);
364:

Line 366: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

362: x_msg_data => x_msg_data,
363: p_api_type => g_api_type);
364:
365: WHEN OTHERS THEN
366: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
367: p_api_name => l_api_name,
368: p_pkg_name => G_PKG_NAME,
369: p_exc_name => 'OTHERS',
370: x_msg_count => x_msg_count,

Line 391: x_return_status := OKL_API.G_RET_STS_SUCCESS;

387: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.CREATE_CHANGE_REQUEST_LINES';
388: l_debug_enabled VARCHAR2(10);
389:
390: BEGIN
391: x_return_status := OKL_API.G_RET_STS_SUCCESS;
392:
393: l_debug_enabled := okl_debug_pub.check_log_enabled;
394:
395: IF(l_debug_enabled='Y') THEN

Line 400: x_return_status := OKL_API.START_ACTIVITY(

396: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call create_change_request_lines');
397: END IF;
398:
399: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
400: x_return_status := OKL_API.START_ACTIVITY(
401: p_api_name => l_api_name
402: ,p_pkg_name => G_PKG_NAME
403: ,p_init_msg_list => p_init_msg_list
404: ,l_api_version => l_api_version

Line 409: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

405: ,p_api_version => p_api_version
406: ,p_api_type => g_api_type
407: ,x_return_status => x_return_status);
408: -- check if activity started successfully
409: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
410: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
411: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
412: RAISE OKL_API.G_EXCEPTION_ERROR;
413: END IF;

Line 410: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

406: ,p_api_type => g_api_type
407: ,x_return_status => x_return_status);
408: -- check if activity started successfully
409: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
410: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
411: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
412: RAISE OKL_API.G_EXCEPTION_ERROR;
413: END IF;
414:

Line 411: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

407: ,x_return_status => x_return_status);
408: -- check if activity started successfully
409: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
410: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
411: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
412: RAISE OKL_API.G_EXCEPTION_ERROR;
413: END IF;
414:
415: okl_vrr_pvt.insert_row(p_api_version => p_api_version

Line 412: RAISE OKL_API.G_EXCEPTION_ERROR;

408: -- check if activity started successfully
409: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
410: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
411: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
412: RAISE OKL_API.G_EXCEPTION_ERROR;
413: END IF;
414:
415: okl_vrr_pvt.insert_row(p_api_version => p_api_version
416: ,p_init_msg_list => p_init_msg_list

Line 431: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

427: 'okl_vrr_pvt.insert_row returned with status '||x_return_status||' x_msg_data '||x_msg_data
428: );
429: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
430:
431: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
432: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
433: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
434: RAISE OKL_API.G_EXCEPTION_ERROR;
435: END IF;

Line 432: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

428: );
429: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
430:
431: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
432: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
433: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
434: RAISE OKL_API.G_EXCEPTION_ERROR;
435: END IF;
436:

Line 433: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

429: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
430:
431: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
432: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
433: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
434: RAISE OKL_API.G_EXCEPTION_ERROR;
435: END IF;
436:
437: -- get the master change request id and re-set the status of the change request if needed

Line 434: RAISE OKL_API.G_EXCEPTION_ERROR;

430:
431: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
432: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
433: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
434: RAISE OKL_API.G_EXCEPTION_ERROR;
435: END IF;
436:
437: -- get the master change request id and re-set the status of the change request if needed
438: -- this scenario could be possible if the user adds more reasons once the change request is validated successfully.

Line 440: IF(p_vrrv_tbl.COUNT > 0 AND lv_crs_id IS NOT NULL AND lv_crs_id <> OKL_API.G_MISS_NUM)THEN

436:
437: -- get the master change request id and re-set the status of the change request if needed
438: -- this scenario could be possible if the user adds more reasons once the change request is validated successfully.
439: lv_crs_id := p_vrrv_tbl(p_vrrv_tbl.FIRST).crs_id;
440: IF(p_vrrv_tbl.COUNT > 0 AND lv_crs_id IS NOT NULL AND lv_crs_id <> OKL_API.G_MISS_NUM)THEN
441: cascade_request_status_edit(p_api_version => p_api_version
442: ,p_init_msg_list => p_init_msg_list
443: ,x_return_status => x_return_status
444: ,x_msg_count => x_msg_count

Line 449: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

445: ,x_msg_data => x_msg_data
446: ,p_vp_crq_id => lv_crs_id
447: ,x_status_code => x_request_status
448: );
449: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
450: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
451: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
452: RAISE OKL_API.G_EXCEPTION_ERROR;
453: END IF;

Line 450: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

446: ,p_vp_crq_id => lv_crs_id
447: ,x_status_code => x_request_status
448: );
449: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
450: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
451: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
452: RAISE OKL_API.G_EXCEPTION_ERROR;
453: END IF;
454: END IF;

Line 451: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

447: ,x_status_code => x_request_status
448: );
449: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
450: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
451: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
452: RAISE OKL_API.G_EXCEPTION_ERROR;
453: END IF;
454: END IF;
455:

Line 452: RAISE OKL_API.G_EXCEPTION_ERROR;

448: );
449: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
450: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
451: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
452: RAISE OKL_API.G_EXCEPTION_ERROR;
453: END IF;
454: END IF;
455:
456: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

Line 456: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

452: RAISE OKL_API.G_EXCEPTION_ERROR;
453: END IF;
454: END IF;
455:
456: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
457:
458: IF(l_debug_enabled='Y') THEN
459: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request_lines');
460: END IF;

Line 462: WHEN OKL_API.G_EXCEPTION_ERROR THEN

458: IF(l_debug_enabled='Y') THEN
459: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request_lines');
460: END IF;
461: EXCEPTION
462: WHEN OKL_API.G_EXCEPTION_ERROR THEN
463: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
464: p_api_name => l_api_name,
465: p_pkg_name => G_PKG_NAME,
466: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 463: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

459: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request_lines');
460: END IF;
461: EXCEPTION
462: WHEN OKL_API.G_EXCEPTION_ERROR THEN
463: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
464: p_api_name => l_api_name,
465: p_pkg_name => G_PKG_NAME,
466: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
467: x_msg_count => x_msg_count,

Line 466: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

462: WHEN OKL_API.G_EXCEPTION_ERROR THEN
463: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
464: p_api_name => l_api_name,
465: p_pkg_name => G_PKG_NAME,
466: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
467: x_msg_count => x_msg_count,
468: x_msg_data => x_msg_data,
469: p_api_type => g_api_type);
470:

Line 471: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

467: x_msg_count => x_msg_count,
468: x_msg_data => x_msg_data,
469: p_api_type => g_api_type);
470:
471: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
472: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
473: p_api_name => l_api_name,
474: p_pkg_name => G_PKG_NAME,
475: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 472: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

468: x_msg_data => x_msg_data,
469: p_api_type => g_api_type);
470:
471: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
472: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
473: p_api_name => l_api_name,
474: p_pkg_name => G_PKG_NAME,
475: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
476: x_msg_count => x_msg_count,

Line 475: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

471: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
472: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
473: p_api_name => l_api_name,
474: p_pkg_name => G_PKG_NAME,
475: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
476: x_msg_count => x_msg_count,
477: x_msg_data => x_msg_data,
478: p_api_type => g_api_type);
479:

Line 481: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

477: x_msg_data => x_msg_data,
478: p_api_type => g_api_type);
479:
480: WHEN OTHERS THEN
481: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
482: p_api_name => l_api_name,
483: p_pkg_name => G_PKG_NAME,
484: p_exc_name => 'OTHERS',
485: x_msg_count => x_msg_count,

Line 506: x_return_status := OKL_API.G_RET_STS_SUCCESS;

502: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.UPDATE_CHANGE_REQUEST_LINES';
503: l_debug_enabled VARCHAR2(10);
504:
505: BEGIN
506: x_return_status := OKL_API.G_RET_STS_SUCCESS;
507:
508: l_debug_enabled := okl_debug_pub.check_log_enabled;
509:
510: IF(l_debug_enabled='Y') THEN

Line 515: x_return_status := OKL_API.START_ACTIVITY(

511: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call update_change_request_lines');
512: END IF;
513:
514: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
515: x_return_status := OKL_API.START_ACTIVITY(
516: p_api_name => l_api_name
517: ,p_pkg_name => G_PKG_NAME
518: ,p_init_msg_list => p_init_msg_list
519: ,l_api_version => l_api_version

Line 524: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

520: ,p_api_version => p_api_version
521: ,p_api_type => g_api_type
522: ,x_return_status => x_return_status);
523: -- check if activity started successfully
524: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
525: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
526: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
527: RAISE OKL_API.G_EXCEPTION_ERROR;
528: END IF;

Line 525: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

521: ,p_api_type => g_api_type
522: ,x_return_status => x_return_status);
523: -- check if activity started successfully
524: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
525: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
526: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
527: RAISE OKL_API.G_EXCEPTION_ERROR;
528: END IF;
529:

Line 526: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

522: ,x_return_status => x_return_status);
523: -- check if activity started successfully
524: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
525: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
526: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
527: RAISE OKL_API.G_EXCEPTION_ERROR;
528: END IF;
529:
530: okl_vrr_pvt.update_row(p_api_version => p_api_version

Line 527: RAISE OKL_API.G_EXCEPTION_ERROR;

523: -- check if activity started successfully
524: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
525: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
526: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
527: RAISE OKL_API.G_EXCEPTION_ERROR;
528: END IF;
529:
530: okl_vrr_pvt.update_row(p_api_version => p_api_version
531: ,p_init_msg_list => p_init_msg_list

Line 546: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

542: 'okl_vrr_pvt.update_row returned with status '||x_return_status||' x_msg_data '||x_msg_data
543: );
544: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
545:
546: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
547: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
548: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
549: RAISE OKL_API.G_EXCEPTION_ERROR;
550: END IF;

Line 547: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

543: );
544: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
545:
546: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
547: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
548: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
549: RAISE OKL_API.G_EXCEPTION_ERROR;
550: END IF;
551:

Line 548: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

544: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
545:
546: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
547: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
548: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
549: RAISE OKL_API.G_EXCEPTION_ERROR;
550: END IF;
551:
552: -- get the master change request id and re-set the status of the change request if needed

Line 549: RAISE OKL_API.G_EXCEPTION_ERROR;

545:
546: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
547: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
548: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
549: RAISE OKL_API.G_EXCEPTION_ERROR;
550: END IF;
551:
552: -- get the master change request id and re-set the status of the change request if needed
553: -- this scenario could be possible if the user updates one or more reasons once the change request is validated successfully.

Line 555: IF(p_vrrv_tbl.COUNT > 0 AND lv_crs_id IS NOT NULL AND lv_crs_id <> OKL_API.G_MISS_NUM)THEN

551:
552: -- get the master change request id and re-set the status of the change request if needed
553: -- this scenario could be possible if the user updates one or more reasons once the change request is validated successfully.
554: lv_crs_id := p_vrrv_tbl(p_vrrv_tbl.FIRST).crs_id;
555: IF(p_vrrv_tbl.COUNT > 0 AND lv_crs_id IS NOT NULL AND lv_crs_id <> OKL_API.G_MISS_NUM)THEN
556: cascade_request_status_edit(p_api_version => p_api_version
557: ,p_init_msg_list => p_init_msg_list
558: ,x_return_status => x_return_status
559: ,x_msg_count => x_msg_count

Line 564: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

560: ,x_msg_data => x_msg_data
561: ,p_vp_crq_id => lv_crs_id
562: ,x_status_code => x_request_status
563: );
564: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
565: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
566: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
567: RAISE OKL_API.G_EXCEPTION_ERROR;
568: END IF;

Line 565: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

561: ,p_vp_crq_id => lv_crs_id
562: ,x_status_code => x_request_status
563: );
564: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
565: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
566: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
567: RAISE OKL_API.G_EXCEPTION_ERROR;
568: END IF;
569: END IF;

Line 566: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

562: ,x_status_code => x_request_status
563: );
564: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
565: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
566: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
567: RAISE OKL_API.G_EXCEPTION_ERROR;
568: END IF;
569: END IF;
570:

Line 567: RAISE OKL_API.G_EXCEPTION_ERROR;

563: );
564: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
565: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
566: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
567: RAISE OKL_API.G_EXCEPTION_ERROR;
568: END IF;
569: END IF;
570:
571: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

Line 571: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

567: RAISE OKL_API.G_EXCEPTION_ERROR;
568: END IF;
569: END IF;
570:
571: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
572:
573: IF(l_debug_enabled='Y') THEN
574: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call update_change_request_lines');
575: END IF;

Line 577: WHEN OKL_API.G_EXCEPTION_ERROR THEN

573: IF(l_debug_enabled='Y') THEN
574: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call update_change_request_lines');
575: END IF;
576: EXCEPTION
577: WHEN OKL_API.G_EXCEPTION_ERROR THEN
578: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
579: p_api_name => l_api_name,
580: p_pkg_name => G_PKG_NAME,
581: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 578: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

574: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call update_change_request_lines');
575: END IF;
576: EXCEPTION
577: WHEN OKL_API.G_EXCEPTION_ERROR THEN
578: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
579: p_api_name => l_api_name,
580: p_pkg_name => G_PKG_NAME,
581: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
582: x_msg_count => x_msg_count,

Line 581: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

577: WHEN OKL_API.G_EXCEPTION_ERROR THEN
578: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
579: p_api_name => l_api_name,
580: p_pkg_name => G_PKG_NAME,
581: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
582: x_msg_count => x_msg_count,
583: x_msg_data => x_msg_data,
584: p_api_type => g_api_type);
585:

Line 586: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

582: x_msg_count => x_msg_count,
583: x_msg_data => x_msg_data,
584: p_api_type => g_api_type);
585:
586: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
587: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
588: p_api_name => l_api_name,
589: p_pkg_name => G_PKG_NAME,
590: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 587: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

583: x_msg_data => x_msg_data,
584: p_api_type => g_api_type);
585:
586: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
587: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
588: p_api_name => l_api_name,
589: p_pkg_name => G_PKG_NAME,
590: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
591: x_msg_count => x_msg_count,

Line 590: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

586: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
587: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
588: p_api_name => l_api_name,
589: p_pkg_name => G_PKG_NAME,
590: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
591: x_msg_count => x_msg_count,
592: x_msg_data => x_msg_data,
593: p_api_type => g_api_type);
594:

Line 596: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

592: x_msg_data => x_msg_data,
593: p_api_type => g_api_type);
594:
595: WHEN OTHERS THEN
596: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
597: p_api_name => l_api_name,
598: p_pkg_name => G_PKG_NAME,
599: p_exc_name => 'OTHERS',
600: x_msg_count => x_msg_count,

Line 625: x_return_status := OKL_API.G_RET_STS_SUCCESS;

621: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.DELETE_CHANGE_REQUEST_LINES';
622: l_debug_enabled VARCHAR2(10);
623:
624: BEGIN
625: x_return_status := OKL_API.G_RET_STS_SUCCESS;
626:
627: l_debug_enabled := okl_debug_pub.check_log_enabled;
628:
629: IF(l_debug_enabled='Y') THEN

Line 634: x_return_status := OKL_API.START_ACTIVITY(

630: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call delete_change_request_lines');
631: END IF;
632:
633: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
634: x_return_status := OKL_API.START_ACTIVITY(
635: p_api_name => l_api_name
636: ,p_pkg_name => G_PKG_NAME
637: ,p_init_msg_list => p_init_msg_list
638: ,l_api_version => l_api_version

Line 643: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

639: ,p_api_version => p_api_version
640: ,p_api_type => g_api_type
641: ,x_return_status => x_return_status);
642: -- check if activity started successfully
643: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
644: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
645: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
646: RAISE OKL_API.G_EXCEPTION_ERROR;
647: END IF;

Line 644: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

640: ,p_api_type => g_api_type
641: ,x_return_status => x_return_status);
642: -- check if activity started successfully
643: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
644: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
645: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
646: RAISE OKL_API.G_EXCEPTION_ERROR;
647: END IF;
648: IF(p_vrrv_tbl.COUNT > 0)THEN

Line 645: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

641: ,x_return_status => x_return_status);
642: -- check if activity started successfully
643: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
644: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
645: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
646: RAISE OKL_API.G_EXCEPTION_ERROR;
647: END IF;
648: IF(p_vrrv_tbl.COUNT > 0)THEN
649: okl_vrr_pvt.delete_row(p_api_version => p_api_version

Line 646: RAISE OKL_API.G_EXCEPTION_ERROR;

642: -- check if activity started successfully
643: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
644: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
645: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
646: RAISE OKL_API.G_EXCEPTION_ERROR;
647: END IF;
648: IF(p_vrrv_tbl.COUNT > 0)THEN
649: okl_vrr_pvt.delete_row(p_api_version => p_api_version
650: ,p_init_msg_list => p_init_msg_list

Line 663: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

659: l_module,
660: 'okl_vrr_pvt.delete_row returned with status '||x_return_status||' x_msg_data '||x_msg_data
661: );
662: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
663: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
664: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
665: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
666: RAISE OKL_API.G_EXCEPTION_ERROR;
667: END IF;

Line 664: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

660: 'okl_vrr_pvt.delete_row returned with status '||x_return_status||' x_msg_data '||x_msg_data
661: );
662: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
663: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
664: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
665: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
666: RAISE OKL_API.G_EXCEPTION_ERROR;
667: END IF;
668: -- now check if there are any change request reasons still for this change request. if there are no change request reasons

Line 665: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

661: );
662: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
663: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
664: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
665: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
666: RAISE OKL_API.G_EXCEPTION_ERROR;
667: END IF;
668: -- now check if there are any change request reasons still for this change request. if there are no change request reasons
669: -- then raise an error. Atleast One Change Request Reason is mandatory for a Change Request

Line 666: RAISE OKL_API.G_EXCEPTION_ERROR;

662: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
663: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
664: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
665: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
666: RAISE OKL_API.G_EXCEPTION_ERROR;
667: END IF;
668: -- now check if there are any change request reasons still for this change request. if there are no change request reasons
669: -- then raise an error. Atleast One Change Request Reason is mandatory for a Change Request
670: OPEN c_get_more_reasons_csr(p_vrrv_tbl(p_vrrv_tbl.FIRST).crs_id); FETCH c_get_more_reasons_csr INTO lv_dummy;

Line 673: OKL_API.set_message(G_APP_NAME, G_ONE_REASON_REQD);

669: -- then raise an error. Atleast One Change Request Reason is mandatory for a Change Request
670: OPEN c_get_more_reasons_csr(p_vrrv_tbl(p_vrrv_tbl.FIRST).crs_id); FETCH c_get_more_reasons_csr INTO lv_dummy;
671: CLOSE c_get_more_reasons_csr;
672: IF(NVL(lv_dummy,'Y')<>'X')THEN
673: OKL_API.set_message(G_APP_NAME, G_ONE_REASON_REQD);
674: RAISE OKL_API.G_EXCEPTION_ERROR;
675: END IF;
676: -- get the master change request id and re-set the status of the change request if needed
677: -- this scenario could be possible if the user removes one or more reasons once the change request is validated successfully.

Line 674: RAISE OKL_API.G_EXCEPTION_ERROR;

670: OPEN c_get_more_reasons_csr(p_vrrv_tbl(p_vrrv_tbl.FIRST).crs_id); FETCH c_get_more_reasons_csr INTO lv_dummy;
671: CLOSE c_get_more_reasons_csr;
672: IF(NVL(lv_dummy,'Y')<>'X')THEN
673: OKL_API.set_message(G_APP_NAME, G_ONE_REASON_REQD);
674: RAISE OKL_API.G_EXCEPTION_ERROR;
675: END IF;
676: -- get the master change request id and re-set the status of the change request if needed
677: -- this scenario could be possible if the user removes one or more reasons once the change request is validated successfully.
678: lv_crs_id := p_vrrv_tbl(p_vrrv_tbl.FIRST).crs_id;

Line 679: IF(lv_crs_id IS NOT NULL AND lv_crs_id <> OKL_API.G_MISS_NUM)THEN

675: END IF;
676: -- get the master change request id and re-set the status of the change request if needed
677: -- this scenario could be possible if the user removes one or more reasons once the change request is validated successfully.
678: lv_crs_id := p_vrrv_tbl(p_vrrv_tbl.FIRST).crs_id;
679: IF(lv_crs_id IS NOT NULL AND lv_crs_id <> OKL_API.G_MISS_NUM)THEN
680: cascade_request_status_edit(p_api_version => p_api_version
681: ,p_init_msg_list => p_init_msg_list
682: ,x_return_status => x_return_status
683: ,x_msg_count => x_msg_count

Line 688: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

684: ,x_msg_data => x_msg_data
685: ,p_vp_crq_id => lv_crs_id
686: ,x_status_code => x_request_status
687: );
688: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
689: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
690: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
691: RAISE OKL_API.G_EXCEPTION_ERROR;
692: END IF;

Line 689: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

685: ,p_vp_crq_id => lv_crs_id
686: ,x_status_code => x_request_status
687: );
688: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
689: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
690: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
691: RAISE OKL_API.G_EXCEPTION_ERROR;
692: END IF;
693: END IF;

Line 690: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

686: ,x_status_code => x_request_status
687: );
688: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
689: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
690: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
691: RAISE OKL_API.G_EXCEPTION_ERROR;
692: END IF;
693: END IF;
694: ELSE

Line 691: RAISE OKL_API.G_EXCEPTION_ERROR;

687: );
688: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
689: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
690: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
691: RAISE OKL_API.G_EXCEPTION_ERROR;
692: END IF;
693: END IF;
694: ELSE
695: OKL_API.set_message(G_APP_NAME, G_NO_ROWS_SELECTED);

Line 695: OKL_API.set_message(G_APP_NAME, G_NO_ROWS_SELECTED);

691: RAISE OKL_API.G_EXCEPTION_ERROR;
692: END IF;
693: END IF;
694: ELSE
695: OKL_API.set_message(G_APP_NAME, G_NO_ROWS_SELECTED);
696: RAISE OKL_API.G_EXCEPTION_ERROR;
697: END IF;
698: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
699:

Line 696: RAISE OKL_API.G_EXCEPTION_ERROR;

692: END IF;
693: END IF;
694: ELSE
695: OKL_API.set_message(G_APP_NAME, G_NO_ROWS_SELECTED);
696: RAISE OKL_API.G_EXCEPTION_ERROR;
697: END IF;
698: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
699:
700: IF(l_debug_enabled='Y') THEN

Line 698: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

694: ELSE
695: OKL_API.set_message(G_APP_NAME, G_NO_ROWS_SELECTED);
696: RAISE OKL_API.G_EXCEPTION_ERROR;
697: END IF;
698: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
699:
700: IF(l_debug_enabled='Y') THEN
701: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call delete_change_request_lines');
702: END IF;

Line 704: WHEN OKL_API.G_EXCEPTION_ERROR THEN

700: IF(l_debug_enabled='Y') THEN
701: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call delete_change_request_lines');
702: END IF;
703: EXCEPTION
704: WHEN OKL_API.G_EXCEPTION_ERROR THEN
705: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
706: p_api_name => l_api_name,
707: p_pkg_name => G_PKG_NAME,
708: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 705: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

701: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call delete_change_request_lines');
702: END IF;
703: EXCEPTION
704: WHEN OKL_API.G_EXCEPTION_ERROR THEN
705: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
706: p_api_name => l_api_name,
707: p_pkg_name => G_PKG_NAME,
708: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
709: x_msg_count => x_msg_count,

Line 708: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

704: WHEN OKL_API.G_EXCEPTION_ERROR THEN
705: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
706: p_api_name => l_api_name,
707: p_pkg_name => G_PKG_NAME,
708: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
709: x_msg_count => x_msg_count,
710: x_msg_data => x_msg_data,
711: p_api_type => g_api_type);
712:

Line 713: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

709: x_msg_count => x_msg_count,
710: x_msg_data => x_msg_data,
711: p_api_type => g_api_type);
712:
713: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
714: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
715: p_api_name => l_api_name,
716: p_pkg_name => G_PKG_NAME,
717: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 714: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

710: x_msg_data => x_msg_data,
711: p_api_type => g_api_type);
712:
713: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
714: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
715: p_api_name => l_api_name,
716: p_pkg_name => G_PKG_NAME,
717: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
718: x_msg_count => x_msg_count,

Line 717: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

713: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
714: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
715: p_api_name => l_api_name,
716: p_pkg_name => G_PKG_NAME,
717: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
718: x_msg_count => x_msg_count,
719: x_msg_data => x_msg_data,
720: p_api_type => g_api_type);
721:

Line 723: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

719: x_msg_data => x_msg_data,
720: p_api_type => g_api_type);
721:
722: WHEN OTHERS THEN
723: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
724: p_api_name => l_api_name,
725: p_pkg_name => G_PKG_NAME,
726: p_exc_name => 'OTHERS',
727: x_msg_count => x_msg_count,

Line 800: x_return_status := OKL_API.G_RET_STS_SUCCESS;

796: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.CREATE_CHANGE_REQUEST';
797: l_debug_enabled VARCHAR2(10);
798:
799: BEGIN
800: x_return_status := OKL_API.G_RET_STS_SUCCESS;
801:
802: l_debug_enabled := okl_debug_pub.check_log_enabled;
803:
804: IF(l_debug_enabled='Y') THEN

Line 809: x_return_status := OKL_API.START_ACTIVITY(

805: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call create_change_request');
806: END IF;
807:
808: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
809: x_return_status := OKL_API.START_ACTIVITY(
810: p_api_name => l_api_name
811: ,p_pkg_name => G_PKG_NAME
812: ,p_init_msg_list => p_init_msg_list
813: ,l_api_version => l_api_version

Line 818: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

814: ,p_api_version => p_api_version
815: ,p_api_type => g_api_type
816: ,x_return_status => x_return_status);
817: -- check if activity started successfully
818: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
819: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
820: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
821: RAISE OKL_API.G_EXCEPTION_ERROR;
822: END IF;

Line 819: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

815: ,p_api_type => g_api_type
816: ,x_return_status => x_return_status);
817: -- check if activity started successfully
818: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
819: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
820: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
821: RAISE OKL_API.G_EXCEPTION_ERROR;
822: END IF;
823:

Line 820: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

816: ,x_return_status => x_return_status);
817: -- check if activity started successfully
818: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
819: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
820: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
821: RAISE OKL_API.G_EXCEPTION_ERROR;
822: END IF;
823:
824: lv_vcrv_rec := p_vcrv_rec;

Line 821: RAISE OKL_API.G_EXCEPTION_ERROR;

817: -- check if activity started successfully
818: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
819: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
820: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
821: RAISE OKL_API.G_EXCEPTION_ERROR;
822: END IF;
823:
824: lv_vcrv_rec := p_vcrv_rec;
825:

Line 827: IF(lv_vcrv_rec.chr_id IS NULL OR lv_vcrv_rec.chr_id = OKL_API.G_MISS_NUM)THEN

823:
824: lv_vcrv_rec := p_vcrv_rec;
825:
826: -- first: verify if all the parameters required for processing are passed.
827: IF(lv_vcrv_rec.chr_id IS NULL OR lv_vcrv_rec.chr_id = OKL_API.G_MISS_NUM)THEN
828: OKL_API.set_message(G_APP_NAME, G_CR_PARMS_MISSING);
829: RAISE OKL_API.G_EXCEPTION_ERROR;
830: END IF;
831:

Line 828: OKL_API.set_message(G_APP_NAME, G_CR_PARMS_MISSING);

824: lv_vcrv_rec := p_vcrv_rec;
825:
826: -- first: verify if all the parameters required for processing are passed.
827: IF(lv_vcrv_rec.chr_id IS NULL OR lv_vcrv_rec.chr_id = OKL_API.G_MISS_NUM)THEN
828: OKL_API.set_message(G_APP_NAME, G_CR_PARMS_MISSING);
829: RAISE OKL_API.G_EXCEPTION_ERROR;
830: END IF;
831:
832: -- second: check if there exists a change request already in status NEW, PENDING_APPROVAL, REJCTED, INCOMPLETE or PASSED

Line 829: RAISE OKL_API.G_EXCEPTION_ERROR;

825:
826: -- first: verify if all the parameters required for processing are passed.
827: IF(lv_vcrv_rec.chr_id IS NULL OR lv_vcrv_rec.chr_id = OKL_API.G_MISS_NUM)THEN
828: OKL_API.set_message(G_APP_NAME, G_CR_PARMS_MISSING);
829: RAISE OKL_API.G_EXCEPTION_ERROR;
830: END IF;
831:
832: -- second: check if there exists a change request already in status NEW, PENDING_APPROVAL, REJCTED, INCOMPLETE or PASSED
833: OPEN c_chk_pending_req_csr (lv_vcrv_rec.chr_id); FETCH c_chk_pending_req_csr INTO lv_pending_req_cvar;

Line 841: OKL_API.set_message(G_APP_NAME, G_PENDING_CHANGE_REQ_EXISTS, 'AGR_NUMBER', lv_agreement_number);

837: OPEN c_get_agr_num_csr(lv_vcrv_rec.chr_id); FETCH c_get_agr_num_csr INTO lv_agreement_number, lv_agreement_status;
838: CLOSE c_get_agr_num_csr;
839:
840: IF(NVL(lv_pending_req_cvar,'Y') = 'X')THEN
841: OKL_API.set_message(G_APP_NAME, G_PENDING_CHANGE_REQ_EXISTS, 'AGR_NUMBER', lv_agreement_number);
842: RAISE OKL_API.G_EXCEPTION_ERROR;
843: END IF;
844:
845: -- third: check if the agreement is ACTIVE. Change Requests cannot be created for non active agreements

Line 842: RAISE OKL_API.G_EXCEPTION_ERROR;

838: CLOSE c_get_agr_num_csr;
839:
840: IF(NVL(lv_pending_req_cvar,'Y') = 'X')THEN
841: OKL_API.set_message(G_APP_NAME, G_PENDING_CHANGE_REQ_EXISTS, 'AGR_NUMBER', lv_agreement_number);
842: RAISE OKL_API.G_EXCEPTION_ERROR;
843: END IF;
844:
845: -- third: check if the agreement is ACTIVE. Change Requests cannot be created for non active agreements
846: IF(lv_agreement_status <> G_ACTIVE_STS_CODE)THEN

Line 847: OKL_API.set_message(G_APP_NAME, G_NOT_ACTIVE_AGREEMENT, 'AGR_NUMBER', lv_agreement_number);

843: END IF;
844:
845: -- third: check if the agreement is ACTIVE. Change Requests cannot be created for non active agreements
846: IF(lv_agreement_status <> G_ACTIVE_STS_CODE)THEN
847: OKL_API.set_message(G_APP_NAME, G_NOT_ACTIVE_AGREEMENT, 'AGR_NUMBER', lv_agreement_number);
848: RAISE OKL_API.G_EXCEPTION_ERROR;
849: END IF;
850:
851: -- fourth: check there is atleast one change request reason for the AGREEMENT or ASSOCIATION type of change request

Line 848: RAISE OKL_API.G_EXCEPTION_ERROR;

844:
845: -- third: check if the agreement is ACTIVE. Change Requests cannot be created for non active agreements
846: IF(lv_agreement_status <> G_ACTIVE_STS_CODE)THEN
847: OKL_API.set_message(G_APP_NAME, G_NOT_ACTIVE_AGREEMENT, 'AGR_NUMBER', lv_agreement_number);
848: RAISE OKL_API.G_EXCEPTION_ERROR;
849: END IF;
850:
851: -- fourth: check there is atleast one change request reason for the AGREEMENT or ASSOCIATION type of change request
852: IF(p_vrrv_tbl.COUNT <= 0)THEN

Line 853: OKL_API.set_message(G_APP_NAME, G_ONE_REASON_REQD);

849: END IF;
850:
851: -- fourth: check there is atleast one change request reason for the AGREEMENT or ASSOCIATION type of change request
852: IF(p_vrrv_tbl.COUNT <= 0)THEN
853: OKL_API.set_message(G_APP_NAME, G_ONE_REASON_REQD);
854: RAISE OKL_API.G_EXCEPTION_ERROR;
855: END IF;
856:
857: -- check if this is the first change request for this vendor agreement and if so, take a backup

Line 854: RAISE OKL_API.G_EXCEPTION_ERROR;

850:
851: -- fourth: check there is atleast one change request reason for the AGREEMENT or ASSOCIATION type of change request
852: IF(p_vrrv_tbl.COUNT <= 0)THEN
853: OKL_API.set_message(G_APP_NAME, G_ONE_REASON_REQD);
854: RAISE OKL_API.G_EXCEPTION_ERROR;
855: END IF;
856:
857: -- check if this is the first change request for this vendor agreement and if so, take a backup
858: -- of the original agreement and associate with another change request whose status is created as COMPLETED

Line 873: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

869: ,p_vcrv_rec => lv_vcrv_rec
870: ,p_agreement_number => lv_agreement_number
871: ,x_vcrv_rec => xc_vcrv_rec
872: );
873: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
874: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
875: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
876: RAISE OKL_API.G_EXCEPTION_ERROR;
877: END IF;

Line 874: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

870: ,p_agreement_number => lv_agreement_number
871: ,x_vcrv_rec => xc_vcrv_rec
872: );
873: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
874: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
875: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
876: RAISE OKL_API.G_EXCEPTION_ERROR;
877: END IF;
878: END IF; -- end of NVL(lv_is_first_cr,'Y')<>'X'

Line 875: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

871: ,x_vcrv_rec => xc_vcrv_rec
872: );
873: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
874: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
875: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
876: RAISE OKL_API.G_EXCEPTION_ERROR;
877: END IF;
878: END IF; -- end of NVL(lv_is_first_cr,'Y')<>'X'
879:

Line 876: RAISE OKL_API.G_EXCEPTION_ERROR;

872: );
873: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
874: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
875: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
876: RAISE OKL_API.G_EXCEPTION_ERROR;
877: END IF;
878: END IF; -- end of NVL(lv_is_first_cr,'Y')<>'X'
879:
880: IF(lv_vcrv_rec.change_type_code=G_ARGREEMENT_TYPE_CODE)THEN

Line 905: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

901: ,x_msg_data => x_msg_data
902: ,p_copy_rec => lv_vagr_hdr_rec
903: ,x_new_contract_id => lx_new_agr_id
904: );
905: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
906: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
907: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
908: RAISE OKL_API.G_EXCEPTION_ERROR;
909: END IF;

Line 906: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

902: ,p_copy_rec => lv_vagr_hdr_rec
903: ,x_new_contract_id => lx_new_agr_id
904: );
905: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
906: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
907: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
908: RAISE OKL_API.G_EXCEPTION_ERROR;
909: END IF;
910:

Line 907: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

903: ,x_new_contract_id => lx_new_agr_id
904: );
905: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
906: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
907: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
908: RAISE OKL_API.G_EXCEPTION_ERROR;
909: END IF;
910:
911: -- create change request header and change request reasons

Line 908: RAISE OKL_API.G_EXCEPTION_ERROR;

904: );
905: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
906: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
907: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
908: RAISE OKL_API.G_EXCEPTION_ERROR;
909: END IF;
910:
911: -- create change request header and change request reasons
912: lv_vcrv_rec.status_code := 'NEW';

Line 926: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

922: ,x_msg_data => x_msg_data
923: ,p_vcrv_rec => lv_vcrv_rec
924: ,x_vcrv_rec => x_vcrv_rec
925: );
926: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
927: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
928: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
929: RAISE OKL_API.G_EXCEPTION_ERROR;
930: END IF;

Line 927: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

923: ,p_vcrv_rec => lv_vcrv_rec
924: ,x_vcrv_rec => x_vcrv_rec
925: );
926: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
927: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
928: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
929: RAISE OKL_API.G_EXCEPTION_ERROR;
930: END IF;
931:

Line 928: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

924: ,x_vcrv_rec => x_vcrv_rec
925: );
926: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
927: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
928: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
929: RAISE OKL_API.G_EXCEPTION_ERROR;
930: END IF;
931:
932: -- make sure there are reasons to record and call the api.

Line 929: RAISE OKL_API.G_EXCEPTION_ERROR;

925: );
926: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
927: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
928: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
929: RAISE OKL_API.G_EXCEPTION_ERROR;
930: END IF;
931:
932: -- make sure there are reasons to record and call the api.
933: IF(p_vrrv_tbl.COUNT > 0)THEN

Line 948: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

944: ,p_vrrv_tbl => lv_vrrv_tbl
945: ,x_vrrv_tbl => x_vrrv_tbl
946: ,x_request_status => x_request_status
947: );
948: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
949: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
950: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
951: RAISE OKL_API.G_EXCEPTION_ERROR;
952: END IF;

Line 949: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

945: ,x_vrrv_tbl => x_vrrv_tbl
946: ,x_request_status => x_request_status
947: );
948: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
949: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
950: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
951: RAISE OKL_API.G_EXCEPTION_ERROR;
952: END IF;
953: END IF; -- end of p_vrrv_tbl.COUNT > 0

Line 950: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

946: ,x_request_status => x_request_status
947: );
948: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
949: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
950: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
951: RAISE OKL_API.G_EXCEPTION_ERROR;
952: END IF;
953: END IF; -- end of p_vrrv_tbl.COUNT > 0
954:

Line 951: RAISE OKL_API.G_EXCEPTION_ERROR;

947: );
948: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
949: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
950: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
951: RAISE OKL_API.G_EXCEPTION_ERROR;
952: END IF;
953: END IF; -- end of p_vrrv_tbl.COUNT > 0
954:
955: -- now that the agreement copy is created, set the change request id in the okl_k_headers to the created change request

Line 966: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

962: ,x_msg_count => x_msg_count
963: ,x_msg_data => x_msg_data
964: ,p_khrv_rec => lv_khrv_rec
965: ,x_khrv_rec => x_khrv_rec);
966: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
967: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
968: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
969: RAISE OKL_API.G_EXCEPTION_ERROR;
970: END IF;

Line 967: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

963: ,x_msg_data => x_msg_data
964: ,p_khrv_rec => lv_khrv_rec
965: ,x_khrv_rec => x_khrv_rec);
966: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
967: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
968: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
969: RAISE OKL_API.G_EXCEPTION_ERROR;
970: END IF;
971:

Line 968: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

964: ,p_khrv_rec => lv_khrv_rec
965: ,x_khrv_rec => x_khrv_rec);
966: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
967: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
968: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
969: RAISE OKL_API.G_EXCEPTION_ERROR;
970: END IF;
971:
972: -- now copy the out variable of x_vcrv_rec.chr_id to the new agreement id that was created for this

Line 969: RAISE OKL_API.G_EXCEPTION_ERROR;

965: ,x_khrv_rec => x_khrv_rec);
966: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
967: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
968: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
969: RAISE OKL_API.G_EXCEPTION_ERROR;
970: END IF;
971:
972: -- now copy the out variable of x_vcrv_rec.chr_id to the new agreement id that was created for this
973: -- AGREEMENT type of change request. this is essential because the UI depends on this parameter.

Line 994: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

990: ,x_msg_data => x_msg_data
991: ,p_vcrv_rec => lv_vcrv_rec
992: ,x_vcrv_rec => x_vcrv_rec
993: );
994: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
995: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
996: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
997: RAISE OKL_API.G_EXCEPTION_ERROR;
998: END IF;

Line 995: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

991: ,p_vcrv_rec => lv_vcrv_rec
992: ,x_vcrv_rec => x_vcrv_rec
993: );
994: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
995: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
996: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
997: RAISE OKL_API.G_EXCEPTION_ERROR;
998: END IF;
999:

Line 996: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

992: ,x_vcrv_rec => x_vcrv_rec
993: );
994: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
995: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
996: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
997: RAISE OKL_API.G_EXCEPTION_ERROR;
998: END IF;
999:
1000: -- make sure there are reasons to record and call the api.

Line 997: RAISE OKL_API.G_EXCEPTION_ERROR;

993: );
994: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
995: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
996: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
997: RAISE OKL_API.G_EXCEPTION_ERROR;
998: END IF;
999:
1000: -- make sure there are reasons to record and call the api.
1001: IF(p_vrrv_tbl.COUNT > 0)THEN

Line 1016: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1012: ,p_vrrv_tbl => lv_vrrv_tbl
1013: ,x_vrrv_tbl => x_vrrv_tbl
1014: ,x_request_status => x_request_status
1015: );
1016: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1017: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1018: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1019: RAISE OKL_API.G_EXCEPTION_ERROR;
1020: END IF;

Line 1017: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1013: ,x_vrrv_tbl => x_vrrv_tbl
1014: ,x_request_status => x_request_status
1015: );
1016: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1017: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1018: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1019: RAISE OKL_API.G_EXCEPTION_ERROR;
1020: END IF;
1021: END IF; -- end of p_vrrv_tbl.COUNT > 0

Line 1018: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1014: ,x_request_status => x_request_status
1015: );
1016: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1017: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1018: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1019: RAISE OKL_API.G_EXCEPTION_ERROR;
1020: END IF;
1021: END IF; -- end of p_vrrv_tbl.COUNT > 0
1022:

Line 1019: RAISE OKL_API.G_EXCEPTION_ERROR;

1015: );
1016: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1017: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1018: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1019: RAISE OKL_API.G_EXCEPTION_ERROR;
1020: END IF;
1021: END IF; -- end of p_vrrv_tbl.COUNT > 0
1022:
1023: -- for ASSOCIATION type of change requests, the associations on the original agreements are copied over to the

Line 1034: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1030: ,x_msg_data => x_msg_data
1031: ,p_chr_id => lv_vcrv_rec.chr_id
1032: ,p_crs_id => x_vcrv_rec.id
1033: );
1034: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1035: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1036: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1037: RAISE OKL_API.G_EXCEPTION_ERROR;
1038: END IF;

Line 1035: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1031: ,p_chr_id => lv_vcrv_rec.chr_id
1032: ,p_crs_id => x_vcrv_rec.id
1033: );
1034: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1035: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1036: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1037: RAISE OKL_API.G_EXCEPTION_ERROR;
1038: END IF;
1039: END IF; -- end if for lv_vcrv_rec.change_type_code=G_ARGREEMENT_TYPE_CODE

Line 1036: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1032: ,p_crs_id => x_vcrv_rec.id
1033: );
1034: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1035: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1036: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1037: RAISE OKL_API.G_EXCEPTION_ERROR;
1038: END IF;
1039: END IF; -- end if for lv_vcrv_rec.change_type_code=G_ARGREEMENT_TYPE_CODE
1040:

Line 1037: RAISE OKL_API.G_EXCEPTION_ERROR;

1033: );
1034: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1035: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1036: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1037: RAISE OKL_API.G_EXCEPTION_ERROR;
1038: END IF;
1039: END IF; -- end if for lv_vcrv_rec.change_type_code=G_ARGREEMENT_TYPE_CODE
1040:
1041: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

Line 1041: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

1037: RAISE OKL_API.G_EXCEPTION_ERROR;
1038: END IF;
1039: END IF; -- end if for lv_vcrv_rec.change_type_code=G_ARGREEMENT_TYPE_CODE
1040:
1041: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
1042:
1043: IF(l_debug_enabled='Y') THEN
1044: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request');
1045: END IF;

Line 1047: WHEN OKL_API.G_EXCEPTION_ERROR THEN

1043: IF(l_debug_enabled='Y') THEN
1044: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request');
1045: END IF;
1046: EXCEPTION
1047: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1048: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1049: p_api_name => l_api_name,
1050: p_pkg_name => G_PKG_NAME,
1051: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 1048: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1044: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call create_change_request');
1045: END IF;
1046: EXCEPTION
1047: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1048: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1049: p_api_name => l_api_name,
1050: p_pkg_name => G_PKG_NAME,
1051: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1052: x_msg_count => x_msg_count,

Line 1051: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

1047: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1048: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1049: p_api_name => l_api_name,
1050: p_pkg_name => G_PKG_NAME,
1051: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1052: x_msg_count => x_msg_count,
1053: x_msg_data => x_msg_data,
1054: p_api_type => g_api_type);
1055:

Line 1056: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

1052: x_msg_count => x_msg_count,
1053: x_msg_data => x_msg_data,
1054: p_api_type => g_api_type);
1055:
1056: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1057: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1058: p_api_name => l_api_name,
1059: p_pkg_name => G_PKG_NAME,
1060: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 1057: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1053: x_msg_data => x_msg_data,
1054: p_api_type => g_api_type);
1055:
1056: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1057: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1058: p_api_name => l_api_name,
1059: p_pkg_name => G_PKG_NAME,
1060: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1061: x_msg_count => x_msg_count,

Line 1060: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

1056: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1057: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1058: p_api_name => l_api_name,
1059: p_pkg_name => G_PKG_NAME,
1060: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1061: x_msg_count => x_msg_count,
1062: x_msg_data => x_msg_data,
1063: p_api_type => g_api_type);
1064:

Line 1066: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1062: x_msg_data => x_msg_data,
1063: p_api_type => g_api_type);
1064:
1065: WHEN OTHERS THEN
1066: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1067: p_api_name => l_api_name,
1068: p_pkg_name => G_PKG_NAME,
1069: p_exc_name => 'OTHERS',
1070: x_msg_count => x_msg_count,

Line 1089: x_return_status := OKL_API.G_RET_STS_SUCCESS;

1085: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.ABANDON_CHANGE_REQUEST';
1086: l_debug_enabled VARCHAR2(10);
1087:
1088: BEGIN
1089: x_return_status := OKL_API.G_RET_STS_SUCCESS;
1090:
1091: l_debug_enabled := okl_debug_pub.check_log_enabled;
1092:
1093: IF(l_debug_enabled='Y') THEN

Line 1098: x_return_status := OKL_API.START_ACTIVITY(

1094: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call abandon_change_request');
1095: END IF;
1096:
1097: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
1098: x_return_status := OKL_API.START_ACTIVITY(
1099: p_api_name => l_api_name
1100: ,p_pkg_name => G_PKG_NAME
1101: ,p_init_msg_list => p_init_msg_list
1102: ,l_api_version => l_api_version

Line 1107: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1103: ,p_api_version => p_api_version
1104: ,p_api_type => g_api_type
1105: ,x_return_status => x_return_status);
1106: -- check if activity started successfully
1107: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1108: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1109: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1110: RAISE OKL_API.G_EXCEPTION_ERROR;
1111: END IF;

Line 1108: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1104: ,p_api_type => g_api_type
1105: ,x_return_status => x_return_status);
1106: -- check if activity started successfully
1107: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1108: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1109: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1110: RAISE OKL_API.G_EXCEPTION_ERROR;
1111: END IF;
1112:

Line 1109: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1105: ,x_return_status => x_return_status);
1106: -- check if activity started successfully
1107: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1108: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1109: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1110: RAISE OKL_API.G_EXCEPTION_ERROR;
1111: END IF;
1112:
1113: set_change_request_status(p_api_version => p_api_version

Line 1110: RAISE OKL_API.G_EXCEPTION_ERROR;

1106: -- check if activity started successfully
1107: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1108: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1109: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1110: RAISE OKL_API.G_EXCEPTION_ERROR;
1111: END IF;
1112:
1113: set_change_request_status(p_api_version => p_api_version
1114: ,p_init_msg_list => p_init_msg_list

Line 1128: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1124: l_module,
1125: 'set_change_request_status for '||p_vcrv_rec.id||' from abandon_change_request returned with status '||x_return_status
1126: );
1127: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1128: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1129: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1130: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1131: RAISE OKL_API.G_EXCEPTION_ERROR;
1132: END IF;

Line 1129: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1125: 'set_change_request_status for '||p_vcrv_rec.id||' from abandon_change_request returned with status '||x_return_status
1126: );
1127: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1128: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1129: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1130: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1131: RAISE OKL_API.G_EXCEPTION_ERROR;
1132: END IF;
1133:

Line 1130: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1126: );
1127: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1128: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1129: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1130: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1131: RAISE OKL_API.G_EXCEPTION_ERROR;
1132: END IF;
1133:
1134: -- now set the OUT variables for calling UI or API use

Line 1131: RAISE OKL_API.G_EXCEPTION_ERROR;

1127: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1128: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1129: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1130: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1131: RAISE OKL_API.G_EXCEPTION_ERROR;
1132: END IF;
1133:
1134: -- now set the OUT variables for calling UI or API use
1135: x_vcrv_rec.id := p_vcrv_rec.id;

Line 1138: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

1134: -- now set the OUT variables for calling UI or API use
1135: x_vcrv_rec.id := p_vcrv_rec.id;
1136: x_vcrv_rec.status_code := G_ABANDONED_STS_CODE;
1137:
1138: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
1139:
1140: IF(l_debug_enabled='Y') THEN
1141: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call abandon_change_request');
1142: END IF;

Line 1144: WHEN OKL_API.G_EXCEPTION_ERROR THEN

1140: IF(l_debug_enabled='Y') THEN
1141: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call abandon_change_request');
1142: END IF;
1143: EXCEPTION
1144: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1145: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1146: p_api_name => l_api_name,
1147: p_pkg_name => G_PKG_NAME,
1148: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 1145: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1141: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call abandon_change_request');
1142: END IF;
1143: EXCEPTION
1144: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1145: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1146: p_api_name => l_api_name,
1147: p_pkg_name => G_PKG_NAME,
1148: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1149: x_msg_count => x_msg_count,

Line 1148: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

1144: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1145: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1146: p_api_name => l_api_name,
1147: p_pkg_name => G_PKG_NAME,
1148: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1149: x_msg_count => x_msg_count,
1150: x_msg_data => x_msg_data,
1151: p_api_type => g_api_type);
1152:

Line 1153: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

1149: x_msg_count => x_msg_count,
1150: x_msg_data => x_msg_data,
1151: p_api_type => g_api_type);
1152:
1153: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1154: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1155: p_api_name => l_api_name,
1156: p_pkg_name => G_PKG_NAME,
1157: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 1154: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1150: x_msg_data => x_msg_data,
1151: p_api_type => g_api_type);
1152:
1153: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1154: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1155: p_api_name => l_api_name,
1156: p_pkg_name => G_PKG_NAME,
1157: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1158: x_msg_count => x_msg_count,

Line 1157: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

1153: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1154: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1155: p_api_name => l_api_name,
1156: p_pkg_name => G_PKG_NAME,
1157: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1158: x_msg_count => x_msg_count,
1159: x_msg_data => x_msg_data,
1160: p_api_type => g_api_type);
1161:

Line 1163: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1159: x_msg_data => x_msg_data,
1160: p_api_type => g_api_type);
1161:
1162: WHEN OTHERS THEN
1163: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1164: p_api_name => l_api_name,
1165: p_pkg_name => G_PKG_NAME,
1166: p_exc_name => 'OTHERS',
1167: x_msg_count => x_msg_count,

Line 1208: x_return_status := OKL_API.G_RET_STS_SUCCESS;

1204: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.SET_CHANGE_REQUEST_STATUS';
1205: l_debug_enabled VARCHAR2(10);
1206:
1207: BEGIN
1208: x_return_status := OKL_API.G_RET_STS_SUCCESS;
1209:
1210: l_debug_enabled := okl_debug_pub.check_log_enabled;
1211:
1212: IF(l_debug_enabled='Y') THEN

Line 1217: x_return_status := OKL_API.START_ACTIVITY(

1213: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call set_change_request_status');
1214: END IF;
1215:
1216: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
1217: x_return_status := OKL_API.START_ACTIVITY(
1218: p_api_name => l_api_name
1219: ,p_pkg_name => G_PKG_NAME
1220: ,p_init_msg_list => p_init_msg_list
1221: ,l_api_version => l_api_version

Line 1226: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1222: ,p_api_version => p_api_version
1223: ,p_api_type => g_api_type
1224: ,x_return_status => x_return_status);
1225: -- check if activity started successfully
1226: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1227: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1228: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1229: RAISE OKL_API.G_EXCEPTION_ERROR;
1230: END IF;

Line 1227: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1223: ,p_api_type => g_api_type
1224: ,x_return_status => x_return_status);
1225: -- check if activity started successfully
1226: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1227: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1228: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1229: RAISE OKL_API.G_EXCEPTION_ERROR;
1230: END IF;
1231:

Line 1228: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1224: ,x_return_status => x_return_status);
1225: -- check if activity started successfully
1226: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1227: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1228: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1229: RAISE OKL_API.G_EXCEPTION_ERROR;
1230: END IF;
1231:
1232: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM OR p_status_code IS NULL OR p_status_code = OKL_API.G_MISS_CHAR)THEN

Line 1229: RAISE OKL_API.G_EXCEPTION_ERROR;

1225: -- check if activity started successfully
1226: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1227: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1228: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1229: RAISE OKL_API.G_EXCEPTION_ERROR;
1230: END IF;
1231:
1232: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM OR p_status_code IS NULL OR p_status_code = OKL_API.G_MISS_CHAR)THEN
1233: OKL_API.set_message(G_APP_NAME, G_NO_PARAM_STS_CODE);

Line 1232: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM OR p_status_code IS NULL OR p_status_code = OKL_API.G_MISS_CHAR)THEN

1228: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1229: RAISE OKL_API.G_EXCEPTION_ERROR;
1230: END IF;
1231:
1232: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM OR p_status_code IS NULL OR p_status_code = OKL_API.G_MISS_CHAR)THEN
1233: OKL_API.set_message(G_APP_NAME, G_NO_PARAM_STS_CODE);
1234: RAISE OKL_API.G_EXCEPTION_ERROR;
1235: END IF;
1236:

Line 1233: OKL_API.set_message(G_APP_NAME, G_NO_PARAM_STS_CODE);

1229: RAISE OKL_API.G_EXCEPTION_ERROR;
1230: END IF;
1231:
1232: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM OR p_status_code IS NULL OR p_status_code = OKL_API.G_MISS_CHAR)THEN
1233: OKL_API.set_message(G_APP_NAME, G_NO_PARAM_STS_CODE);
1234: RAISE OKL_API.G_EXCEPTION_ERROR;
1235: END IF;
1236:
1237: OPEN c_get_cr_dtls_csr(p_vp_crq_id); FETCH c_get_cr_dtls_csr INTO cv_get_cr_dtls;

Line 1234: RAISE OKL_API.G_EXCEPTION_ERROR;

1230: END IF;
1231:
1232: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM OR p_status_code IS NULL OR p_status_code = OKL_API.G_MISS_CHAR)THEN
1233: OKL_API.set_message(G_APP_NAME, G_NO_PARAM_STS_CODE);
1234: RAISE OKL_API.G_EXCEPTION_ERROR;
1235: END IF;
1236:
1237: OPEN c_get_cr_dtls_csr(p_vp_crq_id); FETCH c_get_cr_dtls_csr INTO cv_get_cr_dtls;
1238: CLOSE c_get_cr_dtls_csr;

Line 1244: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_INCOMP, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);

1240: -- if status code is being set to incomplete then the status code in the db should be either PASSED or REJECTED
1241: -- error otherwise
1242: IF(G_INCOMPLETE_STS_CODE = p_status_code)THEN
1243: IF(cv_get_cr_dtls.status_code NOT IN(G_NEW_STS_CODE, G_PASSED_STS_CODE, G_REJECTED_STS_CODE))THEN
1244: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_INCOMP, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);
1245: RAISE OKL_API.G_EXCEPTION_ERROR;
1246: END IF;
1247: ELSIF(G_PENDING_STS_CODE = p_status_code)THEN
1248: -- check useful from preventing the user from resubmitting the change request and also to prevent the same workflow

Line 1245: RAISE OKL_API.G_EXCEPTION_ERROR;

1241: -- error otherwise
1242: IF(G_INCOMPLETE_STS_CODE = p_status_code)THEN
1243: IF(cv_get_cr_dtls.status_code NOT IN(G_NEW_STS_CODE, G_PASSED_STS_CODE, G_REJECTED_STS_CODE))THEN
1244: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_INCOMP, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);
1245: RAISE OKL_API.G_EXCEPTION_ERROR;
1246: END IF;
1247: ELSIF(G_PENDING_STS_CODE = p_status_code)THEN
1248: -- check useful from preventing the user from resubmitting the change request and also to prevent the same workflow
1249: -- being re-launched

Line 1251: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_PENDING, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);

1247: ELSIF(G_PENDING_STS_CODE = p_status_code)THEN
1248: -- check useful from preventing the user from resubmitting the change request and also to prevent the same workflow
1249: -- being re-launched
1250: IF(cv_get_cr_dtls.status_code NOT IN(G_PASSED_STS_CODE))THEN
1251: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_PENDING, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);
1252: RAISE OKL_API.G_EXCEPTION_ERROR;
1253: END IF;
1254: ELSIF(G_APPROVED_STS_CODE = p_status_code)THEN
1255: -- if a change request to be approved, the prior status should have been PENDING_APPROVAL, error otherwise

Line 1252: RAISE OKL_API.G_EXCEPTION_ERROR;

1248: -- check useful from preventing the user from resubmitting the change request and also to prevent the same workflow
1249: -- being re-launched
1250: IF(cv_get_cr_dtls.status_code NOT IN(G_PASSED_STS_CODE))THEN
1251: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_PENDING, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);
1252: RAISE OKL_API.G_EXCEPTION_ERROR;
1253: END IF;
1254: ELSIF(G_APPROVED_STS_CODE = p_status_code)THEN
1255: -- if a change request to be approved, the prior status should have been PENDING_APPROVAL, error otherwise
1256: IF(cv_get_cr_dtls.status_code NOT IN(G_PENDING_STS_CODE))THEN

Line 1257: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_APPROVED, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);

1253: END IF;
1254: ELSIF(G_APPROVED_STS_CODE = p_status_code)THEN
1255: -- if a change request to be approved, the prior status should have been PENDING_APPROVAL, error otherwise
1256: IF(cv_get_cr_dtls.status_code NOT IN(G_PENDING_STS_CODE))THEN
1257: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_APPROVED, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);
1258: RAISE OKL_API.G_EXCEPTION_ERROR;
1259: END IF;
1260: lv_vcrv_rec.approved_date := TRUNC(SYSDATE);
1261: ELSIF(G_ABANDONED_STS_CODE = p_status_code)THEN

Line 1258: RAISE OKL_API.G_EXCEPTION_ERROR;

1254: ELSIF(G_APPROVED_STS_CODE = p_status_code)THEN
1255: -- if a change request to be approved, the prior status should have been PENDING_APPROVAL, error otherwise
1256: IF(cv_get_cr_dtls.status_code NOT IN(G_PENDING_STS_CODE))THEN
1257: OKL_API.set_message(G_APP_NAME, G_INVALID_STS_APPROVED, 'CHANGE_REQ_NUM',cv_get_cr_dtls.change_request_number);
1258: RAISE OKL_API.G_EXCEPTION_ERROR;
1259: END IF;
1260: lv_vcrv_rec.approved_date := TRUNC(SYSDATE);
1261: ELSIF(G_ABANDONED_STS_CODE = p_status_code)THEN
1262: -- verify if the change request whose abandonment is requested is in status NEW, PASSED, INCOMPLETE or REJECTED. error otherwise

Line 1265: OKL_API.set_message(G_APP_NAME, G_NOT_NEW_PASS_CR, 'CHANGE_REQ_NUM', cv_get_cr_dtls.change_request_number);

1261: ELSIF(G_ABANDONED_STS_CODE = p_status_code)THEN
1262: -- verify if the change request whose abandonment is requested is in status NEW, PASSED, INCOMPLETE or REJECTED. error otherwise
1263: -- this check will also prevent user from re-abandoning the change request by use of browser refresh button
1264: IF(cv_get_cr_dtls.status_code NOT IN ('NEW','PASSED','INCOMPLETE','REJECTED'))THEN
1265: OKL_API.set_message(G_APP_NAME, G_NOT_NEW_PASS_CR, 'CHANGE_REQ_NUM', cv_get_cr_dtls.change_request_number);
1266: RAISE OKL_API.G_EXCEPTION_ERROR;
1267: END IF;
1268: END IF;
1269:

Line 1266: RAISE OKL_API.G_EXCEPTION_ERROR;

1262: -- verify if the change request whose abandonment is requested is in status NEW, PASSED, INCOMPLETE or REJECTED. error otherwise
1263: -- this check will also prevent user from re-abandoning the change request by use of browser refresh button
1264: IF(cv_get_cr_dtls.status_code NOT IN ('NEW','PASSED','INCOMPLETE','REJECTED'))THEN
1265: OKL_API.set_message(G_APP_NAME, G_NOT_NEW_PASS_CR, 'CHANGE_REQ_NUM', cv_get_cr_dtls.change_request_number);
1266: RAISE OKL_API.G_EXCEPTION_ERROR;
1267: END IF;
1268: END IF;
1269:
1270: -- for AGREEMENT type of change request, the referred agreement has also be set to status that was set

Line 1294: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1290: l_module,
1291: 'okl_contract_status_pub.update_contract_status returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
1292: );
1293: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1294: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1295: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1296: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1297: RAISE OKL_API.G_EXCEPTION_ERROR;
1298: END IF;

Line 1295: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1291: 'okl_contract_status_pub.update_contract_status returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
1292: );
1293: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1294: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1295: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1296: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1297: RAISE OKL_API.G_EXCEPTION_ERROR;
1298: END IF;
1299: END IF;

Line 1296: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1292: );
1293: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1294: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1295: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1296: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1297: RAISE OKL_API.G_EXCEPTION_ERROR;
1298: END IF;
1299: END IF;
1300:

Line 1297: RAISE OKL_API.G_EXCEPTION_ERROR;

1293: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1294: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1295: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1296: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1297: RAISE OKL_API.G_EXCEPTION_ERROR;
1298: END IF;
1299: END IF;
1300:
1301: -- now set the status of the change request once the copy agreement has been changed

Line 1324: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1320: l_module,
1321: 'update_change_request_header returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
1322: );
1323: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1324: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1325: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1326: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1327: RAISE OKL_API.G_EXCEPTION_ERROR;
1328: END IF;

Line 1325: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1321: 'update_change_request_header returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
1322: );
1323: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1324: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1325: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1326: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1327: RAISE OKL_API.G_EXCEPTION_ERROR;
1328: END IF;
1329:

Line 1326: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1322: );
1323: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1324: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1325: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1326: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1327: RAISE OKL_API.G_EXCEPTION_ERROR;
1328: END IF;
1329:
1330: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

Line 1327: RAISE OKL_API.G_EXCEPTION_ERROR;

1323: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1324: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1325: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1326: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1327: RAISE OKL_API.G_EXCEPTION_ERROR;
1328: END IF;
1329:
1330: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
1331:

Line 1330: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

1326: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1327: RAISE OKL_API.G_EXCEPTION_ERROR;
1328: END IF;
1329:
1330: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
1331:
1332: IF(l_debug_enabled='Y') THEN
1333: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call set_change_request_status');
1334: END IF;

Line 1337: WHEN OKL_API.G_EXCEPTION_ERROR THEN

1333: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call set_change_request_status');
1334: END IF;
1335:
1336: EXCEPTION
1337: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1338: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1339: p_api_name => l_api_name,
1340: p_pkg_name => G_PKG_NAME,
1341: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 1338: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1334: END IF;
1335:
1336: EXCEPTION
1337: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1338: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1339: p_api_name => l_api_name,
1340: p_pkg_name => G_PKG_NAME,
1341: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1342: x_msg_count => x_msg_count,

Line 1341: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

1337: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1338: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1339: p_api_name => l_api_name,
1340: p_pkg_name => G_PKG_NAME,
1341: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1342: x_msg_count => x_msg_count,
1343: x_msg_data => x_msg_data,
1344: p_api_type => g_api_type);
1345:

Line 1346: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

1342: x_msg_count => x_msg_count,
1343: x_msg_data => x_msg_data,
1344: p_api_type => g_api_type);
1345:
1346: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1347: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1348: p_api_name => l_api_name,
1349: p_pkg_name => G_PKG_NAME,
1350: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 1347: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1343: x_msg_data => x_msg_data,
1344: p_api_type => g_api_type);
1345:
1346: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1347: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1348: p_api_name => l_api_name,
1349: p_pkg_name => G_PKG_NAME,
1350: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1351: x_msg_count => x_msg_count,

Line 1350: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

1346: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1347: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1348: p_api_name => l_api_name,
1349: p_pkg_name => G_PKG_NAME,
1350: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1351: x_msg_count => x_msg_count,
1352: x_msg_data => x_msg_data,
1353: p_api_type => g_api_type);
1354:

Line 1356: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1352: x_msg_data => x_msg_data,
1353: p_api_type => g_api_type);
1354:
1355: WHEN OTHERS THEN
1356: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1357: p_api_name => l_api_name,
1358: p_pkg_name => G_PKG_NAME,
1359: p_exc_name => 'OTHERS',
1360: x_msg_count => x_msg_count,

Line 1388: x_return_status := OKL_API.G_RET_STS_SUCCESS;

1384: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.CASCADE_REQUEST_STATUS_EDIT';
1385: l_debug_enabled VARCHAR2(10);
1386:
1387: BEGIN
1388: x_return_status := OKL_API.G_RET_STS_SUCCESS;
1389:
1390: l_debug_enabled := okl_debug_pub.check_log_enabled;
1391:
1392: IF(l_debug_enabled='Y') THEN

Line 1397: x_return_status := OKL_API.START_ACTIVITY(

1393: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call cascade_request_status_edit');
1394: END IF;
1395:
1396: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
1397: x_return_status := OKL_API.START_ACTIVITY(
1398: p_api_name => l_api_name
1399: ,p_pkg_name => G_PKG_NAME
1400: ,p_init_msg_list => p_init_msg_list
1401: ,l_api_version => l_api_version

Line 1406: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1402: ,p_api_version => p_api_version
1403: ,p_api_type => g_api_type
1404: ,x_return_status => x_return_status);
1405: -- check if activity started successfully
1406: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1407: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1408: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1409: RAISE OKL_API.G_EXCEPTION_ERROR;
1410: END IF;

Line 1407: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1403: ,p_api_type => g_api_type
1404: ,x_return_status => x_return_status);
1405: -- check if activity started successfully
1406: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1407: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1408: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1409: RAISE OKL_API.G_EXCEPTION_ERROR;
1410: END IF;
1411:

Line 1408: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1404: ,x_return_status => x_return_status);
1405: -- check if activity started successfully
1406: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1407: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1408: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1409: RAISE OKL_API.G_EXCEPTION_ERROR;
1410: END IF;
1411:
1412: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM)THEN

Line 1409: RAISE OKL_API.G_EXCEPTION_ERROR;

1405: -- check if activity started successfully
1406: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1407: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1408: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1409: RAISE OKL_API.G_EXCEPTION_ERROR;
1410: END IF;
1411:
1412: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM)THEN
1413: OKL_API.set_message(G_APP_NAME, OKL_API.G_REQUIRED_VALUE, OKL_API.G_COL_NAME_TOKEN, 'ID');

Line 1412: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM)THEN

1408: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1409: RAISE OKL_API.G_EXCEPTION_ERROR;
1410: END IF;
1411:
1412: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM)THEN
1413: OKL_API.set_message(G_APP_NAME, OKL_API.G_REQUIRED_VALUE, OKL_API.G_COL_NAME_TOKEN, 'ID');
1414: RAISE OKL_API.G_EXCEPTION_ERROR;
1415: END IF;
1416: -- if the change request is in status PASSED then we need to set it back to INCOMPLETE

Line 1413: OKL_API.set_message(G_APP_NAME, OKL_API.G_REQUIRED_VALUE, OKL_API.G_COL_NAME_TOKEN, 'ID');

1409: RAISE OKL_API.G_EXCEPTION_ERROR;
1410: END IF;
1411:
1412: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM)THEN
1413: OKL_API.set_message(G_APP_NAME, OKL_API.G_REQUIRED_VALUE, OKL_API.G_COL_NAME_TOKEN, 'ID');
1414: RAISE OKL_API.G_EXCEPTION_ERROR;
1415: END IF;
1416: -- if the change request is in status PASSED then we need to set it back to INCOMPLETE
1417: OPEN c_get_cr_sts_csr(p_vp_crq_id); FETCH c_get_cr_sts_csr INTO c_get_cr_sts_rec;

Line 1414: RAISE OKL_API.G_EXCEPTION_ERROR;

1410: END IF;
1411:
1412: IF(p_vp_crq_id IS NULL OR p_vp_crq_id = OKL_API.G_MISS_NUM)THEN
1413: OKL_API.set_message(G_APP_NAME, OKL_API.G_REQUIRED_VALUE, OKL_API.G_COL_NAME_TOKEN, 'ID');
1414: RAISE OKL_API.G_EXCEPTION_ERROR;
1415: END IF;
1416: -- if the change request is in status PASSED then we need to set it back to INCOMPLETE
1417: OPEN c_get_cr_sts_csr(p_vp_crq_id); FETCH c_get_cr_sts_csr INTO c_get_cr_sts_rec;
1418: CLOSE c_get_cr_sts_csr;

Line 1437: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1433: l_module,
1434: 'set_change_request_status returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
1435: );
1436: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1437: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1438: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1439: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1440: RAISE OKL_API.G_EXCEPTION_ERROR;
1441: END IF;

Line 1438: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1434: 'set_change_request_status returned with status '||x_return_status||' x_msg_data '||x_msg_data||' id '||x_vcrv_rec.id
1435: );
1436: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1437: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1438: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1439: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1440: RAISE OKL_API.G_EXCEPTION_ERROR;
1441: END IF;
1442: x_status_code := G_INCOMPLETE_STS_CODE;

Line 1439: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1435: );
1436: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1437: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1438: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1439: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1440: RAISE OKL_API.G_EXCEPTION_ERROR;
1441: END IF;
1442: x_status_code := G_INCOMPLETE_STS_CODE;
1443: ELSE

Line 1440: RAISE OKL_API.G_EXCEPTION_ERROR;

1436: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1437: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1438: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1439: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1440: RAISE OKL_API.G_EXCEPTION_ERROR;
1441: END IF;
1442: x_status_code := G_INCOMPLETE_STS_CODE;
1443: ELSE
1444: x_status_code := c_get_cr_sts_rec.status_code;

Line 1447: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

1443: ELSE
1444: x_status_code := c_get_cr_sts_rec.status_code;
1445: END IF; -- end of c_get_cr_sts_rec.status_code = G_PASSED_STS_CODE
1446:
1447: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
1448:
1449: IF(l_debug_enabled='Y') THEN
1450: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call cascade_request_status_edit');
1451: END IF;

Line 1454: WHEN OKL_API.G_EXCEPTION_ERROR THEN

1450: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call cascade_request_status_edit');
1451: END IF;
1452:
1453: EXCEPTION
1454: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1455: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1456: p_api_name => l_api_name,
1457: p_pkg_name => G_PKG_NAME,
1458: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 1455: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1451: END IF;
1452:
1453: EXCEPTION
1454: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1455: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1456: p_api_name => l_api_name,
1457: p_pkg_name => G_PKG_NAME,
1458: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1459: x_msg_count => x_msg_count,

Line 1458: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

1454: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1455: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1456: p_api_name => l_api_name,
1457: p_pkg_name => G_PKG_NAME,
1458: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1459: x_msg_count => x_msg_count,
1460: x_msg_data => x_msg_data,
1461: p_api_type => g_api_type);
1462:

Line 1463: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

1459: x_msg_count => x_msg_count,
1460: x_msg_data => x_msg_data,
1461: p_api_type => g_api_type);
1462:
1463: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1464: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1465: p_api_name => l_api_name,
1466: p_pkg_name => G_PKG_NAME,
1467: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 1464: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1460: x_msg_data => x_msg_data,
1461: p_api_type => g_api_type);
1462:
1463: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1464: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1465: p_api_name => l_api_name,
1466: p_pkg_name => G_PKG_NAME,
1467: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1468: x_msg_count => x_msg_count,

Line 1467: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

1463: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1464: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1465: p_api_name => l_api_name,
1466: p_pkg_name => G_PKG_NAME,
1467: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1468: x_msg_count => x_msg_count,
1469: x_msg_data => x_msg_data,
1470: p_api_type => g_api_type);
1471:

Line 1473: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1469: x_msg_data => x_msg_data,
1470: p_api_type => g_api_type);
1471:
1472: WHEN OTHERS THEN
1473: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1474: p_api_name => l_api_name,
1475: p_pkg_name => G_PKG_NAME,
1476: p_exc_name => 'OTHERS',
1477: x_msg_count => x_msg_count,

Line 1514: x_return_status := OKL_API.G_RET_STS_SUCCESS;

1510: l_module CONSTANT fnd_log_messages.module%TYPE := 'okl.plsql.OKL_VP_CHANGE_REQUEST_PVT.SUBMIT_CR_FOR_APPROVAL';
1511: l_debug_enabled VARCHAR2(10);
1512:
1513: BEGIN
1514: x_return_status := OKL_API.G_RET_STS_SUCCESS;
1515:
1516: l_debug_enabled := okl_debug_pub.check_log_enabled;
1517:
1518: IF(l_debug_enabled='Y') THEN

Line 1523: x_return_status := OKL_API.START_ACTIVITY(

1519: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'begin debug OKLRVCRB.pls call submit_cr_for_approval');
1520: END IF;
1521:
1522: -- call START_ACTIVITY to create savepoint, check compatibility and initialize message list
1523: x_return_status := OKL_API.START_ACTIVITY(
1524: p_api_name => l_api_name
1525: ,p_pkg_name => G_PKG_NAME
1526: ,p_init_msg_list => p_init_msg_list
1527: ,l_api_version => l_api_version

Line 1532: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1528: ,p_api_version => p_api_version
1529: ,p_api_type => g_api_type
1530: ,x_return_status => x_return_status);
1531: -- check if activity started successfully
1532: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1533: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1534: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1535: RAISE OKL_API.G_EXCEPTION_ERROR;
1536: END IF;

Line 1533: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1529: ,p_api_type => g_api_type
1530: ,x_return_status => x_return_status);
1531: -- check if activity started successfully
1532: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1533: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1534: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1535: RAISE OKL_API.G_EXCEPTION_ERROR;
1536: END IF;
1537:

Line 1534: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1530: ,x_return_status => x_return_status);
1531: -- check if activity started successfully
1532: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1533: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1534: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1535: RAISE OKL_API.G_EXCEPTION_ERROR;
1536: END IF;
1537:
1538: -- get the change request id from the agreement id; error if no change request found

Line 1535: RAISE OKL_API.G_EXCEPTION_ERROR;

1531: -- check if activity started successfully
1532: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1533: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1534: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1535: RAISE OKL_API.G_EXCEPTION_ERROR;
1536: END IF;
1537:
1538: -- get the change request id from the agreement id; error if no change request found
1539: OPEN c_get_change_req_csr(p_chr_id); FETCH c_get_change_req_csr INTO lv_change_request_id;

Line 1547: OKL_API.set_message(G_APP_NAME, G_CR_PARMS_MISSING);

1543: -- if no crs_id exists, then error
1544: OPEN c_get_crs_id_csr(p_chr_id); FETCH c_get_crs_id_csr INTO lv_change_request_id;
1545: IF(c_get_crs_id_csr%NOTFOUND)THEN
1546: CLOSE c_get_crs_id_csr;
1547: OKL_API.set_message(G_APP_NAME, G_CR_PARMS_MISSING);
1548: RAISE OKL_API.G_EXCEPTION_ERROR;
1549: ELSE
1550: CLOSE c_get_crs_id_csr;
1551: END IF;

Line 1548: RAISE OKL_API.G_EXCEPTION_ERROR;

1544: OPEN c_get_crs_id_csr(p_chr_id); FETCH c_get_crs_id_csr INTO lv_change_request_id;
1545: IF(c_get_crs_id_csr%NOTFOUND)THEN
1546: CLOSE c_get_crs_id_csr;
1547: OKL_API.set_message(G_APP_NAME, G_CR_PARMS_MISSING);
1548: RAISE OKL_API.G_EXCEPTION_ERROR;
1549: ELSE
1550: CLOSE c_get_crs_id_csr;
1551: END IF;
1552: ELSE

Line 1576: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1572: ,x_msg_data => x_msg_data
1573: ,p_vp_crq_id => lv_change_request_id
1574: ,p_status_code => G_PENDING_STS_CODE
1575: );
1576: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1577: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1578: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1579: RAISE OKL_API.G_EXCEPTION_ERROR;
1580: END IF;

Line 1577: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1573: ,p_vp_crq_id => lv_change_request_id
1574: ,p_status_code => G_PENDING_STS_CODE
1575: );
1576: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1577: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1578: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1579: RAISE OKL_API.G_EXCEPTION_ERROR;
1580: END IF;
1581:

Line 1578: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1574: ,p_status_code => G_PENDING_STS_CODE
1575: );
1576: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1577: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1578: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1579: RAISE OKL_API.G_EXCEPTION_ERROR;
1580: END IF;
1581:
1582: -- read the profile OKL: Change Request Approval Process

Line 1579: RAISE OKL_API.G_EXCEPTION_ERROR;

1575: );
1576: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1577: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1578: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1579: RAISE OKL_API.G_EXCEPTION_ERROR;
1580: END IF;
1581:
1582: -- read the profile OKL: Change Request Approval Process
1583: l_approval_process := fnd_profile.value('OKL_VP_CR_APPROVAL_PROCESS');

Line 1605: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1601: 'okl_vp_sync_cr_pvt.sync_change_request on change request id '||lv_change_request_id||' returned with status '||x_return_status
1602: );
1603: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1604:
1605: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1606: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1607: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1608: RAISE OKL_API.G_EXCEPTION_ERROR;
1609: END IF;

Line 1606: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1602: );
1603: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1604:
1605: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1606: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1607: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1608: RAISE OKL_API.G_EXCEPTION_ERROR;
1609: END IF;
1610: -- when the change request is synced up successfully, the status of the change request is COMPLETED and the status of the agreement

Line 1607: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1603: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1604:
1605: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1606: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1607: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1608: RAISE OKL_API.G_EXCEPTION_ERROR;
1609: END IF;
1610: -- when the change request is synced up successfully, the status of the change request is COMPLETED and the status of the agreement
1611: -- associated with the change request is set to ABANDONED.

Line 1608: RAISE OKL_API.G_EXCEPTION_ERROR;

1604:
1605: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1606: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1607: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1608: RAISE OKL_API.G_EXCEPTION_ERROR;
1609: END IF;
1610: -- when the change request is synced up successfully, the status of the change request is COMPLETED and the status of the agreement
1611: -- associated with the change request is set to ABANDONED.
1612: -- the OUT variable is assigned to COMPLETED so that this value can be utillized by the caller program or UI

Line 1629: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN

1625: l_module,
1626: 'okl_vp_cr_wf.raise_oa_event_approval on change request id '||lv_change_request_id||' returned with status '||x_return_status
1627: );
1628: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1629: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1630: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1631: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1632: RAISE OKL_API.G_EXCEPTION_ERROR;
1633: END IF;

Line 1630: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;

1626: 'okl_vp_cr_wf.raise_oa_event_approval on change request id '||lv_change_request_id||' returned with status '||x_return_status
1627: );
1628: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1629: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1630: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1631: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1632: RAISE OKL_API.G_EXCEPTION_ERROR;
1633: END IF;
1634:

Line 1631: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN

1627: );
1628: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1629: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1630: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1631: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1632: RAISE OKL_API.G_EXCEPTION_ERROR;
1633: END IF;
1634:
1635: -- copy the OUT variable as PENDING_APPROVAL

Line 1632: RAISE OKL_API.G_EXCEPTION_ERROR;

1628: END IF; -- end of NVL(l_debug_enabled,'N')='Y'
1629: IF(x_return_status = OKL_API.G_RET_STS_UNEXP_ERROR) THEN
1630: RAISE OKL_API.G_EXCEPTION_UNEXPECTED_ERROR;
1631: ELSIF (x_return_status = OKL_API.G_RET_STS_ERROR) THEN
1632: RAISE OKL_API.G_EXCEPTION_ERROR;
1633: END IF;
1634:
1635: -- copy the OUT variable as PENDING_APPROVAL
1636: x_status_code := G_PENDING_STS_CODE;

Line 1639: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);

1635: -- copy the OUT variable as PENDING_APPROVAL
1636: x_status_code := G_PENDING_STS_CODE;
1637: END IF; -- end of NVL(l_approval_process,'NONE')='NONE'
1638:
1639: OKL_API.END_ACTIVITY(x_msg_count => x_msg_count, x_msg_data => x_msg_data);
1640:
1641: IF(l_debug_enabled='Y') THEN
1642: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call submit_cr_for_approval');
1643: END IF;

Line 1646: WHEN OKL_API.G_EXCEPTION_ERROR THEN

1642: okl_debug_pub.log_debug(FND_LOG.LEVEL_PROCEDURE,l_module,'end debug OKLRVCRB.pls call submit_cr_for_approval');
1643: END IF;
1644:
1645: EXCEPTION
1646: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1647: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1648: p_api_name => l_api_name,
1649: p_pkg_name => G_PKG_NAME,
1650: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

Line 1647: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1643: END IF;
1644:
1645: EXCEPTION
1646: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1647: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1648: p_api_name => l_api_name,
1649: p_pkg_name => G_PKG_NAME,
1650: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1651: x_msg_count => x_msg_count,

Line 1650: p_exc_name => 'OKL_API.G_RET_STS_ERROR',

1646: WHEN OKL_API.G_EXCEPTION_ERROR THEN
1647: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1648: p_api_name => l_api_name,
1649: p_pkg_name => G_PKG_NAME,
1650: p_exc_name => 'OKL_API.G_RET_STS_ERROR',
1651: x_msg_count => x_msg_count,
1652: x_msg_data => x_msg_data,
1653: p_api_type => g_api_type);
1654:

Line 1655: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

1651: x_msg_count => x_msg_count,
1652: x_msg_data => x_msg_data,
1653: p_api_type => g_api_type);
1654:
1655: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1656: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1657: p_api_name => l_api_name,
1658: p_pkg_name => G_PKG_NAME,
1659: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

Line 1656: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1652: x_msg_data => x_msg_data,
1653: p_api_type => g_api_type);
1654:
1655: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1656: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1657: p_api_name => l_api_name,
1658: p_pkg_name => G_PKG_NAME,
1659: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1660: x_msg_count => x_msg_count,

Line 1659: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',

1655: WHEN OKL_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
1656: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1657: p_api_name => l_api_name,
1658: p_pkg_name => G_PKG_NAME,
1659: p_exc_name => 'OKL_API.G_RET_STS_UNEXP_ERROR',
1660: x_msg_count => x_msg_count,
1661: x_msg_data => x_msg_data,
1662: p_api_type => g_api_type);
1663:

Line 1665: x_return_status := OKL_API.HANDLE_EXCEPTIONS(

1661: x_msg_data => x_msg_data,
1662: p_api_type => g_api_type);
1663:
1664: WHEN OTHERS THEN
1665: x_return_status := OKL_API.HANDLE_EXCEPTIONS(
1666: p_api_name => l_api_name,
1667: p_pkg_name => G_PKG_NAME,
1668: p_exc_name => 'OTHERS',
1669: x_msg_count => x_msg_count,

Line 1697: IF(p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM)THEN

1693: WHERE id = cp_chr_id;
1694:
1695: lv_ageement_number okc_k_headers_b.contract_number%TYPE;
1696: BEGIN
1697: IF(p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM)THEN
1698: OPEN c_get_chreq_csr(cp_ch_req_id => p_change_request_id);
1699: FETCH c_get_chreq_csr INTO cv_chreq_rec;
1700: CLOSE c_get_chreq_csr;
1701:

Line 1725: END IF; -- end of p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM

1721: ELSIF(c_get_chr_num_csr%FOUND)THEN
1722: CLOSE c_get_chr_num_csr;
1723: END IF;
1724: END IF; -- end of G_ARGREEMENT_TYPE_CODE = cv_chreq_rec.change_type_code
1725: END IF; -- end of p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM
1726: RETURN lv_ageement_number;
1727: END get_assoc_agr_number;
1728:
1729: FUNCTION get_assoc_agr_id(p_change_request_id IN okl_vp_change_requests.id%TYPE) RETURN NUMBER IS

Line 1747: IF(p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM)THEN

1743: AND khr.crs_id = cp_ch_req_id;
1744:
1745: lv_chr_id okc_k_headers_b.id%TYPE;
1746: BEGIN
1747: IF(p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM)THEN
1748: OPEN c_get_chreq_csr(cp_ch_req_id => p_change_request_id);
1749: FETCH c_get_chreq_csr INTO cv_chreq_rec;
1750: CLOSE c_get_chreq_csr;
1751:

Line 1769: END IF; -- end of p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM

1765: ELSIF(c_get_chr_id_csr%FOUND)THEN
1766: CLOSE c_get_chr_id_csr;
1767: END IF;
1768: END IF; -- end of G_ARGREEMENT_TYPE_CODE = cv_chreq_rec.change_type_code
1769: END IF; -- end of p_change_request_id IS NOT NULL AND p_change_request_id <> OKL_API.G_MISS_NUM
1770: RETURN lv_chr_id;
1771: END get_assoc_agr_id;
1772: END okl_vp_change_request_pvt;