diff options
Diffstat (limited to 'src/server/Main.hs')
-rw-r--r-- | src/server/Main.hs | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/server/Main.hs b/src/server/Main.hs index 5524ba7..9946961 100644 --- a/src/server/Main.hs +++ b/src/server/Main.hs @@ -11,7 +11,6 @@ import MonthlyPaymentJob (monthlyPaymentJobListener) import Data.Text (Text) import qualified Data.Text.IO as T -import Data.Time.Clock.POSIX (posixSecondsToUTCTime) import Controller.Index import Controller.SignIn @@ -63,10 +62,7 @@ main = do get "/incomes" getIncomes - post "/income" $ do - creation <- param "creation" :: ActionM Int - amount <- param "amount" :: ActionM Int - addIncome (posixSecondsToUTCTime $ (fromIntegral creation) / 1000) amount + post "/income" $ jsonData >>= addIncome delete "/income" $ do incomeId <- param "id" :: ActionM Text |