DBA Data[Home] [Help]

APPS.AP_CHECKS_PKG dependencies on AP_PAYMENT_HISTORY

Line 1231: -- ap_payment_history table.

1227:
1228: -- We need to check if the payment is being matured/unmatured during this
1229: -- updated, i.e. if the status_lookup_code is going from ISSUED to MATURED
1230: -- or vice-versa. If yes, then we want to insert/delete a row in the
1231: -- ap_payment_history table.
1232: -- I am putting the logic to figure out NOCOPY if the status has changed in this
1233: -- procedure because it is too messy and bug prone to put it in the form.
1234: -- Some of the issues are - we will need to track the previous and new value
1235: -- of the displayed field and then retrieve the lookup_codes to figure out NOCOPY

Line 1258: debug_info := 'Insert row in Ap_Payment_History for payment maturity';

1254:
1255: If (l_old_status_lookup_code = 'ISSUED' AND
1256: X_status_lookup_code = 'NEGOTIABLE')
1257: Then
1258: debug_info := 'Insert row in Ap_Payment_History for payment maturity';
1259: ap_reconciliation_pkg.recon_payment_history
1260: (X_CHECKRUN_ID => NULL,
1261: X_CHECK_ID => X_check_id,
1262: X_TRANSACTION_TYPE => 'PAYMENT MATURITY',

Line 1287: debug_info := 'Delete maturity row from ap_payment_history';

1283: X_CALLING_SEQUENCE => current_calling_sequence);
1284: Elsif (l_old_status_lookup_code = 'NEGOTIABLE' AND
1285: X_status_lookup_code = 'ISSUED')
1286: Then
1287: debug_info := 'Delete maturity row from ap_payment_history';
1288: ap_reconciliation_pkg.recon_payment_history
1289: (X_CHECKRUN_ID => NULL,
1290: X_CHECK_ID => X_check_id,
1291: X_TRANSACTION_TYPE => 'PAYMENT MATURITY REVERSAL',

Line 1539: -- ap_payment_history for this payment with posted_flag = 'Y'.

1535:
1536: -----------------------------------------------------------------------
1537: -- Function is_maturity_accounted returns TRUE if the maturity event
1538: -- has been accounted for, i.e. a PAYMENT MATURITY row exists in
1539: -- ap_payment_history for this payment with posted_flag = 'Y'.
1540: -- Otherwise it returns a FALSE.
1541: --
1542: FUNCTION is_maturity_accounted(X_check_id IN NUMBER,
1543: X_calling_sequence IN VARCHAR2)

Line 1553: debug_info := 'Selecting from ap_payment_history';

1549: -- Update the calling sequence
1550: --
1551: current_calling_sequence := 'AP_CHECKS_PKG.is_maturity_accounted<-' ||
1552: X_calling_sequence;
1553: debug_info := 'Selecting from ap_payment_history';
1554: SELECT count(*)
1555: INTO l_num_accounted_pay_hist
1556: FROM ap_payment_history
1557: WHERE check_id = X_check_id

Line 1556: FROM ap_payment_history

1552: X_calling_sequence;
1553: debug_info := 'Selecting from ap_payment_history';
1554: SELECT count(*)
1555: INTO l_num_accounted_pay_hist
1556: FROM ap_payment_history
1557: WHERE check_id = X_check_id
1558: AND transaction_type = 'PAYMENT MATURITY'
1559: AND posted_flag = 'Y';
1560:

Line 1583: -- ap_payment_history for this payment.

1579:
1580: -----------------------------------------------------------------------
1581: -- Function is_payment_matured returns TRUE if the maturity event
1582: -- has been created, i.e. a PAYMENT MATURITY row exists in
1583: -- ap_payment_history for this payment.
1584: -- Otherwise it returns a FALSE.
1585: --
1586: FUNCTION is_payment_matured(X_check_id IN NUMBER,
1587: X_calling_sequence IN VARCHAR2)

Line 1597: debug_info := 'Selecting from ap_payment_history';

1593: -- Update the calling sequence
1594: --
1595: current_calling_sequence := 'AP_CHECKS_PKG.is_payment_matured<-' ||
1596: X_calling_sequence;
1597: debug_info := 'Selecting from ap_payment_history';
1598: SELECT count(*)
1599: INTO l_num_pay_hist
1600: FROM ap_payment_history
1601: WHERE check_id = X_check_id

Line 1600: FROM ap_payment_history

1596: X_calling_sequence;
1597: debug_info := 'Selecting from ap_payment_history';
1598: SELECT count(*)
1599: INTO l_num_pay_hist
1600: FROM ap_payment_history
1601: WHERE check_id = X_check_id
1602: AND transaction_type = 'PAYMENT MATURITY';
1603:
1604: If (l_num_pay_hist = 0)

Line 1648: -- ap_invoice_payments and ap_payment_history. Previously, the cursor

1644: -- are unposted (N). The status should be partial (P).
1645: --
1646:
1647: -- Fix for 1375672. Modified the cursor to select the posted_flag from
1648: -- ap_invoice_payments and ap_payment_history. Previously, the cursor
1649: -- selected the cash_posted_flag and accrual_posted_flag (depending upon
1650: -- the accounting option) from ap_invoice_payments only, ignoring
1651: -- the ap_payment_history table.
1652:

Line 1651: -- the ap_payment_history table.

1647: -- Fix for 1375672. Modified the cursor to select the posted_flag from
1648: -- ap_invoice_payments and ap_payment_history. Previously, the cursor
1649: -- selected the cash_posted_flag and accrual_posted_flag (depending upon
1650: -- the accounting option) from ap_invoice_payments only, ignoring
1651: -- the ap_payment_history table.
1652:
1653: -- bug 3676049 Posting status of check is irrespective of Payment Maturity
1654: -- when Payment Accounting = 'CLEARING ONLY'
1655: CURSOR posting_cursor IS

Line 1661: FROM ap_payment_history aph, ap_system_parameters asp

1657: FROM ap_invoice_payments_all
1658: WHERE check_id = l_check_id
1659: UNION ALL
1660: SELECT posted_flag
1661: FROM ap_payment_history aph, ap_system_parameters asp
1662: WHERE check_id = l_check_id
1663: AND nvl(aph.org_id, -99) = nvl(asp.org_id, -99)
1664: AND (nvl(asp.when_to_account_pmt, 'ALWAYS') = 'ALWAYS' or
1665: (nvl(asp.when_to_account_pmt, 'ALWAYS') = 'CLEARING ONLY' and