DBA Data[Home] [Help]

APPS.OZF_FUNDRULES_PVT dependencies on FND_API

Line 33: x_return_status := fnd_api.g_ret_sts_success;

29: WHERE EXISTS( SELECT 1
30: FROM ams_act_products
31: WHERE act_product_used_by_id = p_fund_id AND arc_act_product_used_by = 'FUND');
32: BEGIN
33: x_return_status := fnd_api.g_ret_sts_success;
34: -- Fetch the cursor
35: OPEN c_product_elig;
36: FETCH c_product_elig INTO l_dummy;
37: CLOSE c_product_elig;

Line 41: x_return_status := fnd_api.g_ret_sts_error;

37: CLOSE c_product_elig;
38:
39: IF l_dummy IS NULL THEN
40: ozf_utility_pvt.error_message('OZF_ACCRUAL_NO_PROD');
41: x_return_status := fnd_api.g_ret_sts_error;
42: END IF;
43: END check_product_elig_exists;
44:
45:

Line 84: x_return_status := fnd_api.g_ret_sts_success;

80: l_par_curr_code VARCHAR2(30);
81: l_coverted_orig_budget NUMBER;
82: l_rate NUMBER;
83: BEGIN
84: x_return_status := fnd_api.g_ret_sts_success;
85:
86: IF p_parent_id IS NULL THEN
87: RETURN;
88: END IF;

Line 127: x_return_status := fnd_api.g_ret_sts_error;

123: END IF;
124: fnd_msg_pub.ADD;
125: END IF;
126:
127: x_return_status := fnd_api.g_ret_sts_error;
128: END IF;
129: END check_fund_amount_vs_parent;
130:
131:

Line 156: x_return_status := fnd_api.g_ret_sts_success;

152: WHERE fund_id = p_parent_id;
153:
154: l_parent_fund_type VARCHAR2(30);
155: BEGIN
156: x_return_status := fnd_api.g_ret_sts_success;
157:
158: IF p_parent_id IS NULL THEN
159: RETURN;
160: END IF;

Line 176: x_return_status := fnd_api.g_ret_sts_error;

172: fnd_message.set_name('OZF', 'OZF_CHILD_WRONG_FUND_TYPE');
173: END IF;
174: fnd_msg_pub.ADD;
175: END IF;
176: x_return_status := fnd_api.g_ret_sts_error;
177: END IF;
178: END check_fund_type_vs_parent;
179:
180:

Line 206: x_return_status := fnd_api.g_ret_sts_success;

202: l_parent_fund_status VARCHAR2(30);
203: l_parent_fund_type VARCHAR2(30);
204:
205: BEGIN
206: x_return_status := fnd_api.g_ret_sts_success;
207:
208:
209: IF p_parent_id IS NULL THEN
210: RETURN;

Line 230: x_return_status := fnd_api.g_ret_sts_error;

226: END IF;
227: fnd_msg_pub.ADD;
228: END IF;
229:
230: x_return_status := fnd_api.g_ret_sts_error;
231: END IF;
232: ELSIF p_status_code = 'ON_HOLD' THEN
233: -- Check parent fund status
234: IF l_parent_fund_status NOT IN ('ON_HOLD', 'ACTIVE') THEN

Line 244: x_return_status := fnd_api.g_ret_sts_error;

240: END IF;
241: fnd_msg_pub.ADD;
242: END IF;
243:
244: x_return_status := fnd_api.g_ret_sts_error;
245: END IF; --status_code
246: END IF;
247: END check_fund_status_vs_parent;
248:

Line 276: x_return_status := fnd_api.g_ret_sts_success;

272:
273: l_parent_start_date DATE;
274: l_parent_end_date DATE;
275: BEGIN
276: x_return_status := fnd_api.g_ret_sts_success;
277:
278: IF p_parent_id IS NULL THEN
279: RETURN;
280: END IF;

Line 295: x_return_status := fnd_api.g_ret_sts_error;

291: fnd_message.set_name('OZF', 'OZF_CHILD_ILLEGAL_DATE');
292: fnd_msg_pub.ADD;
293: END IF;
294:
295: x_return_status := fnd_api.g_ret_sts_error;
296: END IF;
297: END check_fund_dates_vs_parent;
298:
299:

Line 323: x_return_status := fnd_api.g_ret_sts_success;

319: WHERE fund_id = p_parent_id;
320:
321: l_parent_fund_curr VARCHAR2(30);
322: BEGIN
323: x_return_status := fnd_api.g_ret_sts_success;
324:
325: IF p_parent_id IS NULL THEN
326: RETURN;
327: END IF;

Line 340: x_return_status := fnd_api.g_ret_sts_error;

336: fnd_message.set_name('OZF', 'OZF_CHILD_ILLEGAL_CURRENCY');
337: fnd_msg_pub.ADD;
338: END IF;
339:
340: x_return_status := fnd_api.g_ret_sts_error;
341: END IF;
342: END check_fund_curr_vs_parent;
343:
344:

Line 383: x_return_status := fnd_api.g_ret_sts_success;

379: WHERE fund_id = p_fund_id;
380:
381: l_parent_fund_type VARCHAR2(30);
382: BEGIN
383: x_return_status := fnd_api.g_ret_sts_success;
384:
385: IF p_fund_id IS NULL THEN
386: RETURN;
387: END IF;

Line 428: x_return_status := fnd_api.g_ret_sts_error;

424: 'FUND_NAME',
425: l_sub_rec.short_name);
426: END IF;
427:
428: x_return_status := fnd_api.g_ret_sts_error;
429: END IF;
430: END LOOP;
431: END check_fund_amount_vs_child;
432:

Line 458: x_return_status := fnd_api.g_ret_sts_success;

454: fund_type AS fund_type
455: FROM ozf_funds_all_vl
456: WHERE parent_fund_id = p_fund_id;
457: BEGIN
458: x_return_status := fnd_api.g_ret_sts_success;
459:
460: IF p_fund_id IS NULL THEN
461: RETURN;
462: END IF;

Line 467: x_return_status := fnd_api.g_ret_sts_error;

463:
464: FOR l_sub_rec IN c_sub_fund
465: LOOP
466: IF p_start_date > l_sub_rec.start_date THEN
467: x_return_status := fnd_api.g_ret_sts_error;
468: IF l_sub_rec.fund_type = 'QUOTA' THEN
469: ozf_utility_pvt.error_message('OZF_TP_START_AFT_SUB_START', 'FUND_NAME', l_sub_rec.short_name);
470: ELSE
471: ozf_utility_pvt.error_message('OZF_FUND_START_AFT_SUB_START', 'FUND_NAME', l_sub_rec.short_name);

Line 474: x_return_status := fnd_api.g_ret_sts_error;

470: ELSE
471: ozf_utility_pvt.error_message('OZF_FUND_START_AFT_SUB_START', 'FUND_NAME', l_sub_rec.short_name);
472: END IF;
473: ELSIF p_start_date > l_sub_rec.end_date THEN
474: x_return_status := fnd_api.g_ret_sts_error;
475: IF l_sub_rec.fund_type = 'QUOTA' THEN
476: ozf_utility_pvt.error_message('OZF_TP_START_AFT_SUB_END', 'FUND_NAME', l_sub_rec.short_name);
477: ELSE
478: ozf_utility_pvt.error_message('OZF_FUND_START_AFT_SUB_END', 'FUND_NAME', l_sub_rec.short_name);

Line 483: x_return_status := fnd_api.g_ret_sts_error;

479: END IF;
480: END IF;
481:
482: IF p_end_date < l_sub_rec.end_date THEN
483: x_return_status := fnd_api.g_ret_sts_error;
484: IF l_sub_rec.fund_type = 'QUOTA' THEN
485: ozf_utility_pvt.error_message('OZF_TP_QUOTA_END_BEF_SUB_END', 'FUND_NAME', l_sub_rec.short_name);
486: ELSE
487: ozf_utility_pvt.error_message('OZF_FUND_END_BEF_SUB_END', 'FUND_NAME', l_sub_rec.short_name);

Line 490: x_return_status := fnd_api.g_ret_sts_error;

486: ELSE
487: ozf_utility_pvt.error_message('OZF_FUND_END_BEF_SUB_END', 'FUND_NAME', l_sub_rec.short_name);
488: END IF;
489: ELSIF p_end_date < l_sub_rec.start_date THEN
490: x_return_status := fnd_api.g_ret_sts_error;
491: IF l_sub_rec.fund_type = 'QUOTA' THEN
492: ozf_utility_pvt.error_message('OZF_TP_END_BEF_SUB_START', 'FUND_NAME', l_sub_rec.short_name);
493: ELSE
494: ozf_utility_pvt.error_message('OZF_FUND_END_BEF_SUB_START', 'FUND_NAME', l_sub_rec.short_name);

