Correct OwnerData

This commit is contained in:
Rene Vergara 2023-05-10 10:42:40 -05:00
parent d67d1937f5
commit 55d30b8b0f
Signed by: pitmutt
GPG key ID: 65122AD495A7F5B2
2 changed files with 5 additions and 1 deletions

View file

@ -289,6 +289,7 @@ data OwnerData =
, od_email :: T.Text , od_email :: T.Text
, od_website :: T.Text , od_website :: T.Text
, od_phone :: T.Text , od_phone :: T.Text
, od_payconf :: Bool
} }
deriving (Eq, Show) deriving (Eq, Show)
@ -306,7 +307,8 @@ instance FromJSON OwnerData where
e <- obj .: "email" e <- obj .: "email"
w <- obj .: "website" w <- obj .: "website"
ph <- obj .: "phone" ph <- obj .: "phone"
pure $ OwnerData f l n s c st p co e w ph pc <- obj .: "payconf"
pure $ OwnerData f l n s c st p co e w ph pc
-- Database actions -- Database actions
-- | Function to upsert an Owner -- | Function to upsert an Owner

View file

@ -932,6 +932,7 @@ routes pipe config = do
, "zats" .= ozats q , "zats" .= ozats q
, "invoices" .= oinvoices q , "invoices" .= oinvoices q
, "expiration" .= oexpiration q , "expiration" .= oexpiration q
, "payconf" .= opayconf q
, "crmToken" .= ocrmToken q , "crmToken" .= ocrmToken q
] ]
]) ])
@ -963,6 +964,7 @@ routes pipe config = do
, "zats" .= ozats q , "zats" .= ozats q
, "invoices" .= oinvoices q , "invoices" .= oinvoices q
, "expiration" .= oexpiration q , "expiration" .= oexpiration q
, "payconf" .= opayconf q
, "crmToken" .= ocrmToken q , "crmToken" .= ocrmToken q
] ]
]) ])