diff options
Diffstat (limited to 'common/src')
-rw-r--r-- | common/src/Common/Model.hs | 1 | ||||
-rw-r--r-- | common/src/Common/Model/CreatedPayment.hs | 17 |
2 files changed, 18 insertions, 0 deletions
diff --git a/common/src/Common/Model.hs b/common/src/Common/Model.hs index b0e0491..64db890 100644 --- a/common/src/Common/Model.hs +++ b/common/src/Common/Model.hs @@ -2,6 +2,7 @@ module Common.Model (module X) where import Common.Model.Category as X import Common.Model.CreateCategory as X +import Common.Model.CreatedPayment as X import Common.Model.CreateIncome as X import Common.Model.CreatePayment as X import Common.Model.Currency as X diff --git a/common/src/Common/Model/CreatedPayment.hs b/common/src/Common/Model/CreatedPayment.hs new file mode 100644 index 0000000..c1bba29 --- /dev/null +++ b/common/src/Common/Model/CreatedPayment.hs @@ -0,0 +1,17 @@ +module Common.Model.CreatedPayment + ( CreatedPayment(..) + ) where + +import Data.Aeson (FromJSON, ToJSON) +import GHC.Generics (Generic) + +import Common.Model.Payment (Payment) +import Common.Model.PaymentCategory (PaymentCategory) + +data CreatedPayment = CreatedPayment + { _createdPayment_payment :: Payment + , _createdPayment_paymentCategory :: PaymentCategory + } deriving (Show, Generic) + +instance FromJSON CreatedPayment +instance ToJSON CreatedPayment |