Line 523: x_return_status := fnd_api.g_ret_sts_success;

519: fund_type AS fund_type
520: FROM ozf_funds_all_vl
521: WHERE parent_fund_id = p_fund_id;
522: BEGIN
523: x_return_status := fnd_api.g_ret_sts_success;
524:
525: IF p_fund_id IS NULL THEN
526: RETURN;
527: END IF;

Line 538: x_return_status := fnd_api.g_ret_sts_error;

534: ozf_utility_pvt.error_message('OZF_TP_PAR_MISMATCH_CHILD_TYPE', 'FUND_NAME', l_sub_rec.short_name);
535: ELSE
536: ozf_utility_pvt.error_message('OZF_PAR_MISMATCH_CHILD_TYPE', 'FUND_NAME', l_sub_rec.short_name);
537: END IF;
538: x_return_status := fnd_api.g_ret_sts_error;
539: END IF;
540: END LOOP;
541: END check_fund_type_vs_child;
542:

Line 567: x_return_status := fnd_api.g_ret_sts_success;

563: fund_type AS fund_type
564: FROM ozf_funds_all_vl
565: WHERE parent_fund_id = p_fund_id;
566: BEGIN
567: x_return_status := fnd_api.g_ret_sts_success;
568:
569: IF p_fund_id IS NULL THEN
570: RETURN;
571: END IF;

Line 582: x_return_status := fnd_api.g_ret_sts_error;

578: ozf_utility_pvt.error_message('OZF_TP_PAR_MISMATCH_CHILD_CURR', 'FUND_NAME', l_sub_rec.short_name);
579: ELSE
580: ozf_utility_pvt.error_message('OZF_PAR_MISMATCH_CHILD_CURR', 'FUND_NAME', l_sub_rec.short_name);
581: END IF;
582: x_return_status := fnd_api.g_ret_sts_error;
583: END IF;
584: END LOOP;
585: END check_fund_curr_vs_child;
586:

Line 674: x_return_status := fnd_api.g_ret_sts_success;

670: WHERE NAME = p_end_period_name;
671: */
672:
673: BEGIN
674: x_return_status := fnd_api.g_ret_sts_success;
675:
676: -- check if p_fund_calendar is null
677: IF p_fund_calendar IS NULL AND p_start_period_name IS NULL AND p_end_period_name IS NULL THEN
678: RETURN;

Line 680: x_return_status := fnd_api.g_ret_sts_error;

676: -- check if p_fund_calendar is null
677: IF p_fund_calendar IS NULL AND p_start_period_name IS NULL AND p_end_period_name IS NULL THEN
678: RETURN;
679: ELSIF p_fund_calendar IS NULL THEN
680: x_return_status := fnd_api.g_ret_sts_error;
681: ozf_utility_pvt.error_message('OZF_FUND_NO_CALENDAR');
682: RETURN;
683: END IF;
684:

Line 691: x_return_status := fnd_api.g_ret_sts_error;

687: FETCH c_fund_calendar INTO l_local;
688: CLOSE c_fund_calendar;
689:
690: IF l_local IS NULL THEN
691: x_return_status := fnd_api.g_ret_sts_error;
692: ozf_utility_pvt.error_message('OZF_FUND_BAD_CALENDAR');
693: RETURN;
694: END IF;
695:

Line 710: x_return_status := fnd_api.g_ret_sts_error;

706: CLOSE c_start_period;
707: END IF;
708:
709: IF l_start_start IS NULL THEN
710: x_return_status := fnd_api.g_ret_sts_error;
711: ozf_utility_pvt.error_message('OZF_FUND_BAD_START_PERIOD');
712: RETURN;
713: ELSIF p_start_date < l_start_start
714: OR p_start_date > l_start_end THEN

Line 715: x_return_status := fnd_api.g_ret_sts_error;

711: ozf_utility_pvt.error_message('OZF_FUND_BAD_START_PERIOD');
712: RETURN;
713: ELSIF p_start_date < l_start_start
714: OR p_start_date > l_start_end THEN
715: x_return_status := fnd_api.g_ret_sts_error;
716: IF p_fund_type = 'QUOTA' THEN
717: ozf_utility_pvt.error_message('OZF_TP_QUOTA_OUT_START_PERIOD');
718: ELSE
719: ozf_utility_pvt.error_message('OZF_FUND_OUT_START_PERIOD');

Line 738: x_return_status := fnd_api.g_ret_sts_error;

734: CLOSE c_end_period;
735: END IF;
736:
737: IF l_end_end IS NULL THEN
738: x_return_status := fnd_api.g_ret_sts_error;
739: ozf_utility_pvt.error_message('OZF_FUND_BAD_END_PERIOD');
740: RETURN;
741: ELSIF TRUNC(p_end_date) < TRUNC(l_end_start)
742: OR TRUNC(p_end_date) > TRUNC(l_end_end) THEN

Line 743: x_return_status := fnd_api.g_ret_sts_error;

739: ozf_utility_pvt.error_message('OZF_FUND_BAD_END_PERIOD');
740: RETURN;
741: ELSIF TRUNC(p_end_date) < TRUNC(l_end_start)
742: OR TRUNC(p_end_date) > TRUNC(l_end_end) THEN
743: x_return_status := fnd_api.g_ret_sts_error;
744: IF p_fund_type = 'QUOTA' THEN
745: ozf_utility_pvt.error_message('OZF_TP_QUOTA_OUT_END_PERIOD');
746: ELSE
747: ozf_utility_pvt.error_message('OZF_FUND_OUT_END_PERIOD');

Line 755: x_return_status := fnd_api.g_ret_sts_error;

751: END IF;
752:
753: -- compare the start date and the end date
754: IF TRUNC(l_start_start) > TRUNC(l_end_end) THEN
755: x_return_status := fnd_api.g_ret_sts_error;
756: ozf_utility_pvt.error_message('OZF_FUND_BAD_PERIODS');
757: END IF;
758: END check_fund_calendar;
759:

Line 797: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

793: p_old_fund_status IN VARCHAR2 := NULL,
794: x_msg_count OUT NOCOPY NUMBER,
795: x_msg_data OUT NOCOPY VARCHAR2,
796: x_return_status OUT NOCOPY VARCHAR2) IS
797: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
798: l_msg_count NUMBER;
799: l_msg_data VARCHAR2(2000);
800: l_api_name CONSTANT VARCHAR2(30) := 'process_offers';
801: l_full_name CONSTANT VARCHAR2(60) := g_pkg_name ||

Line 850: x_return_status := fnd_api.g_ret_sts_success;

846: IF G_DEBUG THEN
847: ozf_utility_pvt.debug_message(l_full_name ||
848: ': create offers');
849: END IF;
850: x_return_status := fnd_api.g_ret_sts_success;
851:
852: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
853: RAISE fnd_api.g_exc_unexpected_error;
854: END IF;

Line 852: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

848: ': create offers');
849: END IF;
850: x_return_status := fnd_api.g_ret_sts_success;
851:
852: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
853: RAISE fnd_api.g_exc_unexpected_error;
854: END IF;
855:
856: IF p_old_fund_status IS NULL THEN

Line 853: RAISE fnd_api.g_exc_unexpected_error;

849: END IF;
850: x_return_status := fnd_api.g_ret_sts_success;
851:
852: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
853: RAISE fnd_api.g_exc_unexpected_error;
854: END IF;
855:
856: IF p_old_fund_status IS NULL THEN
857: OPEN c_old_fund(p_fund_rec.fund_id);

Line 867: l_offer_hdr_rec.qp_list_header_id := fnd_api.g_miss_num;

863: IF G_DEBUG THEN
864: ozf_utility_pvt.debug_message('Create');
865: END IF;
866: -- first process_offerss in QP
867: l_offer_hdr_rec.qp_list_header_id := fnd_api.g_miss_num;
868: l_offer_hdr_rec.activity_media_id := p_fund_rec.task_id;
869: l_offer_hdr_rec.offer_id := fnd_api.g_miss_num;
870:
871: --kdass 18-MAY-2004 fix for bug 3628608

Line 869: l_offer_hdr_rec.offer_id := fnd_api.g_miss_num;

