From a5a08d06383678197e6fc95e38580f79451e9568 Mon Sep 17 00:00:00 2001 From: nek0 Date: Sat, 10 Sep 2016 11:55:01 +0200 Subject: [PATCH] fill grid --- Handler/Home.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Handler/Home.hs b/Handler/Home.hs index d3779cb..acedf87 100755 --- a/Handler/Home.hs +++ b/Handler/Home.hs @@ -26,8 +26,8 @@ import Yesod.AtomFeed getHomeR :: Handler Html getHomeR = do - recentMedia <- runDB $ selectList [] [Desc MediumTime, LimitTo 15] - nextMediaQuery <- runDB $ selectList [] [Desc MediumTime, LimitTo 1, OffsetBy 15] + recentMedia <- runDB $ selectList [] [Desc MediumTime, LimitTo 16] + nextMediaQuery <- runDB $ selectList [] [Desc MediumTime, LimitTo 1, OffsetBy 16] let nextMedia = not $ L.null nextMediaQuery defaultLayout $ do rssLink RootFeedRssR "Root Feed" @@ -37,8 +37,8 @@ getHomeR = do getPageR :: Int -> Handler Html getPageR page = do - pageMedia <- runDB $ selectList [] [Desc MediumTime, LimitTo 15, OffsetBy (page*15)] - nextMediaQuery <- runDB $ selectList [] [Desc MediumTime, LimitTo 1, OffsetBy ((page + 1) * 15)] + pageMedia <- runDB $ selectList [] [Desc MediumTime, LimitTo 16, OffsetBy (page*16)] + nextMediaQuery <- runDB $ selectList [] [Desc MediumTime, LimitTo 1, OffsetBy ((page + 1) * 16)] let nextMedia = not $ L.null nextMediaQuery defaultLayout $ do rssLink RootFeedRssR "Root Feed"