diff options
author | Christian Pointner <equinox@helsinki.at> | 2016-12-03 21:42:05 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2016-12-03 21:42:05 (GMT) |
commit | f40e2b4db40b871666c669de8f3a5a23db4fb176 (patch) | |
tree | d3dd8d565e4b18ad4e3bd4bcb7e0e39457e6d81a | |
parent | 118522ced59b522713bde5147286a102f90d72ea (diff) |
rhrd-show is now more normalized
-rwxr-xr-x | utils/rhrd-show | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/utils/rhrd-show b/utils/rhrd-show index 88f29ce..ca62fa5 100755 --- a/utils/rhrd-show +++ b/utils/rhrd-show @@ -52,7 +52,10 @@ sub list } my @sorted = sort { lc($a->{'TITLE'}) cmp lc($b->{'TITLE'}) } @shows; for my $href (@sorted) { - print $href->{'ID'} . ": " . $href->{'TITLE'} . "\n"; + my $title = $href->{'TITLE'}; + $title = $title . " (Wiederholung)" if($href->{'TYPE'} eq 'r'); + $title = $title . " (Sondersendung)" if($href->{'TYPE'} eq 's'); + print $href->{'ID'} . ": " . $title . "\n"; } return 0; } @@ -339,10 +342,10 @@ sub multi_list } my @sorted = sort { lc($a->{'TITLE'}) cmp lc($b->{'TITLE'}) } @mshows; for my $href (@sorted) { - my %showids = %{$href->{'SHOWS'}}; - my $showtype = RHRD::utils::dropbox_param_showtype_to_string($href->{'TYPE'}); - my $showstr = join(", ", map { "W$_: $showids{$_}" } sort keys %showids); - print $href->{'ID'} . ": " . $href->{'TITLE'} . ", " . $showtype. ", (" . $showstr . ")\n"; + my $title = $href->{'TITLE'}; + $title = $title . " (Wiederholung)" if($href->{'TYPE'} eq 'r'); + $title = $title . " (Sondersendung)" if($href->{'TYPE'} eq 's'); + print $href->{'ID'} . ": " . $title . "\n"; } return 0; } @@ -474,8 +477,10 @@ sub multi_show print STDERR "$errorstring\n"; return 1; } - my $showtype = RHRD::utils::dropbox_param_showtype_to_string($show->{'TYPE'}); - print $show->{'TITLE'} . ": " . $showtype . "\n"; + my $title = $show->{'TITLE'}; + $title = $title . " (Wiederholung)" if($show->{'TYPE'} eq 'r'); + $title = $title . " (Sondersendung)" if($show->{'TYPE'} eq 's'); + print $title . ":\n"; my %showids = %{$show->{'SHOWS'}}; foreach my $week (sort keys %showids) { |