865: END IF;
866: -- first process_offerss in QP
867: l_offer_hdr_rec.qp_list_header_id := fnd_api.g_miss_num;
868: l_offer_hdr_rec.activity_media_id := p_fund_rec.task_id;
869: l_offer_hdr_rec.offer_id := fnd_api.g_miss_num;
870:
871: --kdass 18-MAY-2004 fix for bug 3628608
872: l_offer_hdr_rec.confidential_flag := 'Y';
873: -- commented for 11.5.9

Line 878: l_offer_hdr_rec.offer_operation := fnd_api.g_miss_char;

874: /*
875: IF p_fund_rec.liability_flag = 'Y' THEN
876: l_offer_hdr_rec.offer_operation := 'CREATE';
877: ELSE
878: l_offer_hdr_rec.offer_operation := fnd_api.g_miss_char;
879: END IF;
880: */
881: l_offer_hdr_rec.offer_operation := 'CREATE';
882: l_offer_hdr_rec.modifier_operation := 'CREATE';

Line 927: p_approval_flag=> fnd_api.g_true);

923: x_msg_data=> x_msg_data,
924: p_act_budgets_rec=> l_act_budgets_rec_type,
925: p_act_util_rec=> ozf_actbudgets_pvt.g_miss_act_util_rec,
926: x_act_budget_id=> l_act_budget_id,
927: p_approval_flag=> fnd_api.g_true);
928:
929: -- dbms_output.put_line('fundrules: create_act_budget returns ' || l_return_status);
930: -- dbms_output.put_line(' actbudget_used_by_id=' || l_act_budgets_rec_type.act_budget_used_by_id);
931: IF l_return_status = fnd_api.g_ret_sts_error THEN

Line 931: IF l_return_status = fnd_api.g_ret_sts_error THEN

927: p_approval_flag=> fnd_api.g_true);
928:
929: -- dbms_output.put_line('fundrules: create_act_budget returns ' || l_return_status);
930: -- dbms_output.put_line(' actbudget_used_by_id=' || l_act_budgets_rec_type.act_budget_used_by_id);
931: IF l_return_status = fnd_api.g_ret_sts_error THEN
932: RAISE fnd_api.g_exc_error;
933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
934: RAISE fnd_api.g_exc_unexpected_error;
935: END IF;

Line 932: RAISE fnd_api.g_exc_error;

928:
929: -- dbms_output.put_line('fundrules: create_act_budget returns ' || l_return_status);
930: -- dbms_output.put_line(' actbudget_used_by_id=' || l_act_budgets_rec_type.act_budget_used_by_id);
931: IF l_return_status = fnd_api.g_ret_sts_error THEN
932: RAISE fnd_api.g_exc_error;
933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
934: RAISE fnd_api.g_exc_unexpected_error;
935: END IF;
936:

Line 933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

929: -- dbms_output.put_line('fundrules: create_act_budget returns ' || l_return_status);
930: -- dbms_output.put_line(' actbudget_used_by_id=' || l_act_budgets_rec_type.act_budget_used_by_id);
931: IF l_return_status = fnd_api.g_ret_sts_error THEN
932: RAISE fnd_api.g_exc_error;
933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
934: RAISE fnd_api.g_exc_unexpected_error;
935: END IF;
936:
937: IF G_DEBUG THEN

Line 934: RAISE fnd_api.g_exc_unexpected_error;

