summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcos <cos>2015-02-05 21:36:02 +0100
committercos <cos>2015-02-05 21:36:02 +0100
commita478c12859dfcad58da89758a94ba4c59a8ce1fd (patch)
treeb842f75183037bf1ca8d3244b4287d2a49556e7b
parent80e18fc5ac7e7dcac500f292f886ef9195dc9341 (diff)
downloadmat-a478c12859dfcad58da89758a94ba4c59a8ce1fd.zip
Make cmd_showplan display comments again.
-rwxr-xr-xmat6
1 files changed, 5 insertions, 1 deletions
diff --git a/mat b/mat
index 2c7c0f5..2a1cb16 100755
--- a/mat
+++ b/mat
@@ -454,8 +454,12 @@ sub cmd_showplan {
# ($portions_left > 0) ? $portions_left : 'u',
$ids->{$mealtype}{'recipe_id'},
# get_recipe_uri($ids->{$mealtype}{'recipe_id'}),
-# get_comment($ids->{$mealtype}{'recipe_id'});
# "apa", "lemur", "katt", "hund";
+ } elsif ($ids->{$mealtype}{'comment_id'}) {
+ printf "%-10s %-13s |%s\n",
+ ($mealtype eq "frukost" ? $dt->ymd() : # FIXME remove hard coded mealtype
+ ($mealtype eq "elvakaffe" ? $dt->day_name() : "")), $mealtype, # FIXME remove hard coded mealtype
+ get_comment($ids->{$mealtype}{'comment_id'});
} else {
printf "%-10s %-13s | \n",
($mealtype eq "frukost" ? $dt->ymd() : # FIXME remove hard coded mealtype