webERP Forum

Full Version: bug: Internal stock request
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

ge_zhiyuan

file InternalStockRequest.php, line 209 and line 237:

variable $myrow while in the while-loop this variable name is $MyRow.

cannot upload png-file to show this bug.

PHP Code:
while ($myrow=DB_fetch_array($result)){
    if (isset(
$_SESSION['Request']->Location) AND $_SESSION['Request']->Location==$myrow['loccode']){
        echo 
'<option selected value="'$MyRow['loccode'], '">'$MyRow['loccode'], ' - 'htmlspecialchars($MyRow['locationname'], ENT_QUOTES,'UTF-8'), '</option>';
    } else {
        echo 
'<option value="'$MyRow['loccode'], '">'$MyRow['loccode'], ' - 'htmlspecialchars($MyRow['locationname'], ENT_QUOTES,'UTF-8'),  '</option>';
    }


should be revised to:
PHP Code:
while ($MyRow=DB_fetch_array($result)){
    if (isset(
$_SESSION['Request']->Location) AND $_SESSION['Request']->Location==$myrow['loccode']){
        echo 
'<option selected value="'$MyRow['loccode'], '">'$MyRow['loccode'], ' - 'htmlspecialchars($MyRow['locationname'], ENT_QUOTES,'UTF-8'), '</option>';
    } else {
        echo 
'<option value="'$MyRow['loccode'], '">'$MyRow['loccode'], ' - 'htmlspecialchars($MyRow['locationname'], ENT_QUOTES,'UTF-8'),  '</option>';
    }

Thanks for the report on that, ge_zhiyuan!

Will get that change applied later today.
Hello, ge_zhiyuan!

Checking this file tonight, it looks like that was fixed back in September, along with some other variable name issues.
Thanks for the report, was worth checking!

GitHub file reference

GitHub commit diff reference