[Home] [Help]
PACKAGE BODY: APPS.OKL_SSC_CONTRACTS
Source
1 package body OKL_SSC_CONTRACTS as
2 /* $Header: OKLSSCTB.pls 115.2 2003/05/21 11:06:06 arajagop noship $ */
3
4
5 procedure accept_asset ( headerId in Number,
6 acceptance_date in Date )
7 IS
8
9 CURSOR acceptance_method IS
10 SELECT meaning from fnd_lookups
11 where lookup_type ='OKL_ACCEPTANCE_METHOD'
12 and lookup_code = 'SELF_SERVICE';
13
14 l_api_version NUMBER := 1.0;
15 l_return_status VARCHAR2(1);
16 l_msg_count NUMBER;
17 l_msg_data VARCHAR2(2000);
18 l_chrv_rec okl_okc_migration_pvt.chrv_rec_type;
19 l_khrv_rec okl_contract_pub.khrv_rec_type;
20 lx_chrv_rec okl_okc_migration_pvt.chrv_rec_type;
21 lx_khrv_rec okl_contract_pub.khrv_rec_type;
22 l_msg_index_out NUMBER;
23
24 error_accepting_asset EXCEPTION;
25
26 begin
27 l_chrv_rec.id := headerId;
28 l_khrv_rec.id := l_chrv_rec.id;
29 l_khrv_rec.accepted_date := acceptance_date;
30
31
32 l_khrv_rec.AMD_CODE := 'SELF_SERVICE';
33
34
35 OKL_CONTRACT_PUB.update_contract_header(
36 p_api_version => l_api_version,
37 p_init_msg_list => OKL_API.G_FALSE,
38 x_return_status => l_return_status,
39 x_msg_count => l_msg_count,
40 x_msg_data => l_msg_data,
41 p_restricted_update => OKL_API.G_FALSE,
42 p_chrv_rec => l_chrv_rec,
43 p_khrv_rec => l_khrv_rec,
44 p_edit_mode => 'N',
45 x_chrv_rec => lx_chrv_rec,
46 x_khrv_rec => lx_khrv_rec);
47
48 IF l_return_status <> 'S' THEN
49 RAISE error_accepting_asset;
50 END IF;
51
52 end accept_asset;
53
54 END OKL_SSC_CONTRACTS;