Skip to Content

Refund

  • Code: PUR-RF
  • Module: Purchasing
  • Type: Transaction

1. Overview

A Refund is the record of money actually returned by a supplier to the store against a Credit Note. A Refund stands in relation to a Credit Note exactly as a payment stands in relation to a bill: where a payment records money going out from the store to the supplier, a Refund records money coming in from the supplier to the store. Every Refund states the person in charge who received the money and may be accompanied by proof. A Refund has no page of its own — it is recorded and read from inside the detail of its parent Credit Note.

Expected outcome: “the supplier recognizes the credit” and “the supplier has returned the money” become two separate facts that are both visible, so the remaining credit still hanging with the supplier is always a figure, not an estimate.

2. Problem

Without recording Refunds, a Credit Note can only state that the supplier recognizes credit, without being able to state whether the money has come back. The two things get mixed into one, even though in practice they are often weeks apart and frequently paid in installments. As a result:

  • Credit that has been paid out and credit still hanging read the same, so finance staff chase suppliers who have actually already paid.
  • Installment returns cannot be recorded, so staff record them outside the system and the figures never match.
  • There is no limit keeping the amount of money recorded as received from exceeding the credit the supplier recognizes.
  • It is unclear who received the money from the supplier and what the proof is, so cash differences are hard to trace.

3. Goals & Non-goals

3.1 Goals

  • Money returned by a supplier is recorded as an event of its own, whether in full or in installments, and may happen more than once for one Credit Note.
  • The remaining credit is always calculated from the difference between the Credit Note value and the money already received, so there are never two figures that contradict each other.
  • The amount of money recorded as received never exceeds the credit the supplier recognizes.
  • Every Refund has a clear person in charge, and its proof is stored attached to its record.
  • Typing mistakes can be cleaned up without leaving false figures in the remaining credit or the Credit Note status.

3.2 Non-goals

  • Replacement goods from the supplier; those come in through the Purchase Order and Goods Receipt flow, not Refunds.
  • Deducting the remaining credit from a later bill; that is the Credit Note’s business and has not been built.
  • Automatic reconciliation against bank account transactions.
  • Expiry rules for credit that is never returned.
  • Correcting the amount of a Refund already recorded; one that is wrong is deleted, not edited.

4. Business Rules

Business rules are the set of provisions and constraints that apply to Refunds throughout the application, on every screen and action that involves it, whoever performs it. These rules are the single source of truth: if another part of this PRD appears to differ, the rules here prevail.

  • BR-01 A Refund can only be recorded on a Credit Note in Submitted or Partially Refunded status. A Draft Credit Note is rejected because its credit has not been recognized yet, and a Refunded Credit Note is rejected because its credit has already been returned in full.
  • BR-02 The amount of every Refund must be greater than zero with at most 2 decimal places, and the sum of all Refunds on one Credit Note must not exceed the Credit Note Total. This limit is checked against the unrounded Credit Note Total before a new Refund is accepted.
  • BR-03 The Remaining Credit is derived from the Credit Note Total minus the sum of all Refunds. If stored, its value is only a copy recalculated from all remaining Refunds by the single writer, never partially added to or subtracted from. Every time a Refund is recorded, the Credit Note status becomes Partially Refunded if the Remaining Credit is still above zero, or Refunded if the Remaining Credit is zero. A Credit Note Total with more than 2 decimal places cannot reach a Remaining Credit of zero through 2-decimal Refunds, so a remainder below Rp 0.01 keeps the Credit Note Partially Refunded; how to settle it Needs confirmation.
  • BR-04 Partial Refunds are allowed, and one Credit Note may have more than one Refund, limited only by BR-02.
  • BR-05 A Credit Note that never receives a Refund is a legitimate state and is not considered an error; it means the supplier is still holding the credit.
  • BR-06 A Refund is Submitted from the moment it is recorded, and its content cannot be changed afterwards, except the Person in Charge. The amount, method, time, note, and proof stay fixed; the Person in Charge may be corrected by a holder of the assign permission in any Credit Note status, because correcting who handled the money is not a movement of money. Recording a Refund means declaring that the money has come in, not submitting a proposal to be approved.
  • BR-07 A Refund recorded incorrectly is deleted, not corrected, including on a Credit Note that is already Refunded. Deletion requires a reason, and a deleted Refund stays stored as an uncounted, hidden trace, not gone. Deleting means the money never actually came in: the Remaining Credit is recalculated, then the Credit Note status becomes Partially Refunded if Refunds remain, or returns to Submitted if there are none left.
  • BR-08 Every recording, deletion, and Person in Charge change of a Refund is recorded in the activity log of its parent Credit Note along with the actor, time, and the reason for deletion.
  • BR-09 The Refund amount limit is checked against the Credit Note’s state at save time, not against the figure shown on screen. Recording and deleting Refunds on the same Credit Note are processed one at a time, so two simultaneous recordings cannot both pass if their sum exceeds the Credit Note Total, and the status and Remaining Credit are always calculated from the Refunds that actually remain. Deleting a Refund that has already been deleted changes nothing.
  • BR-10 Every Refund must state at least one person in charge from the Credit Note store’s employees, namely the person who received or handled the money from the supplier.
  • BR-11 A Refund may attach proof of return as more than one file, or attach nothing; attachments are only evidence and do not affect the Remaining Credit or status. At most 10 files, each at most 2 MB, of type PDF, JPG, JPEG, PNG, or WEBP.
  • BR-12 Resubmitting the same Refund recording, due to a double click or a dropped connection, never produces a second Refund. Every form submission carries a unique marker, and a marker already accepted for the same Credit Note returns the Refund already recorded.

