diff options
-rw-r--r-- | spec/src/Thermoprint/API.hs | 4 | ||||
-rw-r--r-- | spec/src/Thermoprint/Identifiers.hs | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/spec/src/Thermoprint/API.hs b/spec/src/Thermoprint/API.hs index 6c86008..00115f3 100644 --- a/spec/src/Thermoprint/API.hs +++ b/spec/src/Thermoprint/API.hs | |||
@@ -52,10 +52,10 @@ data JobStatus = Queued PrinterId | |||
52 | | Printing PrinterId | 52 | | Printing PrinterId |
53 | | Done | 53 | | Done |
54 | | Failed PrintingError | 54 | | Failed PrintingError |
55 | deriving (Generic, Show, FromJSON, ToJSON) | 55 | deriving (Generic, Show, Read, FromJSON, ToJSON) |
56 | 56 | ||
57 | data PrintingError = UnknownError | 57 | data PrintingError = UnknownError |
58 | deriving (Typeable, Generic, Show, FromJSON, ToJSON, Exception) | 58 | deriving (Typeable, Generic, Show, Read, FromJSON, ToJSON, Exception) |
59 | 59 | ||
60 | type DraftTitle = Text | 60 | type DraftTitle = Text |
61 | 61 | ||
diff --git a/spec/src/Thermoprint/Identifiers.hs b/spec/src/Thermoprint/Identifiers.hs index a2609a4..ee35e24 100644 --- a/spec/src/Thermoprint/Identifiers.hs +++ b/spec/src/Thermoprint/Identifiers.hs | |||
@@ -12,13 +12,13 @@ import Servant.API (ToText, FromText) | |||
12 | import Data.Aeson (FromJSON, ToJSON) | 12 | import Data.Aeson (FromJSON, ToJSON) |
13 | 13 | ||
14 | newtype PrinterId = PrinterId Integer | 14 | newtype PrinterId = PrinterId Integer |
15 | deriving (Show, Eq, Ord, Num, Real, Integral, Enum, FromText, ToText, FromJSON, ToJSON) | 15 | deriving (Show, Read, Eq, Ord, Num, Real, Integral, Enum, FromText, ToText, FromJSON, ToJSON) |
16 | 16 | ||
17 | newtype JobId = JobId Integer | 17 | newtype JobId = JobId Integer |
18 | deriving (Show, Eq, Ord, Num, Real, Integral, Enum, FromText, ToText, FromJSON, ToJSON) | 18 | deriving (Show, Read, Eq, Ord, Num, Real, Integral, Enum, FromText, ToText, FromJSON, ToJSON) |
19 | 19 | ||
20 | newtype DraftId = DraftId Integer | 20 | newtype DraftId = DraftId Integer |
21 | deriving (Show, Eq, Ord, Num, Real, Integral, Enum, FromText, ToText, FromJSON, ToJSON) | 21 | deriving (Show, Read, Eq, Ord, Num, Real, Integral, Enum, FromText, ToText, FromJSON, ToJSON) |
22 | 22 | ||
23 | castId :: (Integral a, Enum b) => a -> b | 23 | castId :: (Integral a, Enum b) => a -> b |
24 | castId = toEnum . fromInteger . toInteger | 24 | castId = toEnum . fromInteger . toInteger |