Hi,
We had a Custom Payment module made for a particular bank.

After we upgraded and made some changes we face the following problem.

If order is is worth $100 (example), customer uses gift certificate of $20, the amount shown on the Banks payment page is $80 .

However when customer returns to our website, the order page does not show the calculation of the $20 gift certificate nor it is deleted from the Database.
The order total shown is $100 itself, however you can see we received payment of $80.

Please suggest what could we look into.