update model coin_change

This commit is contained in:
wyx 2020-07-25 12:17:46 +08:00
parent 0f69255422
commit 0ebcf3d7f7
1 changed files with 3 additions and 0 deletions

View File

@ -1,2 +1,5 @@
class CoinChange < ApplicationRecord
belongs_to :to_wallet, class_name: 'Wallet'
belongs_to :from_wallet, class_name: 'Wallet'
validates :amount, presence: true
end