930: -- dbms_output.put_line(' actbudget_used_by_id=' || l_act_budgets_rec_type.act_budget_used_by_id);
931: IF l_return_status = fnd_api.g_ret_sts_error THEN
932: RAISE fnd_api.g_exc_error;
933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
934: RAISE fnd_api.g_exc_unexpected_error;
935: END IF;
936:
937: IF G_DEBUG THEN
938: ozf_utility_pvt.debug_message(l_full_name ||

Line 977: l_offer_hdr_rec.offer_operation := fnd_api.g_miss_char;

973: /*
974: IF p_fund_rec.liability_flag = 'Y' THEN
975: l_offer_hdr_rec.offer_operation := 'UPDATE';
976: ELSE
977: l_offer_hdr_rec.offer_operation := fnd_api.g_miss_char;
978: END IF;
979: */
980: l_offer_hdr_rec.offer_operation := 'UPDATE';
981: l_offer_hdr_rec.modifier_operation := 'UPDATE';

Line 1052: --l_offer_hdr_rec.BUDGET_AMOUNT_FC NUMBER := Fnd_Api.g_miss_num

1048: p_fund_rec.fund_id;
1049: l_offer_hdr_rec.description := p_fund_rec.short_name;
1050: l_offer_hdr_rec.offer_amount := NVL(p_fund_rec.accrual_cap, 0);
1051: l_offer_hdr_rec.budget_amount_tc := NVL(p_fund_rec.accrual_cap, 0);
1052: --l_offer_hdr_rec.BUDGET_AMOUNT_FC NUMBER := Fnd_Api.g_miss_num
1053: IF l_qp_list_header_id IS NULL THEN
1054: l_offer_hdr_rec.offer_code := p_fund_rec.fund_number;
1055: END IF;
1056: l_offer_hdr_rec.ql_qualifier_type := p_fund_rec.apply_accrual_on;

Line 1086: p_commit => fnd_api.g_false,

1082: AND p_fund_rec.status_code in('ACTIVE','ON_HOLD','REJECTED') THEN
1083: */
1084: ozf_offer_pvt.update_offer_status
1085: (
1086: p_commit => fnd_api.g_false,
1087: x_return_status=> l_return_status,
1088: x_msg_count=> x_msg_count,
1089: x_msg_data=> x_msg_data,
1090: p_modifier_list_rec => l_offer_hdr_rec

Line 1093: IF l_return_status <> fnd_api.g_ret_sts_success THEN

1089: x_msg_data=> x_msg_data,
1090: p_modifier_list_rec => l_offer_hdr_rec
1091: );
1092:
1093: IF l_return_status <> fnd_api.g_ret_sts_success THEN
1094: IF G_DEBUG THEN
1095: ozf_utility_pvt.debug_message('OZF_OFFR_UPDATE_SATAUS FAIL');
1096: END IF;
1097:

Line 1098: IF l_return_status = fnd_api.g_ret_sts_error THEN

1094: IF G_DEBUG THEN
1095: ozf_utility_pvt.debug_message('OZF_OFFR_UPDATE_SATAUS FAIL');
1096: END IF;
1097:
1098: IF l_return_status = fnd_api.g_ret_sts_error THEN
1099: RAISE fnd_api.g_exc_error;
1100: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1101: RAISE fnd_api.g_exc_unexpected_error;
1102: END IF;

Line 1099: RAISE fnd_api.g_exc_error;

1095: ozf_utility_pvt.debug_message('OZF_OFFR_UPDATE_SATAUS FAIL');
1096: END IF;
1097:
1098: IF l_return_status = fnd_api.g_ret_sts_error THEN
1099: RAISE fnd_api.g_exc_error;
1100: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1101: RAISE fnd_api.g_exc_unexpected_error;
1102: END IF;
1103: END IF;

Line 1100: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

1096: END IF;
1097:
1098: IF l_return_status = fnd_api.g_ret_sts_error THEN
1099: RAISE fnd_api.g_exc_error;
1100: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1101: RAISE fnd_api.g_exc_unexpected_error;
1102: END IF;
1103: END IF;
1104:

Line 1101: RAISE fnd_api.g_exc_unexpected_error;

1097:
1098: IF l_return_status = fnd_api.g_ret_sts_error THEN
1099: RAISE fnd_api.g_exc_error;
1100: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1101: RAISE fnd_api.g_exc_unexpected_error;
1102: END IF;
1103: END IF;
1104:
1105: ELSE

Line 1110: p_init_msg_list=> fnd_api.g_false,

1106: IF G_DEBUG THEN
1107: ozf_utility_pvt.debug_message('process modifiers');
1108: END IF;
1109: ozf_offer_pvt.process_modifiers(
1110: p_init_msg_list=> fnd_api.g_false,
1111: p_api_version=> 1.0,
1112: p_commit=> fnd_api.g_false,
1113: x_return_status=> l_return_status,
1114: x_msg_count=> x_msg_count,

Line 1112: p_commit=> fnd_api.g_false,

1108: END IF;
1109: ozf_offer_pvt.process_modifiers(
1110: p_init_msg_list=> fnd_api.g_false,
1111: p_api_version=> 1.0,
1112: p_commit=> fnd_api.g_false,
1113: x_return_status=> l_return_status,
1114: x_msg_count=> x_msg_count,
1115: x_msg_data=> x_msg_data,
1116: p_modifier_list_rec=> l_offer_hdr_rec,

Line 1131: IF l_return_status <> fnd_api.g_ret_sts_success THEN

1127: x_msg_data);
1128: END IF;
1129: END IF;
1130:
1131: IF l_return_status <> fnd_api.g_ret_sts_success THEN
1132: IF G_DEBUG THEN
1133: ozf_utility_pvt.debug_message('OZF_OFFR_QP_FAILURE' ||
1134: l_error_location ||
1135: x_msg_data);

Line 1139: IF l_return_status = fnd_api.g_ret_sts_error THEN

1135: x_msg_data);
1136: END IF;
1137:
1138: -- ozf_utility_pvt.error_message('OZF_OFFR_QP_FAILURE'||l_error_location||x_msg_data);
1139: IF l_return_status = fnd_api.g_ret_sts_error THEN
1140: RAISE fnd_api.g_exc_error;
1141: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1142: RAISE fnd_api.g_exc_unexpected_error;
1143: END IF;

Line 1140: RAISE fnd_api.g_exc_error;

1136: END IF;
1137:
1138: -- ozf_utility_pvt.error_message('OZF_OFFR_QP_FAILURE'||l_error_location||x_msg_data);
1139: IF l_return_status = fnd_api.g_ret_sts_error THEN
1140: RAISE fnd_api.g_exc_error;
1141: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1142: RAISE fnd_api.g_exc_unexpected_error;
1143: END IF;
1144: END IF;

Line 1141: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

1137:
1138: -- ozf_utility_pvt.error_message('OZF_OFFR_QP_FAILURE'||l_error_location||x_msg_data);
1139: IF l_return_status = fnd_api.g_ret_sts_error THEN
1140: RAISE fnd_api.g_exc_error;
1141: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1142: RAISE fnd_api.g_exc_unexpected_error;
1143: END IF;
1144: END IF;
1145:

Line 1142: RAISE fnd_api.g_exc_unexpected_error;

1138: -- ozf_utility_pvt.error_message('OZF_OFFR_QP_FAILURE'||l_error_location||x_msg_data);
1139: IF l_return_status = fnd_api.g_ret_sts_error THEN
1140: RAISE fnd_api.g_exc_error;
1141: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1142: RAISE fnd_api.g_exc_unexpected_error;
1143: END IF;
1144: END IF;
1145:
1146: -- Update ozf_offers with status code 'PENDING' by incrementing object_version_number.

Line 1204: --l_offer_advd_opt_rec.PRINT_ON_INVOICE_FLAG VARCHAR2(1) := Fnd_Api.g_miss_char

1200: IF p_fund_rec.accrual_discount_level <> 'ORDER' THEN
1201: l_offer_advd_opt_rec.pricing_group_sequence := p_fund_rec.accrual_method;
1202: END IF;
1203:
1204: --l_offer_advd_opt_rec.PRINT_ON_INVOICE_FLAG VARCHAR2(1) := Fnd_Api.g_miss_char
1205: ozf_offer_pvt.process_adv_options(
1206: p_init_msg_list=> fnd_api.g_false,
1207: p_api_version=> 1.0,
1208: p_commit=> fnd_api.g_false,

Line 1206: p_init_msg_list=> fnd_api.g_false,

1202: END IF;
1203:
1204: --l_offer_advd_opt_rec.PRINT_ON_INVOICE_FLAG VARCHAR2(1) := Fnd_Api.g_miss_char
1205: ozf_offer_pvt.process_adv_options(
1206: p_init_msg_list=> fnd_api.g_false,
1207: p_api_version=> 1.0,
1208: p_commit=> fnd_api.g_false,
1209: x_return_status=> l_return_status,
1210: x_msg_count=> l_msg_count,

Line 1208: p_commit=> fnd_api.g_false,

1204: --l_offer_advd_opt_rec.PRINT_ON_INVOICE_FLAG VARCHAR2(1) := Fnd_Api.g_miss_char
1205: ozf_offer_pvt.process_adv_options(
1206: p_init_msg_list=> fnd_api.g_false,
1207: p_api_version=> 1.0,
1208: p_commit=> fnd_api.g_false,
1209: x_return_status=> l_return_status,
1210: x_msg_count=> l_msg_count,
1211: x_msg_data=> l_msg_data,
1212: p_advanced_options_rec=> l_offer_advd_opt_rec);

Line 1218: IF l_return_status = fnd_api.g_ret_sts_error THEN

1214: ozf_utility_pvt.debug_message('ret status for process adv options =>' ||
1215: l_return_status);
1216: END IF;
1217:
1218: IF l_return_status = fnd_api.g_ret_sts_error THEN
1219: RAISE fnd_api.g_exc_error;
1220: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1221: RAISE fnd_api.g_exc_unexpected_error;
1222: END IF;

Line 1219: RAISE fnd_api.g_exc_error;

1215: l_return_status);
1216: END IF;
1217:
1218: IF l_return_status = fnd_api.g_ret_sts_error THEN
1219: RAISE fnd_api.g_exc_error;
1220: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1221: RAISE fnd_api.g_exc_unexpected_error;
1222: END IF;
1223: END IF;

Line 1220: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

1216: END IF;
1217:
1218: IF l_return_status = fnd_api.g_ret_sts_error THEN
1219: RAISE fnd_api.g_exc_error;
1220: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1221: RAISE fnd_api.g_exc_unexpected_error;
1222: END IF;
1223: END IF;
1224: */

Line 1221: RAISE fnd_api.g_exc_unexpected_error;

1217:
1218: IF l_return_status = fnd_api.g_ret_sts_error THEN
1219: RAISE fnd_api.g_exc_error;
1220: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1221: RAISE fnd_api.g_exc_unexpected_error;
1222: END IF;
1223: END IF;
1224: */
1225: EXCEPTION

Line 1226: WHEN fnd_api.g_exc_error THEN

1222: END IF;
1223: END IF;
1224: */
1225: EXCEPTION
1226: WHEN fnd_api.g_exc_error THEN
1227: ROLLBACK TO process_offers;
1228: x_return_status := fnd_api.g_ret_sts_error;
1229: fnd_msg_pub.count_and_get(
1230: p_encoded=> fnd_api.g_false,

Line 1228: x_return_status := fnd_api.g_ret_sts_error;

1224: */
1225: EXCEPTION
1226: WHEN fnd_api.g_exc_error THEN
1227: ROLLBACK TO process_offers;
1228: x_return_status := fnd_api.g_ret_sts_error;
1229: fnd_msg_pub.count_and_get(
1230: p_encoded=> fnd_api.g_false,
1231: p_count=> x_msg_count,
1232: p_data=> x_msg_data);

Line 1230: p_encoded=> fnd_api.g_false,

1226: WHEN fnd_api.g_exc_error THEN
1227: ROLLBACK TO process_offers;
1228: x_return_status := fnd_api.g_ret_sts_error;
1229: fnd_msg_pub.count_and_get(
1230: p_encoded=> fnd_api.g_false,
1231: p_count=> x_msg_count,
1232: p_data=> x_msg_data);
1233: WHEN fnd_api.g_exc_unexpected_error THEN
1234: ROLLBACK TO process_offers;

Line 1233: WHEN fnd_api.g_exc_unexpected_error THEN

1229: fnd_msg_pub.count_and_get(
1230: p_encoded=> fnd_api.g_false,
1231: p_count=> x_msg_count,
1232: p_data=> x_msg_data);
1233: WHEN fnd_api.g_exc_unexpected_error THEN
1234: ROLLBACK TO process_offers;
1235: x_return_status := fnd_api.g_ret_sts_unexp_error;
1236: fnd_msg_pub.count_and_get(
1237: p_encoded=> fnd_api.g_false,

Line 1235: x_return_status := fnd_api.g_ret_sts_unexp_error;

1231: p_count=> x_msg_count,
1232: p_data=> x_msg_data);
1233: WHEN fnd_api.g_exc_unexpected_error THEN
1234: ROLLBACK TO process_offers;
1235: x_return_status := fnd_api.g_ret_sts_unexp_error;
1236: fnd_msg_pub.count_and_get(
1237: p_encoded=> fnd_api.g_false,
1238: p_count=> x_msg_count,
1239: p_data=> x_msg_data);

Line 1237: p_encoded=> fnd_api.g_false,

1233: WHEN fnd_api.g_exc_unexpected_error THEN
1234: ROLLBACK TO process_offers;
1235: x_return_status := fnd_api.g_ret_sts_unexp_error;
1236: fnd_msg_pub.count_and_get(
1237: p_encoded=> fnd_api.g_false,
1238: p_count=> x_msg_count,
1239: p_data=> x_msg_data);
1240: WHEN OTHERS THEN
1241: ROLLBACK TO process_offers;

Line 1242: x_return_status := fnd_api.g_ret_sts_unexp_error;

1238: p_count=> x_msg_count,
1239: p_data=> x_msg_data);
1240: WHEN OTHERS THEN
1241: ROLLBACK TO process_offers;
1242: x_return_status := fnd_api.g_ret_sts_unexp_error;
1243:
1244: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1245: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1246: END IF;

Line 1249: p_encoded=> fnd_api.g_false,

1245: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1246: END IF;
1247:
1248: fnd_msg_pub.count_and_get(
1249: p_encoded=> fnd_api.g_false,
1250: p_count=> x_msg_count,
1251: p_data=> x_msg_data);
1252: END process_offers;
1253:

Line 1289: x_return_status := fnd_api.g_ret_sts_success;

1285: BEGIN
1286: -- If the fund_status is changing from 'DRAFT to 'ACTIVE', we need to create a record in the
1287: -- FUND_REQUESTS table for the holdback amount.
1288: SAVEPOINT process_approval;
1289: x_return_status := fnd_api.g_ret_sts_success;
1290:
1291: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1292: RAISE fnd_api.g_exc_unexpected_error;
1293: END IF;

Line 1291: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

1287: -- FUND_REQUESTS table for the holdback amount.
1288: SAVEPOINT process_approval;
1289: x_return_status := fnd_api.g_ret_sts_success;
1290:
1291: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1292: RAISE fnd_api.g_exc_unexpected_error;
1293: END IF;
1294:
1295: IF p_mode = 'ACTIVE' THEN

Line 1292: RAISE fnd_api.g_exc_unexpected_error;

1288: SAVEPOINT process_approval;
1289: x_return_status := fnd_api.g_ret_sts_success;
1290:
1291: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1292: RAISE fnd_api.g_exc_unexpected_error;
1293: END IF;
1294:
1295: IF p_mode = 'ACTIVE' THEN
1296: IF (NVL(p_fund_rec.holdback_amt, 0) <> 0) THEN

Line 1321: IF l_return_status = fnd_api.g_ret_sts_error THEN

1317: x_msg_data=> x_msg_data,
1318: p_act_budgets_rec=> l_act_budget_rec,
1319: x_act_budget_id=> l_act_budget_id);
1320:
1321: IF l_return_status = fnd_api.g_ret_sts_error THEN
1322: RAISE fnd_api.g_exc_error;
1323: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1324: RAISE fnd_api.g_exc_unexpected_error;
1325: END IF;

Line 1322: RAISE fnd_api.g_exc_error;

1318: p_act_budgets_rec=> l_act_budget_rec,
1319: x_act_budget_id=> l_act_budget_id);
1320:
1321: IF l_return_status = fnd_api.g_ret_sts_error THEN
1322: RAISE fnd_api.g_exc_error;
1323: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1324: RAISE fnd_api.g_exc_unexpected_error;
1325: END IF;
1326: END IF; -- end for holdback mat

