Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Business checks can be refunded. Point a flag for it. The cclastfour …
…field will be renamed to refundinfo later. Merged from 17stable.
  • Loading branch information
ethem committed Nov 17, 2006
1 parent 88c5092 commit 4df4b15
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions enrol/authorize/enrol.php
Expand Up @@ -312,12 +312,13 @@ function echeck_submit($form, $course)

$useripno = getremoteaddr();
$curcost = get_course_cost($course);
$isbusinesschecking = ($form->acctype == 'BUSINESSCHECKING');

// NEW ECHECK ORDER
$timenow = time();
$order = new stdClass();
$order->paymentmethod = AN_METHOD_ECHECK;
$order->cclastfour = 0;
$order->cclastfour = $isbusinesschecking ? 1 : 0;
$order->ccname = $form->firstname . ' ' . $form->lastname;
$order->courseid = $course->id;
$order->userid = $USER->id;
Expand All @@ -338,7 +339,7 @@ function echeck_submit($form, $course)
$extra->x_bank_aba_code = $form->abacode;
$extra->x_bank_acct_num = $form->accnum;
$extra->x_bank_acct_type = $form->acctype;
$extra->x_echeck_type = ($form->acctype == 'BUSINESSCHECKING') ? 'CCD' : 'WEB';
$extra->x_echeck_type = $isbusinesschecking ? 'CCD' : 'WEB';
$extra->x_bank_name = $form->bankname;
$extra->x_currency_code = $curcost['currency'];
$extra->x_amount = $curcost['cost'];
Expand Down

0 comments on commit 4df4b15

Please sign in to comment.