diff options
author | Christian Pointner <equinox@helsinki.at> | 2016-09-14 20:11:20 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2016-09-14 20:18:27 (GMT) |
commit | d7177aa0309b044596f04af4e269dc29f82ad1e0 (patch) | |
tree | 3224baf2a72131669998142ada8723905f965d37 /lib | |
parent | 308a989ca62ba7d97fa7a60a8940d9d2b6dbb7b7 (diff) |
implemented multi-show remove
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/RHRD/rddb.pm | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/lib/RHRD/rddb.pm b/lib/RHRD/rddb.pm index 5e0afbc..da3a1e5 100755 --- a/lib/RHRD/rddb.pm +++ b/lib/RHRD/rddb.pm @@ -155,6 +155,12 @@ sub get_showid_range return get_cart_range($ctx, $ctx->{'config'}{'specialgroups'}{'shows'}) } +sub get_multi_showid_range +{ + my ($ctx) = @_; + return get_cart_range($ctx, $ctx->{'config'}{'specialgroups'}{'multishows'}) +} + sub get_next_free_slot { my ($ctx, $groupname) = @_; @@ -2058,6 +2064,23 @@ sub create_multi_show return ($number, 'OK', 'success'); } +sub remove_multi_show +{ + my ($ctx, $showid) = @_; + + my $sql = qq{delete from CART where NUMBER = ?;}; + + my $sth = $ctx->{'dbh'}->prepare($sql) + or return (undef, 'ERROR', "Database Error: " . $ctx->{'dbh'}->errstr); + + my $cnt = $sth->execute($showid) + or return (undef, 'ERROR', "Database Error: " . $sth->errstr); + + $sth->finish(); + + return ($cnt, 'OK', 'success'); +} + ########################### MUSICPOOL handling ########################### |