mirror of
https://gitlab.com/t6353/sharee.bike.git
synced 2025-05-09 21:46:34 +02:00
voltage and privacy on register
This commit is contained in:
parent
f95f503bf6
commit
901c4c2a71
4 changed files with 44 additions and 7 deletions
|
@ -1076,7 +1076,7 @@ sub booking_update(){
|
|||
$dbt->update_record($dbh,$update_ct,$record_ct);
|
||||
if($q->param('voltage') && $q->param('voltage') =~ /(\d+)/){
|
||||
$update_cc->{int14} = $1;
|
||||
$self->service_automatic($q) if($1 <= 40);
|
||||
#$self->service_automatic($q) if($1 <= 40);
|
||||
}
|
||||
$update_cc->{txt15} = $q->escapeHTML($q->param('firmware')) if($q->param('firmware'));
|
||||
$update_cc->{txt17} = $Ilockit_GUID if($Ilockit_GUID);
|
||||
|
@ -1108,9 +1108,11 @@ sub booking_update(){
|
|||
mtime => "now()",
|
||||
owner => "$owner",
|
||||
};
|
||||
$update_cc->{int14} = $q->escapeHTML($q->param('voltage')) if($q->param('voltage'));
|
||||
|
||||
#my $record_cc = { c_id => $record_pos->{cc_id} };
|
||||
if($q->param('voltage') && $q->param('voltage') =~ /(\d+)/){
|
||||
$update_cc->{int14} = $1;
|
||||
$self->service_automatic($q) if($1 <= 40);
|
||||
}
|
||||
|
||||
my $update_pos = {
|
||||
table => "contenttranspos",
|
||||
|
@ -1295,8 +1297,10 @@ sub service_automatic {
|
|||
my $self = shift;
|
||||
my $q = shift || "";
|
||||
|
||||
my $station_id = $1 if($q->param('station') =~ /(\d+)/);
|
||||
my $bike_id = $1 if($q->param('bike') =~ /(\d+)/);
|
||||
my $station_id = "";
|
||||
my $bike_id = "";
|
||||
$station_id = $1 if($q->param('station') && $q->param('station') =~ /(\d+)/);
|
||||
$bike_id = $1 if($q->param('bike') && $q->param('bike') =~ /(\d+)/);
|
||||
my $authraw = { c_id => $owner };#default sys API
|
||||
my $lock_charge = "Achtung, Fahrradschloss Ladung unter " . $q->param('voltage') . "%";
|
||||
my $response = {};
|
||||
|
|
|
@ -41,12 +41,14 @@ sub tpl(){
|
|||
($api_return,$users_sharee) = $apif->auth_verify($q,$coo,"");
|
||||
|
||||
my $initMap = $dbt->{website}->{$varenv->{syshost}}->{initMap};
|
||||
my $map_zoom = $dbt->{website}->{$varenv->{syshost}}->{map_zoom} || "10";
|
||||
|
||||
if($dbt->{website}->{$varenv->{syshost}}->{merchant_id}){
|
||||
$api_return->{authcookie} = $dbt->{website}->{$varenv->{syshost}}->{merchant_id} if(!$api_return->{authcookie});
|
||||
}elsif($dbt->{operator}->{$varenv->{dbname}}->{merchant_id}){
|
||||
$api_return->{authcookie} = $dbt->{operator}->{$varenv->{dbname}}->{merchant_id} if(!$api_return->{authcookie});
|
||||
$initMap = $dbt->{operator}->{$varenv->{dbname}}->{initMap};
|
||||
$map_zoom = $dbt->{operator}->{$varenv->{dbname}}->{map_zoom} if($dbt->{operator}->{$varenv->{dbname}}->{map_zoom});
|
||||
}elsif($dbt->{primary}->{$varenv->{dbname}}->{merchant_id}){
|
||||
$api_return->{authcookie} = $dbt->{primary}->{$varenv->{dbname}}->{merchant_id} if(!$api_return->{authcookie});
|
||||
$initMap = $dbt->{primary}->{$varenv->{dbname}}->{initMap};
|
||||
|
@ -75,7 +77,7 @@ print<<EOF
|
|||
scrollwheel: false,
|
||||
draggable: !("ontouchend" in document),
|
||||
center: {lat: $lat, lng: $lng},
|
||||
zoom: 13
|
||||
zoom: $map_zoom
|
||||
});
|
||||
|
||||
var ctaLayer = new google.maps.KmlLayer({
|
||||
|
|
|
@ -173,7 +173,7 @@ my $booking_update_locking = "$uriop?request=booking_update&bike=$bike&lock_stat
|
|||
print $q->div({-style=>'margin:15px;'},$q->a({-target=>'_blank', -href=>"$booking_update_locking"},"[ booking_update_locking ]---> $booking_update_locking")),"\n";
|
||||
my $booking_update_locked = "$uriop?request=booking_update&bike=$bike&lock_state=locked&authcookie=$coo";
|
||||
print $q->div({-style=>'margin:15px;'},$q->a({-target=>'_blank', -href=>"$booking_update_locked"},"[ booking_update_locked ]---> $booking_update_locked")),"\n";
|
||||
my $booking_update_unlocked = "$uriop?request=booking_update&bike=$bike&lock_state=unlocked&authcookie=$coo";
|
||||
my $booking_update_unlocked = "$uriop?request=booking_update&bike=$bike&lock_state=unlocked&voltage=39&authcookie=$coo";
|
||||
print $q->div({-style=>'margin:15px;'},$q->a({-target=>'_blank', -href=>"$booking_update_unlocked"},"[ booking_update_unlocked ]---> $booking_update_unlocked")),"\n";
|
||||
|
||||
my $booking_update_oc_ul = "$uriop?request=booking_update&bike=$bike&state=occupied&lock_state=unlocked&authcookie=$coo";
|
||||
|
|
|
@ -137,6 +137,10 @@ sub tpl(){
|
|||
$sharee_agb_text->{txt01} = "<iframe src='$varenv->{wwwhost}/site/agb.html' style='width:100%;height:8000px;border:none;' scrolling='auto'></iframe>";
|
||||
$sharee_agb_text->{txt01} = "<iframe src='$varenv->{wwwhost}/site/agb_konrad_1.html' style='width:100%;height:8000px;border:none;' scrolling='auto'></iframe>" if($aowner == 195 || $aowner == 185 || $aowner == 176);
|
||||
|
||||
my $sharee_privacy_text = {};
|
||||
$sharee_privacy_text->{ct_name} = "Datenschutzhinweise";
|
||||
$sharee_privacy_text->{txt01} = "<iframe src='$varenv->{wwwhost}/site/privacy_2.html' style='width:100%;height:8000px;border:none;' scrolling='auto'></iframe>";
|
||||
|
||||
print "<div id='Contentapp'>\n";
|
||||
|
||||
print <<EOF
|
||||
|
@ -160,6 +164,28 @@ print <<EOF
|
|||
EOF
|
||||
;
|
||||
|
||||
print <<EOF
|
||||
<!-- Modal -->
|
||||
<div class="modal fade" id="sharee_privacy" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true" style="text-decoration:underline;">schließen</span><span class="sr-only">Close</span></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="text-default"><h4>$sharee_privacy_text->{ct_name}</h4>$sharee_privacy_text->{txt01}</div>
|
||||
</div>
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true" style="text-decoration:underline;">schließen</span><span class="sr-only">Close</span></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
EOF
|
||||
;
|
||||
|
||||
|
||||
my $debug=0;
|
||||
$debug=1 if($users_sharee->{c_id} eq $dbt->{copri_conf}->{superu_id} || $dbt->{copri_conf}->{stage} eq "test");
|
||||
my $debug_message = "";
|
||||
|
@ -527,6 +553,11 @@ Weitere Personen aus Ihrem Haushalt profitieren jedoch ebenfalls, falls Sie weit
|
|||
print $q->div({-id=>"$key"},$but->checkbox("1","$key","$ctrel->{$key}","","$required","$autofocus"), " $sharee_agb"),"\n";
|
||||
print $q->hidden(-name=>"$key",-override=>1,-value=>"null");
|
||||
|
||||
my $sharee_privacy = "<button type='button' class='btn btn-primary ' style='text-decoration:underline;color:black;border:1px solid white;background-color:white;' data-toggle='modal' data-target='#sharee_privacy'>Datenschutzhinweise.</button>\n";
|
||||
print $q->div({-style=>'padding-top:10px;'},"Bitte beachten Sie unsere neuen $sharee_privacy"),"\n" if($aowner == 195 || $aowner == 185 || $aowner == 176);
|
||||
|
||||
#print $q->div({-class=>'content2'},"Bitte beachten Sie unsere <a href='$varenv->{wwwhost}/site/privacy_2.html' target='_blank'>Datenschutzhinweise.</a>"),"\n";
|
||||
|
||||
}elsif(1==2 && $key =~ /int02/){#newsletter
|
||||
if($varenv->{wwwhost} !~ /konrad/){
|
||||
print $q->label({-for=>"$key", -style=>'padding-top:10px;'},""),"\n";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue