Skip to content

Commit

Permalink
generate new reference
Browse files Browse the repository at this point in the history
  • Loading branch information
Kendysond committed Oct 1, 2016
1 parent 90496cb commit fe36cf3
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions controllers/front/payment.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,15 @@ private function getPaystackcode($cart_id){
$pcode->add();

} else {
$acode = new Paystackcode();
$newcode = $acode->generate_code();
// Db::getInstance()->execute($sql);
$newref = @Db::getInstance()->execute('UPDATE `'._DB_PREFIX_.'paystack_txncodes` SET `code` = "'.$newcode.'" WHERE `cart_id` = "'.$cart_id.'"');
//SELECT * FROM `'._DB_PREFIX_.'paystack_txncodes` WHERE `code` = "'.$code.'"');//Rproduct::where('code', '=', $code)->

$pcode = @new Paystackcode((int)$o_exist[0][id]);
print_r($o_exist);

}


Expand Down

0 comments on commit fe36cf3

Please sign in to comment.