Line 1323: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

1319: x_act_budget_id=> l_act_budget_id);
1320:
1321: IF l_return_status = fnd_api.g_ret_sts_error THEN
1322: RAISE fnd_api.g_exc_error;
1323: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1324: RAISE fnd_api.g_exc_unexpected_error;
1325: END IF;
1326: END IF; -- end for holdback mat
1327: END IF;

Line 1324: RAISE fnd_api.g_exc_unexpected_error;

1320:
1321: IF l_return_status = fnd_api.g_ret_sts_error THEN
1322: RAISE fnd_api.g_exc_error;
1323: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1324: RAISE fnd_api.g_exc_unexpected_error;
1325: END IF;
1326: END IF; -- end for holdback mat
1327: END IF;
1328:

Line 1340: IF l_return_status = fnd_api.g_ret_sts_error THEN

1336: x_return_status=> l_return_status,
1337: x_msg_count=> x_msg_count,
1338: x_msg_data=> x_msg_data);
1339:
1340: IF l_return_status = fnd_api.g_ret_sts_error THEN
1341: RAISE fnd_api.g_exc_error;
1342: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1343: RAISE fnd_api.g_exc_unexpected_error;
1344: END IF;

Line 1341: RAISE fnd_api.g_exc_error;

1337: x_msg_count=> x_msg_count,
1338: x_msg_data=> x_msg_data);
1339:
1340: IF l_return_status = fnd_api.g_ret_sts_error THEN
1341: RAISE fnd_api.g_exc_error;
1342: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1343: RAISE fnd_api.g_exc_unexpected_error;
1344: END IF;
1345: END IF;

Line 1342: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

1338: x_msg_data=> x_msg_data);
1339:
1340: IF l_return_status = fnd_api.g_ret_sts_error THEN
1341: RAISE fnd_api.g_exc_error;
1342: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1343: RAISE fnd_api.g_exc_unexpected_error;
1344: END IF;
1345: END IF;
1346:

Line 1343: RAISE fnd_api.g_exc_unexpected_error;

1339:
1340: IF l_return_status = fnd_api.g_ret_sts_error THEN
1341: RAISE fnd_api.g_exc_error;
1342: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1343: RAISE fnd_api.g_exc_unexpected_error;
1344: END IF;
1345: END IF;
1346:
1347: IF G_DEBUG THEN

Line 1352: WHEN fnd_api.g_exc_error THEN

1348: ozf_utility_pvt.debug_message(l_full_name ||
1349: ': end');
1350: END IF;
1351: EXCEPTION
1352: WHEN fnd_api.g_exc_error THEN
1353: ROLLBACK TO process_approval;
1354: x_return_status := fnd_api.g_ret_sts_error;
1355: fnd_msg_pub.count_and_get(
1356: p_encoded=> fnd_api.g_false,

Line 1354: x_return_status := fnd_api.g_ret_sts_error;

1350: END IF;
1351: EXCEPTION
1352: WHEN fnd_api.g_exc_error THEN
1353: ROLLBACK TO process_approval;
1354: x_return_status := fnd_api.g_ret_sts_error;
1355: fnd_msg_pub.count_and_get(
1356: p_encoded=> fnd_api.g_false,
1357: p_count=> x_msg_count,
1358: p_data=> x_msg_data);

Line 1356: p_encoded=> fnd_api.g_false,

1352: WHEN fnd_api.g_exc_error THEN
1353: ROLLBACK TO process_approval;
1354: x_return_status := fnd_api.g_ret_sts_error;
1355: fnd_msg_pub.count_and_get(
1356: p_encoded=> fnd_api.g_false,
1357: p_count=> x_msg_count,
1358: p_data=> x_msg_data);
1359: WHEN fnd_api.g_exc_unexpected_error THEN
1360: ROLLBACK TO process_approval;

Line 1359: WHEN fnd_api.g_exc_unexpected_error THEN

1355: fnd_msg_pub.count_and_get(
1356: p_encoded=> fnd_api.g_false,
1357: p_count=> x_msg_count,
1358: p_data=> x_msg_data);
1359: WHEN fnd_api.g_exc_unexpected_error THEN
1360: ROLLBACK TO process_approval;
1361: x_return_status := fnd_api.g_ret_sts_unexp_error;
1362: fnd_msg_pub.count_and_get(
1363: p_encoded=> fnd_api.g_false,

Line 1361: x_return_status := fnd_api.g_ret_sts_unexp_error;

1357: p_count=> x_msg_count,
1358: p_data=> x_msg_data);
1359: WHEN fnd_api.g_exc_unexpected_error THEN
1360: ROLLBACK TO process_approval;
1361: x_return_status := fnd_api.g_ret_sts_unexp_error;
1362: fnd_msg_pub.count_and_get(
1363: p_encoded=> fnd_api.g_false,
1364: p_count=> x_msg_count,
1365: p_data=> x_msg_data);

Line 1363: p_encoded=> fnd_api.g_false,

1359: WHEN fnd_api.g_exc_unexpected_error THEN
1360: ROLLBACK TO process_approval;
1361: x_return_status := fnd_api.g_ret_sts_unexp_error;
1362: fnd_msg_pub.count_and_get(
1363: p_encoded=> fnd_api.g_false,
1364: p_count=> x_msg_count,
1365: p_data=> x_msg_data);
1366: WHEN OTHERS THEN
1367: ROLLBACK TO process_approval;

Line 1368: x_return_status := fnd_api.g_ret_sts_unexp_error;

1364: p_count=> x_msg_count,
1365: p_data=> x_msg_data);
1366: WHEN OTHERS THEN
1367: ROLLBACK TO process_approval;
1368: x_return_status := fnd_api.g_ret_sts_unexp_error;
1369:
1370: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1371: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1372: END IF;

