blob: daad4c25d2f6aa3fe06822755f9e12b4db24d728 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
{-# LANGUAGE DeriveGeneric #-}
module Model.Json.Category
( Category(..)
) where
import GHC.Generics
import Data.Aeson
import Data.Text (Text)
import Model.Database (CategoryId)
data Category = Category
{ id :: CategoryId
, name :: Text
, color :: Text
} deriving (Show, Generic)
instance ToJSON Category
|