FAS Refunds - Send back left over routing slip funds via Liabilities
Zac/Karen discussion - Refund Authorized is expected to flip to Refund Completed via a back end process. System change needed to refund RS against the original RS GL code (dynamic)
From our meeting:
There is apparently a supplier "override"
Feed the persons address and name in CAS
It might be possible to fill these in with values Karen has provided:


Acceptable to use the same STOB that the original charge used
Solves refunding the whole routing slip back when it’s all been spent Refunding when there is a balance remaining
Lisa says to recognize this instance as a liability STOB 3000 AP General 3200000 Blank Project code
https://github.com/bcgov/sbc-pay/blob/main/docs/docs/architecture/FAS_Intgeration.md
Scaling this down, I have a feeling it's just the liability we have to refund, which consists of a few minor changes, but still left high, because there is a feedback file.. and requires a bit of domain knowledge to figure out.
In addition to this ticket, it may require some review to look at a few of the routing slips that have been flipped from REFUND_AUTHORIZED -> REFUND_REQUESTED
It looks like none of the routing slips have invoices applied to them, due to the routing slip job not running.
Some of them have unapplied_amounts, others don't. I think this needs to be fixed before we can go forward with the next step.
~1. Implement void functionality for routing slips~ ~2. Use part of void functionality for correcting routing slips (OPS only workflow)~ ~3. Recreate the data in CAS (it's messed up because the payment jobs didn't run for months, applied / unapplied amounts and no invoices applied). There are no PUT or PATCH methods to fix a routing slip (apparently by design, to prevent fraud). I've worked around this by including a CAS_VERSION field in the routing_slip table.~ ~4. Establish a baseline with Karen at finance to close Routing Slips that are manually refunded (so we don't have double refunds) This has been done, hopefully will receive it sometime tomorrow~ ~5. Fix all of the refund data~ 6. Fix the AP refund job
Karen is looking at the already refunded routing slips, she has a list hopefully she'll send over tomorrow. After we get this list, we can attempt doing the refunds in PRODUCTION.
We're also a bit blocked until we get the FAS credentials working again in TEST.
Working on a notebook that can look at all routing slips and compare them in FAS.
After that I'll probably restore the state in PAY, and correct them using the UI (if possible).
After that.. Working on the AP Refund job! YAY
Finished the child task. Working on the AP refund job now.
Running the job, waiting for feedback now
Looks like 2/240 refunds failed. I'll have to talk to Tara, and figure out why they failed.
Moving to done, will create another ticket for these two errors. I've done some analysis and it doesn't look like anything glaring.