From: <dai...@us...> - 2011-04-06 10:01:37
|
Revision: 4540 http://web-erp.svn.sourceforge.net/web-erp/?rev=4540&view=rev Author: daintree Date: 2011-04-06 10:01:30 +0000 (Wed, 06 Apr 2011) Log Message: ----------- various Modified Paths: -------------- trunk/SuppLoginSetup.php trunk/SuppShiptChgs.php trunk/SuppTransGLAnalysis.php trunk/SystemParameters.php Modified: trunk/SuppLoginSetup.php =================================================================== --- trunk/SuppLoginSetup.php 2011-04-05 10:14:24 UTC (rev 4539) +++ trunk/SuppLoginSetup.php 2011-04-06 10:01:30 UTC (rev 4540) @@ -1,9 +1,7 @@ <?php -/* $Revision: 1.2 $ */ + /* $Id$*/ -//$PageSecurity = 15; - include('includes/session.inc'); $title = _('Supplier Login Configuration'); include('includes/header.inc'); @@ -20,10 +18,9 @@ _('Petty Cash'), _('Setup')); -echo "<a href='" . $rootpath . '/SelectSupplier.php?' . SID . "'>" . _('Back to Suppliers') . '</a><br>'; +echo '<a href="' . $rootpath . '/SelectSupplier.php?">' . _('Back to Suppliers') . '</a><br>'; echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/supplier.png" title="' . _('Supplier') . '" alt="" />' . ' ' . _('Supplier') . ' : ' . $_SESSION['SupplierID'] . _(' has been selected') . '</p><br />'; -//echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/group_add.png" title="' . _('Search') . '" alt="">' . ' ' . $title.'<br>'; //Make an array of the security roles where only one role is active and is ID 1 @@ -32,7 +29,7 @@ //- Only one entry in securitygroups AND the tokenid of this entry == 1 //First get all available security role ID's' -$query_roles = 'SELECT secroleid FROM securityroles'; +$query_roles = "SELECT secroleid FROM securityroles"; $result_roles = DB_query($query_roles, $db); //Check for every security role if they have only one entry in securitygroups, if so check if the tokenid == 1, then store in selection box @@ -101,7 +98,7 @@ $i=0; $ModulesAllowed = ''; while ($i < count($ModuleList)){ - $FormVbl = "Module_" . $i; + $FormVbl = 'Module_' . $i; $ModulesAllowed .= $_POST[($FormVbl)] . ','; $i++; } @@ -200,7 +197,7 @@ prnMsg(_('The demonstration user called demo cannot be deleted'),'error'); } else { */ - $sql='SELECT userid FROM audittrail where userid="'. $SelectedUser .'"'; + $sql="SELECT userid FROM audittrail where userid='" . $SelectedUser ."'"; $result=DB_query($sql, $db); if (DB_num_rows($result)!=0) { prnMsg(_('Cannot delete user as entries already exist in the audit trail'), 'warn'); @@ -234,17 +231,17 @@ $result = DB_query($sql,$db); echo '<table class=selection>'; - echo "<tr><th>" . _('User Login') . "</th> - <th>" . _('Full Name') . "</th> - <th>" . _('Telephone') . "</th> - <th>" . _('Email') . "</th> - <th>" . _('Supplier Code') . "</th> - <th>" . _('Last Visit') . "</th> - <th>" . _('Security Role') ."</th> - <th>" . _('Report Size') ."</th> - <th>" . _('Theme') ."</th> - <th>" . _('Language') ."</th> - </tr>"; + echo '<tr><th>' . _('User Login') . '</th> + <th>' . _('Full Name') . '</th> + <th>' . _('Telephone') . '</th> + <th>' . _('Email') . '</th> + <th>' . _('Supplier Code') . '</th> + <th>' . _('Last Visit') . '</th> + <th>' . _('Security Role') .'</th> + <th>' . _('Report Size') .'</th> + <th>' . _('Theme') .'</th> + <th>' . _('Language') .'</th> + </tr>'; $k=0; //row colour counter @@ -261,19 +258,19 @@ /*The SecurityHeadings array is defined in config.php */ - echo "<td>".$myrow['userid']."</td> - <td>".$myrow['realname']."</td> - <td>".$myrow['phone']."</td> - <td>".$myrow['email']."</td> - <td>".$myrow['supplierid']."</td> - <td>".$LastVisitDate."</td> - <td>".$SecurityRoles[($myrow['fullaccess'])]."</td> - <td>".$myrow['pagesize']."</td> - <td>".$myrow['theme']."</td> - <td>".$myrow['language']."</td> - <td><a href=\"".$_SERVER['PHP_SELF'] . "?" . SID."&SelectedUser=".$myrow[0]."\">" . _('Edit') . "</a></td> - <td><a href=\"".$_SERVER['PHP_SELF'] . "?" . SID."&SelectedUser=".$myrow[0]."&delete=1\">" . _('Delete') . "</a></td> - </tr>"; + echo '<td>'.$myrow['userid'].'</td> + <td>'.$myrow['realname'].'</td> + <td>'.$myrow['phone'].'</td> + <td>'.$myrow['email'].'</td> + <td>'.$myrow['supplierid'].'</td> + <td>'.$LastVisitDate.'</td> + <td>'.$SecurityRoles[($myrow['fullaccess'])].'</td> + <td>'.$myrow['pagesize'].'</td> + <td>'.$myrow['theme'].'</td> + <td>'.$myrow['language'].'</td> + <td><a href="' .$_SERVER['PHP_SELF'] . '?SelectedUser=' . $myrow[0] .'">' . _('Edit') . '</a></td> + <td><a href="' . $_SERVER['PHP_SELF'] . '?SelectedUser=' . $myrow[0] . '&delete=1">' . _('Delete') . '</a></td> + </tr>'; } //END WHILE LIST LOOP echo '</table><br>'; @@ -281,10 +278,10 @@ if (isset($SelectedUser)) { - echo "<div class='centre'><a href='" . $_SERVER['PHP_SELF'] ."?" . SID . "'>" . _('Review Existing Users') . '</a></div><br>'; + echo '<div class="centre"><a href="' . $_SERVER['PHP_SELF'] .'?">' . _('Review Existing Users') . '</a></div><br>'; } -echo "<form method='post' action=" . $_SERVER['PHP_SELF'] . "?" . SID . ">"; +echo '<form method="post" action="' . $_SERVER['PHP_SELF'] . '">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; if (isset($SelectedUser)) { @@ -324,9 +321,9 @@ $_POST['UserLanguage'] = $myrow['language']; $_POST['Blocked'] = $myrow['blocked']; - echo "<input type='hidden' name='SelectedUser' value='" . $SelectedUser . "'>"; - echo "<input type='hidden' name='UserID' value='" . $_POST['UserID'] . "'>"; - echo "<input type='hidden' name='ModulesAllowed' value='" . $_POST['ModulesAllowed'] . "'>"; + echo '<input type="hidden" name="SelectedUser" value="' . $SelectedUser . '">'; + echo '<input type="hidden" name="UserID" value="' . $_POST['UserID'] . '">'; + echo '<input type="hidden" name="ModulesAllowed" value="' . $_POST['ModulesAllowed'] . '">'; echo '<table class=selection> <tr><td>' . _('User code') . ':</td><td>'; echo $_POST['UserID'] . '</td></tr>'; @@ -374,16 +371,16 @@ foreach ($SecurityRoles as $SecKey => $SecVal) { if (isset($_POST['Access']) and $SecKey == $_POST['Access']){ - echo "<option selected value=" . $SecKey . ">" . $SecVal; + echo '<option selected value="' . $SecKey . '">' . $SecVal . '</option>'; } else { - echo "<option value=" . $SecKey . ">" . $SecVal; + echo '<option value="' . $SecKey . '">' . $SecVal . '</option>'; } } echo '</select></td></tr>'; echo '<input type="hidden" name="ID" value="'.$_SESSION['UserID'].'">'; -echo '<tr><td>' . _('Default Location') . ":</td> - <td><select name='DefaultLocation'>"; +echo '<tr><td>' . _('Default Location') . ':</td> + <td><select name="DefaultLocation">'; $sql = "SELECT loccode, locationname FROM locations"; $result = DB_query($sql,$db); @@ -392,10 +389,10 @@ if (isset($_POST['DefaultLocation']) and $myrow['loccode'] == $_POST['DefaultLocation']){ - echo "<option selected value='" . $myrow['loccode'] . "'>" . $myrow['locationname']; + echo '<option selected value="' . $myrow['loccode'] . '">' . $myrow['locationname'] . '</option>'; } else { - echo "<option Value='" . $myrow['loccode'] . "'>" . $myrow['locationname']; + echo '<option Value="' . $myrow['loccode'] . '">' . $myrow['locationname'] . '</option>'; } @@ -407,55 +404,55 @@ echo '<tr><td>'._('Supplier Code').':</td> <td>' . $_POST['Supp'] . '</td></tr>'; -echo '<tr><td>' . _('Reports Page Size') .":</td> - <td><select name='PageSize'>"; +echo '<tr><td>' . _('Reports Page Size') .':</td> + <td><select name="PageSize">'; if(isset($_POST['PageSize']) and $_POST['PageSize']=='A4'){ - echo "<option selected value='A4'>" . _('A4'); + echo '<option selected value="A4">' . _('A4') . '</option>'; } else { - echo "<option value='A4'>A4"; + echo '<option value="A4">' . _('A4') . '</option>'; } if(isset($_POST['PageSize']) and $_POST['PageSize']=='A3'){ - echo "<option selected Value='A3'>" . _('A3'); + echo '<option selected value="A3">' . _('A3') . '</option>'; } else { - echo "<option value='A3'>A3"; + echo '<option value="A3">' . _('A3') . '</option>'; } if(isset($_POST['PageSize']) and $_POST['PageSize']=='A3_landscape'){ - echo "<option selected Value='A3_landscape'>" . _('A3') . ' ' . _('landscape'); + echo '<option selected Value="A3_landscape">' . _('A3') . ' ' . _('landscape') . '</option>'; } else { - echo "<option value='A3_landscape'>" . _('A3') . ' ' . _('landscape'); + echo '<option value="A3_landscape">' . _('A3') . ' ' . _('landscape') . '</option>'; } if(isset($_POST['PageSize']) and $_POST['PageSize']=='letter'){ - echo "<option selected Value='letter'>" . _('Letter'); + echo '<option selected value="letter">' . _('Letter') . '</option>'; } else { - echo "<option value='letter'>" . _('Letter'); + echo '<option value="letter">' . _('Letter') . '</option>'; } if(isset($_POST['PageSize']) and $_POST['PageSize']=='letter_landscape'){ - echo "<option selected Value='letter_landscape'>" . _('Letter') . ' ' . _('landscape'); + echo '<option selected value="letter_landscape">' . _('Letter') . ' ' . _('landscape') . '</option>'; } else { - echo "<option value='letter_landscape'>" . _('Letter') . ' ' . _('landscape'); + echo '<option value="letter_landscape">' . _('Letter') . ' ' . _('landscape') . '</option>'; } if(isset($_POST['PageSize']) and $_POST['PageSize']=='legal'){ - echo "<option selected value='legal'>" . _('Legal'); + echo '<option selected value="legal">' . _('Legal') . '</option>'; } else { - echo "<option Value='legal'>" . _('Legal'); + echo '<option Value="legal">' . _('Legal') . '</option>'; } if(isset($_POST['PageSize']) and $_POST['PageSize']=='legal_landscape'){ - echo "<option selected value='legal_landscape'>" . _('Legal') . ' ' . _('landscape'); + echo '<option selected value="legal_landscape">' . _('Legal') . ' ' . _('landscape') . '</option>'; } else { - echo "<option value='legal_landscape'>" . _('Legal') . ' ' . _('landscape'); + echo '<option value="legal_landscape">' . _('Legal') . ' ' . _('landscape') . '</option>'; } echo '</select></td></tr>'; echo '<tr> - <td>' . _('Theme') . ":</td> - <td><select name='Theme'>"; + <td>' . _('Theme') . ':</td> + <td><select name="Theme">'; $ThemeDirectory = dir('css/'); @@ -465,11 +462,11 @@ if (is_dir("css/$ThemeName") AND $ThemeName != '.' AND $ThemeName != '..' AND $ThemeName != 'CVS'){ if (isset($_POST['Theme']) and $_POST['Theme'] == $ThemeName){ - echo "<option selected value='$ThemeName'>$ThemeName"; + echo '<option selected value="' . $ThemeName . '">' . $ThemeName . '</option>'; } else if (!isset($_POST['Theme']) and ($_SESSION['DefaultTheme']==$ThemeName)) { - echo "<option selected value='$ThemeName'>$ThemeName"; + echo '<option selected value="' . $ThemeName . '">' . $ThemeName . '</option>'; } else { - echo "<option value='$ThemeName'>$ThemeName"; + echo '<option value="' . $ThemeName . '">' . $ThemeName . '</option>'; } } } @@ -478,8 +475,8 @@ echo '<tr> - <td>' . _('Language') . ":</td> - <td><select name='UserLanguage'>"; + <td>' . _('Language') . ':</td> + <td><select name="UserLanguage">'; $LangDirHandle = dir('locale/'); @@ -489,11 +486,11 @@ if (is_dir('locale/' . $LanguageEntry) AND $LanguageEntry != '..' AND $LanguageEntry != 'CVS' AND $LanguageEntry!='.'){ if (isset($_POST['UserLanguage']) and $_POST['UserLanguage'] == $LanguageEntry){ - echo "<option selected value='$LanguageEntry'>$LanguageEntry"; + echo '<option selected value="' . $LanguageEntry . '">' . $LanguageEntry . '</option>'; } elseif (!isset($_POST['UserLanguage']) and $LanguageEntry == $DefaultLanguage) { - echo "<option selected value='$LanguageEntry'>$LanguageEntry"; + echo '<option selected value="' . $LanguageEntry . '">' . $LanguageEntry . '</option>'; } else { - echo "<option value='$LanguageEntry'>$LanguageEntry"; + echo '<option value="' . $LanguageEntry . '">' . $LanguageEntry . '</option>'; } } } @@ -519,11 +516,11 @@ echo '<tr><td>' . _('Account Status') . ":</td><td><select name='Blocked'>"; if ($_POST['Blocked']==0){ - echo '<option selected value=0>' . _('Open'); - echo '<option value=1>' . _('Blocked'); + echo '<option selected value=0>' . _('Open') . '</option>'; + echo '<option value=1>' . _('Blocked') . '</option>'; } else { - echo '<option selected value=1>' . _('Blocked'); - echo '<option value=0>' . _('Open'); + echo '<option selected value=1>' . _('Blocked') . '</option>'; + echo '<option value=0>' . _('Open') . '</option>'; } echo '</select></td></tr>'; Modified: trunk/SuppShiptChgs.php =================================================================== --- trunk/SuppShiptChgs.php 2011-04-05 10:14:24 UTC (rev 4539) +++ trunk/SuppShiptChgs.php 2011-04-06 10:01:30 UTC (rev 4540) @@ -10,8 +10,6 @@ include('includes/DefineSuppTransClass.php'); -//$PageSecurity = 5; - /* Session started here for password checking and authorisation level check */ include('includes/session.inc'); @@ -20,14 +18,14 @@ include('includes/header.inc'); if ($_SESSION['SuppTrans']->InvoiceOrCredit == 'Invoice'){ - echo '<a href="' . $rootpath . '/SupplierInvoice.php?' . SID . '">' . _('Back to Invoice Entry') . '</a>'; + echo '<a href="' . $rootpath . '/SupplierInvoice.php">' . _('Back to Invoice Entry') . '</a>'; } else { - echo '<a href="' . $rootpath . '/SupplierCredit.php?' . SID . '">' . _('Back to Credit Note Entry') . '</a>'; + echo '<a href="' . $rootpath . '/SupplierCredit.php">' . _('Back to Credit Note Entry') . '</a>'; } if (!isset($_SESSION['SuppTrans'])){ prnMsg(_('Shipment charges or credits are entered against supplier invoices or credit notes respectively') . '. ' . _('To enter supplier transactions the supplier must first be selected from the supplier selection screen') . ', ' . _('then the link to enter a supplier invoice or credit note must be clicked on'),'info'); - echo "<br><a href='$rootpath/SelectSupplier.php?" . SID ."'>" . _('Select A Supplier') . '</a>'; + echo '<br /><a href="' . $rootpath . '/SelectSupplier.php">' . _('Select A Supplier') . '</a>'; exit; /*It all stops here if there aint no supplier selected and invoice/credit initiated ie $_SESSION['SuppTrans'] started off*/ } @@ -37,8 +35,13 @@ if (isset($_POST['AddShiptChgToInvoice'])){ $InputError = False; - if ($_POST['ShiptRef'] == ""){ - $_POST['ShiptRef'] = $_POST['ShiptSelection']; + if ($_POST['ShiptRef'] == ''){ + if ($_POST['ShiptSelection']==''){ + prnMsg(_('Shipment charges must reference a shipment. It appears that no shipment has been entered'),'error'); + $InputError = True; + } else { + $_POST['ShiptRef'] = $_POST['ShiptSelection']; + } } else { $result = DB_query("SELECT shiptref FROM shipments WHERE shiptref='". $_POST['ShiptRef'] . "'",$db); if (DB_num_rows($result)==0) { @@ -96,7 +99,7 @@ </table><br />'; /*Set up a form to allow input of new Shipment charges */ -echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID . '" method="post">'; +echo '<form action="' . $_SERVER['PHP_SELF'] . '" method="post">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; if (!isset($_POST['ShiptRef'])) { @@ -104,24 +107,24 @@ } echo '<table class=selection>'; echo '<tr><td>' . _('Shipment Reference') . ':</td> - <td><input type="text" name="ShiptRef" size="12" maxlength="11" VALUE="' . $_POST['ShiptRef'] . '"></td></tr>'; -echo '<tr><td>' . _('Shipment Selection') . ':<br> ' . _('If you know the code enter it above') . '<br>' . _('otherwise select the shipment from the list') . '</td><td><select name="ShiptSelection">'; + <td><input type="text" name="ShiptRef" size="12" maxlength="11" value="' . $_POST['ShiptRef'] . '"></td></tr>'; +echo '<tr><td>' . _('Shipment Selection') . ':<br /> ' . _('If you know the code enter it above') . '<br />' . _('otherwise select the shipment from the list') . '</td><td><select name="ShiptSelection">'; -$sql = 'SELECT shiptref, - vessel, - eta, - suppname - FROM shipments INNER JOIN suppliers - ON shipments.supplierid=suppliers.supplierid - WHERE closed=0'; +$sql = "SELECT shiptref, + vessel, + eta, + suppname + FROM shipments INNER JOIN suppliers + ON shipments.supplierid=suppliers.supplierid + WHERE closed='0'"; $result = DB_query($sql, $db); while ($myrow = DB_fetch_array($result)) { if (isset($_POST['ShiptSelection']) and $myrow['shiptref']==$_POST['ShiptSelection']) { - echo '<option selected VALUE='; + echo '<option selected value='; } else { - echo '<option VALUE='; + echo '<option value='; } echo $myrow['shiptref'] . '>' . $myrow['shiptref'] . ' - ' . $myrow['vessel'] . ' ' . _('ETA') . ' ' . ConvertSQLDate($myrow['eta']) . ' ' . _('from') . ' ' . $myrow['suppname'] . '</option>'; } @@ -132,10 +135,10 @@ $_POST['Amount']=0; } echo '<tr><td>' . _('Amount') . ':</td> - <td><input type="text" name="Amount" size="12" maxlength="11" VALUE="' . $_POST['Amount'] . '"></td></tr>'; + <td><input type="text" name="Amount" size="12" maxlength="11" value="' . $_POST['Amount'] . '"></td></tr>'; echo '</table>'; -echo '<br /><div class=centre><input type="submit" name="AddShiptChgToInvoice" VALUE="' . _('Enter Shipment Charge') . '"></div>'; +echo '<br /><div class=centre><input type="submit" name="AddShiptChgToInvoice" value="' . _('Enter Shipment Charge') . '"></div>'; echo '</form>'; include('includes/footer.inc'); Modified: trunk/SuppTransGLAnalysis.php =================================================================== --- trunk/SuppTransGLAnalysis.php 2011-04-05 10:14:24 UTC (rev 4539) +++ trunk/SuppTransGLAnalysis.php 2011-04-06 10:01:30 UTC (rev 4540) @@ -1,13 +1,13 @@ <?php + /* $Id$*/ + /*The supplier transaction uses the SuppTrans class to hold the information about the invoice or credit note the SuppTrans class contains an array of GRNs objects - containing details of GRNs for invoicing/crediting and also an array of GLCodes objects - only used if the AP - GL link is effective */ include('includes/DefineSuppTransClass.php'); -//$PageSecurity = 5; - /* Session started in header.inc for password checking and authorisation level check */ include('includes/session.inc'); @@ -17,7 +17,7 @@ if (!isset($_SESSION['SuppTrans'])){ prnMsg(_('To enter a supplier invoice or credit note the supplier must first be selected from the supplier selection screen') . ', ' . _('then the link to enter a supplier invoice or supplier credit note must be clicked on'),'info'); - echo "<br><a href='$rootpath/SelectSupplier.php?" . SID ."'>" . _('Select A Supplier') . '</a>'; + echo '<br><a href="' . $rootpath . '/SelectSupplier.php">' . _('Select A Supplier') . '</a>'; include('includes/footer.inc'); exit; /*It all stops here if there aint no supplier selected and transaction initiated ie $_SESSION['SuppTrans'] started off*/ @@ -63,10 +63,10 @@ if ($InputError == False){ $_SESSION['SuppTrans']->Add_GLCodes_To_Trans($_POST['GLCode'], - $GLActName, - $_POST['Amount'], - $_POST['JobRef'], - $_POST['Narrative']); + $GLActName, + $_POST['Amount'], + $_POST['JobRef'], + $_POST['Narrative']); unset($_POST['GLCode']); unset($_POST['Amount']); unset($_POST['JobRef']); @@ -92,11 +92,11 @@ echo '</p><table cellpadding=2 class=selection>'; $TableHeader = '<tr> - <th>' . _('Account') . '</th> - <th>' . _('Name') . '</th> - <th>' . _('Amount') . '<br>' . _('in') . ' ' . $_SESSION['SuppTrans']->CurrCode . '</th> - <th>' . _('Narrative') . '</th> - </tr>'; + <th>' . _('Account') . '</th> + <th>' . _('Name') . '</th> + <th>' . _('Amount') . '<br>' . _('in') . ' ' . $_SESSION['SuppTrans']->CurrCode . '</th> + <th>' . _('Narrative') . '</th> + </tr>'; echo $TableHeader; $TotalGLValue=0; $i=0; @@ -107,8 +107,8 @@ <td>' . $EnteredGLCode->GLCode . '</td> <td>' . $EnteredGLCode->GLActName . '</td> <td class=number>' . number_format($EnteredGLCode->Amount,2) . '</td> - <td>' . $EnteredGLCode->Narrative . "</td> - <td><a href='" . $_SERVER['PHP_SELF'] . "?" . SID . "Delete=" . $EnteredGLCode->Counter . "'>" . _('Delete') . '</a></td> + <td>' . $EnteredGLCode->Narrative . '</td> + <td><a href="' . $_SERVER['PHP_SELF'] . '?Delete=' . $EnteredGLCode->Counter . '">' . _('Delete') . '</a></td> </tr>'; $TotalGLValue += $EnteredGLCode->Amount; @@ -128,13 +128,13 @@ if ($_SESSION['SuppTrans']->InvoiceOrCredit == 'Invoice'){ - echo '<br /><a href="' . $rootpath . '/SupplierInvoice.php?' . SID . '">' . _('Back to Invoice Entry') . '</a>'; + echo '<br /><a href="' . $rootpath . '/SupplierInvoice.php">' . _('Back to Invoice Entry') . '</a>'; } else { - echo '<br /><a href="' . $rootpath . '/SupplierCredit.php?' . SID . '">' . _('Back to Credit Note Entry') . '</a>'; + echo '<br /><a href="' . $rootpath . '/SupplierCredit.php">' . _('Back to Credit Note Entry') . '</a>'; } /*Set up a form to allow input of new GL entries */ -echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID . '" method="post">'; +echo '<form action="' . $_SERVER['PHP_SELF'] . '" method="post">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; echo '<br /><table class=selection>'; @@ -150,7 +150,7 @@ <td>' . _('Account Selection') . ':<br>(' . _('If you know the code enter it above') . '<br>' . _('otherwise select the account from the list') . ')</td> <td><select name="AcctSelection">'; -$sql = 'SELECT accountcode, accountname FROM chartmaster ORDER BY accountcode'; +$sql = "SELECT accountcode, accountname FROM chartmaster ORDER BY accountcode"; $result = DB_query($sql, $db); echo '<option value=""></option>'; Modified: trunk/SystemParameters.php =================================================================== --- trunk/SystemParameters.php 2011-04-05 10:14:24 UTC (rev 4539) +++ trunk/SystemParameters.php 2011-04-06 10:01:30 UTC (rev 4540) @@ -2,8 +2,6 @@ /* $Id$*/ -//$PageSecurity =15; - include('includes/session.inc'); $title = _('System Configuration'); @@ -311,10 +309,11 @@ echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; echo '<table cellpadding=2 class=selection width=98%>'; -$TableHeader = '<tr><th>' . _('System Variable Name') . '</th> - <th>' . _('Value') . '</th> - <th>' . _('Notes') . '</th>'; - +$TableHeader = '<tr> + <th>' . _('System Variable Name') . '</th> + <th>' . _('Value') . '</th> + <th>' . _('Notes') . '</th>'; + echo '<tr><th colspan=3>' . _('General Settings') . '</th></tr>'; echo $TableHeader; @@ -334,10 +333,11 @@ $ThemeDirectory = dir('css/'); while (false != ($ThemeName = $ThemeDirectory->read())){ if (is_dir("css/$ThemeName") AND $ThemeName != '.' AND $ThemeName != '..' AND $ThemeName != '.svn'){ - if ($_SESSION['DefaultTheme'] == $ThemeName) - echo "<option selected value='$ThemeName'>$ThemeName"; - else - echo "<option value='$ThemeName'>$ThemeName"; + if ($_SESSION['DefaultTheme'] == $ThemeName) { + echo '<option selected value="' . $ThemeName . '">' . $ThemeName . '</option>'; + } else { + echo '<option value="' . $ThemeName . '">' . $ThemeName . '</option>'; + } } } echo '</select></td> @@ -364,17 +364,17 @@ // Check Credit Limits echo '<tr style="outline: 1px solid"><td>' . _('Check Credit Limits') . ':</td> <td><select Name="X_CheckCreditLimits"> - <option '.($_SESSION['CheckCreditLimits']==0?'selected ':'').'value="0">'._('Do not check').' - <option '.($_SESSION['CheckCreditLimits']==1?'selected ':'').'value="1">'._('Warn on breach').' - <option '.($_SESSION['CheckCreditLimits']==2?'selected ':'').'value="2">'._('Prohibit Sales').' + <option '.($_SESSION['CheckCreditLimits']==0?'selected ':'').'value="0">'._('Do not check').'</option> + <option '.($_SESSION['CheckCreditLimits']==1?'selected ':'').'value="1">'._('Warn on breach').'</option> + <option '.($_SESSION['CheckCreditLimits']==2?'selected ':'').'value="2">'._('Prohibit Sales').'</option> </select></td> <td>' . _('Credit limits can be checked at order entry to warn only or to stop the order from being entered where it would take a customer account balance over their limit') . '</td></tr>'; // Show_Settled_LastMonth echo '<tr style="outline: 1px solid"><td>' . _('Show Settled Last Month') . ':</td> <td><select Name="X_Show_Settled_LastMonth"> - <option '.($_SESSION['Show_Settled_LastMonth']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['Show_Settled_LastMonth']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['Show_Settled_LastMonth']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['Show_Settled_LastMonth']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('This setting refers to the format of customer statements. If the invoices and credit notes that have been paid and settled during the course of the current month should be shown then select Yes. Selecting No will only show currently outstanding invoices, credits and payments that have not been allocated') . '</td></tr>'; @@ -396,15 +396,15 @@ // SO_AllowSameItemMultipleTimes echo '<tr style="outline: 1px solid"><td>' . _('Sales Order Allows Same Item Multiple Times') . ':</td> <td><select Name="X_SO_AllowSameItemMultipleTimes"> - <option '.($_SESSION['SO_AllowSameItemMultipleTimes']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['SO_AllowSameItemMultipleTimes']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['SO_AllowSameItemMultipleTimes']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['SO_AllowSameItemMultipleTimes']?'selected ':'').'value="0">'._('No').'</option> </select></td><td> </td></tr>'; //'AllowOrderLineItemNarrative' echo '<tr style="outline: 1px solid"><td>' . _('Order Entry allows Line Item Narrative') . ':</td> <td><select Name="X_AllowOrderLineItemNarrative"> - <option '.($_SESSION['AllowOrderLineItemNarrative']=='1'?'selected ':'').'value="1">'._('Allow Narrative Entry').' - <option '.($_SESSION['AllowOrderLineItemNarrative']=='0'?'selected ':'').'value="0">'._('No Narrative Line').' + <option '.($_SESSION['AllowOrderLineItemNarrative']=='1'?'selected ':'').'value="1">'._('Allow Narrative Entry').'</option> + <option '.($_SESSION['AllowOrderLineItemNarrative']=='0'?'selected ':'').'value="0">'._('No Narrative Line').'</option> </select></td> <td>' . _('Select whether or not to allow entry of narrative on order line items. This narrative will appear on invoices and packing slips. Useful mainly for service businesses.') . '</td> </tr>'; @@ -412,8 +412,8 @@ //'RequirePickingNote' echo '<tr style="outline: 1px solid"><td>' . _('A picking note must be produced before an order can be delivered') . ':</td> <td><select Name="X_RequirePickingNote"> - <option '.($_SESSION['RequirePickingNote']=='1'?'selected ':'').'value="1">'._('Yes').' - <option '.($_SESSION['RequirePickingNote']=='0'?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['RequirePickingNote']=='1'?'selected ':'').'value="1">'._('Yes').'</option> + <option '.($_SESSION['RequirePickingNote']=='0'?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('Select whether or not a picking note must be produced before an order can be delivered to a customer.') . '</td> </tr>'; @@ -421,8 +421,8 @@ //UpdateCurrencyRatesDaily echo '<tr style="outline: 1px solid"><td>' . _('Auto Update Exchange Rates Daily') . ':</td> <td><select Name="X_UpdateCurrencyRatesDaily"> - <option '.($_SESSION['UpdateCurrencyRatesDaily']!='0'?'selected ':'').'value="1">'._('Automatic').' - <option '.($_SESSION['UpdateCurrencyRatesDaily']=='0'?'selected ':'').'value="0">'._('Manual').' + <option '.($_SESSION['UpdateCurrencyRatesDaily']!='0'?'selected ':'').'value="1">'._('Automatic').'</option> + <option '.($_SESSION['UpdateCurrencyRatesDaily']=='0'?'selected ':'').'value="0">'._('Manual').'</option> </select></td> <td>' . _('Automatic updates to exchange rates will retrieve the latest daily rates from the European Central Bank once per day - when the first user logs in for the day. Manual will never update the rates automatically - exchange rates will need to be maintained manually') . '</td> </tr>'; @@ -430,8 +430,8 @@ //Default Packing Note Format echo '<tr style="outline: 1px solid"><td>' . _('Format of Packing Slips') . ':</td> <td><select Name="X_PackNoteFormat"> - <option '.($_SESSION['PackNoteFormat']=='1'?'selected ':'').'value="1">'._('Laser Printed').' - <option '.($_SESSION['PackNoteFormat']=='2'?'selected ':'').'value="2">'._('Special Stationery').' + <option '.($_SESSION['PackNoteFormat']=='1'?'selected ':'').'value="1">'._('Laser Printed').'</option> + <option '.($_SESSION['PackNoteFormat']=='2'?'selected ':'').'value="2">'._('Special Stationery').'</option> </select></td> <td>' . _('Choose the format that packing notes should be printed by default') . '</td> </tr>'; @@ -439,8 +439,8 @@ //Default Invoice Format echo '<tr style="outline: 1px solid"><td>' . _('Invoice Orientation') . ':</td> <td><select Name="X_InvoicePortraitFormat"> - <option '.($_SESSION['InvoicePortraitFormat']=='0'?'selected ':'').'value="0">'._('Landscape').' - <option '.($_SESSION['InvoicePortraitFormat']=='1'?'selected ':'').'value="1">'._('Portrait').' + <option '.($_SESSION['InvoicePortraitFormat']=='0'?'selected ':'').'value="0">'._('Landscape').'</option> + <option '.($_SESSION['InvoicePortraitFormat']=='1'?'selected ':'').'value="1">'._('Portrait').'</option> </select></td> <td>' . _('Select the invoice layout') . '</td> </tr>'; @@ -448,8 +448,8 @@ //Blind packing note echo '<tr style="outline: 1px solid"><td>' . _('Show company details on packing slips') . ':</td> <td><select Name="X_DefaultBlindPackNote"> - <option '.($_SESSION['DefaultBlindPackNote']=="1"?'selected ':'').'value="1">'._('Show Company Details').' - <option '.($_SESSION['DefaultBlindPackNote']=="2"?'selected ':'').'value="2">'._('Hide Company Details').' + <option '.($_SESSION['DefaultBlindPackNote']=='1'?'selected ':'').'value="1">'._('Show Company Details').'</option> + <option '.($_SESSION['DefaultBlindPackNote']=='2'?'selected ':'').'value="2">'._('Hide Company Details').'</option> </select></td> <td>' . _('Customer branches can be set by default not to print packing slips with the company logo and address. This is useful for companies that ship to customers customers and to show the source of the shipment would be inappropriate. There is an option on the setup of customer branches to ship blind, this setting is the default applied to all new customer branches') . '</td> </tr>'; @@ -465,21 +465,21 @@ // AllowSalesOfZeroCostItems echo '<tr style="outline: 1px solid"><td>' . _('Allow Sales Of Zero Cost Items') . ':</td> <td><select Name="X_AllowSalesOfZeroCostItems"> - <option '.($_SESSION['AllowSalesOfZeroCostItems']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['AllowSalesOfZeroCostItems']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['AllowSalesOfZeroCostItems']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['AllowSalesOfZeroCostItems']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('If an item selected at order entry does not have a cost set up then if this parameter is set to No then the order line will not be able to be entered') . '</td></tr>'; // CreditingControlledItems_MustExist echo '<tr style="outline: 1px solid"><td>' . _('Controlled Items Must Exist For Crediting') . ':</td> <td><select Name="X_CreditingControlledItems_MustExist"> - <option '.($_SESSION['CreditingControlledItems_MustExist']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['CreditingControlledItems_MustExist']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['CreditingControlledItems_MustExist']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['CreditingControlledItems_MustExist']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('This parameter relates to the behaviour of the controlled items code. If a serial numbered item has not previously existed then a credit note for it will not be allowed if this is set to Yes') . '</td></tr>'; // DefaultPriceList -$sql = 'SELECT typeabbrev, sales_type FROM salestypes ORDER BY sales_type'; +$sql = "SELECT typeabbrev, sales_type FROM salestypes ORDER BY sales_type"; $ErrMsg = _('Could not load price lists'); $result = DB_query($sql,$db,$ErrMsg); echo '<tr style="outline: 1px solid"><td>' . _('Default Price List') . ':</td>'; @@ -495,16 +495,16 @@ <td>' . _('This price list is used as a last resort where there is no price set up for an item in the price list that the customer is set up for') . '</td></tr>'; // Default_Shipper -$sql = 'SELECT shipper_id, shippername FROM shippers ORDER BY shippername'; +$sql = "SELECT shipper_id, shippername FROM shippers ORDER BY shippername"; $ErrMsg = _('Could not load shippers'); $result = DB_query($sql,$db,$ErrMsg); echo '<tr style="outline: 1px solid"><td>' . _('Default Shipper') . ':</td>'; echo '<td><select Name="X_Default_Shipper">'; if( DB_num_rows($result) == 0 ) { - echo '<option selected value="">'._('Unavailable'); + echo '<option selected value="">'._('Unavailable') . '</option>'; } else { while( $row = DB_fetch_array($result) ) { - echo '<option '.($_SESSION['Default_Shipper'] == $row['shipper_id']?'selected ':'').'value="'.$row['shipper_id'].'">'.$row['shippername']; + echo '<option '.($_SESSION['Default_Shipper'] == $row['shipper_id']?'selected ':'').'value="'.$row['shipper_id'].'">'.$row['shippername'] . '</option>'; } } echo '</select></td> @@ -513,8 +513,8 @@ // DoFreightCalc echo '<tr style="outline: 1px solid"><td>' . _('Do Freight Calculation') . ':</td> <td><select Name="X_DoFreightCalc"> - <option '.($_SESSION['DoFreightCalc']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['DoFreightCalc']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['DoFreightCalc']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['DoFreightCalc']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('If this is set to Yes then the system will attempt to calculate the freight cost of a dispatch based on the weight and cubic and the data defined for each shipper and their rates for shipping to various locations. The results of this calculation will only be meaningful if the data is entered for the item weight and volume in the stock item setup for all items and the freight costs for each shipper properly maintained.') . '</td></tr>'; @@ -529,26 +529,26 @@ <td><select Name="X_AutoDebtorNo">'; if ($_SESSION['AutoDebtorNo']==0) { - echo '<option selected value=0>' . _('Manual Entry'); - echo '<option value=1>' . _('Automatic'); + echo '<option selected value=0>' . _('Manual Entry') . '</option>'; + echo '<option value=1>' . _('Automatic') . '</option>'; } else { - echo '<option selected value=1>' . _('Automatic'); - echo '<option value=0>' . _('Manual Entry'); + echo '<option selected value=1>' . _('Automatic') . '</option>'; + echo '<option value=0>' . _('Manual Entry') . '</option>'; } echo '</select></td> <td>' . _('Set to Automatic - customer codes are automatically created - as a sequential number') .'</td></tr>'; //==HJ== drop down list for tax category -$sql = 'SELECT taxcatid, taxcatname FROM taxcategories ORDER BY taxcatname'; +$sql = "SELECT taxcatid, taxcatname FROM taxcategories ORDER BY taxcatname"; $ErrMsg = _('Could not load tax categories table'); $result = DB_query($sql,$db,$ErrMsg); echo '<tr style="outline: 1px solid"><td>' . _('Default Tax Category') . ':</td>'; echo '<td><select Name="X_DefaultTaxCategory">'; if( DB_num_rows($result) == 0 ) { - echo '<option selected value="">'._('Unavailable'); + echo '<option selected value="">'._('Unavailable') . '</option>'; } else { while( $row = DB_fetch_array($result) ) { - echo '<option '.($_SESSION['DefaultTaxCategory'] == $row['taxcatid']?'selected ':'').'value="'.$row['taxcatid'].'">'.$row['taxcatname']; + echo '<option '.($_SESSION['DefaultTaxCategory'] == $row['taxcatid']?'selected ':'').'value="'.$row['taxcatid'].'">'.$row['taxcatname'] . '</option>'; } } echo '</select></td> @@ -557,17 +557,17 @@ //TaxAuthorityReferenceName echo '<tr style="outline: 1px solid"><td>' . _('TaxAuthorityReferenceName') . ':</td> - <td><input type="Text" Name="X_TaxAuthorityReferenceName" size=16 maxlength=25 value="' . $_SESSION['TaxAuthorityReferenceName'] . '"></td> + <td><input type="Text" Name="X_TaxAuthotaxcatid, taxcatname FROM taxcategoriesrityReferenceName" size=16 maxlength=25 value="' . $_SESSION['TaxAuthorityReferenceName'] . '"></td> <td>' . _('This parameter is what is displayed on tax invoices and credits for the tax authority of the company eg. in Australian this would by A.B.N.: - in NZ it would be GST No: in the UK it would be VAT Regn. No') .'</td></tr>'; // CountryOfOperation -$sql = 'SELECT currabrev, country FROM currencies ORDER BY country'; +$sql = "SELECT currabrev, country FROM currencies ORDER BY country"; $ErrMsg = _('Could not load the countries from the currency table'); $result = DB_query($sql,$db,$ErrMsg); echo '<tr style="outline: 1px solid"><td>' . _('Country Of Operation') . ':</td>'; echo '<td><select name="X_CountryOfOperation">'; if( DB_num_rows($result) == 0 ) { - echo '<option selected value="">'._('Unavailable'); + echo '<option selected value="">'._('Unavailable') . '</option>'; } else { while( $row = DB_fetch_array($result) ) { echo '<option '.($_SESSION['CountryOfOperation'] == $row['currabrev']?'selected ':'').'value="'.$row['currabrev'].'">'.$row['country'] . '</option>'; @@ -586,8 +586,8 @@ //Show values on GRN echo '<tr style="outline: 1px solid"><td>' . _('Show order values on GRN') . ':</td> <td><select Name="X_ShowValueOnGRN"> - <option '.($_SESSION['ShowValueOnGRN']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['ShowValueOnGRN']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['ShowValueOnGRN']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['ShowValueOnGRN']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('Should the value of the purchased stock be shown on the GRN screen') . '</td> </tr>'; @@ -595,16 +595,16 @@ // Check_Qty_Charged_vs_Del_Qty echo '<tr style="outline: 1px solid"><td>' . _('Check Quantity Charged vs Deliver Qty') . ':</td> <td><select Name="X_Check_Qty_Charged_vs_Del_Qty"> - <option '.($_SESSION['Check_Qty_Charged_vs_Del_Qty']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['Check_Qty_Charged_vs_Del_Qty']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['Check_Qty_Charged_vs_Del_Qty']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['Check_Qty_Charged_vs_Del_Qty']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('In entry of AP invoices this determines whether or not to check the quantities received into stock tie up with the quantities invoiced') .'</td></tr>'; // Check_Price_Charged_vs_Order_Price echo '<tr style="outline: 1px solid"><td>' . _('Check Price Charged vs Order Price') . ':</td> <td><select Name="X_Check_Price_Charged_vs_Order_Price"> - <option '.($_SESSION['Check_Price_Charged_vs_Order_Price']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['Check_Price_Charged_vs_Order_Price']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['Check_Price_Charged_vs_Order_Price']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['Check_Price_Charged_vs_Order_Price']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('In entry of AP invoices this parameter determines whether or not to check invoice prices tie up to ordered prices') .'</td></tr>'; @@ -628,8 +628,8 @@ // AutoAuthorisePO echo '<tr style="outline: 1px solid"><td>' . _('Automatically authorise purchase orders if user has authority') . ':</td> <td><select Name="X_AutoAuthorisePO"> - <option '.($_SESSION['AutoAuthorisePO'] ?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['AutoAuthorisePO'] ?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['AutoAuthorisePO'] ?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['AutoAuthorisePO'] ?'selected ':'').'value="0">'._('No').'</option> </select></td><td>' . _('If the user changing an existing purchase order or adding a new puchase order is set up to authorise purchase orders and the order is within their limit, then the purchase order status is automatically set to authorised') . '</td></tr>'; @@ -652,7 +652,7 @@ echo '<tr style="outline: 1px solid"><td>' . _('Financial Year Ends On') . ':</td> <td><select Name="X_YearEnd">'; for ($i=1; $i <= sizeof($MonthNames); $i++ ) - echo '<option '.($_SESSION['YearEnd'] == $i ? 'selected ' : '').'value="'.$i.'">'.$MonthNames[$i]; + echo '<option '.($_SESSION['YearEnd'] == $i ? 'selected ' : '').'value="'.$i.'">'.$MonthNames[$i] . '</option>'; echo '</select></td> <td>' . _('Defining the month in which the financial year ends enables the system to provide useful defaults for general ledger reports') .'</td></tr>'; @@ -673,9 +673,9 @@ <td>' . _('Picture files of items can be uploaded to the server. The system will check that files uploaded are less than this size (in KB) before they will be allowed to be uploaded. Large pictures will make the system slow and will be difficult to view in the stock maintenance screen.') .'</td> </tr>'; //NumberOfMonthMustBeShown -$sql = 'SELECT confvalue +$sql = "SELECT confvalue FROM `config` - WHERE confname ="numberOfMonthMustBeShown"'; + WHERE confname ='numberOfMonthMustBeShown'"; $ErrMsg = _('Could not load the Number Of Month Must be Shown'); $result = DB_query($sql,$db,$ErrMsg); @@ -700,6 +700,7 @@ if (is_dir($CompanyDirectory . $DirEntry) AND $DirEntry != '..' AND $DirEntry!='.' + AND $DirEntry!='.svn' AND $DirEntry != 'CVS' AND $DirEntry != 'reports' AND $DirEntry != 'locale' @@ -729,6 +730,7 @@ AND $DirEntry != '..' AND $DirEntry != 'includes' AND $DirEntry!='.' + AND $DirEntry!='.svn' AND $DirEntry != 'doc' AND $DirEntry != 'css' AND $DirEntry != 'CVS' @@ -854,7 +856,7 @@ echo '<tr style="outline: 1px solid"><td>' . _('Prohibit GL Journals to Periods Prior To') . ':</td> <td><select Name="X_ProhibitPostingsBefore">'; -$sql = 'SELECT lastdate_in_period FROM periods ORDER BY periodno DESC'; +$sql = "SELECT lastdate_in_period FROM periods ORDER BY periodno DESC"; $ErrMsg = _('Could not load periods table'); $result = DB_query($sql,$db,$ErrMsg); while ($PeriodRow = DB_fetch_row($result)){ @@ -952,8 +954,8 @@ //DefineControlledOnWOEntry echo '<tr style="outline: 1px solid"><td>' . _('Controlled Items Defined At Work Order Entry') . ':</td> <td><select Name="X_DefineControlledOnWOEntry"> - <option '.($_SESSION['DefineControlledOnWOEntry']?'selected ':'').'value="1">'._('Yes').' - <option '.(!$_SESSION['DefineControlledOnWOEntry']?'selected ':'').'value="0">'._('No').' + <option '.($_SESSION['DefineControlledOnWOEntry']?'selected ':'').'value="1">'._('Yes').'</option> + <option '.(!$_SESSION['DefineControlledOnWOEntry']?'selected ':'').'value="0">'._('No').'</option> </select></td> <td>' . _('When set to yes, controlled items are defined at the time of the work order creation. Otherwise controlled items (serial numbers and batch/roll/lot references) are entered at the time the finished items are received against the work order') . '</td></tr>'; @@ -974,7 +976,7 @@ echo '<tr style="outline: 1px solid"><td>' . _('Default Factory Location') . ':</td> <td><select Name="X_DefaultFactoryLocation">'; -$sql = 'SELECT loccode,locationname FROM locations'; +$sql = "SELECT loccode,locationname FROM locations"; $ErrMsg = _('Could not load locations table'); $result = DB_query($sql,$db,$ErrMsg); while ($LocationRow = DB_fetch_array($result)){ @@ -995,7 +997,9 @@ <td>' . _('The email address for the purchasing manager, used to receive notifications by the tendering system') .'</td></tr>'; -echo '</table><br /><div class="centre"><input type="Submit" Name="submit" value="' . _('Update') . '"></div></form>'; +echo '</table> + <br /><div class="centre"><input type="Submit" Name="submit" value="' . _('Update') . '"></div> + </form>'; include('includes/footer.inc'); ?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |