diff --git a/copri4/main/src/Mod/APIfunc.pm b/copri4/main/src/Mod/APIfunc.pm index d280c97..9048000 100755 --- a/copri4/main/src/Mod/APIfunc.pm +++ b/copri4/main/src/Mod/APIfunc.pm @@ -1208,9 +1208,11 @@ sub booking_update(){ mtime => "now()", }; + if($user_agent && $user_agent !~ /axios/){#keep device info if sig push $update_pos->{txt21} = $q->escapeHTML($q->param('user_device')) if($q->param('user_device')); $update_pos->{txt26} = $q->escapeHTML($user_agent) if($user_agent); $update_pos->{txt27} = $q->escapeHTML($q->param('app_debug')) if($q->param('app_debug')); + } #if($state =~ /canceled/ && $record_pos->{txt10} =~ /requested/) if($state_key == 6 && $record_pos->{int10} == 2){ @@ -1463,10 +1465,12 @@ sub booking_update(){ int24 => 0, }; + if($user_agent && $user_agent !~ /axios/){#keep device info if sig push $update_pos->{int14} = $q->escapeHTML($q->param('voltage')) if($q->param('voltage')); $update_pos->{txt21} = $q->escapeHTML($q->param('user_device')) if($q->param('user_device')); $update_pos->{txt26} = $q->escapeHTML($user_agent) if($user_agent); $update_pos->{txt27} = $q->escapeHTML($q->param('app_debug')) if($q->param('app_debug')); + } my $lock_value = 0; if($lock_state eq "locked"){ @@ -1906,7 +1910,19 @@ sub bikes_available(){ my $authed = 0; my $station = $q->escapeHTML($q->param('station')) || ""; - my $station_id = $1 if($station =~ /(\d+)/); + my $station_id = ""; + $station_id = $1 if($station =~ /(\d+)/); + + #to get A-A key for text + my $pref_st = { + table => "content", + fetch => "one", + template_id => "225", + int10 => "1", + int04 => "$station_id", + }; + my $record_st = {}; + $record_st = $dbt->fetch_record($dbh,$pref_st) if($station_id); my $bike = $q->escapeHTML($q->param('bike')) || ""; my $bike_id = $bike; @@ -2027,7 +2043,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} = ["AGB","Mit der Mietrad Anmietung wird folgender Betreiber AGB zugestimmt (als Demo sharee AGB)."] if($auth->{c_id} && ($auth->{c_id} == 1842 || $auth->{c_id} == 1843 || $auth->{c_id} == 5781 || $auth->{c_id} == 11765 || $auth->{c_id} == 38883)); + $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}); my $i = 0; foreach my $td (sort keys (%$td_template)){ diff --git a/copri4/main/src/Mod/APIjsonserver.pm b/copri4/main/src/Mod/APIjsonserver.pm index 1fa0ee6..e8451ad 100755 --- a/copri4/main/src/Mod/APIjsonserver.pm +++ b/copri4/main/src/Mod/APIjsonserver.pm @@ -114,9 +114,10 @@ if(!$coo && !$q->param('merchant_id')){ $response->{bike_info_html} = "site/bike_info_konrad_1.html"; } if($return_merchant->{project_id} eq "Bayern"){ - $response->{agb_html} = "site/agb_lastenradbayern.html"; + $response->{agb_html} = "site/agb_lastenradbayern_220804.html"; $response->{bike_info_html} = "site/bike_info_bayern.html"; $response->{privacy_html} = "site/privacy_lastenradbayern.html"; + $response->{tariff_info_html} = "site/tarif_info_lastenradbayern_220804.html"; } } diff --git a/copri4/shareeapp-operator/src/Tpl/FormEdit.pm b/copri4/shareeapp-operator/src/Tpl/FormEdit.pm index 8a4522d..6490102 100755 --- a/copri4/shareeapp-operator/src/Tpl/FormEdit.pm +++ b/copri4/shareeapp-operator/src/Tpl/FormEdit.pm @@ -175,7 +175,7 @@ Weitere Personen aus Ihrem Haushalt profitieren jedoch ebenfalls, falls Sie weit $sharee_agb_text->{txt01} = ""; } if($project eq "Bayern"){ - $sharee_agb_text->{txt01} = ""; + $sharee_agb_text->{txt01} = ""; $sharee_privacy_text->{txt01} = ""; }