AAFahrten and SEPA

This commit is contained in:
ragu 2022-08-08 13:59:42 +02:00
parent 1e81d08904
commit 00919c51eb
3 changed files with 10 additions and 9 deletions

View file

@ -1911,18 +1911,19 @@ sub bikes_available(){
my $station = $q->escapeHTML($q->param('station')) || "";
my $station_id = "";
$station_id = $1 if($station =~ /(\d+)/);
$station_id = $1 if($station =~ /(\d+)$/);
#to get A-A key for text
my $pref_st = {
table => "content",
fetch => "one",
fetch => "all",
keyfield => "int04",
template_id => "225",
int10 => "1",
int04 => "$station_id",
};
my $record_st = {};
$record_st = $dbt->fetch_record($dbh,$pref_st) if($station_id);
$pref_st->{int04} = "$station_id" if($station_id);
$record_st = $dbt->fetch_record($dbh,$pref_st);
my $bike = $q->escapeHTML($q->param('bike')) || "";
my $bike_id = $bike;
@ -2043,7 +2044,7 @@ sub bikes_available(){
$return->{$id}->{rental_description}->{reserve_timerange} = "15";
$return->{$id}->{rental_description}->{reserve_timerange} = "30" if($record->{$id}->{int11} == 3);#sig timeout time
$return->{$id}->{rental_description}->{rental_info}->{1} = ["Tracking","Ich stimme der Speicherung (Tracking) meiner Fahrstrecke zwecks wissenschaftlicher Auswertung und Berechnung der CO2-Einsparung zu!"] if($record->{$id}->{int25});
$return->{$id}->{rental_description}->{rental_info}->{2} = ["AAFahrten","Achtung, das Mietende von diesem Lastenrad ist nur an dieser Station möglich!"] if($station_id && $record_st->{int42});
$return->{$id}->{rental_description}->{rental_info}->{2} = ["AAFahrten","Dieses E-Lastenrad darf nur an der Station zurück gegeben werden an der es ausgeliehen wurde!"] if($record_st->{$record->{$id}->{int04}}->{int42});
my $i = 0;
foreach my $td (sort keys (%$td_template)){