Line 1375: p_encoded=> fnd_api.g_false,

1371: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1372: END IF;
1373:
1374: fnd_msg_pub.count_and_get(
1375: p_encoded=> fnd_api.g_false,
1376: p_count=> x_msg_count,
1377: p_data=> x_msg_data);
1378: END process_approval;
1379:

Line 1417: x_return_status := fnd_api.g_ret_sts_success;

1413: l_earned_amt NUMBER;
1414: l_paid_amt NUMBER;
1415: l_fund_type VARCHAR2(20);
1416: BEGIN
1417: x_return_status := fnd_api.g_ret_sts_success;
1418:
1419: OPEN c_get_fund_amount;
1420: FETCH c_get_fund_amount INTO l_total_budget, l_committed_amt, l_utilized_amt, l_earned_amt, l_paid_amt, l_fund_type;
1421: CLOSE c_get_fund_amount;

Line 1431: x_return_status := fnd_api.g_ret_sts_error;

1427: ozf_utility_pvt.error_message('OZF_TP_QUOTA_BAN_CLOSE');
1428: ELSE
1429: ozf_utility_pvt.error_message('OZF_FUND_BAN_CLOSE');
1430: END IF;
1431: x_return_status := fnd_api.g_ret_sts_error;
1432: ELSIF l_total_budget < l_committed_amt THEN
1433: -- total < re-calculated committed This only happens when profile 'OZF_BUDGET_ADJ_ALLOW_RECAL' is 'Y'
1434: -- don't close budget because re-calculated committed has committed funds for over the pool of money originally available,
1435: -- need a budget transfer into the budget

Line 1441: x_return_status := fnd_api.g_ret_sts_error;

1437: ozf_utility_pvt.error_message('OZF_TP_QUOTA_BAN_CLOSE');
1438: ELSE
1439: ozf_utility_pvt.error_message('OZF_FUND_BAN_CLOSE_COMM_MORE');
1440: END IF;
1441: x_return_status := fnd_api.g_ret_sts_error;
1442: ELSE
1443: -- total = committed
1444: IF l_committed_amt > l_utilized_amt THEN
1445: -- total = calculated committed > utilized

Line 1452: x_return_status := fnd_api.g_ret_sts_error;

1448: ozf_utility_pvt.error_message('OZF_TP_QUOTA_BAN_CLOSE');
1449: ELSE
1450: ozf_utility_pvt.error_message('OZF_FUND_BAN_CLOSE_UTIL_LESS');
1451: END IF;
1452: x_return_status := fnd_api.g_ret_sts_error;
1453: ELSIF l_committed_amt = l_utilized_amt THEN
1454: -- total = committed = utilized
1455: IF l_utilized_amt > l_earned_amt THEN
1456: -- total = calculated committed = utilized > earned

Line 1463: x_return_status := fnd_api.g_ret_sts_error;

1459: ozf_utility_pvt.error_message('OZF_TP_QUOTA_BAN_CLOSE');
1460: ELSE
1461: ozf_utility_pvt.error_message('OZF_FUND_BAN_CLOSE_EARN_LESS');
1462: END IF;
1463: x_return_status := fnd_api.g_ret_sts_error;
1464: ELSIF l_utilized_amt = l_earned_amt THEN
1465: -- total = calculated committed = utilized = earned
1466: IF l_earned_amt > l_paid_amt THEN
1467: -- total = re-calculated committed = utilized = earned > paid

Line 1475: x_return_status := fnd_api.g_ret_sts_error;

1471: ozf_utility_pvt.error_message('OZF_TP_QUOTA_BAN_CLOSE');
1472: ELSE
1473: ozf_utility_pvt.error_message('OZF_FUND_BAN_CLOSE_PAID_LESS');
1474: END IF;
1475: x_return_status := fnd_api.g_ret_sts_error;
1476: ELSIF l_earned_amt = l_paid_amt THEN
1477: -- total = re-calculated committed = utilized = earned = paid
1478: x_return_status := fnd_api.g_ret_sts_success;
1479: END IF;

Line 1478: x_return_status := fnd_api.g_ret_sts_success;

1474: END IF;
1475: x_return_status := fnd_api.g_ret_sts_error;
1476: ELSIF l_earned_amt = l_paid_amt THEN
1477: -- total = re-calculated committed = utilized = earned = paid
1478: x_return_status := fnd_api.g_ret_sts_success;
1479: END IF;
1480: END IF;
1481: END IF;
1482: END IF;

Line 1485: x_return_status := fnd_api.g_ret_sts_unexp_error;

1481: END IF;
1482: END IF;
1483: EXCEPTION
1484: WHEN OTHERS THEN
1485: x_return_status := fnd_api.g_ret_sts_unexp_error;
1486: fnd_msg_pub.count_and_get(
1487: p_encoded => fnd_api.g_false
1488: ,p_count => x_msg_count
1489: ,p_data => x_msg_data);

Line 1487: p_encoded => fnd_api.g_false

1483: EXCEPTION
1484: WHEN OTHERS THEN
1485: x_return_status := fnd_api.g_ret_sts_unexp_error;
1486: fnd_msg_pub.count_and_get(
1487: p_encoded => fnd_api.g_false
1488: ,p_count => x_msg_count
1489: ,p_data => x_msg_data);
1490: END check_fund_before_close;
1491:

Line 1522: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1518: l_api_name CONSTANT VARCHAR2(30) := 'Update_fund_status';
1519: l_full_name CONSTANT VARCHAR2(60) := g_pkg_name ||
1520: '.' ||
1521: l_api_name;
1522: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1523: l_msg_count NUMBER;
1524: l_msg_data VARCHAR2(4000);
1525: l_old_status_code VARCHAR2(30);
1526: l_old_user_status_id NUMBER;

Line 1563: x_return_status := fnd_api.g_ret_sts_success;

1559: IF G_DEBUG THEN
1560: ozf_utility_pvt.debug_message(l_full_name ||
1561: '- enter');
1562: END IF;
1563: x_return_status := fnd_api.g_ret_sts_success;
1564: -- initiallize the out params 08/14/2001 mpande added
1565: x_submit_budget_approval := fnd_api.g_false;
1566: x_submit_child_approval := fnd_api.g_false;
1567: --Get old_status

Line 1565: x_submit_budget_approval := fnd_api.g_false;

1561: '- enter');
1562: END IF;
1563: x_return_status := fnd_api.g_ret_sts_success;
1564: -- initiallize the out params 08/14/2001 mpande added
1565: x_submit_budget_approval := fnd_api.g_false;
1566: x_submit_child_approval := fnd_api.g_false;
1567: --Get old_status
1568: OPEN l_old_status;
1569: FETCH l_old_status INTO l_old_status_code, l_old_user_status_id, l_old_owner_id, l_fund_type, l_plan_id;

Line 1566: x_submit_child_approval := fnd_api.g_false;

1562: END IF;
1563: x_return_status := fnd_api.g_ret_sts_success;
1564: -- initiallize the out params 08/14/2001 mpande added
1565: x_submit_budget_approval := fnd_api.g_false;
1566: x_submit_child_approval := fnd_api.g_false;
1567: --Get old_status
1568: OPEN l_old_status;
1569: FETCH l_old_status INTO l_old_status_code, l_old_user_status_id, l_old_owner_id, l_fund_type, l_plan_id;
1570: CLOSE l_old_status;

Line 1589: x_return_status := fnd_api.g_ret_sts_error;

1585: END IF;
1586: --return the old status
1587: x_new_status_id := l_old_user_status_id;
1588: x_new_status_code := l_old_status_code;
1589: x_return_status := fnd_api.g_ret_sts_error;
1590: ELSE
1591: x_new_status_code := p_fund_rec.status_code;
1592: x_new_status_id := p_fund_rec.user_status_id;
1593: END IF;

Line 1638: x_submit_child_approval := fnd_api.g_true;

1634: l_status_type,
1635: l_new_status_code);
1636: x_new_status_code := l_new_status_code;
1637: IF p_fund_rec.parent_fund_id IS NOT NULL THEN
1638: x_submit_child_approval := fnd_api.g_true;
1639: END IF;
1640: END IF;
1641: -- niprakas ends
1642:

Line 1650: x_submit_child_approval := fnd_api.g_true;

