Permalink
Browse files

Syncing the production website with the codebase.

  • Loading branch information...
1 parent 4d63825 commit 6b661f488f88d4adc6025a5e0d6c9e78c4839dc4 www-data committed Jan 17, 2009
Showing with 0 additions and 9 deletions.
  1. +0 −5 App/Components/Controllers/Page.hs
  2. +0 −4 App/Models/Bases/PageFunctions.hs
@@ -12,12 +12,7 @@ list = do pages <- findAllOrderBy "_id"
setViewDataValue "component-pages-list" $ map (\p -> (title p, _id p)) pages
listOnly :: Controller ()
-<<<<<<< HEAD:App/Components/Controllers/Page.hs
listOnly = do prefix <- getSetting_u "pages-prefix" :: Controller String
pages <- findAllWhereOrderBy "_id like ?" [toSql $ prefix ++ "%"] "_id"
-=======
-listOnly = do prefix <- getSetting_u "pages-prefix"
- pages <- findAllWhereOrderBy "_id like ?" [toSql $ prefix ++ "%"] "title"
->>>>>>> 765e0ae686c48f0146e555e92ed507e4964e87a9:App/Components/Controllers/Page.hs
setViewDataValue "component-pages-list" $ map (\p -> (title p, _id p)) pages
setSetting "component-view" "List" -- use the view from the List action
@@ -90,11 +90,7 @@ instance IsModel Page where
return $ map (\r -> Page (HDBC.fromSql (r !! 0)) (HDBC.fromSql (r !! 1)) (HDBC.fromSql (r !! 2))) res
findAllWhereOrderBy ss sp op = do
conn <- getEnvironment >>= (return . fromJust . getDatabase )
-<<<<<<< HEAD:App/Models/Bases/PageModelBase.hs
- res <- liftIO $ HDBC.handleSqlError $ HDBC.quickQuery' conn ("SELECT _id , content , title FROM page WHERE (" ++ ss ++ ") ORDER BY " ++ op) sp
-=======
res <- liftIO $ HDBC.handleSqlError $ HDBC.quickQuery' conn ("SELECT _id , content , title FROM page WHERE (" ++ ss ++ ") ORDER BY " ++ op) sp
->>>>>>> 765e0ae686c48f0146e555e92ed507e4964e87a9:App/Models/Bases/PageFunctions.hs
return $ map (\r -> Page (HDBC.fromSql (r !! 0)) (HDBC.fromSql (r !! 1)) (HDBC.fromSql (r !! 2))) res
findOneWhere ss sp = do
conn <- getEnvironment >>= (return . fromJust . getDatabase )

0 comments on commit 6b661f4

Please sign in to comment.