minor changes

This commit is contained in:
ragu 2023-01-11 06:55:55 +01:00
parent 8607a42e34
commit c1fe6c235c
8 changed files with 11 additions and 10 deletions

View file

@ -111,7 +111,7 @@ sub battery_percent {
my $max_bars = shift || 0;
my $current_bars = shift || 0;#by user input
my $current_percent = 1;#keep 1 % for Mietjournal view
my $current_percent = 0;
if($max_bars == 5){
$current_percent = 10 if($current_bars >= 1);
$current_percent = 30 if($current_bars >= 2);

View file

@ -525,7 +525,7 @@ sub handler {
my $debug=0;
$debug=1;
#send confirm codes
if($users_sharee->{c_id} && $users_sharee->{txt34} && length($users_sharee->{txt34}) > 20 && $payable_check && $R::sharee_edit && $R::sharee_edit =~ /save_account|send_email|send_sms/){
if($users_sharee->{c_id} && $users_sharee->{txt34} && length($users_sharee->{txt34}) > 10 && $payable_check && $R::sharee_edit && $R::sharee_edit =~ /save_account|send_email|send_sms/){
if(($users_sharee->{int04} != 1 || $R::sharee_edit =~ /send_email/) && ($users_sharee->{txt08} =~ /\w\@\w/)){
$tk->emailack($users_sharee->{c_id});

View file

@ -423,6 +423,7 @@ sub save_account(){
my $email = $R::txt08;
$email =~ s/\s//g;
my $confirm_digest = sha1_base64($email . $valxx);
$confirm_digest =~ s/[I1LO0]//ig;
$u_rows = $dbt->update_one($dbh,$update_primary,"txt34='$confirm_digest'");
}
#user alias email

View file

@ -49,7 +49,7 @@ sub handler {
open(FILE,">>/var/log/copri-bike/ajax_json.log") if($debug);
print FILE "$now_dt| u_id:$users_dms->{u_id}|$main_id\n" if($debug);
if($users_dms->{u_id} && $users_dms->{int07} == 2){
if($users_dms->{u_id} && ($users_dms->{int03} == 2 || $users_dms->{int07} == 2)){
foreach(@keywords){
my @val = $q->param($_);
my $valxx = $q->escapeHTML("@val");