diff --git a/src/ZGoBackend.hs b/src/ZGoBackend.hs index 72968f8..d32c0da 100644 --- a/src/ZGoBackend.hs +++ b/src/ZGoBackend.hs @@ -649,7 +649,7 @@ routes pipe config = do let invReq = payload (invData :: Payload XeroInvoiceRequest) case cast' . Doc =<< xeroConfig of Nothing -> do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= (1 :: Integer) @@ -660,7 +660,7 @@ routes pipe config = do o <- liftAndCatchIO $ run $ findOwnerById $ xr_owner invReq case cast' . Doc =<< o of Nothing -> do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= (2 :: Integer) @@ -679,7 +679,7 @@ routes pipe config = do oaddress o' case resInv of Nothing -> do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= (2 :: Integer) @@ -701,7 +701,7 @@ routes pipe config = do T.unpack . ocurrency $ o') case cast' . Doc =<< pr of Nothing -> do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= @@ -755,7 +755,7 @@ routes pipe config = do text "Unable to save order to DB" Just fO -> do - status ok200 + status created201 Web.Scotty.json (object [ "reportType" .= @@ -766,7 +766,7 @@ routes pipe config = do , "shop" .= oname o' ]) else do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= @@ -777,7 +777,7 @@ routes pipe config = do (Nothing :: Maybe String) ]) else do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= (7 :: Integer) @@ -786,7 +786,7 @@ routes pipe config = do , "shop" .= (Nothing :: Maybe String) ]) else do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= (6 :: Integer) @@ -794,7 +794,7 @@ routes pipe config = do , "shop" .= (Nothing :: Maybe String) ]) else do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= (5 :: Integer) @@ -802,7 +802,7 @@ routes pipe config = do , "shop" .= (Nothing :: Maybe String) ]) else do - status noContent204 + status ok200 Web.Scotty.json (object [ "reportType" .= (1 :: Integer)