5. Flow

5.1 Main Flowchart

  1. Credit Note in Submitted or Partially Refunded status — A Refund can only be recorded on a Credit Note whose credit has been recognized and is not yet settled (BR-01). The details are explained in a separate PRD.
  2. Record Refund — Finance staff fill in the date, method, the amount of money received from the supplier, and the person in charge, and may attach proof (BR-10, BR-11).
  3. Validate Amount — The new amount plus all earlier Refunds is checked against the Credit Note Total. Anything exceeding the limit is rejected before saving (BR-02, BR-09).
  4. Submitted — The only Refund status, set from the moment of recording. Its content can no longer be changed (BR-06).
  5. Recalculate Remaining Credit and Credit Note Status — Every time a Refund is recorded or deleted, the Remaining Credit on the Credit Note is recalculated from the difference between its total and all Refunds still recorded, then the Credit Note status is set again (BR-03, BR-07).
  6. Remaining Credit? — The calculation result determines the Credit Note’s next status.
  7. Credit Note Submitted — No Refunds remain recorded because all have been deleted; the Credit Note returns to how it was when newly submitted (BR-07).
  8. Credit Note Partially Refunded — Credit remains, and further Refunds can still be recorded (BR-04).
  9. Credit Note Refunded — The remaining credit is used up, so the Credit Note stops accepting new Refunds.
  10. Deleted — A Refund recorded incorrectly is deleted along with its reason, from a Credit Note that is Partially Refunded or Refunded, then the Remaining Credit and Credit Note status are recalculated as in step 5 (BR-07).

5.2 Status Lifecycle

StatusDescriptionNext
Submitted
submitted
The money has been received from the supplier and counts as reducing the Remaining Credit—

A Refund has no Draft or Cancelled status: one recorded incorrectly is deleted, not moved to another status (BR-06, BR-07).

6. Document Structure

This section defines the content of the Refund document itself: which fields it has, their type, which are required, their initial values, and their value rules. The provisions here apply wherever the Refund is recorded and are enforced on save, regardless of how the field is displayed. A Refund has no product lines and no calculations of its own; its derived figure is the Remaining Credit calculated on the Credit Note.

6.1 General

FieldTypeRequiredDefaultRules
Refund NumberText—Generated on saveSet by the system in the format RFD/{Store Code}/{Year}/{000000}, cannot be changed
Credit NoteRef. Credit Note—The Credit Note the Refund is recorded onSet by the system; must be in Submitted or Partially Refunded status (BR-01)
StoreRef. Store—The Credit Note’s storeSet by the system, cannot be changed
Refund Date & TimeDate & TimeYesNow—
Refund MethodEnumYes—Cash, Bank Transfer, Giro, Credit Card, or Other
Refund AmountCurrencyYesThe Credit Note’s Remaining CreditGreater than 0, at most 2 decimal places, and not exceeding the Remaining Credit (BR-02)
Person in ChargeRef. Employee, multipleYesThe logged-in user’s employee record, if they are an employee of the Credit Note’s storeAt least one employee of the Credit Note’s store (BR-10)
Refund ProofFile, multipleNo—Images or documents, for example proof of transfer; at most 10 files, 2 MB each, PDF/JPG/JPEG/PNG/WEBP (BR-11)
NotesTextNo——
Deletion ReasonTextYes, when deleted—Required on the Delete action (BR-07)
StatusEnum—SubmittedSet by the system; see Status Lifecycle

