projects
/
Business-OnlinePayment-TransactionCentral.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add some debugging methods to get at raw responses
[Business-OnlinePayment-TransactionCentral.git]
/
lib
/
Business
/
OnlinePayment
/
TransactionCentral.pm
diff --git
a/lib/Business/OnlinePayment/TransactionCentral.pm
b/lib/Business/OnlinePayment/TransactionCentral.pm
index
68a193d
..
78b84ec
100644
(file)
--- a/
lib/Business/OnlinePayment/TransactionCentral.pm
+++ b/
lib/Business/OnlinePayment/TransactionCentral.pm
@@
-8,7
+8,7
@@
use Business::OnlinePayment::HTTPS 0.02;
use vars qw($VERSION @ISA $DEBUG);
@ISA = qw(Business::OnlinePayment::HTTPS);
use vars qw($VERSION @ISA $DEBUG);
@ISA = qw(Business::OnlinePayment::HTTPS);
-$VERSION = '0.0
1
';
+$VERSION = '0.0
2
';
$DEBUG = 0;
sub set_defaults {
$DEBUG = 0;
sub set_defaults {
@@
-18,7
+18,9
@@
sub set_defaults {
$self->port('443');
$self->path('/billing/TransactionCentral/');
$self->port('443');
$self->path('/billing/TransactionCentral/');
- $self->build_subs(qw( order_number avs_code cvv2_response ));
+ $self->build_subs(qw( order_number avs_code cvv2_response
+ response_page response_code response_headers
+ ));
}
sub submit {
}
sub submit {
@@
-107,10
+109,13
@@
sub submit {
DESCRIPTION DESCDATE TRANSTYPE TRANSROUTE
);
DESCRIPTION DESCDATE TRANSTYPE TRANSROUTE
);
- #my( $page, $response, %reply_headers ) =
- my( $page, $response ) =
+ my( $page, $response, %reply_headers ) =
$self->https_post( $self->get_fields( @fields ) );
$self->https_post( $self->get_fields( @fields ) );
+ $self->response_code( $response );
+ $self->response_page( $page );
+ $self->response_headers( \%reply_headers );
+
warn "\n" if $DEBUG > 1;
if ( $DEBUG > 2 ) {
warn "response: $response\n";
warn "\n" if $DEBUG > 1;
if ( $DEBUG > 2 ) {
warn "response: $response\n";
@@
-177,7
+182,7
@@
Business::OnlinePayment::TransactionCentral - Transaction Central backend module
# One step transaction, the simple case.
####
# One step transaction, the simple case.
####
- my $tx = new Business::OnlinePayment("
Capstone
");
+ my $tx = new Business::OnlinePayment("
TransactionCentral
");
$tx->content(
type => 'CC',
login => '10011', #MerchantID
$tx->content(
type => 'CC',
login => '10011', #MerchantID