diff options
Diffstat (limited to 'common/src/Common/Model')
-rw-r--r-- | common/src/Common/Model/EditPayment.hs | 3 | ||||
-rw-r--r-- | common/src/Common/Model/SavedPayment.hs (renamed from common/src/Common/Model/CreatedPayment.hs) | 14 |
2 files changed, 9 insertions, 8 deletions
diff --git a/common/src/Common/Model/EditPayment.hs b/common/src/Common/Model/EditPayment.hs index d2c223f..8860b84 100644 --- a/common/src/Common/Model/EditPayment.hs +++ b/common/src/Common/Model/EditPayment.hs @@ -2,7 +2,7 @@ module Common.Model.EditPayment ( EditPayment(..) ) where -import Data.Aeson (FromJSON) +import Data.Aeson (FromJSON, ToJSON) import Data.Text (Text) import Data.Time.Calendar (Day) import GHC.Generics (Generic) @@ -21,3 +21,4 @@ data EditPayment = EditPayment } deriving (Show, Generic) instance FromJSON EditPayment +instance ToJSON EditPayment diff --git a/common/src/Common/Model/CreatedPayment.hs b/common/src/Common/Model/SavedPayment.hs index c1bba29..f45c479 100644 --- a/common/src/Common/Model/CreatedPayment.hs +++ b/common/src/Common/Model/SavedPayment.hs @@ -1,5 +1,5 @@ -module Common.Model.CreatedPayment - ( CreatedPayment(..) +module Common.Model.SavedPayment + ( SavedPayment(..) ) where import Data.Aeson (FromJSON, ToJSON) @@ -8,10 +8,10 @@ import GHC.Generics (Generic) import Common.Model.Payment (Payment) import Common.Model.PaymentCategory (PaymentCategory) -data CreatedPayment = CreatedPayment - { _createdPayment_payment :: Payment - , _createdPayment_paymentCategory :: PaymentCategory +data SavedPayment = SavedPayment + { _savedPayment_payment :: Payment + , _savedPayment_paymentCategory :: PaymentCategory } deriving (Show, Generic) -instance FromJSON CreatedPayment -instance ToJSON CreatedPayment +instance FromJSON SavedPayment +instance ToJSON SavedPayment |