7. UI Structure

This section defines how Refunds are displayed and operated. A Refund has no list page, filters, or PDF of its own: its entire surface lives inside the Refunds tab on the Credit Note detail, and reading it follows the view Credit Note detail permission. This section only governs display and interaction; content and value rules still follow Document Structure.

7.1 Refund Card

ColumnSample ValueComponent
TitleRefund 1Text
Refund NumberRFD/CBI/2026/000031Text
Refund Date & Time24 Sep 2026, 10:15Date
Refund MethodBank TransferBadge
Refund AmountRp 200,000Currency
Person in ChargeAndi, SariText
Refund Prooftransfer-proof.jpgThumbnail, Link
NotesReceived in the store’s bank accountText
ActionsDeleteAction Menu

7.2 Form

FieldControlOptions SourceBehavior
Refund Date & TimeDate Time Picker—Defaults to now
Refund MethodSingle SelectRefund method enum—
Refund AmountCurrency Input—Defaults to the Remaining Credit; exceeding the Remaining Credit → error on the field
Person in ChargeMulti SelectThe Credit Note store’s employeesDefaults to the logged-in user’s employee record, if they are an employee of that store
Refund ProofFile Uploader, multiple—Optional
NotesTextarea——

The form opens as a dialog from the Add Refund button in the Refunds tab, and that button only appears while the Credit Note is in Submitted or Partially Refunded status. The Save button is disabled while saving is in progress.

7.3 Delete Dialog

FieldControlOptions SourceBehavior
Deletion ReasonTextarea—Empty → the confirm button is disabled

8. User Stories

US-01 - Record a full refund

As finance staff, I want to record the return of money equal to the whole credit note value, so that the credit is closed and no longer appears as a claim against the supplier.

IDAcceptance criteria
AC-01.1The Add Refund button only appears on Credit Notes in Submitted or Partially Refunded status for users with the create permission in the active store (BR-01).
AC-01.2The Refund amount is filled in by default with the Remaining Credit truncated to 2 decimal places, and can be changed to a smaller value (BR-02).
AC-01.3The form requires the date & time, method, amount, and at least one person in charge (default the logged-in user); refund proof and notes are optional (BR-10, BR-11).
AC-01.4After saving, the Refund is immediately Submitted and the Remaining Credit becomes Rp 0 (BR-03, BR-06).
AC-01.5The Credit Note moves to Refunded status without a separate action, and the Add Refund button disappears (BR-03).

US-02 - Record a partial refund

As finance staff, I want to record installment returns, so that money already received is visible without waiting for the supplier to settle everything.

IDAcceptance criteria
AC-02.1After the Refund is saved, the Remaining Credit equals the Credit Note Total minus the sum of all Refunds (BR-03).
AC-02.2The Credit Note moves to Partially Refunded status without a separate action as long as the Remaining Credit is still above zero (BR-03).
AC-02.3A second, third, and further Refund can still be recorded as long as their total stays within the limit (BR-02, BR-04).
AC-02.4Each Refund appears as its own card in order of the time it was recorded, along with its person in charge and proof preview.

US-03 - Reject refunds exceeding the remaining credit

As the system, I want to reject a Refund whose amount exceeds the remaining credit, so that the money recorded as received is never greater than the credit the supplier recognizes.

IDAcceptance criteria
AC-03.1A Refund is rejected when its new amount plus all earlier Refunds exceeds the Credit Note Total, before saving (BR-02).
AC-03.2The error message appears on the Refund Amount field, not as a general page error.
AC-03.3A Refund on a Credit Note in Draft or Refunded status is rejected (BR-01).
AC-03.4A Refund amount of zero or negative is rejected (BR-02).
AC-03.5A Refund without a person in charge is rejected (BR-10).
AC-03.6Two Refunds are recorded on the same Credit Note at the same time — only one passes if their sum exceeds the Credit Note Total (BR-09).
AC-03.7The same form is submitted twice due to a double click or dropped connection — only one Refund is recorded, and the second submission shows the Refund that already exists (BR-12).
AC-03.8A Refund is recorded at the same time as another Refund on the same Credit Note is deleted — both are processed in sequence, and the final Remaining Credit and status match the Refunds that actually remain (BR-03, BR-09).

US-04 - Leave credit without a refund

