DBA Data[Home] [Help]

APPS.OZF_SD_REQUEST_PUB dependencies on OZF_UTILITY_PVT

Line 34: ozf_utility_pvt.debug_message(' Request Header Id :'||p_request_header_id );

30:
31: l_event_name := 'oracle.apps.ozf.sd.request.statuschange';
32:
33: IF G_DEBUG THEN
34: ozf_utility_pvt.debug_message(' Request Header Id :'||p_request_header_id );
35: END IF;
36:
37: wf_event.AddParameterToList(p_name => 'OZF_SDR_HEADER_ID',
38: p_value => p_request_header_id,

Line 50: ozf_utility_pvt.debug_message('Item Key is :'||l_item_key);

46: p_value => p_to_status,
47: p_parameterlist => l_parameter_list);
48:
49: IF G_DEBUG THEN
50: ozf_utility_pvt.debug_message('Item Key is :'||l_item_key);
51: END IF;
52:
53: wf_event.raise( p_event_name =>l_event_name,
54: p_event_key => l_item_key,

Line 61: ozf_utility_pvt.debug_message('Exception in raising business event');

57: EXCEPTION
58: WHEN OTHERS THEN
59: RAISE Fnd_Api.g_exc_error;
60: IF G_DEBUG THEN
61: ozf_utility_pvt.debug_message('Exception in raising business event');
62: END IF;
63:
64: END;
65:

Line 91: ozf_utility_pvt.debug_message(' Request Header Id :'||p_request_header_id );

87:
88: l_event_name := 'oracle.apps.ozf.sd.request.outbound';
89:
90: IF G_DEBUG THEN
91: ozf_utility_pvt.debug_message(' Request Header Id :'||p_request_header_id );
92: END IF;
93:
94: wf_event.AddParameterToList(p_name => 'ECX_MAP_CODE',
95: p_value => 'OZF_SD_REQ_OUT',

Line 147: ozf_utility_pvt.debug_message('Item Key is :'||l_item_key);

143: p_value => 3,
144: p_parameterlist => l_parameter_list);
145:
146: IF G_DEBUG THEN
147: ozf_utility_pvt.debug_message('Item Key is :'||l_item_key);
148: END IF;
149:
150: wf_event.raise( p_event_name =>l_event_name,
151: p_event_key => l_item_key,

Line 158: ozf_utility_pvt.debug_message('Exception in raising XML Gateway business event');

154: EXCEPTION
155: WHEN OTHERS THEN
156: RAISE Fnd_Api.g_exc_error;
157: IF G_DEBUG THEN
158: ozf_utility_pvt.debug_message('Exception in raising XML Gateway business event');
159: END IF;
160: END;
161:
162: ---------------------------------------------------------------------

Line 288: OZF_UTILITY_PVT.debug_message('Checking status transitions for External Request');

284: BEGIN
285: IF p_external_flag ='Y' THEN
286:
287: IF G_DEBUG THEN
288: OZF_UTILITY_PVT.debug_message('Checking status transitions for External Request');
289: END IF;
290:
291: IF p_owner_flag ='Y' THEN
292:

Line 298: OZF_UTILITY_PVT.debug_message('l_owner_count :'||l_owner_count);

294: FETCH c_external_transition INTO l_owner_count;
295: CLOSE c_external_transition;
296:
297: IF G_DEBUG THEN
298: OZF_UTILITY_PVT.debug_message('l_owner_count :'||l_owner_count);
299: END IF;
300: END IF;
301:
302: IF p_pm_flag ='Y' THEN

Line 309: OZF_UTILITY_PVT.debug_message('l_pm_count :'||l_pm_count);

305: FETCH c_external_transition INTO l_pm_count;
306: CLOSE c_external_transition;
307:
308: IF G_DEBUG THEN
309: OZF_UTILITY_PVT.debug_message('l_pm_count :'||l_pm_count);
310: END IF;
311: END IF;
312:
313: IF p_owner_flag ='Y' AND p_pm_flag ='Y' THEN

Line 328: OZF_UTILITY_PVT.debug_message('Checking status transitions for Internal Request');

324:
325: ELSIF p_internal_flag ='Y' THEN
326:
327: IF G_DEBUG THEN
328: OZF_UTILITY_PVT.debug_message('Checking status transitions for Internal Request');
329: END IF;
330:
331: IF p_owner_flag ='Y' THEN
332:

Line 338: OZF_UTILITY_PVT.debug_message('l_owner_count :'||l_owner_count);

334: FETCH c_internal_transition INTO l_owner_count;
335: CLOSE c_internal_transition;
336:
337: IF G_DEBUG THEN
338: OZF_UTILITY_PVT.debug_message('l_owner_count :'||l_owner_count);
339: END IF;
340: END IF;
341:
342: IF p_pm_flag ='Y' THEN

Line 349: OZF_UTILITY_PVT.debug_message('l_pm_count :'||l_pm_count);

345: FETCH c_internal_transition INTO l_pm_count;
346: CLOSE c_internal_transition;
347:
348: IF G_DEBUG THEN
349: OZF_UTILITY_PVT.debug_message('l_pm_count :'||l_pm_count);
350: END IF;
351: END IF;
352:
353: IF p_owner_flag ='Y' AND p_pm_flag ='Y' THEN

Line 544: OZF_UTILITY_PVT.debug_message('l_resource_id of the user :'||l_resource_id);

540: x_return_status := fnd_api.g_ret_sts_error;
541: RETURN;
542: END IF;
543: IF g_debug THEN
544: OZF_UTILITY_PVT.debug_message('l_resource_id of the user :'||l_resource_id);
545: END IF;
546: END IF;
547:
548: ELSE

Line 588: OZF_UTILITY_PVT.debug_message('Requestor NOT NULL');

584:
585: --// Requestor ID Validation (owner)
586: IF p_SDR_hdr_rec.requestor_id <> FND_API.g_miss_num AND p_SDR_hdr_rec.requestor_id IS NOT NULL THEN
587: IF G_DEBUG THEN
588: OZF_UTILITY_PVT.debug_message('Requestor NOT NULL');
589: END IF;
590: OPEN c_requestor_id(p_SDR_hdr_rec.requestor_id);
591: FETCH c_requestor_id INTO l_requestor_id;
592: CLOSE c_requestor_id;

Line 599: OZF_UTILITY_PVT.debug_message('Requestor id entered is invalid');

595: IF FND_MSG_PUB.check_msg_level(FND_MSG_PUB.g_msg_lvl_error) THEN
596: FND_MESSAGE.set_name('OZF', 'OZF_SD_INVALID_REQUESTOR_ID');
597: --//Requestor id entered is invalid
598: IF G_DEBUG THEN
599: OZF_UTILITY_PVT.debug_message('Requestor id entered is invalid');
600: END IF;
601: FND_MSG_PUB.add;
602: END IF;
603: x_return_status := fnd_api.g_ret_sts_error;

Line 609: OZF_UTILITY_PVT.debug_message('l_resource_id :'||l_resource_id);

605: END IF;
606: ELSE
607: p_SDR_hdr_rec.requestor_id := l_resource_id;
608: IF G_DEBUG THEN
609: OZF_UTILITY_PVT.debug_message('l_resource_id :'||l_resource_id);
610: END IF;
611: END IF;
612:
613: IF p_SDR_hdr_rec.accrual_type ='SUPPLIER' THEN

Line 759: OZF_UTILITY_PVT.debug_message('Validating Assignee Resource ID');

755: --//Validating Assignee Resource ID
756: l_system_status_code := get_system_status_code(p_SDR_hdr_rec.user_status_id);
757:
758: IF G_DEBUG THEN
759: OZF_UTILITY_PVT.debug_message('Validating Assignee Resource ID');
760: END IF;
761:
762: IF l_system_status_code <> 'DRAFT' THEN
763:

Line 765: OZF_UTILITY_PVT.debug_message('Assignee resource_id ID :'||p_SDR_hdr_rec.assignee_resource_id);

761:
762: IF l_system_status_code <> 'DRAFT' THEN
763:
764: IF G_DEBUG THEN
765: OZF_UTILITY_PVT.debug_message('Assignee resource_id ID :'||p_SDR_hdr_rec.assignee_resource_id);
766: END IF;
767:
768: IF p_SDR_hdr_rec.assignee_resource_id <> FND_API.g_miss_num AND p_SDR_hdr_rec.assignee_resource_id IS NOT NULL THEN
769:

Line 937: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

933: END IF;
934:
935: --Request Outcome
936: IF p_SDR_hdr_rec.request_outcome <> FND_API.g_miss_char AND p_SDR_hdr_rec.request_outcome IS NOT NULL THEN
937: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
938: p_lookup_table_name =>'OZF_LOOKUPS'
939: ,p_lookup_type =>'OZF_SD_REQUEST_OUTCOME'
940: ,p_lookup_code => p_SDR_hdr_rec.request_outcome);
941:

Line 1197: OZF_UTILITY_PVT.debug_message('c_master_org_id -->G_ITEM_ORG_ID: ' || G_ITEM_ORG_ID);

1193: FETCH c_master_org_id INTO G_ITEM_ORG_ID;
1194: CLOSE c_master_org_id;
1195:
1196: IF G_DEBUG THEN
1197: OZF_UTILITY_PVT.debug_message('c_master_org_id -->G_ITEM_ORG_ID: ' || G_ITEM_ORG_ID);
1198: END IF;
1199:
1200:
1201: FOR i IN p_SDR_lines_tbl.FIRST..p_SDR_lines_tbl.LAST LOOP

Line 1339: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

1335:
1336: --Product Context
1337: IF p_SDR_lines_tbl(i).product_context <> FND_API.g_miss_char AND p_SDR_lines_tbl(i).product_context IS NOT NULL THEN
1338:
1339: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
1340: p_lookup_table_name =>'OZF_LOOKUPS'
1341: ,p_lookup_type =>'OZF_SD_PRODUCT_CONTEXT'
1342: ,p_lookup_code => p_SDR_lines_tbl(i).product_context);
1343:

