Each transaction type's create_from_json (and possibly update_from_json) method should delegate where possible to it's superclass.
So Transaction.create_from_json would set the :memo and :flag; CashTransaction.create_from_json would set the :amount, PayeeCashTransaction.create_from_json would set the :header etc..
Each transaction type's
create_from_json
(and possiblyupdate_from_json
) method should delegate where possible to it's superclass.So
Transaction.create_from_json
would set the :memo and :flag;CashTransaction.create_from_json
would set the :amount,PayeeCashTransaction.create_from_json
would set the :header etc..