1

in Finland we have reference number this: 1234 -> 12344, 12345 -> 123453,... Where last number is counted from first ones and bank system tests that number is correct. This is how we calculate number:

function viitenumero($orderid) {
$orderid = strval($orderid);
$paino = array(7, 3, 1);
$summa = 0;
for($i=strlen($orderid)-1, $j=0; $i>=0; $i--,$j++){
    $summa += (int) $orderid[$i] * (int) $paino[$j%3];
    }
    $tarkiste = (10-($summa%10))%10;
    return $orderid.$tarkiste;

How can I change all Magento Invoice numbers counted like this? And what is the file that I should change?

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.