diff --git a/Handler/Avatar.hs b/Handler/Avatar.hs index ecfa8bc..9b7f748 100644 --- a/Handler/Avatar.hs +++ b/Handler/Avatar.hs @@ -25,7 +25,8 @@ postNewAvatarR = do FormSuccess na -> do raw <- runResourceT $ fileSource (avatarNewFile na) $$ sinkLbs thumb <- generateThumb $ B.concat $ L.toChunks raw - runDB $ insert_ $ Avatar (avatarNewIdent na) thumb + now <- liftIO $ getCurrentTime + runDB $ insert_ $ Avatar (avatarNewIdent na) thumb now setMessageI MsgAvatarUploadSuccessfull redirect $ HomeR _ -> do diff --git a/config/models b/config/models index 7641baa..13c11ad 100644 --- a/config/models +++ b/config/models @@ -32,6 +32,7 @@ CashCheck Avatar ident Text data ByteString + altTime UTCTime default=now() deriving Typeable Show Barcode code Text