Line 1522: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

1518: END IF;
1519:
1520: --//Requested discount type
1521: IF p_SDR_lines_tbl(i).requested_discount_type <> FND_API.g_miss_char AND p_SDR_lines_tbl(i).requested_discount_type IS NOT NULL THEN
1522: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
1523: p_lookup_table_name =>'OZF_LOOKUPS'
1524: ,p_lookup_type =>'OZF_SD_REQUEST_DISTYPE'
1525: ,p_lookup_code => p_SDR_lines_tbl(i).requested_discount_type);
1526:

Line 1674: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

1670: p_SDR_lines_tbl(i).end_date := TRUNC(p_SDR_lines_tbl(i).end_date);
1671:
1672: --//Price Type
1673: IF p_SDR_lines_tbl(i).end_customer_price_type <> FND_API.g_miss_char AND p_SDR_lines_tbl(i).end_customer_price_type IS NOT NULL THEN
1674: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
1675: p_lookup_table_name =>'OZF_LOOKUPS'
1676: ,p_lookup_type =>'OZF_SD_PRICE_TYPE'
1677: ,p_lookup_code => p_SDR_lines_tbl(i).end_customer_price_type);
1678:

Line 1691: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

1687: END IF;
1688:
1689: --Tolerance Type
1690: IF p_SDR_lines_tbl(i).end_customer_tolerance_type <> FND_API.g_miss_char AND p_SDR_lines_tbl(i).end_customer_tolerance_type IS NOT NULL THEN
1691: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
1692: p_lookup_table_name =>'OZF_LOOKUPS'
1693: ,p_lookup_type =>'OZF_SD_TOLERANCE_TYPE'
1694: ,p_lookup_code => p_SDR_lines_tbl(i).end_customer_tolerance_type);
1695:

Line 1708: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

1704: END IF;
1705:
1706: --//Rejection Code
1707: IF p_SDR_lines_tbl(i).rejection_code <> FND_API.g_miss_char AND p_SDR_lines_tbl(i).rejection_code IS NOT NULL THEN
1708: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
1709: p_lookup_table_name =>'OZF_LOOKUPS'
1710: ,p_lookup_type =>'OZF_SD_REQ_LINE_REJECT_CODE'
1711: ,p_lookup_code => p_SDR_lines_tbl(i).rejection_code);
1712:

Line 1724: OZF_UTILITY_PVT.debug_message('Validate Product Lines Status Code :'||l_status_code);

1720: END IF;
1721: END IF;
1722: l_status_code := get_system_status_code(p_SDR_hdr_rec.user_status_id);
1723: IF G_DEBUG THEN
1724: OZF_UTILITY_PVT.debug_message('Validate Product Lines Status Code :'||l_status_code);
1725: END IF;
1726:
1727: IF l_status_code = 'SUPPLIER_APPROVED' THEN
1728: IF G_DEBUG THEN

Line 1729: OZF_UTILITY_PVT.debug_message('Validate Product Lines Status Code INSIDE');

1725: END IF;
1726:
1727: IF l_status_code = 'SUPPLIER_APPROVED' THEN
1728: IF G_DEBUG THEN
1729: OZF_UTILITY_PVT.debug_message('Validate Product Lines Status Code INSIDE');
1730: END IF;
1731:
1732: --//Approved discount type
1733: IF p_SDR_lines_tbl(i).approved_discount_type <> FND_API.g_miss_char AND p_SDR_lines_tbl(i).approved_discount_type IS NOT NULL THEN

Line 1734: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

1730: END IF;
1731:
1732: --//Approved discount type
1733: IF p_SDR_lines_tbl(i).approved_discount_type <> FND_API.g_miss_char AND p_SDR_lines_tbl(i).approved_discount_type IS NOT NULL THEN
1734: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
1735: p_lookup_table_name =>'OZF_LOOKUPS'
1736: ,p_lookup_type =>'OZF_SP_REQUEST_DISTYPE'
1737: ,p_lookup_code => p_SDR_lines_tbl(i).approved_discount_type);
1738:

Line 1993: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

1989:
1990: --//Customer usage code Check
1991: IF p_SDR_cust_tbl(j).cust_usage_code <> FND_API.g_miss_char AND p_SDR_cust_tbl(j).cust_usage_code IS NOT NULL THEN
1992:
1993: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
1994: p_lookup_table_name =>'OZF_LOOKUPS'
1995: ,p_lookup_type =>'OZF_SD_CUSTOMER_TYPE'
1996: ,p_lookup_code => p_SDR_cust_tbl(j).cust_usage_code);
1997:

Line 2160: OZF_UTILITY_PVT.debug_message('Inside INSERT HEADER RECORD Procedure ');

2156:
2157: x_return_status := FND_API.G_RET_STS_SUCCESS;
2158:
2159: IF G_DEBUG THEN
2160: OZF_UTILITY_PVT.debug_message('Inside INSERT HEADER RECORD Procedure ');
2161: END IF;
2162:
2163: IF l_SDR_hdr_rec.request_basis IS NULL THEN
2164: l_SDR_hdr_rec.request_basis := FND_PROFILE.value('OZF_SD_REQUEST_BASED');

Line 2180: OZF_UTILITY_PVT.debug_message('Request Number : '||l_SDR_hdr_rec.request_number);

2176: CLOSE c_code_prefix;
2177:
2178: l_SDR_hdr_rec.request_number :=l_code_prefix||TO_CHAR(l_req_hdr_seq);
2179: IF G_DEBUG THEN
2180: OZF_UTILITY_PVT.debug_message('Request Number : '||l_SDR_hdr_rec.request_number);
2181: END IF;
2182:
2183: END IF;
2184:

Line 2189: OZF_UTILITY_PVT.debug_message('Root Request Header ID :'||l_root_request_header_id);

