DBA Data[Home] [Help]

APPS.PA_BILL_PCT dependencies on PA_BILLING

Line 128: PA_MCB_INVOICE_PKG.log_message('Before pa_billing_extn_params_v select pa_bill_pct.calc_pct_comp_amt :');

124: END IF;
125: /** gets the cost and revenue budget amounts **/
126:
127: IF g1_debug_mode = 'Y' THEN
128: PA_MCB_INVOICE_PKG.log_message('Before pa_billing_extn_params_v select pa_bill_pct.calc_pct_comp_amt :');
129: END IF;
130: /* Added for bug 2649456.Not handling exception intentionaly because if it is coming,
131: it will be data issue */
132: BEGIN

Line 135: FROM pa_billing_extn_params_v;

131: it will be data issue */
132: BEGIN
133: SELECT default_cost_plan_type_id,default_rev_plan_type_id
134: INTO l_cost_plan_type_id,l_rev_plan_type_id
135: FROM pa_billing_extn_params_v;
136: EXCEPTION
137: WHEN OTHERS THEN
138: IF g1_debug_mode = 'Y' THEN
139: PA_MCB_INVOICE_PKG.log_message('Error from pa_billing_extn_params_v pa_bill_pct.calc_pct_comp_amt :'||SQLERRM);

Line 139: PA_MCB_INVOICE_PKG.log_message('Error from pa_billing_extn_params_v pa_bill_pct.calc_pct_comp_amt :'||SQLERRM);

135: FROM pa_billing_extn_params_v;
136: EXCEPTION
137: WHEN OTHERS THEN
138: IF g1_debug_mode = 'Y' THEN
139: PA_MCB_INVOICE_PKG.log_message('Error from pa_billing_extn_params_v pa_bill_pct.calc_pct_comp_amt :'||SQLERRM);
140: END IF;
141: RAISE;
142: END;
143: /* till here */

Line 190: PA_MCB_INVOICE_PKG.log_message('before calling pa_billing_amount.LowestAmountLeft inside pa_bill_pct.calc_pct_comp_amt :');

