summaryrefslogtreecommitdiff
path: root/lib/RHRD/rddb.pm
diff options
context:
space:
mode:
authorChristian Pointner <equinox@helsinki.at>2016-11-25 21:52:08 (GMT)
committerChristian Pointner <equinox@helsinki.at>2016-11-25 21:52:08 (GMT)
commitb40c235c699e737431ded7c4ccdc57c5c80be770 (patch)
treed697a81e8bc73c493f5132b6af74eff6cb85c14a /lib/RHRD/rddb.pm
parent1eab56a6601fc41643cdc3d9372462edf3f5000d (diff)
implemented show types
Diffstat (limited to 'lib/RHRD/rddb.pm')
-rwxr-xr-xlib/RHRD/rddb.pm14
1 files changed, 10 insertions, 4 deletions
diff --git a/lib/RHRD/rddb.pm b/lib/RHRD/rddb.pm
index f89682a..e9f79ef 100755
--- a/lib/RHRD/rddb.pm
+++ b/lib/RHRD/rddb.pm
@@ -1237,6 +1237,8 @@ sub get_dropboxes
$entry->{'SHOWSTARTTIME'} = '????' unless((RHRD::utils::dropbox_param_starttime_ok($entry->{'SHOWSTARTTIME'}))[0]);
$entry->{'SHOWLEN'} = $p[4];
$entry->{'SHOWLEN'} = 0 unless((RHRD::utils::dropbox_param_len_ok($entry->{'SHOWLEN'}))[0]);
+ $entry->{'SHOWTYPE'} = $p[5];
+ $entry->{'SHOWTYPE'} = 'n' unless((RHRD::utils::dropbox_param_showtype_ok($entry->{'SHOWTYPE'}))[0]);
} elsif(defined($p[0]) && $p[0] eq "J") {
$entry->{'TYPE'} = 'jingle';
$entry->{'JINGLETITLE'} = $groupdesc;
@@ -1452,6 +1454,8 @@ sub list_shows
substr($p[3], 2, 0) = ':';
$entry->{'STARTTIME'} = $p[3];
$entry->{'LEN'} = int $p[4];
+ $entry->{'TYPE'} = 'n';
+ $entry->{'TYPE'} = $p[5] if(defined($p[5]));
push @show_dbs, $entry;
}
@@ -1712,6 +1716,8 @@ sub get_show_info
substr($p[3], 2, 0) = ':';
$entry->{'STARTTIME'} = $p[3];
$entry->{'LEN'} = int $p[4];
+ $entry->{'TYPE'} = 'n';
+ $entry->{'TYPE'} = $p[5] if(defined($p[5]));
return ($entry, 'OK', 'success');
}
@@ -1920,8 +1926,8 @@ sub create_show_macro_cart
sub create_show_dropbox
{
- my ($ctx, $groupname, $showid, $rhythm, $dow, $starttime, $len) = @_;
- my $param = join(';', ('S', $rhythm, $dow, $starttime, $len));
+ my ($ctx, $groupname, $showid, $rhythm, $dow, $starttime, $len, $type) = @_;
+ my $param = join(';', ('S', $rhythm, $dow, $starttime, $len, $type));
my $sql = qq{insert into DROPBOXES (STATION_NAME, GROUP_NAME, NORMALIZATION_LEVEL, AUTOTRIM_LEVEL, TO_CART, FIX_BROKEN_FORMATS, SET_USER_DEFINED) values (?, ?, ?, ?, ?, 'Y', ?)};
@@ -1938,8 +1944,8 @@ sub create_show_dropbox
sub update_show_dropbox
{
- my ($ctx, $showid, $rhythm, $dow, $starttime, $len) = @_;
- my $param = join(';', ('S', $rhythm, $dow, $starttime, $len));
+ my ($ctx, $showid, $rhythm, $dow, $starttime, $len, $type) = @_;
+ my $param = join(';', ('S', $rhythm, $dow, $starttime, $len, $type));
my $sql = qq{update DROPBOXES set SET_USER_DEFINED = ? where TO_CART = ?};