From 4d410cf1f7fdb1d1c9da905215e37dc7d349e6c3 Mon Sep 17 00:00:00 2001 From: fr33domlover Date: Fri, 13 May 2016 22:11:46 +0000 Subject: [PATCH] Pick shorter names for project page templates --- src/Vervis/Handler/Project.hs | 10 +++++----- templates/project/{projects.hamlet => list.hamlet} | 0 templates/project/{project-new.hamlet => new.hamlet} | 0 templates/project/{project.hamlet => one.hamlet} | 0 4 files changed, 5 insertions(+), 5 deletions(-) rename templates/project/{projects.hamlet => list.hamlet} (100%) rename templates/project/{project-new.hamlet => new.hamlet} (100%) rename templates/project/{project.hamlet => one.hamlet} (100%) diff --git a/src/Vervis/Handler/Project.hs b/src/Vervis/Handler/Project.hs index ed0405b..88a0b01 100644 --- a/src/Vervis/Handler/Project.hs +++ b/src/Vervis/Handler/Project.hs @@ -38,7 +38,7 @@ getProjectsR ident = do sharer ^. SharerId ==. project ^. ProjectSharer orderBy [asc $ project ^. ProjectIdent] return $ project ^. ProjectIdent - defaultLayout $(widgetFile "project/projects") + defaultLayout $(widgetFile "project/list") postProjectsR :: Text -> Handler Html postProjectsR ident = do @@ -52,17 +52,17 @@ postProjectsR ident = do redirect HomeR FormMissing -> do setMessage "Field(s) missing" - defaultLayout $(widgetFile "project/project-new") + defaultLayout $(widgetFile "project/new") FormFailure _l -> do setMessage "Project creation failed, see below" - defaultLayout $(widgetFile "project/project-new") + defaultLayout $(widgetFile "project/new") getProjectNewR :: Text -> Handler Html getProjectNewR ident = do Entity _pid person <- requireAuth let sid = personIdent person ((_result, widget), enctype) <- runFormPost $ newProjectForm sid - defaultLayout $(widgetFile "project/project-new") + defaultLayout $(widgetFile "project/new") getProjectR :: Text -> Text -> Handler Html getProjectR user proj = do @@ -70,4 +70,4 @@ getProjectR user proj = do Entity sid _s <- getBy404 $ UniqueSharerIdent user Entity _pid p <- getBy404 $ UniqueProject proj sid return p - defaultLayout $(widgetFile "project/project") + defaultLayout $(widgetFile "project/one") diff --git a/templates/project/projects.hamlet b/templates/project/list.hamlet similarity index 100% rename from templates/project/projects.hamlet rename to templates/project/list.hamlet diff --git a/templates/project/project-new.hamlet b/templates/project/new.hamlet similarity index 100% rename from templates/project/project-new.hamlet rename to templates/project/new.hamlet diff --git a/templates/project/project.hamlet b/templates/project/one.hamlet similarity index 100% rename from templates/project/project.hamlet rename to templates/project/one.hamlet