186: /** Get the amount left based on the hard limit set for the projects
187: customers **/
188:
189: IF g1_debug_mode = 'Y' THEN
190: PA_MCB_INVOICE_PKG.log_message('before calling pa_billing_amount.LowestAmountLeft inside pa_bill_pct.calc_pct_comp_amt :');
191: END IF;
192: Amount_Left := pa_billing_amount.LowestAmountLeft(
193: X_project_id,
194: X_top_task_id,

Line 192: Amount_Left := pa_billing_amount.LowestAmountLeft(

188:
189: IF g1_debug_mode = 'Y' THEN
190: PA_MCB_INVOICE_PKG.log_message('before calling pa_billing_amount.LowestAmountLeft inside pa_bill_pct.calc_pct_comp_amt :');
191: END IF;
192: Amount_Left := pa_billing_amount.LowestAmountLeft(
193: X_project_id,
194: X_top_task_id,
195: X_calling_process);
196:

Line 298: pa_billing_pub.insert_event (

294: IF g1_debug_mode = 'Y' THEN
295: PA_MCB_INVOICE_PKG.log_message('rev part inside pa_bill_pct.calc_pct_comp_amt event desc :'||Event_Description);
296: PA_MCB_INVOICE_PKG.log_message('rev part Before calling insert_event inside pa_bill_pct.calc_pct_comp_amt Revenue :');
297: END IF;
298: pa_billing_pub.insert_event (
299: X_rev_amt => Revenue,
300: X_bill_amt => 0,
301: X_event_description => event_description,
302: X_audit_amount1 => amount_left,

Line 379: pa_billing_pub.insert_event (

375: IF g1_debug_mode = 'Y' THEN
376: PA_MCB_INVOICE_PKG.log_message('Inv part inside pa_bill_pct.calc_pct_comp_amt event desc :'||Event_Description);
377: PA_MCB_INVOICE_PKG.log_message('Inv part Before insert event inside pa_bill_pct.calc_pct_comp_amt Invoice :');
378: END IF;
379: pa_billing_pub.insert_event (
380: X_rev_amt => 0,
381: X_bill_amt => Invoice,
382: X_event_description => Event_Description,
383: X_audit_amount1 => amount_left,

Line 495: from pa_billing_assignments bea,

491: AND e.project_id = X2_project_id
492: AND nvl(e.task_id,0) = nvl(X2_task_id, nvl(e.task_id,0))
493: AND e.completion_date <= nvl(X2_accrue_through_date, sysdate)
494: AND NOT EXISTS ( select '1'
495: from pa_billing_assignments bea,
496: pa_billing_extensions be
497: where be.billing_extension_id = bea.billing_extension_id
498: and bea.billing_assignment_id = e.billing_assignment_id
499: and be.procedure_name = 'pa_bill_pct.calc_pct_comp_amt');

Line 496: pa_billing_extensions be

492: AND nvl(e.task_id,0) = nvl(X2_task_id, nvl(e.task_id,0))
493: AND e.completion_date <= nvl(X2_accrue_through_date, sysdate)
494: AND NOT EXISTS ( select '1'
495: from pa_billing_assignments bea,
496: pa_billing_extensions be
497: where be.billing_extension_id = bea.billing_extension_id
498: and bea.billing_assignment_id = e.billing_assignment_id
499: and be.procedure_name = 'pa_bill_pct.calc_pct_comp_amt');
500:

Line 523: from pa_billing_assignments bea,

519: AND e.project_id = X2_project_id
520: AND nvl(e.task_id,0) = nvl(X2_task_id, nvl(e.task_id,0))
521: AND e.completion_date <= nvl(X2_accrue_through_date, sysdate)
522: AND NOT EXISTS ( select '1'
523: from pa_billing_assignments bea,
524: pa_billing_extensions be
525: where be.billing_extension_id = bea.billing_extension_id
526: and bea.billing_assignment_id = e.billing_assignment_id
527: and be.procedure_name = 'pa_bill_pct.calc_pct_comp_amt'); */

Line 524: pa_billing_extensions be

520: AND nvl(e.task_id,0) = nvl(X2_task_id, nvl(e.task_id,0))
521: AND e.completion_date <= nvl(X2_accrue_through_date, sysdate)
522: AND NOT EXISTS ( select '1'
523: from pa_billing_assignments bea,
524: pa_billing_extensions be
525: where be.billing_extension_id = bea.billing_extension_id
526: and bea.billing_assignment_id = e.billing_assignment_id
527: and be.procedure_name = 'pa_bill_pct.calc_pct_comp_amt'); */
528:

Line 531: l_calling_process := pa_billing.GetCallProcess;

527: and be.procedure_name = 'pa_bill_pct.calc_pct_comp_amt'); */
528:
529: /* Following code has been added for MCB2 */
530: l_project_id := X2_project_id;
531: l_calling_process := pa_billing.GetCallProcess;
532: PA_MULTI_CURRENCY_BILLING.get_project_defaults (
533: p_project_id => l_project_id,
534: x_multi_currency_billing_flag => l_multi_currency_billing_flag,
535: x_baseline_funding_flag => l_baseline_funding_flag,

Line 563: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetPaDate);

559: l_projfunc_currency_code,l_projfunc_rate_type,
560: l_projfunc_rate_date,l_projfunc_exchange_rate;
561: EXIT WHEN pctfunc_rev_inv_amt%NOTFOUND;
562: IF ( l_calling_process = 'Revenue' ) THEN
563: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetPaDate);
564: l_passd_amt := l_trans_rev_amt;
565: ELSIF ( l_calling_process = 'Invoice' ) THEN
566: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetInvoiceDate);
567: l_passd_amt := l_trans_bill_amt;

Line 566: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetInvoiceDate);

562: IF ( l_calling_process = 'Revenue' ) THEN
563: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetPaDate);
564: l_passd_amt := l_trans_rev_amt;
565: ELSIF ( l_calling_process = 'Invoice' ) THEN
566: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetInvoiceDate);
567: l_passd_amt := l_trans_bill_amt;
568: END IF;
569: /* Calling convert amount proc to convert this amount in PFC */
570: PA_MULTI_CURRENCY.convert_amount(

Line 666: pa_billing_assignments bea,

662: CURSOR pctfunc_revenue(X2_project_id Number,X2_task_id Number) IS
663: SELECT NVL(e.bill_trans_rev_amount,0) trans_rev_amount,e.bill_trans_currency_code,
664: e.projfunc_currency_code,e.projfunc_rate_type,e.projfunc_rate_date,e.projfunc_exchange_rate
665: FROM pa_events e,
666: pa_billing_assignments bea,
667: pa_billing_extensions be
668: where be.billing_extension_id = bea.billing_extension_id
669: and e.project_id = X2_project_id
670: and nvl(e.task_id,0) =

Line 667: pa_billing_extensions be

663: SELECT NVL(e.bill_trans_rev_amount,0) trans_rev_amount,e.bill_trans_currency_code,
664: e.projfunc_currency_code,e.projfunc_rate_type,e.projfunc_rate_date,e.projfunc_exchange_rate
665: FROM pa_events e,
666: pa_billing_assignments bea,
667: pa_billing_extensions be
668: where be.billing_extension_id = bea.billing_extension_id
669: and e.project_id = X2_project_id
670: and nvl(e.task_id,0) =
671: decode(X2_task_id,

Line 692: pa_billing_assignments bea,

688: AND nvl(dri.task_id,0) = decode(X2_task_id, NULL, nvl(dri.task_id,0), X2_task_id )
689: AND (EXISTS ( select '1'
690: from pa_cust_event_rev_dist_lines erdl,
691: pa_events e,
692: pa_billing_assignments bea,
693: pa_billing_extensions be
694: where be.billing_extension_id = bea.billing_extension_id
695: and bea.billing_assignment_id = e.billing_assignment_id
696: and e.project_id = erdl.project_id

Line 693: pa_billing_extensions be

689: AND (EXISTS ( select '1'
690: from pa_cust_event_rev_dist_lines erdl,
691: pa_events e,
692: pa_billing_assignments bea,
693: pa_billing_extensions be
694: where be.billing_extension_id = bea.billing_extension_id
695: and bea.billing_assignment_id = e.billing_assignment_id
696: and e.project_id = erdl.project_id
697: and e.event_num = erdl.event_num

Line 717: pa_billing_assignments bea,

713: /*
714: SELECT sum(nvl(e.revenue_amount,0))
715: INTO pending_pctrev
716: FROM pa_events e,
717: pa_billing_assignments bea,
718: pa_billing_extensions be
719: where be.billing_extension_id = bea.billing_extension_id
720: and e.project_id = X2_project_id
721: and nvl(e.task_id,0) =

Line 718: pa_billing_extensions be

714: SELECT sum(nvl(e.revenue_amount,0))
715: INTO pending_pctrev
716: FROM pa_events e,
717: pa_billing_assignments bea,
718: pa_billing_extensions be
719: where be.billing_extension_id = bea.billing_extension_id
720: and e.project_id = X2_project_id
721: and nvl(e.task_id,0) =
722: decode(X2_task_id,

Line 761: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetPaDate);

757: FETCH pctfunc_revenue INTO l_trans_rev_amt,l_txn_currency_code,l_projfunc_currency_code,
758: l_projfunc_rate_type,l_projfunc_rate_date,l_projfunc_exchange_rate;
759: EXIT WHEN pctfunc_revenue%NOTFOUND;
760: IF ( l_project_bil_rate_date_code = 'PA_INVOICE_DATE' ) THEN
761: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetPaDate);
762: END IF;
763:
764: /* Calling convert amount proc to convert this amount in PFC */
765: PA_MULTI_CURRENCY.convert_amount(

Line 857: pa_billing_assignments bea,

853: CURSOR pctfunc_invoice(X2_project_id Number,X2_task_id Number) IS
854: SELECT NVL(e.bill_trans_bill_amount,0) trans_bill_amount,e.bill_trans_currency_code,e.projfunc_currency_code,
855: e.projfunc_rate_type,e.projfunc_rate_date,e.projfunc_exchange_rate
856: FROM pa_events e,
857: pa_billing_assignments bea,
858: pa_billing_extensions be
859: WHERE be.billing_extension_id = bea.billing_extension_id
860: AND bea.billing_assignment_id = e.billing_assignment_id
861: AND e.project_id = X2_project_id

Line 858: pa_billing_extensions be

854: SELECT NVL(e.bill_trans_bill_amount,0) trans_bill_amount,e.bill_trans_currency_code,e.projfunc_currency_code,
855: e.projfunc_rate_type,e.projfunc_rate_date,e.projfunc_exchange_rate
856: FROM pa_events e,
857: pa_billing_assignments bea,
858: pa_billing_extensions be
859: WHERE be.billing_extension_id = bea.billing_extension_id
860: AND bea.billing_assignment_id = e.billing_assignment_id
861: AND e.project_id = X2_project_id
862: AND be.procedure_name = 'pa_bill_pct.calc_pct_comp_amt'

Line 885: pa_billing_assignments bea,

881: /*
882: SELECT sum(nvl(e.bill_amount,0))
883: INTO pending_ccinv
884: from pa_events e,
885: pa_billing_assignments bea,
886: pa_billing_extensions be
887: where be.billing_extension_id = bea.billing_extension_id
888: and bea.billing_assignment_id = e.billing_assignment_id
889: and e.project_id = X2_project_id

Line 886: pa_billing_extensions be

882: SELECT sum(nvl(e.bill_amount,0))
883: INTO pending_ccinv
884: from pa_events e,
885: pa_billing_assignments bea,
886: pa_billing_extensions be
887: where be.billing_extension_id = bea.billing_extension_id
888: and bea.billing_assignment_id = e.billing_assignment_id
889: and e.project_id = X2_project_id
890: and be.procedure_name = 'pa_bill_pct.calc_pct_comp_amt'

Line 933: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetInvoiceDate);

929: FETCH pctfunc_invoice INTO l_trans_bill_amt,l_txn_currency_code,l_projfunc_currency_code,
930: l_projfunc_rate_type,l_projfunc_rate_date,l_projfunc_exchange_rate;
931: EXIT WHEN pctfunc_invoice%NOTFOUND;
932: IF ( l_project_bil_rate_date_code = 'PA_INVOICE_DATE' ) THEN
933: l_projfunc_rate_date := NVL(l_projfunc_rate_date,pa_billing.GetInvoiceDate);
934: END IF;
935: /* Calling convert amount proc to convert this amount in PFC */
936: PA_MULTI_CURRENCY.convert_amount(
937: P_FROM_CURRENCY => l_txn_currency_code,

Line 974: pa_billing_assignments bea,

970: FROM pa_draft_invoice_items dii
971: WHERE dii.project_id = X2_project_id
972: AND (EXISTS (select '1'
973: from pa_events e,
974: pa_billing_assignments bea,
975: pa_billing_extensions be
976: where be.billing_extension_id = bea.billing_extension_id
977: and bea.billing_assignment_id = e.billing_assignment_id
978: and dii.project_id = e.project_id

Line 975: pa_billing_extensions be

971: WHERE dii.project_id = X2_project_id
972: AND (EXISTS (select '1'
973: from pa_events e,
974: pa_billing_assignments bea,
975: pa_billing_extensions be
976: where be.billing_extension_id = bea.billing_extension_id
977: and bea.billing_assignment_id = e.billing_assignment_id
978: and dii.project_id = e.project_id
979: and dii.event_num = e.event_num

Line 1019: pa_billing_assignments bea,

1015: WHERE pdii.event_task_id = X2_task_id
1016: AND pdii.Project_ID = X2_Project_ID -- Perf Bug 2695332
1017: AND EXISTS (select '1'
1018: from pa_events e,
1019: pa_billing_assignments bea,
1020: pa_billing_extensions be
1021: where be.billing_extension_id = bea.billing_extension_id
1022: and bea.billing_assignment_id = e.billing_assignment_id
1023: and pdii.project_id = e.project_id

Line 1020: pa_billing_extensions be

1016: AND pdii.Project_ID = X2_Project_ID -- Perf Bug 2695332
1017: AND EXISTS (select '1'
1018: from pa_events e,
1019: pa_billing_assignments bea,
1020: pa_billing_extensions be
1021: where be.billing_extension_id = bea.billing_extension_id
1022: and bea.billing_assignment_id = e.billing_assignment_id
1023: and pdii.project_id = e.project_id
1024: and pdii.event_num = e.event_num

Line 1176: FROM pa_billing_extensions

1172: DECODE(P_rev_plan_type_id,NULL,default_rev_plan_type_id,
1173: P_rev_plan_type_id) /* Added for fin plan type id */
1174: INTO l_rev_budget_type_code,
1175: l_rev_plan_type_id
1176: FROM pa_billing_extensions
1177: WHERE billing_extension_id=pa_billing.GetBillingExtensionId;
1178:
1179: IF g1_debug_mode = 'Y' THEN
1180: PA_MCB_INVOICE_PKG.log_message(' getting l_rev_budget_type_code inside pa_bill_pct.get_rev_budget_amount: '||l_rev_budget_type_code);

Line 1177: WHERE billing_extension_id=pa_billing.GetBillingExtensionId;

1173: P_rev_plan_type_id) /* Added for fin plan type id */
1174: INTO l_rev_budget_type_code,
1175: l_rev_plan_type_id
1176: FROM pa_billing_extensions
1177: WHERE billing_extension_id=pa_billing.GetBillingExtensionId;
1178:
1179: IF g1_debug_mode = 'Y' THEN
1180: PA_MCB_INVOICE_PKG.log_message(' getting l_rev_budget_type_code inside pa_bill_pct.get_rev_budget_amount: '||l_rev_budget_type_code);
1181: END IF;

Line 1286: status := pa_billing_values.get_message('INVALID_REV_BUDGET_TYPE');

1282: PA_MCB_INVOICE_PKG.log_message(' Exiting pa_bill_pct.get_rev_budget_amount: ');
1283: END IF;
1284: EXCEPTION
1285: WHEN invalid_rev_budget_code THEN
1286: status := pa_billing_values.get_message('INVALID_REV_BUDGET_TYPE');
1287: l_status := 2;
1288: RAISE_APPLICATION_ERROR(-20101,status);
1289: WHEN rev_budget_not_baselined THEN
1290: status := pa_billing_values.get_message('REV_BUDGET_NOT_BASELINED');

Line 1290: status := pa_billing_values.get_message('REV_BUDGET_NOT_BASELINED');

1286: status := pa_billing_values.get_message('INVALID_REV_BUDGET_TYPE');
1287: l_status := 2;
1288: RAISE_APPLICATION_ERROR(-20101,status);
1289: WHEN rev_budget_not_baselined THEN
1290: status := pa_billing_values.get_message('REV_BUDGET_NOT_BASELINED');
1291: l_status := 3;
1292: RAISE_APPLICATION_ERROR(-20101,status);
1293: WHEN OTHERS THEN
1294: status := substr(SQLERRM,1,240);

Line 1311: pa_billing_pub.insert_message

1307:
1308: X_error_message := status;
1309: X_status := l_status;
1310:
1311: pa_billing_pub.insert_message
1312: (X_inserting_procedure_name =>'pa_billing_pct.get_rev_budget_amount',
1313: X_attribute2 => l_rev_budget_type_code,
1314: X_message => status,
1315: X_error_message=>err_msg,

Line 1312: (X_inserting_procedure_name =>'pa_billing_pct.get_rev_budget_amount',

1308: X_error_message := status;
1309: X_status := l_status;
1310:
1311: pa_billing_pub.insert_message
1312: (X_inserting_procedure_name =>'pa_billing_pct.get_rev_budget_amount',
1313: X_attribute2 => l_rev_budget_type_code,
1314: X_message => status,
1315: X_error_message=>err_msg,
1316: X_status=>err_status);