1646: l_status_type,
1647: l_new_status_code);
1648: x_new_status_code := l_new_status_code;
1649: IF p_fund_rec.parent_fund_id IS NOT NULL THEN
1650: x_submit_child_approval := fnd_api.g_true;
1651: END IF;
1652: ELSE
1653: /* yzhao: 01/29/2003 fix bug 2775762 MKTF1R9:1159.0127:FUNC: ACCRUAL BUDGET CANNOT GO ACTIVE
1654: for accrual budget, check if discount rule already defined

Line 1666: RAISE FND_API.g_exc_error;

1662: IF FND_MSG_PUB.check_msg_level(FND_MSG_PUB.g_msg_lvl_error) THEN
1663: FND_MESSAGE.set_name('OZF', 'OZF_OFFR_NO_DISC_LINES');
1664: FND_MSG_PUB.add;
1665: END IF;
1666: RAISE FND_API.g_exc_error;
1667: END IF;
1668: END IF;
1669: -- yzhao: 01/29/2003 fix bug 2775762 ends
1670:

Line 1680: x_submit_child_approval := fnd_api.g_true;

1676: ozf_utility_pvt.debug_message(l_full_name ||
1677: 'owner' ||
1678: p_fund_rec.owner);
1679: END IF;
1680: x_submit_child_approval := fnd_api.g_true;
1681: OPEN c_parent_fund_owner(p_fund_rec.parent_fund_id);
1682: FETCH c_parent_fund_owner INTO l_approver_id;
1683:
1684: IF (c_parent_fund_owner%NOTFOUND) THEN

Line 1692: RAISE fnd_api.g_exc_error;

1688: fnd_message.set_name('OZF', 'OZF_API_RECORD_NOT_FOUND');
1689: fnd_msg_pub.ADD;
1690: END IF;
1691:
1692: RAISE fnd_api.g_exc_error;
1693: END IF;
1694:
1695: CLOSE c_parent_fund_owner;
1696:

Line 1720: x_submit_budget_approval := fnd_api.g_true;

1716: -- the approval API would updatethe fund status to pending
1717: IF G_DEBUG THEN
1718: ozf_utility_pvt.debug_message('Approval');
1719: END IF;
1720: x_submit_budget_approval := fnd_api.g_true;
1721: x_new_status_id := ozf_utility_pvt.get_default_user_status(l_status_type, 'PENDING');
1722: x_new_status_code := 'PENDING';
1723: END IF; -- end of parent fund id check
1724: END IF; -- IF (p_fund_rec.fund_usage == 'ALLOC')

Line 1731: x_return_status := fnd_api.g_ret_sts_error;

1727: ozf_utility_pvt.error_message('OZF_FUND_WRONG_STATUS');
1728: --return the old status
1729: x_new_status_id := l_old_user_status_id;
1730: x_new_status_code := l_old_status_code;
1731: x_return_status := fnd_api.g_ret_sts_error;
1732: ELSE
1733: x_new_status_code := p_fund_rec.status_code;
1734: x_new_status_id := p_fund_rec.user_status_id;
1735: END IF; -- end for old draft

Line 1741: l_return_status := fnd_api.g_ret_sts_success;

1737: ELSIF l_old_status_code IN('ACTIVE', 'ON_HOLD') THEN
1738: IF l_new_status_code IN('CANCELLED', 'CLOSED') THEN
1739: -- 06/14/2004 yzhao: for quota, do not check remaining amount before closing
1740: IF l_fund_type = 'QUOTA' THEN
1741: l_return_status := fnd_api.g_ret_sts_success;
1742: ELSE
1743: check_fund_before_close( p_fund_id => p_fund_rec.fund_id
1744: , x_return_status => l_return_status
1745: , x_msg_count => l_msg_count

Line 1748: IF l_return_status = fnd_api.g_ret_sts_success THEN

1744: , x_return_status => l_return_status
1745: , x_msg_count => l_msg_count
1746: , x_msg_data => l_msg_data);
1747: END IF;
1748: IF l_return_status = fnd_api.g_ret_sts_success THEN
1749: x_new_status_code := p_fund_rec.status_code;
1750: x_new_status_id := p_fund_rec.user_status_id;
1751: ELSE
1752: -- can not close budget, return the old status

Line 1755: x_return_status := fnd_api.g_ret_sts_error;

1751: ELSE
1752: -- can not close budget, return the old status
1753: x_new_status_id := l_old_user_status_id;
1754: x_new_status_code := l_old_status_code;
1755: x_return_status := fnd_api.g_ret_sts_error;
1756: END IF;
1757:
1758: -- 05/11/2003 niprakas added the else loop for the bug#2950428
1759: ELSIF l_new_status_code IN('ACTIVE') THEN

Line 1770: x_return_status := fnd_api.g_ret_sts_error;

1766: ozf_utility_pvt.error_message('OZF_FUND_WRONG_STATUS');
1767: -- return the old status
1768: x_new_status_id := l_old_user_status_id;
1769: x_new_status_code := l_old_status_code;
1770: x_return_status := fnd_api.g_ret_sts_error;
1771: END IF;
1772: -- 01/20/2003 yzhao bug 2532491 ends
1773:
1774: ELSE

Line 1798: x_return_status := fnd_api.g_ret_sts_success;

1794: IF l_resource_id = l_old_owner_id
1795: OR ams_access_pvt.check_admin_access(l_resource_id) THEN
1796: x_new_status_id := l_old_user_status_id;
1797: x_new_status_code := l_old_status_code;
1798: x_return_status := fnd_api.g_ret_sts_success;
1799: ELSE
1800: --ozf_utility_pvt.error_message('OZF_FUND_BAN_UPDATE');
1801: IF l_fund_type = 'QUOTA' THEN
1802: ozf_utility_pvt.error_message('OZF_TP_QUOTA_UPDT_OWNER_PERM');

Line 1809: x_return_status := fnd_api.g_ret_sts_error;

1805: END IF;
1806: --return the old status
1807: x_new_status_id := l_old_user_status_id;
1808: x_new_status_code := l_old_status_code;
1809: x_return_status := fnd_api.g_ret_sts_error;
1810: END IF;
1811: /*
1812: ELSIF p_fund_rec.fund_type = 'FULLY_ACCRUED' THEN
1813: x_new_status_id := l_old_user_status_id;

Line 1815: x_return_status := fnd_api.g_ret_sts_success;

1811: /*
1812: ELSIF p_fund_rec.fund_type = 'FULLY_ACCRUED' THEN
1813: x_new_status_id := l_old_user_status_id;
1814: x_new_status_code := l_old_status_code;
1815: x_return_status := fnd_api.g_ret_sts_success;
1816: */
1817: ELSE
1818: x_new_status_code := p_fund_rec.status_code;
1819: x_new_status_id := p_fund_rec.user_status_id;

Line 1820: x_return_status := fnd_api.g_ret_sts_success;

1816: */
1817: ELSE
1818: x_new_status_code := p_fund_rec.status_code;
1819: x_new_status_id := p_fund_rec.user_status_id;
1820: x_return_status := fnd_api.g_ret_sts_success;
1821: END IF;
1822: ELSE
1823: x_new_status_code := p_fund_rec.status_code;
1824: x_new_status_id := p_fund_rec.user_status_id;

Line 1832: WHEN fnd_api.g_exc_error THEN