As finance staff, I want a Credit Note without a Refund to still be considered normal, so that credit the supplier deliberately holds is not read as a data error.

IDAcceptance criteria
AC-04.1A Credit Note with its full Remaining Credit and no Refund stays valid and in Submitted status with no time limit (BR-05).
AC-04.2The Refunds tab appears empty with the Remaining Credit summary still filled in.

US-05 - Delete a refund recorded incorrectly

As finance staff, I want to delete a Refund with a typing mistake, so that the remaining credit and the Credit Note status return to the correct state.

IDAcceptance criteria
AC-05.1The Delete action is available on every Refund card for users with the delete permission in the active store, including on a Credit Note in Refunded status; the confirmation dialog requires a deletion reason (BR-07).
AC-05.2After deletion, the Remaining Credit is recalculated without that Refund (BR-03, BR-07).
AC-05.3Other Refunds are still recorded — the Credit Note is in Partially Refunded status and can receive Refunds again (BR-07).
AC-05.4No other Refunds are recorded — the Credit Note returns to Submitted status (BR-07).
AC-05.5A Refund’s amount, method, time, note, and proof cannot be changed; the only correction is to delete and record again (BR-06).
AC-05.6The deletion, its reason, and the Credit Note status transition are recorded in the Credit Note’s activity log along with the actor and time (BR-08).
AC-05.7The same Refund is deleted twice, for example due to a double click — the second deletion changes neither the Remaining Credit nor the status (BR-09).
AC-05.8A deleted Refund no longer appears as a card and is not counted, but can still be traced through the Credit Note’s activity log (BR-07).
AC-05.9A user with the assign permission in the active store can change the Person in Charge of a Refund, including on a Credit Note in Refunded status; the choices are limited to the Credit Note store’s employees, and the change is recorded in the Credit Note’s activity log (BR-06, BR-08, BR-10).

9. User Scenarios

RoleScenario
Finance StaffReceives a transfer from the supplier for the whole value of the Credit Note, records it as one Refund with the proof of transfer attached, and sees the Credit Note move by itself to Refunded
Finance StaffRecords two cash returns from the supplier’s salesperson during two different visits on the same Credit Note, with the cashier who received the money as the person in charge
Finance StaffMistypes the amount on the settlement Refund, deletes it so the Credit Note returns to Partially Refunded, then records it again with the correct figure
OwnerSees a two-month-old Credit Note without a single Refund, then asks finance staff to chase the supplier

10. Permissions & Actions

10.1 Permission by Action

ActionPermissionCondition
View Refund—Follows the view Credit Note detail permission
Record Refundpurchase:refund:create:storeStore is active
Change Person in Chargepurchase:refund:assign:storeStore is active
Download Refund Proof—Follows the view Credit Note detail permission
Delete Refundpurchase:refund:delete:storeStore is active

There are no separate list and view permissions: Refunds are read through their parent Credit Note, not from a list page. There are no submit or update permissions: recording a Refund already means submitting it (BR-06), and its content cannot be changed except the Person in Charge, which uses the assign permission.

10.2 Action by Status

ActionSubmitted
View Refund✓
Download Refund Proof✓
Change Person in Charge✓
Delete Refund✓

Record Refund is not in this matrix because it depends on the parent Credit Note’s status, not the Refund’s status; see Action by Status in Credit Note. A Refund’s activity log is read from its parent Credit Note’s log (BR-08).

11. Notifications

This feature does not trigger any notifications.

12. Dependencies

Related PRDs

  • Credit Note — the mandatory parent, the determinant of the Refund amount limit, where the Remaining Credit is calculated, and the document whose status follows the Refunds (BR-01, BR-02, BR-03, BR-07).
  • Purchase Return — an indirect relation: a Return whose Credit Note has been submitted cannot be cancelled, so a Refund never loses its parent.

Master data

  • Stores — the active store, active status, and employees (persons in charge) (BR-10).
  • File Manager — storage for attached refund proof (BR-11).

Effects on other modules

  • Credit Note — the Remaining Credit decreases when a Refund is recorded and is recalculated when it is deleted; the Credit Note moves between Submitted, Partially Refunded, and Refunded because of it (BR-03, BR-07).
  • A Refund does not change stock, does not change any Bill, and does not change any Return.
  • Finance — the Refund amount becomes the basis for matching money coming in from suppliers.
  • Every recording and deletion is recorded in the Credit Note’s activity log (BR-08).
Last updated on