eidolon/Handler/Admin.hs
2014-12-28 01:08:35 +01:00

16 lines
356 B
Haskell

module Handler.Admin where
import Import
import Handler.Commons
getAdminR :: Handler Html
getAdminR = do
adminCheck <- loginIsAdmin
case adminCheck of
Right _ -> do
defaultLayout $ do
setTitle "Administration: Menu"
$(widgetFile "adminBase")
Left (errorMsg, route) -> do
setMessage errorMsg
redirect $ route