mirror of
https://gitlab.com/t6353/sharee.bike.git
synced 2025-05-11 22:37:27 +02:00
checking payment data after changing the payment typ
This commit is contained in:
parent
5044e9bfe8
commit
b2dce25de8
18 changed files with 209 additions and 123 deletions
|
@ -600,10 +600,9 @@ sub handler {
|
|||
};
|
||||
my $vde_on_fail = $users_sharee->{int12} || 1;#keep last or set 1
|
||||
|
||||
#SEPA, done in payone Payment
|
||||
#SEPA, done by Shareework managemandate
|
||||
#CC
|
||||
if($R::pseudocardpan && length($R::pseudocardpan) >= 19){#done by payone AJAX return
|
||||
#if($R::status eq "APPROVED")
|
||||
$now_dt = strftime "%Y-%m-%d %H:%M:%S", localtime;
|
||||
$update_adr->{txt22} = "";
|
||||
$update_adr->{txt23} = "";
|
||||
|
@ -615,31 +614,15 @@ sub handler {
|
|||
$update_adr->{int24} = "null";#cpdate reset
|
||||
$dbt->update_record($dbh,$update_adr,$users_sharee) if($users_sharee->{c_id} > 0);
|
||||
($api_return,$users_sharee) = $apif->auth_verify($q,$coo,"");
|
||||
|
||||
#payment_ack
|
||||
system("$dbt->{copri_conf}->{basedir}/$varenv{syshost}/src/scripts/payment_ack.pl '$varenv{syshost}' 'payment_ackCC' '$users_sharee->{c_id}' '$aowner'");
|
||||
|
||||
#define fictiv invoice to get 1 € test
|
||||
my $epoche = time();
|
||||
my $ctt = {
|
||||
c_id => 1,
|
||||
int01 => 0,#capture amount
|
||||
int15 => 1,#preauth amount
|
||||
txt16 => "",
|
||||
reference => "$users_sharee->{c_id}_$epoche",
|
||||
payone_reset => ''
|
||||
};
|
||||
|
||||
my $payone_txid = "";
|
||||
##preauthorization and/or capture needs to much time, must be done async!
|
||||
#$payone_txid = $payone->preauthorizationCC_main(\%varenv,$users_sharee,$ctt,$aowner);
|
||||
#if($payone_txid)
|
||||
if(1==1){
|
||||
if(1==1){
|
||||
open(FILE,">>$varenv{logdir}/confirm.log") if($debug);
|
||||
print FILE "\n\n*--> $now_dt done by $0\n" if($debug);
|
||||
print FILE "trigger confirm-code request by pseudocardpan\n" if($debug);
|
||||
|
||||
#$ctt->{txt16} = "$payone_txid";
|
||||
#$payone_txid = $payone->captureCC_main(\%varenv,$users_sharee,$ctt,$aowner);
|
||||
#int12=0 should be set after capture success in payment module
|
||||
|
||||
if(($users_sharee->{int04} != 1) && ($users_sharee->{txt08} =~ /\w\@\w/)){
|
||||
$shwo->emailack(\%varenv,$users_sharee->{c_id});
|
||||
}
|
||||
|
@ -647,10 +630,7 @@ sub handler {
|
|||
$shwo->smsack($users_sharee);
|
||||
}
|
||||
close(FILE) if($debug);
|
||||
}else{
|
||||
$dbt->update_one($dbh,$update_adr,"int12=$vde_on_fail");#Vde
|
||||
}
|
||||
|
||||
$dbt->update_operatorsloop($varenv{dbname},$users_sharee->{c_id},"update");
|
||||
|
||||
print redirect("$varenv{wwwhost}/$varenv{mandant}/Account/$varenv{accounting_3}?$returnwww$session_and");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue