solidus icon indicating copy to clipboard operation
solidus copied to clipboard

Refund created for uncompleted payments

Open bitberry-dev opened this issue 7 years ago • 1 comments

Steps to reproduce

  1. Create order with check payment method.
  2. Create refund in admin -> order -> payments. 2018-10-26 17 55 34

Expected behavior

I expect error when creating refund from uncompleted payment. Also do not show refund icon for uncompleted payments and do not run refunds#new action.

Actual behavior

Refund created for payment in "invalid" state. 2018-10-26 17 55 58

System configuration

Solidus Version:

"2.8.0.alpha" master, latest commit 622aa25e6c351c4de16af87e9cba70de596ad959

Is this the right behavior? If not I can fix it. Also refund model doesn't validate amount on updates.

bitberry-dev avatar Oct 26 '18 15:10 bitberry-dev

I don't think it is expected, it does not make sense to refund a payment that never happened. Feel free to submit a patch, thanks!

kennyadsl avatar Oct 26 '18 16:10 kennyadsl