showing beverage avatars in restock menu
This commit is contained in:
parent
a93cdb937f
commit
0689cd76b7
2 changed files with 7 additions and 3 deletions
|
@ -17,6 +17,7 @@ module Handler.Restock where
|
|||
|
||||
import Import
|
||||
import Handler.Common
|
||||
import Data.Maybe (fromJust)
|
||||
|
||||
getRestockR :: Handler Html
|
||||
getRestockR = do
|
||||
|
|
|
@ -5,9 +5,12 @@ $doctype 5
|
|||
|
||||
$forall (Entity bId bev) <- beverages
|
||||
<article .article>
|
||||
<a href=@{UpstockR bId}>
|
||||
<p>
|
||||
#{beverageIdent bev}
|
||||
$if isNothing (beverageAvatar bev)
|
||||
<a href="@{UpstockR bId}">
|
||||
<p>#{beverageIdent bev}
|
||||
$else
|
||||
<a href="@{UpstockR bId}" style="background-image: url(@{GetAvatarR $ fromJust $ beverageAvatar bev})" .avatar>
|
||||
<p>#{beverageIdent bev}
|
||||
|
||||
<article .article #func>
|
||||
<a href=@{NewArticleR}>
|
||||
|
|
Loading…
Reference in a new issue