mirror of
https://code.naskya.net/repos/ndqEd
synced 2025-01-10 16:46:46 +09:00
Fix: Was displaying all tickets instead of just projects'
This commit is contained in:
parent
1b7cee4b78
commit
604e3ca80a
1 changed files with 6 additions and 6 deletions
|
@ -56,10 +56,12 @@ import Vervis.Settings (widgetFile)
|
||||||
|
|
||||||
getTicketsR :: Text -> Text -> Handler Html
|
getTicketsR :: Text -> Text -> Handler Html
|
||||||
getTicketsR shar proj = do
|
getTicketsR shar proj = do
|
||||||
rows <- runDB $ select $ from $ \ (ticket, person, sharer) -> do
|
rows <- runDB $ select $ from $ \ (sharer, project, ticket) -> do
|
||||||
where_ $
|
where_ $
|
||||||
ticket ^. TicketCreator E.==. person ^. PersonId &&.
|
sharer ^. SharerIdent E.==. val shar &&.
|
||||||
person ^. PersonIdent E.==. sharer ^. SharerId
|
project ^. ProjectSharer E.==. sharer ^. SharerId &&.
|
||||||
|
project ^. ProjectIdent E.==. val proj &&.
|
||||||
|
ticket ^. TicketProject E.==. project ^. ProjectId
|
||||||
orderBy [asc $ ticket ^. TicketNumber]
|
orderBy [asc $ ticket ^. TicketNumber]
|
||||||
return
|
return
|
||||||
( ticket ^. TicketNumber
|
( ticket ^. TicketNumber
|
||||||
|
@ -68,9 +70,7 @@ getTicketsR shar proj = do
|
||||||
, ticket ^. TicketTitle
|
, ticket ^. TicketTitle
|
||||||
, ticket ^. TicketDone
|
, ticket ^. TicketDone
|
||||||
)
|
)
|
||||||
defaultLayout $ do
|
defaultLayout $(widgetFile "ticket/list")
|
||||||
setTitle $ toHtml $ T.intercalate " :: " [shar, proj, "Tickes"]
|
|
||||||
$(widgetFile "ticket/list")
|
|
||||||
|
|
||||||
postTicketsR :: Text -> Text -> Handler Html
|
postTicketsR :: Text -> Text -> Handler Html
|
||||||
postTicketsR shar proj = do
|
postTicketsR shar proj = do
|
||||||
|
|
Loading…
Reference in a new issue