2185: IF l_SDR_hdr_rec.request_header_id IS NOT NULL THEN
2186: --//Set the root request header id for Copy
2187: l_root_request_header_id :=l_SDR_hdr_rec.request_header_id;
2188: IF G_DEBUG THEN
2189: OZF_UTILITY_PVT.debug_message('Root Request Header ID :'||l_root_request_header_id);
2190: END IF;
2191: END IF;
2192:
2193: OZF_SD_REQUEST_HEADER_PKG.Insert_Row(

Line 2390: OZF_UTILITY_PVT.debug_message('populate_product_lines - Create Mode');

2386:
2387: IF p_SDR_lines_tbl(p).request_line_id = FND_API.g_miss_num OR p_SDR_lines_tbl(p).request_line_id IS NULL THEN
2388:
2389: IF G_DEBUG THEN
2390: OZF_UTILITY_PVT.debug_message('populate_product_lines - Create Mode');
2391: OZF_UTILITY_PVT.debug_message('Count :'||p_SDR_lines_tbl.count);
2392: END IF;
2393:
2394: OPEN c_reqest_lines_seq;

Line 2391: OZF_UTILITY_PVT.debug_message('Count :'||p_SDR_lines_tbl.count);

2387: IF p_SDR_lines_tbl(p).request_line_id = FND_API.g_miss_num OR p_SDR_lines_tbl(p).request_line_id IS NULL THEN
2388:
2389: IF G_DEBUG THEN
2390: OZF_UTILITY_PVT.debug_message('populate_product_lines - Create Mode');
2391: OZF_UTILITY_PVT.debug_message('Count :'||p_SDR_lines_tbl.count);
2392: END IF;
2393:
2394: OPEN c_reqest_lines_seq;
2395: FETCH c_reqest_lines_seq INTO l_req_line_seq;

Line 2579: OZF_UTILITY_PVT.debug_message('Inside populate_customer_details');

2575: -- Initialize API return status to SUCCESS
2576: x_return_status := FND_API.G_RET_STS_SUCCESS;
2577:
2578: IF G_DEBUG THEN
2579: OZF_UTILITY_PVT.debug_message('Inside populate_customer_details');
2580: END IF;
2581:
2582: FOR c IN p_SDR_cust_tbl.FIRST..p_SDR_cust_tbl.LAST LOOP
2583:

Line 2598: OZF_UTILITY_PVT.debug_message('Duplicate Customer/End Customer ');

2594:
2595: IF l_cust_count <> 0 THEN
2596:
2597: IF G_DEBUG THEN
2598: OZF_UTILITY_PVT.debug_message('Duplicate Customer/End Customer ');
2599: OZF_UTILITY_PVT.debug_message('Cust Usage Code :'||p_SDR_cust_tbl(c).cust_usage_code);
2600: OZF_UTILITY_PVT.debug_message('Party Id :'||p_SDR_cust_tbl(c).party_id);
2601: OZF_UTILITY_PVT.debug_message('Cust Account id :'||p_SDR_cust_tbl(c).cust_account_id);
2602: OZF_UTILITY_PVT.debug_message('End Customer Flag :'||p_SDR_cust_tbl(c).end_customer_flag);

Line 2599: OZF_UTILITY_PVT.debug_message('Cust Usage Code :'||p_SDR_cust_tbl(c).cust_usage_code);

2595: IF l_cust_count <> 0 THEN
2596:
2597: IF G_DEBUG THEN
2598: OZF_UTILITY_PVT.debug_message('Duplicate Customer/End Customer ');
2599: OZF_UTILITY_PVT.debug_message('Cust Usage Code :'||p_SDR_cust_tbl(c).cust_usage_code);
2600: OZF_UTILITY_PVT.debug_message('Party Id :'||p_SDR_cust_tbl(c).party_id);
2601: OZF_UTILITY_PVT.debug_message('Cust Account id :'||p_SDR_cust_tbl(c).cust_account_id);
2602: OZF_UTILITY_PVT.debug_message('End Customer Flag :'||p_SDR_cust_tbl(c).end_customer_flag);
2603: END IF;

Line 2600: OZF_UTILITY_PVT.debug_message('Party Id :'||p_SDR_cust_tbl(c).party_id);

2596:
2597: IF G_DEBUG THEN
2598: OZF_UTILITY_PVT.debug_message('Duplicate Customer/End Customer ');
2599: OZF_UTILITY_PVT.debug_message('Cust Usage Code :'||p_SDR_cust_tbl(c).cust_usage_code);
2600: OZF_UTILITY_PVT.debug_message('Party Id :'||p_SDR_cust_tbl(c).party_id);
2601: OZF_UTILITY_PVT.debug_message('Cust Account id :'||p_SDR_cust_tbl(c).cust_account_id);
2602: OZF_UTILITY_PVT.debug_message('End Customer Flag :'||p_SDR_cust_tbl(c).end_customer_flag);
2603: END IF;
2604:

Line 2601: OZF_UTILITY_PVT.debug_message('Cust Account id :'||p_SDR_cust_tbl(c).cust_account_id);

2597: IF G_DEBUG THEN
2598: OZF_UTILITY_PVT.debug_message('Duplicate Customer/End Customer ');
2599: OZF_UTILITY_PVT.debug_message('Cust Usage Code :'||p_SDR_cust_tbl(c).cust_usage_code);
2600: OZF_UTILITY_PVT.debug_message('Party Id :'||p_SDR_cust_tbl(c).party_id);
2601: OZF_UTILITY_PVT.debug_message('Cust Account id :'||p_SDR_cust_tbl(c).cust_account_id);
2602: OZF_UTILITY_PVT.debug_message('End Customer Flag :'||p_SDR_cust_tbl(c).end_customer_flag);
2603: END IF;
2604:
2605: IF FND_MSG_PUB.check_msg_level(FND_MSG_PUB.g_msg_lvl_error) THEN

Line 2602: OZF_UTILITY_PVT.debug_message('End Customer Flag :'||p_SDR_cust_tbl(c).end_customer_flag);

2598: OZF_UTILITY_PVT.debug_message('Duplicate Customer/End Customer ');
2599: OZF_UTILITY_PVT.debug_message('Cust Usage Code :'||p_SDR_cust_tbl(c).cust_usage_code);
2600: OZF_UTILITY_PVT.debug_message('Party Id :'||p_SDR_cust_tbl(c).party_id);
2601: OZF_UTILITY_PVT.debug_message('Cust Account id :'||p_SDR_cust_tbl(c).cust_account_id);
2602: OZF_UTILITY_PVT.debug_message('End Customer Flag :'||p_SDR_cust_tbl(c).end_customer_flag);
2603: END IF;
2604:
2605: IF FND_MSG_PUB.check_msg_level(FND_MSG_PUB.g_msg_lvl_error) THEN
2606: IF p_SDR_cust_tbl(c).end_customer_flag = 'Y' THEN

Line 2734: OZF_UTILITY_PVT.debug_message('Invokes Update Row');

2730: x_return_status := FND_API.G_RET_STS_SUCCESS;
2731:
2732: --//Update process
2733: IF G_DEBUG THEN
2734: OZF_UTILITY_PVT.debug_message('Invokes Update Row');
2735: END IF;
2736:
2737: OPEN c_qp_list_header_id(p_SDR_hdr_rec.request_header_id);
2738: FETCH c_qp_list_header_id INTO l_qp_list_header_id;

Line 2816: OZF_UTILITY_PVT.debug_message('End update_header_record');

2812: ,p_request_basis =>p_SDR_hdr_rec.request_basis
2813: ,p_supplier_contact_name =>p_SDR_hdr_rec.supplier_contact_name); --//Bugfix : 7822442
2814:
2815: IF G_DEBUG THEN
2816: OZF_UTILITY_PVT.debug_message('End update_header_record');
2817: END IF;
2818:
2819: EXCEPTION
2820: WHEN FND_API.G_EXC_ERROR THEN

Line 2824: OZF_UTILITY_PVT.debug_message(SQLERRM);

2820: WHEN FND_API.G_EXC_ERROR THEN
2821: x_return_status := FND_API.G_RET_STS_ERROR;
2822: WHEN OTHERS THEN
2823: IF G_DEBUG THEN
2824: OZF_UTILITY_PVT.debug_message(SQLERRM);
2825: END IF;
2826: x_return_status := FND_API.g_ret_sts_unexp_error;
2827: IF FND_MSG_PUB.check_msg_level(FND_MSG_PUB.g_msg_lvl_error) THEN
2828: FND_MESSAGE.set_name('OZF', 'OZF_TABLE_HANDLER_ERROR');

Line 2903: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' PUB start');

2899: FND_MSG_PUB.initialize;
2900: END IF;
2901: -- Debug Message
2902: IF G_DEBUG THEN
2903: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' PUB start');
2904: END IF;
2905: -- Initialize API return status to SUCCESS
2906: x_return_status := FND_API.G_RET_STS_SUCCESS;
2907:

Line 2915: l_lookup_check :=OZF_UTILITY_PVT.check_lookup_exists(

2911:
2912: --//Accrual type Validation
2913: IF l_SDR_rec.accrual_type <> FND_API.g_miss_char AND l_SDR_rec.accrual_type IS NOT NULL THEN
2914:
2915: l_lookup_check :=OZF_UTILITY_PVT.check_lookup_exists(
2916: p_lookup_table_name =>'OZF_LOOKUPS'
2917: ,p_lookup_type =>'OZF_SDR_ACCRUAL_TYPE'
2918: ,p_lookup_code => l_SDR_rec.accrual_type);
2919:

Line 2979: OZF_UTILITY_PVT.debug_message('User Status id '||l_SDR_rec.user_status_id);

2975: END IF;
2976: END IF;
2977:
2978: IF G_DEBUG THEN
2979: OZF_UTILITY_PVT.debug_message('User Status id '||l_SDR_rec.user_status_id);
2980: OZF_UTILITY_PVT.debug_message('l_system_status_code :'||l_system_status_code);
2981: END IF;
2982:
2983: IF (l_system_status_code <> 'DRAFT') AND (p_SDR_lines_tbl.count = 0) THEN

Line 2980: OZF_UTILITY_PVT.debug_message('l_system_status_code :'||l_system_status_code);

2976: END IF;
2977:
2978: IF G_DEBUG THEN
2979: OZF_UTILITY_PVT.debug_message('User Status id '||l_SDR_rec.user_status_id);
2980: OZF_UTILITY_PVT.debug_message('l_system_status_code :'||l_system_status_code);
2981: END IF;
2982:
2983: IF (l_system_status_code <> 'DRAFT') AND (p_SDR_lines_tbl.count = 0) THEN
2984: IF FND_MSG_PUB.check_msg_level(FND_MSG_PUB.g_msg_lvl_error) THEN

Line 3046: OZF_UTILITY_PVT.debug_message('Validate Header Record');

3042: RETURN;
3043: END IF;
3044:
3045: IF G_DEBUG THEN
3046: OZF_UTILITY_PVT.debug_message('Validate Header Record');
3047: END IF;
3048: --//Validate Header Record
3049: validate_header_items(p_SDR_hdr_rec => l_SDR_rec
3050: ,p_mode =>'CREATE'

Line 3061: OZF_UTILITY_PVT.debug_message('Validate Product Lines');

3057: END IF;
3058:
3059: --//Validate Product Lines
3060: IF G_DEBUG THEN
3061: OZF_UTILITY_PVT.debug_message('Validate Product Lines');
3062: END IF;
3063: IF p_SDR_lines_tbl.count > 0 THEN
3064: validate_product_lines(p_SDR_lines_tbl => l_SDR_lines_tbl
3065: ,p_SDR_hdr_rec => l_SDR_rec

Line 3078: OZF_UTILITY_PVT.debug_message('Validate Customer Records');

3074: l_line_rec_flag :='Y';
3075: END IF;
3076:
3077: IF G_DEBUG THEN
3078: OZF_UTILITY_PVT.debug_message('Validate Customer Records');
3079: END IF;
3080: --//Validate Customer Records
3081: IF ((p_SDR_cust_tbl.count > 0) AND (l_request_type = 'BID' ))THEN
3082: validate_customer_items(p_SDR_cust_tbl => l_SDR_cust_tbl

Line 3095: OZF_UTILITY_PVT.debug_message('Inserting data into SD Request Header table');

3091: l_cust_rec_flag :='Y';
3092: END IF;
3093:
3094: IF G_DEBUG THEN
3095: OZF_UTILITY_PVT.debug_message('Inserting data into SD Request Header table');
3096: END IF;
3097: --// Insert into Header Table
3098: Insert_header_record(
3099: p_SDR_hdr_rec => l_SDR_rec

Line 3111: OZF_UTILITY_PVT.debug_message('Populating Translation table');

3107: RAISE fnd_api.g_exc_error;
3108: END IF;
3109:
3110: IF G_DEBUG THEN
3111: OZF_UTILITY_PVT.debug_message('Populating Translation table');
3112: END IF;
3113: --//Populate Transilation table
3114: populate_translation_record(
3115: p_request_header_id =>x_request_header_id

Line 3128: OZF_UTILITY_PVT.debug_message('Populate SD Access table for Requestor');

3124: RAISE fnd_api.g_exc_error;
3125: END IF;
3126:
3127: IF G_DEBUG THEN
3128: OZF_UTILITY_PVT.debug_message('Populate SD Access table for Requestor');
3129: OZF_UTILITY_PVT.debug_message('p_resource_id =>'||l_SDR_rec.requestor_id);
3130: END IF;
3131: --Populate SD Access table
3132:

Line 3129: OZF_UTILITY_PVT.debug_message('p_resource_id =>'||l_SDR_rec.requestor_id);

3125: END IF;
3126:
3127: IF G_DEBUG THEN
3128: OZF_UTILITY_PVT.debug_message('Populate SD Access table for Requestor');
3129: OZF_UTILITY_PVT.debug_message('p_resource_id =>'||l_SDR_rec.requestor_id);
3130: END IF;
3131: --Populate SD Access table
3132:
3133: OZF_APPROVAL_PVT.Add_SD_Access(

Line 3158: OZF_UTILITY_PVT.debug_message('Populate SD Access table for Assignee');

3154: END IF;
3155:
3156: IF l_SDR_rec.assignee_resource_id IS NOT NULL THEN
3157: IF G_DEBUG THEN
3158: OZF_UTILITY_PVT.debug_message('Populate SD Access table for Assignee');
3159: OZF_UTILITY_PVT.debug_message('p_resource_id =>'||l_SDR_rec.assignee_resource_id);
3160: END IF;
3161: --//Assignee Entry
3162: OZF_APPROVAL_PVT.Add_SD_Access(

Line 3159: OZF_UTILITY_PVT.debug_message('p_resource_id =>'||l_SDR_rec.assignee_resource_id);

3155:
3156: IF l_SDR_rec.assignee_resource_id IS NOT NULL THEN
3157: IF G_DEBUG THEN
3158: OZF_UTILITY_PVT.debug_message('Populate SD Access table for Assignee');
3159: OZF_UTILITY_PVT.debug_message('p_resource_id =>'||l_SDR_rec.assignee_resource_id);
3160: END IF;
3161: --//Assignee Entry
3162: OZF_APPROVAL_PVT.Add_SD_Access(
3163: p_api_version =>p_api_version_number

Line 3189: OZF_UTILITY_PVT.debug_message('Populate Product Lines table');

3185:
3186:
3187: IF l_line_rec_flag ='Y' THEN
3188: IF G_DEBUG THEN
3189: OZF_UTILITY_PVT.debug_message('Populate Product Lines table');
3190: END IF;
3191: --//Populate Product Lines table
3192: populate_product_lines(
3193: p_request_header_id => x_request_header_id

Line 3207: OZF_UTILITY_PVT.debug_message('Populate Customer Details table');

3203:
3204: IF ((l_cust_rec_flag ='Y') AND (l_request_type = 'BID' ))THEN
3205:
3206: IF G_DEBUG THEN
3207: OZF_UTILITY_PVT.debug_message('Populate Customer Details table');
3208: END IF;
3209: --//Populate Customer Details table
3210: populate_customer_details(
3211: p_request_header_id => x_request_header_id

Line 3224: OZF_UTILITY_PVT.debug_message('Request Header Id: '||x_request_header_id);

3220: END IF;
3221: --========================================================================
3222: --// Commit the process
3223: IF G_DEBUG THEN
3224: OZF_UTILITY_PVT.debug_message('Request Header Id: '||x_request_header_id);
3225: OZF_UTILITY_PVT.debug_message('Public API: '|| l_api_name||' End');
3226: END IF;
3227: IF FND_API.to_Boolean( p_commit )
3228: THEN

Line 3225: OZF_UTILITY_PVT.debug_message('Public API: '|| l_api_name||' End');

3221: --========================================================================
3222: --// Commit the process
3223: IF G_DEBUG THEN
3224: OZF_UTILITY_PVT.debug_message('Request Header Id: '||x_request_header_id);
3225: OZF_UTILITY_PVT.debug_message('Public API: '|| l_api_name||' End');
3226: END IF;
3227: IF FND_API.to_Boolean( p_commit )
3228: THEN
3229: COMMIT WORK;

Line 3458: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' PUB start');

3454: FND_MSG_PUB.initialize;
3455: END IF;
3456: -- Debug Message
3457: IF G_DEBUG THEN
3458: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' PUB start');
3459: END IF;
3460: -- Initialize API return status to SUCCESS
3461: x_return_status := FND_API.G_RET_STS_SUCCESS;
3462: --==============================================================================

Line 3489: OZF_UTILITY_PVT.debug_message('G_REQUEST_HEADER_ID: ' ||G_REQUEST_HEADER_ID);

3485: END IF;
3486: --//Set the request Header ID to Global var
3487: G_REQUEST_HEADER_ID :=l_request_header_id;
3488: IF G_DEBUG THEN
3489: OZF_UTILITY_PVT.debug_message('G_REQUEST_HEADER_ID: ' ||G_REQUEST_HEADER_ID);
3490: END IF;
3491:
3492: --//Request Number Validation
3493: IF l_new_sdr_hdr_rec.request_number <> FND_API.g_miss_char AND l_new_sdr_hdr_rec.request_number IS NOT NULL THEN

Line 3574: OZF_UTILITY_PVT.debug_message('Validating User');

3570: FETCH c_old_sdr_tl INTO l_old_sdr_hdr_rec.request_description;
3571: CLOSE c_old_sdr_tl;
3572:
3573: IF G_DEBUG THEN
3574: OZF_UTILITY_PVT.debug_message('Validating User');
3575: END IF;
3576: --//User Check
3577: IF l_new_sdr_hdr_rec.user_id <> FND_API.g_miss_num AND l_new_sdr_hdr_rec.user_id IS NOT NULL THEN
3578: OPEN c_user(l_new_sdr_hdr_rec.user_id);

Line 3625: OZF_UTILITY_PVT.debug_message('SD Access Check');

3621: l_admin_flag :='Y';
3622: END IF;
3623:
3624: IF G_DEBUG THEN
3625: OZF_UTILITY_PVT.debug_message('SD Access Check');
3626: OZF_UTILITY_PVT.debug_message('Request Header ID :'||l_new_sdr_hdr_rec.request_header_id);
3627: OZF_UTILITY_PVT.debug_message('User id :'||l_new_sdr_hdr_rec.user_id);
3628: END IF;
3629: OPEN c_sd_access(l_new_sdr_hdr_rec.request_header_id

Line 3626: OZF_UTILITY_PVT.debug_message('Request Header ID :'||l_new_sdr_hdr_rec.request_header_id);

3622: END IF;
3623:
3624: IF G_DEBUG THEN
3625: OZF_UTILITY_PVT.debug_message('SD Access Check');
3626: OZF_UTILITY_PVT.debug_message('Request Header ID :'||l_new_sdr_hdr_rec.request_header_id);
3627: OZF_UTILITY_PVT.debug_message('User id :'||l_new_sdr_hdr_rec.user_id);
3628: END IF;
3629: OPEN c_sd_access(l_new_sdr_hdr_rec.request_header_id
3630: ,l_new_sdr_hdr_rec.user_id);

Line 3627: OZF_UTILITY_PVT.debug_message('User id :'||l_new_sdr_hdr_rec.user_id);

3623:
3624: IF G_DEBUG THEN
3625: OZF_UTILITY_PVT.debug_message('SD Access Check');
3626: OZF_UTILITY_PVT.debug_message('Request Header ID :'||l_new_sdr_hdr_rec.request_header_id);
3627: OZF_UTILITY_PVT.debug_message('User id :'||l_new_sdr_hdr_rec.user_id);
3628: END IF;
3629: OPEN c_sd_access(l_new_sdr_hdr_rec.request_header_id
3630: ,l_new_sdr_hdr_rec.user_id);
3631:

Line 3640: OZF_UTILITY_PVT.debug_message('Owner Flag :'||l_owner_flag);

3636: l_approver_flag :='Y';
3637: END IF;
3638:
3639: IF G_DEBUG THEN
3640: OZF_UTILITY_PVT.debug_message('Owner Flag :'||l_owner_flag);
3641: OZF_UTILITY_PVT.debug_message('Approver Flag :'||l_approver_flag);
3642: OZF_UTILITY_PVT.debug_message('Admin Flag :'||l_admin_flag);
3643: END IF;
3644:

Line 3641: OZF_UTILITY_PVT.debug_message('Approver Flag :'||l_approver_flag);

3637: END IF;
3638:
3639: IF G_DEBUG THEN
3640: OZF_UTILITY_PVT.debug_message('Owner Flag :'||l_owner_flag);
3641: OZF_UTILITY_PVT.debug_message('Approver Flag :'||l_approver_flag);
3642: OZF_UTILITY_PVT.debug_message('Admin Flag :'||l_admin_flag);
3643: END IF;
3644:
3645: --//Access Permission check

Line 3642: OZF_UTILITY_PVT.debug_message('Admin Flag :'||l_admin_flag);

3638:
3639: IF G_DEBUG THEN
3640: OZF_UTILITY_PVT.debug_message('Owner Flag :'||l_owner_flag);
3641: OZF_UTILITY_PVT.debug_message('Approver Flag :'||l_approver_flag);
3642: OZF_UTILITY_PVT.debug_message('Admin Flag :'||l_admin_flag);
3643: END IF;
3644:
3645: --//Access Permission check
3646: IF ((l_owner_flag IS NULL)

Line 3669: OZF_UTILITY_PVT.debug_message('Internal Flag :'||l_internal_flag);

3665: l_external_flag := 'Y';
3666: END IF;
3667:
3668: IF G_DEBUG THEN
3669: OZF_UTILITY_PVT.debug_message('Internal Flag :'||l_internal_flag);
3670: OZF_UTILITY_PVT.debug_message('External Flag :'||l_external_flag);
3671:
3672: END IF;
3673:

Line 3670: OZF_UTILITY_PVT.debug_message('External Flag :'||l_external_flag);

3666: END IF;
3667:
3668: IF G_DEBUG THEN
3669: OZF_UTILITY_PVT.debug_message('Internal Flag :'||l_internal_flag);
3670: OZF_UTILITY_PVT.debug_message('External Flag :'||l_external_flag);
3671:
3672: END IF;
3673:
3674: l_old_user_status_id :=NVL(l_old_sdr_hdr_rec.user_status_id,0);

Line 3687: OZF_UTILITY_PVT.debug_message('Checking the Status transition ');

3683: l_new_status_code := l_old_status_code;
3684: END IF;
3685:
3686: IF G_DEBUG THEN
3687: OZF_UTILITY_PVT.debug_message('Checking the Status transition ');
3688: OZF_UTILITY_PVT.debug_message('Old Status Code :'||l_old_status_code);
3689: OZF_UTILITY_PVT.debug_message('New Status Code :'||l_new_status_code);
3690: OZF_UTILITY_PVT.debug_message('Old Status Id :'||l_old_user_status_id);
3691: OZF_UTILITY_PVT.debug_message('New Status Id :'||l_new_user_status_id);

Line 3688: OZF_UTILITY_PVT.debug_message('Old Status Code :'||l_old_status_code);

3684: END IF;
3685:
3686: IF G_DEBUG THEN
3687: OZF_UTILITY_PVT.debug_message('Checking the Status transition ');
3688: OZF_UTILITY_PVT.debug_message('Old Status Code :'||l_old_status_code);
3689: OZF_UTILITY_PVT.debug_message('New Status Code :'||l_new_status_code);
3690: OZF_UTILITY_PVT.debug_message('Old Status Id :'||l_old_user_status_id);
3691: OZF_UTILITY_PVT.debug_message('New Status Id :'||l_new_user_status_id);
3692: END IF;

Line 3689: OZF_UTILITY_PVT.debug_message('New Status Code :'||l_new_status_code);

3685:
3686: IF G_DEBUG THEN
3687: OZF_UTILITY_PVT.debug_message('Checking the Status transition ');
3688: OZF_UTILITY_PVT.debug_message('Old Status Code :'||l_old_status_code);
3689: OZF_UTILITY_PVT.debug_message('New Status Code :'||l_new_status_code);
3690: OZF_UTILITY_PVT.debug_message('Old Status Id :'||l_old_user_status_id);
3691: OZF_UTILITY_PVT.debug_message('New Status Id :'||l_new_user_status_id);
3692: END IF;
3693:

Line 3690: OZF_UTILITY_PVT.debug_message('Old Status Id :'||l_old_user_status_id);

3686: IF G_DEBUG THEN
3687: OZF_UTILITY_PVT.debug_message('Checking the Status transition ');
3688: OZF_UTILITY_PVT.debug_message('Old Status Code :'||l_old_status_code);
3689: OZF_UTILITY_PVT.debug_message('New Status Code :'||l_new_status_code);
3690: OZF_UTILITY_PVT.debug_message('Old Status Id :'||l_old_user_status_id);
3691: OZF_UTILITY_PVT.debug_message('New Status Id :'||l_new_user_status_id);
3692: END IF;
3693:
3694: IF l_old_status_code <> l_new_status_code THEN

Line 3691: OZF_UTILITY_PVT.debug_message('New Status Id :'||l_new_user_status_id);

3687: OZF_UTILITY_PVT.debug_message('Checking the Status transition ');
3688: OZF_UTILITY_PVT.debug_message('Old Status Code :'||l_old_status_code);
3689: OZF_UTILITY_PVT.debug_message('New Status Code :'||l_new_status_code);
3690: OZF_UTILITY_PVT.debug_message('Old Status Id :'||l_old_user_status_id);
3691: OZF_UTILITY_PVT.debug_message('New Status Id :'||l_new_user_status_id);
3692: END IF;
3693:
3694: IF l_old_status_code <> l_new_status_code THEN
3695: l_is_stat_trns_allowed := check_status_transition(

Line 3742: OZF_UTILITY_PVT.debug_message('l_old_status_code :'||l_old_status_code);

3738: (l_new_sdr_hdr_rec.supplier_contact_phone_number,l_old_sdr_hdr_rec.supplier_contact_phone_number);
3739: END IF;
3740:
3741: IF G_DEBUG THEN
3742: OZF_UTILITY_PVT.debug_message('l_old_status_code :'||l_old_status_code);
3743: END IF;
3744:
3745: --//Statuswise transitions
3746: IF l_old_status_code ='DRAFT' THEN

Line 3828: OZF_UTILITY_PVT.debug_message('l_new_sdr_hdr_rec.request_number '||l_new_sdr_hdr_rec.request_number);

3824: l_old_sdr_hdr_rec.request_description :=NVL(l_new_sdr_hdr_rec.request_description,l_old_sdr_hdr_rec.request_description);
3825: END IF;
3826:
3827: IF (l_approver_flag ='Y') OR (l_admin_flag='Y') THEN
3828: OZF_UTILITY_PVT.debug_message('l_new_sdr_hdr_rec.request_number '||l_new_sdr_hdr_rec.request_number);
3829:
3830: l_old_sdr_hdr_rec.request_number :=NVL(l_new_sdr_hdr_rec.request_number,l_old_sdr_hdr_rec.request_number);
3831: l_old_sdr_hdr_rec.org_id :=NVL(l_new_sdr_hdr_rec.org_id,l_old_sdr_hdr_rec.org_id);
3832: l_old_sdr_hdr_rec.supplier_id :=NVL(l_new_sdr_hdr_rec.supplier_id,l_old_sdr_hdr_rec.supplier_id);

Line 3970: OZF_UTILITY_PVT.debug_message('End of Statuswise Data set');

3966: END IF;
3967: END IF;
3968:
3969: IF G_DEBUG THEN
3970: OZF_UTILITY_PVT.debug_message('End of Statuswise Data set');
3971: END IF;
3972: --//Set the user Id
3973: l_old_sdr_hdr_rec.user_id := l_new_sdr_hdr_rec.user_id;
3974:

Line 3978: OZF_UTILITY_PVT.debug_message('Admin Actions ');

3974:
3975: --//Admin Actions
3976: IF l_admin_flag ='Y' THEN
3977: IF G_DEBUG THEN
3978: OZF_UTILITY_PVT.debug_message('Admin Actions ');
3979: END IF;
3980:
3981: IF (l_new_sdr_hdr_rec.requestor_id IS NOT NULL)
3982: AND (NVL(l_old_sdr_hdr_rec.requestor_id,0) <> NVL(l_new_sdr_hdr_rec.requestor_id,0)) THEN

Line 3985: OZF_UTILITY_PVT.debug_message('Admin is updating the Owner ');

3981: IF (l_new_sdr_hdr_rec.requestor_id IS NOT NULL)
3982: AND (NVL(l_old_sdr_hdr_rec.requestor_id,0) <> NVL(l_new_sdr_hdr_rec.requestor_id,0)) THEN
3983: --//Admin is updating the Owner
3984: IF G_DEBUG THEN
3985: OZF_UTILITY_PVT.debug_message('Admin is updating the Owner ');
3986: END IF;
3987:
3988: OZF_APPROVAL_PVT.Add_SD_Access(
3989: p_api_version =>p_api_version_number

Line 4017: OZF_UTILITY_PVT.debug_message('Admin is updating the Assignee ');

4013: IF ((l_new_sdr_hdr_rec.assignee_resource_id IS NOT NULL)
4014: AND NVL(l_old_sdr_hdr_rec.assignee_resource_id,0) <> NVL(l_new_sdr_hdr_rec.assignee_resource_id,0)) THEN
4015: --//Admin is updating the Assignee
4016: IF g_debug THEN
4017: OZF_UTILITY_PVT.debug_message('Admin is updating the Assignee ');
4018: END IF;
4019:
4020: OZF_APPROVAL_PVT.Add_SD_Access(
4021: p_api_version =>p_api_version_number

Line 4050: OZF_UTILITY_PVT.debug_message('Validate Header Records');

4046: l_old_sdr_hdr_rec.assignee_resource_id :=NVL(l_new_sdr_hdr_rec.assignee_resource_id,l_old_sdr_hdr_rec.assignee_resource_id);
4047: END IF;
4048:
4049: IF G_DEBUG THEN
4050: OZF_UTILITY_PVT.debug_message('Validate Header Records');
4051: END IF;
4052: --//Validate Header Record
4053: validate_header_items(p_SDR_hdr_rec => l_old_sdr_hdr_rec
4054: ,p_mode =>'UPDATE'

Line 4065: OZF_UTILITY_PVT.debug_message('Proc Lines & Customer details Validation');

4061: END IF;
4062:
4063: --//Proc Lines & Customer details Validation
4064: IF G_DEBUG THEN
4065: OZF_UTILITY_PVT.debug_message('Proc Lines & Customer details Validation');
4066: END IF;
4067:
4068: IF l_old_status_code ='DRAFT' AND (l_owner_flag ='Y' OR l_admin_flag ='Y') THEN
4069: IF G_DEBUG THEN

Line 4070: OZF_UTILITY_PVT.debug_message('Owner can update Product Lines & Customer Details');

4066: END IF;
4067:
4068: IF l_old_status_code ='DRAFT' AND (l_owner_flag ='Y' OR l_admin_flag ='Y') THEN
4069: IF G_DEBUG THEN
4070: OZF_UTILITY_PVT.debug_message('Owner can update Product Lines & Customer Details');
4071: END IF;
4072: --//Owner can update Product Lines & Customer Details
4073: l_line_update_flag := 'Y';
4074: l_cust_update_flag := 'Y';

Line 4077: OZF_UTILITY_PVT.debug_message('PM Can update Product Lines & Customer Details');

4073: l_line_update_flag := 'Y';
4074: l_cust_update_flag := 'Y';
4075: ELSIF l_old_status_code <>'DRAFT' AND (l_approver_flag ='Y' OR l_admin_flag ='Y') THEN
4076: IF G_DEBUG THEN
4077: OZF_UTILITY_PVT.debug_message('PM Can update Product Lines & Customer Details');
4078: END IF;
4079: --//PM Can update Product Lines & Customer Details
4080: l_line_update_flag := 'Y';
4081: l_cust_update_flag := 'Y';

Line 4088: OZF_UTILITY_PVT.debug_message('Validate Product Line Records');

4084: --//Validate Product Line Records
4085: IF l_line_update_flag ='Y' THEN
4086:
4087: IF G_DEBUG THEN
4088: OZF_UTILITY_PVT.debug_message('Validate Product Line Records');
4089: END IF;
4090:
4091: IF l_new_sdr_lines_tbl.count > 0 THEN
4092:

Line 4110: OZF_UTILITY_PVT.debug_message('Validate Customer Records');

4106:
4107: --//Validate Customer Records
4108: IF l_cust_update_flag = 'Y' THEN
4109: IF G_DEBUG THEN
4110: OZF_UTILITY_PVT.debug_message('Validate Customer Records');
4111: END IF;
4112:
4113: IF l_new_sdr_cust_tbl.count > 0 THEN
4114:

Line 4132: OZF_UTILITY_PVT.debug_message('update_header_record');

4128:
4129: --//UPDATE PROCESS
4130: --//Update Header Records
4131: IF G_DEBUG THEN
4132: OZF_UTILITY_PVT.debug_message('update_header_record');
4133: END IF;
4134:
4135: update_header_record(
4136: p_SDR_hdr_rec =>l_old_sdr_hdr_rec

Line 4146: OZF_UTILITY_PVT.debug_message('populate_translation_record');

4142: RAISE fnd_api.g_exc_error;
4143: END IF;
4144:
4145: IF G_DEBUG THEN
4146: OZF_UTILITY_PVT.debug_message('populate_translation_record');
4147: END IF;
4148: --//Update TL record
4149: populate_translation_record(
4150: p_request_header_id =>l_old_sdr_hdr_rec.request_header_id

Line 4194: OZF_UTILITY_PVT.debug_message('Update Lines Record');

4190: --//Update Lines Record
4191: IF l_line_rec_flag ='Y' THEN
4192:
4193: IF G_DEBUG THEN
4194: OZF_UTILITY_PVT.debug_message('Update Lines Record');
4195: END IF;
4196: populate_product_lines(
4197: p_request_header_id => l_new_sdr_hdr_rec.request_header_id
4198: ,p_SDR_lines_tbl => l_new_sdr_lines_tbl

Line 4211: OZF_UTILITY_PVT.debug_message('Populate Customer Details table');

4207:
4208: --//Update Customer Record
4209: IF l_cust_rec_flag ='Y' THEN
4210: IF G_DEBUG THEN
4211: OZF_UTILITY_PVT.debug_message('Populate Customer Details table');
4212: END IF;
4213: populate_customer_details(
4214: p_request_header_id => l_new_sdr_hdr_rec.request_header_id
4215: ,p_SDR_cust_tbl => l_new_sdr_cust_tbl

Line 4228: OZF_UTILITY_PVT.debug_message('Request Header id from update_header_record :'||p_SDR_hdr_rec.request_header_id);

4224:
4225: --//Invoking Offer API Process
4226: --//Moved the code from update_header_record Procedure - Bugfix : 7501052
4227: IF G_DEBUG THEN
4228: OZF_UTILITY_PVT.debug_message('Request Header id from update_header_record :'||p_SDR_hdr_rec.request_header_id);
4229: END IF;
4230:
4231: IF l_new_status_code IN ('PENDING_OFFER_APPROVAL','ACTIVE') OR
4232: l_old_status_code ='ACTIVE' OR

Line 4240: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id:'||l_qp_list_header_id);

4236: FETCH c_qp_list_header_id INTO l_qp_list_header_id;
4237: CLOSE c_qp_list_header_id;
4238:
4239: IF G_DEBUG THEN
4240: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id:'||l_qp_list_header_id);
4241: OZF_UTILITY_PVT.debug_message('l_new_status_code :'||l_new_status_code);
4242: OZF_UTILITY_PVT.debug_message('IG_OLD_STATUS_CODE:'||l_old_status_code);
4243: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers :'||p_SDR_hdr_rec.request_header_id);
4244: END IF;

Line 4241: OZF_UTILITY_PVT.debug_message('l_new_status_code :'||l_new_status_code);

4237: CLOSE c_qp_list_header_id;
4238:
4239: IF G_DEBUG THEN
4240: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id:'||l_qp_list_header_id);
4241: OZF_UTILITY_PVT.debug_message('l_new_status_code :'||l_new_status_code);
4242: OZF_UTILITY_PVT.debug_message('IG_OLD_STATUS_CODE:'||l_old_status_code);
4243: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers :'||p_SDR_hdr_rec.request_header_id);
4244: END IF;
4245:

Line 4242: OZF_UTILITY_PVT.debug_message('IG_OLD_STATUS_CODE:'||l_old_status_code);

4238:
4239: IF G_DEBUG THEN
4240: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id:'||l_qp_list_header_id);
4241: OZF_UTILITY_PVT.debug_message('l_new_status_code :'||l_new_status_code);
4242: OZF_UTILITY_PVT.debug_message('IG_OLD_STATUS_CODE:'||l_old_status_code);
4243: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers :'||p_SDR_hdr_rec.request_header_id);
4244: END IF;
4245:
4246: OZF_OFFER_PVT.process_sd_modifiers(

Line 4243: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers :'||p_SDR_hdr_rec.request_header_id);

4239: IF G_DEBUG THEN
4240: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id:'||l_qp_list_header_id);
4241: OZF_UTILITY_PVT.debug_message('l_new_status_code :'||l_new_status_code);
4242: OZF_UTILITY_PVT.debug_message('IG_OLD_STATUS_CODE:'||l_old_status_code);
4243: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers :'||p_SDR_hdr_rec.request_header_id);
4244: END IF;
4245:
4246: OZF_OFFER_PVT.process_sd_modifiers(
4247: p_sdr_header_id => p_SDR_hdr_rec.request_header_id

Line 4258: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id(Offer Id) :'||l_qp_list_header_id);

4254: ,x_qp_list_header_id => l_qp_list_header_id
4255: ,x_error_location => l_error_location);
4256:
4257: IF G_DEBUG THEN
4258: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id(Offer Id) :'||l_qp_list_header_id);
4259: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers'||l_error_location);
4260: END IF;
4261:
4262: IF l_new_status_code ='PENDING_OFFER_APPROVAL' THEN

Line 4259: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers'||l_error_location);

4255: ,x_error_location => l_error_location);
4256:
4257: IF G_DEBUG THEN
4258: OZF_UTILITY_PVT.debug_message('l_qp_list_header_id(Offer Id) :'||l_qp_list_header_id);
4259: OZF_UTILITY_PVT.debug_message('Invoking OZF_OFFER_PVT.process_sd_modifiers'||l_error_location);
4260: END IF;
4261:
4262: IF l_new_status_code ='PENDING_OFFER_APPROVAL' THEN
4263: --//Updating SD Request Header table with offer information

Line 4280: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' End');

4276:
4277:
4278: --// Commit the process
4279: IF G_DEBUG THEN
4280: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' End');
4281: END IF;
4282: IF FND_API.to_Boolean( p_commit )
4283: THEN
4284: COMMIT WORK;

Line 4292: OZF_UTILITY_PVT.debug_message('Raises business event');

4288: --//1.Status Change Business Event
4289:
4290: IF l_old_user_status_id <> l_new_user_status_id THEN
4291: IF G_DEBUG THEN
4292: OZF_UTILITY_PVT.debug_message('Raises business event');
4293: END IF;
4294: --//Get the user status names
4295: OPEN c_user_status_name(l_old_user_status_id);
4296: FETCH c_user_status_name INTO l_old_user_stat_name;

Line 4326: OZF_UTILITY_PVT.debug_message('Raises a XML Gateway business event');

4322: AND (l_new_status_code='PENDING_SUPPLIER_APPROVAL')
4323: AND (l_request_communication ='XML') THEN
4324:
4325: IF G_DEBUG THEN
4326: OZF_UTILITY_PVT.debug_message('Raises a XML Gateway business event');
4327: END IF;
4328: raise_XML_business_event(
4329: p_request_header_id => l_new_sdr_hdr_rec.request_header_id
4330: ,p_supplier_id => l_old_sdr_hdr_rec.supplier_id

Line 4607: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' pub start');

4603: FND_MSG_PUB.initialize;
4604: END IF;
4605: -- Debug Message
4606: IF G_DEBUG THEN
4607: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' pub start');
4608: END IF;
4609: -- Initialize API return status to SUCCESS
4610: x_return_status := FND_API.G_RET_STS_SUCCESS;
4611: --==============================================================================

Line 4617: OZF_UTILITY_PVT.debug_message('l_user_id: ' ||l_user_id);

4613:
4614: l_user_id := FND_GLOBAL.user_id;
4615:
4616: IF G_DEBUG THEN
4617: OZF_UTILITY_PVT.debug_message('l_user_id: ' ||l_user_id);
4618: END IF;
4619: --//Check if user is a valid resource or not
4620: OPEN c_resource_id(l_user_id);
4621: FETCH c_resource_id INTO l_resource_id;

Line 4634: OZF_UTILITY_PVT.debug_message('l_resource_id: ' ||l_resource_id);

4630: RETURN;
4631: END IF;
4632:
4633: IF G_DEBUG THEN
4634: OZF_UTILITY_PVT.debug_message('l_resource_id: ' ||l_resource_id);
4635: END IF;
4636:
4637:
4638: --//Check If Source Request Id is valid

Line 4681: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(

4677: END IF;
4678: END IF;
4679: --//Accrual type Check
4680: IF p_accrual_type IS NOT NULL THEN
4681: l_lookup_stat :=OZF_UTILITY_PVT.check_lookup_exists(
4682: p_lookup_table_name =>'OZF_LOOKUPS'
4683: ,p_lookup_type =>'OZF_SDR_ACCRUAL_TYPE'
4684: ,p_lookup_code => p_accrual_type);
4685:

Line 4846: OZF_UTILITY_PVT.debug_message('Copy Option ');

4842: RETURN;
4843: END IF;
4844:
4845: IF G_DEBUG THEN
4846: OZF_UTILITY_PVT.debug_message('Copy Option ');
4847: OZF_UTILITY_PVT.debug_message('Source accrual_type :'||l_sdr_source_rec.accrual_type);
4848: OZF_UTILITY_PVT.debug_message('New accrual_type :'|| p_accrual_type);
4849: END IF;
4850:

Line 4847: OZF_UTILITY_PVT.debug_message('Source accrual_type :'||l_sdr_source_rec.accrual_type);

4843: END IF;
4844:
4845: IF G_DEBUG THEN
4846: OZF_UTILITY_PVT.debug_message('Copy Option ');
4847: OZF_UTILITY_PVT.debug_message('Source accrual_type :'||l_sdr_source_rec.accrual_type);
4848: OZF_UTILITY_PVT.debug_message('New accrual_type :'|| p_accrual_type);
4849: END IF;
4850:
4851: IF (l_sdr_source_rec.accrual_type ='INTERNAL') AND (p_accrual_type ='SUPPLIER') THEN

Line 4848: OZF_UTILITY_PVT.debug_message('New accrual_type :'|| p_accrual_type);

4844:
4845: IF G_DEBUG THEN
4846: OZF_UTILITY_PVT.debug_message('Copy Option ');
4847: OZF_UTILITY_PVT.debug_message('Source accrual_type :'||l_sdr_source_rec.accrual_type);
4848: OZF_UTILITY_PVT.debug_message('New accrual_type :'|| p_accrual_type);
4849: END IF;
4850:
4851: IF (l_sdr_source_rec.accrual_type ='INTERNAL') AND (p_accrual_type ='SUPPLIER') THEN
4852: --Invalid Copy Option

Line 4887: OZF_UTILITY_PVT.debug_message('Populate Header table');

4883: --//Get the User status ID
4884: l_sdr_source_rec.user_status_id :=get_user_status_id('DRAFT');
4885:
4886: IF G_DEBUG THEN
4887: OZF_UTILITY_PVT.debug_message('Populate Header table');
4888: END IF;
4889: --//Populate Header table
4890: Insert_header_record(
4891: p_SDR_hdr_rec => l_sdr_source_rec

Line 4908: OZF_UTILITY_PVT.debug_message('Populate Translation table');

4904: FETCH c_tl_description INTO l_sdr_source_rec.request_description;
4905: CLOSE c_tl_description;
4906:
4907: IF G_DEBUG THEN
4908: OZF_UTILITY_PVT.debug_message('Populate Translation table');
4909: END IF;
4910: populate_translation_record(
4911: p_request_header_id =>x_request_header_id
4912: ,p_description =>l_sdr_source_rec.request_description

Line 4918: OZF_UTILITY_PVT.debug_message('x_request_header_id '||x_request_header_id);

4914: ,p_mode =>'COPY'
4915: ,x_return_status => x_return_status);
4916:
4917: IF G_DEBUG THEN
4918: OZF_UTILITY_PVT.debug_message('x_request_header_id '||x_request_header_id);
4919: END IF;
4920:
4921: IF x_return_status = fnd_api.g_ret_sts_unexp_error THEN
4922: RAISE fnd_api.g_exc_unexpected_error;

Line 4954: OZF_UTILITY_PVT.debug_message('Copy Product Lines');

4950: END IF;
4951:
4952:
4953: IF G_DEBUG THEN
4954: OZF_UTILITY_PVT.debug_message('Copy Product Lines');
4955: END IF;
4956: --//Copy Product Lines
4957: IF ((p_copy_product_flag ='Y') AND (l_product_exists ='Y'))THEN
4958: OPEN c_source_sd_lines(p_source_request_id);

Line 4962: OZF_UTILITY_PVT.debug_message('Inside Loop :'||l_product_count);

4958: OPEN c_source_sd_lines(p_source_request_id);
4959: LOOP
4960: l_product_count := l_product_count + 1;
4961: IF G_DEBUG THEN
4962: OZF_UTILITY_PVT.debug_message('Inside Loop :'||l_product_count);
4963: END IF;
4964:
4965: FETCH c_source_sd_lines INTO
4966: l_sdr_source_lines_tbl(l_product_count).product_context,

Line 5067: OZF_UTILITY_PVT.debug_message('populate_customer_details');

5063: END LOOP;
5064: CLOSE c_source_customer_dtl;
5065: --//Populate Customer Details table
5066: IF G_DEBUG THEN
5067: OZF_UTILITY_PVT.debug_message('populate_customer_details');
5068: END IF;
5069: populate_customer_details(
5070: p_request_header_id => x_request_header_id
5071: ,p_SDR_cust_tbl => l_sdr_source_cust_tbl

Line 5129: OZF_UTILITY_PVT.debug_message('New request_header_id :'||x_request_header_id );

5125: END IF;
5126:
5127: -- Commit the process
5128: IF G_DEBUG THEN
5129: OZF_UTILITY_PVT.debug_message('New request_header_id :'||x_request_header_id );
5130: OZF_UTILITY_PVT.debug_message('Return Status :'|| x_return_status );
5131: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' End..');
5132: END IF;
5133: IF FND_API.to_Boolean( p_commit )

Line 5130: OZF_UTILITY_PVT.debug_message('Return Status :'|| x_return_status );

5126:
5127: -- Commit the process
5128: IF G_DEBUG THEN
5129: OZF_UTILITY_PVT.debug_message('New request_header_id :'||x_request_header_id );
5130: OZF_UTILITY_PVT.debug_message('Return Status :'|| x_return_status );
5131: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' End..');
5132: END IF;
5133: IF FND_API.to_Boolean( p_commit )
5134: THEN

Line 5131: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' End..');

5127: -- Commit the process
5128: IF G_DEBUG THEN
5129: OZF_UTILITY_PVT.debug_message('New request_header_id :'||x_request_header_id );
5130: OZF_UTILITY_PVT.debug_message('Return Status :'|| x_return_status );
5131: OZF_UTILITY_PVT.debug_message('Public API: ' || l_api_name || ' End..');
5132: END IF;
5133: IF FND_API.to_Boolean( p_commit )
5134: THEN
5135: COMMIT WORK;