C1-RF-VALID
This algorithm is invoked when the user clicks the Validate button. It validates the records which are in the Pending status. It validates the following:
-
The account ID given in the record is valid.
Note: If the account ID is invalid, it derives the account ID using the respective account identifier type and account identifier combination. Once the account ID is derived, the corresponding record is updated in the C1_UPLOAD_REQ_DTLS table. If the system could not derive the account ID using the account identifier type and account identifier combination, the status of the record in the C1_UPLOAD_REQ_DTLS table is changed to Invalid. -
The entity type is a valid and active value of the REF_WO_ENTITY_FLG lookup field.
-
The entity type given in the record for the entity ID is correct.
-
The entity (i.e., adjustment, bill, bill segment, payment event, or payment) exists for the respective account in the system.
-
The payment ID given in the record is in the Frozen status and is matched against the suspense or excess credit contract.
-
The bill ID given in the record is in the Complete status.
-
The bill segment ID given in the record is in the Frozen status.
-
The adjustment ID given in the record is in the Freezable or Frozen status.
-
The refund request type given in the record is valid and in the Active status. Its action flag is set to Refund.
-
The refund amount is greater than zero.
-
The refund amount is not greater than the eligible refund amount and the eligible refund amount is not equal to zero.
-
The adjustment type given in the record is valid and its A/P Request Type Code flag is set to Refund.
-
One record with a bill (for example, B01) and another record with the bill segment (for example, BS01) or adjustment (for example, AD01) of the same bill (i.e., B01) are not present in the upload request.
-
One record with a payment event (for example, PE01) and another record with the payment (for example, PY01) of the same payment event (i.e., PE01) are not present in the upload request.
-
The amount matches the decimal positions of the respective currency.
-
The entity is not already included in any refund request that is in the non-final status.
-
The characteristic type given in the record is valid and its characteristic entity is set to Refund/Write Off Request.
-
The adhoc characteristic values are validated as per the validations defined in the respective algorithm.
-
The predefined characteristic value is already defined for the characteristic type.
-
The foreign key reference characteristic value is valid.
-
The two or more records with the same entity type and entity ID combination do not exist in the upload request.
Note: If duplicate records exist in the upload request, it validates and changes the status of one record to Valid and the status of the remaining records to Invalid.
If any of above validations fail, the status of the record in the C1_UPLOAD_REQ_DTLS table is changed to Invalid. However, if all the above validations are successful, the status of the record in the C1_UPLOAD_REQ_DTLS table is changed to Valid. Once all the pending records in the upload request are validated, the status of the upload request is changed to Validated.
