summaryrefslogtreecommitdiff
path: root/templates/inventoryListing.hamlet
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2017-03-16 01:19:07 +0100
committerGregor Kleen <gkleen@yggdrasil.li>2017-03-16 01:19:07 +0100
commit3bfe0bdcb79b398a387e202c5150b5e6fd230d3a (patch)
tree8384b49048e84969a3a3440ed309b9c6e6b779de /templates/inventoryListing.hamlet
parent3ed9ec8ca70afb556f75d4e087043f4c67f50974 (diff)
downloadbar-3bfe0bdcb79b398a387e202c5150b5e6fd230d3a.tar
bar-3bfe0bdcb79b398a387e202c5150b5e6fd230d3a.tar.gz
bar-3bfe0bdcb79b398a387e202c5150b5e6fd230d3a.tar.bz2
bar-3bfe0bdcb79b398a387e202c5150b5e6fd230d3a.tar.xz
bar-3bfe0bdcb79b398a387e202c5150b5e6fd230d3a.zip
More complicated date handling
Diffstat (limited to 'templates/inventoryListing.hamlet')
-rw-r--r--templates/inventoryListing.hamlet33
1 files changed, 19 insertions, 14 deletions
diff --git a/templates/inventoryListing.hamlet b/templates/inventoryListing.hamlet
index 3be43db..39758bb 100644
--- a/templates/inventoryListing.hamlet
+++ b/templates/inventoryListing.hamlet
@@ -26,22 +26,27 @@
26 <div .kind>#{itemKind} 26 <div .kind>#{itemKind}
27 <div .type>#{itemType} 27 <div .type>#{itemType}
28 <div .td .day> 28 <div .td .day>
29 $maybe bought <- itemBought 29 $case itemBought
30 #{dayFormat bought} 30 $of DateUnknown
31 $nothing 31 <hr>
32 <hr> 32 $of DateKnown d
33 #{dayFormat d}
33 <div .td .day> 34 <div .td .day>
34 $maybe expires <- itemExpires 35 $case itemExpires
35 #{dayFormat expires} 36 $of DateNever
36 $nothing 37 <hr>
37 <hr> 38 $of DateKnown d
39 <span :d < today:.expired>#{dayFormat d}
38 <div .td .day> 40 <div .td .day>
39 $maybe opened <- itemOpened 41 $case itemOpened
40 #{dayFormat opened} 42 $of DateKnown d
41 $nothing 43 #{dayFormat d}
42 <form method=post action=@{OpenItemR itemId}> 44 $of DateUnknown
43 <button type=submit> 45 Yes
44 Open 46 $of DateNever
47 <form method=post action=@{OpenItemR itemId}>
48 <button type=submit>
49 Open
45 <div .td> 50 <div .td>
46 <form method=get action=@{UpdateItemR itemId}##{toPathPiece itemId}> 51 <form method=get action=@{UpdateItemR itemId}##{toPathPiece itemId}>
47 <button type=submit> 52 <button type=submit>