1828: ozf_utility_pvt.debug_message(l_full_name ||
1829: ': end');
1830: END IF;
1831: EXCEPTION
1832: WHEN fnd_api.g_exc_error THEN
1833: ROLLBACK TO update_fund_status;
1834: x_return_status := fnd_api.g_ret_sts_error;
1835: fnd_msg_pub.count_and_get(
1836: p_encoded=> fnd_api.g_false,

Line 1834: x_return_status := fnd_api.g_ret_sts_error;

1830: END IF;
1831: EXCEPTION
1832: WHEN fnd_api.g_exc_error THEN
1833: ROLLBACK TO update_fund_status;
1834: x_return_status := fnd_api.g_ret_sts_error;
1835: fnd_msg_pub.count_and_get(
1836: p_encoded=> fnd_api.g_false,
1837: p_count=> x_msg_count,
1838: p_data=> x_msg_data);

Line 1836: p_encoded=> fnd_api.g_false,

1832: WHEN fnd_api.g_exc_error THEN
1833: ROLLBACK TO update_fund_status;
1834: x_return_status := fnd_api.g_ret_sts_error;
1835: fnd_msg_pub.count_and_get(
1836: p_encoded=> fnd_api.g_false,
1837: p_count=> x_msg_count,
1838: p_data=> x_msg_data);
1839: WHEN fnd_api.g_exc_unexpected_error THEN
1840: ROLLBACK TO update_fund_status;

Line 1839: WHEN fnd_api.g_exc_unexpected_error THEN

1835: fnd_msg_pub.count_and_get(
1836: p_encoded=> fnd_api.g_false,
1837: p_count=> x_msg_count,
1838: p_data=> x_msg_data);
1839: WHEN fnd_api.g_exc_unexpected_error THEN
1840: ROLLBACK TO update_fund_status;
1841: x_return_status := fnd_api.g_ret_sts_unexp_error;
1842: fnd_msg_pub.count_and_get(
1843: p_encoded=> fnd_api.g_false,

Line 1841: x_return_status := fnd_api.g_ret_sts_unexp_error;

1837: p_count=> x_msg_count,
1838: p_data=> x_msg_data);
1839: WHEN fnd_api.g_exc_unexpected_error THEN
1840: ROLLBACK TO update_fund_status;
1841: x_return_status := fnd_api.g_ret_sts_unexp_error;
1842: fnd_msg_pub.count_and_get(
1843: p_encoded=> fnd_api.g_false,
1844: p_count=> x_msg_count,
1845: p_data=> x_msg_data);

Line 1843: p_encoded=> fnd_api.g_false,

1839: WHEN fnd_api.g_exc_unexpected_error THEN
1840: ROLLBACK TO update_fund_status;
1841: x_return_status := fnd_api.g_ret_sts_unexp_error;
1842: fnd_msg_pub.count_and_get(
1843: p_encoded=> fnd_api.g_false,
1844: p_count=> x_msg_count,
1845: p_data=> x_msg_data);
1846: WHEN OTHERS THEN
1847: ROLLBACK TO update_fund_status;

Line 1848: x_return_status := fnd_api.g_ret_sts_unexp_error;

1844: p_count=> x_msg_count,
1845: p_data=> x_msg_data);
1846: WHEN OTHERS THEN
1847: ROLLBACK TO update_fund_status;
1848: x_return_status := fnd_api.g_ret_sts_unexp_error;
1849:
1850: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1851: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1852: END IF;

Line 1855: p_encoded=> fnd_api.g_false,

1851: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1852: END IF;
1853:
1854: fnd_msg_pub.count_and_get(
1855: p_encoded=> fnd_api.g_false,
1856: p_count=> x_msg_count,
1857: p_data=> x_msg_data);
1858: END update_fund_status;
1859:

Line 1906: x_return_status := fnd_api.g_ret_sts_success;

1902: ozf_utility_pvt.debug_message(l_full_name ||
1903: ': begin');
1904: END IF;
1905: SAVEPOINT process_accrual;
1906: x_return_status := fnd_api.g_ret_sts_success;
1907:
1908: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1909: RAISE fnd_api.g_exc_unexpected_error;
1910: END IF;

Line 1908: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

1904: END IF;
1905: SAVEPOINT process_accrual;
1906: x_return_status := fnd_api.g_ret_sts_success;
1907:
1908: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1909: RAISE fnd_api.g_exc_unexpected_error;
1910: END IF;
1911:
1912: -- dbms_OUTPUT.put_line('FUND ID ' ||

Line 1909: RAISE fnd_api.g_exc_unexpected_error;

1905: SAVEPOINT process_accrual;
1906: x_return_status := fnd_api.g_ret_sts_success;
1907:
1908: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1909: RAISE fnd_api.g_exc_unexpected_error;
1910: END IF;
1911:
1912: -- dbms_OUTPUT.put_line('FUND ID ' ||
1913: -- p_fund_rec.fund_id ||

Line 1931: IF l_return_status = fnd_api.g_ret_sts_error THEN

1927: x_msg_count=> l_msg_count,
1928: x_msg_data=> l_msg_data,
1929: x_return_status=> l_return_status);
1930:
1931: IF l_return_status = fnd_api.g_ret_sts_error THEN
1932: RAISE fnd_api.g_exc_error;
1933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1934: RAISE fnd_api.g_exc_unexpected_error;
1935: END IF;

Line 1932: RAISE fnd_api.g_exc_error;

1928: x_msg_data=> l_msg_data,
1929: x_return_status=> l_return_status);
1930:
1931: IF l_return_status = fnd_api.g_ret_sts_error THEN
1932: RAISE fnd_api.g_exc_error;
1933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1934: RAISE fnd_api.g_exc_unexpected_error;
1935: END IF;
1936:

Line 1933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

1929: x_return_status=> l_return_status);
1930:
1931: IF l_return_status = fnd_api.g_ret_sts_error THEN
1932: RAISE fnd_api.g_exc_error;
1933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1934: RAISE fnd_api.g_exc_unexpected_error;
1935: END IF;
1936:
1937: EXCEPTION

Line 1934: RAISE fnd_api.g_exc_unexpected_error;

1930:
1931: IF l_return_status = fnd_api.g_ret_sts_error THEN
1932: RAISE fnd_api.g_exc_error;
1933: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1934: RAISE fnd_api.g_exc_unexpected_error;
1935: END IF;
1936:
1937: EXCEPTION
1938: WHEN fnd_api.g_exc_error THEN

Line 1938: WHEN fnd_api.g_exc_error THEN

1934: RAISE fnd_api.g_exc_unexpected_error;
1935: END IF;
1936:
1937: EXCEPTION
1938: WHEN fnd_api.g_exc_error THEN
1939: ROLLBACK TO process_accrual;
1940: x_return_status := fnd_api.g_ret_sts_error;
1941: fnd_msg_pub.count_and_get(
1942: p_encoded=> fnd_api.g_false,

Line 1940: x_return_status := fnd_api.g_ret_sts_error;

1936:
1937: EXCEPTION
1938: WHEN fnd_api.g_exc_error THEN
1939: ROLLBACK TO process_accrual;
1940: x_return_status := fnd_api.g_ret_sts_error;
1941: fnd_msg_pub.count_and_get(
1942: p_encoded=> fnd_api.g_false,
1943: p_count=> x_msg_count,
1944: p_data=> x_msg_data);

Line 1942: p_encoded=> fnd_api.g_false,

1938: WHEN fnd_api.g_exc_error THEN
1939: ROLLBACK TO process_accrual;
1940: x_return_status := fnd_api.g_ret_sts_error;
1941: fnd_msg_pub.count_and_get(
1942: p_encoded=> fnd_api.g_false,
1943: p_count=> x_msg_count,
1944: p_data=> x_msg_data);
1945: WHEN fnd_api.g_exc_unexpected_error THEN
1946: ROLLBACK TO process_accrual;

Line 1945: WHEN fnd_api.g_exc_unexpected_error THEN

1941: fnd_msg_pub.count_and_get(
1942: p_encoded=> fnd_api.g_false,
1943: p_count=> x_msg_count,
1944: p_data=> x_msg_data);
1945: WHEN fnd_api.g_exc_unexpected_error THEN
1946: ROLLBACK TO process_accrual;
1947: x_return_status := fnd_api.g_ret_sts_unexp_error;
1948: fnd_msg_pub.count_and_get(
1949: p_encoded=> fnd_api.g_false,

Line 1947: x_return_status := fnd_api.g_ret_sts_unexp_error;

1943: p_count=> x_msg_count,
1944: p_data=> x_msg_data);
1945: WHEN fnd_api.g_exc_unexpected_error THEN
1946: ROLLBACK TO process_accrual;
1947: x_return_status := fnd_api.g_ret_sts_unexp_error;
1948: fnd_msg_pub.count_and_get(
1949: p_encoded=> fnd_api.g_false,
1950: p_count=> x_msg_count,
1951: p_data=> x_msg_data);

Line 1949: p_encoded=> fnd_api.g_false,

1945: WHEN fnd_api.g_exc_unexpected_error THEN
1946: ROLLBACK TO process_accrual;
1947: x_return_status := fnd_api.g_ret_sts_unexp_error;
1948: fnd_msg_pub.count_and_get(
1949: p_encoded=> fnd_api.g_false,
1950: p_count=> x_msg_count,
1951: p_data=> x_msg_data);
1952: WHEN OTHERS THEN
1953: ROLLBACK TO process_accrual;

Line 1954: x_return_status := fnd_api.g_ret_sts_unexp_error;

1950: p_count=> x_msg_count,
1951: p_data=> x_msg_data);
1952: WHEN OTHERS THEN
1953: ROLLBACK TO process_accrual;
1954: x_return_status := fnd_api.g_ret_sts_unexp_error;
1955:
1956: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1957: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1958: END IF;

Line 1961: p_encoded=> fnd_api.g_false,

1957: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1958: END IF;
1959:
1960: fnd_msg_pub.count_and_get(
1961: p_encoded=> fnd_api.g_false,
1962: p_count=> x_msg_count,
1963: p_data=> x_msg_data);
1964: END process_accrual;
1965: END ozf_fundrules_pvt;