From: <tim...@us...> - 2011-02-08 15:48:08
|
Revision: 4488 http://web-erp.svn.sourceforge.net/web-erp/?rev=4488&view=rev Author: tim_schofield Date: 2011-02-08 15:48:02 +0000 (Tue, 08 Feb 2011) Log Message: ----------- Rework CounterSales.php so that it is now possible to sell items that have sales/purchasing tax Modified Paths: -------------- trunk/CounterSales.php trunk/doc/Change.log.html trunk/includes/DefineCartClass.php Modified: trunk/CounterSales.php =================================================================== --- trunk/CounterSales.php 2011-02-08 09:41:58 UTC (rev 4487) +++ trunk/CounterSales.php 2011-02-08 15:48:02 UTC (rev 4488) @@ -455,7 +455,6 @@ unset($NewItem); } /* end of if quick entry */ - /*Now do non-quick entry delete/edits/adds */ if ((isset($_SESSION['Items'.$identifier])) OR isset($NewItem)) { @@ -513,7 +512,47 @@ } } +if (isset($_POST['Recalculate'])) { + foreach ($_SESSION['Items'.$identifier]->LineItems as $OrderLine) { + $NewItem=$OrderLine->StockID; + $sql = "SELECT stockmaster.mbflag, stockmaster.controlled + FROM stockmaster + WHERE stockmaster.stockid='". $OrderLine->StockID."'"; + $ErrMsg = _('Could not determine if the part being ordered was a kitset or not because'); + $DbgMsg = _('The sql that was used to determine if the part being ordered was a kitset or not was '); + $KitResult = DB_query($sql, $db,$ErrMsg,$DbgMsg); + if ($myrow=DB_fetch_array($KitResult)){ + if ($myrow['mbflag']=='K'){ /*It is a kit set item */ + $sql = "SELECT bom.component, + bom.quantity + FROM bom + WHERE bom.parent='" . $OrderLine->StockID. "' + AND bom.effectiveto > '" . Date('Y-m-d') . "' + AND bom.effectiveafter < '" . Date('Y-m-d') . "'"; + + $ErrMsg = _('Could not retrieve kitset components from the database because'); + $KitResult = DB_query($sql,$db,$ErrMsg); + + $ParentQty = $NewItemQty; + while ($KitParts = DB_fetch_array($KitResult,$db)){ + $NewItem = $KitParts['component']; + $NewItemQty = $KitParts['quantity'] * $ParentQty; + $NewPOLine = 0; + $NewItemDue = date($_SESSION['DefaultDateFormat']); + $_SESSION['Items'.$identifier]->GetTaxes($OrderLine->LineNumber); + } + + } else { /*Its not a kit set item*/ + $NewItemDue = date($_SESSION['DefaultDateFormat']); + $NewPOLine = 0; + $_SESSION['Items'.$identifier]->GetTaxes($OrderLine->LineNumber); + } + } + unset($NewItem); + } /* end of if its a new item */ +} + if (isset($NewItem)){ /* get the item details from the database and hold them in the cart object make the quantity 1 by default then add it to the cart Now figure out if the item is a kit set - the field MBFlag='K' @@ -735,7 +774,8 @@ } $TaxTotal += $TaxLineTotal; - + $_SESSION['Items'.$identifier]->TaxTotals=$TaxTotals; + $_SESSION['Items'.$identifier]->TaxGLCodes=$TaxGLCodes; echo '<td class="number">' . number_format($TaxLineTotal ,2) . '</td>'; echo '<td class="number">' . number_format($SubTotal + $TaxLineTotal ,2) . '</td>'; echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?' . SID .'&identifier='.$identifier . '&Delete=' . $OrderLine->LineNumber . '" onclick="return confirm(\'' . _('Are You Sure?') . '\');">' . _('Delete') . '</a></td></tr>'; @@ -759,6 +799,7 @@ <td class="number">' . number_format(($_SESSION['Items'.$identifier]->total+$TaxTotal),2) . '</td> </tr> </table>'; + echo '<input type="hidden" name="TaxTotal" value="'.$TaxTotal.'" />'; echo '<table><tr><td>'; //nested table echo '<table><tr> @@ -784,7 +825,7 @@ echo '</td><th valign="bottom">'; //for the master table echo '<table class="selection">'; // a new nested table in the second column of master table //now the payment stuff in this column - $PaymentMethodsResult = DB_query('SELECT paymentid, paymentname FROM paymentmethods',$db); + $PaymentMethodsResult = DB_query("SELECT paymentid, paymentname FROM paymentmethods",$db); echo '<tr><td>' . _('Payment Type') . ':</td><td><select name="PaymentMethod">'; while ($PaymentMethodRow = DB_fetch_array($PaymentMethodsResult)){ @@ -796,7 +837,7 @@ } echo '</select></td></tr>'; - $BankAccountsResult = DB_query('SELECT bankaccountname, accountcode FROM bankaccounts',$db); + $BankAccountsResult = DB_query("SELECT bankaccountname, accountcode FROM bankaccounts",$db); echo '<tr><td>' . _('Banked to') . ':</td><td><select name="BankAccount">'; while ($BankAccountsRow = DB_fetch_array($BankAccountsResult)){ @@ -817,6 +858,7 @@ echo '</th></tr></table>'; //end of column/row/master table echo '<br /><div class="centre"><input type="submit" name="Recalculate" value="' . _('Re-Calculate') . '" /> <input type="submit" name="ProcessSale" value="' . _('Process The Sale') . '" /></div><hr />'; + } # end of if lines /* ********************************** @@ -831,7 +873,7 @@ prnMsg(_('There are no lines on this sale. Please enter lines to invoice first'),'error'); $InputError = true; } - if (abs($_POST['AmountPaid'] -($_SESSION['Items'.$identifier]->total+$TaxTotal))>=0.01) { + if (abs($_POST['AmountPaid'] -($_SESSION['Items'.$identifier]->total+$_POST['TaxTotal']))>=0.01) { prnMsg(_('The amount entered as payment does not equal the amount of the invoice. Please ensure the customer has paid the correct amount and re-enter'),'error'); $InputError = true; } @@ -963,7 +1005,7 @@ $ErrMsg = _('The order cannot be added because'); $InsertQryResult = DB_query($HeaderSQL,$db,$ErrMsg); - $StartOf_LineItemsSQL = 'INSERT INTO salesorderdetails (orderlineno, + $StartOf_LineItemsSQL = "INSERT INTO salesorderdetails (orderlineno, orderno, stkcode, unitprice, @@ -974,7 +1016,7 @@ actualdispatchdate, qtyinvoiced, completed) - VALUES ('; + VALUES ("; $DbgMsg = _('Trouble inserting a line of a sales order. The SQL that failed was'); foreach ($_SESSION['Items'.$identifier]->LineItems as $StockItem) { @@ -1103,7 +1145,7 @@ WoRealRequirements($db, $WONo, $_SESSION['DefaultFactoryLocation'], $StockItem->StockID); $FactoryManagerEmail = _('A new work order has been created for') . - ":\n" . $StockItem->StockID . ' - ' . $StockItem->Descr . ' x ' . $WOQuantity . ' ' . $StockItem->UOM . + ":\n" . $StockItem->StockID . ' - ' . $StockItem->ItemDescription . ' x ' . $WOQuantity . ' ' . $StockItem->Units . "\n" . _('These are for') . ' ' . $_SESSION['Items'.$identifier]->CustomerName . ' ' . _('there order ref') . ': ' . $_SESSION['Items'.$identifier]->CustRef . ' ' ._('our order number') . ': ' . $OrderNo; if ($StockItem->Serialised AND $StockItem->NextSerialNo>0){ @@ -1199,11 +1241,11 @@ '" . $_SESSION['Items'.$identifier]->DefaultSalesType . "', '" . $OrderNo . "', '" . $_SESSION['Items'.$identifier]->total . "', - '" . $TaxTotal . "', + '" . $_POST['TaxTotal'] . "', '" . $ExRate . "', '" . $_SESSION['Items'.$identifier]->Comments . "', '" . $_SESSION['Items'.$identifier]->ShipVia . "', - '" . ($_SESSION['Items'.$identifier]->total + $TaxTotal) . "')"; + '" . ($_SESSION['Items'.$identifier]->total + $_POST['TaxTotal']) . "')"; $ErrMsg =_('CRITICAL ERROR') . '! ' . _('NOTE DOWN THIS ERROR AND SEEK ASSISTANCE') . ': ' . _('The debtor transaction record could not be inserted because'); $DbgMsg = _('The following SQL to insert the debtor transaction record was used'); @@ -1212,7 +1254,7 @@ $DebtorTransID = DB_Last_Insert_ID($db,'debtortrans','id'); /* Insert the tax totals for each tax authority where tax was charged on the invoice */ - foreach ($TaxTotals AS $TaxAuthID => $TaxAmount) { + foreach ($_SESSION['Items'.$identifier]->TaxTotals AS $TaxAuthID => $TaxAmount) { $SQL = "INSERT INTO debtortranstaxes (debtortransid, taxauthid, @@ -1691,7 +1733,7 @@ if ($_SESSION['CompanyRecord']['gllink_debtors']==1){ /*Post debtors transaction to GL debit debtors, credit freight re-charged and credit sales */ - if (($_SESSION['Items'.$identifier]->total + $TaxTotal) !=0) { + if (($_SESSION['Items'.$identifier]->total + $_POST['TaxTotal']) !=0) { $SQL = "INSERT INTO gltrans ( type, typeno, trandate, @@ -1705,7 +1747,7 @@ '" . $PeriodNo . "', '" . $_SESSION['CompanyRecord']['debtorsact'] . "', '" . $_SESSION['Items'.$identifier]->DebtorNo . "', - '" . (($_SESSION['Items'.$identifier]->total + $TaxTotal)/$ExRate) . "')"; + '" . (($_SESSION['Items'.$identifier]->total + $_POST['TaxTotal'])/$ExRate) . "')"; $ErrMsg = _('CRITICAL ERROR') . '! ' . _('NOTE DOWN THIS ERROR AND SEEK ASSISTANCE') . ': ' . _('The total debtor GL posting could not be inserted because'); $DbgMsg = _('The following SQL to insert the total debtors control GLTrans record was used'); @@ -1713,7 +1755,7 @@ } - foreach ( $TaxTotals as $TaxAuthID => $TaxAmount){ + foreach ( $_SESSION['Items'.$identifier]->TaxTotals as $TaxAuthID => $TaxAmount){ if ($TaxAmount !=0 ){ $SQL = "INSERT INTO gltrans ( type, typeno, @@ -1726,7 +1768,7 @@ '" . $InvoiceNo . "', '" . $DefaultDispatchDate . "', '" . $PeriodNo . "', - '" . $TaxGLCodes[$TaxAuthID] . "', + '" . $_SESSION['Items'.$identifier]->TaxGLCodes[$TaxAuthID] . "', '" . $_SESSION['Items'.$identifier]->DebtorNo . "', '" . (-$TaxAmount/$ExRate) . "')"; @@ -1993,7 +2035,7 @@ AND purchorders.status<>'Cancelled' AND purchorders.status<>'Rejected' AND purchorderdetails.itemcode='" . $myrow['stockid'] . "'"; - + $ErrMsg = _('The order details for this product cannot be retrieved because'); $PurchResult = db_query($sql,$db,$ErrMsg); @@ -2140,7 +2182,7 @@ $QOHSql = "SELECT sum(quantity) AS QOH, stockmaster.decimalplaces FROM locstock INNER JOIN stockmaster - WHERE locstock.stockid='" .$myrow['stockid'] . "' + WHERE locstock.stockid='" .$myrow['stockid'] . "' AND loccode = '" . $_SESSION['Items'.$identifier]->Location . "'"; $QOHResult = DB_query($QOHSql,$db); $QOHRow = DB_fetch_array($QOHResult); @@ -2149,10 +2191,10 @@ // Find the quantity on outstanding sales orders $sql = "SELECT SUM(salesorderdetails.quantity-salesorderdetails.qtyinvoiced) AS dem FROM salesorderdetails INNER JOIN salesorders - ON salesorders.orderno = salesorderdetails.orderno - WHERE salesorders.fromstkloc='" . $_SESSION['Items'.$identifier]->Location . "' - AND salesorderdetails.completed=0 - AND salesorders.quotation=0 + ON salesorders.orderno = salesorderdetails.orderno + WHERE salesorders.fromstkloc='" . $_SESSION['Items'.$identifier]->Location . "' + AND salesorderdetails.completed=0 + AND salesorders.quotation=0 AND salesorderdetails.stkcode='" . $myrow['stockid'] . "'"; $ErrMsg = _('The demand for this product from') . ' ' . $_SESSION['Items'.$identifier]->Location . ' ' . _('cannot be retrieved because'); @@ -2168,7 +2210,7 @@ // Find the quantity on purchase orders $sql = "SELECT SUM(purchorderdetails.quantityord-purchorderdetails.quantityrecd) AS QOO FROM purchorderdetails INNER JOIN purchorders - WHERE purchorderdetails.completed=0 + WHERE purchorderdetails.completed=0 AND purchorders.status <>'Cancelled' AND purchorders.status <>'Rejected' AND purchorderdetails.itemcode='" . $myrow['stockid'] . "'"; @@ -2288,4 +2330,4 @@ } echo '</form>'; include('includes/footer.inc'); -?> \ No newline at end of file +?> Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-08 09:41:58 UTC (rev 4487) +++ trunk/doc/Change.log.html 2011-02-08 15:48:02 UTC (rev 4488) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p <p></p> +<p>8/2/11: Tim Rework CounterSales.php so that it is now possible to sell items that have sales/purchasing tax</p> <p>8/2/11: Phil Fix InventoryPlanning and InventoryPlanningPrefSupplier to only show sales order demand - excluding quotations. Also fixed for conversionfactor as now all purchase order quantities are in our normal stock units</p> <p>8/2/11: Phil Fix incorrect layout of narrative on multiple lines of PDFQuotation.php as reported by Ricard Andreu</p> <p>8/2/11: Tim/Ricard StockLocTransfer.php can now transfer the same amount as on hand in the location - previously checked to see that the transfer was less than the quantity on hand (when checking for negative stock)</p> Modified: trunk/includes/DefineCartClass.php =================================================================== --- trunk/includes/DefineCartClass.php 2011-02-08 09:41:58 UTC (rev 4487) +++ trunk/includes/DefineCartClass.php 2011-02-08 15:48:02 UTC (rev 4488) @@ -56,6 +56,8 @@ VAR $vtigerProductID; Var $DefaultPOLine; Var $DeliveryDays; + var $TaxTotals; + var $TaxGLCodes; function Cart(){ /*Constructor function initialises a new shopping cart */ @@ -338,7 +340,7 @@ $ErrMsg = _('The taxes and rates for this item could not be retrieved because'); $GetTaxRatesResult = DB_query($SQL,$db,$ErrMsg); - + unset($this->LineItems[$LineNumber]->Taxes); while ($myrow = DB_fetch_array($GetTaxRatesResult)){ $this->LineItems[$LineNumber]->Taxes[$myrow['calculationorder']] = new Tax($myrow['calculationorder'], This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-13 04:15:48
|
Revision: 4490 http://web-erp.svn.sourceforge.net/web-erp/?rev=4490&view=rev Author: daintree Date: 2011-02-13 04:15:38 +0000 (Sun, 13 Feb 2011) Log Message: ----------- pre 4.03RC1 Modified Paths: -------------- trunk/Contracts.php trunk/GoodsReceived.php trunk/GoodsReceivedControlled.php trunk/PricesByCost.php trunk/SelectOrderItems.php trunk/StockSerialItems.php trunk/SuppInvGRNs.php trunk/SystemParameters.php trunk/UpgradeDatabase.php trunk/doc/Change.log.html trunk/doc/INSTALL.txt trunk/includes/ConnectDB.inc trunk/includes/InputSerialItems.php trunk/includes/InputSerialItemsExisting.php trunk/includes/InputSerialItemsFile.php trunk/includes/InputSerialItemsKeyed.php trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.mo trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po trunk/locale/de_DE.utf8/LC_MESSAGES/messages.mo trunk/locale/de_DE.utf8/LC_MESSAGES/messages.po trunk/locale/el_GR.utf8/LC_MESSAGES/messages.mo trunk/locale/el_GR.utf8/LC_MESSAGES/messages.po trunk/locale/en_GB.utf8/LC_MESSAGES/messages.pot trunk/locale/en_US.utf8/LC_MESSAGES/messages.mo trunk/locale/en_US.utf8/LC_MESSAGES/messages.po trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/et_EE.utf8/LC_MESSAGES/messages.mo trunk/locale/et_EE.utf8/LC_MESSAGES/messages.po trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.mo trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.mo trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.po trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.mo trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.po trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.mo trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.po trunk/locale/id_ID.utf8/LC_MESSAGES/messages.mo trunk/locale/id_ID.utf8/LC_MESSAGES/messages.po trunk/locale/it_IT.utf8/LC_MESSAGES/messages.mo trunk/locale/it_IT.utf8/LC_MESSAGES/messages.po trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.mo trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.po trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.mo trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.po trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.mo trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.po trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.mo trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.po trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.po trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.po trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.mo trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.po trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.mo trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.po trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.mo trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.po trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.mo trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.po trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.mo trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.po trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.mo trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.po trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.po trunk/sql/mysql/upgrade3.11.1-4.00.sql trunk/sql/mysql/weberp-demo.sql trunk/sql/mysql/weberp-new.sql Modified: trunk/Contracts.php =================================================================== --- trunk/Contracts.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/Contracts.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -667,23 +667,37 @@ if (DB_num_rows($result_CustSelect)==1){ $myrow=DB_fetch_array($result_CustSelect); - $_POST['SelectedCustomer'] = $myrow['debtorno'] . '-' . $myrow['branchcode']; + $SelectedCustomer = $myrow['debtorno'] . '-' . $myrow['branchcode']; } elseif (DB_num_rows($result_CustSelect)==0){ prnMsg(_('No Customer Branch records contain the search criteria') . ' - ' . _('please try again') . ' - ' . _('Note a Customer Branch Name may be different to the Customer Name'),'info'); } } /*one of keywords or custcode was more than a zero length string */ } /*end of if search for customer codes/names */ +if (isset($_POST['JustSelectedACustomer'])){ + /*Need to figure out the number of the form variable that the user clicked on */ + for ($i=1;$i<count($_POST);$i++){ //loop through the returned customers + if(isset($_POST['SubmitCustomerSelection'.$i])){ + break; + } + } + if ($i==count($_POST)){ + prnMsg(_('Unable to identify the selected customer'),'error'); + } else { + $SelectedCustomer = $_POST['SelectedCustomer'.$i]; + } +} -if (isset($_POST['SelectedCustomer'])) { +if (isset($SelectedCustomer)) { -/* will only be true if page called from customer selection form - * or set because only one customer record returned from a search - * so parse the $Select string into debtorno and branch code */ - $CustomerBranchArray = explode('-',$_POST['SelectedCustomer']); +/* will only be true if page called from customer selection + * or set because only one customer record returned from a search - isset($SelectedCustomer) + * so parse the returned SelectedCustomer string into debtorno and branch code */ + + $CustomerBranchArray = explode('-',$SelectedCustomer); $_SESSION['Contract'.$identifier]->DebtorNo = trim($CustomerBranchArray[0]); $_SESSION['Contract'.$identifier]->BranchCode = trim($CustomerBranchArray[1]); - + $sql = "SELECT debtorsmaster.name, custbranch.brname, debtorsmaster.currcode, @@ -699,8 +713,7 @@ WHERE debtorsmaster.debtorno='" . $_SESSION['Contract'.$identifier]->DebtorNo . "' AND custbranch.branchcode='" . $_SESSION['Contract'.$identifier]->BranchCode . "'" ; - $ErrMsg = _('The customer record selected') . ': ' . $_POST['SelectedCustomer'] . ' ' . - _('cannot be retrieved because'); + $ErrMsg = _('The customer record selected') . ': ' .$_SESSION['Contract'.$identifier]->DebtorNo. ' ' . _('cannot be retrieved because'); $DbgMsg = _('The SQL used to retrieve the customer details and failed was'); $result = DB_query($sql,$db,$ErrMsg,$DbgMsg); $myrow = DB_fetch_array($result); @@ -783,8 +796,8 @@ } else { echo '<td></td>'; } - echo '<td><input tabindex="'.number_format($j+5).'" type="submit" name="Submit" value="'.htmlentities($myrow['brname']).'" /></td> - <input type="hidden" name="SelectedCustomer" value="'.$myrow['debtorno'].' - '.$myrow['branchcode'].'" /> + echo '<td><input tabindex="'.($j+5).'" type="submit" name="SubmitCustomerSelection' . $j .'" value="'.htmlentities($myrow['brname']).'" /></td> + <input type="hidden" name="SelectedCustomer' . $j .'" value="'.$myrow['debtorno'].' - '.$myrow['branchcode'].'" /> <td>'.htmlentities($myrow['contactname']).'</td> <td>'.$myrow['phoneno'].'</td> <td>'.$myrow['faxno'].'</td> @@ -794,7 +807,8 @@ //end of page full new headings if } //end of while loop - + echo '<input type="hidden" name="JustSelectedACustomer" value="Yes">'; + echo '</table></form>'; }//end if results to show Modified: trunk/GoodsReceived.php =================================================================== --- trunk/GoodsReceived.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/GoodsReceived.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -26,13 +26,13 @@ $title = _('Receive Purchase Orders'); include('includes/header.inc'); -echo '<a href="'. $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">' . _('Back to Purchase Orders'). '</a><br>'; +echo '<a href="'. $rootpath . '/PO_SelectOSPurchOrder.php">' . _('Back to Purchase Orders'). '</a><br />'; if (isset($_GET['PONumber']) and $_GET['PONumber']<=0 and !isset($_SESSION['PO'.$identifier])) { /* This page can only be called with a purchase order number for invoicing*/ echo '<div class="centre"><a href= "' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">'. _('Select a purchase order to receive').'</a></div>'; - echo '<br>'. _('This page can only be opened if a purchase order has been selected. Please select a purchase order first'); + echo '<br />'. _('This page can only be opened if a purchase order has been selected. Please select a purchase order first'); include ('includes/footer.inc'); exit; } elseif (isset($_GET['PONumber']) AND !isset($_POST['Update'])) { @@ -55,7 +55,7 @@ } if ($_SESSION['PO'.$identifier]->Status != 'Printed') { - prnMsg( _('Purchase orders must have a status of Printed before they can be received').'.<br>'. + prnMsg( _('Purchase orders must have a status of Printed before they can be received').'.<br />'. _('Order number') . ' ' . $_GET['PONumber'] . ' ' . _('has a status of') . ' ' . _($_SESSION['PO'.$identifier]->Status), 'warn'); include('includes/footer.inc'); exit; @@ -78,7 +78,7 @@ echo '<table class=selection><tr><td>'. _('Date Goods/Service Received'). ':</td><td><input type=text class=date alt="'. $_SESSION['DefaultDateFormat'] .'" maxlength=10 size=10 onChange="return isDate(this, this.value, '."'". $_SESSION['DefaultDateFormat']."'".')" name=DefaultReceivedDate value="' . $_POST['DefaultReceivedDate'] . - '"></td></tr></table><br>'; + '"></td></tr></table><br />'; echo '<table cellpadding=2 class=selection> <tr><th colspan="2"></th> @@ -88,17 +88,17 @@ </tr> <tr><th>' . _('Item Code') . '</th> <th>' . _('Description') . '</th> - <th>' . _('Quantity') . '<br>' . _('Ordered') . '</th> + <th>' . _('Quantity') . '<br />' . _('Ordered') . '</th> <th>' . _('Units') . '</th> <th>' . _('Already') . '<br />' . _('Received') . '</th> <th>' . _('Conversion') . '<br />' . _('Factor') . '</th> - <th>' . _('Quantity') . '<br>' . _('Ordered') . '</th> + <th>' . _('Quantity') . '<br />' . _('Ordered') . '</th> <th>' . _('Units') . '</th> <th>' . _('Already') . '<br />' . _('Received') . '</th> <th>' . _('This Delivery') . '<br />' . _('Quantity') . '</th>'; if ($_SESSION['ShowValueOnGRN']==1) { - echo '<th>' . _('Price') . '</th><th>' . _('Total Value') . '<br>' . _('Received') . '</th>'; + echo '<th>' . _('Price') . '</th><th>' . _('Total Value') . '<br />' . _('Received') . '</th>'; } echo '<td> </td> @@ -156,7 +156,7 @@ if ($LnItm->Controlled == 1) { - echo '<input type=hidden name="RecvQty_' . $LnItm->LineNo . '" value="' . $LnItm->ReceiveQty . '"><a href="GoodsReceivedControlled.php?' . SID . '&LineNo=' . $LnItm->LineNo . '">' . number_format($LnItm->ReceiveQty,$LnItm->DecimalPlaces) . '</a></td>'; + echo '<input type=hidden name="RecvQty_' . $LnItm->LineNo . '" value="' . $LnItm->ReceiveQty . '"><a href="GoodsReceivedControlled.php?identifier=' . $identifier . '&LineNo=' . $LnItm->LineNo . '">' . number_format($LnItm->ReceiveQty,$LnItm->DecimalPlaces) . '</a></td>'; } else { echo '<input type=text class=number name="RecvQty_' . $LnItm->LineNo . '" maxlength=10 size=10 value="' . $LnItm->ReceiveQty . '"></td>'; @@ -170,10 +170,10 @@ if ($LnItm->Controlled == 1) { if ($LnItm->Serialised==1){ - echo '<td><a href="GoodsReceivedControlled.php?' . SID . '&LineNo=' . $LnItm->LineNo . '">'. + echo '<td><a href="GoodsReceivedControlled.php?identifier=' . $identifier . '&LineNo=' . $LnItm->LineNo . '">'. _('Enter Serial Nos'). '</a></td>'; } else { - echo '<td><a href="GoodsReceivedControlled.php?' . SID . '&LineNo=' . $LnItm->LineNo . '">'. + echo '<td><a href="GoodsReceivedControlled.php?identifier=' . $identifier . '&LineNo=' . $LnItm->LineNo . '">'. _('Enter Batches'). '</a></td>'; } } @@ -237,7 +237,7 @@ }elseif ($DeliveryQuantityTooLarge==1 AND isset($_POST['ProcessGoodsReceived'])){ prnMsg(_('Entered quantities cannot be greater than the quantity entered on the purchase invoice including the allowed over-receive percentage'). ' ' . '(' . $_SESSION['OverReceiveProportion'] .'%)','error'); - echo '<br>'; + echo '<br />'; prnMsg(_('Modify the ordered items on the purchase invoice if you wish to increase the quantities'),'info'); echo '<div class="centre"><input type=submit name=Update Value=' . _('Update') . '>'; @@ -314,9 +314,9 @@ <td>' . $myrow['quantityrecd'] . '</td></tr>'; echo '</table>'; } - echo "<div class='centre'><a href='$rootpath/PO_SelectOSPurchOrder.php?" . SID . "'>". + echo '<div class="centre"><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php">'. _('Select a different purchase order for receiving goods against').'</a></div>'; - echo "<div class='centre'><a href='$rootpath/GoodsReceived.php?" . SID . '&PONumber=' . + echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php?PONumber=' . $_SESSION['PO'.$identifier]->OrderNumber . '">'. _('Re-read the updated purchase order for receiving goods against'). '</a></div>'; unset($_SESSION['PO'.$identifier]->LineItems); unset($_SESSION['PO'.$identifier]); @@ -681,8 +681,8 @@ unset($_SESSION['PO'.$identifier]); unset($_POST['ProcessGoodsReceived']); - echo '<br><div class=centre>'. _('GRN number'). ' '. $GRN .' '. _('has been processed').'<br>'; - echo '<br><a href=PDFGrn.php?GRNNo='.$GRN .'&PONo='.$PONo.'>'. _('Print this Goods Received Note (GRN)').'</a><br><br>'; + echo '<br /><div class=centre>'. _('GRN number'). ' '. $GRN .' '. _('has been processed').'<br />'; + echo '<br /><a href=PDFGrn.php?GRNNo='.$GRN .'&PONo='.$PONo.'>'. _('Print this Goods Received Note (GRN)').'</a><br /><br />'; echo '<a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">' . _('Select a different purchase order for receiving goods against'). '</a></div>'; /*end of process goods received entry */ @@ -691,9 +691,9 @@ } else { /*Process Goods received not set so show a link to allow mod of line items on order and allow input of date goods received*/ - echo '<br><div class="centre"><a href="' . $rootpath . '/PO_Items.php?=' . SID . '">' . _('Modify Order Items'). '</a></div>'; + echo '<br /><div class="centre"><a href="' . $rootpath . '/PO_Items.php">' . _('Modify Order Items'). '</a></div>'; - echo '<br><div class="centre"><input type=submit name=Update Value=' . _('Update') . '><p>'; + echo '<br /><div class="centre"><input type=submit name=Update Value=' . _('Update') . '><p>'; echo '<input type=submit name="ProcessGoodsReceived" Value="' . _('Process Goods Received') . '"></div>'; } Modified: trunk/GoodsReceivedControlled.php =================================================================== --- trunk/GoodsReceivedControlled.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/GoodsReceivedControlled.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -12,21 +12,32 @@ /* Session started in header.inc for password checking and authorisation level check */ include('includes/header.inc'); -if (!isset($_SESSION['PO'])) { +if (empty($_GET['identifier'])) { + if (empty($_POST['identifier'])){ + $identifier=date('U'); + } else { + $identifier=$_POST['identifier']; + } +} else { + $identifier=$_GET['identifier']; +} + + +if (!isset($_SESSION['PO'.$identifier])) { /* This page can only be called with a purchase order number for receiving*/ - echo '<div class="centre"><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">'. + echo '<div class="centre"><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php">'. _('Select a purchase order to receive'). '</a></div><br>'; prnMsg( _('This page can only be opened if a purchase order and line item has been selected') . '. ' . _('Please do that first'),'error'); include('includes/footer.inc'); exit; } -if ($_GET['LineNo']>0){ +if (isset($_GET['LineNo'])){ $LineNo = $_GET['LineNo']; -} else if ($_POST['LineNo']>0){ +} elseif (isset($_POST['LineNo'])){ $LineNo = $_POST['LineNo']; } else { - echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php?' . SID . '">'. + echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php">'. _('Select a line Item to Receive').'</a></div>'; prnMsg( _('This page can only be opened if a Line Item on a PO has been selected') . '. ' . _('Please do that first'), 'error'); include( 'includes/footer.inc'); @@ -34,11 +45,11 @@ } global $LineItem; -$LineItem = &$_SESSION['PO']->LineItems[$LineNo]; +$LineItem = &$_SESSION['PO'.$identifier]->LineItems[$LineNo]; if ($LineItem->Controlled !=1 ){ /*This page only relavent for controlled items */ - echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php?' . SID . '">'. + echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php">'. _('Back to the Purchase Order'). '</a></div>'; prnMsg( _('The line being received must be controlled as defined in the item definition'), 'error'); include('includes/footer.inc'); @@ -50,13 +61,13 @@ ********************************************/ echo '<div class="centre">'; -echo '<br><a href="'.$rootpath.'/GoodsReceived.php?' . SID . '">'. _('Back To Purchase Order'). ' # '. $_SESSION['PO']->OrderNo . '</a>'; +echo '<br><a href="'.$rootpath.'/GoodsReceived.php?identifier=' .$identifier . '">'. _('Back To Purchase Order'). ' # '. $_SESSION['PO'.$identifier]->OrderNo . '</a>'; echo '<br><font size=2><b>'. _('Receive controlled item'). ' '. $LineItem->StockID . ' - ' . $LineItem->ItemDescription . - ' ' . _('on order') . ' ' . $_SESSION['PO']->OrderNo . ' ' . _('from') . ' ' . $_SESSION['PO']->SupplierName . '</b></font></div>'; + ' ' . _('on order') . ' ' . $_SESSION['PO'.$identifier]->OrderNo . ' ' . _('from') . ' ' . $_SESSION['PO'.$identifier]->SupplierName . '</b></font></div>'; /** vars needed by InputSerialItem : **/ -$LocationOut = $_SESSION['PO']->Location; +$LocationOut = $_SESSION['PO'.$identifier]->Location; $ItemMustExist = false; $StockID = $LineItem->StockID; $InOutModifier=1; @@ -67,7 +78,7 @@ /*TotalQuantity set inside this include file from the sum of the bundles of the item selected for dispatch */ -$_SESSION['PO']->LineItems[$LineItem->LineNo]->ReceiveQty = $TotalQuantity; +$_SESSION['PO'.$identifier]->LineItems[$LineItem->LineNo]->ReceiveQty = $TotalQuantity; include( 'includes/footer.inc'); ?> \ No newline at end of file Modified: trunk/PricesByCost.php =================================================================== --- trunk/PricesByCost.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/PricesByCost.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -95,7 +95,7 @@ $SalesTypeRow = DB_fetch_array($ResultType); if (isset($CategoryRow['categorgdescription'])) { - $CategoryText = _('the') . ' ' . $CategoryRow['categorgdescription'] . ' ' . _('category'); + $CategoryText = $CategoryRow['categorgdescription'] . ' ' . _('category'); } else { $CategoryText = _('all Categories'); } /*end of else Category */ Modified: trunk/SelectOrderItems.php =================================================================== --- trunk/SelectOrderItems.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/SelectOrderItems.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -238,7 +238,6 @@ $myrow['narrative'], 'No', /* Update DB */ $myrow['orderlineno'], - // ConvertSQLDate($myrow['itemdue']), 0, '', ConvertSQLDate($myrow['itemdue']), @@ -288,8 +287,7 @@ } } -$msg=''; - +//Customer logins are not allowed to select other customers henc in_array(2,$_SESSION['AllowedPageSecurityTokens']) if (isset($_POST['SearchCust']) AND $_SESSION['RequireCustomerSelection']==1 AND in_array(2,$_SESSION['AllowedPageSecurityTokens'])){ if (($_POST['CustKeywords']!='') AND (($_POST['CustCode']!='') OR ($_POST['CustPhone']!=''))) { @@ -371,22 +369,34 @@ if (DB_num_rows($result_CustSelect)==1){ $myrow=DB_fetch_array($result_CustSelect); - $_POST['Select'] = $myrow['debtorno'] . ' - ' . $myrow['branchcode']; + $SelectedCustomer= $myrow['debtorno'] . ' - ' . $myrow['branchcode']; } elseif (DB_num_rows($result_CustSelect)==0){ prnMsg(_('No Customer Branch records contain the search criteria') . ' - ' . _('please try again') . ' - ' . _('Note a Customer Branch Name may be different to the Customer Name'),'info'); } } /*one of keywords or custcode was more than a zero length string */ } /*end of if search for customer codes/names */ +if (isset($_POST['JustSelectedACustomer'])){ + /*Need to figure out the number of the form variable that the user clicked on */ + for ($i=1;$i<count($_POST);$i++){ //loop through the returned customers + if(isset($_POST['SubmitCustomerSelection'.$i])){ + break; + } + } + if ($i==count($_POST)){ + prnMsg(_('Unable to identify the selected customer'),'error'); + } else { + $SelectedCustomer = $_POST['SelectedCustomer'.$i]; + } +} +/* will only be true if page called from customer selection form or set because only one customer + record returned from a search so parse the $SelectCustomer string into customer code and branch code */ +if (isset($SelectedCustomer)) { + + $CustomerBranchArray = explode('-',$SelectedCustomer); + $_SESSION['Items'.$identifier]->DebtorNo = trim($CustomerBranchArray[0]); + $_SESSION['Items'.$identifier]->Branch = trim($CustomerBranchArray[1]); -// will only be true if page called from customer selection form or set because only one customer -// record returned from a search so parse the $Select string into customer code and branch code */ -if (isset($_POST['Select']) AND $_POST['Select']!='') { - - $_SESSION['Items'.$identifier]->Branch = substr($_POST['Select'],strpos($_POST['Select'],' - ')+3); - - $_POST['Select'] = substr($_POST['Select'],0,strpos($_POST['Select'],' - ')); - // Now check to ensure this account is not on hold */ $sql = "SELECT debtorsmaster.name, holdreasons.dissallowinvoices, @@ -402,30 +412,29 @@ WHERE debtorsmaster.salestype=salestypes.typeabbrev AND debtorsmaster.holdreason=holdreasons.reasoncode AND debtorsmaster.paymentterms=paymentterms.termsindicator - AND debtorsmaster.debtorno = '" . $_POST['Select'] . "'"; + AND debtorsmaster.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo. "'"; - $ErrMsg = _('The details of the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); + $ErrMsg = _('The details of the customer selected') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); $DbgMsg = _('The SQL used to retrieve the customer details and failed was') . ':'; $result =DB_query($sql,$db,$ErrMsg,$DbgMsg); - $myrow = DB_fetch_row($result); + $myrow = DB_fetch_array($result); if ($myrow[1] != 1){ if ($myrow[1]==2){ prnMsg(_('The') . ' ' . $myrow[0] . ' ' . _('account is currently flagged as an account that needs to be watched. Please contact the credit control personnel to discuss'),'warn'); } - $_SESSION['Items'.$identifier]->DebtorNo=$_POST['Select']; $_SESSION['RequireCustomerSelection']=0; - $_SESSION['Items'.$identifier]->CustomerName = $myrow[0]; + $_SESSION['Items'.$identifier]->CustomerName = $myrow['name']; # the sales type determines the price list to be used by default the customer of the user is # defaulted from the entry of the userid and password. - $_SESSION['Items'.$identifier]->DefaultSalesType = $myrow[2]; - $_SESSION['Items'.$identifier]->SalesTypeName = $myrow[3]; - $_SESSION['Items'.$identifier]->DefaultCurrency = $myrow[4]; - $_SESSION['Items'.$identifier]->DefaultPOLine = $myrow[5]; - $_SESSION['Items'.$identifier]->PaymentTerms = $myrow[6]; + $_SESSION['Items'.$identifier]->DefaultSalesType = $myrow['salestype']; + $_SESSION['Items'.$identifier]->SalesTypeName = $myrow['sales_type']; + $_SESSION['Items'.$identifier]->DefaultCurrency = $myrow['currcode']; + $_SESSION['Items'.$identifier]->DefaultPOLine = $myrow['customerpoline']; + $_SESSION['Items'.$identifier]->PaymentTerms = $myrow['terms']; # the branch was also selected from the customer selection so default the delivery details from the customer branches table CustBranch. The order process will ask for branch details later anyway @@ -449,24 +458,24 @@ INNER JOIN locations ON custbranch.defaultlocation=locations.loccode WHERE custbranch.branchcode='" . $_SESSION['Items'.$identifier]->Branch . "' - AND custbranch.debtorno = '" . $_POST['Select'] . "'"; + AND custbranch.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo . "'"; - $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); + $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); $DbgMsg = _('SQL used to retrieve the branch details was') . ':'; $result =DB_query($sql,$db,$ErrMsg,$DbgMsg); if (DB_num_rows($result)==0){ - prnMsg(_('The branch details for branch code') . ': ' . $_SESSION['Items'.$identifier]->Branch . ' ' . _('against customer code') . ': ' . $_POST['Select'] . ' ' . _('could not be retrieved') . '. ' . _('Check the set up of the customer and branch'),'error'); + prnMsg(_('The branch details for branch code') . ': ' . $_SESSION['Items'.$identifier]->Branch . ' ' . _('against customer code') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('could not be retrieved') . '. ' . _('Check the set up of the customer and branch'),'error'); if ($debug==1){ - echo '<br>' . _('The SQL that failed to get the branch details was') . ':<br>' . $sql; + prnMsg( _('The SQL that failed to get the branch details was') . ':<br />' . $sql . 'warning'); } include('includes/footer.inc'); exit; } // add echo - echo '<br>'; + echo '<br />'; $myrow = DB_fetch_row($result); if ($_SESSION['SalesmanLogin']!='' AND $_SESSION['SalesmanLogin']!=$myrow[15]){ prnMsg(_('Your login is only set up for a particular salesperson. This customer has a different salesperson.'),'error'); @@ -494,7 +503,7 @@ prnMsg($_SESSION['Items'.$identifier]->SpecialInstructions,'warn'); if ($_SESSION['CheckCreditLimits'] > 0){ /*Check credit limits is 1 for warn and 2 for prohibit sales */ - $_SESSION['Items'.$identifier]->CreditAvailable = GetCreditAvailable($_POST['Select'],$db); + $_SESSION['Items'.$identifier]->CreditAvailable = GetCreditAvailable($_SESSION['Items'.$identifier]->DebtorNo,$db); if ($_SESSION['CheckCreditLimits']==1 AND $_SESSION['Items'.$identifier]->CreditAvailable <=0){ prnMsg(_('The') . ' ' . $myrow[0] . ' ' . _('account is currently at or over their credit limit'),'warn'); @@ -524,12 +533,8 @@ WHERE debtorsmaster.holdreason=holdreasons.reasoncode AND debtorsmaster.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo . "'"; - if (isset($_POST['Select'])) { - $ErrMsg = _('The details for the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); - } else { - $ErrMsg = ''; - } - $DbgMsg = _('SQL used to retrieve the customer details was') . ':<br>' . $sql; + $ErrMsg = _('The details for the customer selected') . ': ' .$_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); + $DbgMsg = _('SQL used to retrieve the customer details was') . ':<br />' . $sql; $result =DB_query($sql,$db,$ErrMsg,$DbgMsg); $myrow = DB_fetch_row($result); @@ -568,11 +573,7 @@ WHERE custbranch.branchcode='" . $_SESSION['Items'.$identifier]->Branch . "' AND custbranch.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo . "'"; - if (isset($_POST['Select'])) { - $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); - } else { - $ErrMsg = ''; - } + $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); $DbgMsg = _('SQL used to retrieve the branch details was'); $result =DB_query($sql,$db,$ErrMsg, $DbgMsg); @@ -610,7 +611,6 @@ <?php echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; ?> - <b><?php echo '<p>' . $msg; ?></p> <table cellpadding=3 colspan=4 class=selection> <tr> <td><h5><?php echo _('Part of the Customer Branch Name'); ?>:</h5></td> @@ -623,7 +623,7 @@ <td><input tabindex=3 type="Text" name="CustPhone" size=15 maxlength=18></td> </tr> </table> - <br><div class="centre"><input tabindex=4 type=submit name="SearchCust" value="<?php echo _('Search Now'); ?>"> + <br /><div class="centre"><input tabindex=4 type=submit name="SearchCust" value="<?php echo _('Search Now'); ?>"> <input tabindex=5 type=submit action=reset value="<?php echo _('Reset'); ?>"></div> <?php @@ -631,7 +631,7 @@ echo '<table cellpadding=2 colspan=7>'; - $TableHeader = '<br><tr> + $TableHeader = '<br /><tr> <th>' . _('Customer') . '</th> <th>' . _('Branch') . '</th> <th>' . _('Contact') . '</th> @@ -659,20 +659,20 @@ } else { echo '<td></td>'; } - echo '<td><input tabindex='.number_format($j+5).' type=submit name="Submit" value="'.$myrow['brname'].'"</td> - <input type=hidden name="Select" value="'.$myrow['debtorno'].' - '.$myrow['branchcode'].'"> + echo '<td><input tabindex='.($j+5).' type=submit name="SubmitCustomerSelection' . $j .'" value="' . htmlentities($myrow['brname']) . '"></td> + <input type="hidden" name="SelectedCustomer' . $j .'" value="'.$myrow['debtorno'] .' - '.$myrow['branchcode'].'"> <td>'.$myrow['contactname'].'</td> <td>'.$myrow['phoneno'].'</td> <td>'.$myrow['faxno'].'</td> - </tr></form>'; + </tr>'; $LastCustomer=$myrow['name']; $j++; //end of page full new headings if } //end of while loop + echo '<input type="hidden" name="JustSelectedACustomer" value="Yes">'; + echo '</table></form>'; - echo '</table>'; - }//end if results to show //end if RequireCustomerSelection @@ -723,7 +723,7 @@ } else { $_SESSION['RequireCustomerSelection'] = 0; } - echo '<br><br>'; + echo '<br /><br />'; prnMsg(_('This sales order has been cancelled as requested'),'success'); include('includes/footer.inc'); exit; @@ -739,13 +739,13 @@ } echo ':<b> ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('Customer Name') . ': ' . $_SESSION['Items'.$identifier]->CustomerName; - echo '</b></p><div class="page_help_text">' . '<b>' . _('Default Options (can be modified during order):') . '</b><br>' . _('Deliver To') . ':<b> ' . $_SESSION['Items'.$identifier]->DeliverTo; + echo '</b></p><div class="page_help_text">' . '<b>' . _('Default Options (can be modified during order):') . '</b><br />' . _('Deliver To') . ':<b> ' . $_SESSION['Items'.$identifier]->DeliverTo; echo '</b> ' . _('From Location') . ':<b> ' . $_SESSION['Items'.$identifier]->LocationName; - echo '</b><br>' . _('Sales Type') . '/' . _('Price List') . ':<b> ' . $_SESSION['Items'.$identifier]->SalesTypeName; - echo '</b><br>' . _('Terms') . ':<b> ' . $_SESSION['Items'.$identifier]->PaymentTerms; + echo '</b><br />' . _('Sales Type') . '/' . _('Price List') . ':<b> ' . $_SESSION['Items'.$identifier]->SalesTypeName; + echo '</b><br />' . _('Terms') . ':<b> ' . $_SESSION['Items'.$identifier]->PaymentTerms; echo '</b></div>'; } - + $msg =''; if (isset($_POST['Search']) or isset($_POST['Next']) or isset($_POST['Prev'])){ if ($_POST['Keywords']!=='' AND $_POST['StockCode']=='') { @@ -769,7 +769,7 @@ WHERE stockmaster.categoryid=stockcategory.categoryid AND (stockcategory.stocktype='F' OR stockcategory.stocktype='D') AND stockmaster.mbflag <>'G' - AND stockmaster.description " . LIKE . " '$SearchString' + AND stockmaster.description " . LIKE . " '" . $SearchString . "' AND stockmaster.discontinued=0 ORDER BY stockmaster.stockid"; } else { @@ -1280,13 +1280,13 @@ /* This is where the order as selected should be displayed reflecting any deletions or insertions*/ - echo '<br> + echo '<br /> <table width="90%" cellpadding="2" colspan="7"> <tr bgcolor=#800000>'; if($_SESSION['Items'.$identifier]->DefaultPOLine == 1){ echo '<th>' . _('PO Line') . '</th>'; } - echo '<div class="page_help_text">' . _('Quantity (required) - Enter the number of units ordered. Price (required) - Enter the unit price. Discount (optional) - Enter a percentage discount. GP% (optional) - Enter a percentage Gross Profit (GP) to add to the unit cost. Due Date (optional) - Enter a date for delivery.') . '</div><br>'; + echo '<div class="page_help_text">' . _('Quantity (required) - Enter the number of units ordered. Price (required) - Enter the unit price. Discount (optional) - Enter a percentage discount. GP% (optional) - Enter a percentage Gross Profit (GP) to add to the unit cost. Due Date (optional) - Enter a date for delivery.') . '</div><br />'; echo '<th>' . _('Item Code') . '</th> <th>' . _('Item Description') . '</th> <th>' . _('Quantity') . '</th> @@ -1336,7 +1336,7 @@ echo '<td><input class="number" tabindex=2 type=tect name="Quantity_' . $OrderLine->LineNumber . '" size=6 maxlength=6 value=' . $OrderLine->Quantity . '>'; if ($QtyRemain != $QtyOrdered){ - echo '<br>'.$OrderLine->QtyInv.' of '.$OrderLine->Quantity.' invoiced'; + echo '<br />'.$OrderLine->QtyInv.' of '.$OrderLine->Quantity.' invoiced'; } echo '</td> <td class="number">' . $OrderLine->QOHatLoc . '</td> @@ -1369,7 +1369,7 @@ if ($_SESSION['AllowOrderLineItemNarrative'] == 1){ echo $RowStarter; - echo '<td colspan=10>' . _('Narrative') . ':<textarea name="Narrative_' . $OrderLine->LineNumber . '" cols="100%" rows="1">' . stripslashes(AddCarriageReturns($OrderLine->Narrative)) . '</textarea><br></td></tr>'; + echo '<td colspan=10>' . _('Narrative') . ':<textarea name="Narrative_' . $OrderLine->LineNumber . '" cols="100%" rows="1">' . stripslashes(AddCarriageReturns($OrderLine->Narrative)) . '</textarea><br /></td></tr>'; } else { echo '<input type=hidden name="Narrative" value="">'; } @@ -1398,7 +1398,7 @@ </tr></table>'; - echo '<br><div class="centre"><input type=submit name="Recalculate" Value="' . _('Re-Calculate') . '"> + echo '<br /><div class="centre"><input type=submit name="Recalculate" Value="' . _('Re-Calculate') . '"> <input type=submit name="DeliveryDetails" value="' . _('Enter Delivery Details and Confirm Order') . '"></div><hr>'; } # end of if lines @@ -1428,8 +1428,8 @@ $result2 = DB_query($SQL,$db); echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/magnifier.png" title="' . _('Search') . '" alt="" />' . ' '; - echo _('Frequently Ordered Items') . '</p><br>'; - echo '<div class="page_help_text">' . _('Frequently Ordered Items') . _(', shows the most frequently ordered items in the last 6 months. You can choose from this list, or search further for other items') . '.</div><br>'; + echo _('Frequently Ordered Items') . '</p><br />'; + echo '<div class="page_help_text">' . _('Frequently Ordered Items') . _(', shows the most frequently ordered items in the last 6 months. You can choose from this list, or search further for other items') . '.</div><br />'; echo '<table class="table1">'; $TableHeader = '<tr><th>' . _('Code') . '</th> <th>' . _('Description') . '</th> @@ -1553,7 +1553,7 @@ echo '<p><div class="centre"><b><p>' . $msg . '</b></p>'; echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/magnifier.png" title="' . _('Search') . '" alt="" />' . ' '; echo _('Search for Order Items') . '</p>'; - echo '<div class="page_help_text">' . _('Search for Order Items') . _(', Searches the database for items, you can narrow the results by selecting a stock category, or just enter a partial item description or partial item code') . '.</div><br>'; + echo '<div class="page_help_text">' . _('Search for Order Items') . _(', Searches the database for items, you can narrow the results by selecting a stock category, or just enter a partial item description or partial item code') . '.</div><br />'; echo '<table class="selection"><tr><td><b>' . _('Select a Stock Category') . ': </b><select tabindex=1 name="StockCat">'; if (!isset($_POST['StockCat'])){ @@ -1601,13 +1601,13 @@ if (in_array(2,$_SESSION['AllowedPageSecurityTokens'])){ //not a customer entry of own order echo '<td style="text-align:center" colspan=1><input tabindex=6 type="submit" name="ChangeCustomer" value="' . _('Change Customer') . '"></td> <td style="text-align:center" colspan=1><input tabindex=7 type="submit" name="SelectAsset" value="' . _('Fixed Asset Disposal') . '"></td> - </tr></table><br>'; + </tr></table><br />'; } if (isset($SearchResult)) { - echo '<br>'; + echo '<br />'; echo '<div class="page_help_text">' . _('Select an item by entering the quantity required. Click Order when ready.') . '</div>'; - echo '<br>'; + echo '<br />'; $j = 1; echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID .'identifier='.$identifier . ' method=post name="orderform">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; @@ -1631,7 +1631,7 @@ while ($myrow=DB_fetch_array($SearchResult)) { // Find the quantity in stock at location - $QOHSQL = "SELECT sum(quantity) AS qoh, + $QOHSQL = "SELECT quantity AS qoh, stockmaster.decimalplaces FROM locstock INNER JOIN stockmaster ON locstock.stockid = stockmaster.stockid @@ -1662,11 +1662,12 @@ } // Find the quantity on purchase orders - $sql = "SELECT SUM(purchorderdetails.quantityord-purchorderdetails.quantityrecd) AS dem + $sql = "SELECT SUM(purchorderdetails.quantityord-purchorderdetails.quantityrecd) AS qoo FROM purchorderdetails INNER JOIN purchorders WHERE purchorderdetails.completed=0 AND purchorders.status<>'Cancelled' AND purchorders.status<>'Rejected' + AND purchorders.status<>'Pending' AND purchorderdetails.itemcode='" . $myrow['stockid'] . "'"; $ErrMsg = _('The order details for this product cannot be retrieved because'); @@ -1741,7 +1742,7 @@ } /*end of PartSearch options to be displayed */ elseif( isset($_POST['QuickEntry'])) { /* show the quick entry form variable */ /*FORM VARIABLES TO POST TO THE ORDER WITH PART CODE AND QUANTITY */ - echo '<div class="page_help_text"><b>' . _('Use this screen for the '). _('Quick Entry')._(' of products to be ordered') . '</b></div><br> + echo '<div class="page_help_text"><b>' . _('Use this screen for the '). _('Quick Entry')._(' of products to be ordered') . '</b></div><br /> <table border=1> <tr>'; /*do not display colum unless customer requires po line number by sales order line*/ @@ -1767,12 +1768,12 @@ } echo '<script type="text/javascript">if (document.SelectParts) {defaultControl(document.SelectParts.part_1);}</script>'; - echo '</table><br><div class="centre"><input type="submit" name="QuickEntry" value="' . _('Quick Entry') . '"> + echo '</table><br /><div class="centre"><input type="submit" name="QuickEntry" value="' . _('Quick Entry') . '"> <input type="submit" name="PartSearch" value="' . _('Search Parts') . '"></div>'; } elseif (isset($_POST['SelectAsset'])){ - echo '<div class="page_help_text"><b>' . _('Use this screen to select an asset to dispose of to this customer') . '</b></div><br> + echo '<div class="page_help_text"><b>' . _('Use this screen to select an asset to dispose of to this customer') . '</b></div><br /> <table border=1>'; /*do not display colum unless customer requires po line number by sales order line*/ if($_SESSION['Items'.$identifier]->DefaultPOLine ==1){ @@ -1787,13 +1788,13 @@ echo '<option value="' . $AssetRow['assetid'] . '">' . $AssetRow['assetid'] . ' - ' . $AssetRow['description'] . '</option>'; } echo '</select></td></tr></table> - <br><div class="centre"><input type="submit" name="AssetDisposalEntered" value="' . _('Add Asset To Order') . '"> + <br /><div class="centre"><input type="submit" name="AssetDisposalEntered" value="' . _('Add Asset To Order') . '"> <input type="submit" name="PartSearch" value="' . _('Search Parts') . '"></div>'; } //end of if it is a Quick Entry screen/part search or asset selection form to display if ($_SESSION['Items'.$identifier]->ItemsOrdered >=1){ - echo '<br><div class="centre"><input type=submit name="CancelOrder" value="' . _('Cancel Whole Order') . '" onclick="return confirm(\'' . _('Are you sure you wish to cancel this entire order?') . '\');"></div>'; + echo '<br /><div class="centre"><input type=submit name="CancelOrder" value="' . _('Cancel Whole Order') . '" onclick="return confirm(\'' . _('Are you sure you wish to cancel this entire order?') . '\');"></div>'; } }#end of else not selecting a customer @@ -1803,4 +1804,4 @@ echo '<script type="text/javascript">if (document.SelectParts) {defaultControl(document.SelectCustomer.CustKeywords);}</script>'; } include('includes/footer.inc'); -?> +?> \ No newline at end of file Modified: trunk/StockSerialItems.php =================================================================== --- trunk/StockSerialItems.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/StockSerialItems.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -11,6 +11,11 @@ '" alt="" /><b>' . $title. '</b></p>'; if (isset($_GET['StockID'])){ + if (ContainsIllegalCharacters ($_GET['StockID'])){ + prnMsg(_('The stock code sent to this page appears to be invalid'),'error'); + include('includes/footer.inc'); + exit; + } $StockID = trim(strtoupper($_GET['StockID'])); } else { prnMsg( _('This page must be called with parameters specifying the item to show the serial references and quantities') . '. ' . _('It cannot be displayed without the proper parameters being passed'),'error'); Modified: trunk/SuppInvGRNs.php =================================================================== --- trunk/SuppInvGRNs.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/SuppInvGRNs.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -241,7 +241,7 @@ <td>' . $GRNTmp->ItemCode . ' ' . $GRNTmp->ItemDescription . '</td> <td class=number>' . number_format($GRNTmp->QtyRecd - $GRNTmp->Prev_QuantityInv,2) . '</td> <td><input type="text" class="number" Name="This_QuantityInv" Value="' . $GRNTmp->This_QuantityInv . '" size=11 maxlength=10></td> - <td class=number>"' . $GRNTmp->OrderPrice . '"</td> + <td class=number>' . $GRNTmp->OrderPrice . '</td> <td><input type="text" class="number" Name="ChgPrice" Value=' . $GRNTmp->ChgPrice . ' size="11" maxlength="10"></td> </tr>'; echo '</table>'; Modified: trunk/SystemParameters.php =================================================================== --- trunk/SystemParameters.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/SystemParameters.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -623,14 +623,14 @@ <td><select Name="X_PO_AllowSameItemMultipleTimes"> <option '.($_SESSION['PO_AllowSameItemMultipleTimes']?'selected ':'').'value="1">'._('Yes') . '</option> <option '.(!$_SESSION['PO_AllowSameItemMultipleTimes']?'selected ':'').'value="0">'._('No') . '</option> - </select></td> <td></td></tr>'; + </select></td><td>' . _('If a purchase order can have the same item on the order several times this parameter should be set to yes') . '</td></tr>'; // 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').' - </select></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></td></tr>'; + </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>'; echo '<tr><th colspan=3>' . _('General Settings') . '</th></tr>'; Modified: trunk/UpgradeDatabase.php =================================================================== --- trunk/UpgradeDatabase.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/UpgradeDatabase.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -29,7 +29,7 @@ echo '<option value="3.08">' . _('Version 3.08') . '</option>'; echo '<option value="3.09">' . _('Version 3.09') . '</option>'; echo '<option value="3.10">' . _('Version 3.10') . '</option>'; - echo '<option value="3.11">' . _('Version 3.11') . '</option>'; + echo '<option value="3.11">' . _('Version 3.11 or 4.01 - 4.02') . '</option>'; echo '</select></td></tr></table>'; } else { if ($_SESSION['VersionNumber']=='4.00-RC1'){ @@ -48,7 +48,7 @@ if ($dbType=='mysql' OR $dbType =='mysqli'){ /* First do a backup */ - $BackupFile = '.' . $PathPrefix . '/companies/' . $_SESSION['DatabaseName'] .'/' . _('Backup') . '_' . Date('Y-m-d-H-i-s') . '.gz'; + $BackupFile = $PathPrefix . './companies/' . $_SESSION['DatabaseName'] .'/' . _('Backup') . '_' . Date('Y-m-d-H-i-s') . '.sql.gz'; $Command = 'mysqldump --opt -h' . $host . ' -u' . $dbuser . ' -p' . $dbpassword . ' ' . $_SESSION['DatabaseName'] . '| gzip > ' . $BackupFile; system($Command); Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/doc/Change.log.html 2011-02-13 04:15:38 UTC (rev 4490) @@ -1,5 +1,9 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p -<p></p> +<p /> +<p>13/2/11 Release 4.03RC1</p> +<p /> +<p>13/2/11:Phil GoodsReceivedControlled InputSerialItems and friends - now uses session identifier to ensure uniqueness is several people entering stock receipts</p> +<p>13/2/11:Phil Contracts.php SelectOrderItems.php customer selection mechanism reworked - was causing issues in Contracts as noted by DK Shukla</p> <p>8/2/11: Tim Rework CounterSales.php so that it is now possible to sell items that have sales/purchasing tax</p> <p>8/2/11: Phil Fix InventoryPlanning and InventoryPlanningPrefSupplier to only show sales order demand - excluding quotations. Also fixed for conversionfactor as now all purchase order quantities are in our normal stock units</p> <p>8/2/11: Phil Fix incorrect layout of narrative on multiple lines of PDFQuotation.php as reported by Ricard Andreu</p> Modified: trunk/doc/INSTALL.txt =================================================================== --- trunk/doc/INSTALL.txt 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/doc/INSTALL.txt 2011-02-13 04:15:38 UTC (rev 4490) @@ -4,8 +4,12 @@ Upgrading -A php upgrade script is provided for versions from 3.05 that applies the database changes required to move from the previous version to the newer version - this script also updates any data as required to work with the new version scripts. Simply point your browser to Z_Upgrade3.06-3.07.php (for an upgrade between 3.06 and 3.07 - similar naming convention applies to subsequent releases) and follow the prompts. If you are upgrading through several versions eg. from 3.05 to 3.08 then you must run each successive Z_UpgradeX.XX-X.XY.php script in sequence. +As from version 4.01 an automated database upgrade mechanism has been built in. Just copy the extract the scripts and copy: +1. config.php file from your old installation and +2. webERP/companies directory into the new webERP directory structure +Open up the webERP/index.php and the system will identify any database changes required. If the system is unable to indentify the database changes required - if the old system was a version prior to 4.01 then it will prompt you to select the old version you were using. The necessary database changes will then be applied automatically. + If the database must be updated manually (as it must for versions prior to 3.05): The SQL scripts are included under webERP/sql/mysql/ to update an existing mysql webERP database to the current version. The upgrade script no longer assumes the weberp database is called webERP. If using the mysql command line client then each upgrade SQL script must be edited to enter the name of the database to upgrade by adding a line @@ -41,7 +45,6 @@ The install script checks for the appropriate permissions and will not even attempt to install unless the web-server has the necessary write access to the files. - Manual Installation Read on below if you cannot use the installer to set up your installation for some reason or you simply wish to understand what is going on when the installer runs. @@ -50,7 +53,7 @@ Pre-requisites: -- A working PHP web server - v 5.0 or later is required (it no longer works with versions prior) PHP must have support for mysql databases (either mysql or mysqli), gd, gettext and ftp +- A working PHP web server - v 5.0 or later is required (it no longer works with versions prior) PHP must have support for mysql databases (either mysql or mysqli), gd, gettext, libxml and ftp - A working MySQL server (MySql version 4.1 or above - innodb tables MUST be enabled - check your my.cnf file to ensure innodb tables are enabled (normally under /etc/my.cnf or the mysql data directory - see the MySQL manual). Installing these components are well covered elsewhere - but if you need to install these components the recommended solution under windows would be to download and install apache2triad - http://apache2triad.net/ or under windows or *nix download and install XAMPP - http://www.apachefriends.org/en/xampp.html Modified: trunk/includes/ConnectDB.inc =================================================================== --- trunk/includes/ConnectDB.inc 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/ConnectDB.inc 2011-02-13 04:15:38 UTC (rev 4490) @@ -4,7 +4,7 @@ * this value is saved in the $_SESSION['Versionumber'] when includes/GetConfig.php is run * if VersionNumber is < $Version then the DB update script is run */ -$Version='3.12.32'; //must update manually every time there is a DB change +$Version='4.03'; //must update manually every time there is a DB change require_once ($PathPrefix .'includes/MiscFunctions.php'); Modified: trunk/includes/InputSerialItems.php =================================================================== --- trunk/includes/InputSerialItems.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/InputSerialItems.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -48,7 +48,7 @@ $invalid_imports = 0; $valid = true; -echo '<form method="post" action="' . $_SERVER['PHP_SELF'] . '?' . SID . '" enctype="multipart/form-data" >'; +echo '<form method="post" action="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier .'" enctype="multipart/form-data" >'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; echo '<input type=hidden name="LineNo" value="' . $LineNo . '">'; echo '<input type=hidden name="StockID" value="'. $StockID. '">'; @@ -71,7 +71,7 @@ } echo '<td valign=bottom>'; -echo '<input type=radio id="FileEntry" name=EntryType onClick="submit();" '; +echo '<input type="radio" id="FileEntry" name="EntryType" onClick="submit();" '; if ($_POST['EntryType']=='FILE') { echo ' checked '; } @@ -84,9 +84,9 @@ global $tableheader; /* Link to clear the list and start from scratch */ -$EditLink = '<br><div class="centre"><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&EditControlled=true&StockID=' . $LineItem->StockID . +$EditLink = '<br><div class="centre"><a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&EditControlled=true&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Edit'). '</a> | '; -$RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&DELETEALL=YES&StockID=' . $LineItem->StockID . +$RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&DELETEALL=YES&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Remove All'). '</a><br></div>'; if ($LineItem->Serialised==1){ $tableheader .= '<tr> Modified: trunk/includes/InputSerialItemsExisting.php =================================================================== --- trunk/includes/InputSerialItemsExisting.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/InputSerialItemsExisting.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -29,10 +29,11 @@ echo '<form action="' . $_SERVER['PHP_SELF'] . '?=' . SID . '" method="POST">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - echo '<input type=hidden name=LineNo value="' . $LineNo . '"> - <input type=hidden name=StockID value="' . $StockID . '"> - <input type=hidden name=EntryType value="KEYED"> - <input type=hidden name=EditControlled value="true"> + echo '<input type=hidden name="LineNo" value="' . $LineNo . '"> + <input type="hidden" name="StockID" value="' . $StockID . '"> + <input type="hidden" name="EntryType" value="KEYED"> + <input type=hidden name="identifier" value="' . $identifier . '"> + <input type="hidden" name="EditControlled" value="true"> <select Name=Bundles[] multiple>'; $id=0; Modified: trunk/includes/InputSerialItemsFile.php =================================================================== --- trunk/includes/InputSerialItemsFile.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/InputSerialItemsFile.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -34,17 +34,17 @@ //only show 1st 10 lines if ($RowCounter < 10){ if ($k==1){ - echo '<tr bgcolor="#CCCCCC">'; + echo '<tr class="EvenTableRows">'; $k=0; } else { - echo '<tr bgcolor="#EEEEEE">'; + echo '<tr class="OddTableRows">'; $k=1; } - echo '<TD>' . $Bundle->BundleRef . '</TD>'; + echo '<td>' . $Bundle->BundleRef . '</td>'; if ($LineItem->Serialised==0){ - echo '<TD ALIGN=RIGHT>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</TD>'; + echo '<td align=right>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; } } @@ -54,16 +54,16 @@ /*Display the totals and rule off before allowing new entries */ if ($LineItem->Serialised==1){ - echo '<TR><TD ALIGN=RIGHT><B>'. _('Total Quantity'). ': ' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</B></TD></TR>'; - echo '<TR><TD><HR></TD></TR>'; + echo '<tr><td align=right><b>'. _('Total Quantity'). ': ' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; + echo '<tr><td><hr></td></tr>'; } else { - echo '<TR><TD ALIGN=RIGHT><B>'. _('Total Quantity'). ':</B></TD><TD ALIGN=RIGHT><B>' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</B></TD></TR>'; - echo '<TR><TD COLSPAN=2><HR></TD></TR>'; + echo '<tr><td align=right><b>'. _('Total Quantity'). ':</B></TD><TD ALIGN=RIGHT><B>' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; + echo '<tr><td colspan=2><hr></td></tr>'; } -echo '</TABLE><HR>'; -//echo "<TABLE><TR><TD>"; +echo '</table><hr>'; + //DISPLAY FILE INFO // do some inits & error checks... $ShowFileInfo = false; @@ -75,18 +75,18 @@ $msg = _('Please Choose a file and then click Set Entry Type to upload a file for import'); prnMsg($msg); $LineItem->SerialItemsValid=false; - echo '</TD></TR></TABLE>'; + echo '</td></tr></table>'; include('includes/footer.inc'); exit(); } if ($_FILES['ImportFile']['error'] != '' && !isset($_SESSION['CurImportFile'])){ - echo _('There was a problem with the uploaded file') . '. ' . _('We received').':<BR>'. - _('Name').':'.$_FILES['ImportFile']['name'].'<br>'. - _('Size').':'.number_format($_FILES['ImportFile']['size']/1024,2).'kb<br>'. - _('Type').':'.$_FILES['ImportFile']['type'].'<br>'; - echo '<br>'._('Error was').' '.$_FILES['ImportFile']['error'].'<br>'; + echo _('There was a problem with the uploaded file') . '. ' . _('We received').':<br />'. + _('Name').':'.$_FILES['ImportFile']['name'].'<br />'. + _('Size').':'.number_format($_FILES['ImportFile']['size']/1024,2).'kb<br />'. + _('Type').':'.$_FILES['ImportFile']['type'].'<br />'; + echo '<br />'._('Error was').' '.$_FILES['ImportFile']['error'].'<br />'; $LineItem->SerialItemsValid=false; - echo '</TD></TR></TABLE>'; + echo '</td></tr></table>'; include('includes/footer.inc'); exit(); } elseif ($_FILES['ImportFile']['name']!=''){ @@ -100,18 +100,18 @@ if (!move_uploaded_file($_FILES['ImportFile']['tmp_name'],$_SESSION['CurImportFile']['tmp_name'])){ prnMsg(_('Error moving temporary file') . '. ' . _('Please check your configuration'),'error' ); $LineItem->SerialItemsValid=false; - echo '</TD></TR></TABLE>'; + echo '</td></tr></table>'; include('includes/footer.inc'); exit; } if ($_FILES['ImportFile']['name']!=''){ - echo _('Successfully received').':<br>'; + echo _('Successfully received').':<br />'; $ShowFileInfo = true; } } elseif (isset($_SESSION['CurImportFile']) && $_SESSION['CurImportFile']['Processed'] ) { //file exists, some action performed... - echo _('Working with'). ':<br>'; + echo _('Working with'). ':<br />'; $ShowFileInfo = true; } elseif ($LineItem->SerialItemsValid && $_SESSION['CurImportFile']['Processed']){ $ShowInfo = true; @@ -120,20 +120,20 @@ /******************************************** Display file info for visual verification ********************************************/ - echo '<TABLE>'; + echo '<table>'; echo '<tr><td>'._('Name').':</td><td>'.$_SESSION['CurImportFile']['name'].'</td></tr> <tr><td>'. _('Size') .':</td><td>' . number_format($_SESSION['CurImportFile']['size']/1024,4) . 'kb</td></tr> <tr><td>'. _('Type') .':</td><td>' . $_SESSION['CurImportFile']['type'] . '</td></tr> <tr><td>'. _('TempName') .':</td><td>' . $_SESSION['CurImportFile']['tmp_name'] . '</td></tr> <tr><td>'. _('Status') .':</td><td>' . ($LineItem->SerialItemsValid?getMsg(_('Valid'),'success'):getMsg(_('Invalid'),'error')) . '</td></tr> - </TABLE>'. - $invalid_imports.' '. _('out of') .' '.$TotalLines.' '. _('records are invalid').'<br>'; + </table>'. + $invalid_imports.' '. _('out of') .' '.$TotalLines.' '. _('records are invalid').'<br />'; $filename = $_SESSION['CurImportFile']['tmp_name']; } if (!$LineItem->SerialItemsValid && !$_SESSION['CurImportFile']['Processed']){ - // IF all items are not valid, show the raw first 10 lines of the file. maybe it will help. + // If all items are not valid, show the raw first 10 lines of the file. maybe it will help. $filename = $_SESSION['CurImportFile']['tmp_name']; $handle = fopen($filename, 'r'); $i=0; @@ -143,12 +143,13 @@ } fclose($handle); - echo '<br><form method=POST>'; + echo '<br /><form method=POST>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - echo '<input type=submit name=ValidateFile value=' . _('Validate File') . '> - <input type=hidden name=LineNo value="' . $LineNo . '"> - <input type=hidden name=StockID value="' . $StockID . '"> - <input type=hidden name=EntryType value="FILE"> + echo '<input type=submit name="ValidateFile" value=' . _('Validate File') . '> + <input type=hidden name="LineNo" value="' . $LineNo . '"> + <input type=hidden name="identifier" value="' . $identifier . '"> + <input type=hidden name="StockID" value="' . $StockID . '"> + <input type=hidden name="EntryType" value="FILE"> </form> <... [truncated message content] |
From: <dai...@us...> - 2011-02-13 04:15:48
|
Revision: 4490 http://web-erp.svn.sourceforge.net/web-erp/?rev=4490&view=rev Author: daintree Date: 2011-02-13 04:15:38 +0000 (Sun, 13 Feb 2011) Log Message: ----------- pre 4.03RC1 Modified Paths: -------------- trunk/Contracts.php trunk/GoodsReceived.php trunk/GoodsReceivedControlled.php trunk/PricesByCost.php trunk/SelectOrderItems.php trunk/StockSerialItems.php trunk/SuppInvGRNs.php trunk/SystemParameters.php trunk/UpgradeDatabase.php trunk/doc/Change.log.html trunk/doc/INSTALL.txt trunk/includes/ConnectDB.inc trunk/includes/InputSerialItems.php trunk/includes/InputSerialItemsExisting.php trunk/includes/InputSerialItemsFile.php trunk/includes/InputSerialItemsKeyed.php trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.mo trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po trunk/locale/de_DE.utf8/LC_MESSAGES/messages.mo trunk/locale/de_DE.utf8/LC_MESSAGES/messages.po trunk/locale/el_GR.utf8/LC_MESSAGES/messages.mo trunk/locale/el_GR.utf8/LC_MESSAGES/messages.po trunk/locale/en_GB.utf8/LC_MESSAGES/messages.pot trunk/locale/en_US.utf8/LC_MESSAGES/messages.mo trunk/locale/en_US.utf8/LC_MESSAGES/messages.po trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/et_EE.utf8/LC_MESSAGES/messages.mo trunk/locale/et_EE.utf8/LC_MESSAGES/messages.po trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.mo trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.mo trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.po trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.mo trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.po trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.mo trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.po trunk/locale/id_ID.utf8/LC_MESSAGES/messages.mo trunk/locale/id_ID.utf8/LC_MESSAGES/messages.po trunk/locale/it_IT.utf8/LC_MESSAGES/messages.mo trunk/locale/it_IT.utf8/LC_MESSAGES/messages.po trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.mo trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.po trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.mo trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.po trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.mo trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.po trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.mo trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.po trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.po trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.po trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.mo trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.po trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.mo trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.po trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.mo trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.po trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.mo trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.po trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.mo trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.po trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.mo trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.po trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.po trunk/sql/mysql/upgrade3.11.1-4.00.sql trunk/sql/mysql/weberp-demo.sql trunk/sql/mysql/weberp-new.sql Modified: trunk/Contracts.php =================================================================== --- trunk/Contracts.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/Contracts.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -667,23 +667,37 @@ if (DB_num_rows($result_CustSelect)==1){ $myrow=DB_fetch_array($result_CustSelect); - $_POST['SelectedCustomer'] = $myrow['debtorno'] . '-' . $myrow['branchcode']; + $SelectedCustomer = $myrow['debtorno'] . '-' . $myrow['branchcode']; } elseif (DB_num_rows($result_CustSelect)==0){ prnMsg(_('No Customer Branch records contain the search criteria') . ' - ' . _('please try again') . ' - ' . _('Note a Customer Branch Name may be different to the Customer Name'),'info'); } } /*one of keywords or custcode was more than a zero length string */ } /*end of if search for customer codes/names */ +if (isset($_POST['JustSelectedACustomer'])){ + /*Need to figure out the number of the form variable that the user clicked on */ + for ($i=1;$i<count($_POST);$i++){ //loop through the returned customers + if(isset($_POST['SubmitCustomerSelection'.$i])){ + break; + } + } + if ($i==count($_POST)){ + prnMsg(_('Unable to identify the selected customer'),'error'); + } else { + $SelectedCustomer = $_POST['SelectedCustomer'.$i]; + } +} -if (isset($_POST['SelectedCustomer'])) { +if (isset($SelectedCustomer)) { -/* will only be true if page called from customer selection form - * or set because only one customer record returned from a search - * so parse the $Select string into debtorno and branch code */ - $CustomerBranchArray = explode('-',$_POST['SelectedCustomer']); +/* will only be true if page called from customer selection + * or set because only one customer record returned from a search - isset($SelectedCustomer) + * so parse the returned SelectedCustomer string into debtorno and branch code */ + + $CustomerBranchArray = explode('-',$SelectedCustomer); $_SESSION['Contract'.$identifier]->DebtorNo = trim($CustomerBranchArray[0]); $_SESSION['Contract'.$identifier]->BranchCode = trim($CustomerBranchArray[1]); - + $sql = "SELECT debtorsmaster.name, custbranch.brname, debtorsmaster.currcode, @@ -699,8 +713,7 @@ WHERE debtorsmaster.debtorno='" . $_SESSION['Contract'.$identifier]->DebtorNo . "' AND custbranch.branchcode='" . $_SESSION['Contract'.$identifier]->BranchCode . "'" ; - $ErrMsg = _('The customer record selected') . ': ' . $_POST['SelectedCustomer'] . ' ' . - _('cannot be retrieved because'); + $ErrMsg = _('The customer record selected') . ': ' .$_SESSION['Contract'.$identifier]->DebtorNo. ' ' . _('cannot be retrieved because'); $DbgMsg = _('The SQL used to retrieve the customer details and failed was'); $result = DB_query($sql,$db,$ErrMsg,$DbgMsg); $myrow = DB_fetch_array($result); @@ -783,8 +796,8 @@ } else { echo '<td></td>'; } - echo '<td><input tabindex="'.number_format($j+5).'" type="submit" name="Submit" value="'.htmlentities($myrow['brname']).'" /></td> - <input type="hidden" name="SelectedCustomer" value="'.$myrow['debtorno'].' - '.$myrow['branchcode'].'" /> + echo '<td><input tabindex="'.($j+5).'" type="submit" name="SubmitCustomerSelection' . $j .'" value="'.htmlentities($myrow['brname']).'" /></td> + <input type="hidden" name="SelectedCustomer' . $j .'" value="'.$myrow['debtorno'].' - '.$myrow['branchcode'].'" /> <td>'.htmlentities($myrow['contactname']).'</td> <td>'.$myrow['phoneno'].'</td> <td>'.$myrow['faxno'].'</td> @@ -794,7 +807,8 @@ //end of page full new headings if } //end of while loop - + echo '<input type="hidden" name="JustSelectedACustomer" value="Yes">'; + echo '</table></form>'; }//end if results to show Modified: trunk/GoodsReceived.php =================================================================== --- trunk/GoodsReceived.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/GoodsReceived.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -26,13 +26,13 @@ $title = _('Receive Purchase Orders'); include('includes/header.inc'); -echo '<a href="'. $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">' . _('Back to Purchase Orders'). '</a><br>'; +echo '<a href="'. $rootpath . '/PO_SelectOSPurchOrder.php">' . _('Back to Purchase Orders'). '</a><br />'; if (isset($_GET['PONumber']) and $_GET['PONumber']<=0 and !isset($_SESSION['PO'.$identifier])) { /* This page can only be called with a purchase order number for invoicing*/ echo '<div class="centre"><a href= "' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">'. _('Select a purchase order to receive').'</a></div>'; - echo '<br>'. _('This page can only be opened if a purchase order has been selected. Please select a purchase order first'); + echo '<br />'. _('This page can only be opened if a purchase order has been selected. Please select a purchase order first'); include ('includes/footer.inc'); exit; } elseif (isset($_GET['PONumber']) AND !isset($_POST['Update'])) { @@ -55,7 +55,7 @@ } if ($_SESSION['PO'.$identifier]->Status != 'Printed') { - prnMsg( _('Purchase orders must have a status of Printed before they can be received').'.<br>'. + prnMsg( _('Purchase orders must have a status of Printed before they can be received').'.<br />'. _('Order number') . ' ' . $_GET['PONumber'] . ' ' . _('has a status of') . ' ' . _($_SESSION['PO'.$identifier]->Status), 'warn'); include('includes/footer.inc'); exit; @@ -78,7 +78,7 @@ echo '<table class=selection><tr><td>'. _('Date Goods/Service Received'). ':</td><td><input type=text class=date alt="'. $_SESSION['DefaultDateFormat'] .'" maxlength=10 size=10 onChange="return isDate(this, this.value, '."'". $_SESSION['DefaultDateFormat']."'".')" name=DefaultReceivedDate value="' . $_POST['DefaultReceivedDate'] . - '"></td></tr></table><br>'; + '"></td></tr></table><br />'; echo '<table cellpadding=2 class=selection> <tr><th colspan="2"></th> @@ -88,17 +88,17 @@ </tr> <tr><th>' . _('Item Code') . '</th> <th>' . _('Description') . '</th> - <th>' . _('Quantity') . '<br>' . _('Ordered') . '</th> + <th>' . _('Quantity') . '<br />' . _('Ordered') . '</th> <th>' . _('Units') . '</th> <th>' . _('Already') . '<br />' . _('Received') . '</th> <th>' . _('Conversion') . '<br />' . _('Factor') . '</th> - <th>' . _('Quantity') . '<br>' . _('Ordered') . '</th> + <th>' . _('Quantity') . '<br />' . _('Ordered') . '</th> <th>' . _('Units') . '</th> <th>' . _('Already') . '<br />' . _('Received') . '</th> <th>' . _('This Delivery') . '<br />' . _('Quantity') . '</th>'; if ($_SESSION['ShowValueOnGRN']==1) { - echo '<th>' . _('Price') . '</th><th>' . _('Total Value') . '<br>' . _('Received') . '</th>'; + echo '<th>' . _('Price') . '</th><th>' . _('Total Value') . '<br />' . _('Received') . '</th>'; } echo '<td> </td> @@ -156,7 +156,7 @@ if ($LnItm->Controlled == 1) { - echo '<input type=hidden name="RecvQty_' . $LnItm->LineNo . '" value="' . $LnItm->ReceiveQty . '"><a href="GoodsReceivedControlled.php?' . SID . '&LineNo=' . $LnItm->LineNo . '">' . number_format($LnItm->ReceiveQty,$LnItm->DecimalPlaces) . '</a></td>'; + echo '<input type=hidden name="RecvQty_' . $LnItm->LineNo . '" value="' . $LnItm->ReceiveQty . '"><a href="GoodsReceivedControlled.php?identifier=' . $identifier . '&LineNo=' . $LnItm->LineNo . '">' . number_format($LnItm->ReceiveQty,$LnItm->DecimalPlaces) . '</a></td>'; } else { echo '<input type=text class=number name="RecvQty_' . $LnItm->LineNo . '" maxlength=10 size=10 value="' . $LnItm->ReceiveQty . '"></td>'; @@ -170,10 +170,10 @@ if ($LnItm->Controlled == 1) { if ($LnItm->Serialised==1){ - echo '<td><a href="GoodsReceivedControlled.php?' . SID . '&LineNo=' . $LnItm->LineNo . '">'. + echo '<td><a href="GoodsReceivedControlled.php?identifier=' . $identifier . '&LineNo=' . $LnItm->LineNo . '">'. _('Enter Serial Nos'). '</a></td>'; } else { - echo '<td><a href="GoodsReceivedControlled.php?' . SID . '&LineNo=' . $LnItm->LineNo . '">'. + echo '<td><a href="GoodsReceivedControlled.php?identifier=' . $identifier . '&LineNo=' . $LnItm->LineNo . '">'. _('Enter Batches'). '</a></td>'; } } @@ -237,7 +237,7 @@ }elseif ($DeliveryQuantityTooLarge==1 AND isset($_POST['ProcessGoodsReceived'])){ prnMsg(_('Entered quantities cannot be greater than the quantity entered on the purchase invoice including the allowed over-receive percentage'). ' ' . '(' . $_SESSION['OverReceiveProportion'] .'%)','error'); - echo '<br>'; + echo '<br />'; prnMsg(_('Modify the ordered items on the purchase invoice if you wish to increase the quantities'),'info'); echo '<div class="centre"><input type=submit name=Update Value=' . _('Update') . '>'; @@ -314,9 +314,9 @@ <td>' . $myrow['quantityrecd'] . '</td></tr>'; echo '</table>'; } - echo "<div class='centre'><a href='$rootpath/PO_SelectOSPurchOrder.php?" . SID . "'>". + echo '<div class="centre"><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php">'. _('Select a different purchase order for receiving goods against').'</a></div>'; - echo "<div class='centre'><a href='$rootpath/GoodsReceived.php?" . SID . '&PONumber=' . + echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php?PONumber=' . $_SESSION['PO'.$identifier]->OrderNumber . '">'. _('Re-read the updated purchase order for receiving goods against'). '</a></div>'; unset($_SESSION['PO'.$identifier]->LineItems); unset($_SESSION['PO'.$identifier]); @@ -681,8 +681,8 @@ unset($_SESSION['PO'.$identifier]); unset($_POST['ProcessGoodsReceived']); - echo '<br><div class=centre>'. _('GRN number'). ' '. $GRN .' '. _('has been processed').'<br>'; - echo '<br><a href=PDFGrn.php?GRNNo='.$GRN .'&PONo='.$PONo.'>'. _('Print this Goods Received Note (GRN)').'</a><br><br>'; + echo '<br /><div class=centre>'. _('GRN number'). ' '. $GRN .' '. _('has been processed').'<br />'; + echo '<br /><a href=PDFGrn.php?GRNNo='.$GRN .'&PONo='.$PONo.'>'. _('Print this Goods Received Note (GRN)').'</a><br /><br />'; echo '<a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">' . _('Select a different purchase order for receiving goods against'). '</a></div>'; /*end of process goods received entry */ @@ -691,9 +691,9 @@ } else { /*Process Goods received not set so show a link to allow mod of line items on order and allow input of date goods received*/ - echo '<br><div class="centre"><a href="' . $rootpath . '/PO_Items.php?=' . SID . '">' . _('Modify Order Items'). '</a></div>'; + echo '<br /><div class="centre"><a href="' . $rootpath . '/PO_Items.php">' . _('Modify Order Items'). '</a></div>'; - echo '<br><div class="centre"><input type=submit name=Update Value=' . _('Update') . '><p>'; + echo '<br /><div class="centre"><input type=submit name=Update Value=' . _('Update') . '><p>'; echo '<input type=submit name="ProcessGoodsReceived" Value="' . _('Process Goods Received') . '"></div>'; } Modified: trunk/GoodsReceivedControlled.php =================================================================== --- trunk/GoodsReceivedControlled.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/GoodsReceivedControlled.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -12,21 +12,32 @@ /* Session started in header.inc for password checking and authorisation level check */ include('includes/header.inc'); -if (!isset($_SESSION['PO'])) { +if (empty($_GET['identifier'])) { + if (empty($_POST['identifier'])){ + $identifier=date('U'); + } else { + $identifier=$_POST['identifier']; + } +} else { + $identifier=$_GET['identifier']; +} + + +if (!isset($_SESSION['PO'.$identifier])) { /* This page can only be called with a purchase order number for receiving*/ - echo '<div class="centre"><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">'. + echo '<div class="centre"><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php">'. _('Select a purchase order to receive'). '</a></div><br>'; prnMsg( _('This page can only be opened if a purchase order and line item has been selected') . '. ' . _('Please do that first'),'error'); include('includes/footer.inc'); exit; } -if ($_GET['LineNo']>0){ +if (isset($_GET['LineNo'])){ $LineNo = $_GET['LineNo']; -} else if ($_POST['LineNo']>0){ +} elseif (isset($_POST['LineNo'])){ $LineNo = $_POST['LineNo']; } else { - echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php?' . SID . '">'. + echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php">'. _('Select a line Item to Receive').'</a></div>'; prnMsg( _('This page can only be opened if a Line Item on a PO has been selected') . '. ' . _('Please do that first'), 'error'); include( 'includes/footer.inc'); @@ -34,11 +45,11 @@ } global $LineItem; -$LineItem = &$_SESSION['PO']->LineItems[$LineNo]; +$LineItem = &$_SESSION['PO'.$identifier]->LineItems[$LineNo]; if ($LineItem->Controlled !=1 ){ /*This page only relavent for controlled items */ - echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php?' . SID . '">'. + echo '<div class="centre"><a href="' . $rootpath . '/GoodsReceived.php">'. _('Back to the Purchase Order'). '</a></div>'; prnMsg( _('The line being received must be controlled as defined in the item definition'), 'error'); include('includes/footer.inc'); @@ -50,13 +61,13 @@ ********************************************/ echo '<div class="centre">'; -echo '<br><a href="'.$rootpath.'/GoodsReceived.php?' . SID . '">'. _('Back To Purchase Order'). ' # '. $_SESSION['PO']->OrderNo . '</a>'; +echo '<br><a href="'.$rootpath.'/GoodsReceived.php?identifier=' .$identifier . '">'. _('Back To Purchase Order'). ' # '. $_SESSION['PO'.$identifier]->OrderNo . '</a>'; echo '<br><font size=2><b>'. _('Receive controlled item'). ' '. $LineItem->StockID . ' - ' . $LineItem->ItemDescription . - ' ' . _('on order') . ' ' . $_SESSION['PO']->OrderNo . ' ' . _('from') . ' ' . $_SESSION['PO']->SupplierName . '</b></font></div>'; + ' ' . _('on order') . ' ' . $_SESSION['PO'.$identifier]->OrderNo . ' ' . _('from') . ' ' . $_SESSION['PO'.$identifier]->SupplierName . '</b></font></div>'; /** vars needed by InputSerialItem : **/ -$LocationOut = $_SESSION['PO']->Location; +$LocationOut = $_SESSION['PO'.$identifier]->Location; $ItemMustExist = false; $StockID = $LineItem->StockID; $InOutModifier=1; @@ -67,7 +78,7 @@ /*TotalQuantity set inside this include file from the sum of the bundles of the item selected for dispatch */ -$_SESSION['PO']->LineItems[$LineItem->LineNo]->ReceiveQty = $TotalQuantity; +$_SESSION['PO'.$identifier]->LineItems[$LineItem->LineNo]->ReceiveQty = $TotalQuantity; include( 'includes/footer.inc'); ?> \ No newline at end of file Modified: trunk/PricesByCost.php =================================================================== --- trunk/PricesByCost.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/PricesByCost.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -95,7 +95,7 @@ $SalesTypeRow = DB_fetch_array($ResultType); if (isset($CategoryRow['categorgdescription'])) { - $CategoryText = _('the') . ' ' . $CategoryRow['categorgdescription'] . ' ' . _('category'); + $CategoryText = $CategoryRow['categorgdescription'] . ' ' . _('category'); } else { $CategoryText = _('all Categories'); } /*end of else Category */ Modified: trunk/SelectOrderItems.php =================================================================== --- trunk/SelectOrderItems.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/SelectOrderItems.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -238,7 +238,6 @@ $myrow['narrative'], 'No', /* Update DB */ $myrow['orderlineno'], - // ConvertSQLDate($myrow['itemdue']), 0, '', ConvertSQLDate($myrow['itemdue']), @@ -288,8 +287,7 @@ } } -$msg=''; - +//Customer logins are not allowed to select other customers henc in_array(2,$_SESSION['AllowedPageSecurityTokens']) if (isset($_POST['SearchCust']) AND $_SESSION['RequireCustomerSelection']==1 AND in_array(2,$_SESSION['AllowedPageSecurityTokens'])){ if (($_POST['CustKeywords']!='') AND (($_POST['CustCode']!='') OR ($_POST['CustPhone']!=''))) { @@ -371,22 +369,34 @@ if (DB_num_rows($result_CustSelect)==1){ $myrow=DB_fetch_array($result_CustSelect); - $_POST['Select'] = $myrow['debtorno'] . ' - ' . $myrow['branchcode']; + $SelectedCustomer= $myrow['debtorno'] . ' - ' . $myrow['branchcode']; } elseif (DB_num_rows($result_CustSelect)==0){ prnMsg(_('No Customer Branch records contain the search criteria') . ' - ' . _('please try again') . ' - ' . _('Note a Customer Branch Name may be different to the Customer Name'),'info'); } } /*one of keywords or custcode was more than a zero length string */ } /*end of if search for customer codes/names */ +if (isset($_POST['JustSelectedACustomer'])){ + /*Need to figure out the number of the form variable that the user clicked on */ + for ($i=1;$i<count($_POST);$i++){ //loop through the returned customers + if(isset($_POST['SubmitCustomerSelection'.$i])){ + break; + } + } + if ($i==count($_POST)){ + prnMsg(_('Unable to identify the selected customer'),'error'); + } else { + $SelectedCustomer = $_POST['SelectedCustomer'.$i]; + } +} +/* will only be true if page called from customer selection form or set because only one customer + record returned from a search so parse the $SelectCustomer string into customer code and branch code */ +if (isset($SelectedCustomer)) { + + $CustomerBranchArray = explode('-',$SelectedCustomer); + $_SESSION['Items'.$identifier]->DebtorNo = trim($CustomerBranchArray[0]); + $_SESSION['Items'.$identifier]->Branch = trim($CustomerBranchArray[1]); -// will only be true if page called from customer selection form or set because only one customer -// record returned from a search so parse the $Select string into customer code and branch code */ -if (isset($_POST['Select']) AND $_POST['Select']!='') { - - $_SESSION['Items'.$identifier]->Branch = substr($_POST['Select'],strpos($_POST['Select'],' - ')+3); - - $_POST['Select'] = substr($_POST['Select'],0,strpos($_POST['Select'],' - ')); - // Now check to ensure this account is not on hold */ $sql = "SELECT debtorsmaster.name, holdreasons.dissallowinvoices, @@ -402,30 +412,29 @@ WHERE debtorsmaster.salestype=salestypes.typeabbrev AND debtorsmaster.holdreason=holdreasons.reasoncode AND debtorsmaster.paymentterms=paymentterms.termsindicator - AND debtorsmaster.debtorno = '" . $_POST['Select'] . "'"; + AND debtorsmaster.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo. "'"; - $ErrMsg = _('The details of the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); + $ErrMsg = _('The details of the customer selected') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); $DbgMsg = _('The SQL used to retrieve the customer details and failed was') . ':'; $result =DB_query($sql,$db,$ErrMsg,$DbgMsg); - $myrow = DB_fetch_row($result); + $myrow = DB_fetch_array($result); if ($myrow[1] != 1){ if ($myrow[1]==2){ prnMsg(_('The') . ' ' . $myrow[0] . ' ' . _('account is currently flagged as an account that needs to be watched. Please contact the credit control personnel to discuss'),'warn'); } - $_SESSION['Items'.$identifier]->DebtorNo=$_POST['Select']; $_SESSION['RequireCustomerSelection']=0; - $_SESSION['Items'.$identifier]->CustomerName = $myrow[0]; + $_SESSION['Items'.$identifier]->CustomerName = $myrow['name']; # the sales type determines the price list to be used by default the customer of the user is # defaulted from the entry of the userid and password. - $_SESSION['Items'.$identifier]->DefaultSalesType = $myrow[2]; - $_SESSION['Items'.$identifier]->SalesTypeName = $myrow[3]; - $_SESSION['Items'.$identifier]->DefaultCurrency = $myrow[4]; - $_SESSION['Items'.$identifier]->DefaultPOLine = $myrow[5]; - $_SESSION['Items'.$identifier]->PaymentTerms = $myrow[6]; + $_SESSION['Items'.$identifier]->DefaultSalesType = $myrow['salestype']; + $_SESSION['Items'.$identifier]->SalesTypeName = $myrow['sales_type']; + $_SESSION['Items'.$identifier]->DefaultCurrency = $myrow['currcode']; + $_SESSION['Items'.$identifier]->DefaultPOLine = $myrow['customerpoline']; + $_SESSION['Items'.$identifier]->PaymentTerms = $myrow['terms']; # the branch was also selected from the customer selection so default the delivery details from the customer branches table CustBranch. The order process will ask for branch details later anyway @@ -449,24 +458,24 @@ INNER JOIN locations ON custbranch.defaultlocation=locations.loccode WHERE custbranch.branchcode='" . $_SESSION['Items'.$identifier]->Branch . "' - AND custbranch.debtorno = '" . $_POST['Select'] . "'"; + AND custbranch.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo . "'"; - $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); + $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); $DbgMsg = _('SQL used to retrieve the branch details was') . ':'; $result =DB_query($sql,$db,$ErrMsg,$DbgMsg); if (DB_num_rows($result)==0){ - prnMsg(_('The branch details for branch code') . ': ' . $_SESSION['Items'.$identifier]->Branch . ' ' . _('against customer code') . ': ' . $_POST['Select'] . ' ' . _('could not be retrieved') . '. ' . _('Check the set up of the customer and branch'),'error'); + prnMsg(_('The branch details for branch code') . ': ' . $_SESSION['Items'.$identifier]->Branch . ' ' . _('against customer code') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('could not be retrieved') . '. ' . _('Check the set up of the customer and branch'),'error'); if ($debug==1){ - echo '<br>' . _('The SQL that failed to get the branch details was') . ':<br>' . $sql; + prnMsg( _('The SQL that failed to get the branch details was') . ':<br />' . $sql . 'warning'); } include('includes/footer.inc'); exit; } // add echo - echo '<br>'; + echo '<br />'; $myrow = DB_fetch_row($result); if ($_SESSION['SalesmanLogin']!='' AND $_SESSION['SalesmanLogin']!=$myrow[15]){ prnMsg(_('Your login is only set up for a particular salesperson. This customer has a different salesperson.'),'error'); @@ -494,7 +503,7 @@ prnMsg($_SESSION['Items'.$identifier]->SpecialInstructions,'warn'); if ($_SESSION['CheckCreditLimits'] > 0){ /*Check credit limits is 1 for warn and 2 for prohibit sales */ - $_SESSION['Items'.$identifier]->CreditAvailable = GetCreditAvailable($_POST['Select'],$db); + $_SESSION['Items'.$identifier]->CreditAvailable = GetCreditAvailable($_SESSION['Items'.$identifier]->DebtorNo,$db); if ($_SESSION['CheckCreditLimits']==1 AND $_SESSION['Items'.$identifier]->CreditAvailable <=0){ prnMsg(_('The') . ' ' . $myrow[0] . ' ' . _('account is currently at or over their credit limit'),'warn'); @@ -524,12 +533,8 @@ WHERE debtorsmaster.holdreason=holdreasons.reasoncode AND debtorsmaster.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo . "'"; - if (isset($_POST['Select'])) { - $ErrMsg = _('The details for the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); - } else { - $ErrMsg = ''; - } - $DbgMsg = _('SQL used to retrieve the customer details was') . ':<br>' . $sql; + $ErrMsg = _('The details for the customer selected') . ': ' .$_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); + $DbgMsg = _('SQL used to retrieve the customer details was') . ':<br />' . $sql; $result =DB_query($sql,$db,$ErrMsg,$DbgMsg); $myrow = DB_fetch_row($result); @@ -568,11 +573,7 @@ WHERE custbranch.branchcode='" . $_SESSION['Items'.$identifier]->Branch . "' AND custbranch.debtorno = '" . $_SESSION['Items'.$identifier]->DebtorNo . "'"; - if (isset($_POST['Select'])) { - $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_POST['Select'] . ' ' . _('cannot be retrieved because'); - } else { - $ErrMsg = ''; - } + $ErrMsg = _('The customer branch record of the customer selected') . ': ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('cannot be retrieved because'); $DbgMsg = _('SQL used to retrieve the branch details was'); $result =DB_query($sql,$db,$ErrMsg, $DbgMsg); @@ -610,7 +611,6 @@ <?php echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; ?> - <b><?php echo '<p>' . $msg; ?></p> <table cellpadding=3 colspan=4 class=selection> <tr> <td><h5><?php echo _('Part of the Customer Branch Name'); ?>:</h5></td> @@ -623,7 +623,7 @@ <td><input tabindex=3 type="Text" name="CustPhone" size=15 maxlength=18></td> </tr> </table> - <br><div class="centre"><input tabindex=4 type=submit name="SearchCust" value="<?php echo _('Search Now'); ?>"> + <br /><div class="centre"><input tabindex=4 type=submit name="SearchCust" value="<?php echo _('Search Now'); ?>"> <input tabindex=5 type=submit action=reset value="<?php echo _('Reset'); ?>"></div> <?php @@ -631,7 +631,7 @@ echo '<table cellpadding=2 colspan=7>'; - $TableHeader = '<br><tr> + $TableHeader = '<br /><tr> <th>' . _('Customer') . '</th> <th>' . _('Branch') . '</th> <th>' . _('Contact') . '</th> @@ -659,20 +659,20 @@ } else { echo '<td></td>'; } - echo '<td><input tabindex='.number_format($j+5).' type=submit name="Submit" value="'.$myrow['brname'].'"</td> - <input type=hidden name="Select" value="'.$myrow['debtorno'].' - '.$myrow['branchcode'].'"> + echo '<td><input tabindex='.($j+5).' type=submit name="SubmitCustomerSelection' . $j .'" value="' . htmlentities($myrow['brname']) . '"></td> + <input type="hidden" name="SelectedCustomer' . $j .'" value="'.$myrow['debtorno'] .' - '.$myrow['branchcode'].'"> <td>'.$myrow['contactname'].'</td> <td>'.$myrow['phoneno'].'</td> <td>'.$myrow['faxno'].'</td> - </tr></form>'; + </tr>'; $LastCustomer=$myrow['name']; $j++; //end of page full new headings if } //end of while loop + echo '<input type="hidden" name="JustSelectedACustomer" value="Yes">'; + echo '</table></form>'; - echo '</table>'; - }//end if results to show //end if RequireCustomerSelection @@ -723,7 +723,7 @@ } else { $_SESSION['RequireCustomerSelection'] = 0; } - echo '<br><br>'; + echo '<br /><br />'; prnMsg(_('This sales order has been cancelled as requested'),'success'); include('includes/footer.inc'); exit; @@ -739,13 +739,13 @@ } echo ':<b> ' . $_SESSION['Items'.$identifier]->DebtorNo . ' ' . _('Customer Name') . ': ' . $_SESSION['Items'.$identifier]->CustomerName; - echo '</b></p><div class="page_help_text">' . '<b>' . _('Default Options (can be modified during order):') . '</b><br>' . _('Deliver To') . ':<b> ' . $_SESSION['Items'.$identifier]->DeliverTo; + echo '</b></p><div class="page_help_text">' . '<b>' . _('Default Options (can be modified during order):') . '</b><br />' . _('Deliver To') . ':<b> ' . $_SESSION['Items'.$identifier]->DeliverTo; echo '</b> ' . _('From Location') . ':<b> ' . $_SESSION['Items'.$identifier]->LocationName; - echo '</b><br>' . _('Sales Type') . '/' . _('Price List') . ':<b> ' . $_SESSION['Items'.$identifier]->SalesTypeName; - echo '</b><br>' . _('Terms') . ':<b> ' . $_SESSION['Items'.$identifier]->PaymentTerms; + echo '</b><br />' . _('Sales Type') . '/' . _('Price List') . ':<b> ' . $_SESSION['Items'.$identifier]->SalesTypeName; + echo '</b><br />' . _('Terms') . ':<b> ' . $_SESSION['Items'.$identifier]->PaymentTerms; echo '</b></div>'; } - + $msg =''; if (isset($_POST['Search']) or isset($_POST['Next']) or isset($_POST['Prev'])){ if ($_POST['Keywords']!=='' AND $_POST['StockCode']=='') { @@ -769,7 +769,7 @@ WHERE stockmaster.categoryid=stockcategory.categoryid AND (stockcategory.stocktype='F' OR stockcategory.stocktype='D') AND stockmaster.mbflag <>'G' - AND stockmaster.description " . LIKE . " '$SearchString' + AND stockmaster.description " . LIKE . " '" . $SearchString . "' AND stockmaster.discontinued=0 ORDER BY stockmaster.stockid"; } else { @@ -1280,13 +1280,13 @@ /* This is where the order as selected should be displayed reflecting any deletions or insertions*/ - echo '<br> + echo '<br /> <table width="90%" cellpadding="2" colspan="7"> <tr bgcolor=#800000>'; if($_SESSION['Items'.$identifier]->DefaultPOLine == 1){ echo '<th>' . _('PO Line') . '</th>'; } - echo '<div class="page_help_text">' . _('Quantity (required) - Enter the number of units ordered. Price (required) - Enter the unit price. Discount (optional) - Enter a percentage discount. GP% (optional) - Enter a percentage Gross Profit (GP) to add to the unit cost. Due Date (optional) - Enter a date for delivery.') . '</div><br>'; + echo '<div class="page_help_text">' . _('Quantity (required) - Enter the number of units ordered. Price (required) - Enter the unit price. Discount (optional) - Enter a percentage discount. GP% (optional) - Enter a percentage Gross Profit (GP) to add to the unit cost. Due Date (optional) - Enter a date for delivery.') . '</div><br />'; echo '<th>' . _('Item Code') . '</th> <th>' . _('Item Description') . '</th> <th>' . _('Quantity') . '</th> @@ -1336,7 +1336,7 @@ echo '<td><input class="number" tabindex=2 type=tect name="Quantity_' . $OrderLine->LineNumber . '" size=6 maxlength=6 value=' . $OrderLine->Quantity . '>'; if ($QtyRemain != $QtyOrdered){ - echo '<br>'.$OrderLine->QtyInv.' of '.$OrderLine->Quantity.' invoiced'; + echo '<br />'.$OrderLine->QtyInv.' of '.$OrderLine->Quantity.' invoiced'; } echo '</td> <td class="number">' . $OrderLine->QOHatLoc . '</td> @@ -1369,7 +1369,7 @@ if ($_SESSION['AllowOrderLineItemNarrative'] == 1){ echo $RowStarter; - echo '<td colspan=10>' . _('Narrative') . ':<textarea name="Narrative_' . $OrderLine->LineNumber . '" cols="100%" rows="1">' . stripslashes(AddCarriageReturns($OrderLine->Narrative)) . '</textarea><br></td></tr>'; + echo '<td colspan=10>' . _('Narrative') . ':<textarea name="Narrative_' . $OrderLine->LineNumber . '" cols="100%" rows="1">' . stripslashes(AddCarriageReturns($OrderLine->Narrative)) . '</textarea><br /></td></tr>'; } else { echo '<input type=hidden name="Narrative" value="">'; } @@ -1398,7 +1398,7 @@ </tr></table>'; - echo '<br><div class="centre"><input type=submit name="Recalculate" Value="' . _('Re-Calculate') . '"> + echo '<br /><div class="centre"><input type=submit name="Recalculate" Value="' . _('Re-Calculate') . '"> <input type=submit name="DeliveryDetails" value="' . _('Enter Delivery Details and Confirm Order') . '"></div><hr>'; } # end of if lines @@ -1428,8 +1428,8 @@ $result2 = DB_query($SQL,$db); echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/magnifier.png" title="' . _('Search') . '" alt="" />' . ' '; - echo _('Frequently Ordered Items') . '</p><br>'; - echo '<div class="page_help_text">' . _('Frequently Ordered Items') . _(', shows the most frequently ordered items in the last 6 months. You can choose from this list, or search further for other items') . '.</div><br>'; + echo _('Frequently Ordered Items') . '</p><br />'; + echo '<div class="page_help_text">' . _('Frequently Ordered Items') . _(', shows the most frequently ordered items in the last 6 months. You can choose from this list, or search further for other items') . '.</div><br />'; echo '<table class="table1">'; $TableHeader = '<tr><th>' . _('Code') . '</th> <th>' . _('Description') . '</th> @@ -1553,7 +1553,7 @@ echo '<p><div class="centre"><b><p>' . $msg . '</b></p>'; echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/magnifier.png" title="' . _('Search') . '" alt="" />' . ' '; echo _('Search for Order Items') . '</p>'; - echo '<div class="page_help_text">' . _('Search for Order Items') . _(', Searches the database for items, you can narrow the results by selecting a stock category, or just enter a partial item description or partial item code') . '.</div><br>'; + echo '<div class="page_help_text">' . _('Search for Order Items') . _(', Searches the database for items, you can narrow the results by selecting a stock category, or just enter a partial item description or partial item code') . '.</div><br />'; echo '<table class="selection"><tr><td><b>' . _('Select a Stock Category') . ': </b><select tabindex=1 name="StockCat">'; if (!isset($_POST['StockCat'])){ @@ -1601,13 +1601,13 @@ if (in_array(2,$_SESSION['AllowedPageSecurityTokens'])){ //not a customer entry of own order echo '<td style="text-align:center" colspan=1><input tabindex=6 type="submit" name="ChangeCustomer" value="' . _('Change Customer') . '"></td> <td style="text-align:center" colspan=1><input tabindex=7 type="submit" name="SelectAsset" value="' . _('Fixed Asset Disposal') . '"></td> - </tr></table><br>'; + </tr></table><br />'; } if (isset($SearchResult)) { - echo '<br>'; + echo '<br />'; echo '<div class="page_help_text">' . _('Select an item by entering the quantity required. Click Order when ready.') . '</div>'; - echo '<br>'; + echo '<br />'; $j = 1; echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID .'identifier='.$identifier . ' method=post name="orderform">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; @@ -1631,7 +1631,7 @@ while ($myrow=DB_fetch_array($SearchResult)) { // Find the quantity in stock at location - $QOHSQL = "SELECT sum(quantity) AS qoh, + $QOHSQL = "SELECT quantity AS qoh, stockmaster.decimalplaces FROM locstock INNER JOIN stockmaster ON locstock.stockid = stockmaster.stockid @@ -1662,11 +1662,12 @@ } // Find the quantity on purchase orders - $sql = "SELECT SUM(purchorderdetails.quantityord-purchorderdetails.quantityrecd) AS dem + $sql = "SELECT SUM(purchorderdetails.quantityord-purchorderdetails.quantityrecd) AS qoo FROM purchorderdetails INNER JOIN purchorders WHERE purchorderdetails.completed=0 AND purchorders.status<>'Cancelled' AND purchorders.status<>'Rejected' + AND purchorders.status<>'Pending' AND purchorderdetails.itemcode='" . $myrow['stockid'] . "'"; $ErrMsg = _('The order details for this product cannot be retrieved because'); @@ -1741,7 +1742,7 @@ } /*end of PartSearch options to be displayed */ elseif( isset($_POST['QuickEntry'])) { /* show the quick entry form variable */ /*FORM VARIABLES TO POST TO THE ORDER WITH PART CODE AND QUANTITY */ - echo '<div class="page_help_text"><b>' . _('Use this screen for the '). _('Quick Entry')._(' of products to be ordered') . '</b></div><br> + echo '<div class="page_help_text"><b>' . _('Use this screen for the '). _('Quick Entry')._(' of products to be ordered') . '</b></div><br /> <table border=1> <tr>'; /*do not display colum unless customer requires po line number by sales order line*/ @@ -1767,12 +1768,12 @@ } echo '<script type="text/javascript">if (document.SelectParts) {defaultControl(document.SelectParts.part_1);}</script>'; - echo '</table><br><div class="centre"><input type="submit" name="QuickEntry" value="' . _('Quick Entry') . '"> + echo '</table><br /><div class="centre"><input type="submit" name="QuickEntry" value="' . _('Quick Entry') . '"> <input type="submit" name="PartSearch" value="' . _('Search Parts') . '"></div>'; } elseif (isset($_POST['SelectAsset'])){ - echo '<div class="page_help_text"><b>' . _('Use this screen to select an asset to dispose of to this customer') . '</b></div><br> + echo '<div class="page_help_text"><b>' . _('Use this screen to select an asset to dispose of to this customer') . '</b></div><br /> <table border=1>'; /*do not display colum unless customer requires po line number by sales order line*/ if($_SESSION['Items'.$identifier]->DefaultPOLine ==1){ @@ -1787,13 +1788,13 @@ echo '<option value="' . $AssetRow['assetid'] . '">' . $AssetRow['assetid'] . ' - ' . $AssetRow['description'] . '</option>'; } echo '</select></td></tr></table> - <br><div class="centre"><input type="submit" name="AssetDisposalEntered" value="' . _('Add Asset To Order') . '"> + <br /><div class="centre"><input type="submit" name="AssetDisposalEntered" value="' . _('Add Asset To Order') . '"> <input type="submit" name="PartSearch" value="' . _('Search Parts') . '"></div>'; } //end of if it is a Quick Entry screen/part search or asset selection form to display if ($_SESSION['Items'.$identifier]->ItemsOrdered >=1){ - echo '<br><div class="centre"><input type=submit name="CancelOrder" value="' . _('Cancel Whole Order') . '" onclick="return confirm(\'' . _('Are you sure you wish to cancel this entire order?') . '\');"></div>'; + echo '<br /><div class="centre"><input type=submit name="CancelOrder" value="' . _('Cancel Whole Order') . '" onclick="return confirm(\'' . _('Are you sure you wish to cancel this entire order?') . '\');"></div>'; } }#end of else not selecting a customer @@ -1803,4 +1804,4 @@ echo '<script type="text/javascript">if (document.SelectParts) {defaultControl(document.SelectCustomer.CustKeywords);}</script>'; } include('includes/footer.inc'); -?> +?> \ No newline at end of file Modified: trunk/StockSerialItems.php =================================================================== --- trunk/StockSerialItems.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/StockSerialItems.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -11,6 +11,11 @@ '" alt="" /><b>' . $title. '</b></p>'; if (isset($_GET['StockID'])){ + if (ContainsIllegalCharacters ($_GET['StockID'])){ + prnMsg(_('The stock code sent to this page appears to be invalid'),'error'); + include('includes/footer.inc'); + exit; + } $StockID = trim(strtoupper($_GET['StockID'])); } else { prnMsg( _('This page must be called with parameters specifying the item to show the serial references and quantities') . '. ' . _('It cannot be displayed without the proper parameters being passed'),'error'); Modified: trunk/SuppInvGRNs.php =================================================================== --- trunk/SuppInvGRNs.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/SuppInvGRNs.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -241,7 +241,7 @@ <td>' . $GRNTmp->ItemCode . ' ' . $GRNTmp->ItemDescription . '</td> <td class=number>' . number_format($GRNTmp->QtyRecd - $GRNTmp->Prev_QuantityInv,2) . '</td> <td><input type="text" class="number" Name="This_QuantityInv" Value="' . $GRNTmp->This_QuantityInv . '" size=11 maxlength=10></td> - <td class=number>"' . $GRNTmp->OrderPrice . '"</td> + <td class=number>' . $GRNTmp->OrderPrice . '</td> <td><input type="text" class="number" Name="ChgPrice" Value=' . $GRNTmp->ChgPrice . ' size="11" maxlength="10"></td> </tr>'; echo '</table>'; Modified: trunk/SystemParameters.php =================================================================== --- trunk/SystemParameters.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/SystemParameters.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -623,14 +623,14 @@ <td><select Name="X_PO_AllowSameItemMultipleTimes"> <option '.($_SESSION['PO_AllowSameItemMultipleTimes']?'selected ':'').'value="1">'._('Yes') . '</option> <option '.(!$_SESSION['PO_AllowSameItemMultipleTimes']?'selected ':'').'value="0">'._('No') . '</option> - </select></td> <td></td></tr>'; + </select></td><td>' . _('If a purchase order can have the same item on the order several times this parameter should be set to yes') . '</td></tr>'; // 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').' - </select></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></td></tr>'; + </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>'; echo '<tr><th colspan=3>' . _('General Settings') . '</th></tr>'; Modified: trunk/UpgradeDatabase.php =================================================================== --- trunk/UpgradeDatabase.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/UpgradeDatabase.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -29,7 +29,7 @@ echo '<option value="3.08">' . _('Version 3.08') . '</option>'; echo '<option value="3.09">' . _('Version 3.09') . '</option>'; echo '<option value="3.10">' . _('Version 3.10') . '</option>'; - echo '<option value="3.11">' . _('Version 3.11') . '</option>'; + echo '<option value="3.11">' . _('Version 3.11 or 4.01 - 4.02') . '</option>'; echo '</select></td></tr></table>'; } else { if ($_SESSION['VersionNumber']=='4.00-RC1'){ @@ -48,7 +48,7 @@ if ($dbType=='mysql' OR $dbType =='mysqli'){ /* First do a backup */ - $BackupFile = '.' . $PathPrefix . '/companies/' . $_SESSION['DatabaseName'] .'/' . _('Backup') . '_' . Date('Y-m-d-H-i-s') . '.gz'; + $BackupFile = $PathPrefix . './companies/' . $_SESSION['DatabaseName'] .'/' . _('Backup') . '_' . Date('Y-m-d-H-i-s') . '.sql.gz'; $Command = 'mysqldump --opt -h' . $host . ' -u' . $dbuser . ' -p' . $dbpassword . ' ' . $_SESSION['DatabaseName'] . '| gzip > ' . $BackupFile; system($Command); Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/doc/Change.log.html 2011-02-13 04:15:38 UTC (rev 4490) @@ -1,5 +1,9 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p -<p></p> +<p /> +<p>13/2/11 Release 4.03RC1</p> +<p /> +<p>13/2/11:Phil GoodsReceivedControlled InputSerialItems and friends - now uses session identifier to ensure uniqueness is several people entering stock receipts</p> +<p>13/2/11:Phil Contracts.php SelectOrderItems.php customer selection mechanism reworked - was causing issues in Contracts as noted by DK Shukla</p> <p>8/2/11: Tim Rework CounterSales.php so that it is now possible to sell items that have sales/purchasing tax</p> <p>8/2/11: Phil Fix InventoryPlanning and InventoryPlanningPrefSupplier to only show sales order demand - excluding quotations. Also fixed for conversionfactor as now all purchase order quantities are in our normal stock units</p> <p>8/2/11: Phil Fix incorrect layout of narrative on multiple lines of PDFQuotation.php as reported by Ricard Andreu</p> Modified: trunk/doc/INSTALL.txt =================================================================== --- trunk/doc/INSTALL.txt 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/doc/INSTALL.txt 2011-02-13 04:15:38 UTC (rev 4490) @@ -4,8 +4,12 @@ Upgrading -A php upgrade script is provided for versions from 3.05 that applies the database changes required to move from the previous version to the newer version - this script also updates any data as required to work with the new version scripts. Simply point your browser to Z_Upgrade3.06-3.07.php (for an upgrade between 3.06 and 3.07 - similar naming convention applies to subsequent releases) and follow the prompts. If you are upgrading through several versions eg. from 3.05 to 3.08 then you must run each successive Z_UpgradeX.XX-X.XY.php script in sequence. +As from version 4.01 an automated database upgrade mechanism has been built in. Just copy the extract the scripts and copy: +1. config.php file from your old installation and +2. webERP/companies directory into the new webERP directory structure +Open up the webERP/index.php and the system will identify any database changes required. If the system is unable to indentify the database changes required - if the old system was a version prior to 4.01 then it will prompt you to select the old version you were using. The necessary database changes will then be applied automatically. + If the database must be updated manually (as it must for versions prior to 3.05): The SQL scripts are included under webERP/sql/mysql/ to update an existing mysql webERP database to the current version. The upgrade script no longer assumes the weberp database is called webERP. If using the mysql command line client then each upgrade SQL script must be edited to enter the name of the database to upgrade by adding a line @@ -41,7 +45,6 @@ The install script checks for the appropriate permissions and will not even attempt to install unless the web-server has the necessary write access to the files. - Manual Installation Read on below if you cannot use the installer to set up your installation for some reason or you simply wish to understand what is going on when the installer runs. @@ -50,7 +53,7 @@ Pre-requisites: -- A working PHP web server - v 5.0 or later is required (it no longer works with versions prior) PHP must have support for mysql databases (either mysql or mysqli), gd, gettext and ftp +- A working PHP web server - v 5.0 or later is required (it no longer works with versions prior) PHP must have support for mysql databases (either mysql or mysqli), gd, gettext, libxml and ftp - A working MySQL server (MySql version 4.1 or above - innodb tables MUST be enabled - check your my.cnf file to ensure innodb tables are enabled (normally under /etc/my.cnf or the mysql data directory - see the MySQL manual). Installing these components are well covered elsewhere - but if you need to install these components the recommended solution under windows would be to download and install apache2triad - http://apache2triad.net/ or under windows or *nix download and install XAMPP - http://www.apachefriends.org/en/xampp.html Modified: trunk/includes/ConnectDB.inc =================================================================== --- trunk/includes/ConnectDB.inc 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/ConnectDB.inc 2011-02-13 04:15:38 UTC (rev 4490) @@ -4,7 +4,7 @@ * this value is saved in the $_SESSION['Versionumber'] when includes/GetConfig.php is run * if VersionNumber is < $Version then the DB update script is run */ -$Version='3.12.32'; //must update manually every time there is a DB change +$Version='4.03'; //must update manually every time there is a DB change require_once ($PathPrefix .'includes/MiscFunctions.php'); Modified: trunk/includes/InputSerialItems.php =================================================================== --- trunk/includes/InputSerialItems.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/InputSerialItems.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -48,7 +48,7 @@ $invalid_imports = 0; $valid = true; -echo '<form method="post" action="' . $_SERVER['PHP_SELF'] . '?' . SID . '" enctype="multipart/form-data" >'; +echo '<form method="post" action="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier .'" enctype="multipart/form-data" >'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; echo '<input type=hidden name="LineNo" value="' . $LineNo . '">'; echo '<input type=hidden name="StockID" value="'. $StockID. '">'; @@ -71,7 +71,7 @@ } echo '<td valign=bottom>'; -echo '<input type=radio id="FileEntry" name=EntryType onClick="submit();" '; +echo '<input type="radio" id="FileEntry" name="EntryType" onClick="submit();" '; if ($_POST['EntryType']=='FILE') { echo ' checked '; } @@ -84,9 +84,9 @@ global $tableheader; /* Link to clear the list and start from scratch */ -$EditLink = '<br><div class="centre"><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&EditControlled=true&StockID=' . $LineItem->StockID . +$EditLink = '<br><div class="centre"><a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&EditControlled=true&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Edit'). '</a> | '; -$RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&DELETEALL=YES&StockID=' . $LineItem->StockID . +$RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&DELETEALL=YES&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Remove All'). '</a><br></div>'; if ($LineItem->Serialised==1){ $tableheader .= '<tr> Modified: trunk/includes/InputSerialItemsExisting.php =================================================================== --- trunk/includes/InputSerialItemsExisting.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/InputSerialItemsExisting.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -29,10 +29,11 @@ echo '<form action="' . $_SERVER['PHP_SELF'] . '?=' . SID . '" method="POST">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - echo '<input type=hidden name=LineNo value="' . $LineNo . '"> - <input type=hidden name=StockID value="' . $StockID . '"> - <input type=hidden name=EntryType value="KEYED"> - <input type=hidden name=EditControlled value="true"> + echo '<input type=hidden name="LineNo" value="' . $LineNo . '"> + <input type="hidden" name="StockID" value="' . $StockID . '"> + <input type="hidden" name="EntryType" value="KEYED"> + <input type=hidden name="identifier" value="' . $identifier . '"> + <input type="hidden" name="EditControlled" value="true"> <select Name=Bundles[] multiple>'; $id=0; Modified: trunk/includes/InputSerialItemsFile.php =================================================================== --- trunk/includes/InputSerialItemsFile.php 2011-02-11 16:43:22 UTC (rev 4489) +++ trunk/includes/InputSerialItemsFile.php 2011-02-13 04:15:38 UTC (rev 4490) @@ -34,17 +34,17 @@ //only show 1st 10 lines if ($RowCounter < 10){ if ($k==1){ - echo '<tr bgcolor="#CCCCCC">'; + echo '<tr class="EvenTableRows">'; $k=0; } else { - echo '<tr bgcolor="#EEEEEE">'; + echo '<tr class="OddTableRows">'; $k=1; } - echo '<TD>' . $Bundle->BundleRef . '</TD>'; + echo '<td>' . $Bundle->BundleRef . '</td>'; if ($LineItem->Serialised==0){ - echo '<TD ALIGN=RIGHT>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</TD>'; + echo '<td align=right>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; } } @@ -54,16 +54,16 @@ /*Display the totals and rule off before allowing new entries */ if ($LineItem->Serialised==1){ - echo '<TR><TD ALIGN=RIGHT><B>'. _('Total Quantity'). ': ' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</B></TD></TR>'; - echo '<TR><TD><HR></TD></TR>'; + echo '<tr><td align=right><b>'. _('Total Quantity'). ': ' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; + echo '<tr><td><hr></td></tr>'; } else { - echo '<TR><TD ALIGN=RIGHT><B>'. _('Total Quantity'). ':</B></TD><TD ALIGN=RIGHT><B>' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</B></TD></TR>'; - echo '<TR><TD COLSPAN=2><HR></TD></TR>'; + echo '<tr><td align=right><b>'. _('Total Quantity'). ':</B></TD><TD ALIGN=RIGHT><B>' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; + echo '<tr><td colspan=2><hr></td></tr>'; } -echo '</TABLE><HR>'; -//echo "<TABLE><TR><TD>"; +echo '</table><hr>'; + //DISPLAY FILE INFO // do some inits & error checks... $ShowFileInfo = false; @@ -75,18 +75,18 @@ $msg = _('Please Choose a file and then click Set Entry Type to upload a file for import'); prnMsg($msg); $LineItem->SerialItemsValid=false; - echo '</TD></TR></TABLE>'; + echo '</td></tr></table>'; include('includes/footer.inc'); exit(); } if ($_FILES['ImportFile']['error'] != '' && !isset($_SESSION['CurImportFile'])){ - echo _('There was a problem with the uploaded file') . '. ' . _('We received').':<BR>'. - _('Name').':'.$_FILES['ImportFile']['name'].'<br>'. - _('Size').':'.number_format($_FILES['ImportFile']['size']/1024,2).'kb<br>'. - _('Type').':'.$_FILES['ImportFile']['type'].'<br>'; - echo '<br>'._('Error was').' '.$_FILES['ImportFile']['error'].'<br>'; + echo _('There was a problem with the uploaded file') . '. ' . _('We received').':<br />'. + _('Name').':'.$_FILES['ImportFile']['name'].'<br />'. + _('Size').':'.number_format($_FILES['ImportFile']['size']/1024,2).'kb<br />'. + _('Type').':'.$_FILES['ImportFile']['type'].'<br />'; + echo '<br />'._('Error was').' '.$_FILES['ImportFile']['error'].'<br />'; $LineItem->SerialItemsValid=false; - echo '</TD></TR></TABLE>'; + echo '</td></tr></table>'; include('includes/footer.inc'); exit(); } elseif ($_FILES['ImportFile']['name']!=''){ @@ -100,18 +100,18 @@ if (!move_uploaded_file($_FILES['ImportFile']['tmp_name'],$_SESSION['CurImportFile']['tmp_name'])){ prnMsg(_('Error moving temporary file') . '. ' . _('Please check your configuration'),'error' ); $LineItem->SerialItemsValid=false; - echo '</TD></TR></TABLE>'; + echo '</td></tr></table>'; include('includes/footer.inc'); exit; } if ($_FILES['ImportFile']['name']!=''){ - echo _('Successfully received').':<br>'; + echo _('Successfully received').':<br />'; $ShowFileInfo = true; } } elseif (isset($_SESSION['CurImportFile']) && $_SESSION['CurImportFile']['Processed'] ) { //file exists, some action performed... - echo _('Working with'). ':<br>'; + echo _('Working with'). ':<br />'; $ShowFileInfo = true; } elseif ($LineItem->SerialItemsValid && $_SESSION['CurImportFile']['Processed']){ $ShowInfo = true; @@ -120,20 +120,20 @@ /******************************************** Display file info for visual verification ********************************************/ - echo '<TABLE>'; + echo '<table>'; echo '<tr><td>'._('Name').':</td><td>'.$_SESSION['CurImportFile']['name'].'</td></tr> <tr><td>'. _('Size') .':</td><td>' . number_format($_SESSION['CurImportFile']['size']/1024,4) . 'kb</td></tr> <tr><td>'. _('Type') .':</td><td>' . $_SESSION['CurImportFile']['type'] . '</td></tr> <tr><td>'. _('TempName') .':</td><td>' . $_SESSION['CurImportFile']['tmp_name'] . '</td></tr> <tr><td>'. _('Status') .':</td><td>' . ($LineItem->SerialItemsValid?getMsg(_('Valid'),'success'):getMsg(_('Invalid'),'error')) . '</td></tr> - </TABLE>'. - $invalid_imports.' '. _('out of') .' '.$TotalLines.' '. _('records are invalid').'<br>'; + </table>'. + $invalid_imports.' '. _('out of') .' '.$TotalLines.' '. _('records are invalid').'<br />'; $filename = $_SESSION['CurImportFile']['tmp_name']; } if (!$LineItem->SerialItemsValid && !$_SESSION['CurImportFile']['Processed']){ - // IF all items are not valid, show the raw first 10 lines of the file. maybe it will help. + // If all items are not valid, show the raw first 10 lines of the file. maybe it will help. $filename = $_SESSION['CurImportFile']['tmp_name']; $handle = fopen($filename, 'r'); $i=0; @@ -143,12 +143,13 @@ } fclose($handle); - echo '<br><form method=POST>'; + echo '<br /><form method=POST>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - echo '<input type=submit name=ValidateFile value=' . _('Validate File') . '> - <input type=hidden name=LineNo value="' . $LineNo . '"> - <input type=hidden name=StockID value="' . $StockID . '"> - <input type=hidden name=EntryType value="FILE"> + echo '<input type=submit name="ValidateFile" value=' . _('Validate File') . '> + <input type=hidden name="LineNo" value="' . $LineNo . '"> + <input type=hidden name="identifier" value="' . $identifier . '"> + <input type=hidden name="StockID" value="' . $StockID . '"> + <input type=hidden name="EntryType" value="FILE"> </form> <... [truncated message content] |
From: <dai...@us...> - 2011-02-15 06:31:18
|
Revision: 4491 http://web-erp.svn.sourceforge.net/web-erp/?rev=4491&view=rev Author: daintree Date: 2011-02-15 06:31:08 +0000 (Tue, 15 Feb 2011) Log Message: ----------- Pre 4.03RC2 Modified Paths: -------------- trunk/ConfirmDispatch_Invoice.php trunk/DeliveryDetails.php trunk/PrintCustTrans.php trunk/PrintCustTransPortrait.php trunk/SelectCustomer.php trunk/SelectOrderItems.php trunk/UpgradeDatabase.php trunk/doc/Change.log.html trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.mo trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po trunk/locale/de_DE.utf8/LC_MESSAGES/messages.mo trunk/locale/de_DE.utf8/LC_MESSAGES/messages.po trunk/locale/el_GR.utf8/LC_MESSAGES/messages.mo trunk/locale/el_GR.utf8/LC_MESSAGES/messages.po trunk/locale/en_GB.utf8/LC_MESSAGES/messages.pot trunk/locale/en_US.utf8/LC_MESSAGES/messages.mo trunk/locale/en_US.utf8/LC_MESSAGES/messages.po trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/et_EE.utf8/LC_MESSAGES/messages.mo trunk/locale/et_EE.utf8/LC_MESSAGES/messages.po trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.mo trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.mo trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.po trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.mo trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.po trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.mo trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.po trunk/locale/id_ID.utf8/LC_MESSAGES/messages.mo trunk/locale/id_ID.utf8/LC_MESSAGES/messages.po trunk/locale/it_IT.utf8/LC_MESSAGES/messages.mo trunk/locale/it_IT.utf8/LC_MESSAGES/messages.po trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.mo trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.po trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.mo trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.po trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.mo trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.po trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.mo trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.po trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.po trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.po trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.mo trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.po trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.mo trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.po trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.mo trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.po trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.mo trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.po trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.mo trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.po trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.mo trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.po trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.po trunk/sql/mysql/weberp-demo.sql trunk/sql/mysql/weberp-new.sql Modified: trunk/ConfirmDispatch_Invoice.php =================================================================== --- trunk/ConfirmDispatch_Invoice.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/ConfirmDispatch_Invoice.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -172,7 +172,7 @@ $myrow['controlled'], $myrow['serialised'], $myrow['decimalplaces'], - $myrow['narrative'], + htmlspecialchars_decode($myrow['narrative']), 'No', $myrow['orderlineno'], $myrow['taxcatid'], Modified: trunk/DeliveryDetails.php =================================================================== --- trunk/DeliveryDetails.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/DeliveryDetails.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -257,8 +257,8 @@ if(isset($_POST['MakeRecurringOrder']) AND ! $InputErrors){ - echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/RecurringSalesOrders.php?' . SID.'identifier='.$identifier . '&NewRecurringOrder=Yes">'; - prnMsg(_('You should automatically be forwarded to the entry of recurring order details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' ."<a href='" . $rootpath . '/RecurringOrders.php?' . SID.'identifier='.$identifier . "&NewRecurringOrder=Yes'>". _('click here') .'</a> '. _('to continue'),'info'); + echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/RecurringSalesOrders.php?identifier='.$identifier . '&NewRecurringOrder=Yes">'; + prnMsg(_('You should automatically be forwarded to the entry of recurring order details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' ."<a href='" . $rootpath . '/RecurringOrders.php?identifier='.$identifier . "&NewRecurringOrder=Yes'>". _('click here') .'</a> '. _('to continue'),'info'); include('includes/footer.inc'); exit; } @@ -266,8 +266,8 @@ if (isset($_POST['BackToLineDetails']) and $_POST['BackToLineDetails']==_('Modify Order Lines')){ - echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/SelectOrderItems.php?' . SID.'identifier='.$identifier . '">'; - prnMsg(_('You should automatically be forwarded to the entry of the order line details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' ."<a href='" . $rootpath . '/SelectOrderItems.php?' . SID.'identifier='.$identifier . "'>". _('click here') .'</a> '. _('to continue'),'info'); + echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/SelectOrderItems.php?identifier='.$identifier . '">'; + prnMsg(_('You should automatically be forwarded to the entry of the order line details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' .'<a href="' . $rootpath . '/SelectOrderItems.php?identifier='.$identifier . '">'. _('click here') .'</a> '. _('to continue'),'info'); include('includes/footer.inc'); exit; @@ -571,19 +571,19 @@ if ($_POST['Quotation']==0) { /*then its not a quotation its a real order */ - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder.php?' . SID .'identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Preprinted stationery') . ')' .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?' . SID .'identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder.php?identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Preprinted stationery') . ')' .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/ConfirmDispatch_Invoice.php?' . SID .'identifier='.$identifier . '&OrderNumber=' . $OrderNo .'">'. _('Confirm Dispatch and Produce Invoice') .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/ConfirmDispatch_Invoice.php?identifier='.$identifier . '&OrderNumber=' . $OrderNo .'">'. _('Confirm Dispatch and Produce Invoice') .'</a></td></tr>'; //Add option to Print Sales Orders or Proforma invoice - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/pdf.png" title="' . _('Sales Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PrintSalesOrder_generic.php?' . SID .'identifier='.$identifier . '&TransNo=' . $OrderNo .'">'. _('Print Sales Order / Pro-forma Invoice') .'</a></td></tr></table>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/pdf.png" title="' . _('Sales Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PrintSalesOrder_generic.php?identifier='.$identifier . '&TransNo=' . $OrderNo .'">'. _('Print Sales Order / Pro-forma Invoice') .'</a></td></tr></table>'; } else { /*link to print the quotation */ - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?' . SID .'identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation') .'</a></td></tr></table>'; } - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="'. $rootpath .'/SelectOrderItems.php?' . SID .'identifier='.$identifier . '&NewOrder=Yes">'. _('Add Another Sales Order') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="'. $rootpath .'/SelectOrderItems.php?identifier='.$identifier . '&NewOrder=Yes">'. _('Add Another Sales Order') .'</a></td></tr></table>'; } else { /*its a customer logon so thank them */ prnMsg(_('Thank you for your business'),'success'); @@ -747,10 +747,10 @@ prnMsg(_('Order Number') .' ' . $_SESSION['ExistingOrder'] . ' ' . _('has been updated'),'success'); - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a href="' . $rootpath . '/PrintCustOrder.php?' . SID.'identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip - pre-printed stationery') .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?' . SID.'identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td><a href="' . $rootpath .'/ConfirmDispatch_Invoice.php?' . SID.'identifier='.$identifier . '&OrderNumber=' . $_SESSION['ExistingOrder'] . '">'. _('Confirm Order Delivery Quantities and Produce Invoice') .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td><a href="' . $rootpath .'/SelectSalesOrder.php?' . SID.'identifier='.$identifier . '">'. _('Select A Different Order') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a href="' . $rootpath . '/PrintCustOrder.php?identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip - pre-printed stationery') .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td><a href="' . $rootpath .'/ConfirmDispatch_Invoice.php?identifier='.$identifier . '&OrderNumber=' . $_SESSION['ExistingOrder'] . '">'. _('Confirm Order Delivery Quantities and Produce Invoice') .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td><a href="' . $rootpath .'/SelectSalesOrder.php?identifier='.$identifier . '">'. _('Select A Different Order') .'</a></td></tr></table>'; include('includes/footer.inc'); exit; } @@ -763,7 +763,7 @@ echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/customer.png" title="' . _('Customer') . '" alt="" />' . ' ' . _('Customer Code') . ' :<b> ' . $_SESSION['Items'.$identifier]->DebtorNo; echo '</b> ' . _('Customer Name') . ' :<b> ' . $_SESSION['Items'.$identifier]->CustomerName . '</p>'; //echo '<font size=4><b>'. _('Customer') .' : ' . $_SESSION['Items'.$identifier]->CustomerName . '</b></font>'; -echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID.'identifier='.$identifier . '" method=post>'; +echo '<form action="' . $_SERVER['PHP_SELF'] . '?identifier='.$identifier . '" method=post>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; Modified: trunk/PrintCustTrans.php =================================================================== --- trunk/PrintCustTrans.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/PrintCustTrans.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -261,7 +261,7 @@ $LeftOvers = $pdf->addTextWrap($FormDesign->Data->Column6->x, $YPos,$FormDesign->Data->Column6->Length, $FormDesign->Data->Column6->FontSize, $DisplayDiscount, 'right'); $LeftOvers = $pdf->addTextWrap($FormDesign->Data->Column7->x, $YPos,$FormDesign->Data->Column7->Length, $FormDesign->Data->Column7->FontSize, $DisplayNet, 'right'); $YPos-= ($line_height); - $lines = explode('\r\n', $myrow2['narrative']); + $lines = explode('\r\n', htmlspecialchars_decode($myrow2['narrative'])); for ($i = 0;$i < sizeOf($lines);$i++) { while (strlen($lines[$i]) > 1) { if ($YPos - $line_height <= $Bottom_Margin) { Modified: trunk/PrintCustTransPortrait.php =================================================================== --- trunk/PrintCustTransPortrait.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/PrintCustTransPortrait.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -360,7 +360,7 @@ } $YPos -= ($FontSize*$lines); - $lines=explode('\r\n',$myrow2['narrative']); + $lines=explode('\r\n',htmlspecialchars_decode($myrow2['narrative'])); for ($i=0;$i<sizeOf($lines);$i++) { while (strlen($lines[$i])>1){ if ($YPos-$line_height <= $Bottom_Margin){ @@ -391,10 +391,8 @@ /* check to see enough space left to print the 4 lines for the totals/footer */ if (($YPos-$Bottom_Margin)<(2*$line_height)){ - PrintLinesToBottom (); include ('includes/PDFTransPageHeaderPortrait.inc'); - } /*Print a column vertical line with enough space for the footer*/ /*draw the vertical column lines to 4 lines shy of the bottom @@ -426,9 +424,7 @@ $DisplayFreight = number_format($myrow['ovfreight'],2); $DisplayTax = number_format($myrow['ovgst'],2); $DisplayTotal = number_format($myrow['ovfreight']+$myrow['ovgst']+$myrow['ovamount'],2); - } else { - $DisplaySubTot = number_format(-$myrow['ovamount'],2); $DisplayFreight = number_format(-$myrow['ovfreight'],2); $DisplayTax = number_format(-$myrow['ovgst'],2); Modified: trunk/SelectCustomer.php =================================================================== --- trunk/SelectCustomer.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/SelectCustomer.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -316,7 +316,9 @@ } echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID . '" method=post>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; -prnMsg($msg,'info'); +if (strlen($msg)>1){ + prnMsg($msg,'info'); +} echo '<p class="page_title_text"><img src="' . $rootpath . '/css/' . $theme . '/images/magnifier.png" title="' . _('Search') . '" alt="" />' . ' ' . _('Search for Customers').'</p>'; echo "<table cellpadding=3 colspan=4 class=selection>"; echo "<tr><td colspan=2>" . _('Enter a partial Name') . ":</td><td>"; Modified: trunk/SelectOrderItems.php =================================================================== --- trunk/SelectOrderItems.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/SelectOrderItems.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -35,7 +35,8 @@ } -if (empty($_GET['identifier'])) { +if (empty($_GET['identifier'])) { + /*unique session identifier to ensure that there is no conflict with other order entry sessions on the same machine */ $identifier=date('U'); } else { $identifier=$_GET['identifier']; @@ -1365,7 +1366,7 @@ echo '<td><input type=text class="date" alt="'.$_SESSION['DefaultDateFormat'].'" name="ItemDue_' . $OrderLine->LineNumber . '" size=10 maxlength=10 value=' . $LineDueDate . '></td>'; - echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?' . SID .'identifier='.$identifier . '&Delete=' . $OrderLine->LineNumber . '" onclick="return confirm(\'' . _('Are You Sure?') . '\');">' . $RemTxt . '</a></td></tr>'; + echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&Delete=' . $OrderLine->LineNumber . '" onclick="return confirm(\'' . _('Are You Sure?') . '\');">' . $RemTxt . '</a></td></tr>'; if ($_SESSION['AllowOrderLineItemNarrative'] == 1){ echo $RowStarter; Modified: trunk/UpgradeDatabase.php =================================================================== --- trunk/UpgradeDatabase.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/UpgradeDatabase.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -32,7 +32,7 @@ echo '<option value="3.11">' . _('Version 3.11 or 4.01 - 4.02') . '</option>'; echo '</select></td></tr></table>'; } else { - if ($_SESSION['VersionNumber']=='4.00-RC1'){ + if ($_SESSION['VersionNumber']=='4.00RC1'){ $_SESSION['VersionNumber']='3.12'; } prnMsg(_('The webERP code is version') . ' ' . $Version . ' ' . _('and the database version is') . ' ' . $_SESSION['VersionNumber'],'info'); @@ -97,7 +97,7 @@ $SQLScripts[] = './sql/mysql/upgrade3.11.1-4.00.sql'; break; } //end switch - if(isset($_SESSION['VersionNumber']) AND $_SESSION['VersionNumber']< '4.00') { /* VersionNumber is set to '4.00' when upgrade3.11.1-4.00.sql is run */ + if(isset($_SESSION['VersionNumber']) AND $_SESSION['VersionNumber']< '4.03') { /* VersionNumber is set to '4.03' when upgrade3.11.1-4.00.sql is run */ $SQLScripts[] = './sql/mysql/upgrade3.11.1-4.00.sql'; } } Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/doc/Change.log.html 2011-02-15 06:31:08 UTC (rev 4491) @@ -1,5 +1,11 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p <p /> +<p>15/2/11 Release 4.03RC2</p> +<p /> +<p>15/2/11: Phil UpgradeDatabase.php fix to upgrade from 4.01RC1 !!</p> +<p>15/2/11: Phil PrintCustTrans.php and PrintCustTransPortrait.php htmlspecialchars_decode($narrative) - conversion at the time of committing to DB needs to be unconverted. Also in ConfirmDispatch_Invoice.php</p> +<p>15/2/11: Phil SelectCustomer.php removed showing blank message when $msg was empty </p> +<p /> <p>13/2/11 Release 4.03RC1</p> <p /> <p>13/2/11:Phil GoodsReceivedControlled InputSerialItems and friends - now uses session identifier to ensure uniqueness is several people entering stock receipts</p> Modified: trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po 2011-02-15 06:31:08 UTC (rev 4491) @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: webERP 3.08\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-02-13 17:03+1300\n" +"POT-Creation-Date: 2011-02-15 18:44+1200\n" "PO-Revision-Date: 2010-07-25 17:04+0000\n" "Last-Translator: Tim Schofield <ti...@we...>\n" "Language-Team: Czech <cs...@li...>\n" @@ -219,9 +219,9 @@ #: SalesCategories.php:13 SalesGLPostings.php:18 SalesGraph.php:34 #: SalesPeople.php:22 SalesTypes.php:22 SelectAsset.php:44 #: SelectCompletedOrder.php:13 SelectContract.php:81 SelectCreditItems.php:204 -#: SelectCreditItems.php:272 SelectCustomer.php:320 SelectGLAccount.php:19 -#: SelectGLAccount.php:79 SelectOrderItems.php:606 SelectOrderItems.php:1430 -#: SelectOrderItems.php:1554 SelectProduct.php:456 SelectSalesOrder.php:155 +#: SelectCreditItems.php:272 SelectCustomer.php:322 SelectGLAccount.php:19 +#: SelectGLAccount.php:79 SelectOrderItems.php:607 SelectOrderItems.php:1431 +#: SelectOrderItems.php:1555 SelectProduct.php:456 SelectSalesOrder.php:155 #: SelectSupplier.php:9 SelectSupplier.php:198 SelectWorkOrder.php:11 #: SelectWorkOrder.php:147 ShipmentCosting.php:13 Shipments.php:18 #: Shippers.php:123 Shippers.php:159 Shipt_Select.php:10 @@ -342,9 +342,9 @@ #: PcTypeTabs.php:171 PO_AuthorisationLevels.php:148 Prices_Customer.php:283 #: Prices.php:227 PurchData.php:207 SalesCategories.php:263 #: SalesGLPostings.php:135 SalesGLPostings.php:247 SalesPeople.php:210 -#: SalesTypes.php:206 SelectCustomer.php:607 SelectCustomer.php:623 -#: SelectCustomer.php:645 SelectCustomer.php:661 SelectCustomer.php:683 -#: SelectCustomer.php:699 Shippers.php:144 StockCategories.php:244 +#: SalesTypes.php:206 SelectCustomer.php:609 SelectCustomer.php:625 +#: SelectCustomer.php:647 SelectCustomer.php:663 SelectCustomer.php:685 +#: SelectCustomer.php:701 Shippers.php:144 StockCategories.php:244 #: SupplierContacts.php:153 SupplierTypes.php:192 SuppLoginSetup.php:274 #: TaxAuthorities.php:173 TaxCategories.php:184 TaxGroups.php:179 #: TaxProvinces.php:178 UnitsOfMeasure.php:201 WorkCentres.php:138 @@ -370,9 +370,9 @@ #: PO_Items.php:758 Prices_Customer.php:284 Prices.php:228 PurchData.php:208 #: SalesAnalReptCols.php:294 SalesAnalRepts.php:305 SalesCategories.php:264 #: SalesGLPostings.php:136 SalesGLPostings.php:248 SalesPeople.php:211 -#: SalesTypes.php:207 SelectCreditItems.php:747 SelectCustomer.php:608 -#: SelectCustomer.php:624 SelectCustomer.php:646 SelectCustomer.php:662 -#: SelectCustomer.php:684 SelectCustomer.php:700 SelectOrderItems.php:1357 +#: SalesTypes.php:207 SelectCreditItems.php:747 SelectCustomer.php:610 +#: SelectCustomer.php:626 SelectCustomer.php:648 SelectCustomer.php:664 +#: SelectCustomer.php:686 SelectCustomer.php:702 SelectOrderItems.php:1358 #: Shipments.php:424 Shippers.php:145 SpecialOrder.php:590 #: StockCategories.php:245 StockCategories.php:539 SuppContractChgs.php:91 #: SuppCreditGRNs.php:93 SuppFixedAssetChgs.php:81 SuppInvGRNs.php:135 @@ -500,8 +500,8 @@ msgid "Could not retrieve the requested section please try again." msgstr "Nepodařilo se získat požadovanou sekci prosím zkuste to znovu." -#: AddCustomerContacts.php:6 AddCustomerContacts.php:59 SelectCustomer.php:601 -#: SelectCustomer.php:630 +#: AddCustomerContacts.php:6 AddCustomerContacts.php:59 SelectCustomer.php:603 +#: SelectCustomer.php:632 msgid "Customer Contacts" msgstr "Zákazník Kontakty" @@ -550,7 +550,7 @@ #: AddCustomerContacts.php:112 CompanyPreferences.php:229 #: CustomerBranches.php:377 Customers.php:899 Customers.php:905 -#: Customers.php:971 SalesPeople.php:185 SelectCustomer.php:603 +#: Customers.php:971 SalesPeople.php:185 SelectCustomer.php:605 #: StockDispatch.php:186 StockDispatch.php:198 SupplierContacts.php:141 #: SupplierCredit.php:433 SupplierInvoice.php:408 SuppTransGLAnalysis.php:96 #: includes/InputSerialItemsFile.php:84 includes/InputSerialItemsFile.php:124 @@ -559,7 +559,7 @@ msgstr "Název" #: AddCustomerContacts.php:113 AddCustomerContacts.php:190 Customers.php:900 -#: Customers.php:906 Customers.php:972 SelectCustomer.php:604 +#: Customers.php:906 Customers.php:972 SelectCustomer.php:606 #: WWW_Access.php:111 WWW_Access.php:172 msgid "Role" msgstr "Roli" @@ -572,7 +572,7 @@ #: Customers.php:908 Customers.php:974 PcAssignCashToTab.php:216 #: PcAssignCashToTab.php:341 PcAuthorizeExpenses.php:85 #: PcClaimExpensesFromTab.php:195 PcClaimExpensesFromTab.php:348 -#: PcReportTab.php:348 SelectCustomer.php:606 SystemParameters.php:316 +#: PcReportTab.php:348 SelectCustomer.php:608 SystemParameters.php:316 #: WOSerialNos.php:277 WOSerialNos.php:279 msgid "Notes" msgstr "Bere na vědomí" @@ -591,14 +591,14 @@ #: AddCustomerContacts.php:196 Contracts.php:777 PDFRemittanceAdvice.php:247 #: PO_Header.php:958 PO_Header.php:1028 SelectCreditItems.php:225 -#: SelectCustomer.php:461 SelectOrderItems.php:638 +#: SelectCustomer.php:463 SelectOrderItems.php:639 #: includes/PDFStatementPageHeader.inc:63 includes/PDFTransPageHeader.inc:117 #: includes/PDFTransPageHeaderPortrait.inc:105 msgid "Phone" msgstr "Telefon" -#: AddCustomerNotes.php:6 AddCustomerNotes.php:49 SelectCustomer.php:638 -#: SelectCustomer.php:668 +#: AddCustomerNotes.php:6 AddCustomerNotes.php:49 SelectCustomer.php:640 +#: SelectCustomer.php:670 msgid "Customer Notes" msgstr "Zákazník bere na vědomí" @@ -639,7 +639,7 @@ #: GLAccountReport.php:369 GLTransInquiry.php:45 MRPCalendar.php:217 #: PaymentAllocations.php:77 PcAssignCashToTab.php:212 #: PcAuthorizeExpenses.php:81 PDFRemittanceAdvice.php:308 -#: PrintCustTrans.php:616 PrintCustTransPortrait.php:794 ReverseGRN.php:378 +#: PrintCustTrans.php:616 PrintCustTransPortrait.php:790 ReverseGRN.php:378 #: ShipmentCosting.php:503 ShipmentCosting.php:574 Shipments.php:467 #: StockDispatch.php:188 StockDispatch.php:200 StockLocMovements.php:85 #: StockMovements.php:98 StockSerialItemResearch.php:79 @@ -685,7 +685,7 @@ msgid "Contact Note" msgstr "Kontakt Poznámka:" -#: AddCustomerTypeNotes.php:6 SelectCustomer.php:676 +#: AddCustomerTypeNotes.php:6 SelectCustomer.php:678 msgid "Customer Type (Group) Notes" msgstr "Typ zákazníka (Group) Poznámky" @@ -693,7 +693,7 @@ msgid "The Contact priority must be an integer." msgstr "Prioritou Kontakt musí být celé číslo." -#: AddCustomerTypeNotes.php:49 SelectCustomer.php:706 +#: AddCustomerTypeNotes.php:49 SelectCustomer.php:708 msgid "Customer Group Notes" msgstr "Zákaznická skupina bere na vědomí" @@ -917,7 +917,7 @@ #: OutstandingGRNs.php:185 PDFCustomerList.php:412 PDFLowGP.php:168 #: PDFPriceList.php:301 PDFRemittanceAdvice.php:152 #: PDFStockCheckComparison.php:379 PrintCustTrans.php:416 -#: PrintCustTransPortrait.php:564 ReorderLevel.php:229 StockDispatch.php:309 +#: PrintCustTransPortrait.php:560 ReorderLevel.php:229 StockDispatch.php:309 #: SupplierBalsAtPeriodEnd.php:155 SuppPriceList.php:237 Tax.php:352 msgid "Print PDF" msgstr "Tisknout PDF" @@ -1108,7 +1108,7 @@ #: CustomerTransInquiry.php:21 CustomerTransInquiry.php:85 #: CustWhereAlloc.php:18 CustWhereAlloc.php:87 DailyBankTransactions.php:98 #: GLAccountInquiry.php:152 GLAccountReport.php:367 GLJournal.php:256 -#: MRPReschedules.php:204 SelectCustomer.php:460 ShipmentCosting.php:501 +#: MRPReschedules.php:204 SelectCustomer.php:462 ShipmentCosting.php:501 #: ShipmentCosting.php:572 StockCategories.php:219 StockLocMovements.php:83 #: StockMovements.php:97 SupplierAllocations.php:462 SupplierInquiry.php:193 #: SupplierTransInquiry.php:19 SupplierTransInquiry.php:86 @@ -1599,8 +1599,8 @@ #: CustomerInquiry.php:190 CustomerTransInquiry.php:86 CustWhereAlloc.php:88 #: EmailCustTrans.php:17 GLAccountInquiry.php:153 PrintCustTrans.php:378 #: PrintCustTrans.php:542 PrintCustTrans.php:696 PrintCustTrans.php:735 -#: PrintCustTransPortrait.php:508 PrintCustTransPortrait.php:708 -#: PrintCustTransPortrait.php:898 PrintCustTransPortrait.php:943 +#: PrintCustTransPortrait.php:504 PrintCustTransPortrait.php:704 +#: PrintCustTransPortrait.php:894 PrintCustTransPortrait.php:939 #: StockMovements.php:97 SupplierAllocations.php:463 #: SupplierAllocations.php:575 SupplierAllocations.php:645 #: SupplierTransInquiry.php:87 Z_CheckAllocs.php:60 @@ -1669,7 +1669,7 @@ "měny bankovního účtu" #: BankReconciliation.php:311 CounterSales.php:781 Customers.php:1014 -#: SelectOrderItems.php:1368 Stocks.php:1033 WorkOrderCosting.php:512 +#: SelectOrderItems.php:1369 Stocks.php:1033 WorkOrderCosting.php:512 #: WorkOrderEntry.php:549 msgid "Are You Sure?" msgstr "Opravdu provést?" @@ -1747,14 +1747,14 @@ #: OffersReceived.php:196 OffersReceived.php:245 OrderDetails.php:155 #: PDFOrdersInvoiced.php:387 POReport.php:699 POReport.php:1365 #: PrintCustTrans.php:650 PrintCustTrans.php:713 PrintCustTrans.php:751 -#: PrintCustTransPortrait.php:833 PrintCustTransPortrait.php:916 -#: PrintCustTransPortrait.php:960 RecurringSalesOrders.php:322 +#: PrintCustTransPortrait.php:829 PrintCustTransPortrait.php:912 +#: PrintCustTransPortrait.php:956 RecurringSalesOrders.php:322 #: ReorderLevel.php:268 ReverseGRN.php:379 ReverseGRN.php:380 #: SalesAnalReptCols.php:18 SalesAnalReptCols.php:20 SalesGraph.php:177 #: SalesGraph.php:258 SalesInquiry.php:974 SelectCreditItems.php:653 -#: SelectCreditItems.php:1004 SelectOrderItems.php:1292 -#: SelectOrderItems.php:1441 SelectOrderItems.php:1625 -#: SelectOrderItems.php:1753 ShipmentCosting.php:140 ShipmentCosting.php:141 +#: SelectCreditItems.php:1004 SelectOrderItems.php:1293 +#: SelectOrderItems.php:1442 SelectOrderItems.php:1626 +#: SelectOrderItems.php:1754 ShipmentCosting.php:140 ShipmentCosting.php:141 #: Shipments.php:386 Shipments.php:388 Shipments.php:389 Shipments.php:464 #: Shipments.php:466 SpecialOrder.php:551 StockCounts.php:98 #: StockLocMovements.php:87 StockLocTransfer.php:181 StockMovements.php:99 @@ -1854,8 +1854,8 @@ #: MRPReport.php:827 MRPReschedules.php:191 MRPShortages.php:287 #: PDFPriceList.php:331 PDFReceipt.php:32 PDFRemittanceAdvice.php:218 #: PrintCustTrans.php:560 PrintCustTrans.php:709 PrintCustTrans.php:747 -#: PrintCustTransPortrait.php:730 PrintCustTransPortrait.php:912 -#: PrintCustTransPortrait.php:956 ReorderLevel.php:252 StockDispatch.php:338 +#: PrintCustTransPortrait.php:726 PrintCustTransPortrait.php:908 +#: PrintCustTransPortrait.php:952 ReorderLevel.php:252 StockDispatch.php:338 #: SuppPriceList.php:264 Tax.php:252 includes/PDFAgedDebtorsPageHeader.inc:34 #: includes/PDFAgedSuppliersPageHeader.inc:21 #: includes/PDFBalanceSheetPageHeader.inc:26 @@ -1913,7 +1913,7 @@ #: CounterSales.php:2170 PO_SelectOSPurchOrder.php:214 #: PO_SelectPurchOrder.php:174 ReorderLevelLocation.php:58 #: ReorderLevelLocation.php:59 SelectCompletedOrder.php:468 -#: SelectOrderItems.php:1437 SelectOrderItems.php:1621 +#: SelectOrderItems.php:1438 SelectOrderItems.php:1622 #: SelectSalesOrder.php:197 SelectWorkOrder.php:186 Shipt_Select.php:185 #: TopItems.php:165 includes/PDFTopItemsHeader.inc:59 msgid "On Hand" @@ -2002,8 +2002,8 @@ #: PricesByCost.php:108 ReorderLevelLocation.php:55 ReorderLevel.php:266 #: ReverseGRN.php:377 SalesCategories.php:427 SelectAsset.php:224 #: SelectCompletedOrder.php:467 SelectContract.php:156 -#: SelectCreditItems.php:958 SelectOrderItems.php:1435 -#: SelectOrderItems.php:1619 SelectProduct.php:476 SelectProduct.php:681 +#: SelectCreditItems.php:958 SelectOrderItems.php:1436 +#: SelectOrderItems.php:1620 SelectProduct.php:476 SelectProduct.php:681 #: SelectSalesOrder.php:196 SelectWorkOrder.php:185 Shipt_Select.php:184 #: StockCategories.php:218 StockDispatch.php:357 StockDispatch.php:364 #: StockLocStatus.php:149 StockQuantityByDate.php:92 SuppCreditGRNs.php:75 @@ -2106,10 +2106,10 @@ #: MRPReport.php:563 PO_Header.php:516 PO_Items.php:1015 PO_Items.php:1020 #: PO_SelectOSPurchOrder.php:202 PO_SelectPurchOrder.php:165 PurchData.php:264 #: SelectAsset.php:93 SelectCompletedOrder.php:450 SelectCreditItems.php:210 -#: SelectCreditItems.php:944 SelectCustomer.php:328 SelectCustomer.php:334 -#: SelectCustomer.php:341 SelectCustomer.php:349 SelectCustomer.php:393 -#: SelectGLAccount.php:92 SelectOrderItems.php:618 SelectOrderItems.php:621 -#: SelectOrderItems.php:1588 SelectProduct.php:483 SelectSalesOrder.php:184 +#: SelectCreditItems.php:944 SelectCustomer.php:330 SelectCustomer.php:336 +#: SelectCustomer.php:343 SelectCustomer.php:351 SelectCustomer.php:395 +#: SelectGLAccount.php:92 SelectOrderItems.php:619 SelectOrderItems.php:622 +#: SelectOrderItems.php:1589 SelectProduct.php:483 SelectSalesOrder.php:184 #: SelectSupplier.php:206 SelectWorkOrder.php:173 Shipt_Select.php:170 #: SuppFixedAssetChgs.php:113 SupplierTenders.php:358 WorkOrderEntry.php:583 #: WorkOrderIssue.php:638 @@ -2138,8 +2138,8 @@ #: CounterSales.php:2142 CustomerReceipt.php:1037 FixedAssetTransfer.php:72 #: MRPDemands.php:335 MRPReport.php:571 PO_Header.php:521 PO_Items.php:1023 #: SelectAsset.php:101 SelectCreditItems.php:215 SelectCreditItems.php:949 -#: SelectCustomer.php:416 SelectGLAccount.php:98 SelectOrderItems.php:626 -#: SelectOrderItems.php:1595 SelectProduct.php:491 SelectSupplier.php:212 +#: SelectCustomer.php:418 SelectGLAccount.php:98 SelectOrderItems.php:627 +#: SelectOrderItems.php:1596 SelectProduct.php:491 SelectSupplier.php:212 #: SelectSupplier.php:245 SupplierTenders.php:366 WorkOrderEntry.php:587 #: WorkOrderIssue.php:642 msgid "Search Now" @@ -2180,8 +2180,8 @@ #: PricesByCost.php:107 PurchData.php:338 ReorderLevelLocation.php:54 #: ReorderLevelLocation.php:203 SalesPeople.php:184 #: SelectCompletedOrder.php:466 SelectCreditItems.php:222 -#: SelectCreditItems.php:957 SelectCustomer.php:456 SelectGLAccount.php:105 -#: SelectOrderItems.php:1434 SelectOrderItems.php:1618 SelectProduct.php:680 +#: SelectCreditItems.php:957 SelectCustomer.php:458 SelectGLAccount.php:105 +#: SelectOrderItems.php:1435 SelectOrderItems.php:1619 SelectProduct.php:680 #: SelectSalesOrder.php:195 SelectSupplier.php:249 SelectWorkOrder.php:184 #: Shipt_Select.php:183 SpecialOrder.php:134 SupplierTenders.php:488 #: SuppPriceList.php:281 TopItems.php:160 WorkOrderEntry.php:598 @@ -2196,7 +2196,7 @@ #: MRPReport.php:762 OffersReceived.php:95 PO_Items.php:1038 #: PO_SelectOSPurchOrder.php:216 PO_SelectPurchOrder.php:176 #: SelectCompletedOrder.php:471 SelectCreditItems.php:959 -#: SelectOrderItems.php:1436 SelectOrderItems.php:1620 SelectProduct.php:108 +#: SelectOrderItems.php:1437 SelectOrderItems.php:1621 SelectProduct.php:108 #: SelectProduct.php:683 SelectSalesOrder.php:198 SelectWorkOrder.php:187 #: Shipments.php:387 Shipments.php:465 Shipt_Select.php:187 #: StockLocTransferReceive.php:435 SupplierTenders.php:490 TopItems.php:163 @@ -2645,7 +2645,7 @@ #: Customers.php:738 Customers.php:741 DiscountMatrix.php:98 #: DiscountMatrix.php:157 PricesByCost.php:216 Prices.php:199 #: SalesAnalRepts.php:34 SalesAnalRepts.php:36 SalesGLPostings.php:115 -#: SalesGLPostings.php:226 SalesGLPostings.php:354 SelectOrderItems.php:744 +#: SalesGLPostings.php:226 SalesGLPostings.php:354 SelectOrderItems.php:745 #: api/api_xml-rpc.php:931 api/api_xml-rpc.php:974 msgid "Sales Type" msgstr "Prodej Typ" @@ -2672,7 +2672,7 @@ #: COGSGLPostings.php:307 Customers.php:741 EDIProcessOrders.php:389 #: PDFCustomerList.php:334 PDFPriceList.php:17 PDFPriceList.php:121 #: PDFPriceList.php:251 PricesBasedOnMarkUp.php:223 PricesByCost.php:216 -#: SalesGLPostings.php:354 SelectOrderItems.php:744 SuppPriceList.php:118 +#: SalesGLPostings.php:354 SelectOrderItems.php:745 SuppPriceList.php:118 #: SuppPriceList.php:231 msgid "Price List" msgstr "Ceník" @@ -2961,7 +2961,7 @@ "první z obrazovky dodání podrobnosti klikněte na Potvrdit pro fakturaci" #: ConfirmDispatch_Invoice.php:75 OrderDetails.php:53 -#: RecurringSalesOrders.php:68 SelectOrderItems.php:126 +#: RecurringSalesOrders.php:68 SelectOrderItems.php:127 #: includes/PO_ReadInOrder.inc:58 msgid "The order cannot be retrieved because" msgstr "Aby nemůže získat, protože" @@ -2971,7 +2971,7 @@ msgstr "SQL získat pořadí záhlaví byl" #: ConfirmDispatch_Invoice.php:151 Credit_Invoice.php:127 OrderDetails.php:140 -#: RecurringSalesOrders.php:126 SelectOrderItems.php:216 +#: RecurringSalesOrders.php:126 SelectOrderItems.php:217 msgid "The line items of the order cannot be retrieved because" msgstr "Řádkové položky v řádu nelze načíst, protože" @@ -3003,7 +3003,7 @@ #: DeliveryDetails.php:763 FTP_RadioBeacon.php:52 PDFOrdersInvoiced.php:302 #: PDFOrderStatus.php:269 PricesByCost.php:109 SalesGraph.php:169 #: SelectCompletedOrder.php:517 SelectContract.php:157 SelectCustomer.php:23 -#: SelectCustomer.php:280 SelectOrderItems.php:635 +#: SelectCustomer.php:280 SelectOrderItems.php:636 #: SelectRecurringSalesOrder.php:79 SelectSalesOrder.php:421 #: SelectSalesOrder.php:432 StockLocMovements.php:86 StockMovements.php:98 #: includes/PDFAgedDebtorsPageHeader.inc:48 @@ -3034,7 +3034,7 @@ #: SalesInquiry.php:758 SalesInquiry.php:782 SalesInquiry.php:926 #: SalesInquiry.php:937 SalesInquiry.php:943 SalesInquiry.php:949 #: SalesInquiry.php:1088 SalesInquiry.php:1142 SalesInquiry.php:1158 -#: SelectCustomer.php:457 SelectOrderItems.php:741 +#: SelectCustomer.php:459 SelectOrderItems.php:742 msgid "Customer Name" msgstr "Název zákazníka" @@ -3047,10 +3047,10 @@ #: CounterSales.php:2301 Credit_Invoice.php:271 DeliveryDetails.php:783 #: GoodsReceived.php:89 OrderDetails.php:153 PO_Items.php:708 #: PO_OrderDetails.php:142 PrintCustTrans.php:648 PrintCustTrans.php:711 -#: PrintCustTrans.php:749 PrintCustTransPortrait.php:831 -#: PrintCustTransPortrait.php:914 PrintCustTransPortrait.php:958 +#: PrintCustTrans.php:749 PrintCustTransPortrait.php:827 +#: PrintCustTransPortrait.php:910 PrintCustTransPortrait.php:954 #: RecurringSalesOrders.php:320 ReverseGRN.php:376 SalesGraph.php:170 -#: SelectCreditItems.php:651 SelectOrderItems.php:1290 StockCostUpdate.php:124 +#: SelectCreditItems.php:651 SelectOrderItems.php:1291 StockCostUpdate.php:124 #: StockLocMovements.php:82 StockLocTransfer.php:181 #: StockLocTransferReceive.php:430 StockQuantityByDate.php:91 Stocks.php:584 #: Stocks.php:586 Stocks.php:636 Stocks.php:640 SuppCreditGRNs.php:74 @@ -3071,9 +3071,9 @@ #: Credit_Invoice.php:272 DeliveryDetails.php:784 DeliveryDetails.php:849 #: OrderDetails.php:154 PO_Items.php:776 PO_OrderDetails.php:143 #: PrintCustTrans.php:649 PrintCustTrans.php:712 PrintCustTrans.php:750 -#: PrintCustTransPortrait.php:832 PrintCustTransPortrait.php:915 -#: PrintCustTransPortrait.php:959 RecurringSalesOrders.php:321 -#: SelectCreditItems.php:652 SelectOrderItems.php:1291 SpecialOrder.php:549 +#: PrintCustTransPortrait.php:828 PrintCustTransPortrait.php:911 +#: PrintCustTransPortrait.php:955 RecurringSalesOrders.php:321 +#: SelectCreditItems.php:652 SelectOrderItems.php:1292 SpecialOrder.php:549 #: StockLocTransferReceive.php:431 includes/PDFOrderPageHeader_generic.inc:92 #: includes/PDFPickingListHeader.inc:73 #: includes/PDFQuotationPageHeader.inc:101 @@ -3111,10 +3111,10 @@ #: PDFPrintLabel.php:239 PO_AuthoriseMyOrders.php:108 PricesByCost.php:201 #: Prices_Customer.php:367 Prices.php:200 Prices.php:339 #: PrintCustTrans.php:652 PrintCustTrans.php:715 PrintCustTrans.php:753 -#: PrintCustTransPortrait.php:835 PrintCustTransPortrait.php:918 -#: PrintCustTransPortrait.php:962 PurchData.php:168 PurchData.php:455 +#: PrintCustTransPortrait.php:831 PrintCustTransPortrait.php:914 +#: PrintCustTransPortrait.php:958 PurchData.php:168 PurchData.php:455 #: RecurringSalesOrders.php:324 SelectCreditItems.php:655 -#: SelectOrderItems.php:1295 Shipments.php:390 StockLocMovements.php:89 +#: SelectOrderItems.php:1296 Shipments.php:390 StockLocMovements.php:89 #: StockMovements.php:100 StockStatus.php:310 SuppCreditGRNs.php:227 #: SuppCreditGRNs.php:228 SupplierTenders.php:268 SupplierTenders.php:493 #: SuppPriceList.php:283 includes/DefineLabelClass.php:49 @@ -3127,10 +3127,10 @@ #: ConfirmDispatch_Invoice.php:269 CounterSales.php:705 Credit_Invoice.php:277 #: CustomerReceipt.php:846 DeliveryDetails.php:788 OrderDetails.php:158 #: PrintCustTrans.php:653 PrintCustTrans.php:716 PrintCustTrans.php:754 -#: PrintCustTransPortrait.php:836 PrintCustTransPortrait.php:919 -#: PrintCustTransPortrait.php:963 RecurringSalesOrders.php:325 +#: PrintCustTransPortrait.php:832 PrintCustTransPortrait.php:915 +#: PrintCustTransPortrait.php:959 RecurringSalesOrders.php:325 #: SalesAnalReptCols.php:43 SalesAnalReptCols.php:45 SelectCreditItems.php:657 -#: SelectOrderItems.php:1298 StockLocMovements.php:90 StockMovements.php:101 +#: SelectOrderItems.php:1299 StockLocMovements.php:90 StockMovements.php:101 #: StockStatus.php:311 includes/PDFQuotationPageHeader.inc:104 #: includes/PDFTransPageHeader.inc:206 msgid "Discount" @@ -3149,7 +3149,7 @@ #: OrderDetails.php:159 PDFCustTransListing.php:127 PDFOrdersInvoiced.php:389 #: PDFRemittanceAdvice.php:310 PDFSuppTransListing.php:127 #: RecurringSalesOrders.php:326 SelectCreditItems.php:658 -#: SelectCreditItems.php:662 SelectOrderItems.php:1301 SuppContractChgs.php:98 +#: SelectCreditItems.php:662 SelectOrderItems.php:1302 SuppContractChgs.php:98 #: SuppFixedAssetChgs.php:88 SupplierAllocations.php:466 #: SupplierAllocations.php:577 SupplierAllocations.php:647 #: SupplierCredit.php:389 SupplierCredit.php:421 SupplierCredit.php:456 @@ -3178,7 +3178,7 @@ #: ConfirmDispatch_Invoice.php:273 CounterSales.php:708 Credit_Invoice.php:280 #: Credit_Invoice.php:281 PrintCustTrans.php:335 PrintCustTrans.php:783 -#: PrintCustTransPortrait.php:456 PrintCustTransPortrait.php:999 +#: PrintCustTransPortrait.php:452 PrintCustTransPortrait.php:995 #: SelectCreditItems.php:660 SelectCreditItems.php:661 #: includes/PDFTaxPageHeader.inc:40 msgid "Tax" @@ -3721,7 +3721,7 @@ #: DeliveryDetails.php:586 DeliveryDetails.php:753 MRPReport.php:412 #: PDFOrdersInvoiced.php:301 PDFOrderStatus.php:268 #: SelectCompletedOrder.php:516 SelectContract.php:152 -#: SelectOrderItems.php:733 SelectProduct.php:356 Shipments.php:384 +#: SelectOrderItems.php:734 SelectProduct.php:356 Shipments.php:384 #: Shipments.php:462 SuppCreditGRNs.php:149 SuppCreditGRNs.php:227 #: SuppInvGRNs.php:278 TaxGroups.php:271 #: includes/PDFDeliveryDifferencesPageHeader.inc:41 @@ -3994,7 +3994,7 @@ #: PO_SelectOSPurchOrder.php:451 PO_SelectOSPurchOrder.php:479 #: PrintCustStatements.php:89 PrintCustStatements.php:431 #: PrintCustTrans.php:394 PrintCustTrans.php:415 -#: PrintCustTransPortrait.php:531 SelectSalesOrder.php:471 +#: PrintCustTransPortrait.php:527 SelectSalesOrder.php:471 msgid "Print" msgstr "Tisk" @@ -4065,7 +4065,7 @@ #: Contracts.php:97 DeliveryDetails.php:261 DeliveryDetails.php:270 #: EmailCustTrans.php:24 EmailCustTrans.php:28 GLAccountCSV.php:263 #: PO_Header.php:237 POReport.php:1404 SalesAnalysis_UserDefined.php:46 -#: SelectOrderItems.php:1145 StockQties_csv.php:46 StockUsage.php:24 +#: SelectOrderItems.php:1146 StockQties_csv.php:46 StockUsage.php:24 #: SupplierCredit.php:216 SupplierCredit.php:228 SupplierCredit.php:240 #: SupplierCredit.php:249 SupplierCredit.php:257 SupplierInvoice.php:193 #: SupplierInvoice.php:201 SupplierInvoice.php:209 SupplierInvoice.php:217 @@ -4077,7 +4077,7 @@ #: ContractBOM.php:43 ContractOtherReqts.php:45 Contracts.php:88 #: Contracts.php:97 DeliveryDetails.php:261 DeliveryDetails.php:270 #: PO_Header.php:237 SalesAnalysis_UserDefined.php:46 -#: SelectOrderItems.php:1145 StockUsage.php:24 SupplierCredit.php:216 +#: SelectOrderItems.php:1146 StockUsage.php:24 SupplierCredit.php:216 #: SupplierCredit.php:228 SupplierCredit.php:240 SupplierCredit.php:249 #: SupplierCredit.php:257 SupplierInvoice.php:193 SupplierInvoice.php:201 #: SupplierInvoice.php:209 SupplierInvoice.php:217 SupplierInvoice.php:225 @@ -4086,7 +4086,7 @@ msgstr "pro pokračování" #: ContractBOM.php:143 CounterSales.php:330 PO_Items.php:960 -#: SelectCreditItems.php:370 SelectOrderItems.php:855 SupplierTenders.php:469 +#: SelectCreditItems.php:370 SelectOrderItems.php:856 SupplierTenders.php:469 #: WorkOrderEntry.php:153 WorkOrderIssue.php:469 msgid "There is a problem selecting the part records to display because" msgstr "To je problém výběru část záznamy k zobrazení, protože" @@ -4132,7 +4132,7 @@ msgstr "SQL používá k načtení položky detaily, ale nepodařilo se" #: ContractBOM.php:213 CounterSales.php:425 PO_Items.php:679 -#: SelectOrderItems.php:949 includes/SelectOrderItems_IntoCart.inc:58 +#: SelectOrderItems.php:950 includes/SelectOrderItems_IntoCart.inc:58 #: includes/SelectOrderItems_IntoCart.inc:162 msgid "The item code" msgstr "Položku kód" @@ -4191,8 +4191,8 @@ #: ReorderLevel.php:217 ReorderLevel.php:219 SalesGraph.php:91 #: SalesGraph.php:93 SalesGraph.php:111 SalesGraph.php:113 SalesGraph.php:134 #: SalesGraph.php:136 SalesGraph.php:168 SalesInquiry.php:1060 -#: SalesInquiry.php:1103 SelectCreditItems.php:925 SelectOrderItems.php:1560 -#: SelectOrderItems.php:1563 SelectProduct.php:464 SelectProduct.php:466 +#: SalesInquiry.php:1103 SelectCreditItems.php:925 SelectOrderItems.php:1561 +#: SelectOrderItems.php:1564 SelectProduct.php:464 SelectProduct.php:466 #: StockDispatch.php:283 StockDispatch.php:285 StockLocStatus.php:62 #: StockLocStatus.php:64 StockLocStatus.php:82 StockLocStatus.php:86 #: StockLocStatus.php:90 SupplierTenders.php:337 SupplierTenders.php:339 @@ -4210,7 +4210,7 @@ #: ContractBOM.php:323 CounterSales.php:2138 PO_Items.php:1015 #: SelectCompletedOrder.php:450 SelectCreditItems.php:944 -#: SelectOrderItems.php:1588 SelectSalesOrder.php:184 SelectWorkOrder.php:173 +#: SelectOrderItems.php:1589 SelectSalesOrder.php:184 SelectWorkOrder.php:173 msgid "Enter extract of the Stock Code" msgstr "Zadejte extrakt skladem zákoníku" @@ -4225,7 +4225,7 @@ #: ContractBOM.php:368 CounterSales.php:2001 FixedAssetItems.php:459 #: FixedAssetItems.php:463 PO_Items.php:1062 SelectCreditItems.php:971 -#: SelectOrderItems.php:1448 SelectOrderItems.php:1627 Stocks.php:711 +#: SelectOrderItems.php:1449 SelectOrderItems.php:1628 Stocks.php:711 #: Stocks.php:715 SupplierTenders.php:517 WorkOrderEntry.php:618 #: WorkOrderIssue.php:676 msgid "No Image" @@ -4296,9 +4296,9 @@ #: CounterSales.php:703 DeliveryDetails.php:786 DeliveryDetails.php:851 #: OrderDetails.php:156 PO_Items.php:808 PrintCustTrans.php:651 #: PrintCustTrans.php:714 PrintCustTrans.php:752 -#: PrintCustTransPortrait.php:834 PrintCustTransPortrait.php:917 -#: PrintCustTransPortrait.php:961 RecurringSalesOrders.php:323 -#: SelectCreditItems.php:654 SelectOrderItems.php:1294 +#: PrintCustTransPortrait.php:830 PrintCustTransPortrait.php:913 +#: PrintCustTransPortrait.php:957 RecurringSalesOrders.php:323 +#: SelectCreditItems.php:654 SelectOrderItems.php:1295 #: includes/PDFTopItemsHeader.inc:57 includes/PO_PDFOrderPageHeader.inc:79 msgid "Unit" msgstr "Jednotkou" @@ -4550,7 +4550,7 @@ #: Contracts.php:87 Contracts.php:96 Customers.php:293 DeliveryDetails.php:261 #: DeliveryDetails.php:270 EmailCustTrans.php:24 PO_Header.php:236 -#: SelectOrderItems.php:1144 StockUsage.php:23 SupplierCredit.php:214 +#: SelectOrderItems.php:1145 StockUsage.php:23 SupplierCredit.php:214 #: SupplierCredit.php:226 SupplierCredit.php:238 SupplierCredit.php:248 #: SupplierCredit.php:256 SupplierInvoice.php:192 SupplierInvoice.php:200 #: SupplierInvoice.php:208 SupplierInvoice.php:216 SupplierInvoice.php:224 @@ -4813,7 +4813,7 @@ msgid "Go to quotation number:" msgstr "Přejít na nabídku číslo:" -#: Contracts.php:604 SelectOrderItems.php:294 +#: Contracts.php:604 SelectOrderItems.php:295 msgid "" "Customer Branch Name keywords have been used in preference to the Customer " "Branch Code or Branch Phone Number entered" @@ -4821,7 +4821,7 @@ "Zákazník Obor Název klíčová slova byla použita v preferenci k zákazníkovi " "Pobočka kódu nebo pobočky Telefon vstoupil" -#: Contracts.php:607 SelectOrderItems.php:297 +#: Contracts.php:607 SelectOrderItems.php:298 msgid "" "Customer Branch Code has been used in preference to the Customer Branch " "Phone Number entered" @@ -4829,7 +4829,7 @@ "Zákazník Pobočka Kód byl použit v preferenci k zákazníkovi pobočky telefonní " "číslo zadané" -#: Contracts.php:610 SelectOrderItems.php:300 +#: Contracts.php:610 SelectOrderItems.php:301 msgid "" "At least one Customer Branch Name keyword OR an extract of a Customer Branch " "Code or Branch Phone Number must be entered for the search" @@ -4838,23 +4838,23 @@ "zákazníka kódu nebo pobočky telefonní číslo musí být zapsány na vyhledávání" #: Contracts.php:665 CustomerReceipt.php:575 SelectCustomer.php:245 -#: SelectOrderItems.php:367 +#: SelectOrderItems.php:368 msgid "The searched customer records requested cannot be retrieved because" msgstr "Hledali záznamy zákazníků požadovaná nelze načíst, protože" -#: Contracts.php:672 SelectOrderItems.php:374 +#: Contracts.php:672 SelectOrderItems.php:375 msgid "No Customer Branch records contain the search criteria" msgstr "Zákazník žádné pobočky záznamy obsahují kritéria vyhledávání" -#: Contracts.php:672 SelectOrderItems.php:374 +#: Contracts.php:672 SelectOrderItems.php:375 msgid "please try again" msgstr "prosím zkuste to znovu" -#: Contracts.php:672 SelectOrderItems.php:374 +#: Contracts.php:672 SelectOrderItems.php:375 msgid "Note a Customer Branch Name may be different to the Customer Name" msgstr "Poznámka: Zákazník pobočka Název se může lišit Jméno zákazníka" -#: Contracts.php:685 SelectOrderItems.php:387 +#: Contracts.php:685 SelectOrderItems.php:388 #, fuzzy msgid "Unable to identify the selected customer" msgstr "Nelze určit segment tag" @@ -4866,9 +4866,9 @@ #: Contracts.php:716 CounterSales.php:112 CounterSales.php:147 #: CounterSales.php:2022 CounterSales.php:2200 DeliveryDetails.php:148 #: PO_Header.php:395 PO_Header.php:462 SelectCreditItems.php:136 -#: SelectCreditItems.php:174 SelectOrderItems.php:417 SelectOrderItems.php:463 -#: SelectOrderItems.php:536 SelectOrderItems.php:576 SelectOrderItems.php:1471 -#: SelectOrderItems.php:1654 SpecialOrder.php:59 SpecialOrder.php:82 +#: SelectCreditItems.php:174 SelectOrderItems.php:418 SelectOrderItems.php:464 +#: SelectOrderItems.php:537 SelectOrderItems.php:577 SelectOrderItems.php:1472 +#: SelectOrderItems.php:1655 SpecialOrder.php:59 SpecialOrder.php:82 #: StockCheck.php:222 StockLocStatus.php:172 StockLocStatus.php:196 #: StockLocStatus.php:232 StockStatus.php:120 StockStatus.php:144 #: StockStatus.php:164 StockStatus.php:186 StockStatus.php:203 @@ -4877,7 +4877,7 @@ msgstr "nelze načíst, protože" #: Contracts.php:717 CounterSales.php:113 SelectCreditItems.php:137 -#: SelectOrderItems.php:418 SpecialOrder.php:83 +#: SelectOrderItems.php:419 SpecialOrder.php:83 msgid "The SQL used to retrieve the customer details and failed was" msgstr "SQL slouží k získání údajů o zákaznících a neúspěšný byl" @@ -4890,20 +4890,20 @@ msgstr "SQL používá, že se nepodařilo získat zákazníka detaily o:" #: Contracts.php:735 CounterSales.php:181 SalesAnalRepts.php:165 -#: SalesAnalRepts.php:229 SelectOrderItems.php:424 SelectOrderItems.php:509 -#: SelectOrderItems.php:518 SpecialOrder.php:89 +#: SalesAnalRepts.php:229 SelectOrderItems.php:425 SelectOrderItems.php:510 +#: SelectOrderItems.php:519 SpecialOrder.php:89 msgid "The" msgstr "" -#: Contracts.php:735 CounterSales.php:181 SelectOrderItems.php:509 +#: Contracts.php:735 CounterSales.php:181 SelectOrderItems.php:510 msgid "account is currently at or over their credit limit" msgstr "účet je v současné době, nebo přes jejich úvěrového limitu" -#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:511 +#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:512 msgid "No more orders can be placed by" msgstr "Žádné další objednávky mohou být umístěny na" -#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:511 +#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:512 msgid " their account is currently at or over their credit limit" msgstr "jejich účet je v současné době, nebo přes jejich úvěrového limitu" @@ -4911,20 +4911,20 @@ msgid "Contract: Select Customer" msgstr "Smlouvy: Vyberte zákazníky" -#: Contracts.php:756 SelectOrderItems.php:616 +#: Contracts.php:756 SelectOrderItems.php:617 msgid "Part of the Customer Branch Name" msgstr "Část Jméno zákazníka pobočky" -#: Contracts.php:759 SelectOrderItems.php:619 +#: Contracts.php:759 SelectOrderItems.php:620 msgid "Part of the Customer Branch Code" msgstr "Část kódu zákazníka pobočky" -#: Contracts.php:762 SelectOrderItems.php:622 +#: Contracts.php:762 SelectOrderItems.php:623 msgid "Part of the Branch Phone Number" msgstr "Část číslo pobočky telefonu" #: Contracts.php:767 Customers.php:610 Customers.php:1011 PO_Header.php:522 -#: SelectGLAccount.php:99 SelectOrderItems.php:627 +#: SelectGLAccount.php:99 SelectOrderItems.php:628 msgid "Reset" msgstr "Vymazat formulář" @@ -4932,8 +4932,8 @@ #: FTP_RadioBeacon.php:53 PDFOrdersInvoiced.php:303 PDFOrderStatus.php:270 #: PDFPriceList.php:356 PricesByCost.php:110 Prices_Customer.php:264 #: Prices_Customer.php:350 PrintCustTrans.php:610 -#: PrintCustTransPortrait.php:788 SelectCompletedOrder.php:518 -#: SelectCreditItems.php:223 SelectCustomer.php:458 SelectOrderItems.php:636 +#: PrintCustTransPortrait.php:784 SelectCompletedOrder.php:518 +#: SelectCreditItems.php:223 SelectCustomer.php:460 SelectOrderItems.php:637 #: SelectRecurringSalesOrder.php:80 SelectSalesOrder.php:422 #: SelectSalesOrder.php:433 StockMovements.php:99 #: StockSerialItemResearch.php:81 @@ -4945,13 +4945,13 @@ msgstr "Větev" #: Contracts.php:776 Factors.php:169 SelectCreditItems.php:224 -#: SelectCustomer.php:459 SelectOrderItems.php:637 SupplierContacts.php:212 +#: SelectCustomer.php:461 SelectOrderItems.php:638 SupplierContacts.php:212 msgid "Contact" msgstr "Kontakt" #: Contracts.php:778 EmailConfirmation.php:125 Factors.php:281 #: PDFCustomerList.php:344 PDFRemittanceAdvice.php:249 -#: SelectCreditItems.php:226 SelectCustomer.php:462 SelectOrderItems.php:639 +#: SelectCreditItems.php:226 SelectCustomer.php:464 SelectOrderItems.php:640 #: includes/PDFOrderPageHeader_generic.inc:32 #: includes/PDFPickingListHeader.inc:24 includes/PDFQuotationPageHeader.inc:23 #: includes/PDFSalesOrder_generic.inc:34 @@ -4963,7 +4963,7 @@ #: Contracts.php:827 CustomerInquiry.php:125 CustomerReceipt.php:900 #: PDFRemittanceAdvice.php:275 PO_Header.php:580 PrintCustTrans.php:637 -#: PrintCustTransPortrait.php:818 SupplierInquiry.php:119 +#: PrintCustTransPortrait.php:814 SupplierInquiry.php:119 #: includes/PDFStatementPageHeader.inc:116 includes/PDFTransPageHeader.inc:163 #: includes/PDFTransPageHeaderPortrait.inc:209 #: includes/PO_PDFOrderPageHeader.inc:72 @@ -5161,7 +5161,7 @@ "by měl být zadán pomocí kód zákazníka hypen pak větev kód zákazníka k " "použití." -#: CounterSales.php:112 SelectOrderItems.php:417 +#: CounterSales.php:112 SelectOrderItems.php:418 msgid "The details of the customer selected" msgstr "Podrobnosti o vybrané zákazníky" @@ -5176,34 +5176,34 @@ "pracovníky úvěrového řízení k projednání" #: CounterSales.php:147 DeliveryDetails.php:148 SelectCreditItems.php:174 -#: SelectOrderItems.php:463 SelectOrderItems.php:576 +#: SelectOrderItems.php:464 SelectOrderItems.php:577 msgid "The customer branch record of the customer selected" msgstr "Zákazník pobočka záznam vybrané zákazníky" #: CounterSales.php:148 DeliveryDetails.php:149 SelectCreditItems.php:175 -#: SelectOrderItems.php:464 SelectOrderItems.php:577 +#: SelectOrderItems.php:465 SelectOrderItems.php:578 msgid "SQL used to retrieve the branch details was" msgstr "SQL slouží k načtení informací větev byla" -#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:469 +#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:470 msgid "The branch details for branch code" msgstr "Podrobnosti pobočka pro obor kód" -#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:469 +#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:470 msgid "against customer code" msgstr "před kód zákazníka" #: CounterSales.php:153 DeliveryDetails.php:153 GLAccountCSV.php:183 #: GLAccountCSV.php:212 GLAccountInquiry.php:175 GLAccountInquiry.php:214 -#: GLAccountReport.php:114 GLAccountReport.php:146 SelectOrderItems.php:469 +#: GLAccountReport.php:114 GLAccountReport.php:146 SelectOrderItems.php:470 msgid "could not be retrieved" msgstr "se nepodařilo získat" -#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:469 +#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:470 msgid "Check the set up of the customer and branch" msgstr "Zkontrolujte nastavení na zákazníka a pobočky" -#: CounterSales.php:156 DeliveryDetails.php:156 SelectOrderItems.php:472 +#: CounterSales.php:156 DeliveryDetails.php:156 SelectOrderItems.php:473 msgid "The SQL that failed to get the branch details was" msgstr "SQL, které se nepodařilo dostat pobočky podrobnosti byl" @@ -5242,58 +5242,58 @@ msgid "Item Code has been used in search" msgstr "Položka Kód byl použit při hledání" -#: CounterSales.php:225 SelectOrderItems.php:756 +#: CounterSales.php:225 SelectOrderItems.php:757 msgid "Stock Category has been used in search" msgstr "Skladem Kategorie byl použit při hledání" -#: CounterSales.php:331 SelectOrderItems.php:856 WorkOrderEntry.php:154 +#: CounterSales.php:331 SelectOrderItems.php:857 WorkOrderEntry.php:154 #: WorkOrderIssue.php:470 msgid "The SQL used to get the part selection was" msgstr "SQL používá k získání části Výběr byl" -#: CounterSales.php:335 SelectOrderItems.php:860 WorkOrderEntry.php:158 +#: CounterSales.php:335 SelectOrderItems.php:861 WorkOrderEntry.php:158 #: WorkOrderIssue.php:474 msgid "There are no products available meeting the criteria specified" msgstr "Nejsou žádné výrobky k dispozici splňují kritéria stanovená" -#: CounterSales.php:410 SelectOrderItems.php:934 SelectOrderItems.php:1108 +#: CounterSales.php:410 SelectOrderItems.php:935 SelectOrderItems.php:1109 msgid "An invalid date entry was made for " msgstr "Neplatné datum vstupu byla pro" -#: CounterSales.php:410 SelectOrderItems.php:934 SelectOrderItems.php:1108 +#: CounterSales.php:410 SelectOrderItems.php:935 SelectOrderItems.php:1109 msgid "The date entry" msgstr "Datum vstupu" -#: CounterSales.php:410 SelectOrderItems.php:934 SelectOrderItems.php:1108 +#: CounterSales.php:410 SelectOrderItems.php:935 SelectOrderItems.php:1109 msgid "must be in the format" msgstr "musí být ve formátu" #: CounterSales.php:419 CounterSales.php:522 CounterSales.php:566 -#: CounterSales.php:616 SelectOrderItems.php:943 SelectOrderItems.php:1157 -#: SelectOrderItems.php:1205 +#: CounterSales.php:616 SelectOrderItems.php:944 SelectOrderItems.php:1158 +#: SelectOrderItems.php:1206 msgid "" "Could not determine if the part being ordered was a kitset or not because" msgstr "Nepodařilo se určit, zda část je uložena byla kitset nebo ne, protože" -#: CounterSales.php:420 CounterSales.php:523 SelectOrderItems.php:944 +#: CounterSales.php:420 CounterSales.php:523 SelectOrderItems.php:945 msgid "" "The sql that was used to determine if the part being ordered was a kitset or " "not was " msgstr "" "Sql, který byl použit k určení, zda část je uložena byla kitset byl či nebyl" -#: Counter... [truncated message content] |
From: <dai...@us...> - 2011-02-15 06:31:18
|
Revision: 4491 http://web-erp.svn.sourceforge.net/web-erp/?rev=4491&view=rev Author: daintree Date: 2011-02-15 06:31:08 +0000 (Tue, 15 Feb 2011) Log Message: ----------- Pre 4.03RC2 Modified Paths: -------------- trunk/ConfirmDispatch_Invoice.php trunk/DeliveryDetails.php trunk/PrintCustTrans.php trunk/PrintCustTransPortrait.php trunk/SelectCustomer.php trunk/SelectOrderItems.php trunk/UpgradeDatabase.php trunk/doc/Change.log.html trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.mo trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po trunk/locale/de_DE.utf8/LC_MESSAGES/messages.mo trunk/locale/de_DE.utf8/LC_MESSAGES/messages.po trunk/locale/el_GR.utf8/LC_MESSAGES/messages.mo trunk/locale/el_GR.utf8/LC_MESSAGES/messages.po trunk/locale/en_GB.utf8/LC_MESSAGES/messages.pot trunk/locale/en_US.utf8/LC_MESSAGES/messages.mo trunk/locale/en_US.utf8/LC_MESSAGES/messages.po trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/et_EE.utf8/LC_MESSAGES/messages.mo trunk/locale/et_EE.utf8/LC_MESSAGES/messages.po trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.mo trunk/locale/fa_IR.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.mo trunk/locale/hi_IN.utf8/LC_MESSAGES/messages.po trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.mo trunk/locale/hr_HR.utf8/LC_MESSAGES/messages.po trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.mo trunk/locale/hu_HU.utf8/LC_MESSAGES/messages.po trunk/locale/id_ID.utf8/LC_MESSAGES/messages.mo trunk/locale/id_ID.utf8/LC_MESSAGES/messages.po trunk/locale/it_IT.utf8/LC_MESSAGES/messages.mo trunk/locale/it_IT.utf8/LC_MESSAGES/messages.po trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.mo trunk/locale/ja_JP.utf8/LC_MESSAGES/messages.po trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.mo trunk/locale/lv_LV.utf8/LC_MESSAGES/messages.po trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.mo trunk/locale/nl_NL.utf8/LC_MESSAGES/messages.po trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.mo trunk/locale/pl_PL.utf8/LC_MESSAGES/messages.po trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_BR.utf8/LC_MESSAGES/messages.po trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.mo trunk/locale/pt_PT.utf8/LC_MESSAGES/messages.po trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.mo trunk/locale/ro_RO.utf8/LC_MESSAGES/messages.po trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.mo trunk/locale/ru_RU.utf8/LC_MESSAGES/messages.po trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.mo trunk/locale/sq_AL.utf8/LC_MESSAGES/messages.po trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.mo trunk/locale/sv_SE.utf8/LC_MESSAGES/messages.po trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.mo trunk/locale/sw_KE.utf8/LC_MESSAGES/messages.po trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.mo trunk/locale/tr_TR.utf8/LC_MESSAGES/messages.po trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_HK.utf8/LC_MESSAGES/messages.po trunk/sql/mysql/weberp-demo.sql trunk/sql/mysql/weberp-new.sql Modified: trunk/ConfirmDispatch_Invoice.php =================================================================== --- trunk/ConfirmDispatch_Invoice.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/ConfirmDispatch_Invoice.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -172,7 +172,7 @@ $myrow['controlled'], $myrow['serialised'], $myrow['decimalplaces'], - $myrow['narrative'], + htmlspecialchars_decode($myrow['narrative']), 'No', $myrow['orderlineno'], $myrow['taxcatid'], Modified: trunk/DeliveryDetails.php =================================================================== --- trunk/DeliveryDetails.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/DeliveryDetails.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -257,8 +257,8 @@ if(isset($_POST['MakeRecurringOrder']) AND ! $InputErrors){ - echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/RecurringSalesOrders.php?' . SID.'identifier='.$identifier . '&NewRecurringOrder=Yes">'; - prnMsg(_('You should automatically be forwarded to the entry of recurring order details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' ."<a href='" . $rootpath . '/RecurringOrders.php?' . SID.'identifier='.$identifier . "&NewRecurringOrder=Yes'>". _('click here') .'</a> '. _('to continue'),'info'); + echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/RecurringSalesOrders.php?identifier='.$identifier . '&NewRecurringOrder=Yes">'; + prnMsg(_('You should automatically be forwarded to the entry of recurring order details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' ."<a href='" . $rootpath . '/RecurringOrders.php?identifier='.$identifier . "&NewRecurringOrder=Yes'>". _('click here') .'</a> '. _('to continue'),'info'); include('includes/footer.inc'); exit; } @@ -266,8 +266,8 @@ if (isset($_POST['BackToLineDetails']) and $_POST['BackToLineDetails']==_('Modify Order Lines')){ - echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/SelectOrderItems.php?' . SID.'identifier='.$identifier . '">'; - prnMsg(_('You should automatically be forwarded to the entry of the order line details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' ."<a href='" . $rootpath . '/SelectOrderItems.php?' . SID.'identifier='.$identifier . "'>". _('click here') .'</a> '. _('to continue'),'info'); + echo '<meta http-equiv="Refresh" content="0; url=' . $rootpath . '/SelectOrderItems.php?identifier='.$identifier . '">'; + prnMsg(_('You should automatically be forwarded to the entry of the order line details page') . '. ' . _('If this does not happen') . '(' . _('if the browser does not support META Refresh') . ') ' .'<a href="' . $rootpath . '/SelectOrderItems.php?identifier='.$identifier . '">'. _('click here') .'</a> '. _('to continue'),'info'); include('includes/footer.inc'); exit; @@ -571,19 +571,19 @@ if ($_POST['Quotation']==0) { /*then its not a quotation its a real order */ - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder.php?' . SID .'identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Preprinted stationery') . ')' .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?' . SID .'identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder.php?identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Preprinted stationery') . ')' .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td>' . ' ' . '<a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?identifier='.$identifier . '&TransNo=' . $OrderNo . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/ConfirmDispatch_Invoice.php?' . SID .'identifier='.$identifier . '&OrderNumber=' . $OrderNo .'">'. _('Confirm Dispatch and Produce Invoice') .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/ConfirmDispatch_Invoice.php?identifier='.$identifier . '&OrderNumber=' . $OrderNo .'">'. _('Confirm Dispatch and Produce Invoice') .'</a></td></tr>'; //Add option to Print Sales Orders or Proforma invoice - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/pdf.png" title="' . _('Sales Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PrintSalesOrder_generic.php?' . SID .'identifier='.$identifier . '&TransNo=' . $OrderNo .'">'. _('Print Sales Order / Pro-forma Invoice') .'</a></td></tr></table>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/pdf.png" title="' . _('Sales Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PrintSalesOrder_generic.php?identifier='.$identifier . '&TransNo=' . $OrderNo .'">'. _('Print Sales Order / Pro-forma Invoice') .'</a></td></tr></table>'; } else { /*link to print the quotation */ - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?' . SID .'identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation') .'</a></td></tr></table>'; } - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="'. $rootpath .'/SelectOrderItems.php?' . SID .'identifier='.$identifier . '&NewOrder=Yes">'. _('Add Another Sales Order') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="'. $rootpath .'/SelectOrderItems.php?identifier='.$identifier . '&NewOrder=Yes">'. _('Add Another Sales Order') .'</a></td></tr></table>'; } else { /*its a customer logon so thank them */ prnMsg(_('Thank you for your business'),'success'); @@ -747,10 +747,10 @@ prnMsg(_('Order Number') .' ' . $_SESSION['ExistingOrder'] . ' ' . _('has been updated'),'success'); - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a href="' . $rootpath . '/PrintCustOrder.php?' . SID.'identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip - pre-printed stationery') .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?' . SID.'identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td><a href="' . $rootpath .'/ConfirmDispatch_Invoice.php?' . SID.'identifier='.$identifier . '&OrderNumber=' . $_SESSION['ExistingOrder'] . '">'. _('Confirm Order Delivery Quantities and Produce Invoice') .'</a></td></tr>'; - echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td><a href="' . $rootpath .'/SelectSalesOrder.php?' . SID.'identifier='.$identifier . '">'. _('Select A Different Order') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a href="' . $rootpath . '/PrintCustOrder.php?identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip - pre-printed stationery') .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/printer.png" title="' . _('Print') . '" alt=""></td><td><a target="_blank" href="' . $rootpath . '/PrintCustOrder_generic.php?identifier='.$identifier . '&TransNo=' . $_SESSION['ExistingOrder'] . '">'. _('Print packing slip') . ' (' . _('Laser') . ')' .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Invoice') . '" alt=""></td><td><a href="' . $rootpath .'/ConfirmDispatch_Invoice.php?identifier='.$identifier . '&OrderNumber=' . $_SESSION['ExistingOrder'] . '">'. _('Confirm Order Delivery Quantities and Produce Invoice') .'</a></td></tr>'; + echo '<tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td><a href="' . $rootpath .'/SelectSalesOrder.php?identifier='.$identifier . '">'. _('Select A Different Order') .'</a></td></tr></table>'; include('includes/footer.inc'); exit; } @@ -763,7 +763,7 @@ echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/customer.png" title="' . _('Customer') . '" alt="" />' . ' ' . _('Customer Code') . ' :<b> ' . $_SESSION['Items'.$identifier]->DebtorNo; echo '</b> ' . _('Customer Name') . ' :<b> ' . $_SESSION['Items'.$identifier]->CustomerName . '</p>'; //echo '<font size=4><b>'. _('Customer') .' : ' . $_SESSION['Items'.$identifier]->CustomerName . '</b></font>'; -echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID.'identifier='.$identifier . '" method=post>'; +echo '<form action="' . $_SERVER['PHP_SELF'] . '?identifier='.$identifier . '" method=post>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; Modified: trunk/PrintCustTrans.php =================================================================== --- trunk/PrintCustTrans.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/PrintCustTrans.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -261,7 +261,7 @@ $LeftOvers = $pdf->addTextWrap($FormDesign->Data->Column6->x, $YPos,$FormDesign->Data->Column6->Length, $FormDesign->Data->Column6->FontSize, $DisplayDiscount, 'right'); $LeftOvers = $pdf->addTextWrap($FormDesign->Data->Column7->x, $YPos,$FormDesign->Data->Column7->Length, $FormDesign->Data->Column7->FontSize, $DisplayNet, 'right'); $YPos-= ($line_height); - $lines = explode('\r\n', $myrow2['narrative']); + $lines = explode('\r\n', htmlspecialchars_decode($myrow2['narrative'])); for ($i = 0;$i < sizeOf($lines);$i++) { while (strlen($lines[$i]) > 1) { if ($YPos - $line_height <= $Bottom_Margin) { Modified: trunk/PrintCustTransPortrait.php =================================================================== --- trunk/PrintCustTransPortrait.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/PrintCustTransPortrait.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -360,7 +360,7 @@ } $YPos -= ($FontSize*$lines); - $lines=explode('\r\n',$myrow2['narrative']); + $lines=explode('\r\n',htmlspecialchars_decode($myrow2['narrative'])); for ($i=0;$i<sizeOf($lines);$i++) { while (strlen($lines[$i])>1){ if ($YPos-$line_height <= $Bottom_Margin){ @@ -391,10 +391,8 @@ /* check to see enough space left to print the 4 lines for the totals/footer */ if (($YPos-$Bottom_Margin)<(2*$line_height)){ - PrintLinesToBottom (); include ('includes/PDFTransPageHeaderPortrait.inc'); - } /*Print a column vertical line with enough space for the footer*/ /*draw the vertical column lines to 4 lines shy of the bottom @@ -426,9 +424,7 @@ $DisplayFreight = number_format($myrow['ovfreight'],2); $DisplayTax = number_format($myrow['ovgst'],2); $DisplayTotal = number_format($myrow['ovfreight']+$myrow['ovgst']+$myrow['ovamount'],2); - } else { - $DisplaySubTot = number_format(-$myrow['ovamount'],2); $DisplayFreight = number_format(-$myrow['ovfreight'],2); $DisplayTax = number_format(-$myrow['ovgst'],2); Modified: trunk/SelectCustomer.php =================================================================== --- trunk/SelectCustomer.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/SelectCustomer.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -316,7 +316,9 @@ } echo '<form action="' . $_SERVER['PHP_SELF'] . '?' . SID . '" method=post>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; -prnMsg($msg,'info'); +if (strlen($msg)>1){ + prnMsg($msg,'info'); +} echo '<p class="page_title_text"><img src="' . $rootpath . '/css/' . $theme . '/images/magnifier.png" title="' . _('Search') . '" alt="" />' . ' ' . _('Search for Customers').'</p>'; echo "<table cellpadding=3 colspan=4 class=selection>"; echo "<tr><td colspan=2>" . _('Enter a partial Name') . ":</td><td>"; Modified: trunk/SelectOrderItems.php =================================================================== --- trunk/SelectOrderItems.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/SelectOrderItems.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -35,7 +35,8 @@ } -if (empty($_GET['identifier'])) { +if (empty($_GET['identifier'])) { + /*unique session identifier to ensure that there is no conflict with other order entry sessions on the same machine */ $identifier=date('U'); } else { $identifier=$_GET['identifier']; @@ -1365,7 +1366,7 @@ echo '<td><input type=text class="date" alt="'.$_SESSION['DefaultDateFormat'].'" name="ItemDue_' . $OrderLine->LineNumber . '" size=10 maxlength=10 value=' . $LineDueDate . '></td>'; - echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?' . SID .'identifier='.$identifier . '&Delete=' . $OrderLine->LineNumber . '" onclick="return confirm(\'' . _('Are You Sure?') . '\');">' . $RemTxt . '</a></td></tr>'; + echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&Delete=' . $OrderLine->LineNumber . '" onclick="return confirm(\'' . _('Are You Sure?') . '\');">' . $RemTxt . '</a></td></tr>'; if ($_SESSION['AllowOrderLineItemNarrative'] == 1){ echo $RowStarter; Modified: trunk/UpgradeDatabase.php =================================================================== --- trunk/UpgradeDatabase.php 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/UpgradeDatabase.php 2011-02-15 06:31:08 UTC (rev 4491) @@ -32,7 +32,7 @@ echo '<option value="3.11">' . _('Version 3.11 or 4.01 - 4.02') . '</option>'; echo '</select></td></tr></table>'; } else { - if ($_SESSION['VersionNumber']=='4.00-RC1'){ + if ($_SESSION['VersionNumber']=='4.00RC1'){ $_SESSION['VersionNumber']='3.12'; } prnMsg(_('The webERP code is version') . ' ' . $Version . ' ' . _('and the database version is') . ' ' . $_SESSION['VersionNumber'],'info'); @@ -97,7 +97,7 @@ $SQLScripts[] = './sql/mysql/upgrade3.11.1-4.00.sql'; break; } //end switch - if(isset($_SESSION['VersionNumber']) AND $_SESSION['VersionNumber']< '4.00') { /* VersionNumber is set to '4.00' when upgrade3.11.1-4.00.sql is run */ + if(isset($_SESSION['VersionNumber']) AND $_SESSION['VersionNumber']< '4.03') { /* VersionNumber is set to '4.03' when upgrade3.11.1-4.00.sql is run */ $SQLScripts[] = './sql/mysql/upgrade3.11.1-4.00.sql'; } } Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/doc/Change.log.html 2011-02-15 06:31:08 UTC (rev 4491) @@ -1,5 +1,11 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p <p /> +<p>15/2/11 Release 4.03RC2</p> +<p /> +<p>15/2/11: Phil UpgradeDatabase.php fix to upgrade from 4.01RC1 !!</p> +<p>15/2/11: Phil PrintCustTrans.php and PrintCustTransPortrait.php htmlspecialchars_decode($narrative) - conversion at the time of committing to DB needs to be unconverted. Also in ConfirmDispatch_Invoice.php</p> +<p>15/2/11: Phil SelectCustomer.php removed showing blank message when $msg was empty </p> +<p /> <p>13/2/11 Release 4.03RC1</p> <p /> <p>13/2/11:Phil GoodsReceivedControlled InputSerialItems and friends - now uses session identifier to ensure uniqueness is several people entering stock receipts</p> Modified: trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po 2011-02-13 04:15:38 UTC (rev 4490) +++ trunk/locale/cs_CZ.utf8/LC_MESSAGES/messages.po 2011-02-15 06:31:08 UTC (rev 4491) @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: webERP 3.08\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-02-13 17:03+1300\n" +"POT-Creation-Date: 2011-02-15 18:44+1200\n" "PO-Revision-Date: 2010-07-25 17:04+0000\n" "Last-Translator: Tim Schofield <ti...@we...>\n" "Language-Team: Czech <cs...@li...>\n" @@ -219,9 +219,9 @@ #: SalesCategories.php:13 SalesGLPostings.php:18 SalesGraph.php:34 #: SalesPeople.php:22 SalesTypes.php:22 SelectAsset.php:44 #: SelectCompletedOrder.php:13 SelectContract.php:81 SelectCreditItems.php:204 -#: SelectCreditItems.php:272 SelectCustomer.php:320 SelectGLAccount.php:19 -#: SelectGLAccount.php:79 SelectOrderItems.php:606 SelectOrderItems.php:1430 -#: SelectOrderItems.php:1554 SelectProduct.php:456 SelectSalesOrder.php:155 +#: SelectCreditItems.php:272 SelectCustomer.php:322 SelectGLAccount.php:19 +#: SelectGLAccount.php:79 SelectOrderItems.php:607 SelectOrderItems.php:1431 +#: SelectOrderItems.php:1555 SelectProduct.php:456 SelectSalesOrder.php:155 #: SelectSupplier.php:9 SelectSupplier.php:198 SelectWorkOrder.php:11 #: SelectWorkOrder.php:147 ShipmentCosting.php:13 Shipments.php:18 #: Shippers.php:123 Shippers.php:159 Shipt_Select.php:10 @@ -342,9 +342,9 @@ #: PcTypeTabs.php:171 PO_AuthorisationLevels.php:148 Prices_Customer.php:283 #: Prices.php:227 PurchData.php:207 SalesCategories.php:263 #: SalesGLPostings.php:135 SalesGLPostings.php:247 SalesPeople.php:210 -#: SalesTypes.php:206 SelectCustomer.php:607 SelectCustomer.php:623 -#: SelectCustomer.php:645 SelectCustomer.php:661 SelectCustomer.php:683 -#: SelectCustomer.php:699 Shippers.php:144 StockCategories.php:244 +#: SalesTypes.php:206 SelectCustomer.php:609 SelectCustomer.php:625 +#: SelectCustomer.php:647 SelectCustomer.php:663 SelectCustomer.php:685 +#: SelectCustomer.php:701 Shippers.php:144 StockCategories.php:244 #: SupplierContacts.php:153 SupplierTypes.php:192 SuppLoginSetup.php:274 #: TaxAuthorities.php:173 TaxCategories.php:184 TaxGroups.php:179 #: TaxProvinces.php:178 UnitsOfMeasure.php:201 WorkCentres.php:138 @@ -370,9 +370,9 @@ #: PO_Items.php:758 Prices_Customer.php:284 Prices.php:228 PurchData.php:208 #: SalesAnalReptCols.php:294 SalesAnalRepts.php:305 SalesCategories.php:264 #: SalesGLPostings.php:136 SalesGLPostings.php:248 SalesPeople.php:211 -#: SalesTypes.php:207 SelectCreditItems.php:747 SelectCustomer.php:608 -#: SelectCustomer.php:624 SelectCustomer.php:646 SelectCustomer.php:662 -#: SelectCustomer.php:684 SelectCustomer.php:700 SelectOrderItems.php:1357 +#: SalesTypes.php:207 SelectCreditItems.php:747 SelectCustomer.php:610 +#: SelectCustomer.php:626 SelectCustomer.php:648 SelectCustomer.php:664 +#: SelectCustomer.php:686 SelectCustomer.php:702 SelectOrderItems.php:1358 #: Shipments.php:424 Shippers.php:145 SpecialOrder.php:590 #: StockCategories.php:245 StockCategories.php:539 SuppContractChgs.php:91 #: SuppCreditGRNs.php:93 SuppFixedAssetChgs.php:81 SuppInvGRNs.php:135 @@ -500,8 +500,8 @@ msgid "Could not retrieve the requested section please try again." msgstr "Nepodařilo se získat požadovanou sekci prosím zkuste to znovu." -#: AddCustomerContacts.php:6 AddCustomerContacts.php:59 SelectCustomer.php:601 -#: SelectCustomer.php:630 +#: AddCustomerContacts.php:6 AddCustomerContacts.php:59 SelectCustomer.php:603 +#: SelectCustomer.php:632 msgid "Customer Contacts" msgstr "Zákazník Kontakty" @@ -550,7 +550,7 @@ #: AddCustomerContacts.php:112 CompanyPreferences.php:229 #: CustomerBranches.php:377 Customers.php:899 Customers.php:905 -#: Customers.php:971 SalesPeople.php:185 SelectCustomer.php:603 +#: Customers.php:971 SalesPeople.php:185 SelectCustomer.php:605 #: StockDispatch.php:186 StockDispatch.php:198 SupplierContacts.php:141 #: SupplierCredit.php:433 SupplierInvoice.php:408 SuppTransGLAnalysis.php:96 #: includes/InputSerialItemsFile.php:84 includes/InputSerialItemsFile.php:124 @@ -559,7 +559,7 @@ msgstr "Název" #: AddCustomerContacts.php:113 AddCustomerContacts.php:190 Customers.php:900 -#: Customers.php:906 Customers.php:972 SelectCustomer.php:604 +#: Customers.php:906 Customers.php:972 SelectCustomer.php:606 #: WWW_Access.php:111 WWW_Access.php:172 msgid "Role" msgstr "Roli" @@ -572,7 +572,7 @@ #: Customers.php:908 Customers.php:974 PcAssignCashToTab.php:216 #: PcAssignCashToTab.php:341 PcAuthorizeExpenses.php:85 #: PcClaimExpensesFromTab.php:195 PcClaimExpensesFromTab.php:348 -#: PcReportTab.php:348 SelectCustomer.php:606 SystemParameters.php:316 +#: PcReportTab.php:348 SelectCustomer.php:608 SystemParameters.php:316 #: WOSerialNos.php:277 WOSerialNos.php:279 msgid "Notes" msgstr "Bere na vědomí" @@ -591,14 +591,14 @@ #: AddCustomerContacts.php:196 Contracts.php:777 PDFRemittanceAdvice.php:247 #: PO_Header.php:958 PO_Header.php:1028 SelectCreditItems.php:225 -#: SelectCustomer.php:461 SelectOrderItems.php:638 +#: SelectCustomer.php:463 SelectOrderItems.php:639 #: includes/PDFStatementPageHeader.inc:63 includes/PDFTransPageHeader.inc:117 #: includes/PDFTransPageHeaderPortrait.inc:105 msgid "Phone" msgstr "Telefon" -#: AddCustomerNotes.php:6 AddCustomerNotes.php:49 SelectCustomer.php:638 -#: SelectCustomer.php:668 +#: AddCustomerNotes.php:6 AddCustomerNotes.php:49 SelectCustomer.php:640 +#: SelectCustomer.php:670 msgid "Customer Notes" msgstr "Zákazník bere na vědomí" @@ -639,7 +639,7 @@ #: GLAccountReport.php:369 GLTransInquiry.php:45 MRPCalendar.php:217 #: PaymentAllocations.php:77 PcAssignCashToTab.php:212 #: PcAuthorizeExpenses.php:81 PDFRemittanceAdvice.php:308 -#: PrintCustTrans.php:616 PrintCustTransPortrait.php:794 ReverseGRN.php:378 +#: PrintCustTrans.php:616 PrintCustTransPortrait.php:790 ReverseGRN.php:378 #: ShipmentCosting.php:503 ShipmentCosting.php:574 Shipments.php:467 #: StockDispatch.php:188 StockDispatch.php:200 StockLocMovements.php:85 #: StockMovements.php:98 StockSerialItemResearch.php:79 @@ -685,7 +685,7 @@ msgid "Contact Note" msgstr "Kontakt Poznámka:" -#: AddCustomerTypeNotes.php:6 SelectCustomer.php:676 +#: AddCustomerTypeNotes.php:6 SelectCustomer.php:678 msgid "Customer Type (Group) Notes" msgstr "Typ zákazníka (Group) Poznámky" @@ -693,7 +693,7 @@ msgid "The Contact priority must be an integer." msgstr "Prioritou Kontakt musí být celé číslo." -#: AddCustomerTypeNotes.php:49 SelectCustomer.php:706 +#: AddCustomerTypeNotes.php:49 SelectCustomer.php:708 msgid "Customer Group Notes" msgstr "Zákaznická skupina bere na vědomí" @@ -917,7 +917,7 @@ #: OutstandingGRNs.php:185 PDFCustomerList.php:412 PDFLowGP.php:168 #: PDFPriceList.php:301 PDFRemittanceAdvice.php:152 #: PDFStockCheckComparison.php:379 PrintCustTrans.php:416 -#: PrintCustTransPortrait.php:564 ReorderLevel.php:229 StockDispatch.php:309 +#: PrintCustTransPortrait.php:560 ReorderLevel.php:229 StockDispatch.php:309 #: SupplierBalsAtPeriodEnd.php:155 SuppPriceList.php:237 Tax.php:352 msgid "Print PDF" msgstr "Tisknout PDF" @@ -1108,7 +1108,7 @@ #: CustomerTransInquiry.php:21 CustomerTransInquiry.php:85 #: CustWhereAlloc.php:18 CustWhereAlloc.php:87 DailyBankTransactions.php:98 #: GLAccountInquiry.php:152 GLAccountReport.php:367 GLJournal.php:256 -#: MRPReschedules.php:204 SelectCustomer.php:460 ShipmentCosting.php:501 +#: MRPReschedules.php:204 SelectCustomer.php:462 ShipmentCosting.php:501 #: ShipmentCosting.php:572 StockCategories.php:219 StockLocMovements.php:83 #: StockMovements.php:97 SupplierAllocations.php:462 SupplierInquiry.php:193 #: SupplierTransInquiry.php:19 SupplierTransInquiry.php:86 @@ -1599,8 +1599,8 @@ #: CustomerInquiry.php:190 CustomerTransInquiry.php:86 CustWhereAlloc.php:88 #: EmailCustTrans.php:17 GLAccountInquiry.php:153 PrintCustTrans.php:378 #: PrintCustTrans.php:542 PrintCustTrans.php:696 PrintCustTrans.php:735 -#: PrintCustTransPortrait.php:508 PrintCustTransPortrait.php:708 -#: PrintCustTransPortrait.php:898 PrintCustTransPortrait.php:943 +#: PrintCustTransPortrait.php:504 PrintCustTransPortrait.php:704 +#: PrintCustTransPortrait.php:894 PrintCustTransPortrait.php:939 #: StockMovements.php:97 SupplierAllocations.php:463 #: SupplierAllocations.php:575 SupplierAllocations.php:645 #: SupplierTransInquiry.php:87 Z_CheckAllocs.php:60 @@ -1669,7 +1669,7 @@ "měny bankovního účtu" #: BankReconciliation.php:311 CounterSales.php:781 Customers.php:1014 -#: SelectOrderItems.php:1368 Stocks.php:1033 WorkOrderCosting.php:512 +#: SelectOrderItems.php:1369 Stocks.php:1033 WorkOrderCosting.php:512 #: WorkOrderEntry.php:549 msgid "Are You Sure?" msgstr "Opravdu provést?" @@ -1747,14 +1747,14 @@ #: OffersReceived.php:196 OffersReceived.php:245 OrderDetails.php:155 #: PDFOrdersInvoiced.php:387 POReport.php:699 POReport.php:1365 #: PrintCustTrans.php:650 PrintCustTrans.php:713 PrintCustTrans.php:751 -#: PrintCustTransPortrait.php:833 PrintCustTransPortrait.php:916 -#: PrintCustTransPortrait.php:960 RecurringSalesOrders.php:322 +#: PrintCustTransPortrait.php:829 PrintCustTransPortrait.php:912 +#: PrintCustTransPortrait.php:956 RecurringSalesOrders.php:322 #: ReorderLevel.php:268 ReverseGRN.php:379 ReverseGRN.php:380 #: SalesAnalReptCols.php:18 SalesAnalReptCols.php:20 SalesGraph.php:177 #: SalesGraph.php:258 SalesInquiry.php:974 SelectCreditItems.php:653 -#: SelectCreditItems.php:1004 SelectOrderItems.php:1292 -#: SelectOrderItems.php:1441 SelectOrderItems.php:1625 -#: SelectOrderItems.php:1753 ShipmentCosting.php:140 ShipmentCosting.php:141 +#: SelectCreditItems.php:1004 SelectOrderItems.php:1293 +#: SelectOrderItems.php:1442 SelectOrderItems.php:1626 +#: SelectOrderItems.php:1754 ShipmentCosting.php:140 ShipmentCosting.php:141 #: Shipments.php:386 Shipments.php:388 Shipments.php:389 Shipments.php:464 #: Shipments.php:466 SpecialOrder.php:551 StockCounts.php:98 #: StockLocMovements.php:87 StockLocTransfer.php:181 StockMovements.php:99 @@ -1854,8 +1854,8 @@ #: MRPReport.php:827 MRPReschedules.php:191 MRPShortages.php:287 #: PDFPriceList.php:331 PDFReceipt.php:32 PDFRemittanceAdvice.php:218 #: PrintCustTrans.php:560 PrintCustTrans.php:709 PrintCustTrans.php:747 -#: PrintCustTransPortrait.php:730 PrintCustTransPortrait.php:912 -#: PrintCustTransPortrait.php:956 ReorderLevel.php:252 StockDispatch.php:338 +#: PrintCustTransPortrait.php:726 PrintCustTransPortrait.php:908 +#: PrintCustTransPortrait.php:952 ReorderLevel.php:252 StockDispatch.php:338 #: SuppPriceList.php:264 Tax.php:252 includes/PDFAgedDebtorsPageHeader.inc:34 #: includes/PDFAgedSuppliersPageHeader.inc:21 #: includes/PDFBalanceSheetPageHeader.inc:26 @@ -1913,7 +1913,7 @@ #: CounterSales.php:2170 PO_SelectOSPurchOrder.php:214 #: PO_SelectPurchOrder.php:174 ReorderLevelLocation.php:58 #: ReorderLevelLocation.php:59 SelectCompletedOrder.php:468 -#: SelectOrderItems.php:1437 SelectOrderItems.php:1621 +#: SelectOrderItems.php:1438 SelectOrderItems.php:1622 #: SelectSalesOrder.php:197 SelectWorkOrder.php:186 Shipt_Select.php:185 #: TopItems.php:165 includes/PDFTopItemsHeader.inc:59 msgid "On Hand" @@ -2002,8 +2002,8 @@ #: PricesByCost.php:108 ReorderLevelLocation.php:55 ReorderLevel.php:266 #: ReverseGRN.php:377 SalesCategories.php:427 SelectAsset.php:224 #: SelectCompletedOrder.php:467 SelectContract.php:156 -#: SelectCreditItems.php:958 SelectOrderItems.php:1435 -#: SelectOrderItems.php:1619 SelectProduct.php:476 SelectProduct.php:681 +#: SelectCreditItems.php:958 SelectOrderItems.php:1436 +#: SelectOrderItems.php:1620 SelectProduct.php:476 SelectProduct.php:681 #: SelectSalesOrder.php:196 SelectWorkOrder.php:185 Shipt_Select.php:184 #: StockCategories.php:218 StockDispatch.php:357 StockDispatch.php:364 #: StockLocStatus.php:149 StockQuantityByDate.php:92 SuppCreditGRNs.php:75 @@ -2106,10 +2106,10 @@ #: MRPReport.php:563 PO_Header.php:516 PO_Items.php:1015 PO_Items.php:1020 #: PO_SelectOSPurchOrder.php:202 PO_SelectPurchOrder.php:165 PurchData.php:264 #: SelectAsset.php:93 SelectCompletedOrder.php:450 SelectCreditItems.php:210 -#: SelectCreditItems.php:944 SelectCustomer.php:328 SelectCustomer.php:334 -#: SelectCustomer.php:341 SelectCustomer.php:349 SelectCustomer.php:393 -#: SelectGLAccount.php:92 SelectOrderItems.php:618 SelectOrderItems.php:621 -#: SelectOrderItems.php:1588 SelectProduct.php:483 SelectSalesOrder.php:184 +#: SelectCreditItems.php:944 SelectCustomer.php:330 SelectCustomer.php:336 +#: SelectCustomer.php:343 SelectCustomer.php:351 SelectCustomer.php:395 +#: SelectGLAccount.php:92 SelectOrderItems.php:619 SelectOrderItems.php:622 +#: SelectOrderItems.php:1589 SelectProduct.php:483 SelectSalesOrder.php:184 #: SelectSupplier.php:206 SelectWorkOrder.php:173 Shipt_Select.php:170 #: SuppFixedAssetChgs.php:113 SupplierTenders.php:358 WorkOrderEntry.php:583 #: WorkOrderIssue.php:638 @@ -2138,8 +2138,8 @@ #: CounterSales.php:2142 CustomerReceipt.php:1037 FixedAssetTransfer.php:72 #: MRPDemands.php:335 MRPReport.php:571 PO_Header.php:521 PO_Items.php:1023 #: SelectAsset.php:101 SelectCreditItems.php:215 SelectCreditItems.php:949 -#: SelectCustomer.php:416 SelectGLAccount.php:98 SelectOrderItems.php:626 -#: SelectOrderItems.php:1595 SelectProduct.php:491 SelectSupplier.php:212 +#: SelectCustomer.php:418 SelectGLAccount.php:98 SelectOrderItems.php:627 +#: SelectOrderItems.php:1596 SelectProduct.php:491 SelectSupplier.php:212 #: SelectSupplier.php:245 SupplierTenders.php:366 WorkOrderEntry.php:587 #: WorkOrderIssue.php:642 msgid "Search Now" @@ -2180,8 +2180,8 @@ #: PricesByCost.php:107 PurchData.php:338 ReorderLevelLocation.php:54 #: ReorderLevelLocation.php:203 SalesPeople.php:184 #: SelectCompletedOrder.php:466 SelectCreditItems.php:222 -#: SelectCreditItems.php:957 SelectCustomer.php:456 SelectGLAccount.php:105 -#: SelectOrderItems.php:1434 SelectOrderItems.php:1618 SelectProduct.php:680 +#: SelectCreditItems.php:957 SelectCustomer.php:458 SelectGLAccount.php:105 +#: SelectOrderItems.php:1435 SelectOrderItems.php:1619 SelectProduct.php:680 #: SelectSalesOrder.php:195 SelectSupplier.php:249 SelectWorkOrder.php:184 #: Shipt_Select.php:183 SpecialOrder.php:134 SupplierTenders.php:488 #: SuppPriceList.php:281 TopItems.php:160 WorkOrderEntry.php:598 @@ -2196,7 +2196,7 @@ #: MRPReport.php:762 OffersReceived.php:95 PO_Items.php:1038 #: PO_SelectOSPurchOrder.php:216 PO_SelectPurchOrder.php:176 #: SelectCompletedOrder.php:471 SelectCreditItems.php:959 -#: SelectOrderItems.php:1436 SelectOrderItems.php:1620 SelectProduct.php:108 +#: SelectOrderItems.php:1437 SelectOrderItems.php:1621 SelectProduct.php:108 #: SelectProduct.php:683 SelectSalesOrder.php:198 SelectWorkOrder.php:187 #: Shipments.php:387 Shipments.php:465 Shipt_Select.php:187 #: StockLocTransferReceive.php:435 SupplierTenders.php:490 TopItems.php:163 @@ -2645,7 +2645,7 @@ #: Customers.php:738 Customers.php:741 DiscountMatrix.php:98 #: DiscountMatrix.php:157 PricesByCost.php:216 Prices.php:199 #: SalesAnalRepts.php:34 SalesAnalRepts.php:36 SalesGLPostings.php:115 -#: SalesGLPostings.php:226 SalesGLPostings.php:354 SelectOrderItems.php:744 +#: SalesGLPostings.php:226 SalesGLPostings.php:354 SelectOrderItems.php:745 #: api/api_xml-rpc.php:931 api/api_xml-rpc.php:974 msgid "Sales Type" msgstr "Prodej Typ" @@ -2672,7 +2672,7 @@ #: COGSGLPostings.php:307 Customers.php:741 EDIProcessOrders.php:389 #: PDFCustomerList.php:334 PDFPriceList.php:17 PDFPriceList.php:121 #: PDFPriceList.php:251 PricesBasedOnMarkUp.php:223 PricesByCost.php:216 -#: SalesGLPostings.php:354 SelectOrderItems.php:744 SuppPriceList.php:118 +#: SalesGLPostings.php:354 SelectOrderItems.php:745 SuppPriceList.php:118 #: SuppPriceList.php:231 msgid "Price List" msgstr "Ceník" @@ -2961,7 +2961,7 @@ "první z obrazovky dodání podrobnosti klikněte na Potvrdit pro fakturaci" #: ConfirmDispatch_Invoice.php:75 OrderDetails.php:53 -#: RecurringSalesOrders.php:68 SelectOrderItems.php:126 +#: RecurringSalesOrders.php:68 SelectOrderItems.php:127 #: includes/PO_ReadInOrder.inc:58 msgid "The order cannot be retrieved because" msgstr "Aby nemůže získat, protože" @@ -2971,7 +2971,7 @@ msgstr "SQL získat pořadí záhlaví byl" #: ConfirmDispatch_Invoice.php:151 Credit_Invoice.php:127 OrderDetails.php:140 -#: RecurringSalesOrders.php:126 SelectOrderItems.php:216 +#: RecurringSalesOrders.php:126 SelectOrderItems.php:217 msgid "The line items of the order cannot be retrieved because" msgstr "Řádkové položky v řádu nelze načíst, protože" @@ -3003,7 +3003,7 @@ #: DeliveryDetails.php:763 FTP_RadioBeacon.php:52 PDFOrdersInvoiced.php:302 #: PDFOrderStatus.php:269 PricesByCost.php:109 SalesGraph.php:169 #: SelectCompletedOrder.php:517 SelectContract.php:157 SelectCustomer.php:23 -#: SelectCustomer.php:280 SelectOrderItems.php:635 +#: SelectCustomer.php:280 SelectOrderItems.php:636 #: SelectRecurringSalesOrder.php:79 SelectSalesOrder.php:421 #: SelectSalesOrder.php:432 StockLocMovements.php:86 StockMovements.php:98 #: includes/PDFAgedDebtorsPageHeader.inc:48 @@ -3034,7 +3034,7 @@ #: SalesInquiry.php:758 SalesInquiry.php:782 SalesInquiry.php:926 #: SalesInquiry.php:937 SalesInquiry.php:943 SalesInquiry.php:949 #: SalesInquiry.php:1088 SalesInquiry.php:1142 SalesInquiry.php:1158 -#: SelectCustomer.php:457 SelectOrderItems.php:741 +#: SelectCustomer.php:459 SelectOrderItems.php:742 msgid "Customer Name" msgstr "Název zákazníka" @@ -3047,10 +3047,10 @@ #: CounterSales.php:2301 Credit_Invoice.php:271 DeliveryDetails.php:783 #: GoodsReceived.php:89 OrderDetails.php:153 PO_Items.php:708 #: PO_OrderDetails.php:142 PrintCustTrans.php:648 PrintCustTrans.php:711 -#: PrintCustTrans.php:749 PrintCustTransPortrait.php:831 -#: PrintCustTransPortrait.php:914 PrintCustTransPortrait.php:958 +#: PrintCustTrans.php:749 PrintCustTransPortrait.php:827 +#: PrintCustTransPortrait.php:910 PrintCustTransPortrait.php:954 #: RecurringSalesOrders.php:320 ReverseGRN.php:376 SalesGraph.php:170 -#: SelectCreditItems.php:651 SelectOrderItems.php:1290 StockCostUpdate.php:124 +#: SelectCreditItems.php:651 SelectOrderItems.php:1291 StockCostUpdate.php:124 #: StockLocMovements.php:82 StockLocTransfer.php:181 #: StockLocTransferReceive.php:430 StockQuantityByDate.php:91 Stocks.php:584 #: Stocks.php:586 Stocks.php:636 Stocks.php:640 SuppCreditGRNs.php:74 @@ -3071,9 +3071,9 @@ #: Credit_Invoice.php:272 DeliveryDetails.php:784 DeliveryDetails.php:849 #: OrderDetails.php:154 PO_Items.php:776 PO_OrderDetails.php:143 #: PrintCustTrans.php:649 PrintCustTrans.php:712 PrintCustTrans.php:750 -#: PrintCustTransPortrait.php:832 PrintCustTransPortrait.php:915 -#: PrintCustTransPortrait.php:959 RecurringSalesOrders.php:321 -#: SelectCreditItems.php:652 SelectOrderItems.php:1291 SpecialOrder.php:549 +#: PrintCustTransPortrait.php:828 PrintCustTransPortrait.php:911 +#: PrintCustTransPortrait.php:955 RecurringSalesOrders.php:321 +#: SelectCreditItems.php:652 SelectOrderItems.php:1292 SpecialOrder.php:549 #: StockLocTransferReceive.php:431 includes/PDFOrderPageHeader_generic.inc:92 #: includes/PDFPickingListHeader.inc:73 #: includes/PDFQuotationPageHeader.inc:101 @@ -3111,10 +3111,10 @@ #: PDFPrintLabel.php:239 PO_AuthoriseMyOrders.php:108 PricesByCost.php:201 #: Prices_Customer.php:367 Prices.php:200 Prices.php:339 #: PrintCustTrans.php:652 PrintCustTrans.php:715 PrintCustTrans.php:753 -#: PrintCustTransPortrait.php:835 PrintCustTransPortrait.php:918 -#: PrintCustTransPortrait.php:962 PurchData.php:168 PurchData.php:455 +#: PrintCustTransPortrait.php:831 PrintCustTransPortrait.php:914 +#: PrintCustTransPortrait.php:958 PurchData.php:168 PurchData.php:455 #: RecurringSalesOrders.php:324 SelectCreditItems.php:655 -#: SelectOrderItems.php:1295 Shipments.php:390 StockLocMovements.php:89 +#: SelectOrderItems.php:1296 Shipments.php:390 StockLocMovements.php:89 #: StockMovements.php:100 StockStatus.php:310 SuppCreditGRNs.php:227 #: SuppCreditGRNs.php:228 SupplierTenders.php:268 SupplierTenders.php:493 #: SuppPriceList.php:283 includes/DefineLabelClass.php:49 @@ -3127,10 +3127,10 @@ #: ConfirmDispatch_Invoice.php:269 CounterSales.php:705 Credit_Invoice.php:277 #: CustomerReceipt.php:846 DeliveryDetails.php:788 OrderDetails.php:158 #: PrintCustTrans.php:653 PrintCustTrans.php:716 PrintCustTrans.php:754 -#: PrintCustTransPortrait.php:836 PrintCustTransPortrait.php:919 -#: PrintCustTransPortrait.php:963 RecurringSalesOrders.php:325 +#: PrintCustTransPortrait.php:832 PrintCustTransPortrait.php:915 +#: PrintCustTransPortrait.php:959 RecurringSalesOrders.php:325 #: SalesAnalReptCols.php:43 SalesAnalReptCols.php:45 SelectCreditItems.php:657 -#: SelectOrderItems.php:1298 StockLocMovements.php:90 StockMovements.php:101 +#: SelectOrderItems.php:1299 StockLocMovements.php:90 StockMovements.php:101 #: StockStatus.php:311 includes/PDFQuotationPageHeader.inc:104 #: includes/PDFTransPageHeader.inc:206 msgid "Discount" @@ -3149,7 +3149,7 @@ #: OrderDetails.php:159 PDFCustTransListing.php:127 PDFOrdersInvoiced.php:389 #: PDFRemittanceAdvice.php:310 PDFSuppTransListing.php:127 #: RecurringSalesOrders.php:326 SelectCreditItems.php:658 -#: SelectCreditItems.php:662 SelectOrderItems.php:1301 SuppContractChgs.php:98 +#: SelectCreditItems.php:662 SelectOrderItems.php:1302 SuppContractChgs.php:98 #: SuppFixedAssetChgs.php:88 SupplierAllocations.php:466 #: SupplierAllocations.php:577 SupplierAllocations.php:647 #: SupplierCredit.php:389 SupplierCredit.php:421 SupplierCredit.php:456 @@ -3178,7 +3178,7 @@ #: ConfirmDispatch_Invoice.php:273 CounterSales.php:708 Credit_Invoice.php:280 #: Credit_Invoice.php:281 PrintCustTrans.php:335 PrintCustTrans.php:783 -#: PrintCustTransPortrait.php:456 PrintCustTransPortrait.php:999 +#: PrintCustTransPortrait.php:452 PrintCustTransPortrait.php:995 #: SelectCreditItems.php:660 SelectCreditItems.php:661 #: includes/PDFTaxPageHeader.inc:40 msgid "Tax" @@ -3721,7 +3721,7 @@ #: DeliveryDetails.php:586 DeliveryDetails.php:753 MRPReport.php:412 #: PDFOrdersInvoiced.php:301 PDFOrderStatus.php:268 #: SelectCompletedOrder.php:516 SelectContract.php:152 -#: SelectOrderItems.php:733 SelectProduct.php:356 Shipments.php:384 +#: SelectOrderItems.php:734 SelectProduct.php:356 Shipments.php:384 #: Shipments.php:462 SuppCreditGRNs.php:149 SuppCreditGRNs.php:227 #: SuppInvGRNs.php:278 TaxGroups.php:271 #: includes/PDFDeliveryDifferencesPageHeader.inc:41 @@ -3994,7 +3994,7 @@ #: PO_SelectOSPurchOrder.php:451 PO_SelectOSPurchOrder.php:479 #: PrintCustStatements.php:89 PrintCustStatements.php:431 #: PrintCustTrans.php:394 PrintCustTrans.php:415 -#: PrintCustTransPortrait.php:531 SelectSalesOrder.php:471 +#: PrintCustTransPortrait.php:527 SelectSalesOrder.php:471 msgid "Print" msgstr "Tisk" @@ -4065,7 +4065,7 @@ #: Contracts.php:97 DeliveryDetails.php:261 DeliveryDetails.php:270 #: EmailCustTrans.php:24 EmailCustTrans.php:28 GLAccountCSV.php:263 #: PO_Header.php:237 POReport.php:1404 SalesAnalysis_UserDefined.php:46 -#: SelectOrderItems.php:1145 StockQties_csv.php:46 StockUsage.php:24 +#: SelectOrderItems.php:1146 StockQties_csv.php:46 StockUsage.php:24 #: SupplierCredit.php:216 SupplierCredit.php:228 SupplierCredit.php:240 #: SupplierCredit.php:249 SupplierCredit.php:257 SupplierInvoice.php:193 #: SupplierInvoice.php:201 SupplierInvoice.php:209 SupplierInvoice.php:217 @@ -4077,7 +4077,7 @@ #: ContractBOM.php:43 ContractOtherReqts.php:45 Contracts.php:88 #: Contracts.php:97 DeliveryDetails.php:261 DeliveryDetails.php:270 #: PO_Header.php:237 SalesAnalysis_UserDefined.php:46 -#: SelectOrderItems.php:1145 StockUsage.php:24 SupplierCredit.php:216 +#: SelectOrderItems.php:1146 StockUsage.php:24 SupplierCredit.php:216 #: SupplierCredit.php:228 SupplierCredit.php:240 SupplierCredit.php:249 #: SupplierCredit.php:257 SupplierInvoice.php:193 SupplierInvoice.php:201 #: SupplierInvoice.php:209 SupplierInvoice.php:217 SupplierInvoice.php:225 @@ -4086,7 +4086,7 @@ msgstr "pro pokračování" #: ContractBOM.php:143 CounterSales.php:330 PO_Items.php:960 -#: SelectCreditItems.php:370 SelectOrderItems.php:855 SupplierTenders.php:469 +#: SelectCreditItems.php:370 SelectOrderItems.php:856 SupplierTenders.php:469 #: WorkOrderEntry.php:153 WorkOrderIssue.php:469 msgid "There is a problem selecting the part records to display because" msgstr "To je problém výběru část záznamy k zobrazení, protože" @@ -4132,7 +4132,7 @@ msgstr "SQL používá k načtení položky detaily, ale nepodařilo se" #: ContractBOM.php:213 CounterSales.php:425 PO_Items.php:679 -#: SelectOrderItems.php:949 includes/SelectOrderItems_IntoCart.inc:58 +#: SelectOrderItems.php:950 includes/SelectOrderItems_IntoCart.inc:58 #: includes/SelectOrderItems_IntoCart.inc:162 msgid "The item code" msgstr "Položku kód" @@ -4191,8 +4191,8 @@ #: ReorderLevel.php:217 ReorderLevel.php:219 SalesGraph.php:91 #: SalesGraph.php:93 SalesGraph.php:111 SalesGraph.php:113 SalesGraph.php:134 #: SalesGraph.php:136 SalesGraph.php:168 SalesInquiry.php:1060 -#: SalesInquiry.php:1103 SelectCreditItems.php:925 SelectOrderItems.php:1560 -#: SelectOrderItems.php:1563 SelectProduct.php:464 SelectProduct.php:466 +#: SalesInquiry.php:1103 SelectCreditItems.php:925 SelectOrderItems.php:1561 +#: SelectOrderItems.php:1564 SelectProduct.php:464 SelectProduct.php:466 #: StockDispatch.php:283 StockDispatch.php:285 StockLocStatus.php:62 #: StockLocStatus.php:64 StockLocStatus.php:82 StockLocStatus.php:86 #: StockLocStatus.php:90 SupplierTenders.php:337 SupplierTenders.php:339 @@ -4210,7 +4210,7 @@ #: ContractBOM.php:323 CounterSales.php:2138 PO_Items.php:1015 #: SelectCompletedOrder.php:450 SelectCreditItems.php:944 -#: SelectOrderItems.php:1588 SelectSalesOrder.php:184 SelectWorkOrder.php:173 +#: SelectOrderItems.php:1589 SelectSalesOrder.php:184 SelectWorkOrder.php:173 msgid "Enter extract of the Stock Code" msgstr "Zadejte extrakt skladem zákoníku" @@ -4225,7 +4225,7 @@ #: ContractBOM.php:368 CounterSales.php:2001 FixedAssetItems.php:459 #: FixedAssetItems.php:463 PO_Items.php:1062 SelectCreditItems.php:971 -#: SelectOrderItems.php:1448 SelectOrderItems.php:1627 Stocks.php:711 +#: SelectOrderItems.php:1449 SelectOrderItems.php:1628 Stocks.php:711 #: Stocks.php:715 SupplierTenders.php:517 WorkOrderEntry.php:618 #: WorkOrderIssue.php:676 msgid "No Image" @@ -4296,9 +4296,9 @@ #: CounterSales.php:703 DeliveryDetails.php:786 DeliveryDetails.php:851 #: OrderDetails.php:156 PO_Items.php:808 PrintCustTrans.php:651 #: PrintCustTrans.php:714 PrintCustTrans.php:752 -#: PrintCustTransPortrait.php:834 PrintCustTransPortrait.php:917 -#: PrintCustTransPortrait.php:961 RecurringSalesOrders.php:323 -#: SelectCreditItems.php:654 SelectOrderItems.php:1294 +#: PrintCustTransPortrait.php:830 PrintCustTransPortrait.php:913 +#: PrintCustTransPortrait.php:957 RecurringSalesOrders.php:323 +#: SelectCreditItems.php:654 SelectOrderItems.php:1295 #: includes/PDFTopItemsHeader.inc:57 includes/PO_PDFOrderPageHeader.inc:79 msgid "Unit" msgstr "Jednotkou" @@ -4550,7 +4550,7 @@ #: Contracts.php:87 Contracts.php:96 Customers.php:293 DeliveryDetails.php:261 #: DeliveryDetails.php:270 EmailCustTrans.php:24 PO_Header.php:236 -#: SelectOrderItems.php:1144 StockUsage.php:23 SupplierCredit.php:214 +#: SelectOrderItems.php:1145 StockUsage.php:23 SupplierCredit.php:214 #: SupplierCredit.php:226 SupplierCredit.php:238 SupplierCredit.php:248 #: SupplierCredit.php:256 SupplierInvoice.php:192 SupplierInvoice.php:200 #: SupplierInvoice.php:208 SupplierInvoice.php:216 SupplierInvoice.php:224 @@ -4813,7 +4813,7 @@ msgid "Go to quotation number:" msgstr "Přejít na nabídku číslo:" -#: Contracts.php:604 SelectOrderItems.php:294 +#: Contracts.php:604 SelectOrderItems.php:295 msgid "" "Customer Branch Name keywords have been used in preference to the Customer " "Branch Code or Branch Phone Number entered" @@ -4821,7 +4821,7 @@ "Zákazník Obor Název klíčová slova byla použita v preferenci k zákazníkovi " "Pobočka kódu nebo pobočky Telefon vstoupil" -#: Contracts.php:607 SelectOrderItems.php:297 +#: Contracts.php:607 SelectOrderItems.php:298 msgid "" "Customer Branch Code has been used in preference to the Customer Branch " "Phone Number entered" @@ -4829,7 +4829,7 @@ "Zákazník Pobočka Kód byl použit v preferenci k zákazníkovi pobočky telefonní " "číslo zadané" -#: Contracts.php:610 SelectOrderItems.php:300 +#: Contracts.php:610 SelectOrderItems.php:301 msgid "" "At least one Customer Branch Name keyword OR an extract of a Customer Branch " "Code or Branch Phone Number must be entered for the search" @@ -4838,23 +4838,23 @@ "zákazníka kódu nebo pobočky telefonní číslo musí být zapsány na vyhledávání" #: Contracts.php:665 CustomerReceipt.php:575 SelectCustomer.php:245 -#: SelectOrderItems.php:367 +#: SelectOrderItems.php:368 msgid "The searched customer records requested cannot be retrieved because" msgstr "Hledali záznamy zákazníků požadovaná nelze načíst, protože" -#: Contracts.php:672 SelectOrderItems.php:374 +#: Contracts.php:672 SelectOrderItems.php:375 msgid "No Customer Branch records contain the search criteria" msgstr "Zákazník žádné pobočky záznamy obsahují kritéria vyhledávání" -#: Contracts.php:672 SelectOrderItems.php:374 +#: Contracts.php:672 SelectOrderItems.php:375 msgid "please try again" msgstr "prosím zkuste to znovu" -#: Contracts.php:672 SelectOrderItems.php:374 +#: Contracts.php:672 SelectOrderItems.php:375 msgid "Note a Customer Branch Name may be different to the Customer Name" msgstr "Poznámka: Zákazník pobočka Název se může lišit Jméno zákazníka" -#: Contracts.php:685 SelectOrderItems.php:387 +#: Contracts.php:685 SelectOrderItems.php:388 #, fuzzy msgid "Unable to identify the selected customer" msgstr "Nelze určit segment tag" @@ -4866,9 +4866,9 @@ #: Contracts.php:716 CounterSales.php:112 CounterSales.php:147 #: CounterSales.php:2022 CounterSales.php:2200 DeliveryDetails.php:148 #: PO_Header.php:395 PO_Header.php:462 SelectCreditItems.php:136 -#: SelectCreditItems.php:174 SelectOrderItems.php:417 SelectOrderItems.php:463 -#: SelectOrderItems.php:536 SelectOrderItems.php:576 SelectOrderItems.php:1471 -#: SelectOrderItems.php:1654 SpecialOrder.php:59 SpecialOrder.php:82 +#: SelectCreditItems.php:174 SelectOrderItems.php:418 SelectOrderItems.php:464 +#: SelectOrderItems.php:537 SelectOrderItems.php:577 SelectOrderItems.php:1472 +#: SelectOrderItems.php:1655 SpecialOrder.php:59 SpecialOrder.php:82 #: StockCheck.php:222 StockLocStatus.php:172 StockLocStatus.php:196 #: StockLocStatus.php:232 StockStatus.php:120 StockStatus.php:144 #: StockStatus.php:164 StockStatus.php:186 StockStatus.php:203 @@ -4877,7 +4877,7 @@ msgstr "nelze načíst, protože" #: Contracts.php:717 CounterSales.php:113 SelectCreditItems.php:137 -#: SelectOrderItems.php:418 SpecialOrder.php:83 +#: SelectOrderItems.php:419 SpecialOrder.php:83 msgid "The SQL used to retrieve the customer details and failed was" msgstr "SQL slouží k získání údajů o zákaznících a neúspěšný byl" @@ -4890,20 +4890,20 @@ msgstr "SQL používá, že se nepodařilo získat zákazníka detaily o:" #: Contracts.php:735 CounterSales.php:181 SalesAnalRepts.php:165 -#: SalesAnalRepts.php:229 SelectOrderItems.php:424 SelectOrderItems.php:509 -#: SelectOrderItems.php:518 SpecialOrder.php:89 +#: SalesAnalRepts.php:229 SelectOrderItems.php:425 SelectOrderItems.php:510 +#: SelectOrderItems.php:519 SpecialOrder.php:89 msgid "The" msgstr "" -#: Contracts.php:735 CounterSales.php:181 SelectOrderItems.php:509 +#: Contracts.php:735 CounterSales.php:181 SelectOrderItems.php:510 msgid "account is currently at or over their credit limit" msgstr "účet je v současné době, nebo přes jejich úvěrového limitu" -#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:511 +#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:512 msgid "No more orders can be placed by" msgstr "Žádné další objednávky mohou být umístěny na" -#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:511 +#: Contracts.php:737 CounterSales.php:183 SelectOrderItems.php:512 msgid " their account is currently at or over their credit limit" msgstr "jejich účet je v současné době, nebo přes jejich úvěrového limitu" @@ -4911,20 +4911,20 @@ msgid "Contract: Select Customer" msgstr "Smlouvy: Vyberte zákazníky" -#: Contracts.php:756 SelectOrderItems.php:616 +#: Contracts.php:756 SelectOrderItems.php:617 msgid "Part of the Customer Branch Name" msgstr "Část Jméno zákazníka pobočky" -#: Contracts.php:759 SelectOrderItems.php:619 +#: Contracts.php:759 SelectOrderItems.php:620 msgid "Part of the Customer Branch Code" msgstr "Část kódu zákazníka pobočky" -#: Contracts.php:762 SelectOrderItems.php:622 +#: Contracts.php:762 SelectOrderItems.php:623 msgid "Part of the Branch Phone Number" msgstr "Část číslo pobočky telefonu" #: Contracts.php:767 Customers.php:610 Customers.php:1011 PO_Header.php:522 -#: SelectGLAccount.php:99 SelectOrderItems.php:627 +#: SelectGLAccount.php:99 SelectOrderItems.php:628 msgid "Reset" msgstr "Vymazat formulář" @@ -4932,8 +4932,8 @@ #: FTP_RadioBeacon.php:53 PDFOrdersInvoiced.php:303 PDFOrderStatus.php:270 #: PDFPriceList.php:356 PricesByCost.php:110 Prices_Customer.php:264 #: Prices_Customer.php:350 PrintCustTrans.php:610 -#: PrintCustTransPortrait.php:788 SelectCompletedOrder.php:518 -#: SelectCreditItems.php:223 SelectCustomer.php:458 SelectOrderItems.php:636 +#: PrintCustTransPortrait.php:784 SelectCompletedOrder.php:518 +#: SelectCreditItems.php:223 SelectCustomer.php:460 SelectOrderItems.php:637 #: SelectRecurringSalesOrder.php:80 SelectSalesOrder.php:422 #: SelectSalesOrder.php:433 StockMovements.php:99 #: StockSerialItemResearch.php:81 @@ -4945,13 +4945,13 @@ msgstr "Větev" #: Contracts.php:776 Factors.php:169 SelectCreditItems.php:224 -#: SelectCustomer.php:459 SelectOrderItems.php:637 SupplierContacts.php:212 +#: SelectCustomer.php:461 SelectOrderItems.php:638 SupplierContacts.php:212 msgid "Contact" msgstr "Kontakt" #: Contracts.php:778 EmailConfirmation.php:125 Factors.php:281 #: PDFCustomerList.php:344 PDFRemittanceAdvice.php:249 -#: SelectCreditItems.php:226 SelectCustomer.php:462 SelectOrderItems.php:639 +#: SelectCreditItems.php:226 SelectCustomer.php:464 SelectOrderItems.php:640 #: includes/PDFOrderPageHeader_generic.inc:32 #: includes/PDFPickingListHeader.inc:24 includes/PDFQuotationPageHeader.inc:23 #: includes/PDFSalesOrder_generic.inc:34 @@ -4963,7 +4963,7 @@ #: Contracts.php:827 CustomerInquiry.php:125 CustomerReceipt.php:900 #: PDFRemittanceAdvice.php:275 PO_Header.php:580 PrintCustTrans.php:637 -#: PrintCustTransPortrait.php:818 SupplierInquiry.php:119 +#: PrintCustTransPortrait.php:814 SupplierInquiry.php:119 #: includes/PDFStatementPageHeader.inc:116 includes/PDFTransPageHeader.inc:163 #: includes/PDFTransPageHeaderPortrait.inc:209 #: includes/PO_PDFOrderPageHeader.inc:72 @@ -5161,7 +5161,7 @@ "by měl být zadán pomocí kód zákazníka hypen pak větev kód zákazníka k " "použití." -#: CounterSales.php:112 SelectOrderItems.php:417 +#: CounterSales.php:112 SelectOrderItems.php:418 msgid "The details of the customer selected" msgstr "Podrobnosti o vybrané zákazníky" @@ -5176,34 +5176,34 @@ "pracovníky úvěrového řízení k projednání" #: CounterSales.php:147 DeliveryDetails.php:148 SelectCreditItems.php:174 -#: SelectOrderItems.php:463 SelectOrderItems.php:576 +#: SelectOrderItems.php:464 SelectOrderItems.php:577 msgid "The customer branch record of the customer selected" msgstr "Zákazník pobočka záznam vybrané zákazníky" #: CounterSales.php:148 DeliveryDetails.php:149 SelectCreditItems.php:175 -#: SelectOrderItems.php:464 SelectOrderItems.php:577 +#: SelectOrderItems.php:465 SelectOrderItems.php:578 msgid "SQL used to retrieve the branch details was" msgstr "SQL slouží k načtení informací větev byla" -#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:469 +#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:470 msgid "The branch details for branch code" msgstr "Podrobnosti pobočka pro obor kód" -#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:469 +#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:470 msgid "against customer code" msgstr "před kód zákazníka" #: CounterSales.php:153 DeliveryDetails.php:153 GLAccountCSV.php:183 #: GLAccountCSV.php:212 GLAccountInquiry.php:175 GLAccountInquiry.php:214 -#: GLAccountReport.php:114 GLAccountReport.php:146 SelectOrderItems.php:469 +#: GLAccountReport.php:114 GLAccountReport.php:146 SelectOrderItems.php:470 msgid "could not be retrieved" msgstr "se nepodařilo získat" -#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:469 +#: CounterSales.php:153 DeliveryDetails.php:153 SelectOrderItems.php:470 msgid "Check the set up of the customer and branch" msgstr "Zkontrolujte nastavení na zákazníka a pobočky" -#: CounterSales.php:156 DeliveryDetails.php:156 SelectOrderItems.php:472 +#: CounterSales.php:156 DeliveryDetails.php:156 SelectOrderItems.php:473 msgid "The SQL that failed to get the branch details was" msgstr "SQL, které se nepodařilo dostat pobočky podrobnosti byl" @@ -5242,58 +5242,58 @@ msgid "Item Code has been used in search" msgstr "Položka Kód byl použit při hledání" -#: CounterSales.php:225 SelectOrderItems.php:756 +#: CounterSales.php:225 SelectOrderItems.php:757 msgid "Stock Category has been used in search" msgstr "Skladem Kategorie byl použit při hledání" -#: CounterSales.php:331 SelectOrderItems.php:856 WorkOrderEntry.php:154 +#: CounterSales.php:331 SelectOrderItems.php:857 WorkOrderEntry.php:154 #: WorkOrderIssue.php:470 msgid "The SQL used to get the part selection was" msgstr "SQL používá k získání části Výběr byl" -#: CounterSales.php:335 SelectOrderItems.php:860 WorkOrderEntry.php:158 +#: CounterSales.php:335 SelectOrderItems.php:861 WorkOrderEntry.php:158 #: WorkOrderIssue.php:474 msgid "There are no products available meeting the criteria specified" msgstr "Nejsou žádné výrobky k dispozici splňují kritéria stanovená" -#: CounterSales.php:410 SelectOrderItems.php:934 SelectOrderItems.php:1108 +#: CounterSales.php:410 SelectOrderItems.php:935 SelectOrderItems.php:1109 msgid "An invalid date entry was made for " msgstr "Neplatné datum vstupu byla pro" -#: CounterSales.php:410 SelectOrderItems.php:934 SelectOrderItems.php:1108 +#: CounterSales.php:410 SelectOrderItems.php:935 SelectOrderItems.php:1109 msgid "The date entry" msgstr "Datum vstupu" -#: CounterSales.php:410 SelectOrderItems.php:934 SelectOrderItems.php:1108 +#: CounterSales.php:410 SelectOrderItems.php:935 SelectOrderItems.php:1109 msgid "must be in the format" msgstr "musí být ve formátu" #: CounterSales.php:419 CounterSales.php:522 CounterSales.php:566 -#: CounterSales.php:616 SelectOrderItems.php:943 SelectOrderItems.php:1157 -#: SelectOrderItems.php:1205 +#: CounterSales.php:616 SelectOrderItems.php:944 SelectOrderItems.php:1158 +#: SelectOrderItems.php:1206 msgid "" "Could not determine if the part being ordered was a kitset or not because" msgstr "Nepodařilo se určit, zda část je uložena byla kitset nebo ne, protože" -#: CounterSales.php:420 CounterSales.php:523 SelectOrderItems.php:944 +#: CounterSales.php:420 CounterSales.php:523 SelectOrderItems.php:945 msgid "" "The sql that was used to determine if the part being ordered was a kitset or " "not was " msgstr "" "Sql, který byl použit k určení, zda část je uložena byla kitset byl či nebyl" -#: Counter... [truncated message content] |
From: <dai...@us...> - 2011-02-18 09:56:59
|
Revision: 4492 http://web-erp.svn.sourceforge.net/web-erp/?rev=4492&view=rev Author: daintree Date: 2011-02-18 09:56:52 +0000 (Fri, 18 Feb 2011) Log Message: ----------- various Modified Paths: -------------- trunk/CompanyPreferences.php trunk/ConfirmDispatch_Invoice.php trunk/Credit_Invoice.php trunk/FixedAssetItems.php trunk/PO_Items.php trunk/SelectAsset.php trunk/SelectCreditItems.php trunk/Z_DeleteInvoice.php trunk/doc/Change.log.html trunk/includes/DefineCartClass.php Modified: trunk/CompanyPreferences.php =================================================================== --- trunk/CompanyPreferences.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/CompanyPreferences.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -456,7 +456,7 @@ echo '</select></td></tr>'; -echo '<tr><td>' . _('Create GL entries for stock transactions') . ' (' . _('at standard cost') . '):</td><td><select tabindex="25" Name=GLLink_Stock>'; +echo '<tr><td>' . _('Create GL entries for stock transactions') . '):</td><td><select tabindex="25" Name=GLLink_Stock>'; if ($_POST['GLLink_Stock']==0){ echo '<option selected VALUE=0>' . _('No'); Modified: trunk/ConfirmDispatch_Invoice.php =================================================================== --- trunk/ConfirmDispatch_Invoice.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/ConfirmDispatch_Invoice.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -336,7 +336,7 @@ $i=0; foreach ($_SESSION['Items']->LineItems[$LnItm->LineNumber]->Taxes AS $Tax) { if ($i>0){ - echo '<br>'; + echo '<br />'; } echo $Tax->TaxAuthDescription; $i++; @@ -353,7 +353,7 @@ $TaxTotals[$Tax->TaxAuthID]=0; } if ($i>0){ - echo '<br>'; + echo '<br />'; } if (isset($_POST['ProcessInvoice'])) { echo $Tax->TaxRate*100; Modified: trunk/Credit_Invoice.php =================================================================== --- trunk/Credit_Invoice.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/Credit_Invoice.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -1,5 +1,4 @@ <?php -/* $Revision: 1.35 $ */ /* $Id$*/ //$PageSecurity =3; @@ -1447,9 +1446,9 @@ echo '<div class="centre">'._('Credit Note number') . ' ' . $CreditNo . ' ' . _('has been processed'); if ($_SESSION['InvoicePortraitFormat']==0){ - echo "<br><a href='". $rootpath . "/PrintCustTrans.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; + echo "<br /><a href='". $rootpath . "/PrintCustTrans.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; } else { - echo "<br><a href='". $rootpath . "/PrintCustTransPortrait.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; + echo "<br /><a href='". $rootpath . "/PrintCustTransPortrait.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; } echo '</div>'; /*end of process credit note */ @@ -1462,19 +1461,19 @@ echo '<tr><td>' . _('Credit Note Type') . "</td><td><select tabindex=".$j." name=CreditType>"; if (!isset($_POST['CreditType']) OR $_POST['CreditType']=="Return"){ - echo "<option selected VALUE='Return'>" . _('Goods returned to store'); - echo "<option VALUE='WriteOff'>" . _('Goods written off'); - echo "<option VALUE='ReverseOverCharge'>" . _('Reverse overcharge'); + echo '<option selected value="Return">' . _('Goods returned to store') . '</option>'; + echo '<option VALUE="WriteOff">' . _('Goods written off') . '</option>'; + echo '<option VALUE="ReverseOverCharge">' . _('Reverse overcharge') . '</option>'; } elseif($_POST['CreditType']=='WriteOff') { - echo "<option selected VALUE='WriteOff'>" . _('Goods written off'); - echo "<option VALUE='Return'>" . _('Goods returned to store'); - echo "<option VALUE='ReverseOverCharge'>" . _('Reverse overcharge'); + echo '<option selected value="WriteOff">' . _('Goods written off') . '</option>'; + echo '<option VALUE="Return">' . _('Goods returned to store') . '</option>'; + echo '<option VALUE="ReverseOverCharge">' . _('Reverse overcharge') . '</option>'; } else { - echo "<option VALUE='WriteOff'>" . _('Goods written off'); - echo "<option VALUE='Return'>" . _('Goods returned to store'); - echo "<option selected VALUE='ReverseOverCharge'>" . _('Reverse overcharge'); + echo '<option VALUE="WriteOff">' . _('Goods written off') . '</option>'; + echo '<option VALUE="Return">' . _('Goods returned to store') . '</option>'; + echo '<option selected value="ReverseOverCharge">' . _('Reverse overcharge') . '</option>'; } - echo "</select></td></tr>"; + echo '</select></td></tr>'; $j++; if (!isset($_POST['CreditType']) OR $_POST['CreditType']=='Return'){ @@ -1483,7 +1482,7 @@ echo '<tr><td>' . _('Goods returned to location') . '</td><td><select tabindex='.$j.' name=Location>'; - $SQL="SELECT loccode, locationname FROM locations"; + $SQL='SELECT loccode, locationname FROM locations'; $Result = DB_query($SQL,$db); if (!isset($_POST['Location'])){ @@ -1504,23 +1503,23 @@ echo '<tr><td>' . _('Write off the cost of the goods to') . '</td><td><select TABINDEX='.$j.' name="WriteOffGLCode">'; - $SQL="SELECT accountcode, + $SQL='SELECT accountcode, accountname FROM chartmaster, accountgroups WHERE chartmaster.group_=accountgroups.groupname - AND accountgroups.pandl=1 ORDER BY chartmaster.accountcode"; + AND ccountgroups.pandl=1 ORDER BY chartmaster.accountcode'; $Result = DB_query($SQL,$db); while ($myrow = DB_fetch_array($Result)) { - if ($_POST['WriteOffGLCode']==$myrow["accountcode"]){ - echo "<option selected value=" . $myrow["accountcode"] . ">" . $myrow["accountname"]; + if ($_POST['WriteOffGLCode']==$myrow['accountcode']){ + echo '<option selected value=' . $myrow['accountcode'] . '>' . $myrow['accountname']. '</option>'; } else { - echo "<option value=" . $myrow["accountcode"] . ">" . $myrow["accountname"]; + echo '<option value=' . $myrow['accountcode'] . '>' . $myrow['accountname'] . '</option>'; } } - echo "</select></td></tr>"; + echo '</select></td></tr>'; } if (!isset($_POST['CreditText'])) { $_POST['CreditText'] = ''; @@ -1529,9 +1528,9 @@ echo '<tr><td>' . _('Credit note text') . '</td><td><textarea tabindex='.$j.' name=CreditText cols=31 rows=5>' . $_POST['CreditText'] . '</textarea></td></tr>'; echo '</table><br><div class="centre"><input TABINDEX='.$j.' type=submit name=Update Value=' . _('Update') . '><p>'; $j++; - echo "<input type=submit tabindex=".$j++." name='ProcessCredit' Value='" . _('Process Credit') ."'></div>"; + echo '<input type="submit" tabindex='.$j++.' name="ProcessCredit" Value="' . _('Process Credit') .'"></div>'; } -echo "</form>"; -include("includes/footer.inc"); +echo '</form>'; +include('includes/footer.inc'); ?> \ No newline at end of file Modified: trunk/FixedAssetItems.php =================================================================== --- trunk/FixedAssetItems.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/FixedAssetItems.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -101,6 +101,12 @@ $Errors[$i] = 'AssetCategoryID'; $i++; } + if (trim($_POST['AssetLocation'])==''){ + $InputError = 1; + prnMsg(_('There are no asset locations defined. All assets must belong to a valid location,'),'error'); + $Errors[$i] = 'AssetLocation'; + $i++; + } if (!is_numeric($_POST['DepnRate']) OR $_POST['DepnRate']>100 OR $_POST['DepnRate']<0){ $InputError = 1; prnMsg(_('The depreciation rate is expected to be a number between 0 and 100'),'error'); @@ -506,7 +512,7 @@ echo '<option value="' . $myrow['locationid'] .'">' . $myrow['locationdescription'] . '</option>'; } } -echo '</select></td></tr>'; +echo '</select><a target="_blank" href="'. $rootpath . '/FixedAssetLocations.php">'.' ' . _('Add Asset Location') . '</a></td></tr>'; echo '<tr><td>' . _('Bar Code') . ':</td><td><input ' . (in_array('BarCode',$Errors) ? 'class="inputerror"' : '' ) .' type="Text" name="BarCode" size=22 maxlength=20 value="' . $_POST['BarCode'] . '"></td></tr>'; Modified: trunk/PO_Items.php =================================================================== --- trunk/PO_Items.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/PO_Items.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -35,21 +35,21 @@ if (isset($_POST['UpdateLines']) OR isset($_POST['Commit'])) { foreach ($_SESSION['PO'.$identifier]->LineItems as $POLine) { if ($POLine->Deleted == false) { - if (!is_numeric($_POST['ConversionFactor'.$POLine->LineNo])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['ConversionFactor'.$POLine->LineNo])))){ prnMsg(_('The conversion factor is expected to be numeric - the figure which converts from our units to the supplier units. e.g. if the supplier units is a tonne and our unit is a kilogram then the conversion factor that converts our unit to the suppliers unit is 1000'),'error'); $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor = 1; } else { //a valid number for the conversion factor is entered - $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor = $_POST['ConversionFactor'.$POLine->LineNo]; + $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor = doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['ConversionFactor'.$POLine->LineNo])); } - if (!is_numeric($_POST['SuppQty'.$POLine->LineNo])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppQty'.$POLine->LineNo])))){ prnMsg(_('The quantity in the supplier units is expected to be numeric. Please re-enter as a number'),'error'); } else { //ok to update the PO object variables - $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Quantity=$_POST['SuppQty'.$POLine->LineNo]*$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor; + $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Quantity=doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppQty'.$POLine->LineNo]))*doubleval(str_replace($locale_info['thousands_sep'],'',$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor)); } - if (!is_numeric($_POST['SuppPrice'.$POLine->LineNo])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppPrice'.$POLine->LineNo])))){ prnMsg(_('The supplier price is expected to be numeric. Please re-enter as a number'),'error'); } else { //ok to update the PO object variables - $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Price=$_POST['SuppPrice'.$POLine->LineNo]/$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor; + $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Price=doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppPrice'.$POLine->LineNo]))/doubleval(str_replace($locale_info['thousands_sep'],'',$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor)); } $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->NetWeight=$_POST['NetWeight'.$POLine->LineNo]; $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ReqDelDate=$_POST['ReqDelDate'.$POLine->LineNo]; @@ -413,14 +413,14 @@ if ($_SESSION['PO'.$identifier]->AllowPrintPO==1 AND ($_SESSION['PO'.$identifier]->Status=='Authorised' OR $_SESSION['PO'.$identifier]->Status=='Printed')){ - echo '<br /><a target="_blank" href="'.$rootpath.'/PO_PDFPurchOrder.php?' . SID . '&OrderNo=' . $_SESSION['PO'.$identifier]->OrderNo . '">' . _('Print Purchase Order') . '</a>'; + echo '<br /><a target="_blank" href="'.$rootpath.'/PO_PDFPurchOrder.php?OrderNo=' . $_SESSION['PO'.$identifier]->OrderNo . '">' . _('Print Purchase Order') . '</a>'; } } /*end of if its a new order or an existing one */ $Result = DB_Txn_Commit($db); unset($_SESSION['PO'.$identifier]); /*Clear the PO data to allow a newy to be input*/ - echo '<br /><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">' . _('Return To PO List') . '</a>'; + echo '<br /><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php">' . _('Return To PO List') . '</a>'; include('includes/footer.inc'); exit; } /*end if there were no input errors trapped */ @@ -450,7 +450,7 @@ $AllowUpdate = false; prnMsg( _('Cannot Enter this order line') . '<br />' . _('The quantity of the ordered item entered must be a positive amount'),'error'); } - if (!is_numeric($_POST['Price'])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['Price'])))){ $AllowUpdate = false; prnMsg( _('Cannot Enter this order line') . '<br />' . _('The price entered must be numeric'),'error'); } @@ -518,6 +518,9 @@ if ($AllowUpdate == true){ //adding the non-stock item + $_POST['Price'] = doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['Price'])); + $_POST['Qty'] = doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['Qty'])); + $_SESSION['PO'.$identifier]->add_to_order ($_SESSION['PO'.$identifier]->LinesOnOrder+1, '', 0, /*Serialised */ @@ -549,7 +552,6 @@ $_POST['Qty'], ($_POST['Qty']*$_POST['Price']), $_POST['AssetID']); - include ('includes/PO_UnsetFormVbls.php'); } } Modified: trunk/SelectAsset.php =================================================================== --- trunk/SelectAsset.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/SelectAsset.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -171,6 +171,7 @@ $ErrMsg = _('No assets were returned by the SQL because'); $DbgMsg = _('The SQL that returned an error was'); $searchresult = DB_query($SQL, $db, $ErrMsg, $DbgMsg); + echo $SQL; if (DB_num_rows($searchresult) == 0) { prnMsg(_('No assets were returned by this search please re-enter alternative criteria to try again'), 'info'); Modified: trunk/SelectCreditItems.php =================================================================== --- trunk/SelectCreditItems.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/SelectCreditItems.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -72,7 +72,7 @@ //insert wildcard characters in spaces $SearchString = '%' . str_replace(' ', '%', $_POST['Keywords']) . '%'; - $SQL = 'SELECT + $SQL = "SELECT custbranch.debtorno, custbranch.brname, custbranch.contactname, @@ -80,7 +80,7 @@ custbranch.faxno, custbranch.branchcode FROM custbranch - WHERE custbranch.brname ' . LIKE ."'$SearchString' + WHERE custbranch.brname " . LIKE . "'" . $SearchString . "' AND custbranch.disabletrans=0"; } elseif (strlen($_POST['CustCode'])>0){ Modified: trunk/Z_DeleteInvoice.php =================================================================== --- trunk/Z_DeleteInvoice.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/Z_DeleteInvoice.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -132,7 +132,7 @@ echo '<br><br>'; /* Delete any GL Transaction records*/ -$SQL = "DELETE FROM gltrans WHERE type=10 AND transno='" . $_GET['InvoiceNo'] . "'"; +$SQL = "DELETE FROM gltrans WHERE gltrans.type=10 AND gltrans.typeno='" . $_GET['InvoiceNo'] . "'"; $ErrMsg = _('The SQL to delete the general ledger journal records failed because'); $Result = DB_query($SQL, $db,$ErrMsg,$DbgMsg,true); prnMsg(_('The GL journal records associated with the invoice have been deleted'),'info'); Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/doc/Change.log.html 2011-02-18 09:56:52 UTC (rev 4492) @@ -1,5 +1,11 @@ -<p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p +<p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p /> +<p>18/2/11: PO_Items.php make number_format variables turn back into numbers for > 1000</p> +<p>16/2/11: FixedAssetItems.php now checks for location before allowing additions</p> +<p>16/2/11: Company preferences - changed wording of stock integration at cost removed the word standard as suggested by Exson</p> +<p>16/2/11: SelectCreditItems.php formating/conventions lower case html and CreditInvoice.php</p> +<p>15/2/11: Phil Make invoicing warn the user when no taxes are defined for a tax group - i.e. there is a configuration error with taxes</p> +<p /> <p>15/2/11 Release 4.03RC2</p> <p /> <p>15/2/11: Phil UpgradeDatabase.php fix to upgrade from 4.01RC1 !!</p> Modified: trunk/includes/DefineCartClass.php =================================================================== --- trunk/includes/DefineCartClass.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/includes/DefineCartClass.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -341,15 +341,20 @@ $ErrMsg = _('The taxes and rates for this item could not be retrieved because'); $GetTaxRatesResult = DB_query($SQL,$db,$ErrMsg); unset($this->LineItems[$LineNumber]->Taxes); - while ($myrow = DB_fetch_array($GetTaxRatesResult)){ - - $this->LineItems[$LineNumber]->Taxes[$myrow['calculationorder']] = new Tax($myrow['calculationorder'], - $myrow['taxauthid'], - $myrow['description'], - $myrow['taxrate'], - $myrow['taxontax'], - $myrow['taxglcode']); - } + if (DB_num_rows($GetTaxRatesResult)==0){ + prnMsg(_('It appears that taxes are not defined correctly for this customer tax group') ,'error'); + } else { + + while ($myrow = DB_fetch_array($GetTaxRatesResult)){ + + $this->LineItems[$LineNumber]->Taxes[$myrow['calculationorder']] = new Tax($myrow['calculationorder'], + $myrow['taxauthid'], + $myrow['description'], + $myrow['taxrate'], + $myrow['taxontax'], + $myrow['taxglcode']); + } //end loop around different taxes + } //end if there are some taxes defined } //end method GetTaxes function GetFreightTaxes () { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-18 09:56:59
|
Revision: 4492 http://web-erp.svn.sourceforge.net/web-erp/?rev=4492&view=rev Author: daintree Date: 2011-02-18 09:56:52 +0000 (Fri, 18 Feb 2011) Log Message: ----------- various Modified Paths: -------------- trunk/CompanyPreferences.php trunk/ConfirmDispatch_Invoice.php trunk/Credit_Invoice.php trunk/FixedAssetItems.php trunk/PO_Items.php trunk/SelectAsset.php trunk/SelectCreditItems.php trunk/Z_DeleteInvoice.php trunk/doc/Change.log.html trunk/includes/DefineCartClass.php Modified: trunk/CompanyPreferences.php =================================================================== --- trunk/CompanyPreferences.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/CompanyPreferences.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -456,7 +456,7 @@ echo '</select></td></tr>'; -echo '<tr><td>' . _('Create GL entries for stock transactions') . ' (' . _('at standard cost') . '):</td><td><select tabindex="25" Name=GLLink_Stock>'; +echo '<tr><td>' . _('Create GL entries for stock transactions') . '):</td><td><select tabindex="25" Name=GLLink_Stock>'; if ($_POST['GLLink_Stock']==0){ echo '<option selected VALUE=0>' . _('No'); Modified: trunk/ConfirmDispatch_Invoice.php =================================================================== --- trunk/ConfirmDispatch_Invoice.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/ConfirmDispatch_Invoice.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -336,7 +336,7 @@ $i=0; foreach ($_SESSION['Items']->LineItems[$LnItm->LineNumber]->Taxes AS $Tax) { if ($i>0){ - echo '<br>'; + echo '<br />'; } echo $Tax->TaxAuthDescription; $i++; @@ -353,7 +353,7 @@ $TaxTotals[$Tax->TaxAuthID]=0; } if ($i>0){ - echo '<br>'; + echo '<br />'; } if (isset($_POST['ProcessInvoice'])) { echo $Tax->TaxRate*100; Modified: trunk/Credit_Invoice.php =================================================================== --- trunk/Credit_Invoice.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/Credit_Invoice.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -1,5 +1,4 @@ <?php -/* $Revision: 1.35 $ */ /* $Id$*/ //$PageSecurity =3; @@ -1447,9 +1446,9 @@ echo '<div class="centre">'._('Credit Note number') . ' ' . $CreditNo . ' ' . _('has been processed'); if ($_SESSION['InvoicePortraitFormat']==0){ - echo "<br><a href='". $rootpath . "/PrintCustTrans.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; + echo "<br /><a href='". $rootpath . "/PrintCustTrans.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; } else { - echo "<br><a href='". $rootpath . "/PrintCustTransPortrait.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; + echo "<br /><a href='". $rootpath . "/PrintCustTransPortrait.php?" . SID . "&FromTransNo=" . $CreditNo . "&InvOrCredit=Credit&PrintPDF=True'>" . _('Print this credit note') . '</a>'; } echo '</div>'; /*end of process credit note */ @@ -1462,19 +1461,19 @@ echo '<tr><td>' . _('Credit Note Type') . "</td><td><select tabindex=".$j." name=CreditType>"; if (!isset($_POST['CreditType']) OR $_POST['CreditType']=="Return"){ - echo "<option selected VALUE='Return'>" . _('Goods returned to store'); - echo "<option VALUE='WriteOff'>" . _('Goods written off'); - echo "<option VALUE='ReverseOverCharge'>" . _('Reverse overcharge'); + echo '<option selected value="Return">' . _('Goods returned to store') . '</option>'; + echo '<option VALUE="WriteOff">' . _('Goods written off') . '</option>'; + echo '<option VALUE="ReverseOverCharge">' . _('Reverse overcharge') . '</option>'; } elseif($_POST['CreditType']=='WriteOff') { - echo "<option selected VALUE='WriteOff'>" . _('Goods written off'); - echo "<option VALUE='Return'>" . _('Goods returned to store'); - echo "<option VALUE='ReverseOverCharge'>" . _('Reverse overcharge'); + echo '<option selected value="WriteOff">' . _('Goods written off') . '</option>'; + echo '<option VALUE="Return">' . _('Goods returned to store') . '</option>'; + echo '<option VALUE="ReverseOverCharge">' . _('Reverse overcharge') . '</option>'; } else { - echo "<option VALUE='WriteOff'>" . _('Goods written off'); - echo "<option VALUE='Return'>" . _('Goods returned to store'); - echo "<option selected VALUE='ReverseOverCharge'>" . _('Reverse overcharge'); + echo '<option VALUE="WriteOff">' . _('Goods written off') . '</option>'; + echo '<option VALUE="Return">' . _('Goods returned to store') . '</option>'; + echo '<option selected value="ReverseOverCharge">' . _('Reverse overcharge') . '</option>'; } - echo "</select></td></tr>"; + echo '</select></td></tr>'; $j++; if (!isset($_POST['CreditType']) OR $_POST['CreditType']=='Return'){ @@ -1483,7 +1482,7 @@ echo '<tr><td>' . _('Goods returned to location') . '</td><td><select tabindex='.$j.' name=Location>'; - $SQL="SELECT loccode, locationname FROM locations"; + $SQL='SELECT loccode, locationname FROM locations'; $Result = DB_query($SQL,$db); if (!isset($_POST['Location'])){ @@ -1504,23 +1503,23 @@ echo '<tr><td>' . _('Write off the cost of the goods to') . '</td><td><select TABINDEX='.$j.' name="WriteOffGLCode">'; - $SQL="SELECT accountcode, + $SQL='SELECT accountcode, accountname FROM chartmaster, accountgroups WHERE chartmaster.group_=accountgroups.groupname - AND accountgroups.pandl=1 ORDER BY chartmaster.accountcode"; + AND ccountgroups.pandl=1 ORDER BY chartmaster.accountcode'; $Result = DB_query($SQL,$db); while ($myrow = DB_fetch_array($Result)) { - if ($_POST['WriteOffGLCode']==$myrow["accountcode"]){ - echo "<option selected value=" . $myrow["accountcode"] . ">" . $myrow["accountname"]; + if ($_POST['WriteOffGLCode']==$myrow['accountcode']){ + echo '<option selected value=' . $myrow['accountcode'] . '>' . $myrow['accountname']. '</option>'; } else { - echo "<option value=" . $myrow["accountcode"] . ">" . $myrow["accountname"]; + echo '<option value=' . $myrow['accountcode'] . '>' . $myrow['accountname'] . '</option>'; } } - echo "</select></td></tr>"; + echo '</select></td></tr>'; } if (!isset($_POST['CreditText'])) { $_POST['CreditText'] = ''; @@ -1529,9 +1528,9 @@ echo '<tr><td>' . _('Credit note text') . '</td><td><textarea tabindex='.$j.' name=CreditText cols=31 rows=5>' . $_POST['CreditText'] . '</textarea></td></tr>'; echo '</table><br><div class="centre"><input TABINDEX='.$j.' type=submit name=Update Value=' . _('Update') . '><p>'; $j++; - echo "<input type=submit tabindex=".$j++." name='ProcessCredit' Value='" . _('Process Credit') ."'></div>"; + echo '<input type="submit" tabindex='.$j++.' name="ProcessCredit" Value="' . _('Process Credit') .'"></div>'; } -echo "</form>"; -include("includes/footer.inc"); +echo '</form>'; +include('includes/footer.inc'); ?> \ No newline at end of file Modified: trunk/FixedAssetItems.php =================================================================== --- trunk/FixedAssetItems.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/FixedAssetItems.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -101,6 +101,12 @@ $Errors[$i] = 'AssetCategoryID'; $i++; } + if (trim($_POST['AssetLocation'])==''){ + $InputError = 1; + prnMsg(_('There are no asset locations defined. All assets must belong to a valid location,'),'error'); + $Errors[$i] = 'AssetLocation'; + $i++; + } if (!is_numeric($_POST['DepnRate']) OR $_POST['DepnRate']>100 OR $_POST['DepnRate']<0){ $InputError = 1; prnMsg(_('The depreciation rate is expected to be a number between 0 and 100'),'error'); @@ -506,7 +512,7 @@ echo '<option value="' . $myrow['locationid'] .'">' . $myrow['locationdescription'] . '</option>'; } } -echo '</select></td></tr>'; +echo '</select><a target="_blank" href="'. $rootpath . '/FixedAssetLocations.php">'.' ' . _('Add Asset Location') . '</a></td></tr>'; echo '<tr><td>' . _('Bar Code') . ':</td><td><input ' . (in_array('BarCode',$Errors) ? 'class="inputerror"' : '' ) .' type="Text" name="BarCode" size=22 maxlength=20 value="' . $_POST['BarCode'] . '"></td></tr>'; Modified: trunk/PO_Items.php =================================================================== --- trunk/PO_Items.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/PO_Items.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -35,21 +35,21 @@ if (isset($_POST['UpdateLines']) OR isset($_POST['Commit'])) { foreach ($_SESSION['PO'.$identifier]->LineItems as $POLine) { if ($POLine->Deleted == false) { - if (!is_numeric($_POST['ConversionFactor'.$POLine->LineNo])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['ConversionFactor'.$POLine->LineNo])))){ prnMsg(_('The conversion factor is expected to be numeric - the figure which converts from our units to the supplier units. e.g. if the supplier units is a tonne and our unit is a kilogram then the conversion factor that converts our unit to the suppliers unit is 1000'),'error'); $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor = 1; } else { //a valid number for the conversion factor is entered - $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor = $_POST['ConversionFactor'.$POLine->LineNo]; + $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor = doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['ConversionFactor'.$POLine->LineNo])); } - if (!is_numeric($_POST['SuppQty'.$POLine->LineNo])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppQty'.$POLine->LineNo])))){ prnMsg(_('The quantity in the supplier units is expected to be numeric. Please re-enter as a number'),'error'); } else { //ok to update the PO object variables - $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Quantity=$_POST['SuppQty'.$POLine->LineNo]*$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor; + $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Quantity=doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppQty'.$POLine->LineNo]))*doubleval(str_replace($locale_info['thousands_sep'],'',$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor)); } - if (!is_numeric($_POST['SuppPrice'.$POLine->LineNo])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppPrice'.$POLine->LineNo])))){ prnMsg(_('The supplier price is expected to be numeric. Please re-enter as a number'),'error'); } else { //ok to update the PO object variables - $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Price=$_POST['SuppPrice'.$POLine->LineNo]/$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor; + $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->Price=doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['SuppPrice'.$POLine->LineNo]))/doubleval(str_replace($locale_info['thousands_sep'],'',$_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ConversionFactor)); } $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->NetWeight=$_POST['NetWeight'.$POLine->LineNo]; $_SESSION['PO'.$identifier]->LineItems[$POLine->LineNo]->ReqDelDate=$_POST['ReqDelDate'.$POLine->LineNo]; @@ -413,14 +413,14 @@ if ($_SESSION['PO'.$identifier]->AllowPrintPO==1 AND ($_SESSION['PO'.$identifier]->Status=='Authorised' OR $_SESSION['PO'.$identifier]->Status=='Printed')){ - echo '<br /><a target="_blank" href="'.$rootpath.'/PO_PDFPurchOrder.php?' . SID . '&OrderNo=' . $_SESSION['PO'.$identifier]->OrderNo . '">' . _('Print Purchase Order') . '</a>'; + echo '<br /><a target="_blank" href="'.$rootpath.'/PO_PDFPurchOrder.php?OrderNo=' . $_SESSION['PO'.$identifier]->OrderNo . '">' . _('Print Purchase Order') . '</a>'; } } /*end of if its a new order or an existing one */ $Result = DB_Txn_Commit($db); unset($_SESSION['PO'.$identifier]); /*Clear the PO data to allow a newy to be input*/ - echo '<br /><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php?' . SID . '">' . _('Return To PO List') . '</a>'; + echo '<br /><a href="' . $rootpath . '/PO_SelectOSPurchOrder.php">' . _('Return To PO List') . '</a>'; include('includes/footer.inc'); exit; } /*end if there were no input errors trapped */ @@ -450,7 +450,7 @@ $AllowUpdate = false; prnMsg( _('Cannot Enter this order line') . '<br />' . _('The quantity of the ordered item entered must be a positive amount'),'error'); } - if (!is_numeric($_POST['Price'])){ + if (!is_numeric(doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['Price'])))){ $AllowUpdate = false; prnMsg( _('Cannot Enter this order line') . '<br />' . _('The price entered must be numeric'),'error'); } @@ -518,6 +518,9 @@ if ($AllowUpdate == true){ //adding the non-stock item + $_POST['Price'] = doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['Price'])); + $_POST['Qty'] = doubleval(str_replace($locale_info['thousands_sep'],'',$_POST['Qty'])); + $_SESSION['PO'.$identifier]->add_to_order ($_SESSION['PO'.$identifier]->LinesOnOrder+1, '', 0, /*Serialised */ @@ -549,7 +552,6 @@ $_POST['Qty'], ($_POST['Qty']*$_POST['Price']), $_POST['AssetID']); - include ('includes/PO_UnsetFormVbls.php'); } } Modified: trunk/SelectAsset.php =================================================================== --- trunk/SelectAsset.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/SelectAsset.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -171,6 +171,7 @@ $ErrMsg = _('No assets were returned by the SQL because'); $DbgMsg = _('The SQL that returned an error was'); $searchresult = DB_query($SQL, $db, $ErrMsg, $DbgMsg); + echo $SQL; if (DB_num_rows($searchresult) == 0) { prnMsg(_('No assets were returned by this search please re-enter alternative criteria to try again'), 'info'); Modified: trunk/SelectCreditItems.php =================================================================== --- trunk/SelectCreditItems.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/SelectCreditItems.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -72,7 +72,7 @@ //insert wildcard characters in spaces $SearchString = '%' . str_replace(' ', '%', $_POST['Keywords']) . '%'; - $SQL = 'SELECT + $SQL = "SELECT custbranch.debtorno, custbranch.brname, custbranch.contactname, @@ -80,7 +80,7 @@ custbranch.faxno, custbranch.branchcode FROM custbranch - WHERE custbranch.brname ' . LIKE ."'$SearchString' + WHERE custbranch.brname " . LIKE . "'" . $SearchString . "' AND custbranch.disabletrans=0"; } elseif (strlen($_POST['CustCode'])>0){ Modified: trunk/Z_DeleteInvoice.php =================================================================== --- trunk/Z_DeleteInvoice.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/Z_DeleteInvoice.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -132,7 +132,7 @@ echo '<br><br>'; /* Delete any GL Transaction records*/ -$SQL = "DELETE FROM gltrans WHERE type=10 AND transno='" . $_GET['InvoiceNo'] . "'"; +$SQL = "DELETE FROM gltrans WHERE gltrans.type=10 AND gltrans.typeno='" . $_GET['InvoiceNo'] . "'"; $ErrMsg = _('The SQL to delete the general ledger journal records failed because'); $Result = DB_query($SQL, $db,$ErrMsg,$DbgMsg,true); prnMsg(_('The GL journal records associated with the invoice have been deleted'),'info'); Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/doc/Change.log.html 2011-02-18 09:56:52 UTC (rev 4492) @@ -1,5 +1,11 @@ -<p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p +<p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p /> +<p>18/2/11: PO_Items.php make number_format variables turn back into numbers for > 1000</p> +<p>16/2/11: FixedAssetItems.php now checks for location before allowing additions</p> +<p>16/2/11: Company preferences - changed wording of stock integration at cost removed the word standard as suggested by Exson</p> +<p>16/2/11: SelectCreditItems.php formating/conventions lower case html and CreditInvoice.php</p> +<p>15/2/11: Phil Make invoicing warn the user when no taxes are defined for a tax group - i.e. there is a configuration error with taxes</p> +<p /> <p>15/2/11 Release 4.03RC2</p> <p /> <p>15/2/11: Phil UpgradeDatabase.php fix to upgrade from 4.01RC1 !!</p> Modified: trunk/includes/DefineCartClass.php =================================================================== --- trunk/includes/DefineCartClass.php 2011-02-15 06:31:08 UTC (rev 4491) +++ trunk/includes/DefineCartClass.php 2011-02-18 09:56:52 UTC (rev 4492) @@ -341,15 +341,20 @@ $ErrMsg = _('The taxes and rates for this item could not be retrieved because'); $GetTaxRatesResult = DB_query($SQL,$db,$ErrMsg); unset($this->LineItems[$LineNumber]->Taxes); - while ($myrow = DB_fetch_array($GetTaxRatesResult)){ - - $this->LineItems[$LineNumber]->Taxes[$myrow['calculationorder']] = new Tax($myrow['calculationorder'], - $myrow['taxauthid'], - $myrow['description'], - $myrow['taxrate'], - $myrow['taxontax'], - $myrow['taxglcode']); - } + if (DB_num_rows($GetTaxRatesResult)==0){ + prnMsg(_('It appears that taxes are not defined correctly for this customer tax group') ,'error'); + } else { + + while ($myrow = DB_fetch_array($GetTaxRatesResult)){ + + $this->LineItems[$LineNumber]->Taxes[$myrow['calculationorder']] = new Tax($myrow['calculationorder'], + $myrow['taxauthid'], + $myrow['description'], + $myrow['taxrate'], + $myrow['taxontax'], + $myrow['taxglcode']); + } //end loop around different taxes + } //end if there are some taxes defined } //end method GetTaxes function GetFreightTaxes () { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-18 21:41:20
|
Revision: 4493 http://web-erp.svn.sourceforge.net/web-erp/?rev=4493&view=rev Author: daintree Date: 2011-02-18 21:41:14 +0000 (Fri, 18 Feb 2011) Log Message: ----------- Changed PageSecurityArray to avoid problems with register_globals Modified Paths: -------------- trunk/doc/Change.log.html trunk/includes/GetConfig.php trunk/includes/session.inc Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-18 09:56:52 UTC (rev 4492) +++ trunk/doc/Change.log.html 2011-02-18 21:41:14 UTC (rev 4493) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> -<p /> +<p> +<p>18/2/11: Phil/Don Change PageSecurity array variable name to PageSecurityArray - caused problems with conflict with PageSecurity variable where register_globals = on; </p> <p>18/2/11: PO_Items.php make number_format variables turn back into numbers for > 1000</p> <p>16/2/11: FixedAssetItems.php now checks for location before allowing additions</p> <p>16/2/11: Company preferences - changed wording of stock integration at cost removed the word standard as suggested by Exson</p> Modified: trunk/includes/GetConfig.php =================================================================== --- trunk/includes/GetConfig.php 2011-02-18 09:56:52 UTC (rev 4492) +++ trunk/includes/GetConfig.php 2011-02-18 21:41:14 UTC (rev 4493) @@ -31,9 +31,9 @@ if (DB_error_no($db)!=0){ // the table may not exist with the pagesecurity field in it if it is an older webERP database header('Location: UpgradeDatabase.php'); //divert to the db upgrade if the VersionNumber is not in the config table } - //Populate the PageSecurity array for each script's PageSecurity value + //Populate the PageSecurityArray array for each script's PageSecurity value while ($myrow=DB_fetch_array($result)) { - $_SESSION['PageSecurity'][$myrow['script']]=$myrow['pagesecurity']; + $_SESSION['PageSecurityArray'][$myrow['script']]=$myrow['pagesecurity']; } Modified: trunk/includes/session.inc =================================================================== --- trunk/includes/session.inc 2011-02-18 09:56:52 UTC (rev 4492) +++ trunk/includes/session.inc 2011-02-18 21:41:14 UTC (rev 4493) @@ -115,12 +115,12 @@ /*User is logged in so get configuration parameters - save in session*/ include($PathPrefix . 'includes/GetConfig.php'); -/*The page security variable is now retrieved from the database in GetConfig.php and stored in the $SESSION['PageSecurity'] array +/*The page security variable is now retrieved from the database in GetConfig.php and stored in the $SESSION['PageSecurityArray'] array * the key for the array is the script name - the script name is retrieved from the basename ($_SERVER['SCRIPT_NAME']) */ if (!isset($PageSecurity)){ //only hardcoded in the UpgradeDatabase script - so old versions that don't have the scripts.pagesecurity field do not choke - $PageSecurity = $_SESSION['PageSecurity'][basename($_SERVER['SCRIPT_NAME'])]; + $PageSecurity = $_SESSION['PageSecurityArray'][basename($_SERVER['SCRIPT_NAME'])]; } /*If the Code $Version - held in ConnectDB.inc is > than the Database VersionNumber held in config table then do upgrades */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-18 21:41:20
|
Revision: 4493 http://web-erp.svn.sourceforge.net/web-erp/?rev=4493&view=rev Author: daintree Date: 2011-02-18 21:41:14 +0000 (Fri, 18 Feb 2011) Log Message: ----------- Changed PageSecurityArray to avoid problems with register_globals Modified Paths: -------------- trunk/doc/Change.log.html trunk/includes/GetConfig.php trunk/includes/session.inc Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-18 09:56:52 UTC (rev 4492) +++ trunk/doc/Change.log.html 2011-02-18 21:41:14 UTC (rev 4493) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> -<p /> +<p> +<p>18/2/11: Phil/Don Change PageSecurity array variable name to PageSecurityArray - caused problems with conflict with PageSecurity variable where register_globals = on; </p> <p>18/2/11: PO_Items.php make number_format variables turn back into numbers for > 1000</p> <p>16/2/11: FixedAssetItems.php now checks for location before allowing additions</p> <p>16/2/11: Company preferences - changed wording of stock integration at cost removed the word standard as suggested by Exson</p> Modified: trunk/includes/GetConfig.php =================================================================== --- trunk/includes/GetConfig.php 2011-02-18 09:56:52 UTC (rev 4492) +++ trunk/includes/GetConfig.php 2011-02-18 21:41:14 UTC (rev 4493) @@ -31,9 +31,9 @@ if (DB_error_no($db)!=0){ // the table may not exist with the pagesecurity field in it if it is an older webERP database header('Location: UpgradeDatabase.php'); //divert to the db upgrade if the VersionNumber is not in the config table } - //Populate the PageSecurity array for each script's PageSecurity value + //Populate the PageSecurityArray array for each script's PageSecurity value while ($myrow=DB_fetch_array($result)) { - $_SESSION['PageSecurity'][$myrow['script']]=$myrow['pagesecurity']; + $_SESSION['PageSecurityArray'][$myrow['script']]=$myrow['pagesecurity']; } Modified: trunk/includes/session.inc =================================================================== --- trunk/includes/session.inc 2011-02-18 09:56:52 UTC (rev 4492) +++ trunk/includes/session.inc 2011-02-18 21:41:14 UTC (rev 4493) @@ -115,12 +115,12 @@ /*User is logged in so get configuration parameters - save in session*/ include($PathPrefix . 'includes/GetConfig.php'); -/*The page security variable is now retrieved from the database in GetConfig.php and stored in the $SESSION['PageSecurity'] array +/*The page security variable is now retrieved from the database in GetConfig.php and stored in the $SESSION['PageSecurityArray'] array * the key for the array is the script name - the script name is retrieved from the basename ($_SERVER['SCRIPT_NAME']) */ if (!isset($PageSecurity)){ //only hardcoded in the UpgradeDatabase script - so old versions that don't have the scripts.pagesecurity field do not choke - $PageSecurity = $_SESSION['PageSecurity'][basename($_SERVER['SCRIPT_NAME'])]; + $PageSecurity = $_SESSION['PageSecurityArray'][basename($_SERVER['SCRIPT_NAME'])]; } /*If the Code $Version - held in ConnectDB.inc is > than the Database VersionNumber held in config table then do upgrades */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-22 09:45:08
|
Revision: 4495 http://web-erp.svn.sourceforge.net/web-erp/?rev=4495&view=rev Author: daintree Date: 2011-02-22 09:45:01 +0000 (Tue, 22 Feb 2011) Log Message: ----------- PDF Languages in www_users - PDFTopItems rework - change PageSecurity array name to PageSecurityArray to avoid register globals issue Modified Paths: -------------- trunk/PDFTopItems.php trunk/TopItems.php trunk/UserSettings.php trunk/WWW_Users.php trunk/doc/Change.log.html trunk/doc/Manual/ManualCurrencies.html trunk/doc/Manual/ManualSecuritySchema.html trunk/includes/PDFTopItemsHeader.inc trunk/includes/class.pdf.php Modified: trunk/PDFTopItems.php =================================================================== --- trunk/PDFTopItems.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/PDFTopItems.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -1,7 +1,7 @@ <?php /* $Revision: 1.2 $ */ /* $Id$*/ -//$PageSecurity = 2; + include ('includes/session.inc'); include ('includes/PDFStarter.php'); $FontSize = 10; @@ -10,79 +10,78 @@ $line_height = 12; include ('includes/PDFTopItemsHeader.inc'); $FontSize = 10; -$FromDate = FormatDateForSQL(DateAdd(Date($_SESSION['DefaultDateFormat']),'d', -$_POST['NumberOfDays'])); +$FromDate = FormatDateForSQL(DateAdd(Date($_SESSION['DefaultDateFormat']),'d', -$_GET['NumberOfDays'])); //the situation if the location and customer type selected "All" -if (($_GET["location"] == "All") and ($_GET["customers"] == "All")) { +if (($_GET['Location'] == 'All') and ($_GET['Customers'] == 'All')) { $SQL = "SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND salesorderdetails.ActualDispatchDate >='" . $FromDate . "' + AND salesorderdetails.actualdispatchdate >='" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC - LIMIT 0," . $_GET['NumberOfTopItems'] ; + ORDER BY '" . $_GET['Sequence'] . "' DESC + LIMIT " . $_GET['NumberOfTopItems'] ; } else { //the situation if only location type selected "All" - if ($_GET["location"] == "All") { + if ($_GET['Location'] == 'All') { $SQL = "SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND debtorsmaster.typeid = '" . $_GET["customers"] . "' + AND debtorsmaster.typeid = '" . $_GET['Customers'] . "' AND salesorderdetails.ActualDispatchDate >= '" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC - LIMIT 0," . $_GET['NumberOfTopItems']; + ORDER BY '" . $_GET['Sequence'] . "' DESC + LIMIT " . $_GET['NumberOfTopItems']; } else { //the situation if the customer type selected "All" - if ($_GET["customers"] == "All") { - $SQL = " - SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + if ($_GET['Customers'] == 'All') { + $SQL = "SELECT salesorderdetails.stkcode, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND salesorders.fromstkloc = '" . $_GET['location'] . "' + AND salesorders.fromstkloc = '" . $_GET['Location'] . "' AND salesorderdetails.ActualDispatchDate >= '" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC + ORDER BY '" . $_GET['Sequence'] . "' DESC LIMIT 0," . $_GET['NumberOfTopItems']; } else { //the situation if the location and customer type not selected "All" - $SQL = " - SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + $SQL = "SELECT salesorderdetails.stkcode, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND salesorders.fromstkloc = '" . $_GET['location'] . "' - AND debtorsmaster.typeid = '" . $_GET['customers'] . "' - AND salesorderdetails.ActualDispatchDate >= '" . $FromDate . "' + AND salesorders.fromstkloc = '" . $_GET['Location'] . "' + AND debtorsmaster.typeid = '" . $_GET['Customers'] . "' + AND salesorderdetails.actualdispatchdate >= '" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC - LIMIT 0," . $_GET['NumberOfTopItems']; + ORDER BY '" . $_GET['Sequence'] . "' DESC + LIMIT " . $_GET['NumberOfTopItems']; } } } $result = DB_query($SQL, $db); + $YPos = $YPos - 6; while ($myrow = DB_fetch_array($result)) { //find the quantity onhand item @@ -91,18 +90,12 @@ WHERE stockid='" . $myrow['0'] . "'"; $oh = db_query($sqloh, $db); $ohRow = db_fetch_row($oh); - $OnHand = $ohRow[0]; - $ValueSales = number_format($myrow['2'], 2); - $Code = $myrow['0']; //stkcode - $Desc = $myrow['3']; //desc - $TotalInvoice = $myrow['1']; //total invoice here - $Unit = $myrow['4']; //unit - $LeftOvers = $pdf->addTextWrap($Left_Margin + 1, $YPos, 300 - $Left_Margin, $FontSize, $Code); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 100, $YPos, 270 - $Left_Margin, $FontSize, $Desc); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 330, $YPos, 30, $FontSize, $TotalInvoice, 'right'); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 370, $YPos, 300 - $Left_Margin, $FontSize, $Unit, 'left'); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 400, $YPos, 70, $FontSize, $ValueSales, 'right'); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 490, $YPos, 30, $FontSize, $OnHand, 'right'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 1, $YPos, 300 - $Left_Margin, $FontSize, $myrow['stkcode']); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 100, $YPos, 270 - $Left_Margin, $FontSize, $myrow['description']); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 330, $YPos, 30, $FontSize, $myrow['totalinvoiced'], 'right'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 370, $YPos, 300 - $Left_Margin, $FontSize, $myrow['units'], 'left'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 400, $YPos, 70, $FontSize, number_format($myrow['valuesales'], 2), 'right'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 490, $YPos, 30, $FontSize, $ohRow[0], 'right'); if (strlen($LeftOvers) > 1) { $LeftOvers = $pdf->addTextWrap($Left_Margin + 1 + 94, $YPos - $line_height, 270, $FontSize, $LeftOvers, 'left'); $YPos-= $line_height; @@ -122,7 +115,7 @@ $title = _('Print Price List Error'); include ('includes/header.inc'); prnMsg(_('There were no records returned '), 'warn'); - echo '<br><a href="' . $rootpath . '/index.php?' . SID . '">' . _('Back to the menu') . '</a>'; + echo '<br><a href="' . $rootpath . '/index.php">' . _('Back to the menu') . '</a>'; include ('includes/footer.inc'); exit; } else { Modified: trunk/TopItems.php =================================================================== --- trunk/TopItems.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/TopItems.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -7,11 +7,7 @@ $title = _('Top Items Searching'); include ('includes/header.inc'); //check if input already -if (!(isset($_POST['Location']) - AND isset($_POST['NumberOfDays']) - AND isset($_POST['Customers']) - AND isset($_POST['NumberOfTopItems']) - AND isset($_POST['Sequence']))) { +if (!(isset($_POST['Search']))) { echo '<p class="page_title_text"><img src="' . $rootpath . '/css/' . $theme . '/images/magnifier.png" title="' . _('Top Sales Order Search') . '" alt="" />' . ' ' . _('Top Sales Order Search') . '</p>'; echo "<form action=" . $_SERVER['PHP_SELF'] . '?' . SID . ' name="SelectCustomer" method=POST>'; @@ -44,8 +40,8 @@ echo '<tr> <td width="150">' . _('Select Order By ') . ' </td> <td>:</td> <td><select name="Sequence">'; - echo ' <option value=TotalInvoiced>' . _('Total Pieces') . ''; - echo ' <option value=ValueSales>' . _('Value of Sales') . ''; + echo ' <option value="TotalInvoiced">' . _('Total Pieces') . ''; + echo ' <option value="ValueSales">' . _('Value of Sales') . ''; echo ' </select></td> </tr>'; //View number of days @@ -61,8 +57,10 @@ <td></td> <td></td> </tr> - </form></table>'; - echo '<br /><div class=centre><input tabindex=5 type=submit value="' . _('Search') . '"></div>'; + </table> + <br /><div class=centre> + <input tabindex=5 type=submit name="Search" value="' . _('Search') . '"> + </div></form>'; } else { // everything below here to view NumberOfTopItems items sale on selected location $FromDate = FormatDateForSQL(DateAdd(Date($_SESSION['DefaultDateFormat']),'d', -$_POST['NumberOfDays'])); @@ -153,31 +151,32 @@ } } $result = DB_query($SQL, $db); + echo '<p class="page_title_text" align="center"><strong>' . _('Top Sales Items List') . '</strong></p>'; - echo "<form action=PDFTopItems.php method='GET'><table class='selection'>"; + echo '<form action="PDFTopItems.php" method="GET"><table class="selection">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - $TableHeader = '<tr><th><strong>' . _('#') . '</strong></th> - <th><strong>' . _('Code') . '</strong></th> - <th><strong>' . _('Description') . '</strong></th> - <th><strong>' . _('Total Invoiced') . '</strong></th> - <th><strong>' . _('Units') . '</strong></th> - <th><strong>' . _('Value Sales') . '</strong></th> - <th><strong>' . _('On Hand') . '</strong></th>'; + $TableHeader = '<tr><th>' . _('#') . '</th> + <th>' . _('Code') . '</th> + <th>' . _('Description') . '</th> + <th>' . _('Total Invoiced') . '</th> + <th>' . _('Units') . '</th> + <th>' . _('Value Sales') . '</th> + <th>' . _('On Hand') . '</th>'; echo $TableHeader; echo ' - <input type="hidden" value=' . $_POST['Location'] . ' name=location /> - <input type="hidden" value=' . $_POST['Sequence'] . ' name=Sequence /> - <input type="hidden" value=' . $_POST['NumberOfDays'] . ' name=numberofdays /> - <input type="hidden" value=' . $_POST['Customers'] . ' name=customers /> - <input type="hidden" value=' . $_POST['NumberOfTopItems'] . ' name=NumberOfTopItems /> + <input type="hidden" value=' . $_POST['Location'] . ' name="Location" /> + <input type="hidden" value=' . $_POST['Sequence'] . ' name="Sequence" /> + <input type="hidden" value=' . $_POST['NumberOfDays'] . ' name="NumberOfDays" /> + <input type="hidden" value=' . $_POST['Customers'] . ' name="Customers" /> + <input type="hidden" value=' . $_POST['NumberOfTopItems'] . ' name="NumberOfTopItems" /> '; $k = 0; //row colour counter $i = 1; while ($myrow = DB_fetch_array($result)) { //find the quantity onhand item $sqloh = "SELECT sum(quantity)as qty - FROM `locstock` - WHERE stockid='" . $myrow['0'] . "'"; + FROM `locstock` + WHERE stockid='" . $myrow['0'] . "'"; $oh = db_query($sqloh, $db); $ohRow = db_fetch_row($oh); if ($k == 1) { @@ -194,19 +193,20 @@ <td>%s</td> <td class="number">%s</td> <td class="number">%s</td> - </tr>', $i, $myrow['0'], $myrow['3'], $myrow['1'], //total invoice here - $myrow['4'], //unit - number_format($myrow['2']/$myrow['5'],2), //value sales here - number_format($ohRow[0], $myrow['7']) //on hand - ); - $i+= 1; + </tr>', + $i, + $myrow['0'], + $myrow['3'], + $myrow['1'], //total invoice here + $myrow['4'], //unit + number_format($myrow['2']/$myrow['5'],2), //value sales here + number_format($ohRow[0], $myrow['7']) //on hand + ); + $i++; } echo '</table>'; - // echo '<td style="text-align:center" colspan=6><a href="javascript:history.go(-1)" title="Return to previous page"><input type=Button Name="Back" Value="' . _('Back') . '"></a></font>   '; echo '<br /><div class="centre"><input type=Submit Name="PrintPDF" Value="' . _('Print To PDF') . '"></div>'; echo '</form>'; - //end of the else statement - } include ('includes/footer.inc'); ?> \ No newline at end of file Modified: trunk/UserSettings.php =================================================================== --- trunk/UserSettings.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/UserSettings.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -2,8 +2,6 @@ /* $Id$*/ -//$PageSecurity=1; - include('includes/session.inc'); $title = _('User Settings'); include('includes/header.inc'); @@ -93,7 +91,7 @@ $_SESSION['Theme'] = trim($_POST['Theme']); /*already set by session.inc but for completeness */ $theme = $_SESSION['Theme']; $_SESSION['Language'] = trim($_POST['Language']); - + $_SESSION['PDFLanguage'] = $_POST['PDFLanguage']; include ('includes/LanguageSetup.php'); } @@ -137,9 +135,9 @@ AND $LanguageEntry!='.'){ if ($_SESSION['Language'] == $LanguageEntry){ - 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>'; } } } @@ -159,9 +157,9 @@ if (is_dir("css/$ThemeName") AND $ThemeName != '.' AND $ThemeName != '..' AND $ThemeName != '.svn'){ if ($_SESSION['Theme'] == $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>'; } } } @@ -190,11 +188,11 @@ echo "<td><input type=text name='email' size=40 value='" . $_POST['email'] . "'></td></tr>"; if (!isset($_POST['PDFLanguage'])){ - $_POST['PDFLanguage']=0; + $_POST['PDFLanguage']=$_SESSION['PDFLanguage']; } echo '<tr><td>' . _('PDF Language Support') . ': </td><td><select name="PDFLanguage">'; -for($i=0;$i<=7;$i++){ +for($i=0;$i<count($PDFLanguages);$i++){ if ($_POST['PDFLanguage']==$i){ echo '<option selected value=' . $i .'>' . $PDFLanguages[$i] . '</option>'; } else { Modified: trunk/WWW_Users.php =================================================================== --- trunk/WWW_Users.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/WWW_Users.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -23,13 +23,8 @@ _('Setup')); $PDFLanguages = array(_('Latin Western Languages'), - _('Eastern European Russian Japanese'), - _('Chinese'), - _('Korean'), - _('Vietnamese'), - _('Hebrew'), - _('Arabic'), - _('Thai')); + _('Eastern European Russian Japanese Korean Vietnamese Hebrew Arabic Thai'), + _('Chinese')); $title = _('User Maintenance'); include('includes/header.inc'); @@ -620,7 +615,7 @@ } echo '<tr><td>' . _('PDF Language Support') . ': </td><td><select name="PDFLanguage">'; -for($i=0;$i<=7;$i++){ +for($i=0;$i<count($PDFLanguages);$i++){ if ($_POST['PDFLanguage']==$i){ echo '<option selected value=' . $i .'>' . $PDFLanguages[$i] . '</option>'; } else { Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/doc/Change.log.html 2011-02-22 09:45:01 UTC (rev 4495) @@ -1,5 +1,7 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> +<p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> <p>18/2/11: Phil/Don Change PageSecurity array variable name to PageSecurityArray - caused problems with conflict with PageSecurity variable where register_globals = on; </p> <p>18/2/11: PO_Items.php make number_format variables turn back into numbers for > 1000</p> <p>16/2/11: FixedAssetItems.php now checks for location before allowing additions</p> Modified: trunk/doc/Manual/ManualCurrencies.html =================================================================== --- trunk/doc/Manual/ManualCurrencies.html 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/doc/Manual/ManualCurrencies.html 2011-02-22 09:45:01 UTC (rev 4495) @@ -5,7 +5,7 @@ <br><br> Any number of currencies can be defined in webERP. Every currency that is transacted with either in sales (AR) or purchasing (AP) needs to be defined in the system. To define currencies go to the Setup tab -> General -> Currency Maintenance. Only a few fields are required to be completed for each currency defined: <ul> -<li>The ISO 4217 code for the currency - this is the international standard 3 character code that is used worldwide to represent the currency. If the code entered exists then it is possible for webERP to retrieve exchange rates from either the European Central Bank. webERP is capable of updating exchange rates daily from the ECB if set to do so under Setup->Configuration. +<li>The ISO 4217 code for the currency - this is the international standard 3 character code that is used worldwide to represent the currency. If the code entered exists then it is possible for webERP to retrieve exchange rates from either the European Central Bank or Oanda.com, if there is no rate maintained for the currency at the ECB. webERP is capable of updating exchange rates daily from the ECB if set to do so under Setup->Configuration ->Auto Update Exchange Rates Daily. If this is set to yes, then when the first user logs in for the day the exchange rates are updated automatically. If it is set to no then exchange rates will only be updated if the user does so manually. </li> <li>The name of the currency can be any description that describes the currency</li> <lI>The country of the currency can be entered</li> Modified: trunk/doc/Manual/ManualSecuritySchema.html =================================================================== --- trunk/doc/Manual/ManualSecuritySchema.html 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/doc/Manual/ManualSecuritySchema.html 2011-02-22 09:45:01 UTC (rev 4495) @@ -35,12 +35,9 @@ <br> </li><li> PageSecurity values:<br> -Each webERP page includes a Page Security value from 1 to 15.<br> -This is hard coded into each page; for example: $PageSecurity = 1;<br> -For user access Page Security values correspond to 'Security Token' values.<br> +Each webERP page is given a Page Security value from 1 to 15 in the table scripts. The system reads all the scripts and the PageSecurity value for each into a SESSION array - $_SESSION['PageSecurityArray'] - the key for each element is the script name and the value is the PageSecurity value for that script. The key - the script name is retrieved from the $_SERVER['SCRIPT_NAME'] variable. In this way every time a script is called, the PageSecurity is retrieved from the array. +++<br> -There is no webERP tool to change PageSecurity values.<br> -However, an administrator can edit the pages directly.<br> +There is a webERP tool to change PageSecurity values, for each script which is accessible from the Setup menu.<br> <br></ol> These parts work together as follows. The user name and password combination entered at log on enables the system to identify the 'Security Role' for the User. @@ -52,13 +49,11 @@ <u>A more comprehensive description of the security scheme follows:</u><br> <br> Each webERP page (script) is assigned a specific PageSecurity value. -This page security value is hard coded inside each script. At the time -of writing this is a number between 1 and 15. If more levels of security +This page security value is stored in the scripts table of the database and read into a SESSION array on login (from the GetConfig.php script). At the time of writing this is a number between 1 and 15. If more levels of security are necessary then this can be expanded by an administrator or developer. -The default PageSecurity values for each page are set out in the table -below.<br> +The default PageSecurity values for each page can be inspected by browsing the scripts table<br> <br> -The user is allowed access to a page if the PageSecurity value of the page +The user is allowed access to a page if the PageSecurity value of the page/script is a number contained in the SESSION AllowedPageSecurityTokens array as determined from the users access level (Security Role). The user access level Security Role) is an integer that represents the Security Role assigned to the user in the user set up page @@ -84,7 +79,7 @@ Tokens assigned to each Security Role the security access can be tailored for all users. When making these changes reference the default values in the tables below. PageSecurity values must also be known. -The value of the default settings can be modified as needed.<br> +The value of the default settings can be modified as needed from the Page Security script accessible from the Setup module<br> <br> <u>Security Scheme Tables:</u><br> <br> Modified: trunk/includes/PDFTopItemsHeader.inc =================================================================== --- trunk/includes/PDFTopItemsHeader.inc 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/includes/PDFTopItemsHeader.inc 2011-02-22 09:45:01 UTC (rev 4495) @@ -10,29 +10,24 @@ $XPos=0; $pdf->addJpegFromFile('companies/' . $_SESSION['DatabaseName'] . '/logo.jpg',$XPos+20,$YPos-50,0,60); -if ($_GET["customers"]!='All'){ -$SQL="SELECT typename - FROM `debtortype` - WHERE typeid=".$_GET["customers"].""; - -$result = DB_query($SQL,$db); -$myrow=DB_fetch_array($result); -$Customers=$myrow["0"]; +if ($_GET['Customers']!='All'){ + $SQL="SELECT typename + FROM `debtortype` + WHERE typeid='".$_GET['Customers']."'"; + + $result = DB_query($SQL,$db); + $myrow=DB_fetch_array($result); + $Customers=$myrow["0"]; }else{ -$Customers="All"; + $Customers='All'; } -//searching condition -$infoa=_('Search On Location')." : ".$_GET["location"].""; -$infob=_('Customers'). " : ".$Customers.""; -$infoc=_('Number Of Days')." : ".$_GET["numberofdays"]." "; -$infod=_('Number Of Items')." : ".$_GET['NumberOfTopItems'].""; -$infoe=_('Order By')." : ".$_GET['order'].""; - //Display the searching condition -$pdf->addTextWrap($XPos+40,$YPos-70,500,9,$infoa); $pdf->addTextWrap($XPos+240,$YPos-70,500,9,$infob); -$pdf->addTextWrap($XPos+40,$YPos-90,500,9,$infoc); $pdf->addTextWrap($XPos+240,$YPos-90,500,9,$infod); -$pdf->addTextWrap($XPos+40,$YPos-110,500,9,$infoe); +$pdf->addTextWrap($XPos+40,$YPos-70,500,9,_('Search On Location').' : '.$_GET['Location']); +$pdf->addTextWrap($XPos+240,$YPos-70,500,9,_('Customers'). ' : '.$Customers); +$pdf->addTextWrap($XPos+40,$YPos-90,500,9,_('Number Of Days')." : ".$_GET['NumberOfDays']." "); +$pdf->addTextWrap($XPos+240,$YPos-90,500,9,_('Number Of Items')." : ".$_GET['NumberOfTopItems']); +$pdf->addTextWrap($XPos+40,$YPos-110,500,9,_('Order By')." : ".$_GET['Sequence']); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-140,$YPos,300,$FontSize,$_SESSION['CompanyRecord']['coyname']); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-140,$YPos-($line_height*1.5),550,$FontSize, _('Top Items Sales Search Result') ); @@ -63,6 +58,4 @@ $pdf->Rectangle($Left_Margin, $YPos-$line_height,$Page_Width-$Left_Margin-$Right_Margin,$YPos-$Bottom_Margin); $YPos -= (1.5 * $line_height); -//$PageNumber++; - ?> \ No newline at end of file Modified: trunk/includes/class.pdf.php =================================================================== --- trunk/includes/class.pdf.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/includes/class.pdf.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -39,9 +39,15 @@ $UserPdfLang = $_SESSION['PDFLanguage']; switch ($UserPdfLang) { - case 0: $UserPdfFont = 'times'; break; - case 1: $UserPdfFont = 'javierjp'; break; - case 2: $UserPdfFont = 'javiergb'; break; + case 0: + $UserPdfFont = 'times'; + break; + case 1: + $UserPdfFont = 'javierjp'; + break; + case 2: + $UserPdfFont = 'javiergb'; + break; } } else { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-22 09:45:11
|
Revision: 4495 http://web-erp.svn.sourceforge.net/web-erp/?rev=4495&view=rev Author: daintree Date: 2011-02-22 09:45:01 +0000 (Tue, 22 Feb 2011) Log Message: ----------- PDF Languages in www_users - PDFTopItems rework - change PageSecurity array name to PageSecurityArray to avoid register globals issue Modified Paths: -------------- trunk/PDFTopItems.php trunk/TopItems.php trunk/UserSettings.php trunk/WWW_Users.php trunk/doc/Change.log.html trunk/doc/Manual/ManualCurrencies.html trunk/doc/Manual/ManualSecuritySchema.html trunk/includes/PDFTopItemsHeader.inc trunk/includes/class.pdf.php Modified: trunk/PDFTopItems.php =================================================================== --- trunk/PDFTopItems.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/PDFTopItems.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -1,7 +1,7 @@ <?php /* $Revision: 1.2 $ */ /* $Id$*/ -//$PageSecurity = 2; + include ('includes/session.inc'); include ('includes/PDFStarter.php'); $FontSize = 10; @@ -10,79 +10,78 @@ $line_height = 12; include ('includes/PDFTopItemsHeader.inc'); $FontSize = 10; -$FromDate = FormatDateForSQL(DateAdd(Date($_SESSION['DefaultDateFormat']),'d', -$_POST['NumberOfDays'])); +$FromDate = FormatDateForSQL(DateAdd(Date($_SESSION['DefaultDateFormat']),'d', -$_GET['NumberOfDays'])); //the situation if the location and customer type selected "All" -if (($_GET["location"] == "All") and ($_GET["customers"] == "All")) { +if (($_GET['Location'] == 'All') and ($_GET['Customers'] == 'All')) { $SQL = "SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND salesorderdetails.ActualDispatchDate >='" . $FromDate . "' + AND salesorderdetails.actualdispatchdate >='" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC - LIMIT 0," . $_GET['NumberOfTopItems'] ; + ORDER BY '" . $_GET['Sequence'] . "' DESC + LIMIT " . $_GET['NumberOfTopItems'] ; } else { //the situation if only location type selected "All" - if ($_GET["location"] == "All") { + if ($_GET['Location'] == 'All') { $SQL = "SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND debtorsmaster.typeid = '" . $_GET["customers"] . "' + AND debtorsmaster.typeid = '" . $_GET['Customers'] . "' AND salesorderdetails.ActualDispatchDate >= '" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC - LIMIT 0," . $_GET['NumberOfTopItems']; + ORDER BY '" . $_GET['Sequence'] . "' DESC + LIMIT " . $_GET['NumberOfTopItems']; } else { //the situation if the customer type selected "All" - if ($_GET["customers"] == "All") { - $SQL = " - SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + if ($_GET['Customers'] == 'All') { + $SQL = "SELECT salesorderdetails.stkcode, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND salesorders.fromstkloc = '" . $_GET['location'] . "' + AND salesorders.fromstkloc = '" . $_GET['Location'] . "' AND salesorderdetails.ActualDispatchDate >= '" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC + ORDER BY '" . $_GET['Sequence'] . "' DESC LIMIT 0," . $_GET['NumberOfTopItems']; } else { //the situation if the location and customer type not selected "All" - $SQL = " - SELECT salesorderdetails.stkcode, - SUM(salesorderdetails.qtyinvoiced) TotalInvoiced, - SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS ValueSales, + $SQL = "SELECT salesorderdetails.stkcode, + SUM(salesorderdetails.qtyinvoiced) totalinvoiced, + SUM(salesorderdetails.qtyinvoiced * salesorderdetails.unitprice ) AS valuesales, stockmaster.description, stockmaster.units FROM salesorderdetails, salesorders, debtorsmaster,stockmaster WHERE salesorderdetails.orderno = salesorders.orderno AND salesorderdetails.stkcode = stockmaster.stockid AND salesorders.debtorno = debtorsmaster.debtorno - AND salesorders.fromstkloc = '" . $_GET['location'] . "' - AND debtorsmaster.typeid = '" . $_GET['customers'] . "' - AND salesorderdetails.ActualDispatchDate >= '" . $FromDate . "' + AND salesorders.fromstkloc = '" . $_GET['Location'] . "' + AND debtorsmaster.typeid = '" . $_GET['Customers'] . "' + AND salesorderdetails.actualdispatchdate >= '" . $FromDate . "' GROUP BY salesorderdetails.stkcode - ORDER BY '" . $_GET['order'] . "' DESC - LIMIT 0," . $_GET['NumberOfTopItems']; + ORDER BY '" . $_GET['Sequence'] . "' DESC + LIMIT " . $_GET['NumberOfTopItems']; } } } $result = DB_query($SQL, $db); + $YPos = $YPos - 6; while ($myrow = DB_fetch_array($result)) { //find the quantity onhand item @@ -91,18 +90,12 @@ WHERE stockid='" . $myrow['0'] . "'"; $oh = db_query($sqloh, $db); $ohRow = db_fetch_row($oh); - $OnHand = $ohRow[0]; - $ValueSales = number_format($myrow['2'], 2); - $Code = $myrow['0']; //stkcode - $Desc = $myrow['3']; //desc - $TotalInvoice = $myrow['1']; //total invoice here - $Unit = $myrow['4']; //unit - $LeftOvers = $pdf->addTextWrap($Left_Margin + 1, $YPos, 300 - $Left_Margin, $FontSize, $Code); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 100, $YPos, 270 - $Left_Margin, $FontSize, $Desc); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 330, $YPos, 30, $FontSize, $TotalInvoice, 'right'); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 370, $YPos, 300 - $Left_Margin, $FontSize, $Unit, 'left'); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 400, $YPos, 70, $FontSize, $ValueSales, 'right'); - $LeftOvers = $pdf->addTextWrap($Left_Margin + 490, $YPos, 30, $FontSize, $OnHand, 'right'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 1, $YPos, 300 - $Left_Margin, $FontSize, $myrow['stkcode']); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 100, $YPos, 270 - $Left_Margin, $FontSize, $myrow['description']); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 330, $YPos, 30, $FontSize, $myrow['totalinvoiced'], 'right'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 370, $YPos, 300 - $Left_Margin, $FontSize, $myrow['units'], 'left'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 400, $YPos, 70, $FontSize, number_format($myrow['valuesales'], 2), 'right'); + $LeftOvers = $pdf->addTextWrap($Left_Margin + 490, $YPos, 30, $FontSize, $ohRow[0], 'right'); if (strlen($LeftOvers) > 1) { $LeftOvers = $pdf->addTextWrap($Left_Margin + 1 + 94, $YPos - $line_height, 270, $FontSize, $LeftOvers, 'left'); $YPos-= $line_height; @@ -122,7 +115,7 @@ $title = _('Print Price List Error'); include ('includes/header.inc'); prnMsg(_('There were no records returned '), 'warn'); - echo '<br><a href="' . $rootpath . '/index.php?' . SID . '">' . _('Back to the menu') . '</a>'; + echo '<br><a href="' . $rootpath . '/index.php">' . _('Back to the menu') . '</a>'; include ('includes/footer.inc'); exit; } else { Modified: trunk/TopItems.php =================================================================== --- trunk/TopItems.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/TopItems.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -7,11 +7,7 @@ $title = _('Top Items Searching'); include ('includes/header.inc'); //check if input already -if (!(isset($_POST['Location']) - AND isset($_POST['NumberOfDays']) - AND isset($_POST['Customers']) - AND isset($_POST['NumberOfTopItems']) - AND isset($_POST['Sequence']))) { +if (!(isset($_POST['Search']))) { echo '<p class="page_title_text"><img src="' . $rootpath . '/css/' . $theme . '/images/magnifier.png" title="' . _('Top Sales Order Search') . '" alt="" />' . ' ' . _('Top Sales Order Search') . '</p>'; echo "<form action=" . $_SERVER['PHP_SELF'] . '?' . SID . ' name="SelectCustomer" method=POST>'; @@ -44,8 +40,8 @@ echo '<tr> <td width="150">' . _('Select Order By ') . ' </td> <td>:</td> <td><select name="Sequence">'; - echo ' <option value=TotalInvoiced>' . _('Total Pieces') . ''; - echo ' <option value=ValueSales>' . _('Value of Sales') . ''; + echo ' <option value="TotalInvoiced">' . _('Total Pieces') . ''; + echo ' <option value="ValueSales">' . _('Value of Sales') . ''; echo ' </select></td> </tr>'; //View number of days @@ -61,8 +57,10 @@ <td></td> <td></td> </tr> - </form></table>'; - echo '<br /><div class=centre><input tabindex=5 type=submit value="' . _('Search') . '"></div>'; + </table> + <br /><div class=centre> + <input tabindex=5 type=submit name="Search" value="' . _('Search') . '"> + </div></form>'; } else { // everything below here to view NumberOfTopItems items sale on selected location $FromDate = FormatDateForSQL(DateAdd(Date($_SESSION['DefaultDateFormat']),'d', -$_POST['NumberOfDays'])); @@ -153,31 +151,32 @@ } } $result = DB_query($SQL, $db); + echo '<p class="page_title_text" align="center"><strong>' . _('Top Sales Items List') . '</strong></p>'; - echo "<form action=PDFTopItems.php method='GET'><table class='selection'>"; + echo '<form action="PDFTopItems.php" method="GET"><table class="selection">'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - $TableHeader = '<tr><th><strong>' . _('#') . '</strong></th> - <th><strong>' . _('Code') . '</strong></th> - <th><strong>' . _('Description') . '</strong></th> - <th><strong>' . _('Total Invoiced') . '</strong></th> - <th><strong>' . _('Units') . '</strong></th> - <th><strong>' . _('Value Sales') . '</strong></th> - <th><strong>' . _('On Hand') . '</strong></th>'; + $TableHeader = '<tr><th>' . _('#') . '</th> + <th>' . _('Code') . '</th> + <th>' . _('Description') . '</th> + <th>' . _('Total Invoiced') . '</th> + <th>' . _('Units') . '</th> + <th>' . _('Value Sales') . '</th> + <th>' . _('On Hand') . '</th>'; echo $TableHeader; echo ' - <input type="hidden" value=' . $_POST['Location'] . ' name=location /> - <input type="hidden" value=' . $_POST['Sequence'] . ' name=Sequence /> - <input type="hidden" value=' . $_POST['NumberOfDays'] . ' name=numberofdays /> - <input type="hidden" value=' . $_POST['Customers'] . ' name=customers /> - <input type="hidden" value=' . $_POST['NumberOfTopItems'] . ' name=NumberOfTopItems /> + <input type="hidden" value=' . $_POST['Location'] . ' name="Location" /> + <input type="hidden" value=' . $_POST['Sequence'] . ' name="Sequence" /> + <input type="hidden" value=' . $_POST['NumberOfDays'] . ' name="NumberOfDays" /> + <input type="hidden" value=' . $_POST['Customers'] . ' name="Customers" /> + <input type="hidden" value=' . $_POST['NumberOfTopItems'] . ' name="NumberOfTopItems" /> '; $k = 0; //row colour counter $i = 1; while ($myrow = DB_fetch_array($result)) { //find the quantity onhand item $sqloh = "SELECT sum(quantity)as qty - FROM `locstock` - WHERE stockid='" . $myrow['0'] . "'"; + FROM `locstock` + WHERE stockid='" . $myrow['0'] . "'"; $oh = db_query($sqloh, $db); $ohRow = db_fetch_row($oh); if ($k == 1) { @@ -194,19 +193,20 @@ <td>%s</td> <td class="number">%s</td> <td class="number">%s</td> - </tr>', $i, $myrow['0'], $myrow['3'], $myrow['1'], //total invoice here - $myrow['4'], //unit - number_format($myrow['2']/$myrow['5'],2), //value sales here - number_format($ohRow[0], $myrow['7']) //on hand - ); - $i+= 1; + </tr>', + $i, + $myrow['0'], + $myrow['3'], + $myrow['1'], //total invoice here + $myrow['4'], //unit + number_format($myrow['2']/$myrow['5'],2), //value sales here + number_format($ohRow[0], $myrow['7']) //on hand + ); + $i++; } echo '</table>'; - // echo '<td style="text-align:center" colspan=6><a href="javascript:history.go(-1)" title="Return to previous page"><input type=Button Name="Back" Value="' . _('Back') . '"></a></font>   '; echo '<br /><div class="centre"><input type=Submit Name="PrintPDF" Value="' . _('Print To PDF') . '"></div>'; echo '</form>'; - //end of the else statement - } include ('includes/footer.inc'); ?> \ No newline at end of file Modified: trunk/UserSettings.php =================================================================== --- trunk/UserSettings.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/UserSettings.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -2,8 +2,6 @@ /* $Id$*/ -//$PageSecurity=1; - include('includes/session.inc'); $title = _('User Settings'); include('includes/header.inc'); @@ -93,7 +91,7 @@ $_SESSION['Theme'] = trim($_POST['Theme']); /*already set by session.inc but for completeness */ $theme = $_SESSION['Theme']; $_SESSION['Language'] = trim($_POST['Language']); - + $_SESSION['PDFLanguage'] = $_POST['PDFLanguage']; include ('includes/LanguageSetup.php'); } @@ -137,9 +135,9 @@ AND $LanguageEntry!='.'){ if ($_SESSION['Language'] == $LanguageEntry){ - 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>'; } } } @@ -159,9 +157,9 @@ if (is_dir("css/$ThemeName") AND $ThemeName != '.' AND $ThemeName != '..' AND $ThemeName != '.svn'){ if ($_SESSION['Theme'] == $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>'; } } } @@ -190,11 +188,11 @@ echo "<td><input type=text name='email' size=40 value='" . $_POST['email'] . "'></td></tr>"; if (!isset($_POST['PDFLanguage'])){ - $_POST['PDFLanguage']=0; + $_POST['PDFLanguage']=$_SESSION['PDFLanguage']; } echo '<tr><td>' . _('PDF Language Support') . ': </td><td><select name="PDFLanguage">'; -for($i=0;$i<=7;$i++){ +for($i=0;$i<count($PDFLanguages);$i++){ if ($_POST['PDFLanguage']==$i){ echo '<option selected value=' . $i .'>' . $PDFLanguages[$i] . '</option>'; } else { Modified: trunk/WWW_Users.php =================================================================== --- trunk/WWW_Users.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/WWW_Users.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -23,13 +23,8 @@ _('Setup')); $PDFLanguages = array(_('Latin Western Languages'), - _('Eastern European Russian Japanese'), - _('Chinese'), - _('Korean'), - _('Vietnamese'), - _('Hebrew'), - _('Arabic'), - _('Thai')); + _('Eastern European Russian Japanese Korean Vietnamese Hebrew Arabic Thai'), + _('Chinese')); $title = _('User Maintenance'); include('includes/header.inc'); @@ -620,7 +615,7 @@ } echo '<tr><td>' . _('PDF Language Support') . ': </td><td><select name="PDFLanguage">'; -for($i=0;$i<=7;$i++){ +for($i=0;$i<count($PDFLanguages);$i++){ if ($_POST['PDFLanguage']==$i){ echo '<option selected value=' . $i .'>' . $PDFLanguages[$i] . '</option>'; } else { Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/doc/Change.log.html 2011-02-22 09:45:01 UTC (rev 4495) @@ -1,5 +1,7 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> +<p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> <p>18/2/11: Phil/Don Change PageSecurity array variable name to PageSecurityArray - caused problems with conflict with PageSecurity variable where register_globals = on; </p> <p>18/2/11: PO_Items.php make number_format variables turn back into numbers for > 1000</p> <p>16/2/11: FixedAssetItems.php now checks for location before allowing additions</p> Modified: trunk/doc/Manual/ManualCurrencies.html =================================================================== --- trunk/doc/Manual/ManualCurrencies.html 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/doc/Manual/ManualCurrencies.html 2011-02-22 09:45:01 UTC (rev 4495) @@ -5,7 +5,7 @@ <br><br> Any number of currencies can be defined in webERP. Every currency that is transacted with either in sales (AR) or purchasing (AP) needs to be defined in the system. To define currencies go to the Setup tab -> General -> Currency Maintenance. Only a few fields are required to be completed for each currency defined: <ul> -<li>The ISO 4217 code for the currency - this is the international standard 3 character code that is used worldwide to represent the currency. If the code entered exists then it is possible for webERP to retrieve exchange rates from either the European Central Bank. webERP is capable of updating exchange rates daily from the ECB if set to do so under Setup->Configuration. +<li>The ISO 4217 code for the currency - this is the international standard 3 character code that is used worldwide to represent the currency. If the code entered exists then it is possible for webERP to retrieve exchange rates from either the European Central Bank or Oanda.com, if there is no rate maintained for the currency at the ECB. webERP is capable of updating exchange rates daily from the ECB if set to do so under Setup->Configuration ->Auto Update Exchange Rates Daily. If this is set to yes, then when the first user logs in for the day the exchange rates are updated automatically. If it is set to no then exchange rates will only be updated if the user does so manually. </li> <li>The name of the currency can be any description that describes the currency</li> <lI>The country of the currency can be entered</li> Modified: trunk/doc/Manual/ManualSecuritySchema.html =================================================================== --- trunk/doc/Manual/ManualSecuritySchema.html 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/doc/Manual/ManualSecuritySchema.html 2011-02-22 09:45:01 UTC (rev 4495) @@ -35,12 +35,9 @@ <br> </li><li> PageSecurity values:<br> -Each webERP page includes a Page Security value from 1 to 15.<br> -This is hard coded into each page; for example: $PageSecurity = 1;<br> -For user access Page Security values correspond to 'Security Token' values.<br> +Each webERP page is given a Page Security value from 1 to 15 in the table scripts. The system reads all the scripts and the PageSecurity value for each into a SESSION array - $_SESSION['PageSecurityArray'] - the key for each element is the script name and the value is the PageSecurity value for that script. The key - the script name is retrieved from the $_SERVER['SCRIPT_NAME'] variable. In this way every time a script is called, the PageSecurity is retrieved from the array. +++<br> -There is no webERP tool to change PageSecurity values.<br> -However, an administrator can edit the pages directly.<br> +There is a webERP tool to change PageSecurity values, for each script which is accessible from the Setup menu.<br> <br></ol> These parts work together as follows. The user name and password combination entered at log on enables the system to identify the 'Security Role' for the User. @@ -52,13 +49,11 @@ <u>A more comprehensive description of the security scheme follows:</u><br> <br> Each webERP page (script) is assigned a specific PageSecurity value. -This page security value is hard coded inside each script. At the time -of writing this is a number between 1 and 15. If more levels of security +This page security value is stored in the scripts table of the database and read into a SESSION array on login (from the GetConfig.php script). At the time of writing this is a number between 1 and 15. If more levels of security are necessary then this can be expanded by an administrator or developer. -The default PageSecurity values for each page are set out in the table -below.<br> +The default PageSecurity values for each page can be inspected by browsing the scripts table<br> <br> -The user is allowed access to a page if the PageSecurity value of the page +The user is allowed access to a page if the PageSecurity value of the page/script is a number contained in the SESSION AllowedPageSecurityTokens array as determined from the users access level (Security Role). The user access level Security Role) is an integer that represents the Security Role assigned to the user in the user set up page @@ -84,7 +79,7 @@ Tokens assigned to each Security Role the security access can be tailored for all users. When making these changes reference the default values in the tables below. PageSecurity values must also be known. -The value of the default settings can be modified as needed.<br> +The value of the default settings can be modified as needed from the Page Security script accessible from the Setup module<br> <br> <u>Security Scheme Tables:</u><br> <br> Modified: trunk/includes/PDFTopItemsHeader.inc =================================================================== --- trunk/includes/PDFTopItemsHeader.inc 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/includes/PDFTopItemsHeader.inc 2011-02-22 09:45:01 UTC (rev 4495) @@ -10,29 +10,24 @@ $XPos=0; $pdf->addJpegFromFile('companies/' . $_SESSION['DatabaseName'] . '/logo.jpg',$XPos+20,$YPos-50,0,60); -if ($_GET["customers"]!='All'){ -$SQL="SELECT typename - FROM `debtortype` - WHERE typeid=".$_GET["customers"].""; - -$result = DB_query($SQL,$db); -$myrow=DB_fetch_array($result); -$Customers=$myrow["0"]; +if ($_GET['Customers']!='All'){ + $SQL="SELECT typename + FROM `debtortype` + WHERE typeid='".$_GET['Customers']."'"; + + $result = DB_query($SQL,$db); + $myrow=DB_fetch_array($result); + $Customers=$myrow["0"]; }else{ -$Customers="All"; + $Customers='All'; } -//searching condition -$infoa=_('Search On Location')." : ".$_GET["location"].""; -$infob=_('Customers'). " : ".$Customers.""; -$infoc=_('Number Of Days')." : ".$_GET["numberofdays"]." "; -$infod=_('Number Of Items')." : ".$_GET['NumberOfTopItems'].""; -$infoe=_('Order By')." : ".$_GET['order'].""; - //Display the searching condition -$pdf->addTextWrap($XPos+40,$YPos-70,500,9,$infoa); $pdf->addTextWrap($XPos+240,$YPos-70,500,9,$infob); -$pdf->addTextWrap($XPos+40,$YPos-90,500,9,$infoc); $pdf->addTextWrap($XPos+240,$YPos-90,500,9,$infod); -$pdf->addTextWrap($XPos+40,$YPos-110,500,9,$infoe); +$pdf->addTextWrap($XPos+40,$YPos-70,500,9,_('Search On Location').' : '.$_GET['Location']); +$pdf->addTextWrap($XPos+240,$YPos-70,500,9,_('Customers'). ' : '.$Customers); +$pdf->addTextWrap($XPos+40,$YPos-90,500,9,_('Number Of Days')." : ".$_GET['NumberOfDays']." "); +$pdf->addTextWrap($XPos+240,$YPos-90,500,9,_('Number Of Items')." : ".$_GET['NumberOfTopItems']); +$pdf->addTextWrap($XPos+40,$YPos-110,500,9,_('Order By')." : ".$_GET['Sequence']); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-140,$YPos,300,$FontSize,$_SESSION['CompanyRecord']['coyname']); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-140,$YPos-($line_height*1.5),550,$FontSize, _('Top Items Sales Search Result') ); @@ -63,6 +58,4 @@ $pdf->Rectangle($Left_Margin, $YPos-$line_height,$Page_Width-$Left_Margin-$Right_Margin,$YPos-$Bottom_Margin); $YPos -= (1.5 * $line_height); -//$PageNumber++; - ?> \ No newline at end of file Modified: trunk/includes/class.pdf.php =================================================================== --- trunk/includes/class.pdf.php 2011-02-20 03:52:26 UTC (rev 4494) +++ trunk/includes/class.pdf.php 2011-02-22 09:45:01 UTC (rev 4495) @@ -39,9 +39,15 @@ $UserPdfLang = $_SESSION['PDFLanguage']; switch ($UserPdfLang) { - case 0: $UserPdfFont = 'times'; break; - case 1: $UserPdfFont = 'javierjp'; break; - case 2: $UserPdfFont = 'javiergb'; break; + case 0: + $UserPdfFont = 'times'; + break; + case 1: + $UserPdfFont = 'javierjp'; + break; + case 2: + $UserPdfFont = 'javiergb'; + break; } } else { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-25 21:04:05
|
Revision: 4497 http://web-erp.svn.sourceforge.net/web-erp/?rev=4497&view=rev Author: daintree Date: 2011-02-25 21:03:52 +0000 (Fri, 25 Feb 2011) Log Message: ----------- various Modified Paths: -------------- trunk/MRPPlannedPurchaseOrders.php trunk/includes/SQL_CommonFunctions.inc trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po trunk/locale/zh_CN.utf8/Manual/ManualGettingStarted.html trunk/locale/zh_CN.utf8/Manual/ManualIntroduction.html trunk/locale/zh_CN.utf8/Manual/ManualRequirements.html trunk/locale/zh_CN.utf8/Manual/ManualSecuritySchema.html Modified: trunk/MRPPlannedPurchaseOrders.php =================================================================== --- trunk/MRPPlannedPurchaseOrders.php 2011-02-23 09:12:32 UTC (rev 4496) +++ trunk/MRPPlannedPurchaseOrders.php 2011-02-25 21:03:52 UTC (rev 4497) @@ -3,16 +3,19 @@ /* $Id$*/ // MRPPlannedPurchaseOrders.php - Report of purchase parts that MRP has determined should have // purchase orders created for them -//$PageSecurity = 2; + include('includes/session.inc'); -$sql='show tables where Tables_in_'.$_SESSION['DatabaseName'].'="mrprequirements"'; + +//maybe not ansi sql ?? +$sql='SHOW TABLES WHERE Tables_in_'.$_SESSION['DatabaseName'].'="mrprequirements"'; + $result=DB_query($sql,$db); if (DB_num_rows($result)==0) { - $title='MRP error'; + $title=_('MRP error'); include('includes/header.inc'); - echo '<br>'; + echo '<br />'; prnMsg( _('The MRP calculation must be run before you can run this report').'<br>'. - _('To run the MRP calculation click').' '.'<a href='.$rootpath .'/MRP.php?' . SID .'>'._('here').'</a>', 'error'); + _('To run the MRP calculation click').' '.'<a href='.$rootpath .'/MRP.php>'._('here').'</a>', 'error'); include('includes/footer.inc'); exit; } @@ -111,9 +114,9 @@ $title = _('MRP Planned Purchase Orders') . ' - ' . _('Problem Report'); include('includes/header.inc'); prnMsg( _('The MRP planned purchase orders could not be retrieved by the SQL because') . ' ' . DB_error_msg($db),'error'); - echo "<br><a href='" .$rootpath .'/index.php?' . SID . "'>" . _('Back to the menu') . '</a>'; + echo '<br><a href="' .$rootpath .'/index.php?">' . _('Back to the menu') . '</a>'; if ($debug==1){ - echo "<br>$sql"; + echo '<br />' . $sql; } include('includes/footer.inc'); exit; Modified: trunk/includes/SQL_CommonFunctions.inc =================================================================== --- trunk/includes/SQL_CommonFunctions.inc 2011-02-23 09:12:32 UTC (rev 4496) +++ trunk/includes/SQL_CommonFunctions.inc 2011-02-25 21:03:52 UTC (rev 4497) @@ -18,7 +18,7 @@ DB_query('LOCK TABLES systypes WRITE',$db); - $SQL = "SELECT typeno FROM systypes WHERE typeid = '" . $TransType . "'"; + $SQL = 'SELECT typeno FROM systypes WHERE typeid = ' . $TransType; $ErrMsg = _('CRITICAL ERROR') . '! ' . _('NOTE DOWN THIS ERROR AND SEEK ASSISTANCE') . ': <BR>' . _('The next transaction number could not be retrieved from the database because'); $DbgMsg = _('The following SQL to retrieve the transaction number was used'); @@ -26,7 +26,7 @@ $myrow = DB_fetch_row($GetTransNoResult); - $SQL = "UPDATE systypes SET typeno = '" . ($myrow[0] + 1) . "' WHERE typeid = '" . $TransType . "'"; + $SQL = 'UPDATE systypes SET typeno = ' . ($myrow[0] + 1) . ' WHERE typeid = ' . $TransType; $ErrMsg = _('CRITICAL ERROR') . '! ' . _('NOTE DOWN THIS ERROR AND SEEK ASSISTANCE') . ': ' . _('The transaction number could not be incremented'); $DbgMsg = _('The following SQL to increment the transaction number was used'); $UpdTransNoResult = DB_query($SQL,$db,$ErrMsg,$DbgMsg); @@ -114,13 +114,13 @@ Function GetCreditAvailable($DebtorNo,&$db) { $sql = "SELECT debtorsmaster.debtorno, - debtorsmaster.creditlimit, - SUM(debtortrans.ovamount + debtortrans.ovgst + debtortrans.ovfreight + debtortrans.ovdiscount - debtortrans.alloc) as balance - FROM debtorsmaster INNER JOIN debtortrans - ON debtorsmaster.debtorno=debtortrans.debtorno - WHERE debtorsmaster.debtorno='" . $DebtorNo . "' - GROUP BY debtorsmaster.debtorno, - debtorsmaster.creditlimit"; + debtorsmaster.creditlimit, + SUM(debtortrans.ovamount + debtortrans.ovgst + debtortrans.ovfreight + debtortrans.ovdiscount - debtortrans.alloc) as balance + FROM debtorsmaster INNER JOIN debtortrans + ON debtorsmaster.debtorno=debtortrans.debtorno + WHERE debtorsmaster.debtorno='" . $DebtorNo . "' + GROUP BY debtorsmaster.debtorno, + debtorsmaster.creditlimit"; $ErrMsg = _('The current account balance of the customer could not be retrieved because'); $GetAccountBalanceResult = DB_query($sql, $db, $ErrMsg); @@ -131,8 +131,8 @@ $CreditAvailable = $myrow['creditlimit'] - $myrow['balance']; } else { $sql = "SELECT creditlimit - FROM debtorsmaster - WHERE debtorno='" . $DebtorNo . "'"; + FROM debtorsmaster + WHERE debtorno='" . $DebtorNo . "'"; $GetAccountBalanceResult = DB_query($sql, $db, $ErrMsg); $myrow = DB_fetch_array($GetAccountBalanceResult); $CreditAvailable = $myrow['creditlimit']; @@ -162,7 +162,7 @@ if ($_SESSION['CompanyRecord']['gllink_stock']==1 AND $QOH!=0){ $CostUpdateNo = GetNextTransNo(35, $db); - $PeriodNo = GetPeriod($_SESSION['DefaultDateFormat'], $db); + $PeriodNo = GetPeriod(date($_SESSION['DefaultDateFormat']), $db); $StockGLCode = GetStockGLCode($StockID,$db); $ValueOfChange = $QOH * ($NewCost - $OldCost); @@ -237,7 +237,7 @@ while ($MyRow=DB_fetch_array($result)){ $NewParent = $MyRow['parent']; $MaterialCost = BomMaterialCost($NewParent, $db); - $SQL = "UPDATE stockmaster SET materialcost='" . $MaterialCost . "' WHERE stockid='" . $NewParent . "'"; + $SQL = 'UPDATE stockmaster SET materialcost=' . $MaterialCost . " WHERE stockid='" . $NewParent . "'"; $result1 = DB_query($SQL,$db); if (DB_error_no($db)!=0) { return 1; Modified: trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po 2011-02-23 09:12:32 UTC (rev 4496) +++ trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po 2011-02-25 21:03:52 UTC (rev 4497) @@ -1,4 +1,4 @@ -# weberp 简体中文界面文件 +# weberp 簡體中文介面檔 # Copyright (C) 2007 Logic Works Ltd # This file is distributed under the same license as the webERP package. # FIRST AUTHOR <rom...@gm...>, 2006. @@ -7,472 +7,851 @@ msgstr "" "Project-Id-Version: WEBERP3.05 VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-02-15 18:44+1200\n" -"PO-Revision-Date: 2011-01-29 15:12+0000\n" -"Last-Translator: Exson qu <hex...@gm...>\n" -"Language-Team: WebERP Translation Team <web-erp-translation@lists." -"sourceforge.net>\n" +"POT-Creation-Date: 2011-01-04 22:15+1200\n" +"PO-Revision-Date: 2011-02-25 18:22+0800\n" +"Last-Translator: Exson qu <hex...@ya...>\n" +"Language-Team: WebERP Translation Team <web...@li...>\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Launchpad-Export-Date: 2011-01-29 15:16+0000\n" "X-Generator: Launchpad (build 12274)\n" "X-Poedit-Country: CHINA\n" +"X-Poedit-Basepath: C:\\改過自新\\\n" "X-Poedit-SearchPath-0: webERPRC4\n" -"X-Poedit-Basepath: C:\\改过自新\\\n" -#: AccountGroups.php:9 index.php:1268 +#: AccountGroups.php:9 +#: index.php:1273 msgid "Account Groups" -msgstr "科目组" +msgstr "科目組" #: AccountGroups.php:19 -msgid "" -"An error occurred in retrieving the account groups of the parent account " -"group during the check for recursion" -msgstr "在递归检查中查询父账户组中的科目组发生错误" +msgid "An error occurred in retrieving the account groups of the parent account group during the check for recursion" +msgstr "在遞迴檢查中查詢父帳戶組中的科目組發生錯誤" #: AccountGroups.php:20 -msgid "" -"The SQL that was used to retrieve the account groups of the parent account " -"group and that failed in the process was" -msgstr "用于查询父账户组的科目组失败的SQL是" +msgid "The SQL that was used to retrieve the account groups of the parent account group and that failed in the process was" +msgstr "用於查詢父帳戶組的科目組失敗的SQL是" -#: AccountGroups.php:57 AccountGroups.php:94 AccountGroups.php:177 +#: AccountGroups.php:57 +#: AccountGroups.php:94 +#: AccountGroups.php:177 #: AccountGroups.php:187 msgid "The SQL that was used to retrieve the information was" -msgstr "用于查找交易数据的SQL是" +msgstr "用於查找交易資料的SQL是" #: AccountGroups.php:58 msgid "Could not check whether the group exists because" -msgstr "未能判定组别是否存在, 因为" +msgstr "未能判定組別是否存在, 因為" #: AccountGroups.php:65 msgid "The account group name already exists in the database" -msgstr "科目组名称已经存在在数据库中。" +msgstr "科目組名稱已經存在在資料庫中。" #: AccountGroups.php:71 msgid "The account group name cannot contain the character" -msgstr "科目组名称不能包含这个字符" +msgstr "科目組名稱不能包含這個字元" -#: AccountGroups.php:71 AccountSections.php:75 PaymentMethods.php:41 -#: TaxCategories.php:33 TaxProvinces.php:32 UnitsOfMeasure.php:32 +#: AccountGroups.php:71 +#: AccountSections.php:75 +#: PaymentMethods.php:41 +#: TaxCategories.php:33 +#: TaxProvinces.php:32 +#: UnitsOfMeasure.php:32 msgid "or the character" -msgstr "或这个字符" +msgstr "或這個字元" #: AccountGroups.php:77 msgid "The account group name must be at least one character long" -msgstr "科目组名称必须不少于 1 个字" +msgstr "科目組名稱必須不少於 1 個字" #: AccountGroups.php:84 -msgid "" -"The parent account group selected appears to result in a recursive account " -"structure - select an alternative parent account group or make this group a " -"top level account group" -msgstr "" -"所选的父账户组看来会导致一个递归的账户结构-选择一个另外的父账户组或者将此账户" -"组作为一个最顶层的账户组" +msgid "The parent account group selected appears to result in a recursive account structure - select an alternative parent account group or make this group a top level account group" +msgstr "所選的父帳戶組看來會導致一個遞迴的帳戶結構-選擇一個另外的父帳戶組或者將此帳戶組作為一個最頂層的帳戶組" #: AccountGroups.php:95 msgid "Could not check whether the group is recursive because" -msgstr "未能检查此组是否递归, 因为" +msgstr "未能檢查此組是否遞迴, 因為" #: AccountGroups.php:107 msgid "The section in accounts must be an integer" -msgstr "会计科目类别必须是整数" +msgstr "會計科目類別必須是整數" #: AccountGroups.php:113 msgid "The sequence in the trial balance must be an integer" -msgstr "试算表内行号必须是整数" +msgstr "試算表內行號必須是整數" #: AccountGroups.php:119 msgid "The sequence in the TB must be numeric and less than" -msgstr "试算表内顺序必须是数字且小于" +msgstr "試算表內順序必須是數位且小於" #: AccountGroups.php:136 msgid "An error occurred in updating the account group" -msgstr "更新科目组是发生了错误" +msgstr "更新科目組是發生了錯誤" #: AccountGroups.php:137 msgid "The SQL that was used to update the account group was" -msgstr "用于更新科目组失败的 SQL 是" +msgstr "用於更新科目組失敗的 SQL 是" -#: AccountGroups.php:139 AccountSections.php:106 PaymentMethods.php:91 +#: AccountGroups.php:139 +#: AccountSections.php:106 +#: PaymentMethods.php:91 msgid "Record Updated" -msgstr "记录已更新" +msgstr "記錄已更新" #: AccountGroups.php:157 msgid "An error occurred in inserting the account group" -msgstr "插入科目组时发生错误, 因为" +msgstr "插入科目組時發生錯誤, 因為" #: AccountGroups.php:158 msgid "The SQL that was used to insert the account group was" -msgstr "用作插入科目组失败的 SQL 是" +msgstr "用作插入科目組失敗的 SQL 是" -#: AccountGroups.php:159 AccountSections.php:118 PaymentMethods.php:113 +#: AccountGroups.php:159 +#: AccountSections.php:118 +#: PaymentMethods.php:113 msgid "Record inserted" -msgstr "记录已新增" +msgstr "記錄已新增" #: AccountGroups.php:176 msgid "An error occurred in retrieving the group information from chartmaster" -msgstr "从主表中查找组信息时发生错误" +msgstr "從主表中查找組資訊時發生錯誤" #: AccountGroups.php:181 -msgid "" -"Cannot delete this account group because general ledger accounts have been " -"created using this group" -msgstr "不能删除,已创建了属于这个科目组的会计科目" +msgid "Cannot delete this account group because general ledger accounts have been created using this group" +msgstr "不能刪除,已創建了屬於這個科目組的會計科目" -#: AccountGroups.php:182 AccountGroups.php:192 AccountSections.php:139 -#: Areas.php:117 Areas.php:126 BankAccounts.php:163 CreditStatus.php:126 -#: Currencies.php:144 Currencies.php:152 Currencies.php:159 -#: CustomerBranches.php:296 CustomerBranches.php:306 CustomerBranches.php:316 -#: CustomerBranches.php:326 Customers.php:317 Customers.php:326 -#: Customers.php:334 Customers.php:342 CustomerTypes.php:149 -#: CustomerTypes.php:159 Factors.php:136 FixedAssetCategories.php:132 -#: GLAccounts.php:95 GLAccounts.php:109 Locations.php:247 Locations.php:255 -#: Locations.php:264 Locations.php:272 Locations.php:280 Locations.php:288 -#: Locations.php:296 Locations.php:304 MRPDemandTypes.php:89 -#: PaymentMethods.php:146 PaymentTerms.php:147 PaymentTerms.php:154 -#: PcExpenses.php:119 SalesCategories.php:127 SalesCategories.php:135 -#: SalesPeople.php:144 SalesPeople.php:151 SalesTypes.php:147 -#: SalesTypes.php:157 Shippers.php:82 Shippers.php:94 StockCategories.php:182 -#: Stocks.php:471 Stocks.php:480 Stocks.php:488 Stocks.php:496 Stocks.php:504 -#: Stocks.php:512 Suppliers.php:613 Suppliers.php:622 Suppliers.php:630 -#: SupplierTypes.php:147 TaxCategories.php:133 TaxGroups.php:128 -#: TaxGroups.php:135 TaxProvinces.php:127 UnitsOfMeasure.php:142 -#: UnitsOfMeasure.php:149 WorkCentres.php:90 WorkCentres.php:96 +#: AccountGroups.php:182 +#: AccountGroups.php:192 +#: AccountSections.php:139 +#: Areas.php:117 +#: Areas.php:126 +#: BankAccounts.php:163 +#: CreditStatus.php:126 +#: Currencies.php:144 +#: Currencies.php:152 +#: Currencies.php:159 +#: CustomerBranches.php:296 +#: CustomerBranches.php:306 +#: CustomerBranches.php:316 +#: CustomerBranches.php:326 +#: Customers.php:317 +#: Customers.php:326 +#: Customers.php:334 +#: Customers.php:342 +#: CustomerTypes.php:149 +#: CustomerTypes.php:159 +#: Factors.php:136 +#: FixedAssetCategories.php:132 +#: GLAccounts.php:95 +#: GLAccounts.php:109 +#: Locations.php:247 +#: Locations.php:255 +#: Locations.php:264 +#: Locations.php:272 +#: Locations.php:280 +#: Locations.php:288 +#: Locations.php:296 +#: Locations.php:304 +#: MRPDemandTypes.php:89 +#: PaymentMethods.php:146 +#: PaymentTerms.php:147 +#: PaymentTerms.php:154 +#: PcExpenses.php:119 +#: SalesCategories.php:127 +#: SalesCategories.php:135 +#: SalesPeople.php:144 +#: SalesPeople.php:151 +#: SalesTypes.php:147 +#: SalesTypes.php:157 +#: Shippers.php:82 +#: Shippers.php:94 +#: StockCategories.php:182 +#: Stocks.php:471 +#: Stocks.php:480 +#: Stocks.php:488 +#: Stocks.php:496 +#: Stocks.php:504 +#: Stocks.php:512 +#: Suppliers.php:613 +#: Suppliers.php:622 +#: Suppliers.php:630 +#: SupplierTypes.php:147 +#: TaxCategories.php:133 +#: TaxGroups.php:128 +#: TaxGroups.php:135 +#: TaxProvinces.php:127 +#: UnitsOfMeasure.php:142 +#: UnitsOfMeasure.php:149 +#: WorkCentres.php:90 +#: WorkCentres.php:96 #: WWW_Access.php:87 msgid "There are" msgstr "存在" #: AccountGroups.php:182 msgid "general ledger accounts that refer to this account group" -msgstr "属于此科目组的会计科目" +msgstr "屬於此科目組的會計科目" #: AccountGroups.php:186 msgid "An error occurred in retrieving the parent group information" -msgstr "查找父组信息时发生错误" +msgstr "查找父組資訊時發生錯誤" #: AccountGroups.php:191 -msgid "" -"Cannot delete this account group because it is a parent account group of " -"other account group(s)" -msgstr "删除会计科目组失败, 由于它是其他账户组的父账户组。" +msgid "Cannot delete this account group because it is a parent account group of other account group(s)" +msgstr "刪除會計科目組失敗, 由於它是其他帳戶組的父帳戶組。" #: AccountGroups.php:192 msgid "account groups that have this group as its/there parent account group" -msgstr "账户组将此账户作为他的/他们的父账户组" +msgstr "帳戶組將此帳戶作為他的/他們的父帳戶組" #: AccountGroups.php:195 msgid "An error occurred in deleting the account group" -msgstr "删除账户组是发生错误" +msgstr "刪除帳戶組是發生錯誤" #: AccountGroups.php:196 msgid "The SQL that was used to delete the account group was" -msgstr "用于账户组的 SQL 是" +msgstr "用於帳戶組的 SQL 是" #: AccountGroups.php:198 msgid "group has been deleted" -msgstr "科目组已删除" +msgstr "科目組已刪除" #: AccountGroups.php:223 msgid "The sql that was used to retrieve the account group information was " -msgstr "用于查询账户组信息的SQL是 " +msgstr "用於查詢帳戶組資訊的SQL是 " #: AccountGroups.php:224 msgid "Could not get account groups because" -msgstr "不能取得科目组, 由于" +msgstr "不能取得科目組, 由於" -#: AccountGroups.php:226 AccountSections.php:177 AddCustomerContacts.php:25 -#: AddCustomerContacts.php:28 AddCustomerNotes.php:97 -#: AddCustomerTypeNotes.php:94 AgedDebtors.php:468 AgedSuppliers.php:277 -#: Areas.php:145 AuditTrail.php:13 BOMExtendedQty.php:286 BOMIndented.php:262 -#: BOMIndentedReverse.php:257 BOMInquiry.php:165 BOMListing.php:128 -#: BOMs.php:214 BOMs.php:793 COGSGLPostings.php:20 CompanyPreferences.php:158 -#: CounterSales.php:1983 CounterSales.php:2107 Credit_Invoice.php:257 -#: CreditStatus.php:21 Currencies.php:29 CustEDISetup.php:19 -#: DailyBankTransactions.php:9 DebtorsAtPeriodEnd.php:138 -#: DiscountCategories.php:12 DiscountCategories.php:122 DiscountMatrix.php:18 -#: EDIMessageFormat.php:106 FixedAssetLocations.php:9 -#: FixedAssetRegister.php:13 FixedAssetRegister.php:238 -#: FixedAssetTransfer.php:31 FormDesigner.php:132 GLBalanceSheet.php:351 -#: GLBudgets.php:30 GLJournal.php:243 InventoryPlanning.php:374 -#: InventoryPlanningPrefSupplier.php:474 Labels.php:117 Labels.php:273 -#: MRPReport.php:536 OutstandingGRNs.php:174 PcAssignCashToTab.php:39 -#: PcAssignCashToTab.php:113 PcAssignCashToTab.php:129 -#: PcAssignCashToTab.php:165 PDFPickingList.php:30 PDFPrintLabel.php:132 -#: PDFStockLocTransfer.php:21 PO_AuthorisationLevels.php:12 POReport.php:61 -#: POReport.php:65 POReport.php:69 PO_SelectOSPurchOrder.php:136 -#: PricesBasedOnMarkUp.php:11 Prices_Customer.php:45 Prices.php:32 -#: PurchData.php:141 PurchData.php:256 PurchData.php:275 -#: RecurringSalesOrders.php:311 SalesAnalReptCols.php:51 SalesAnalRepts.php:13 -#: SalesCategories.php:13 SalesGLPostings.php:18 SalesGraph.php:34 -#: SalesPeople.php:22 SalesTypes.php:22 SelectAsset.php:44 -#: SelectCompletedOrder.php:13 SelectContract.php:81 SelectCreditItems.php:204 -#: SelectCreditItems.php:272 SelectCustomer.php:322 SelectGLAccount.php:19 -#: SelectGLAccount.php:79 SelectOrderItems.php:607 SelectOrderItems.php:1431 -#: SelectOrderItems.php:1555 SelectProduct.php:456 SelectSalesOrder.php:155 -#: SelectSupplier.php:9 SelectSupplier.php:198 SelectWorkOrder.php:11 -#: SelectWorkOrder.php:147 ShipmentCosting.php:13 Shipments.php:18 -#: Shippers.php:123 Shippers.php:159 Shipt_Select.php:10 -#: StockLocMovements.php:15 StockLocStatus.php:27 Suppliers.php:306 -#: SupplierTenders.php:261 SupplierTenders.php:318 SupplierTransInquiry.php:11 -#: TaxGroups.php:16 TaxProvinces.php:12 TopItems.php:65 -#: WhereUsedInquiry.php:18 WorkCentres.php:111 WorkCentres.php:158 -#: WorkOrderCosting.php:14 WorkOrderEntry.php:12 WorkOrderIssue.php:22 -#: WorkOrderReceive.php:15 WorkOrderStatus.php:43 WWW_Access.php:13 -#: WWW_Users.php:38 Z_BottomUpCosts.php:51 +#: AccountGroups.php:226 +#: AccountSections.php:177 +#: AddCustomerContacts.php:25 +#: AddCustomerContacts.php:28 +#: AddCustomerNotes.php:97 +#: AddCustomerTypeNotes.php:94 +#: AgedDebtors.php:468 +#: AgedSuppliers.php:277 +#: Areas.php:145 +#: AuditTrail.php:13 +#: BOMExtendedQty.php:286 +#: BOMIndented.php:262 +#: BOMIndentedReverse.php:257 +#: BOMInquiry.php:165 +#: BOMListing.php:128 +#: BOMs.php:214 +#: BOMs.php:793 +#: COGSGLPostings.php:20 +#: CompanyPreferences.php:158 +#: CounterSales.php:1940 +#: CounterSales.php:2062 +#: Credit_Invoice.php:257 +#: CreditStatus.php:21 +#: Currencies.php:29 +#: CustEDISetup.php:19 +#: DailyBankTransactions.php:9 +#: DebtorsAtPeriodEnd.php:138 +#: DiscountCategories.php:12 +#: DiscountCategories.php:122 +#: DiscountMatrix.php:18 +#: EDIMessageFormat.php:106 +#: FixedAssetList.php:8 +#: FixedAssetLocations.php:9 +#: FixedAssetRegister.php:13 +#: FixedAssetRegister.php:232 +#: FixedAssetTransfer.php:31 +#: FormDesigner.php:132 +#: GLBalanceSheet.php:351 +#: GLBudgets.php:30 +#: GLJournal.php:243 +#: InventoryPlanning.php:369 +#: InventoryPlanningPrefSupplier.php:474 +#: Labels.php:117 +#: Labels.php:273 +#: MRPReport.php:536 +#: OutstandingGRNs.php:174 +#: PcAssignCashToTab.php:39 +#: PcAssignCashToTab.php:113 +#: PcAssignCashToTab.php:129 +#: PcAssignCashToTab.php:165 +#: PDFPickingList.php:30 +#: PDFPrintLabel.php:132 +#: PDFStockLocTransfer.php:21 +#: PO_AuthorisationLevels.php:12 +#: POReport.php:61 +#: POReport.php:65 +#: POReport.php:69 +#: PO_SelectOSPurchOrder.php:136 +#: PricesBasedOnMarkUp.php:11 +#: Prices_Customer.php:45 +#: Prices.php:32 +#: PurchData.php:141 +#: PurchData.php:231 +#: PurchData.php:250 +#: RecurringSalesOrders.php:307 +#: SalesAnalReptCols.php:51 +#: SalesAnalRepts.php:13 +#: SalesCategories.php:13 +#: SalesGLPostings.php:18 +#: SalesGraph.php:34 +#: SalesPeople.php:22 +#: SalesTypes.php:22 +#: SelectAsset.php:44 +#: SelectCompletedOrder.php:13 +#: SelectContract.php:81 +#: SelectCreditItems.php:204 +#: SelectCreditItems.php:272 +#: SelectCustomer.php:315 +#: SelectGLAccount.php:19 +#: SelectGLAccount.php:79 +#: SelectOrderItems.php:605 +#: SelectOrderItems.php:1436 +#: SelectOrderItems.php:1556 +#: SelectProduct.php:456 +#: SelectSalesOrder.php:155 +#: SelectSupplier.php:9 +#: SelectSupplier.php:198 +#: SelectWorkOrder.php:11 +#: SelectWorkOrder.php:147 +#: ShipmentCosting.php:13 +#: Shipments.php:18 +#: Shippers.php:123 +#: Shippers.php:159 +#: Shipt_Select.php:10 +#: StockLocMovements.php:15 +#: StockLocStatus.php:27 +#: Suppliers.php:306 +#: SupplierTenders.php:261 +#: SupplierTenders.php:318 +#: SupplierTransInquiry.php:11 +#: TaxGroups.php:16 +#: TaxProvinces.php:12 +#: TopItems.php:60 +#: WhereUsedInquiry.php:18 +#: WorkCentres.php:111 +#: WorkCentres.php:158 +#: WorkOrderCosting.php:14 +#: WorkOrderEntry.php:12 +#: WorkOrderIssue.php:22 +#: WorkOrderReceive.php:15 +#: WorkOrderStatus.php:43 +#: WWW_Access.php:13 +#: WWW_Users.php:38 +#: Z_BottomUpCosts.php:51 msgid "Search" msgstr "查找" #: AccountGroups.php:230 msgid "Group Name" -msgstr "科目组名称" +msgstr "科目組名稱" -#: AccountGroups.php:231 EDIMessageFormat.php:131 +#: AccountGroups.php:231 +#: EDIMessageFormat.php:131 msgid "Section" -msgstr "会计要素" +msgstr "會計要素" -#: AccountGroups.php:232 AccountGroups.php:396 +#: AccountGroups.php:232 +#: AccountGroups.php:396 msgid "Sequence In TB" -msgstr "试算表行次" +msgstr "試算表行次" -#: AccountGroups.php:233 AccountGroups.php:380 GLProfit_Loss.php:8 -#: GLProfit_Loss.php:105 GLProfit_Loss.php:106 GLProfit_Loss.php:157 -#: SelectGLAccount.php:45 SelectGLAccount.php:59 +#: AccountGroups.php:233 +#: AccountGroups.php:380 +#: GLProfit_Loss.php:8 +#: GLProfit_Loss.php:105 +#: GLProfit_Loss.php:106 +#: GLProfit_Loss.php:157 +#: SelectGLAccount.php:45 +#: SelectGLAccount.php:59 msgid "Profit and Loss" -msgstr "损益类" +msgstr "損益類" -#: AccountGroups.php:234 AccountGroups.php:341 +#: AccountGroups.php:234 +#: AccountGroups.php:341 msgid "Parent Group" -msgstr "父组" +msgstr "父組" -#: AccountGroups.php:250 AccountGroups.php:253 AccountGroups.php:384 -#: AccountGroups.php:386 BankAccounts.php:217 BankAccounts.php:361 -#: BankAccounts.php:363 BankAccounts.php:367 BOMs.php:128 BOMs.php:713 -#: BOMs.php:715 CompanyPreferences.php:439 CompanyPreferences.php:441 -#: CompanyPreferences.php:451 CompanyPreferences.php:453 -#: CompanyPreferences.php:463 CompanyPreferences.php:465 -#: ContractCosting.php:174 CustLoginSetup.php:590 CustLoginSetup.php:592 -#: CustomerBranches.php:420 Customers.php:600 Customers.php:857 -#: Customers.php:864 Customers.php:867 DeliveryDetails.php:1034 -#: DeliveryDetails.php:1074 DeliveryDetails.php:1077 GLTransInquiry.php:73 -#: Locations.php:373 MRPCalendar.php:222 MRP.php:530 MRP.php:534 MRP.php:538 -#: MRP.php:542 PaymentMethods.php:203 PaymentMethods.php:204 -#: PaymentMethods.php:264 PaymentMethods.php:270 PDFChequeListing.php:63 -#: PDFDeliveryDifferences.php:64 PDFDIFOT.php:67 -#: PO_AuthorisationLevels.php:132 PO_AuthorisationLevels.php:137 -#: PO_Header.php:758 PO_PDFPurchOrder.php:344 PO_PDFPurchOrder.php:347 -#: PurchData.php:192 PurchData.php:494 PurchData.php:497 -#: RecurringSalesOrders.php:483 RecurringSalesOrders.php:486 -#: SalesAnalReptCols.php:279 SalesAnalReptCols.php:401 -#: SalesAnalReptCols.php:404 SalesAnalRepts.php:406 SalesAnalRepts.php:409 -#: SalesAnalRepts.php:432 SalesAnalRepts.php:435 SalesAnalRepts.php:458 -#: SalesAnalRepts.php:461 SelectProduct.php:351 ShipmentCosting.php:622 -#: Stocks.php:871 Stocks.php:873 Stocks.php:891 Stocks.php:893 -#: SuppContractChgs.php:83 SuppLoginSetup.php:511 SuppLoginSetup.php:513 -#: SystemParameters.php:376 SystemParameters.php:399 SystemParameters.php:415 -#: SystemParameters.php:468 SystemParameters.php:476 SystemParameters.php:516 -#: SystemParameters.php:589 SystemParameters.php:598 SystemParameters.php:606 -#: SystemParameters.php:624 SystemParameters.php:631 SystemParameters.php:756 -#: SystemParameters.php:887 SystemParameters.php:889 SystemParameters.php:899 -#: SystemParameters.php:901 SystemParameters.php:955 SystemParameters.php:967 -#: SystemParameters.php:969 TaxGroups.php:292 TaxGroups.php:295 -#: TaxGroups.php:344 WWW_Users.php:610 WWW_Users.php:612 +#: AccountGroups.php:250 +#: AccountGroups.php:253 +#: AccountGroups.php:384 +#: AccountGroups.php:386 +#: BankAccounts.php:217 +#: BankAccounts.php:361 +#: BankAccounts.php:363 +#: BankAccounts.php:367 +#: BOMs.php:128 +#: BOMs.php:713 +#: BOMs.php:715 +#: CompanyPreferences.php:439 +#: CompanyPreferences.php:441 +#: CompanyPreferences.php:451 +#: CompanyPreferences.php:453 +#: CompanyPreferences.php:463 +#: CompanyPreferences.php:465 +#: ContractCosting.php:174 +#: CustLoginSetup.php:590 +#: CustLoginSetup.php:592 +#: CustomerBranches.php:420 +#: Customers.php:600 +#: Customers.php:857 +#: Customers.php:864 +#: Customers.php:867 +#: DeliveryDetails.php:1034 +#: DeliveryDetails.php:1074 +#: DeliveryDetails.php:1077 +#: GLTransInquiry.php:73 +#: Locations.php:373 +#: MRPCalendar.php:222 +#: MRP.php:530 +#: MRP.php:534 +#: MRP.php:538 +#: MRP.php:542 +#: PaymentMethods.php:203 +#: PaymentMethods.php:204 +#: PaymentMethods.php:264 +#: PaymentMethods.php:270 +#: PDFChequeListing.php:63 +#: PDFDeliveryDifferences.php:64 +#: PDFDIFOT.php:67 +#: PO_AuthorisationLevels.php:132 +#: PO_AuthorisationLevels.php:137 +#: PO_Header.php:758 +#: PO_PDFPurchOrder.php:367 +#: PO_PDFPurchOrder.php:370 +#: PurchData.php:189 +#: PurchData.php:469 +#: PurchData.php:472 +#: RecurringSalesOrders.php:479 +#: RecurringSalesOrders.php:482 +#: SalesAnalReptCols.php:279 +#: SalesAnalReptCols.php:401 +#: SalesAnalReptCols.php:404 +#: SalesAnalRepts.php:406 +#: SalesAnalRepts.php:409 +#: SalesAnalRepts.php:432 +#: SalesAnalRepts.php:435 +#: SalesAnalRepts.php:458 +#: SalesAnalRepts.php:461 +#: SelectProduct.php:351 +#: ShipmentCosting.php:622 +#: Stocks.php:867 +#: Stocks.php:869 +#: Stocks.php:887 +#: Stocks.php:889 +#: SuppContractChgs.php:83 +#: SuppLoginSetup.php:511 +#: SuppLoginSetup.php:513 +#: SystemParameters.php:373 +#: SystemParameters.php:405 +#: SystemParameters.php:450 +#: SystemParameters.php:468 +#: SystemParameters.php:476 +#: SystemParameters.php:516 +#: SystemParameters.php:589 +#: SystemParameters.php:597 +#: SystemParameters.php:615 +#: SystemParameters.php:622 +#: SystemParameters.php:746 +#: SystemParameters.php:877 +#: SystemParameters.php:879 +#: SystemParameters.php:889 +#: SystemParameters.php:891 +#: SystemParameters.php:945 +#: SystemParameters.php:957 +#: SystemParameters.php:959 +#: TaxGroups.php:292 +#: TaxGroups.php:295 +#: TaxGroups.php:344 +#: WWW_Users.php:610 +#: WWW_Users.php:612 msgid "Yes" msgstr "是" -#: AccountGroups.php:256 AccountGroups.php:389 AccountGroups.php:391 -#: BankAccounts.php:215 BankAccounts.php:361 BankAccounts.php:363 -#: BankAccounts.php:367 BOMs.php:130 BOMs.php:712 BOMs.php:716 -#: CompanyPreferences.php:438 CompanyPreferences.php:442 -#: CompanyPreferences.php:450 CompanyPreferences.php:454 -#: CompanyPreferences.php:462 CompanyPreferences.php:466 -#: ContractCosting.php:172 CustLoginSetup.php:589 CustLoginSetup.php:593 -#: CustomerBranches.php:420 Customers.php:599 Customers.php:855 -#: Customers.php:863 Customers.php:866 DeliveryDetails.php:1035 -#: DeliveryDetails.php:1075 DeliveryDetails.php:1078 GLTransInquiry.php:127 -#: Locations.php:375 MRPCalendar.php:224 MRP.php:528 MRP.php:532 MRP.php:536 -#: MRP.php:540 PaymentMethods.php:203 PaymentMethods.php:204 -#: PaymentMethods.php:265 PaymentMethods.php:271 PDFChequeListing.php:62 -#: PDFDeliveryDifferences.php:63 PDFDIFOT.php:66 -#: PO_AuthorisationLevels.php:134 PO_AuthorisationLevels.php:139 -#: PO_Header.php:757 PO_PDFPurchOrder.php:345 PO_PDFPurchOrder.php:348 -#: PurchData.php:195 PurchData.php:495 PurchData.php:498 -#: RecurringSalesOrders.php:482 RecurringSalesOrders.php:485 -#: SalesAnalReptCols.php:277 SalesAnalReptCols.php:402 -#: SalesAnalReptCols.php:405 SalesAnalRepts.php:405 SalesAnalRepts.php:408 -#: SalesAnalRepts.php:431 SalesAnalRepts.php:434 SalesAnalRepts.php:457 -#: SalesAnalRepts.php:460 SelectProduct.php:353 ShipmentCosting.php:623 -#: Stocks.php:866 Stocks.php:868 Stocks.php:886 Stocks.php:888 -#: SuppContractChgs.php:85 SuppLoginSetup.php:510 SuppLoginSetup.php:514 -#: SystemParameters.php:377 SystemParameters.php:400 SystemParameters.php:416 -#: SystemParameters.php:469 SystemParameters.php:477 SystemParameters.php:517 -#: SystemParameters.php:590 SystemParameters.php:599 SystemParameters.php:607 -#: SystemParameters.php:625 SystemParameters.php:632 SystemParameters.php:757 -#: SystemParameters.php:886 SystemParameters.php:890 SystemParameters.php:898 -#: SystemParameters.php:902 SystemParameters.php:956 SystemParameters.php:966 -#: SystemParameters.php:970 TaxGroups.php:293 TaxGroups.php:296 -#: TaxGroups.php:346 WWW_Users.php:609 WWW_Users.php:613 -#: includes/PDFLowGPPageHeader.inc:44 includes/PDFTaxPageHeader.inc:35 +#: AccountGroups.php:256 +#: AccountGroups.php:389 +#: AccountGroups.php:391 +#: BankAccounts.php:215 +#: BankAccounts.php:361 +#: BankAccounts.php:363 +#: BankAccounts.php:367 +#: BOMs.php:130 +#: BOMs.php:712 +#: BOMs.php:716 +#: CompanyPreferences.php:438 +#: CompanyPreferences.php:442 +#: CompanyPreferences.php:450 +#: CompanyPreferences.php:454 +#: CompanyPreferences.php:462 +#: CompanyPreferences.php:466 +#: ContractCosting.php:172 +#: CustLoginSetup.php:589 +#: CustLoginSetup.php:593 +#: CustomerBranches.php:420 +#: Customers.php:599 +#: Customers.php:855 +#: Customers.php:863 +#: Customers.php:866 +#: DeliveryDetails.php:1035 +#: DeliveryDetails.php:1075 +#: DeliveryDetails.php:1078 +#: GLTransInquiry.php:127 +#: Locations.php:375 +#: MRPCalendar.php:224 +#: MRP.php:528 +#: MRP.php:532 +#: MRP.php:536 +#: MRP.php:540 +#: PaymentMethods.php:203 +#: PaymentMethods.php:204 +#: PaymentMethods.php:265 +#: PaymentMethods.php:271 +#: PDFChequeListing.php:62 +#: PDFDeliveryDifferences.php:63 +#: PDFDIFOT.php:66 +#: PO_AuthorisationLevels.php:134 +#: PO_AuthorisationLevels.php:139 +#: PO_Header.php:757 +#: PO_PDFPurchOrder.php:368 +#: PO_PDFPurchOrder.php:371 +#: PurchData.php:192 +#: PurchData.php:470 +#: PurchData.php:473 +#: RecurringSalesOrders.php:478 +#: RecurringSalesOrders.php:481 +#: SalesAnalReptCols.php:277 +#: SalesAnalReptCols.php:402 +#: SalesAnalReptCols.php:405 +#: SalesAnalRepts.php:405 +#: SalesAnalRepts.php:408 +#: SalesAnalRepts.php:431 +#: SalesAnalRepts.php:434 +#: SalesAnalRepts.php:457 +#: SalesAnalRepts.php:460 +#: SelectProduct.php:353 +#: ShipmentCosting.php:623 +#: Stocks.php:862 +#: Stocks.php:864 +#: Stocks.php:882 +#: Stocks.php:884 +#: SuppContractChgs.php:85 +#: SuppLoginSetup.php:510 +#: SuppLoginSetup.php:514 +#: SystemParameters.php:374 +#: SystemParameters.php:406 +#: SystemParameters.php:451 +#: SystemParameters.php:469 +#: SystemParameters.php:477 +#: SystemParameters.php:517 +#: SystemParameters.php:590 +#: SystemParameters.php:598 +#: SystemParameters.php:616 +#: SystemParameters.php:623 +#: SystemParameters.php:747 +#: SystemParameters.php:876 +#: SystemParameters.php:880 +#: SystemParameters.php:888 +#: SystemParameters.php:892 +#: SystemParameters.php:946 +#: SystemParameters.php:956 +#: SystemParameters.php:960 +#: TaxGroups.php:293 +#: TaxGroups.php:296 +#: TaxGroups.php:346 +#: WWW_Users.php:609 +#: WWW_Users.php:613 +#: includes/PDFLowGPPageHeader.inc:44 +#: includes/PDFTaxPageHeader.inc:35 msgid "No" msgstr "否" -#: AccountGroups.php:265 AccountSections.php:197 AddCustomerContacts.php:131 -#: AddCustomerNotes.php:125 AddCustomerTypeNotes.php:123 Areas.php:165 -#: BankAccounts.php:226 BOMs.php:150 COGSGLPostings.php:113 -#: COGSGLPostings.php:218 CreditStatus.php:175 Currencies.php:239 -#: CustLoginSetup.php:312 CustomerBranches.php:424 Customers.php:909 -#: Customers.php:941 CustomerTypes.php:205 EDIMessageFormat.php:152 -#: Factors.php:208 FixedAssetCategories.php:182 FixedAssetLocations.php:102 -#: FreightCosts.php:243 GeocodeSetup.php:169 GLAccounts.php:319 GLTags.php:62 -#: Labels.php:414 Locations.php:382 MRPDemands.php:304 MRPDemandTypes.php:122 -#: PaymentMethods.php:205 PaymentTerms.php:203 PcAssignCashToTab.php:251 -#: PcClaimExpensesFromTab.php:229 PcExpenses.php:176 PcTabs.php:188 -#: PcTypeTabs.php:171 PO_AuthorisationLevels.php:148 Prices_Customer.php:283 -#: Prices.php:227 PurchData.php:207 SalesCategories.php:263 -#: SalesGLPostings.php:135 SalesGLPostings.php:247 SalesPeople.php:210 -#: SalesTypes.php:206 SelectCustomer.php:609 SelectCustomer.php:625 -#: SelectCustomer.php:647 SelectCustomer.php:663 SelectCustomer.php:685 -#: SelectCustomer.php:701 Shippers.php:144 StockCategories.php:244 -#: SupplierContacts.php:153 SupplierTypes.php:192 SuppLoginSetup.php:274 -#: TaxAuthorities.php:173 TaxCategories.php:184 TaxGroups.php:179 -#: TaxProvinces.php:178 UnitsOfMeasure.php:201 WorkCentres.php:138 -#: WWW_Access.php:127 WWW_Users.php:312 includes/InputSerialItems.php:88 +#: AccountGroups.php:265 +#: AccountSections.php:197 +#: AddCustomerContacts.php:131 +#: AddCustomerNotes.php:125 +#: AddCustomerTypeNotes.php:123 +#: Areas.php:165 +#: BankAccounts.php:226 +#: BOMs.php:150 +#: COGSGLPostings.php:113 +#: COGSGLPostings.php:218 +#: CreditStatus.php:175 +#: Currencies.php:239 +#: CustLoginSetup.php:312 +#: CustomerBranches.php:424 +#: Customers.php:909 +#: Customers.php:941 +#: CustomerTypes.php:205 +#: EDIMessageFormat.php:152 +#: Factors.php:208 +#: FixedAssetCategories.php:182 +#: FixedAssetLocations.php:102 +#: FreightCosts.php:243 +#: GeocodeSetup.php:169 +#: GLAccounts.php:319 +#: GLTags.php:62 +#: Labels.php:414 +#: Locations.php:382 +#: MRPDemands.php:304 +#: MRPDemandTypes.php:122 +#: PaymentMethods.php:205 +#: PaymentTerms.php:203 +#: PcAssignCashToTab.php:251 +#: PcClaimExpensesFromTab.php:229 +#: PcExpenses.php:176 +#: PcTabs.php:188 +#: PcTypeTabs.php:171 +#: PO_AuthorisationLevels.php:148 +#: Prices_Customer.php:283 +#: Prices.php:227 +#: PurchData.php:202 +#: SalesCategories.php:263 +#: SalesGLPostings.php:135 +#: SalesGLPostings.php:247 +#: SalesPeople.php:210 +#: SalesTypes.php:206 +#: SelectCustomer.php:607 +#: SelectCustomer.php:623 +#: SelectCustomer.php:645 +#: SelectCustomer.php:661 +#: SelectCustomer.php:683 +#: SelectCustomer.php:699 +#: Shippers.php:144 +#: StockCategories.php:244 +#: SupplierContacts.php:156 +#: SupplierTypes.php:192 +#: SuppLoginSetup.php:274 +#: TaxAuthorities.php:173 +#: TaxCategories.php:184 +#: TaxGroups.php:179 +#: TaxProvinces.php:178 +#: UnitsOfMeasure.php:201 +#: WorkCentres.php:138 +#: WWW_Access.php:127 +#: WWW_Users.php:312 +#: includes/InputSerialItems.php:88 #, php-format msgid "Edit" -msgstr "编辑" +msgstr "編輯" -#: AccountGroups.php:266 AccountSections.php:201 AddCustomerContacts.php:132 -#: AddCustomerNotes.php:126 AddCustomerTypeNotes.php:124 Areas.php:166 -#: BankAccounts.php:227 BOMs.php:152 COGSGLPostings.php:114 -#: COGSGLPostings.php:219 ContractBOM.php:272 ContractOtherReqts.php:121 -#: CounterSales.php:781 Credit_Invoice.php:386 CreditStatus.php:176 -#: Currencies.php:242 CustLoginSetup.php:313 CustomerReceipt.php:866 -#: Customers.php:942 CustomerTypes.php:206 DiscountCategories.php:204 -#: DiscountMatrix.php:178 EDIMessageFormat.php:153 -#: FixedAssetCategories.php:183 FreightCosts.php:244 GeocodeSetup.php:170 -#: GLAccounts.php:320 GLJournal.php:403 Labels.php:414 Locations.php:383 -#: MRPDemands.php:305 MRPDemandTypes.php:123 PaymentMethods.php:206 -#: Payments.php:958 PaymentTerms.php:204 PcAssignCashToTab.php:255 -#: PcClaimExpensesFromTab.php:230 PcExpenses.php:177 PcExpensesTypeTab.php:161 -#: PcTabs.php:189 PcTypeTabs.php:172 PO_AuthorisationLevels.php:150 -#: PO_Items.php:758 Prices_Customer.php:284 Prices.php:228 PurchData.php:208 -#: SalesAnalReptCols.php:294 SalesAnalRepts.php:305 SalesCategories.php:264 -#: SalesGLPostings.php:136 SalesGLPostings.php:248 SalesPeople.php:211 -#: SalesTypes.php:207 SelectCreditItems.php:747 SelectCustomer.php:610 -#: SelectCustomer.php:626 SelectCustomer.php:648 SelectCustomer.php:664 -#: SelectCustomer.php:686 SelectCustomer.php:702 SelectOrderItems.php:1358 -#: Shipments.php:424 Shippers.php:145 SpecialOrder.php:590 -#: StockCategories.php:245 StockCategories.php:539 SuppContractChgs.php:91 -#: SuppCreditGRNs.php:93 SuppFixedAssetChgs.php:81 SuppInvGRNs.php:135 -#: SupplierContacts.php:154 SupplierTypes.php:194 SuppLoginSetup.php:275 -#: SuppShiptChgs.php:86 SuppTransGLAnalysis.php:111 TaxAuthorities.php:174 -#: TaxCategories.php:185 TaxGroups.php:180 TaxProvinces.php:179 -#: UnitsOfMeasure.php:202 WorkCentres.php:139 WOSerialNos.php:300 -#: WWW_Access.php:128 WWW_Users.php:313 includes/InputSerialItemsKeyed.php:54 +#: AccountGroups.php:266 +#: AccountSections.php:201 +#: AddCustomerContacts.php:132 +#: AddCustomerNotes.php:126 +#: AddCustomerTypeNotes.php:124 +#: Areas.php:166 +#: BankAccounts.php:227 +#: BOMs.php:152 +#: COGSGLPostings.php:114 +#: COGSGLPostings.php:219 +#: ContractBOM.php:272 +#: ContractOtherReqts.php:121 +#: CounterSales.php:741 +#: Credit_Invoice.php:386 +#: CreditStatus.php:176 +#: Currencies.php:242 +#: CustLoginSetup.php:313 +#: CustomerReceipt.php:866 +#: Customers.php:942 +#: CustomerTypes.php:206 +#: DiscountCategories.php:204 +#: DiscountMatrix.php:178 +#: EDIMessageFormat.php:153 +#: FixedAssetCategories.php:183 +#: FreightCosts.php:244 +#: GeocodeSetup.php:170 +#: GLAccounts.php:320 +#: GLJournal.php:403 +#: Labels.php:414 +#: Locations.php:383 +#: MRPDemands.php:305 +#: MRPDemandTypes.php:123 +#: PaymentMethods.php:206 +#: Payments.php:961 +#: PaymentTerms.php:204 +#: PcAssignCashToTab.php:255 +#: PcClaimExpensesFromTab.php:230 +#: PcExpenses.php:177 +#: PcExpensesTypeTab.php:161 +#: PcTabs.php:189 +#: PcTypeTabs.php:172 +#: PO_AuthorisationLevels.php:150 +#: PO_Items.php:976 +#: Prices_Customer.php:284 +#: Prices.php:228 +#: PurchData.php:203 +#: SalesAnalReptCols.php:294 +#: SalesAnalRepts.php:305 +#: SalesCategories.php:264 +#: SalesGLPostings.php:136 +#: SalesGLPostings.php:248 +#: SalesPeople.php:211 +#: SalesTypes.php:207 +#: SelectCreditItems.php:747 +#: SelectCustomer.php:608 +#: SelectCustomer.php:624 +#: SelectCustomer.php:646 +#: SelectCustomer.php:662 +#: SelectCustomer.php:684 +#: SelectCustomer.php:700 +#: SelectOrderItems.php:1363 +#: Shipments.php:424 +#: Shippers.php:145 +#: SpecialOrder.php:590 +#: StockCategories.php:245 +#: StockCategories.php:539 +#: SuppContractChgs.php:91 +#: SuppCreditGRNs.php:93 +#: SuppFixedAssetChgs.php:87 +#: SuppInvGRNs.php:135 +#: SupplierContacts.php:157 +#: SupplierTypes.php:194 +#: SuppLoginSetup.php:275 +#: SuppShiptChgs.php:86 +#: SuppTransGLAnalysis.php:111 +#: TaxAuthorities.php:174 +#: TaxCategories.php:185 +#: TaxGroups.php:180 +#: TaxProvinces.php:179 +#: UnitsOfMeasure.php:202 +#: WorkCentres.php:139 +#: WOSerialNos.php:300 +#: WWW_Access.php:128 +#: WWW_Users.php:313 +#: includes/InputSerialItemsKeyed.php:54 #, php-format msgid "Delete" -msgstr "删除" +msgstr "刪除" #: AccountGroups.php:274 msgid "Review Account Groups" -msgstr "查看科目组" +msgstr "查看科目組" #: AccountGroups.php:294 msgid "An error occurred in retrieving the account group information" -msgstr "查找账户组信息时发生错误" +msgstr "查找帳戶組資訊時發生錯誤" #: AccountGroups.php:295 -msgid "" -"The SQL that was used to retrieve the account group and that failed in the " -"process was" -msgstr "用于查询科目组失败的SQL是" +msgid "The SQL that was used to retrieve the account group and that failed in the process was" +msgstr "用於查詢科目組失敗的SQL是" #: AccountGroups.php:298 msgid "The account group name does not exist in the database" -msgstr "科目组名称在数据库中不存在。" +msgstr "科目組名稱在資料庫中不存在。" -#: AccountGroups.php:314 GLAccounts.php:250 GLAccounts.php:299 +#: AccountGroups.php:314 +#: GLAccounts.php:250 +#: GLAccounts.php:299 #: Z_ImportGLAccountGroups.php:28 msgid "Account Group" -msgstr "科目组" +msgstr "科目組" #: AccountGroups.php:338 msgid "Account Group Name" -msgstr "科目组名称" +msgstr "科目組名稱" -#: AccountGroups.php:348 AccountGroups.php:350 +#: AccountGroups.php:348 +#: AccountGroups.php:350 msgid "Top Level Group" -msgstr "顶层组" +msgstr "頂層組" #: AccountGroups.php:364 msgid "Section In Accounts" -msgstr "会计要素" +msgstr "會計要素" -#: AccountGroups.php:401 AccountSections.php:262 AddCustomerContacts.php:208 -#: AddCustomerNotes.php:201 AddCustomerTypeNotes.php:192 Areas.php:222 -#: BankAccounts.php:373 BOMs.php:725 COGSGLPostings.php:347 -#: CreditStatus.php:247 Currencies.php:339 CustLoginSetup.php:611 -#: DiscountMatrix.php:141 EDIMessageFormat.php:249 -#: FixedAssetCategories.php:328 FixedAssetLocations.php:148 -#: FreightCosts.php:342 GeocodeSetup.php:266 GLAccounts.php:269 -#: Locations.php:553 MRPDemands.php:402 MRPDemandTypes.php:182 -#: OffersReceived.php:52 OffersReceived.php:128 PaymentMethods.php:276 -#: PaymentTerms.php:282 PO_AuthorisationLevels.php:217 Prices_Customer.php:372 -#: SalesAnalReptCols.php:510 SalesAnalRepts.php:496 SalesGLPostings.php:415 -#: SalesPeople.php:302 Shippers.php:196 StockCategories.php:561 -#: SupplierContacts.php:250 SuppLoginSetup.php:532 TaxAuthorities.php:313 -#: TaxCategories.php:235 TaxProvinces.php:229 UnitsOfMeasure.php:253 -#: WorkCentres.php:261 WWW_Users.php:643 +#: AccountGroups.php:401 +#: AccountSections.php:262 +#: AddCustomerContacts.php:208 +#: AddCustomerNotes.php:201 +#: AddCustomerTypeNotes.php:192 +#: Areas.php:222 +#: BankAccounts.php:373 +#: BOMs.php:725 +#: COGSGLPostings.php:347 +#: CreditStatus.php:247 +#: Currencies.php:339 +#: CustLoginSetup.php:611 +#: DiscountMatrix.php:141 +#: EDIMessageFormat.php:249 +#: FixedAssetCategories.php:328 +#: FixedAssetLocations.php:148 +#: FreightCosts.php:342 +#: GeocodeSetup.php:266 +#: GLAccounts.php:269 +#: Locations.php:553 +#: MRPDemands.php:402 +#: MRPDemandTypes.php:182 +#: OffersReceived.php:52 +#: OffersReceived.php:128 +#: PaymentMethods.php:276 +#: PaymentTerms.php:282 +#: PO_AuthorisationLevels.php:217 +#: Prices_Customer.php:372 +#: SalesAnalReptCols.php:510 +#: SalesAnalRepts.php:496 +#: SalesGLPostings.php:415 +#: SalesPeople.php:302 +#: Shippers.php:196 +#: StockCategories.php:561 +#: SupplierContacts.php:251 +#: SuppLoginSetup.php:532 +#: TaxAuthorities.php:313 +#: TaxCategories.php:235 +#: TaxProvinces.php:229 +#: UnitsOfMeasure.php:253 +#: WorkCentres.php:261 +#: WWW_Users.php:643 msgid "Enter Information" msgstr "保存" -#: AccountSections.php:9 index.php:1273 +#: AccountSections.php:9 +#: index.php:1278 msgid "Account Sections" -msgstr "会计要素" +msgstr "會計要素" #: AccountSections.php:68 msgid "The account section already exists in the database" -msgstr "会计要素已经存在于数据库" +msgstr "會計要素已經存在於資料庫" #: AccountSections.php:75 msgid "The account section name cannot contain the character" -msgstr "会计要素不能包含这个字符" +msgstr "會計要素不能包含這個字元" #: AccountSections.php:81 msgid "The account section name must contain at least one character" -msgstr "会计要素名称必须包含至少一个字符" +msgstr "會計要素名稱必須包含至少一個字元" -#: AccountSections.php:87 AccountSections.php:93 +#: AccountSections.php:87 +#: AccountSections.php:93 msgid "The section number must be an integer" -msgstr "会计要素编号必须是整数" +msgstr "會計要素編號必須是整數" #: AccountSections.php:138 -msgid "" -"Cannot delete this account section because general ledger accounts groups " -"have been created using this section" -msgstr "此会计要素已被科目组使用,不能删除" +msgid "Cannot delete this account section because general ledger accounts groups have been created using this section" +msgstr "此會計要素已被科目組使用,不能刪除" #: AccountSections.php:139 msgid "general ledger accounts groups that refer to this account section" -msgstr "个科目组需要此会计要素" +msgstr "個科目組需要此會計要素" #: AccountSections.php:150 msgid "section has been deleted" -msgstr "删除会计要素成功" +msgstr "刪除會計要素成功" #: AccountSections.php:175 msgid "Could not get account group sections because" -msgstr "找不到会计要素,原因是:" +msgstr "找不到會計要素,原因是:" -#: AccountSections.php:181 AccountSections.php:238 AccountSections.php:255 +#: AccountSections.php:181 +#: AccountSections.php:238 +#: AccountSections.php:255 msgid "Section Number" -msgstr "会计要素编号" +msgstr "會計要素編號" -#: AccountSections.php:182 AccountSections.php:258 +#: AccountSections.php:182 +#: AccountSections.php:258 msgid "Section Description" -msgstr "会计要素名称" +msgstr "會計要素名稱" #: AccountSections.php:199 msgid "Restricted" @@ -480,220 +859,315 @@ #: AccountSections.php:210 msgid "Review Account Sections" -msgstr "查看会计要素" +msgstr "查看會計要素" #: AccountSections.php:228 msgid "Could not retrieve the requested section please try again." -msgstr "找不到会计要素, 请重试" +msgstr "找不到會計要素, 請重試" -#: AddCustomerContacts.php:6 AddCustomerContacts.php:59 SelectCustomer.php:603 -#: SelectCustomer.php:632 +#: AddCustomerContacts.php:6 +#: AddCustomerContacts.php:59 +#: SelectCustomer.php:601 +#: SelectCustomer.php:630 msgid "Customer Contacts" -msgstr "顾客联系人" +msgstr "顧客聯繫人" -#: AddCustomerContacts.php:20 CustEDISetup.php:11 CustLoginSetup.php:24 +#: AddCustomerContacts.php:20 +#: CustEDISetup.php:11 +#: CustLoginSetup.php:24 #: Z_CheckDebtorsControl.php:21 msgid "Back to Customers" -msgstr "返回客户" +msgstr "返回客戶" #: AddCustomerContacts.php:26 msgid "Contacts for Customer: <b>" -msgstr "客户的联系人" +msgstr "客戶的聯繫人" #: AddCustomerContacts.php:29 msgid "Edit contact for <b>" -msgstr "编辑联系人" +msgstr "編輯聯繫人" #: AddCustomerContacts.php:41 msgid "The Contact must be an integer." -msgstr "联系人必须是整数" +msgstr "聯繫人必須是整數" #: AddCustomerContacts.php:44 msgid "The contact's name must be forty characters or less long" -msgstr "联系人名称必须不多于50个字符" +msgstr "聯繫人名稱必須不多於50個字元" #: AddCustomerContacts.php:47 msgid "The contact's name may not be empty" -msgstr "联系人名称不能留空" +msgstr "聯繫人名稱不能留空" -#: AddCustomerContacts.php:59 AddCustomerNotes.php:49 -#: AddCustomerTypeNotes.php:49 Areas.php:74 CustomerTypes.php:71 -#: DeliveryDetails.php:748 Factors.php:117 FixedAssetItems.php:230 -#: PcAssignCashToTab.php:73 PcClaimExpensesFromTab.php:61 PcExpenses.php:60 -#: PcTabs.php:60 PcTypeTabs.php:59 PO_Items.php:412 SalesAnalReptCols.php:129 -#: SalesPeople.php:94 SalesTypes.php:63 Stocks.php:355 Suppliers.php:514 +#: AddCustomerContacts.php:59 +#: AddCustomerNotes.php:49 +#: AddCustomerTypeNotes.php:49 +#: Areas.php:74 +#: CustomerTypes.php:71 +#: DeliveryDetails.php:748 +#: Factors.php:117 +#: FixedAssetItems.php:230 +#: PcAssignCashToTab.php:73 +#: PcClaimExpensesFromTab.php:61 +#: PcExpenses.php:60 +#: PcTabs.php:60 +#: PcTypeTabs.php:59 +#: PO_Items.php:381 +#: SalesAnalReptCols.php:129 +#: SalesPeople.php:94 +#: SalesTypes.php:63 +#: Stocks.php:355 +#: Suppliers.php:514 #: SupplierTypes.php:69 msgid "has been updated" msgstr "已更新" #: AddCustomerContacts.php:70 msgid "The contact record has been added" -msgstr "联系人已新增" +msgstr "聯繫人已新增" #: AddCustomerContacts.php:98 msgid "The contact record has been deleted" -msgstr "联系人记录已删除" +msgstr "聯繫人記錄已刪除" -#: AddCustomerContacts.php:112 CompanyPreferences.php:229 -#: CustomerBranches.php:377 Customers.php:899 Customers.php:905 -#: Customers.php:971 SalesPeople.php:185 SelectCustomer.php:605 -#: StockDispatch.php:186 StockDispatch.php:198 SupplierContacts.php:141 -#: SupplierCredit.php:433 SupplierInvoice.php:408 SuppTransGLAnalysis.php:96 -#: includes/InputSerialItemsFile.php:84 includes/InputSerialItemsFile.php:124 +#: AddCustomerContacts.php:112 +#: CompanyPreferences.php:229 +#: CustomerBranches.php:377 +#: Customers.php:899 +#: Customers.php:905 +#: Customers.php:971 +#: SalesPeople.php:185 +#: SelectCustomer.php:603 +#: StockDispatch.php:186 +#: StockDispatch.php:198 +#: SupplierContacts.php:144 +#: SupplierCredit.php:433 +#: SupplierInvoice.php:407 +#: SuppTransGLAnalysis.php:96 +#: includes/InputSerialItemsFile.php:84 +#: includes/InputSerialItemsFile.php:124 #: includes/PDFTaxPageHeader.inc:37 msgid "Name" -msgstr "名称" +msgstr "名稱" -#: AddCustomerContacts.php:113 AddCustomerContacts.php:190 Customers.php:900 -#: Customers.php:906 Customers.php:972 SelectCustomer.php:606 -#: WWW_Access.php:111 WWW_Access.php:172 +#: AddCustomerContacts.php:113 +#: AddCustomerContacts.php:190 +#: Customers.php:900 +#: Customers.php:906 +#: Customers.php:972 +#: SelectCustomer.php:604 +#: WWW_Access.php:111 +#: WWW_Access.php:172 msgid "Role" -msgstr "职位" +msgstr "職位" -#: AddCustomerContacts.php:114 Customers.php:973 +#: AddCustomerContacts.php:114 +#: Customers.php:973 msgid "Phone no" -msgstr "电话" +msgstr "電話" -#: AddCustomerContacts.php:115 AddCustomerContacts.php:202 Customers.php:902 -#: Customers.php:908 Customers.php:974 PcAssignCashToTab.php:216 -#: PcAssignCashToTab.php:341 PcAuthorizeExpenses.php:85 -#: PcClaimExpensesFromTab.php:195 PcClaimExpensesFromTab.php:348 -#: PcReportTab.php:348 SelectCustomer.php:608 SystemParameters.php:316 -#: WOSerialNos.php:277 WOSerialNos.php:279 +#: AddCustomerContacts.php:115 +#: AddCustomerContacts.php:202 +#: Customers.php:902 +#: Customers.php:908 +#: Customers.php:974 +#: PcAssignCashToTab.php:216 +#: PcAssignCashToTab.php:341 +#: PcAuthorizeExpenses.php:85 +#: PcClaimExpensesFromTab.php:195 +#: PcClaimExpensesFromTab.php:348 +#: PcReportTab.php:348 +#: SelectCustomer.php:606 +#: SystemParameters.php:313 +#: WOSerialNos.php:277 +#: WOSerialNos.php:279 msgid "Notes" -msgstr "备注" +msgstr "備註" #: AddCustomerContacts.php:149 msgid "Review all contacts for this Customer" -msgstr "查看此顾客的所有联络人" +msgstr "查看此顧客的所有聯絡人" #: AddCustomerContacts.php:179 msgid "Contact Code" -msgstr "联系人代码" +msgstr "聯繫人代碼" -#: AddCustomerContacts.php:184 Factors.php:279 SupplierContacts.php:218 +#: AddCustomerContacts.php:184 +#: Factors.php:279 +#: SupplierContacts.php:219 msgid "Contact Name" -msgstr "联系人名称" +msgstr "聯繫人名稱" -#: AddCustomerContacts.php:196 Contracts.php:777 PDFRemittanceAdvice.php:247 -#: PO_Header.php:958 PO_Header.php:1028 SelectCreditItems.php:225 -#: SelectCustomer.php:463 SelectOrderItems.php:639 -#: includes/PDFStatementPageHeader.inc:63 includes/PDFTransPageHeader.inc:117 +#: AddCustomerContacts.php:196 +#: Contracts.php:766 +#: PDFRemittanceAdvice.php:247 +#: PO_Header.php:958 +#: PO_Header.php:1028 +#: SelectCreditItems.php:225 +#: SelectCustomer.php:461 +#: SelectOrderItems.php:638 +#: includes/PDFStatementPageHeader.inc:63 +#: includes/PDFTransPageHeader.inc:113 #: includes/PDFTransPageHeaderPortrait.inc:105 msgid "Phone" -msgstr "电话" +msgstr "電話" -#: AddCustomerNotes.php:6 AddCustomerNotes.php:49 SelectCustomer.php:640 -#: SelectCustomer.php:670 +#: AddCustomerNotes.php:6 +#: AddCustomerNotes.php:49 +#: SelectCustomer.php:638 +#: SelectCustomer.php:668 msgid "Customer Notes" -msgstr "客户通知" +msgstr "客戶通知" -#: AddCustomerNotes.php:20 AddCustomerTypeNotes.php:20 +#: AddCustomerNotes.php:20 +#: AddCustomerTypeNotes.php:20 msgid "Back to Select Customer" -msgstr "返回选择客户" +msgstr "返回選擇客戶" #: AddCustomerNotes.php:31 msgid "The contact priority must be an integer." -msgstr "联系优先级必须是整数" +msgstr "聯繫優先順序必須是整數" -#: AddCustomerNotes.php:34 AddCustomerTypeNotes.php:34 +#: AddCustomerNotes.php:34 +#: AddCustomerTypeNotes.php:34 msgid "The contact's notes must be two hundred characters or less long" -msgstr "联系人备注必须不多于200个字符" +msgstr "聯繫人備註必須不多於200個字元" -#: AddCustomerNotes.php:37 AddCustomerTypeNotes.php:37 +#: AddCustomerNotes.php:37 +#: AddCustomerTypeNotes.php:37 msgid "The contact's notes may not be empty" -msgstr "联系人备注不能留空" +msgstr "聯繫人備註不能留空" #: AddCustomerNotes.php:60 msgid "The contact notes record has been added" -msgstr "联系人备注记录已新增" +msgstr "聯繫人備註記錄已新增" #: AddCustomerNotes.php:87 msgid "The contact note record has been deleted" -msgstr "联系人备注记录已删除" +msgstr "聯繫人備註記錄已刪除" #: AddCustomerNotes.php:98 msgid "Notes for Customer" -msgstr "客户通知:" +msgstr "客戶通知:" -#: AddCustomerNotes.php:106 AddCustomerNotes.php:189 -#: AddCustomerTypeNotes.php:104 AddCustomerTypeNotes.php:186 -#: BankMatching.php:223 BankReconciliation.php:184 BankReconciliation.php:256 -#: ContractCosting.php:149 CustomerAllocations.php:332 -#: CustomerAllocations.php:358 CustomerInquiry.php:191 -#: CustomerTransInquiry.php:87 GLAccountInquiry.php:154 -#: GLAccountReport.php:369 GLTransInquiry.php:45 MRPCalendar.php:217 -#: PaymentAllocations.php:77 PcAssignCashToTab.php:212 -#: PcAuthorizeExpenses.php:81 PDFRemittanceAdvice.php:308 -#: PrintCustTrans.php:616 PrintCustTransPortrait.php:790 ReverseGRN.php:378 -#: ShipmentCosting.php:503 ShipmentCosting.php:574 Shipments.php:467 -#: StockDispatch.php:188 StockDispatch.php:200 StockLocMovements.php:85 -#: StockMovements.php:98 StockSerialItemResearch.php:79 -#: SupplierAllocations.php:464 SupplierAllocations.php:576 -#: SupplierAllocations.php:646 SupplierInquiry.php:195 -#: SupplierTransInquiry.php:89 includes/PDFQuotationPageHeader.inc:91 -#: includes/PDFStatementPageHeader.inc:169 includes/PDFTaxPageHeader.inc:36 -#: includes/PDFTransPageHeader.inc:84 +#: AddCustomerNotes.php:106 +#: AddCustomerNotes.php:189 +#: AddCustomerTypeNotes.php:104 +#: AddCustomerTypeNotes.php:186 +#: BankMatching.php:223 +#: BankReconciliation.php:184 +#: BankReconciliation.php:256 +#: ContractCosting.php:149 +#: CustomerAllocations.php:332 +#: CustomerAllocations.php:358 +#: CustomerInquiry.php:191 +#: CustomerTransInquiry.php:87 +#: GLAccountInquiry.php:154 +#: GLAccountReport.php:369 +#: GLTransInquiry.php:45 +#: MRPCalendar.php:217 +#: PaymentAllocations.php:77 +#: PcAssignCashToTab.php:212 +#: PcAuthorizeExpenses.php:81 +#: PDFRemittanceAdvice.php:308 +#: PrintCustTrans.php:678 +#: PrintCustTransPortrait.php:860 +#: ReverseGRN.php:378 +#: ShipmentCosting.php:503 +#: ShipmentCosting.php:574 +#: Shipments.php:467 +#: StockDispatch.php:188 +#: StockDispatch.php:200 +#: StockLocMovements.php:85 +#: StockMovements.php:98 +#: StockSerialItemResearch.php:79 +#: SupplierAllocations.php:464 +#: SupplierAllocations.php:576 +#: SupplierAllocations.php:646 +#: SupplierInquiry.php:195 +#: SupplierTransInquiry.php:89 +#: includes/PDFQuotationPageHeader.inc:91 +#: includes/PDFStatementPageHeader.inc:169 +#: includes/PDFTaxPageHeader.inc:36 +#: includes/PDFTransPageHeader.inc:80 #: includes/PDFTransPageHeaderPortrait.inc:58 msgid "Date" msgstr "日期" -#: AddCustomerNotes.php:107 AddCustomerTypeNotes.php:105 PcReportTab.php:176 -#: Stocks.php:875 UpgradeDatabase.php:147 UpgradeDatabase.php:150 -#: UpgradeDatabase.php:153 UpgradeDatabase.php:156 UpgradeDatabase.php:159 -#: UpgradeDatabase.php:162 UpgradeDatabase.php:165 UpgradeDatabase.php:168 -#: Z_Upgrade_3.10-3.11.php:62 Z_Upgrade_3.10-3.11.php:66 -#: Z_Upgrade_3.10-3.11.php:70 Z_Upgrade_3.10-3.11.php:74 -#: Z_Upgrade_3.10-3.11.php:78 Z_Upgrade_3.11-4.00.php:62 -#: Z_Upgrade_3.11-4.00.php:66 Z_Upgrade_3.11-4.00.php:70 -#: Z_Upgrade_3.11-4.00.php:74 Z_Upgrade_3.11-4.00.php:78 +#: AddCustomerNotes.php:107 +#: AddCustomerTypeNotes.php:105 +#: PcReportTab.php:176 +#: Stocks.php:871 +#: UpgradeDatabase.php:145 +#: UpgradeDatabase.php:148 +#: UpgradeDatabase.php:151 +#: UpgradeDatabase.php:154 +#: UpgradeDatabase.php:157 +#: UpgradeDatabase.php:160 +#: UpgradeDatabase.php:163 +#: Z_Upgrade_3.10-3.11.php:62 +#: Z_Upgrade_3.10-3.11.php:66 +#: Z_Upgrade_3.10-3.11.php:70 +#: Z_Upgrade_3.10-3.11.php:74 +#: Z_Upgrade_3.10-3.11.php:78 +#: Z_Upgrade_3.11-4.00.php:62 +#: Z_Upgrade_3.11-4.00.php:66 +#: Z_Upgrade_3.11-4.00.php:70 +#: Z_Upgrade_3.11-4.00.php:74 +#: Z_Upgrade_3.11-4.00.php:78 msgid "Note" -msgstr "备注" +msgstr "備註" -#: AddCustomerNotes.php:108 AddCustomerNotes.php:183 +#: AddCustomerNotes.php:108 +#: AddCustomerNotes.php:183 msgid "WWW" -msgstr "WWW万维网" +msgstr "WWW萬維網" -#: AddCustomerNotes.php:109 AddCustomerNotes.php:195 -#: AddCustomerTypeNotes.php:107 AddCustomerTypeNotes.php:189 +#: AddCustomerNotes.php:109 +#: AddCustomerNotes.php:195 +#: AddCustomerTypeNotes.php:107 +#: AddCustomerTypeNotes.php:189 msgid "Priority" -msgstr "优先级" +msgstr "優先順序" #: AddCustomerNotes.php:143 msgid "Review all notes for this Customer" -msgstr "查看此顾客的所有通知" +msgstr "查看此顧客的所有通知" -#: AddCustomerNotes.php:172 AddCustomerTypeNotes.php:171 +#: AddCustomerNotes.php:172 +#: AddCustomerTypeNotes.php:171 msgid "Note ID" msgstr "Note ID" #: AddCustomerNotes.php:177 msgid "Contact Note" -msgstr "联络人备注" +msgstr "聯絡人備註" -#: AddCustomerTypeNotes.php:6 SelectCustomer.php:678 +#: AddCustomerTypeNotes.php:6 +#: SelectCustomer.php:676 msgid "Customer Type (Group) Notes" -msgstr "顾客种类(组)备注" +msgstr "顧客種類(組)備註" #: AddCustomerTypeNotes.php:31 msgid "The Contact priority must be an integer." -msgstr "联络人优先级必须是整数" +msgstr "聯絡人優先順序必須是整數" -#: AddCustomerTypeNotes.php:49 SelectCustomer.php:708 +#: AddCustomerTypeNotes.php:49 +#: SelectCustomer.php:706 msgid "Customer Group Notes" -msgstr "顾客组通知" +msgstr "顧客組通知" #: AddCustomerTypeNotes.php:60 msgid "The contact group notes record has been added" -msgstr "联系人组通知记录已增加" +msgstr "聯繫人組通知記錄已增加" #: AddCustomerTypeNotes.php:84 msgid "The contact group note record has been deleted" -msgstr "联系人组通知记录已经删除" +msgstr "聯繫人組通知記錄已經刪除" #: AddCustomerTypeNotes.php:95 msgid "Notes for Customer Type" -msgstr "顾客类型的通知:" +msgstr "顧客類型的通知:" #: AddCustomerTypeNotes.php:106 msgid "href" @@ -701,294 +1175,477 @@ #: AddCustomerTypeNotes.php:141 msgid "Review all notes for this Customer Type" -msgstr "查看此顾客类型的所有通知。" +msgstr "查看此顧客類型的所有通知。" #: AddCustomerTypeNotes.php:182 msgid "Contact Group Note" -msgstr "联系人组通知" +msgstr "聯繫人組通知" #: AddCustomerTypeNotes.php:184 msgid "Web site" -msgstr "网站" +msgstr "網站" #: AgedDebtors.php:17 msgid "Aged Customer Balance Listing" -msgstr "应收账款帐龄分析表" +msgstr "應收賬款帳齡分析表" #: AgedDebtors.php:18 msgid "Aged Customer Balances" -msgstr "欠款余额" +msgstr "欠款餘額" -#: AgedDebtors.php:267 AgedDebtors.php:365 AgedDebtors.php:436 +#: AgedDebtors.php:267 +#: AgedDebtors.php:365 +#: AgedDebtors.php:436 msgid "Aged Customer Account Analysis" -msgstr "客户欠款分析" +msgstr "客戶欠款分析" -#: AgedDebtors.php:267 AgedDebtors.php:365 AgedDebtors.php:436 -#: AgedSuppliers.php:105 BOMExtendedQty.php:156 BOMIndented.php:149 -#: BOMIndentedReverse.php:148 BOMListing.php:48 BOMListing.php:59 -#: DebtorsAtPeriodEnd.php:58 DebtorsAtPeriodEnd.php:70 GLBalanceSheet.php:90 -#: GLBalanceSheet.php:128 GLProfit_Loss.php:157 GLTagProfit_Loss.php:174 -#: GLTrialBalance.php:151 InventoryPlanning.php:99 InventoryPlanning.php:174 -#: InventoryPlanning.php:209 InventoryPlanning.php:257 -#: InventoryPlanning.php:295 InventoryPlanningPrefSupplier.php:208 -#: InventoryPlanningPrefSupplier.php:276 InventoryPlanningPrefSupplier.php:310 -#: InventoryPlanningPrefSupplier.php:355 InventoryPlanningPrefSupplier.php:401 -#: InventoryQuantities.php:83 InventoryValuation.php:76 -#: MailInventoryValuation.php:115 MRPPlannedPurchaseOrders.php:111 -#: MRPPlannedWorkOrders.php:105 MRPReport.php:147 MRPReport.php:529 -#: MRPReschedules.php:46 MRPReschedules.php:58 MRPShortages.php:137 -#: MRPShortages.php:149 OutstandingGRNs.php:51 OutstandingGRNs.php:63 -#: PDFCustomerList.php:20 PDFCustomerList.php:232 PDFCustomerList.php:244 -#: PDFLowGP.php:23 PDFStockCheckComparison.php:35 -#: PDFStockCheckComparison.php:61 PDFStockCheckComparison.php:262 -#: ReorderLevel.php:59 SelectAsset.php:36 SelectProduct.php:37 -#: StockCheck.php:65 StockCheck.php:139 SupplierTenders.php:325 -#: SuppPriceList.php:118 includes/PDFPaymentRun_PymtFooter.php:149 +#: AgedDebtors.php:267 +#: AgedDebtors.php:365 +#: AgedDebtors.php:436 +#: AgedSuppliers.php:105 +#: BOMExtendedQty.php:156 +#: BOMIndented.php:149 +#: BOMIndentedReverse.php:148 +#: BOMListing.php:48 +#: BOMListing.php:59 +#: DebtorsAtPeriodEnd.php:58 +#: DebtorsAtPeriodEnd.php:70 +#: GLBalanceSheet.php:90 +#: GLBalanceSheet.php:128 +#: GLProfit_Loss.php:157 +#: GLTagProfit_Loss.php:174 +#: GLTri... [truncated message content] |
From: <dai...@us...> - 2011-02-25 21:04:09
|
Revision: 4497 http://web-erp.svn.sourceforge.net/web-erp/?rev=4497&view=rev Author: daintree Date: 2011-02-25 21:03:52 +0000 (Fri, 25 Feb 2011) Log Message: ----------- various Modified Paths: -------------- trunk/MRPPlannedPurchaseOrders.php trunk/includes/SQL_CommonFunctions.inc trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po trunk/locale/zh_CN.utf8/Manual/ManualGettingStarted.html trunk/locale/zh_CN.utf8/Manual/ManualIntroduction.html trunk/locale/zh_CN.utf8/Manual/ManualRequirements.html trunk/locale/zh_CN.utf8/Manual/ManualSecuritySchema.html Modified: trunk/MRPPlannedPurchaseOrders.php =================================================================== --- trunk/MRPPlannedPurchaseOrders.php 2011-02-23 09:12:32 UTC (rev 4496) +++ trunk/MRPPlannedPurchaseOrders.php 2011-02-25 21:03:52 UTC (rev 4497) @@ -3,16 +3,19 @@ /* $Id$*/ // MRPPlannedPurchaseOrders.php - Report of purchase parts that MRP has determined should have // purchase orders created for them -//$PageSecurity = 2; + include('includes/session.inc'); -$sql='show tables where Tables_in_'.$_SESSION['DatabaseName'].'="mrprequirements"'; + +//maybe not ansi sql ?? +$sql='SHOW TABLES WHERE Tables_in_'.$_SESSION['DatabaseName'].'="mrprequirements"'; + $result=DB_query($sql,$db); if (DB_num_rows($result)==0) { - $title='MRP error'; + $title=_('MRP error'); include('includes/header.inc'); - echo '<br>'; + echo '<br />'; prnMsg( _('The MRP calculation must be run before you can run this report').'<br>'. - _('To run the MRP calculation click').' '.'<a href='.$rootpath .'/MRP.php?' . SID .'>'._('here').'</a>', 'error'); + _('To run the MRP calculation click').' '.'<a href='.$rootpath .'/MRP.php>'._('here').'</a>', 'error'); include('includes/footer.inc'); exit; } @@ -111,9 +114,9 @@ $title = _('MRP Planned Purchase Orders') . ' - ' . _('Problem Report'); include('includes/header.inc'); prnMsg( _('The MRP planned purchase orders could not be retrieved by the SQL because') . ' ' . DB_error_msg($db),'error'); - echo "<br><a href='" .$rootpath .'/index.php?' . SID . "'>" . _('Back to the menu') . '</a>'; + echo '<br><a href="' .$rootpath .'/index.php?">' . _('Back to the menu') . '</a>'; if ($debug==1){ - echo "<br>$sql"; + echo '<br />' . $sql; } include('includes/footer.inc'); exit; Modified: trunk/includes/SQL_CommonFunctions.inc =================================================================== --- trunk/includes/SQL_CommonFunctions.inc 2011-02-23 09:12:32 UTC (rev 4496) +++ trunk/includes/SQL_CommonFunctions.inc 2011-02-25 21:03:52 UTC (rev 4497) @@ -18,7 +18,7 @@ DB_query('LOCK TABLES systypes WRITE',$db); - $SQL = "SELECT typeno FROM systypes WHERE typeid = '" . $TransType . "'"; + $SQL = 'SELECT typeno FROM systypes WHERE typeid = ' . $TransType; $ErrMsg = _('CRITICAL ERROR') . '! ' . _('NOTE DOWN THIS ERROR AND SEEK ASSISTANCE') . ': <BR>' . _('The next transaction number could not be retrieved from the database because'); $DbgMsg = _('The following SQL to retrieve the transaction number was used'); @@ -26,7 +26,7 @@ $myrow = DB_fetch_row($GetTransNoResult); - $SQL = "UPDATE systypes SET typeno = '" . ($myrow[0] + 1) . "' WHERE typeid = '" . $TransType . "'"; + $SQL = 'UPDATE systypes SET typeno = ' . ($myrow[0] + 1) . ' WHERE typeid = ' . $TransType; $ErrMsg = _('CRITICAL ERROR') . '! ' . _('NOTE DOWN THIS ERROR AND SEEK ASSISTANCE') . ': ' . _('The transaction number could not be incremented'); $DbgMsg = _('The following SQL to increment the transaction number was used'); $UpdTransNoResult = DB_query($SQL,$db,$ErrMsg,$DbgMsg); @@ -114,13 +114,13 @@ Function GetCreditAvailable($DebtorNo,&$db) { $sql = "SELECT debtorsmaster.debtorno, - debtorsmaster.creditlimit, - SUM(debtortrans.ovamount + debtortrans.ovgst + debtortrans.ovfreight + debtortrans.ovdiscount - debtortrans.alloc) as balance - FROM debtorsmaster INNER JOIN debtortrans - ON debtorsmaster.debtorno=debtortrans.debtorno - WHERE debtorsmaster.debtorno='" . $DebtorNo . "' - GROUP BY debtorsmaster.debtorno, - debtorsmaster.creditlimit"; + debtorsmaster.creditlimit, + SUM(debtortrans.ovamount + debtortrans.ovgst + debtortrans.ovfreight + debtortrans.ovdiscount - debtortrans.alloc) as balance + FROM debtorsmaster INNER JOIN debtortrans + ON debtorsmaster.debtorno=debtortrans.debtorno + WHERE debtorsmaster.debtorno='" . $DebtorNo . "' + GROUP BY debtorsmaster.debtorno, + debtorsmaster.creditlimit"; $ErrMsg = _('The current account balance of the customer could not be retrieved because'); $GetAccountBalanceResult = DB_query($sql, $db, $ErrMsg); @@ -131,8 +131,8 @@ $CreditAvailable = $myrow['creditlimit'] - $myrow['balance']; } else { $sql = "SELECT creditlimit - FROM debtorsmaster - WHERE debtorno='" . $DebtorNo . "'"; + FROM debtorsmaster + WHERE debtorno='" . $DebtorNo . "'"; $GetAccountBalanceResult = DB_query($sql, $db, $ErrMsg); $myrow = DB_fetch_array($GetAccountBalanceResult); $CreditAvailable = $myrow['creditlimit']; @@ -162,7 +162,7 @@ if ($_SESSION['CompanyRecord']['gllink_stock']==1 AND $QOH!=0){ $CostUpdateNo = GetNextTransNo(35, $db); - $PeriodNo = GetPeriod($_SESSION['DefaultDateFormat'], $db); + $PeriodNo = GetPeriod(date($_SESSION['DefaultDateFormat']), $db); $StockGLCode = GetStockGLCode($StockID,$db); $ValueOfChange = $QOH * ($NewCost - $OldCost); @@ -237,7 +237,7 @@ while ($MyRow=DB_fetch_array($result)){ $NewParent = $MyRow['parent']; $MaterialCost = BomMaterialCost($NewParent, $db); - $SQL = "UPDATE stockmaster SET materialcost='" . $MaterialCost . "' WHERE stockid='" . $NewParent . "'"; + $SQL = 'UPDATE stockmaster SET materialcost=' . $MaterialCost . " WHERE stockid='" . $NewParent . "'"; $result1 = DB_query($SQL,$db); if (DB_error_no($db)!=0) { return 1; Modified: trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po 2011-02-23 09:12:32 UTC (rev 4496) +++ trunk/locale/zh_CN.utf8/LC_MESSAGES/messages.po 2011-02-25 21:03:52 UTC (rev 4497) @@ -1,4 +1,4 @@ -# weberp 简体中文界面文件 +# weberp 簡體中文介面檔 # Copyright (C) 2007 Logic Works Ltd # This file is distributed under the same license as the webERP package. # FIRST AUTHOR <rom...@gm...>, 2006. @@ -7,472 +7,851 @@ msgstr "" "Project-Id-Version: WEBERP3.05 VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2011-02-15 18:44+1200\n" -"PO-Revision-Date: 2011-01-29 15:12+0000\n" -"Last-Translator: Exson qu <hex...@gm...>\n" -"Language-Team: WebERP Translation Team <web-erp-translation@lists." -"sourceforge.net>\n" +"POT-Creation-Date: 2011-01-04 22:15+1200\n" +"PO-Revision-Date: 2011-02-25 18:22+0800\n" +"Last-Translator: Exson qu <hex...@ya...>\n" +"Language-Team: WebERP Translation Team <web...@li...>\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Launchpad-Export-Date: 2011-01-29 15:16+0000\n" "X-Generator: Launchpad (build 12274)\n" "X-Poedit-Country: CHINA\n" +"X-Poedit-Basepath: C:\\改過自新\\\n" "X-Poedit-SearchPath-0: webERPRC4\n" -"X-Poedit-Basepath: C:\\改过自新\\\n" -#: AccountGroups.php:9 index.php:1268 +#: AccountGroups.php:9 +#: index.php:1273 msgid "Account Groups" -msgstr "科目组" +msgstr "科目組" #: AccountGroups.php:19 -msgid "" -"An error occurred in retrieving the account groups of the parent account " -"group during the check for recursion" -msgstr "在递归检查中查询父账户组中的科目组发生错误" +msgid "An error occurred in retrieving the account groups of the parent account group during the check for recursion" +msgstr "在遞迴檢查中查詢父帳戶組中的科目組發生錯誤" #: AccountGroups.php:20 -msgid "" -"The SQL that was used to retrieve the account groups of the parent account " -"group and that failed in the process was" -msgstr "用于查询父账户组的科目组失败的SQL是" +msgid "The SQL that was used to retrieve the account groups of the parent account group and that failed in the process was" +msgstr "用於查詢父帳戶組的科目組失敗的SQL是" -#: AccountGroups.php:57 AccountGroups.php:94 AccountGroups.php:177 +#: AccountGroups.php:57 +#: AccountGroups.php:94 +#: AccountGroups.php:177 #: AccountGroups.php:187 msgid "The SQL that was used to retrieve the information was" -msgstr "用于查找交易数据的SQL是" +msgstr "用於查找交易資料的SQL是" #: AccountGroups.php:58 msgid "Could not check whether the group exists because" -msgstr "未能判定组别是否存在, 因为" +msgstr "未能判定組別是否存在, 因為" #: AccountGroups.php:65 msgid "The account group name already exists in the database" -msgstr "科目组名称已经存在在数据库中。" +msgstr "科目組名稱已經存在在資料庫中。" #: AccountGroups.php:71 msgid "The account group name cannot contain the character" -msgstr "科目组名称不能包含这个字符" +msgstr "科目組名稱不能包含這個字元" -#: AccountGroups.php:71 AccountSections.php:75 PaymentMethods.php:41 -#: TaxCategories.php:33 TaxProvinces.php:32 UnitsOfMeasure.php:32 +#: AccountGroups.php:71 +#: AccountSections.php:75 +#: PaymentMethods.php:41 +#: TaxCategories.php:33 +#: TaxProvinces.php:32 +#: UnitsOfMeasure.php:32 msgid "or the character" -msgstr "或这个字符" +msgstr "或這個字元" #: AccountGroups.php:77 msgid "The account group name must be at least one character long" -msgstr "科目组名称必须不少于 1 个字" +msgstr "科目組名稱必須不少於 1 個字" #: AccountGroups.php:84 -msgid "" -"The parent account group selected appears to result in a recursive account " -"structure - select an alternative parent account group or make this group a " -"top level account group" -msgstr "" -"所选的父账户组看来会导致一个递归的账户结构-选择一个另外的父账户组或者将此账户" -"组作为一个最顶层的账户组" +msgid "The parent account group selected appears to result in a recursive account structure - select an alternative parent account group or make this group a top level account group" +msgstr "所選的父帳戶組看來會導致一個遞迴的帳戶結構-選擇一個另外的父帳戶組或者將此帳戶組作為一個最頂層的帳戶組" #: AccountGroups.php:95 msgid "Could not check whether the group is recursive because" -msgstr "未能检查此组是否递归, 因为" +msgstr "未能檢查此組是否遞迴, 因為" #: AccountGroups.php:107 msgid "The section in accounts must be an integer" -msgstr "会计科目类别必须是整数" +msgstr "會計科目類別必須是整數" #: AccountGroups.php:113 msgid "The sequence in the trial balance must be an integer" -msgstr "试算表内行号必须是整数" +msgstr "試算表內行號必須是整數" #: AccountGroups.php:119 msgid "The sequence in the TB must be numeric and less than" -msgstr "试算表内顺序必须是数字且小于" +msgstr "試算表內順序必須是數位且小於" #: AccountGroups.php:136 msgid "An error occurred in updating the account group" -msgstr "更新科目组是发生了错误" +msgstr "更新科目組是發生了錯誤" #: AccountGroups.php:137 msgid "The SQL that was used to update the account group was" -msgstr "用于更新科目组失败的 SQL 是" +msgstr "用於更新科目組失敗的 SQL 是" -#: AccountGroups.php:139 AccountSections.php:106 PaymentMethods.php:91 +#: AccountGroups.php:139 +#: AccountSections.php:106 +#: PaymentMethods.php:91 msgid "Record Updated" -msgstr "记录已更新" +msgstr "記錄已更新" #: AccountGroups.php:157 msgid "An error occurred in inserting the account group" -msgstr "插入科目组时发生错误, 因为" +msgstr "插入科目組時發生錯誤, 因為" #: AccountGroups.php:158 msgid "The SQL that was used to insert the account group was" -msgstr "用作插入科目组失败的 SQL 是" +msgstr "用作插入科目組失敗的 SQL 是" -#: AccountGroups.php:159 AccountSections.php:118 PaymentMethods.php:113 +#: AccountGroups.php:159 +#: AccountSections.php:118 +#: PaymentMethods.php:113 msgid "Record inserted" -msgstr "记录已新增" +msgstr "記錄已新增" #: AccountGroups.php:176 msgid "An error occurred in retrieving the group information from chartmaster" -msgstr "从主表中查找组信息时发生错误" +msgstr "從主表中查找組資訊時發生錯誤" #: AccountGroups.php:181 -msgid "" -"Cannot delete this account group because general ledger accounts have been " -"created using this group" -msgstr "不能删除,已创建了属于这个科目组的会计科目" +msgid "Cannot delete this account group because general ledger accounts have been created using this group" +msgstr "不能刪除,已創建了屬於這個科目組的會計科目" -#: AccountGroups.php:182 AccountGroups.php:192 AccountSections.php:139 -#: Areas.php:117 Areas.php:126 BankAccounts.php:163 CreditStatus.php:126 -#: Currencies.php:144 Currencies.php:152 Currencies.php:159 -#: CustomerBranches.php:296 CustomerBranches.php:306 CustomerBranches.php:316 -#: CustomerBranches.php:326 Customers.php:317 Customers.php:326 -#: Customers.php:334 Customers.php:342 CustomerTypes.php:149 -#: CustomerTypes.php:159 Factors.php:136 FixedAssetCategories.php:132 -#: GLAccounts.php:95 GLAccounts.php:109 Locations.php:247 Locations.php:255 -#: Locations.php:264 Locations.php:272 Locations.php:280 Locations.php:288 -#: Locations.php:296 Locations.php:304 MRPDemandTypes.php:89 -#: PaymentMethods.php:146 PaymentTerms.php:147 PaymentTerms.php:154 -#: PcExpenses.php:119 SalesCategories.php:127 SalesCategories.php:135 -#: SalesPeople.php:144 SalesPeople.php:151 SalesTypes.php:147 -#: SalesTypes.php:157 Shippers.php:82 Shippers.php:94 StockCategories.php:182 -#: Stocks.php:471 Stocks.php:480 Stocks.php:488 Stocks.php:496 Stocks.php:504 -#: Stocks.php:512 Suppliers.php:613 Suppliers.php:622 Suppliers.php:630 -#: SupplierTypes.php:147 TaxCategories.php:133 TaxGroups.php:128 -#: TaxGroups.php:135 TaxProvinces.php:127 UnitsOfMeasure.php:142 -#: UnitsOfMeasure.php:149 WorkCentres.php:90 WorkCentres.php:96 +#: AccountGroups.php:182 +#: AccountGroups.php:192 +#: AccountSections.php:139 +#: Areas.php:117 +#: Areas.php:126 +#: BankAccounts.php:163 +#: CreditStatus.php:126 +#: Currencies.php:144 +#: Currencies.php:152 +#: Currencies.php:159 +#: CustomerBranches.php:296 +#: CustomerBranches.php:306 +#: CustomerBranches.php:316 +#: CustomerBranches.php:326 +#: Customers.php:317 +#: Customers.php:326 +#: Customers.php:334 +#: Customers.php:342 +#: CustomerTypes.php:149 +#: CustomerTypes.php:159 +#: Factors.php:136 +#: FixedAssetCategories.php:132 +#: GLAccounts.php:95 +#: GLAccounts.php:109 +#: Locations.php:247 +#: Locations.php:255 +#: Locations.php:264 +#: Locations.php:272 +#: Locations.php:280 +#: Locations.php:288 +#: Locations.php:296 +#: Locations.php:304 +#: MRPDemandTypes.php:89 +#: PaymentMethods.php:146 +#: PaymentTerms.php:147 +#: PaymentTerms.php:154 +#: PcExpenses.php:119 +#: SalesCategories.php:127 +#: SalesCategories.php:135 +#: SalesPeople.php:144 +#: SalesPeople.php:151 +#: SalesTypes.php:147 +#: SalesTypes.php:157 +#: Shippers.php:82 +#: Shippers.php:94 +#: StockCategories.php:182 +#: Stocks.php:471 +#: Stocks.php:480 +#: Stocks.php:488 +#: Stocks.php:496 +#: Stocks.php:504 +#: Stocks.php:512 +#: Suppliers.php:613 +#: Suppliers.php:622 +#: Suppliers.php:630 +#: SupplierTypes.php:147 +#: TaxCategories.php:133 +#: TaxGroups.php:128 +#: TaxGroups.php:135 +#: TaxProvinces.php:127 +#: UnitsOfMeasure.php:142 +#: UnitsOfMeasure.php:149 +#: WorkCentres.php:90 +#: WorkCentres.php:96 #: WWW_Access.php:87 msgid "There are" msgstr "存在" #: AccountGroups.php:182 msgid "general ledger accounts that refer to this account group" -msgstr "属于此科目组的会计科目" +msgstr "屬於此科目組的會計科目" #: AccountGroups.php:186 msgid "An error occurred in retrieving the parent group information" -msgstr "查找父组信息时发生错误" +msgstr "查找父組資訊時發生錯誤" #: AccountGroups.php:191 -msgid "" -"Cannot delete this account group because it is a parent account group of " -"other account group(s)" -msgstr "删除会计科目组失败, 由于它是其他账户组的父账户组。" +msgid "Cannot delete this account group because it is a parent account group of other account group(s)" +msgstr "刪除會計科目組失敗, 由於它是其他帳戶組的父帳戶組。" #: AccountGroups.php:192 msgid "account groups that have this group as its/there parent account group" -msgstr "账户组将此账户作为他的/他们的父账户组" +msgstr "帳戶組將此帳戶作為他的/他們的父帳戶組" #: AccountGroups.php:195 msgid "An error occurred in deleting the account group" -msgstr "删除账户组是发生错误" +msgstr "刪除帳戶組是發生錯誤" #: AccountGroups.php:196 msgid "The SQL that was used to delete the account group was" -msgstr "用于账户组的 SQL 是" +msgstr "用於帳戶組的 SQL 是" #: AccountGroups.php:198 msgid "group has been deleted" -msgstr "科目组已删除" +msgstr "科目組已刪除" #: AccountGroups.php:223 msgid "The sql that was used to retrieve the account group information was " -msgstr "用于查询账户组信息的SQL是 " +msgstr "用於查詢帳戶組資訊的SQL是 " #: AccountGroups.php:224 msgid "Could not get account groups because" -msgstr "不能取得科目组, 由于" +msgstr "不能取得科目組, 由於" -#: AccountGroups.php:226 AccountSections.php:177 AddCustomerContacts.php:25 -#: AddCustomerContacts.php:28 AddCustomerNotes.php:97 -#: AddCustomerTypeNotes.php:94 AgedDebtors.php:468 AgedSuppliers.php:277 -#: Areas.php:145 AuditTrail.php:13 BOMExtendedQty.php:286 BOMIndented.php:262 -#: BOMIndentedReverse.php:257 BOMInquiry.php:165 BOMListing.php:128 -#: BOMs.php:214 BOMs.php:793 COGSGLPostings.php:20 CompanyPreferences.php:158 -#: CounterSales.php:1983 CounterSales.php:2107 Credit_Invoice.php:257 -#: CreditStatus.php:21 Currencies.php:29 CustEDISetup.php:19 -#: DailyBankTransactions.php:9 DebtorsAtPeriodEnd.php:138 -#: DiscountCategories.php:12 DiscountCategories.php:122 DiscountMatrix.php:18 -#: EDIMessageFormat.php:106 FixedAssetLocations.php:9 -#: FixedAssetRegister.php:13 FixedAssetRegister.php:238 -#: FixedAssetTransfer.php:31 FormDesigner.php:132 GLBalanceSheet.php:351 -#: GLBudgets.php:30 GLJournal.php:243 InventoryPlanning.php:374 -#: InventoryPlanningPrefSupplier.php:474 Labels.php:117 Labels.php:273 -#: MRPReport.php:536 OutstandingGRNs.php:174 PcAssignCashToTab.php:39 -#: PcAssignCashToTab.php:113 PcAssignCashToTab.php:129 -#: PcAssignCashToTab.php:165 PDFPickingList.php:30 PDFPrintLabel.php:132 -#: PDFStockLocTransfer.php:21 PO_AuthorisationLevels.php:12 POReport.php:61 -#: POReport.php:65 POReport.php:69 PO_SelectOSPurchOrder.php:136 -#: PricesBasedOnMarkUp.php:11 Prices_Customer.php:45 Prices.php:32 -#: PurchData.php:141 PurchData.php:256 PurchData.php:275 -#: RecurringSalesOrders.php:311 SalesAnalReptCols.php:51 SalesAnalRepts.php:13 -#: SalesCategories.php:13 SalesGLPostings.php:18 SalesGraph.php:34 -#: SalesPeople.php:22 SalesTypes.php:22 SelectAsset.php:44 -#: SelectCompletedOrder.php:13 SelectContract.php:81 SelectCreditItems.php:204 -#: SelectCreditItems.php:272 SelectCustomer.php:322 SelectGLAccount.php:19 -#: SelectGLAccount.php:79 SelectOrderItems.php:607 SelectOrderItems.php:1431 -#: SelectOrderItems.php:1555 SelectProduct.php:456 SelectSalesOrder.php:155 -#: SelectSupplier.php:9 SelectSupplier.php:198 SelectWorkOrder.php:11 -#: SelectWorkOrder.php:147 ShipmentCosting.php:13 Shipments.php:18 -#: Shippers.php:123 Shippers.php:159 Shipt_Select.php:10 -#: StockLocMovements.php:15 StockLocStatus.php:27 Suppliers.php:306 -#: SupplierTenders.php:261 SupplierTenders.php:318 SupplierTransInquiry.php:11 -#: TaxGroups.php:16 TaxProvinces.php:12 TopItems.php:65 -#: WhereUsedInquiry.php:18 WorkCentres.php:111 WorkCentres.php:158 -#: WorkOrderCosting.php:14 WorkOrderEntry.php:12 WorkOrderIssue.php:22 -#: WorkOrderReceive.php:15 WorkOrderStatus.php:43 WWW_Access.php:13 -#: WWW_Users.php:38 Z_BottomUpCosts.php:51 +#: AccountGroups.php:226 +#: AccountSections.php:177 +#: AddCustomerContacts.php:25 +#: AddCustomerContacts.php:28 +#: AddCustomerNotes.php:97 +#: AddCustomerTypeNotes.php:94 +#: AgedDebtors.php:468 +#: AgedSuppliers.php:277 +#: Areas.php:145 +#: AuditTrail.php:13 +#: BOMExtendedQty.php:286 +#: BOMIndented.php:262 +#: BOMIndentedReverse.php:257 +#: BOMInquiry.php:165 +#: BOMListing.php:128 +#: BOMs.php:214 +#: BOMs.php:793 +#: COGSGLPostings.php:20 +#: CompanyPreferences.php:158 +#: CounterSales.php:1940 +#: CounterSales.php:2062 +#: Credit_Invoice.php:257 +#: CreditStatus.php:21 +#: Currencies.php:29 +#: CustEDISetup.php:19 +#: DailyBankTransactions.php:9 +#: DebtorsAtPeriodEnd.php:138 +#: DiscountCategories.php:12 +#: DiscountCategories.php:122 +#: DiscountMatrix.php:18 +#: EDIMessageFormat.php:106 +#: FixedAssetList.php:8 +#: FixedAssetLocations.php:9 +#: FixedAssetRegister.php:13 +#: FixedAssetRegister.php:232 +#: FixedAssetTransfer.php:31 +#: FormDesigner.php:132 +#: GLBalanceSheet.php:351 +#: GLBudgets.php:30 +#: GLJournal.php:243 +#: InventoryPlanning.php:369 +#: InventoryPlanningPrefSupplier.php:474 +#: Labels.php:117 +#: Labels.php:273 +#: MRPReport.php:536 +#: OutstandingGRNs.php:174 +#: PcAssignCashToTab.php:39 +#: PcAssignCashToTab.php:113 +#: PcAssignCashToTab.php:129 +#: PcAssignCashToTab.php:165 +#: PDFPickingList.php:30 +#: PDFPrintLabel.php:132 +#: PDFStockLocTransfer.php:21 +#: PO_AuthorisationLevels.php:12 +#: POReport.php:61 +#: POReport.php:65 +#: POReport.php:69 +#: PO_SelectOSPurchOrder.php:136 +#: PricesBasedOnMarkUp.php:11 +#: Prices_Customer.php:45 +#: Prices.php:32 +#: PurchData.php:141 +#: PurchData.php:231 +#: PurchData.php:250 +#: RecurringSalesOrders.php:307 +#: SalesAnalReptCols.php:51 +#: SalesAnalRepts.php:13 +#: SalesCategories.php:13 +#: SalesGLPostings.php:18 +#: SalesGraph.php:34 +#: SalesPeople.php:22 +#: SalesTypes.php:22 +#: SelectAsset.php:44 +#: SelectCompletedOrder.php:13 +#: SelectContract.php:81 +#: SelectCreditItems.php:204 +#: SelectCreditItems.php:272 +#: SelectCustomer.php:315 +#: SelectGLAccount.php:19 +#: SelectGLAccount.php:79 +#: SelectOrderItems.php:605 +#: SelectOrderItems.php:1436 +#: SelectOrderItems.php:1556 +#: SelectProduct.php:456 +#: SelectSalesOrder.php:155 +#: SelectSupplier.php:9 +#: SelectSupplier.php:198 +#: SelectWorkOrder.php:11 +#: SelectWorkOrder.php:147 +#: ShipmentCosting.php:13 +#: Shipments.php:18 +#: Shippers.php:123 +#: Shippers.php:159 +#: Shipt_Select.php:10 +#: StockLocMovements.php:15 +#: StockLocStatus.php:27 +#: Suppliers.php:306 +#: SupplierTenders.php:261 +#: SupplierTenders.php:318 +#: SupplierTransInquiry.php:11 +#: TaxGroups.php:16 +#: TaxProvinces.php:12 +#: TopItems.php:60 +#: WhereUsedInquiry.php:18 +#: WorkCentres.php:111 +#: WorkCentres.php:158 +#: WorkOrderCosting.php:14 +#: WorkOrderEntry.php:12 +#: WorkOrderIssue.php:22 +#: WorkOrderReceive.php:15 +#: WorkOrderStatus.php:43 +#: WWW_Access.php:13 +#: WWW_Users.php:38 +#: Z_BottomUpCosts.php:51 msgid "Search" msgstr "查找" #: AccountGroups.php:230 msgid "Group Name" -msgstr "科目组名称" +msgstr "科目組名稱" -#: AccountGroups.php:231 EDIMessageFormat.php:131 +#: AccountGroups.php:231 +#: EDIMessageFormat.php:131 msgid "Section" -msgstr "会计要素" +msgstr "會計要素" -#: AccountGroups.php:232 AccountGroups.php:396 +#: AccountGroups.php:232 +#: AccountGroups.php:396 msgid "Sequence In TB" -msgstr "试算表行次" +msgstr "試算表行次" -#: AccountGroups.php:233 AccountGroups.php:380 GLProfit_Loss.php:8 -#: GLProfit_Loss.php:105 GLProfit_Loss.php:106 GLProfit_Loss.php:157 -#: SelectGLAccount.php:45 SelectGLAccount.php:59 +#: AccountGroups.php:233 +#: AccountGroups.php:380 +#: GLProfit_Loss.php:8 +#: GLProfit_Loss.php:105 +#: GLProfit_Loss.php:106 +#: GLProfit_Loss.php:157 +#: SelectGLAccount.php:45 +#: SelectGLAccount.php:59 msgid "Profit and Loss" -msgstr "损益类" +msgstr "損益類" -#: AccountGroups.php:234 AccountGroups.php:341 +#: AccountGroups.php:234 +#: AccountGroups.php:341 msgid "Parent Group" -msgstr "父组" +msgstr "父組" -#: AccountGroups.php:250 AccountGroups.php:253 AccountGroups.php:384 -#: AccountGroups.php:386 BankAccounts.php:217 BankAccounts.php:361 -#: BankAccounts.php:363 BankAccounts.php:367 BOMs.php:128 BOMs.php:713 -#: BOMs.php:715 CompanyPreferences.php:439 CompanyPreferences.php:441 -#: CompanyPreferences.php:451 CompanyPreferences.php:453 -#: CompanyPreferences.php:463 CompanyPreferences.php:465 -#: ContractCosting.php:174 CustLoginSetup.php:590 CustLoginSetup.php:592 -#: CustomerBranches.php:420 Customers.php:600 Customers.php:857 -#: Customers.php:864 Customers.php:867 DeliveryDetails.php:1034 -#: DeliveryDetails.php:1074 DeliveryDetails.php:1077 GLTransInquiry.php:73 -#: Locations.php:373 MRPCalendar.php:222 MRP.php:530 MRP.php:534 MRP.php:538 -#: MRP.php:542 PaymentMethods.php:203 PaymentMethods.php:204 -#: PaymentMethods.php:264 PaymentMethods.php:270 PDFChequeListing.php:63 -#: PDFDeliveryDifferences.php:64 PDFDIFOT.php:67 -#: PO_AuthorisationLevels.php:132 PO_AuthorisationLevels.php:137 -#: PO_Header.php:758 PO_PDFPurchOrder.php:344 PO_PDFPurchOrder.php:347 -#: PurchData.php:192 PurchData.php:494 PurchData.php:497 -#: RecurringSalesOrders.php:483 RecurringSalesOrders.php:486 -#: SalesAnalReptCols.php:279 SalesAnalReptCols.php:401 -#: SalesAnalReptCols.php:404 SalesAnalRepts.php:406 SalesAnalRepts.php:409 -#: SalesAnalRepts.php:432 SalesAnalRepts.php:435 SalesAnalRepts.php:458 -#: SalesAnalRepts.php:461 SelectProduct.php:351 ShipmentCosting.php:622 -#: Stocks.php:871 Stocks.php:873 Stocks.php:891 Stocks.php:893 -#: SuppContractChgs.php:83 SuppLoginSetup.php:511 SuppLoginSetup.php:513 -#: SystemParameters.php:376 SystemParameters.php:399 SystemParameters.php:415 -#: SystemParameters.php:468 SystemParameters.php:476 SystemParameters.php:516 -#: SystemParameters.php:589 SystemParameters.php:598 SystemParameters.php:606 -#: SystemParameters.php:624 SystemParameters.php:631 SystemParameters.php:756 -#: SystemParameters.php:887 SystemParameters.php:889 SystemParameters.php:899 -#: SystemParameters.php:901 SystemParameters.php:955 SystemParameters.php:967 -#: SystemParameters.php:969 TaxGroups.php:292 TaxGroups.php:295 -#: TaxGroups.php:344 WWW_Users.php:610 WWW_Users.php:612 +#: AccountGroups.php:250 +#: AccountGroups.php:253 +#: AccountGroups.php:384 +#: AccountGroups.php:386 +#: BankAccounts.php:217 +#: BankAccounts.php:361 +#: BankAccounts.php:363 +#: BankAccounts.php:367 +#: BOMs.php:128 +#: BOMs.php:713 +#: BOMs.php:715 +#: CompanyPreferences.php:439 +#: CompanyPreferences.php:441 +#: CompanyPreferences.php:451 +#: CompanyPreferences.php:453 +#: CompanyPreferences.php:463 +#: CompanyPreferences.php:465 +#: ContractCosting.php:174 +#: CustLoginSetup.php:590 +#: CustLoginSetup.php:592 +#: CustomerBranches.php:420 +#: Customers.php:600 +#: Customers.php:857 +#: Customers.php:864 +#: Customers.php:867 +#: DeliveryDetails.php:1034 +#: DeliveryDetails.php:1074 +#: DeliveryDetails.php:1077 +#: GLTransInquiry.php:73 +#: Locations.php:373 +#: MRPCalendar.php:222 +#: MRP.php:530 +#: MRP.php:534 +#: MRP.php:538 +#: MRP.php:542 +#: PaymentMethods.php:203 +#: PaymentMethods.php:204 +#: PaymentMethods.php:264 +#: PaymentMethods.php:270 +#: PDFChequeListing.php:63 +#: PDFDeliveryDifferences.php:64 +#: PDFDIFOT.php:67 +#: PO_AuthorisationLevels.php:132 +#: PO_AuthorisationLevels.php:137 +#: PO_Header.php:758 +#: PO_PDFPurchOrder.php:367 +#: PO_PDFPurchOrder.php:370 +#: PurchData.php:189 +#: PurchData.php:469 +#: PurchData.php:472 +#: RecurringSalesOrders.php:479 +#: RecurringSalesOrders.php:482 +#: SalesAnalReptCols.php:279 +#: SalesAnalReptCols.php:401 +#: SalesAnalReptCols.php:404 +#: SalesAnalRepts.php:406 +#: SalesAnalRepts.php:409 +#: SalesAnalRepts.php:432 +#: SalesAnalRepts.php:435 +#: SalesAnalRepts.php:458 +#: SalesAnalRepts.php:461 +#: SelectProduct.php:351 +#: ShipmentCosting.php:622 +#: Stocks.php:867 +#: Stocks.php:869 +#: Stocks.php:887 +#: Stocks.php:889 +#: SuppContractChgs.php:83 +#: SuppLoginSetup.php:511 +#: SuppLoginSetup.php:513 +#: SystemParameters.php:373 +#: SystemParameters.php:405 +#: SystemParameters.php:450 +#: SystemParameters.php:468 +#: SystemParameters.php:476 +#: SystemParameters.php:516 +#: SystemParameters.php:589 +#: SystemParameters.php:597 +#: SystemParameters.php:615 +#: SystemParameters.php:622 +#: SystemParameters.php:746 +#: SystemParameters.php:877 +#: SystemParameters.php:879 +#: SystemParameters.php:889 +#: SystemParameters.php:891 +#: SystemParameters.php:945 +#: SystemParameters.php:957 +#: SystemParameters.php:959 +#: TaxGroups.php:292 +#: TaxGroups.php:295 +#: TaxGroups.php:344 +#: WWW_Users.php:610 +#: WWW_Users.php:612 msgid "Yes" msgstr "是" -#: AccountGroups.php:256 AccountGroups.php:389 AccountGroups.php:391 -#: BankAccounts.php:215 BankAccounts.php:361 BankAccounts.php:363 -#: BankAccounts.php:367 BOMs.php:130 BOMs.php:712 BOMs.php:716 -#: CompanyPreferences.php:438 CompanyPreferences.php:442 -#: CompanyPreferences.php:450 CompanyPreferences.php:454 -#: CompanyPreferences.php:462 CompanyPreferences.php:466 -#: ContractCosting.php:172 CustLoginSetup.php:589 CustLoginSetup.php:593 -#: CustomerBranches.php:420 Customers.php:599 Customers.php:855 -#: Customers.php:863 Customers.php:866 DeliveryDetails.php:1035 -#: DeliveryDetails.php:1075 DeliveryDetails.php:1078 GLTransInquiry.php:127 -#: Locations.php:375 MRPCalendar.php:224 MRP.php:528 MRP.php:532 MRP.php:536 -#: MRP.php:540 PaymentMethods.php:203 PaymentMethods.php:204 -#: PaymentMethods.php:265 PaymentMethods.php:271 PDFChequeListing.php:62 -#: PDFDeliveryDifferences.php:63 PDFDIFOT.php:66 -#: PO_AuthorisationLevels.php:134 PO_AuthorisationLevels.php:139 -#: PO_Header.php:757 PO_PDFPurchOrder.php:345 PO_PDFPurchOrder.php:348 -#: PurchData.php:195 PurchData.php:495 PurchData.php:498 -#: RecurringSalesOrders.php:482 RecurringSalesOrders.php:485 -#: SalesAnalReptCols.php:277 SalesAnalReptCols.php:402 -#: SalesAnalReptCols.php:405 SalesAnalRepts.php:405 SalesAnalRepts.php:408 -#: SalesAnalRepts.php:431 SalesAnalRepts.php:434 SalesAnalRepts.php:457 -#: SalesAnalRepts.php:460 SelectProduct.php:353 ShipmentCosting.php:623 -#: Stocks.php:866 Stocks.php:868 Stocks.php:886 Stocks.php:888 -#: SuppContractChgs.php:85 SuppLoginSetup.php:510 SuppLoginSetup.php:514 -#: SystemParameters.php:377 SystemParameters.php:400 SystemParameters.php:416 -#: SystemParameters.php:469 SystemParameters.php:477 SystemParameters.php:517 -#: SystemParameters.php:590 SystemParameters.php:599 SystemParameters.php:607 -#: SystemParameters.php:625 SystemParameters.php:632 SystemParameters.php:757 -#: SystemParameters.php:886 SystemParameters.php:890 SystemParameters.php:898 -#: SystemParameters.php:902 SystemParameters.php:956 SystemParameters.php:966 -#: SystemParameters.php:970 TaxGroups.php:293 TaxGroups.php:296 -#: TaxGroups.php:346 WWW_Users.php:609 WWW_Users.php:613 -#: includes/PDFLowGPPageHeader.inc:44 includes/PDFTaxPageHeader.inc:35 +#: AccountGroups.php:256 +#: AccountGroups.php:389 +#: AccountGroups.php:391 +#: BankAccounts.php:215 +#: BankAccounts.php:361 +#: BankAccounts.php:363 +#: BankAccounts.php:367 +#: BOMs.php:130 +#: BOMs.php:712 +#: BOMs.php:716 +#: CompanyPreferences.php:438 +#: CompanyPreferences.php:442 +#: CompanyPreferences.php:450 +#: CompanyPreferences.php:454 +#: CompanyPreferences.php:462 +#: CompanyPreferences.php:466 +#: ContractCosting.php:172 +#: CustLoginSetup.php:589 +#: CustLoginSetup.php:593 +#: CustomerBranches.php:420 +#: Customers.php:599 +#: Customers.php:855 +#: Customers.php:863 +#: Customers.php:866 +#: DeliveryDetails.php:1035 +#: DeliveryDetails.php:1075 +#: DeliveryDetails.php:1078 +#: GLTransInquiry.php:127 +#: Locations.php:375 +#: MRPCalendar.php:224 +#: MRP.php:528 +#: MRP.php:532 +#: MRP.php:536 +#: MRP.php:540 +#: PaymentMethods.php:203 +#: PaymentMethods.php:204 +#: PaymentMethods.php:265 +#: PaymentMethods.php:271 +#: PDFChequeListing.php:62 +#: PDFDeliveryDifferences.php:63 +#: PDFDIFOT.php:66 +#: PO_AuthorisationLevels.php:134 +#: PO_AuthorisationLevels.php:139 +#: PO_Header.php:757 +#: PO_PDFPurchOrder.php:368 +#: PO_PDFPurchOrder.php:371 +#: PurchData.php:192 +#: PurchData.php:470 +#: PurchData.php:473 +#: RecurringSalesOrders.php:478 +#: RecurringSalesOrders.php:481 +#: SalesAnalReptCols.php:277 +#: SalesAnalReptCols.php:402 +#: SalesAnalReptCols.php:405 +#: SalesAnalRepts.php:405 +#: SalesAnalRepts.php:408 +#: SalesAnalRepts.php:431 +#: SalesAnalRepts.php:434 +#: SalesAnalRepts.php:457 +#: SalesAnalRepts.php:460 +#: SelectProduct.php:353 +#: ShipmentCosting.php:623 +#: Stocks.php:862 +#: Stocks.php:864 +#: Stocks.php:882 +#: Stocks.php:884 +#: SuppContractChgs.php:85 +#: SuppLoginSetup.php:510 +#: SuppLoginSetup.php:514 +#: SystemParameters.php:374 +#: SystemParameters.php:406 +#: SystemParameters.php:451 +#: SystemParameters.php:469 +#: SystemParameters.php:477 +#: SystemParameters.php:517 +#: SystemParameters.php:590 +#: SystemParameters.php:598 +#: SystemParameters.php:616 +#: SystemParameters.php:623 +#: SystemParameters.php:747 +#: SystemParameters.php:876 +#: SystemParameters.php:880 +#: SystemParameters.php:888 +#: SystemParameters.php:892 +#: SystemParameters.php:946 +#: SystemParameters.php:956 +#: SystemParameters.php:960 +#: TaxGroups.php:293 +#: TaxGroups.php:296 +#: TaxGroups.php:346 +#: WWW_Users.php:609 +#: WWW_Users.php:613 +#: includes/PDFLowGPPageHeader.inc:44 +#: includes/PDFTaxPageHeader.inc:35 msgid "No" msgstr "否" -#: AccountGroups.php:265 AccountSections.php:197 AddCustomerContacts.php:131 -#: AddCustomerNotes.php:125 AddCustomerTypeNotes.php:123 Areas.php:165 -#: BankAccounts.php:226 BOMs.php:150 COGSGLPostings.php:113 -#: COGSGLPostings.php:218 CreditStatus.php:175 Currencies.php:239 -#: CustLoginSetup.php:312 CustomerBranches.php:424 Customers.php:909 -#: Customers.php:941 CustomerTypes.php:205 EDIMessageFormat.php:152 -#: Factors.php:208 FixedAssetCategories.php:182 FixedAssetLocations.php:102 -#: FreightCosts.php:243 GeocodeSetup.php:169 GLAccounts.php:319 GLTags.php:62 -#: Labels.php:414 Locations.php:382 MRPDemands.php:304 MRPDemandTypes.php:122 -#: PaymentMethods.php:205 PaymentTerms.php:203 PcAssignCashToTab.php:251 -#: PcClaimExpensesFromTab.php:229 PcExpenses.php:176 PcTabs.php:188 -#: PcTypeTabs.php:171 PO_AuthorisationLevels.php:148 Prices_Customer.php:283 -#: Prices.php:227 PurchData.php:207 SalesCategories.php:263 -#: SalesGLPostings.php:135 SalesGLPostings.php:247 SalesPeople.php:210 -#: SalesTypes.php:206 SelectCustomer.php:609 SelectCustomer.php:625 -#: SelectCustomer.php:647 SelectCustomer.php:663 SelectCustomer.php:685 -#: SelectCustomer.php:701 Shippers.php:144 StockCategories.php:244 -#: SupplierContacts.php:153 SupplierTypes.php:192 SuppLoginSetup.php:274 -#: TaxAuthorities.php:173 TaxCategories.php:184 TaxGroups.php:179 -#: TaxProvinces.php:178 UnitsOfMeasure.php:201 WorkCentres.php:138 -#: WWW_Access.php:127 WWW_Users.php:312 includes/InputSerialItems.php:88 +#: AccountGroups.php:265 +#: AccountSections.php:197 +#: AddCustomerContacts.php:131 +#: AddCustomerNotes.php:125 +#: AddCustomerTypeNotes.php:123 +#: Areas.php:165 +#: BankAccounts.php:226 +#: BOMs.php:150 +#: COGSGLPostings.php:113 +#: COGSGLPostings.php:218 +#: CreditStatus.php:175 +#: Currencies.php:239 +#: CustLoginSetup.php:312 +#: CustomerBranches.php:424 +#: Customers.php:909 +#: Customers.php:941 +#: CustomerTypes.php:205 +#: EDIMessageFormat.php:152 +#: Factors.php:208 +#: FixedAssetCategories.php:182 +#: FixedAssetLocations.php:102 +#: FreightCosts.php:243 +#: GeocodeSetup.php:169 +#: GLAccounts.php:319 +#: GLTags.php:62 +#: Labels.php:414 +#: Locations.php:382 +#: MRPDemands.php:304 +#: MRPDemandTypes.php:122 +#: PaymentMethods.php:205 +#: PaymentTerms.php:203 +#: PcAssignCashToTab.php:251 +#: PcClaimExpensesFromTab.php:229 +#: PcExpenses.php:176 +#: PcTabs.php:188 +#: PcTypeTabs.php:171 +#: PO_AuthorisationLevels.php:148 +#: Prices_Customer.php:283 +#: Prices.php:227 +#: PurchData.php:202 +#: SalesCategories.php:263 +#: SalesGLPostings.php:135 +#: SalesGLPostings.php:247 +#: SalesPeople.php:210 +#: SalesTypes.php:206 +#: SelectCustomer.php:607 +#: SelectCustomer.php:623 +#: SelectCustomer.php:645 +#: SelectCustomer.php:661 +#: SelectCustomer.php:683 +#: SelectCustomer.php:699 +#: Shippers.php:144 +#: StockCategories.php:244 +#: SupplierContacts.php:156 +#: SupplierTypes.php:192 +#: SuppLoginSetup.php:274 +#: TaxAuthorities.php:173 +#: TaxCategories.php:184 +#: TaxGroups.php:179 +#: TaxProvinces.php:178 +#: UnitsOfMeasure.php:201 +#: WorkCentres.php:138 +#: WWW_Access.php:127 +#: WWW_Users.php:312 +#: includes/InputSerialItems.php:88 #, php-format msgid "Edit" -msgstr "编辑" +msgstr "編輯" -#: AccountGroups.php:266 AccountSections.php:201 AddCustomerContacts.php:132 -#: AddCustomerNotes.php:126 AddCustomerTypeNotes.php:124 Areas.php:166 -#: BankAccounts.php:227 BOMs.php:152 COGSGLPostings.php:114 -#: COGSGLPostings.php:219 ContractBOM.php:272 ContractOtherReqts.php:121 -#: CounterSales.php:781 Credit_Invoice.php:386 CreditStatus.php:176 -#: Currencies.php:242 CustLoginSetup.php:313 CustomerReceipt.php:866 -#: Customers.php:942 CustomerTypes.php:206 DiscountCategories.php:204 -#: DiscountMatrix.php:178 EDIMessageFormat.php:153 -#: FixedAssetCategories.php:183 FreightCosts.php:244 GeocodeSetup.php:170 -#: GLAccounts.php:320 GLJournal.php:403 Labels.php:414 Locations.php:383 -#: MRPDemands.php:305 MRPDemandTypes.php:123 PaymentMethods.php:206 -#: Payments.php:958 PaymentTerms.php:204 PcAssignCashToTab.php:255 -#: PcClaimExpensesFromTab.php:230 PcExpenses.php:177 PcExpensesTypeTab.php:161 -#: PcTabs.php:189 PcTypeTabs.php:172 PO_AuthorisationLevels.php:150 -#: PO_Items.php:758 Prices_Customer.php:284 Prices.php:228 PurchData.php:208 -#: SalesAnalReptCols.php:294 SalesAnalRepts.php:305 SalesCategories.php:264 -#: SalesGLPostings.php:136 SalesGLPostings.php:248 SalesPeople.php:211 -#: SalesTypes.php:207 SelectCreditItems.php:747 SelectCustomer.php:610 -#: SelectCustomer.php:626 SelectCustomer.php:648 SelectCustomer.php:664 -#: SelectCustomer.php:686 SelectCustomer.php:702 SelectOrderItems.php:1358 -#: Shipments.php:424 Shippers.php:145 SpecialOrder.php:590 -#: StockCategories.php:245 StockCategories.php:539 SuppContractChgs.php:91 -#: SuppCreditGRNs.php:93 SuppFixedAssetChgs.php:81 SuppInvGRNs.php:135 -#: SupplierContacts.php:154 SupplierTypes.php:194 SuppLoginSetup.php:275 -#: SuppShiptChgs.php:86 SuppTransGLAnalysis.php:111 TaxAuthorities.php:174 -#: TaxCategories.php:185 TaxGroups.php:180 TaxProvinces.php:179 -#: UnitsOfMeasure.php:202 WorkCentres.php:139 WOSerialNos.php:300 -#: WWW_Access.php:128 WWW_Users.php:313 includes/InputSerialItemsKeyed.php:54 +#: AccountGroups.php:266 +#: AccountSections.php:201 +#: AddCustomerContacts.php:132 +#: AddCustomerNotes.php:126 +#: AddCustomerTypeNotes.php:124 +#: Areas.php:166 +#: BankAccounts.php:227 +#: BOMs.php:152 +#: COGSGLPostings.php:114 +#: COGSGLPostings.php:219 +#: ContractBOM.php:272 +#: ContractOtherReqts.php:121 +#: CounterSales.php:741 +#: Credit_Invoice.php:386 +#: CreditStatus.php:176 +#: Currencies.php:242 +#: CustLoginSetup.php:313 +#: CustomerReceipt.php:866 +#: Customers.php:942 +#: CustomerTypes.php:206 +#: DiscountCategories.php:204 +#: DiscountMatrix.php:178 +#: EDIMessageFormat.php:153 +#: FixedAssetCategories.php:183 +#: FreightCosts.php:244 +#: GeocodeSetup.php:170 +#: GLAccounts.php:320 +#: GLJournal.php:403 +#: Labels.php:414 +#: Locations.php:383 +#: MRPDemands.php:305 +#: MRPDemandTypes.php:123 +#: PaymentMethods.php:206 +#: Payments.php:961 +#: PaymentTerms.php:204 +#: PcAssignCashToTab.php:255 +#: PcClaimExpensesFromTab.php:230 +#: PcExpenses.php:177 +#: PcExpensesTypeTab.php:161 +#: PcTabs.php:189 +#: PcTypeTabs.php:172 +#: PO_AuthorisationLevels.php:150 +#: PO_Items.php:976 +#: Prices_Customer.php:284 +#: Prices.php:228 +#: PurchData.php:203 +#: SalesAnalReptCols.php:294 +#: SalesAnalRepts.php:305 +#: SalesCategories.php:264 +#: SalesGLPostings.php:136 +#: SalesGLPostings.php:248 +#: SalesPeople.php:211 +#: SalesTypes.php:207 +#: SelectCreditItems.php:747 +#: SelectCustomer.php:608 +#: SelectCustomer.php:624 +#: SelectCustomer.php:646 +#: SelectCustomer.php:662 +#: SelectCustomer.php:684 +#: SelectCustomer.php:700 +#: SelectOrderItems.php:1363 +#: Shipments.php:424 +#: Shippers.php:145 +#: SpecialOrder.php:590 +#: StockCategories.php:245 +#: StockCategories.php:539 +#: SuppContractChgs.php:91 +#: SuppCreditGRNs.php:93 +#: SuppFixedAssetChgs.php:87 +#: SuppInvGRNs.php:135 +#: SupplierContacts.php:157 +#: SupplierTypes.php:194 +#: SuppLoginSetup.php:275 +#: SuppShiptChgs.php:86 +#: SuppTransGLAnalysis.php:111 +#: TaxAuthorities.php:174 +#: TaxCategories.php:185 +#: TaxGroups.php:180 +#: TaxProvinces.php:179 +#: UnitsOfMeasure.php:202 +#: WorkCentres.php:139 +#: WOSerialNos.php:300 +#: WWW_Access.php:128 +#: WWW_Users.php:313 +#: includes/InputSerialItemsKeyed.php:54 #, php-format msgid "Delete" -msgstr "删除" +msgstr "刪除" #: AccountGroups.php:274 msgid "Review Account Groups" -msgstr "查看科目组" +msgstr "查看科目組" #: AccountGroups.php:294 msgid "An error occurred in retrieving the account group information" -msgstr "查找账户组信息时发生错误" +msgstr "查找帳戶組資訊時發生錯誤" #: AccountGroups.php:295 -msgid "" -"The SQL that was used to retrieve the account group and that failed in the " -"process was" -msgstr "用于查询科目组失败的SQL是" +msgid "The SQL that was used to retrieve the account group and that failed in the process was" +msgstr "用於查詢科目組失敗的SQL是" #: AccountGroups.php:298 msgid "The account group name does not exist in the database" -msgstr "科目组名称在数据库中不存在。" +msgstr "科目組名稱在資料庫中不存在。" -#: AccountGroups.php:314 GLAccounts.php:250 GLAccounts.php:299 +#: AccountGroups.php:314 +#: GLAccounts.php:250 +#: GLAccounts.php:299 #: Z_ImportGLAccountGroups.php:28 msgid "Account Group" -msgstr "科目组" +msgstr "科目組" #: AccountGroups.php:338 msgid "Account Group Name" -msgstr "科目组名称" +msgstr "科目組名稱" -#: AccountGroups.php:348 AccountGroups.php:350 +#: AccountGroups.php:348 +#: AccountGroups.php:350 msgid "Top Level Group" -msgstr "顶层组" +msgstr "頂層組" #: AccountGroups.php:364 msgid "Section In Accounts" -msgstr "会计要素" +msgstr "會計要素" -#: AccountGroups.php:401 AccountSections.php:262 AddCustomerContacts.php:208 -#: AddCustomerNotes.php:201 AddCustomerTypeNotes.php:192 Areas.php:222 -#: BankAccounts.php:373 BOMs.php:725 COGSGLPostings.php:347 -#: CreditStatus.php:247 Currencies.php:339 CustLoginSetup.php:611 -#: DiscountMatrix.php:141 EDIMessageFormat.php:249 -#: FixedAssetCategories.php:328 FixedAssetLocations.php:148 -#: FreightCosts.php:342 GeocodeSetup.php:266 GLAccounts.php:269 -#: Locations.php:553 MRPDemands.php:402 MRPDemandTypes.php:182 -#: OffersReceived.php:52 OffersReceived.php:128 PaymentMethods.php:276 -#: PaymentTerms.php:282 PO_AuthorisationLevels.php:217 Prices_Customer.php:372 -#: SalesAnalReptCols.php:510 SalesAnalRepts.php:496 SalesGLPostings.php:415 -#: SalesPeople.php:302 Shippers.php:196 StockCategories.php:561 -#: SupplierContacts.php:250 SuppLoginSetup.php:532 TaxAuthorities.php:313 -#: TaxCategories.php:235 TaxProvinces.php:229 UnitsOfMeasure.php:253 -#: WorkCentres.php:261 WWW_Users.php:643 +#: AccountGroups.php:401 +#: AccountSections.php:262 +#: AddCustomerContacts.php:208 +#: AddCustomerNotes.php:201 +#: AddCustomerTypeNotes.php:192 +#: Areas.php:222 +#: BankAccounts.php:373 +#: BOMs.php:725 +#: COGSGLPostings.php:347 +#: CreditStatus.php:247 +#: Currencies.php:339 +#: CustLoginSetup.php:611 +#: DiscountMatrix.php:141 +#: EDIMessageFormat.php:249 +#: FixedAssetCategories.php:328 +#: FixedAssetLocations.php:148 +#: FreightCosts.php:342 +#: GeocodeSetup.php:266 +#: GLAccounts.php:269 +#: Locations.php:553 +#: MRPDemands.php:402 +#: MRPDemandTypes.php:182 +#: OffersReceived.php:52 +#: OffersReceived.php:128 +#: PaymentMethods.php:276 +#: PaymentTerms.php:282 +#: PO_AuthorisationLevels.php:217 +#: Prices_Customer.php:372 +#: SalesAnalReptCols.php:510 +#: SalesAnalRepts.php:496 +#: SalesGLPostings.php:415 +#: SalesPeople.php:302 +#: Shippers.php:196 +#: StockCategories.php:561 +#: SupplierContacts.php:251 +#: SuppLoginSetup.php:532 +#: TaxAuthorities.php:313 +#: TaxCategories.php:235 +#: TaxProvinces.php:229 +#: UnitsOfMeasure.php:253 +#: WorkCentres.php:261 +#: WWW_Users.php:643 msgid "Enter Information" msgstr "保存" -#: AccountSections.php:9 index.php:1273 +#: AccountSections.php:9 +#: index.php:1278 msgid "Account Sections" -msgstr "会计要素" +msgstr "會計要素" #: AccountSections.php:68 msgid "The account section already exists in the database" -msgstr "会计要素已经存在于数据库" +msgstr "會計要素已經存在於資料庫" #: AccountSections.php:75 msgid "The account section name cannot contain the character" -msgstr "会计要素不能包含这个字符" +msgstr "會計要素不能包含這個字元" #: AccountSections.php:81 msgid "The account section name must contain at least one character" -msgstr "会计要素名称必须包含至少一个字符" +msgstr "會計要素名稱必須包含至少一個字元" -#: AccountSections.php:87 AccountSections.php:93 +#: AccountSections.php:87 +#: AccountSections.php:93 msgid "The section number must be an integer" -msgstr "会计要素编号必须是整数" +msgstr "會計要素編號必須是整數" #: AccountSections.php:138 -msgid "" -"Cannot delete this account section because general ledger accounts groups " -"have been created using this section" -msgstr "此会计要素已被科目组使用,不能删除" +msgid "Cannot delete this account section because general ledger accounts groups have been created using this section" +msgstr "此會計要素已被科目組使用,不能刪除" #: AccountSections.php:139 msgid "general ledger accounts groups that refer to this account section" -msgstr "个科目组需要此会计要素" +msgstr "個科目組需要此會計要素" #: AccountSections.php:150 msgid "section has been deleted" -msgstr "删除会计要素成功" +msgstr "刪除會計要素成功" #: AccountSections.php:175 msgid "Could not get account group sections because" -msgstr "找不到会计要素,原因是:" +msgstr "找不到會計要素,原因是:" -#: AccountSections.php:181 AccountSections.php:238 AccountSections.php:255 +#: AccountSections.php:181 +#: AccountSections.php:238 +#: AccountSections.php:255 msgid "Section Number" -msgstr "会计要素编号" +msgstr "會計要素編號" -#: AccountSections.php:182 AccountSections.php:258 +#: AccountSections.php:182 +#: AccountSections.php:258 msgid "Section Description" -msgstr "会计要素名称" +msgstr "會計要素名稱" #: AccountSections.php:199 msgid "Restricted" @@ -480,220 +859,315 @@ #: AccountSections.php:210 msgid "Review Account Sections" -msgstr "查看会计要素" +msgstr "查看會計要素" #: AccountSections.php:228 msgid "Could not retrieve the requested section please try again." -msgstr "找不到会计要素, 请重试" +msgstr "找不到會計要素, 請重試" -#: AddCustomerContacts.php:6 AddCustomerContacts.php:59 SelectCustomer.php:603 -#: SelectCustomer.php:632 +#: AddCustomerContacts.php:6 +#: AddCustomerContacts.php:59 +#: SelectCustomer.php:601 +#: SelectCustomer.php:630 msgid "Customer Contacts" -msgstr "顾客联系人" +msgstr "顧客聯繫人" -#: AddCustomerContacts.php:20 CustEDISetup.php:11 CustLoginSetup.php:24 +#: AddCustomerContacts.php:20 +#: CustEDISetup.php:11 +#: CustLoginSetup.php:24 #: Z_CheckDebtorsControl.php:21 msgid "Back to Customers" -msgstr "返回客户" +msgstr "返回客戶" #: AddCustomerContacts.php:26 msgid "Contacts for Customer: <b>" -msgstr "客户的联系人" +msgstr "客戶的聯繫人" #: AddCustomerContacts.php:29 msgid "Edit contact for <b>" -msgstr "编辑联系人" +msgstr "編輯聯繫人" #: AddCustomerContacts.php:41 msgid "The Contact must be an integer." -msgstr "联系人必须是整数" +msgstr "聯繫人必須是整數" #: AddCustomerContacts.php:44 msgid "The contact's name must be forty characters or less long" -msgstr "联系人名称必须不多于50个字符" +msgstr "聯繫人名稱必須不多於50個字元" #: AddCustomerContacts.php:47 msgid "The contact's name may not be empty" -msgstr "联系人名称不能留空" +msgstr "聯繫人名稱不能留空" -#: AddCustomerContacts.php:59 AddCustomerNotes.php:49 -#: AddCustomerTypeNotes.php:49 Areas.php:74 CustomerTypes.php:71 -#: DeliveryDetails.php:748 Factors.php:117 FixedAssetItems.php:230 -#: PcAssignCashToTab.php:73 PcClaimExpensesFromTab.php:61 PcExpenses.php:60 -#: PcTabs.php:60 PcTypeTabs.php:59 PO_Items.php:412 SalesAnalReptCols.php:129 -#: SalesPeople.php:94 SalesTypes.php:63 Stocks.php:355 Suppliers.php:514 +#: AddCustomerContacts.php:59 +#: AddCustomerNotes.php:49 +#: AddCustomerTypeNotes.php:49 +#: Areas.php:74 +#: CustomerTypes.php:71 +#: DeliveryDetails.php:748 +#: Factors.php:117 +#: FixedAssetItems.php:230 +#: PcAssignCashToTab.php:73 +#: PcClaimExpensesFromTab.php:61 +#: PcExpenses.php:60 +#: PcTabs.php:60 +#: PcTypeTabs.php:59 +#: PO_Items.php:381 +#: SalesAnalReptCols.php:129 +#: SalesPeople.php:94 +#: SalesTypes.php:63 +#: Stocks.php:355 +#: Suppliers.php:514 #: SupplierTypes.php:69 msgid "has been updated" msgstr "已更新" #: AddCustomerContacts.php:70 msgid "The contact record has been added" -msgstr "联系人已新增" +msgstr "聯繫人已新增" #: AddCustomerContacts.php:98 msgid "The contact record has been deleted" -msgstr "联系人记录已删除" +msgstr "聯繫人記錄已刪除" -#: AddCustomerContacts.php:112 CompanyPreferences.php:229 -#: CustomerBranches.php:377 Customers.php:899 Customers.php:905 -#: Customers.php:971 SalesPeople.php:185 SelectCustomer.php:605 -#: StockDispatch.php:186 StockDispatch.php:198 SupplierContacts.php:141 -#: SupplierCredit.php:433 SupplierInvoice.php:408 SuppTransGLAnalysis.php:96 -#: includes/InputSerialItemsFile.php:84 includes/InputSerialItemsFile.php:124 +#: AddCustomerContacts.php:112 +#: CompanyPreferences.php:229 +#: CustomerBranches.php:377 +#: Customers.php:899 +#: Customers.php:905 +#: Customers.php:971 +#: SalesPeople.php:185 +#: SelectCustomer.php:603 +#: StockDispatch.php:186 +#: StockDispatch.php:198 +#: SupplierContacts.php:144 +#: SupplierCredit.php:433 +#: SupplierInvoice.php:407 +#: SuppTransGLAnalysis.php:96 +#: includes/InputSerialItemsFile.php:84 +#: includes/InputSerialItemsFile.php:124 #: includes/PDFTaxPageHeader.inc:37 msgid "Name" -msgstr "名称" +msgstr "名稱" -#: AddCustomerContacts.php:113 AddCustomerContacts.php:190 Customers.php:900 -#: Customers.php:906 Customers.php:972 SelectCustomer.php:606 -#: WWW_Access.php:111 WWW_Access.php:172 +#: AddCustomerContacts.php:113 +#: AddCustomerContacts.php:190 +#: Customers.php:900 +#: Customers.php:906 +#: Customers.php:972 +#: SelectCustomer.php:604 +#: WWW_Access.php:111 +#: WWW_Access.php:172 msgid "Role" -msgstr "职位" +msgstr "職位" -#: AddCustomerContacts.php:114 Customers.php:973 +#: AddCustomerContacts.php:114 +#: Customers.php:973 msgid "Phone no" -msgstr "电话" +msgstr "電話" -#: AddCustomerContacts.php:115 AddCustomerContacts.php:202 Customers.php:902 -#: Customers.php:908 Customers.php:974 PcAssignCashToTab.php:216 -#: PcAssignCashToTab.php:341 PcAuthorizeExpenses.php:85 -#: PcClaimExpensesFromTab.php:195 PcClaimExpensesFromTab.php:348 -#: PcReportTab.php:348 SelectCustomer.php:608 SystemParameters.php:316 -#: WOSerialNos.php:277 WOSerialNos.php:279 +#: AddCustomerContacts.php:115 +#: AddCustomerContacts.php:202 +#: Customers.php:902 +#: Customers.php:908 +#: Customers.php:974 +#: PcAssignCashToTab.php:216 +#: PcAssignCashToTab.php:341 +#: PcAuthorizeExpenses.php:85 +#: PcClaimExpensesFromTab.php:195 +#: PcClaimExpensesFromTab.php:348 +#: PcReportTab.php:348 +#: SelectCustomer.php:606 +#: SystemParameters.php:313 +#: WOSerialNos.php:277 +#: WOSerialNos.php:279 msgid "Notes" -msgstr "备注" +msgstr "備註" #: AddCustomerContacts.php:149 msgid "Review all contacts for this Customer" -msgstr "查看此顾客的所有联络人" +msgstr "查看此顧客的所有聯絡人" #: AddCustomerContacts.php:179 msgid "Contact Code" -msgstr "联系人代码" +msgstr "聯繫人代碼" -#: AddCustomerContacts.php:184 Factors.php:279 SupplierContacts.php:218 +#: AddCustomerContacts.php:184 +#: Factors.php:279 +#: SupplierContacts.php:219 msgid "Contact Name" -msgstr "联系人名称" +msgstr "聯繫人名稱" -#: AddCustomerContacts.php:196 Contracts.php:777 PDFRemittanceAdvice.php:247 -#: PO_Header.php:958 PO_Header.php:1028 SelectCreditItems.php:225 -#: SelectCustomer.php:463 SelectOrderItems.php:639 -#: includes/PDFStatementPageHeader.inc:63 includes/PDFTransPageHeader.inc:117 +#: AddCustomerContacts.php:196 +#: Contracts.php:766 +#: PDFRemittanceAdvice.php:247 +#: PO_Header.php:958 +#: PO_Header.php:1028 +#: SelectCreditItems.php:225 +#: SelectCustomer.php:461 +#: SelectOrderItems.php:638 +#: includes/PDFStatementPageHeader.inc:63 +#: includes/PDFTransPageHeader.inc:113 #: includes/PDFTransPageHeaderPortrait.inc:105 msgid "Phone" -msgstr "电话" +msgstr "電話" -#: AddCustomerNotes.php:6 AddCustomerNotes.php:49 SelectCustomer.php:640 -#: SelectCustomer.php:670 +#: AddCustomerNotes.php:6 +#: AddCustomerNotes.php:49 +#: SelectCustomer.php:638 +#: SelectCustomer.php:668 msgid "Customer Notes" -msgstr "客户通知" +msgstr "客戶通知" -#: AddCustomerNotes.php:20 AddCustomerTypeNotes.php:20 +#: AddCustomerNotes.php:20 +#: AddCustomerTypeNotes.php:20 msgid "Back to Select Customer" -msgstr "返回选择客户" +msgstr "返回選擇客戶" #: AddCustomerNotes.php:31 msgid "The contact priority must be an integer." -msgstr "联系优先级必须是整数" +msgstr "聯繫優先順序必須是整數" -#: AddCustomerNotes.php:34 AddCustomerTypeNotes.php:34 +#: AddCustomerNotes.php:34 +#: AddCustomerTypeNotes.php:34 msgid "The contact's notes must be two hundred characters or less long" -msgstr "联系人备注必须不多于200个字符" +msgstr "聯繫人備註必須不多於200個字元" -#: AddCustomerNotes.php:37 AddCustomerTypeNotes.php:37 +#: AddCustomerNotes.php:37 +#: AddCustomerTypeNotes.php:37 msgid "The contact's notes may not be empty" -msgstr "联系人备注不能留空" +msgstr "聯繫人備註不能留空" #: AddCustomerNotes.php:60 msgid "The contact notes record has been added" -msgstr "联系人备注记录已新增" +msgstr "聯繫人備註記錄已新增" #: AddCustomerNotes.php:87 msgid "The contact note record has been deleted" -msgstr "联系人备注记录已删除" +msgstr "聯繫人備註記錄已刪除" #: AddCustomerNotes.php:98 msgid "Notes for Customer" -msgstr "客户通知:" +msgstr "客戶通知:" -#: AddCustomerNotes.php:106 AddCustomerNotes.php:189 -#: AddCustomerTypeNotes.php:104 AddCustomerTypeNotes.php:186 -#: BankMatching.php:223 BankReconciliation.php:184 BankReconciliation.php:256 -#: ContractCosting.php:149 CustomerAllocations.php:332 -#: CustomerAllocations.php:358 CustomerInquiry.php:191 -#: CustomerTransInquiry.php:87 GLAccountInquiry.php:154 -#: GLAccountReport.php:369 GLTransInquiry.php:45 MRPCalendar.php:217 -#: PaymentAllocations.php:77 PcAssignCashToTab.php:212 -#: PcAuthorizeExpenses.php:81 PDFRemittanceAdvice.php:308 -#: PrintCustTrans.php:616 PrintCustTransPortrait.php:790 ReverseGRN.php:378 -#: ShipmentCosting.php:503 ShipmentCosting.php:574 Shipments.php:467 -#: StockDispatch.php:188 StockDispatch.php:200 StockLocMovements.php:85 -#: StockMovements.php:98 StockSerialItemResearch.php:79 -#: SupplierAllocations.php:464 SupplierAllocations.php:576 -#: SupplierAllocations.php:646 SupplierInquiry.php:195 -#: SupplierTransInquiry.php:89 includes/PDFQuotationPageHeader.inc:91 -#: includes/PDFStatementPageHeader.inc:169 includes/PDFTaxPageHeader.inc:36 -#: includes/PDFTransPageHeader.inc:84 +#: AddCustomerNotes.php:106 +#: AddCustomerNotes.php:189 +#: AddCustomerTypeNotes.php:104 +#: AddCustomerTypeNotes.php:186 +#: BankMatching.php:223 +#: BankReconciliation.php:184 +#: BankReconciliation.php:256 +#: ContractCosting.php:149 +#: CustomerAllocations.php:332 +#: CustomerAllocations.php:358 +#: CustomerInquiry.php:191 +#: CustomerTransInquiry.php:87 +#: GLAccountInquiry.php:154 +#: GLAccountReport.php:369 +#: GLTransInquiry.php:45 +#: MRPCalendar.php:217 +#: PaymentAllocations.php:77 +#: PcAssignCashToTab.php:212 +#: PcAuthorizeExpenses.php:81 +#: PDFRemittanceAdvice.php:308 +#: PrintCustTrans.php:678 +#: PrintCustTransPortrait.php:860 +#: ReverseGRN.php:378 +#: ShipmentCosting.php:503 +#: ShipmentCosting.php:574 +#: Shipments.php:467 +#: StockDispatch.php:188 +#: StockDispatch.php:200 +#: StockLocMovements.php:85 +#: StockMovements.php:98 +#: StockSerialItemResearch.php:79 +#: SupplierAllocations.php:464 +#: SupplierAllocations.php:576 +#: SupplierAllocations.php:646 +#: SupplierInquiry.php:195 +#: SupplierTransInquiry.php:89 +#: includes/PDFQuotationPageHeader.inc:91 +#: includes/PDFStatementPageHeader.inc:169 +#: includes/PDFTaxPageHeader.inc:36 +#: includes/PDFTransPageHeader.inc:80 #: includes/PDFTransPageHeaderPortrait.inc:58 msgid "Date" msgstr "日期" -#: AddCustomerNotes.php:107 AddCustomerTypeNotes.php:105 PcReportTab.php:176 -#: Stocks.php:875 UpgradeDatabase.php:147 UpgradeDatabase.php:150 -#: UpgradeDatabase.php:153 UpgradeDatabase.php:156 UpgradeDatabase.php:159 -#: UpgradeDatabase.php:162 UpgradeDatabase.php:165 UpgradeDatabase.php:168 -#: Z_Upgrade_3.10-3.11.php:62 Z_Upgrade_3.10-3.11.php:66 -#: Z_Upgrade_3.10-3.11.php:70 Z_Upgrade_3.10-3.11.php:74 -#: Z_Upgrade_3.10-3.11.php:78 Z_Upgrade_3.11-4.00.php:62 -#: Z_Upgrade_3.11-4.00.php:66 Z_Upgrade_3.11-4.00.php:70 -#: Z_Upgrade_3.11-4.00.php:74 Z_Upgrade_3.11-4.00.php:78 +#: AddCustomerNotes.php:107 +#: AddCustomerTypeNotes.php:105 +#: PcReportTab.php:176 +#: Stocks.php:871 +#: UpgradeDatabase.php:145 +#: UpgradeDatabase.php:148 +#: UpgradeDatabase.php:151 +#: UpgradeDatabase.php:154 +#: UpgradeDatabase.php:157 +#: UpgradeDatabase.php:160 +#: UpgradeDatabase.php:163 +#: Z_Upgrade_3.10-3.11.php:62 +#: Z_Upgrade_3.10-3.11.php:66 +#: Z_Upgrade_3.10-3.11.php:70 +#: Z_Upgrade_3.10-3.11.php:74 +#: Z_Upgrade_3.10-3.11.php:78 +#: Z_Upgrade_3.11-4.00.php:62 +#: Z_Upgrade_3.11-4.00.php:66 +#: Z_Upgrade_3.11-4.00.php:70 +#: Z_Upgrade_3.11-4.00.php:74 +#: Z_Upgrade_3.11-4.00.php:78 msgid "Note" -msgstr "备注" +msgstr "備註" -#: AddCustomerNotes.php:108 AddCustomerNotes.php:183 +#: AddCustomerNotes.php:108 +#: AddCustomerNotes.php:183 msgid "WWW" -msgstr "WWW万维网" +msgstr "WWW萬維網" -#: AddCustomerNotes.php:109 AddCustomerNotes.php:195 -#: AddCustomerTypeNotes.php:107 AddCustomerTypeNotes.php:189 +#: AddCustomerNotes.php:109 +#: AddCustomerNotes.php:195 +#: AddCustomerTypeNotes.php:107 +#: AddCustomerTypeNotes.php:189 msgid "Priority" -msgstr "优先级" +msgstr "優先順序" #: AddCustomerNotes.php:143 msgid "Review all notes for this Customer" -msgstr "查看此顾客的所有通知" +msgstr "查看此顧客的所有通知" -#: AddCustomerNotes.php:172 AddCustomerTypeNotes.php:171 +#: AddCustomerNotes.php:172 +#: AddCustomerTypeNotes.php:171 msgid "Note ID" msgstr "Note ID" #: AddCustomerNotes.php:177 msgid "Contact Note" -msgstr "联络人备注" +msgstr "聯絡人備註" -#: AddCustomerTypeNotes.php:6 SelectCustomer.php:678 +#: AddCustomerTypeNotes.php:6 +#: SelectCustomer.php:676 msgid "Customer Type (Group) Notes" -msgstr "顾客种类(组)备注" +msgstr "顧客種類(組)備註" #: AddCustomerTypeNotes.php:31 msgid "The Contact priority must be an integer." -msgstr "联络人优先级必须是整数" +msgstr "聯絡人優先順序必須是整數" -#: AddCustomerTypeNotes.php:49 SelectCustomer.php:708 +#: AddCustomerTypeNotes.php:49 +#: SelectCustomer.php:706 msgid "Customer Group Notes" -msgstr "顾客组通知" +msgstr "顧客組通知" #: AddCustomerTypeNotes.php:60 msgid "The contact group notes record has been added" -msgstr "联系人组通知记录已增加" +msgstr "聯繫人組通知記錄已增加" #: AddCustomerTypeNotes.php:84 msgid "The contact group note record has been deleted" -msgstr "联系人组通知记录已经删除" +msgstr "聯繫人組通知記錄已經刪除" #: AddCustomerTypeNotes.php:95 msgid "Notes for Customer Type" -msgstr "顾客类型的通知:" +msgstr "顧客類型的通知:" #: AddCustomerTypeNotes.php:106 msgid "href" @@ -701,294 +1175,477 @@ #: AddCustomerTypeNotes.php:141 msgid "Review all notes for this Customer Type" -msgstr "查看此顾客类型的所有通知。" +msgstr "查看此顧客類型的所有通知。" #: AddCustomerTypeNotes.php:182 msgid "Contact Group Note" -msgstr "联系人组通知" +msgstr "聯繫人組通知" #: AddCustomerTypeNotes.php:184 msgid "Web site" -msgstr "网站" +msgstr "網站" #: AgedDebtors.php:17 msgid "Aged Customer Balance Listing" -msgstr "应收账款帐龄分析表" +msgstr "應收賬款帳齡分析表" #: AgedDebtors.php:18 msgid "Aged Customer Balances" -msgstr "欠款余额" +msgstr "欠款餘額" -#: AgedDebtors.php:267 AgedDebtors.php:365 AgedDebtors.php:436 +#: AgedDebtors.php:267 +#: AgedDebtors.php:365 +#: AgedDebtors.php:436 msgid "Aged Customer Account Analysis" -msgstr "客户欠款分析" +msgstr "客戶欠款分析" -#: AgedDebtors.php:267 AgedDebtors.php:365 AgedDebtors.php:436 -#: AgedSuppliers.php:105 BOMExtendedQty.php:156 BOMIndented.php:149 -#: BOMIndentedReverse.php:148 BOMListing.php:48 BOMListing.php:59 -#: DebtorsAtPeriodEnd.php:58 DebtorsAtPeriodEnd.php:70 GLBalanceSheet.php:90 -#: GLBalanceSheet.php:128 GLProfit_Loss.php:157 GLTagProfit_Loss.php:174 -#: GLTrialBalance.php:151 InventoryPlanning.php:99 InventoryPlanning.php:174 -#: InventoryPlanning.php:209 InventoryPlanning.php:257 -#: InventoryPlanning.php:295 InventoryPlanningPrefSupplier.php:208 -#: InventoryPlanningPrefSupplier.php:276 InventoryPlanningPrefSupplier.php:310 -#: InventoryPlanningPrefSupplier.php:355 InventoryPlanningPrefSupplier.php:401 -#: InventoryQuantities.php:83 InventoryValuation.php:76 -#: MailInventoryValuation.php:115 MRPPlannedPurchaseOrders.php:111 -#: MRPPlannedWorkOrders.php:105 MRPReport.php:147 MRPReport.php:529 -#: MRPReschedules.php:46 MRPReschedules.php:58 MRPShortages.php:137 -#: MRPShortages.php:149 OutstandingGRNs.php:51 OutstandingGRNs.php:63 -#: PDFCustomerList.php:20 PDFCustomerList.php:232 PDFCustomerList.php:244 -#: PDFLowGP.php:23 PDFStockCheckComparison.php:35 -#: PDFStockCheckComparison.php:61 PDFStockCheckComparison.php:262 -#: ReorderLevel.php:59 SelectAsset.php:36 SelectProduct.php:37 -#: StockCheck.php:65 StockCheck.php:139 SupplierTenders.php:325 -#: SuppPriceList.php:118 includes/PDFPaymentRun_PymtFooter.php:149 +#: AgedDebtors.php:267 +#: AgedDebtors.php:365 +#: AgedDebtors.php:436 +#: AgedSuppliers.php:105 +#: BOMExtendedQty.php:156 +#: BOMIndented.php:149 +#: BOMIndentedReverse.php:148 +#: BOMListing.php:48 +#: BOMListing.php:59 +#: DebtorsAtPeriodEnd.php:58 +#: DebtorsAtPeriodEnd.php:70 +#: GLBalanceSheet.php:90 +#: GLBalanceSheet.php:128 +#: GLProfit_Loss.php:157 +#: GLTagProfit_Loss.php:174 +#: GLTri... [truncated message content] |
From: <dai...@us...> - 2011-02-27 04:53:41
|
Revision: 4499 http://web-erp.svn.sourceforge.net/web-erp/?rev=4499&view=rev Author: daintree Date: 2011-02-27 04:53:34 +0000 (Sun, 27 Feb 2011) Log Message: ----------- Delete Units of measure fix as reported by Exson Modified Paths: -------------- trunk/UnitsOfMeasure.php trunk/doc/Change.log.html trunk/doc/Manual/ManualContributors.html Modified: trunk/UnitsOfMeasure.php =================================================================== --- trunk/UnitsOfMeasure.php 2011-02-25 21:15:29 UTC (rev 4498) +++ trunk/UnitsOfMeasure.php 2011-02-27 04:53:34 UTC (rev 4499) @@ -1,8 +1,6 @@ <?php /* $Id$*/ -//$PageSecurity = 15; - include('includes/session.inc'); $title = _('Units Of Measure'); @@ -141,19 +139,10 @@ prnMsg( _('Cannot delete this unit of measure because inventory items have been created using this unit of measure'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('inventory items that refer to this unit of measure') . '</font>'; } else { - $sql= "SELECT COUNT(*) FROM contracts WHERE units ".LIKE." '" . $OldMeasureName . "'"; + $sql="DELETE FROM unitsofmeasure WHERE unitname ".LIKE."'" . $OldMeasureName . "'"; $result = DB_query($sql,$db); - $myrow = DB_fetch_row($result); - if ($myrow[0]>0) { - prnMsg( _('Cannot delete this unit of measure because contracts have been created using this unit of measure'),'warn'); - echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('contracts that refer to this unit of measure') . '</font>'; - } else { - $sql="DELETE FROM unitsofmeasure WHERE unitname ".LIKE."'" . $OldMeasureName . "'"; - $result = DB_query($sql,$db); - prnMsg( $OldMeasureName . ' ' . _('unit of measure has been deleted') . '!','success'); - } + prnMsg( $OldMeasureName . ' ' . _('unit of measure has been deleted') . '!','success'); } - } //end if account group used in GL accounts unset ($SelectedMeasureID); unset ($_GET['SelectedMeasureID']); Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-25 21:15:29 UTC (rev 4498) +++ trunk/doc/Change.log.html 2011-02-27 04:53:34 UTC (rev 4499) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>27/2/11: Phil fix units deletion issue reported by Exson in UnitsOfMeasure.php script - checked for none existant units field in contracts table - removed the check</p> <p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> <p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> <p>18/2/11: Phil/Don Change PageSecurity array variable name to PageSecurityArray - caused problems with conflict with PageSecurity variable where register_globals = on; </p> Modified: trunk/doc/Manual/ManualContributors.html =================================================================== --- trunk/doc/Manual/ManualContributors.html 2011-02-25 21:15:29 UTC (rev 4498) +++ trunk/doc/Manual/ManualContributors.html 2011-02-27 04:53:34 UTC (rev 4499) @@ -1,185 +1,187 @@ -<br><br> +<br /><br /> <a name="Contributors"><font size="+3"><b>Contributors - Acknowledgements</b></font></a> -<br><br> +<br /><br /> The following is a list of known contributors. Many of these people can usually be contacted by posting to the appropriate mailing list. -<br><br> +<br /><br /> <table width="100%"> <tr> <td width="50%" valign="top"> <b>Development (sorted by last name)</b> -<br><br> +<br /><br /> Nicola Asuni (TCPDF) -<br><br> +<br /><br /> Shane Barnaby -<br><br> +<br /><br /> Chris Bice -<br><br> +<br /><br /> Danie Brink -<br><br> +<br /><br /> Phil Daintree -<br><br> +<br /><br /> Murray Dancey -<br><br> +<br /><br /> Gilles Deacur -<br><br> +<br /><br /> Miguel de Benito Delgado (phplot) -<br><br> +<br /><br /> Javier de Lorenzo-Cáceres -<br><br> +<br /><br /> Janusz Dobrowolski -<br><br> +<br /><br /> Edd Dumbill (phpxmlrpc) -<br><br> +<br /><br /> Tom Fox -<br><br> +<br /><br /> Braian Gomez -<br><br> +<br /><br /> Lindsay Harris -<br><br> +<br /><br /> David Hawke -<br><br> +<br /><br /> Richard Heyes (html.mime.mail) -<br><br> +<br /><br /> Hindra Joshua -<br><br> +<br /><br /> Alan Jones -<br><br> +<br /><br /> Steve Kaill - bugfixes -<br><br> +<br /><br /> Nico Kaiser (php-gettext) -<br><br> +<br /><br /> Mo Kelly - due dates and customer po by sales order line -<br><br> +<br /><br /> Meraj Khattak - database diagram -<br><br> +<br /><br /> Steve Kitchen -<br><br> +<br /><br /> Ditesh Kumar -<br><br> +<br /><br /> David Luo -<br><br> +<br /><br /> Wayne McDougall -<br><br> +<br /><br /> Greg Morehead -<br><br> +<br /><br /> Clay Mokus -<br><br> +<br /><br /> Suren Naidu -<br><br> +<br /><br /> Hani Naguib -<br><br> +<br /><br /> Harold Naparst -<br><br> +<br /><br /> Sherif Omar -<br><br> +<br /><br /> Simon Peter Otandeka -<br><br> +<br /><br /> Afan Ottenheimer (phplot) -<br><br> +<br /><br /> Ricardo Pedroso -<br><br> +<br /><br /> Jesse Peterson -<br><br> +<br /><br /> Kalmer Piiskop -<br><br> +<br /><br /> Olivier Plathey (FPDF - from which TCPDF was derived) -<br><br> +<br /><br /> Renier du Plessis -<BR><BR> +<br /><br /> Dave Premo (report writer) -<BR><BR> +<br /><br /> +Exson Qu +<br /><br /> Pak Ricard -<BR><BR> +<br /><br /> Harald Ringehahn -<BR><BR> +<br /><br /> Gunnar Rikardsson -<BR><BR> +<br /><br /> Scott Rosa -<br><br> +<br /><br /> Tim Schofield -<br><br> +<br /><br /> Jurgen Schopenhouer -<br><br> +<br /><br /> Danilo Segan (php-gettext) -<BR><BR> +<br /><br /> Gjergj Sheldija -<br><br> +<br /><br /> Matthew Sibson -<BR><BR> +<br /><br /> Vitaliy Shevkunov -<br><br> +<br /><br /> Jake Stride -<br><br> +<br /><br /> Matt Taylor -<BR><BR> +<br /><br /> Paul Thursby -<br><br> +<br /><br /> Marcos Garcia Trejo -<br><br> +<br /><br /> Mark Yeager (MRP) -<br><br> +<br /><br /> Zhiguo Yuan </td> <td valign="top"> <b>Translation </b> -<br><br> +<br /><br /> Csillag Péter Hungarian -<br><br> +<br /><br /> Danu Satrio Pratomo Djojosoemarto and his cousin - Indonesian -<br><br> +<br /><br /> Janusz Dobrowolski - Polish -<br><br> +<br /><br /> Matt Elbrecht - Estonian -<br><br> +<br /><br /> Igor Felix - Portuguese Brazilian -<br><br> +<br /><br /> Karel van der Esch - Dutch -<br><br> +<br /><br /> Thiago Figueiredo - Portuguese -<br><br> +<br /><br /> Romel Den - Chinese Traditional - UTF-8 -<br><br> +<br /><br /> Thiago Mansinho de Lima - Portuguese Brazilian -<br><br> +<br /><br /> Roberto del Pino - Spanish -<br><br> +<br /><br /> Alejandro E Fernández E Spanish (Venezuelan) -<br><br> +<br /><br /> Javier de Lorenzo-Cáceres - Spanish -<br><br> +<br /><br /> Juan L Grassi - Spanish -<br><br> +<br /><br /> Tanya Komarova - Russian -<br><br> +<br /><br /> Eddie Molina - Spanish -<br><br> -Exson Qu - Chinese -<br><br> +<br /><br /> +Exson Qu - Chinese (and Manual) +<br /><br /> J. Hernán Ramírez R. - Spanish (Venezuelan) -<br><br> +<br /><br /> Harald Ringehahn - German -<br><br> +<br /><br /> Manel Sanchez Maulini - Spanish -<br><br> +<br /><br /> Melvin Sequera - Spanish -<br><br> +<br /><br /> Efren Yevale - Spanish -<br><br> +<br /><br /> Carlos F. Castillo - Spanish -<br><br> +<br /><br /> Wilson Almeida - Spanish -<br><br> +<br /><br /> Carlos Vera - Spanish -<BR><BR> +<br /><br /> Zhiguo Yuan - Chinese -<BR><BR> +<br /><br /> </td> </tr> </table> -<br> +<br /> Some Icons sourced via Creative Commons Attribution 2.5 License. http://www.famfamfam.com/lab/icons/silk/ -<br> -<br> +<br /> +<br /> If anyone has been overlooked or should have their entry modified please email in...@we... -<br><br> +<br /><br /> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-27 04:53:41
|
Revision: 4499 http://web-erp.svn.sourceforge.net/web-erp/?rev=4499&view=rev Author: daintree Date: 2011-02-27 04:53:34 +0000 (Sun, 27 Feb 2011) Log Message: ----------- Delete Units of measure fix as reported by Exson Modified Paths: -------------- trunk/UnitsOfMeasure.php trunk/doc/Change.log.html trunk/doc/Manual/ManualContributors.html Modified: trunk/UnitsOfMeasure.php =================================================================== --- trunk/UnitsOfMeasure.php 2011-02-25 21:15:29 UTC (rev 4498) +++ trunk/UnitsOfMeasure.php 2011-02-27 04:53:34 UTC (rev 4499) @@ -1,8 +1,6 @@ <?php /* $Id$*/ -//$PageSecurity = 15; - include('includes/session.inc'); $title = _('Units Of Measure'); @@ -141,19 +139,10 @@ prnMsg( _('Cannot delete this unit of measure because inventory items have been created using this unit of measure'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('inventory items that refer to this unit of measure') . '</font>'; } else { - $sql= "SELECT COUNT(*) FROM contracts WHERE units ".LIKE." '" . $OldMeasureName . "'"; + $sql="DELETE FROM unitsofmeasure WHERE unitname ".LIKE."'" . $OldMeasureName . "'"; $result = DB_query($sql,$db); - $myrow = DB_fetch_row($result); - if ($myrow[0]>0) { - prnMsg( _('Cannot delete this unit of measure because contracts have been created using this unit of measure'),'warn'); - echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('contracts that refer to this unit of measure') . '</font>'; - } else { - $sql="DELETE FROM unitsofmeasure WHERE unitname ".LIKE."'" . $OldMeasureName . "'"; - $result = DB_query($sql,$db); - prnMsg( $OldMeasureName . ' ' . _('unit of measure has been deleted') . '!','success'); - } + prnMsg( $OldMeasureName . ' ' . _('unit of measure has been deleted') . '!','success'); } - } //end if account group used in GL accounts unset ($SelectedMeasureID); unset ($_GET['SelectedMeasureID']); Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-25 21:15:29 UTC (rev 4498) +++ trunk/doc/Change.log.html 2011-02-27 04:53:34 UTC (rev 4499) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>27/2/11: Phil fix units deletion issue reported by Exson in UnitsOfMeasure.php script - checked for none existant units field in contracts table - removed the check</p> <p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> <p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> <p>18/2/11: Phil/Don Change PageSecurity array variable name to PageSecurityArray - caused problems with conflict with PageSecurity variable where register_globals = on; </p> Modified: trunk/doc/Manual/ManualContributors.html =================================================================== --- trunk/doc/Manual/ManualContributors.html 2011-02-25 21:15:29 UTC (rev 4498) +++ trunk/doc/Manual/ManualContributors.html 2011-02-27 04:53:34 UTC (rev 4499) @@ -1,185 +1,187 @@ -<br><br> +<br /><br /> <a name="Contributors"><font size="+3"><b>Contributors - Acknowledgements</b></font></a> -<br><br> +<br /><br /> The following is a list of known contributors. Many of these people can usually be contacted by posting to the appropriate mailing list. -<br><br> +<br /><br /> <table width="100%"> <tr> <td width="50%" valign="top"> <b>Development (sorted by last name)</b> -<br><br> +<br /><br /> Nicola Asuni (TCPDF) -<br><br> +<br /><br /> Shane Barnaby -<br><br> +<br /><br /> Chris Bice -<br><br> +<br /><br /> Danie Brink -<br><br> +<br /><br /> Phil Daintree -<br><br> +<br /><br /> Murray Dancey -<br><br> +<br /><br /> Gilles Deacur -<br><br> +<br /><br /> Miguel de Benito Delgado (phplot) -<br><br> +<br /><br /> Javier de Lorenzo-Cáceres -<br><br> +<br /><br /> Janusz Dobrowolski -<br><br> +<br /><br /> Edd Dumbill (phpxmlrpc) -<br><br> +<br /><br /> Tom Fox -<br><br> +<br /><br /> Braian Gomez -<br><br> +<br /><br /> Lindsay Harris -<br><br> +<br /><br /> David Hawke -<br><br> +<br /><br /> Richard Heyes (html.mime.mail) -<br><br> +<br /><br /> Hindra Joshua -<br><br> +<br /><br /> Alan Jones -<br><br> +<br /><br /> Steve Kaill - bugfixes -<br><br> +<br /><br /> Nico Kaiser (php-gettext) -<br><br> +<br /><br /> Mo Kelly - due dates and customer po by sales order line -<br><br> +<br /><br /> Meraj Khattak - database diagram -<br><br> +<br /><br /> Steve Kitchen -<br><br> +<br /><br /> Ditesh Kumar -<br><br> +<br /><br /> David Luo -<br><br> +<br /><br /> Wayne McDougall -<br><br> +<br /><br /> Greg Morehead -<br><br> +<br /><br /> Clay Mokus -<br><br> +<br /><br /> Suren Naidu -<br><br> +<br /><br /> Hani Naguib -<br><br> +<br /><br /> Harold Naparst -<br><br> +<br /><br /> Sherif Omar -<br><br> +<br /><br /> Simon Peter Otandeka -<br><br> +<br /><br /> Afan Ottenheimer (phplot) -<br><br> +<br /><br /> Ricardo Pedroso -<br><br> +<br /><br /> Jesse Peterson -<br><br> +<br /><br /> Kalmer Piiskop -<br><br> +<br /><br /> Olivier Plathey (FPDF - from which TCPDF was derived) -<br><br> +<br /><br /> Renier du Plessis -<BR><BR> +<br /><br /> Dave Premo (report writer) -<BR><BR> +<br /><br /> +Exson Qu +<br /><br /> Pak Ricard -<BR><BR> +<br /><br /> Harald Ringehahn -<BR><BR> +<br /><br /> Gunnar Rikardsson -<BR><BR> +<br /><br /> Scott Rosa -<br><br> +<br /><br /> Tim Schofield -<br><br> +<br /><br /> Jurgen Schopenhouer -<br><br> +<br /><br /> Danilo Segan (php-gettext) -<BR><BR> +<br /><br /> Gjergj Sheldija -<br><br> +<br /><br /> Matthew Sibson -<BR><BR> +<br /><br /> Vitaliy Shevkunov -<br><br> +<br /><br /> Jake Stride -<br><br> +<br /><br /> Matt Taylor -<BR><BR> +<br /><br /> Paul Thursby -<br><br> +<br /><br /> Marcos Garcia Trejo -<br><br> +<br /><br /> Mark Yeager (MRP) -<br><br> +<br /><br /> Zhiguo Yuan </td> <td valign="top"> <b>Translation </b> -<br><br> +<br /><br /> Csillag Péter Hungarian -<br><br> +<br /><br /> Danu Satrio Pratomo Djojosoemarto and his cousin - Indonesian -<br><br> +<br /><br /> Janusz Dobrowolski - Polish -<br><br> +<br /><br /> Matt Elbrecht - Estonian -<br><br> +<br /><br /> Igor Felix - Portuguese Brazilian -<br><br> +<br /><br /> Karel van der Esch - Dutch -<br><br> +<br /><br /> Thiago Figueiredo - Portuguese -<br><br> +<br /><br /> Romel Den - Chinese Traditional - UTF-8 -<br><br> +<br /><br /> Thiago Mansinho de Lima - Portuguese Brazilian -<br><br> +<br /><br /> Roberto del Pino - Spanish -<br><br> +<br /><br /> Alejandro E Fernández E Spanish (Venezuelan) -<br><br> +<br /><br /> Javier de Lorenzo-Cáceres - Spanish -<br><br> +<br /><br /> Juan L Grassi - Spanish -<br><br> +<br /><br /> Tanya Komarova - Russian -<br><br> +<br /><br /> Eddie Molina - Spanish -<br><br> -Exson Qu - Chinese -<br><br> +<br /><br /> +Exson Qu - Chinese (and Manual) +<br /><br /> J. Hernán Ramírez R. - Spanish (Venezuelan) -<br><br> +<br /><br /> Harald Ringehahn - German -<br><br> +<br /><br /> Manel Sanchez Maulini - Spanish -<br><br> +<br /><br /> Melvin Sequera - Spanish -<br><br> +<br /><br /> Efren Yevale - Spanish -<br><br> +<br /><br /> Carlos F. Castillo - Spanish -<br><br> +<br /><br /> Wilson Almeida - Spanish -<br><br> +<br /><br /> Carlos Vera - Spanish -<BR><BR> +<br /><br /> Zhiguo Yuan - Chinese -<BR><BR> +<br /><br /> </td> </tr> </table> -<br> +<br /> Some Icons sourced via Creative Commons Attribution 2.5 License. http://www.famfamfam.com/lab/icons/silk/ -<br> -<br> +<br /> +<br /> If anyone has been overlooked or should have their entry modified please email in...@we... -<br><br> +<br /><br /> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-27 09:18:49
|
Revision: 4500 http://web-erp.svn.sourceforge.net/web-erp/?rev=4500&view=rev Author: daintree Date: 2011-02-27 09:18:42 +0000 (Sun, 27 Feb 2011) Log Message: ----------- various Modified Paths: -------------- trunk/GoodsReceived.php trunk/MRPShortages.php trunk/PDFQuotation.php trunk/StockUsage.php trunk/WorkOrderEntry.php trunk/doc/Change.log.html Modified: trunk/GoodsReceived.php =================================================================== --- trunk/GoodsReceived.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/GoodsReceived.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -4,8 +4,6 @@ /* $Revision: 1.44 $ */ -//$PageSecurity = 11; now stored in the database - /* Session started in header.inc for password checking and authorisation level check */ include('includes/DefinePOClass.php'); include('includes/DefineSerialItems.php'); @@ -72,6 +70,7 @@ if (!isset($_POST['ProcessGoodsReceived'])) { if (!isset($_POST['DefaultReceivedDate'])){ + /* This is meant to be the date the goods are received - it does not make sense to set this to the date that we requested delivery in the purchase order - I have not applied your change here Tim for this reason - let me know if I have it wrong - Phil */ $_POST['DefaultReceivedDate'] = Date($_SESSION['DefaultDateFormat']); } Modified: trunk/MRPShortages.php =================================================================== --- trunk/MRPShortages.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/MRPShortages.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -1,20 +1,20 @@ <?php /*$Id$ */ - -/* $Revision: 1.7 $ */ // MRPShortages.php - Report of parts with demand greater than supply as determined by MRP -//$PageSecurity = 2; + include('includes/session.inc'); +//ANSI SQL??? $sql='show tables where Tables_in_'.$_SESSION['DatabaseName'].'="mrprequirements"'; + $result=DB_query($sql,$db); if (DB_num_rows($result)==0) { - $title='MRP error'; + $title=_('MRP error'); include('includes/header.inc'); echo '<br>'; - prnMsg( _('The MRP calculation must be run before you can run this report').'<br>'. - _('To run the MRP calculation click').' '.'<a href='.$rootpath .'/MRP.php?' . SID .'>'._('here').'</a>', 'error'); + prnMsg( _('The MRP calculation must be run before you can run this report').'<br />'. + _('To run the MRP calculation click').' '.'<a href="'.$rootpath .'/MRP.php">'._('here').'</a>', 'error'); include('includes/footer.inc'); exit; } @@ -103,7 +103,14 @@ extcost HAVING demand > supply ORDER BY '" . $_POST['Sort']."'"; - $sql = "SELECT stockmaster.stockid, + + if ($_POST['CategoryID'] == 'All'){ + $SQLCategory = ' '; + }else{ + $SQLCategory = "WHERE stockmaster.categoryid = '" . $_POST['CategoryID'] . "'"; + } + + $sql = "SELECT stockmaster.stockid, stockmaster.description, stockmaster.mbflag, stockmaster.actualcost, @@ -117,8 +124,9 @@ stockmaster.overheadcost ) as extcost FROM stockmaster LEFT JOIN demandtotal ON stockmaster.stockid = demandtotal.part - LEFT JOIN supplytotal ON stockmaster.stockid = supplytotal.part - GROUP BY stockmaster.stockid, + LEFT JOIN supplytotal ON stockmaster.stockid = supplytotal.part " + . $SQLCategory . + "GROUP BY stockmaster.stockid, stockmaster.description, stockmaster.mbflag, stockmaster.actualcost, @@ -137,9 +145,9 @@ $title = _('MRP Shortages') . ' - ' . _('Problem Report'); include('includes/header.inc'); prnMsg( _('The MRP shortages could not be retrieved by the SQL because') . ' ' . DB_error_msg($db),'error'); - echo "</br><a href='" .$rootpath .'/index.php?' . SID . "'>" . _('Back to the menu') . '</a>'; + echo '<br/><a href="' .$rootpath .'/index.php">' . _('Back to the menu') . '</a>'; if ($debug==1){ - echo "</br>$sql"; + echo '<br/>' . $sql; } include('includes/footer.inc'); exit; @@ -149,9 +157,9 @@ $title = _('MRP Shortages') . ' - ' . _('Problem Report'); include('includes/header.inc'); prnMsg( _('No MRP shortages retrieved'), 'warn'); - echo "</br><a href='" .$rootpath .'/index.php?' . SID . "'>" . _('Back to the menu') . '</a>'; + echo '<br /><a href="' .$rootpath .'/index.php">' . _('Back to the menu') . '</a>'; if ($debug==1){ - echo "</br>$sql"; + echo "<br />$sql"; } include('includes/footer.inc'); exit; @@ -216,28 +224,7 @@ $pdf->addTextWrap(300,$YPos,180,$FontSize,_('Total Extended Shortage:'), 'right'); $DisplayTotalVal = number_format($Total_Shortage,2); $pdf->addTextWrap(510,$YPos,60,$FontSize,$DisplayTotalVal, 'right'); -/* UldisN - $pdfcode = $pdf->output(); - $len = strlen($pdfcode); - if ($len<=20){ - $title = _('Print MRP Shortages Error'); - include('includes/header.inc'); - prnMsg(_('There were no items with demand greater than supply'),'error'); - echo "</br><a href='$rootpath/index.php?" . SID . "'>" . _('Back to the menu') . '</a>'; - include('includes/footer.inc'); - exit; - } else { - header('Content-type: application/pdf'); - header("Content-Length: " . $len); - header('Content-Disposition: inline; filename=MRPShortages.pdf'); - header('Expires: 0'); - header('Cache-Control: private, post-check=0, pre-check=0'); - header('Pragma: public'); - - $pdf->Output('MRPShortages.pdf', 'I'); - } -*/ $pdf->OutputD($_SESSION['DatabaseName'] . '_MRPShortages_' . date('Y-m-d').'.pdf');//UldisN $pdf->__destruct(); //UldisN } else { /*The option to print PDF was not hit so display form */ @@ -250,14 +237,24 @@ echo '<form action=' . $_SERVER['PHP_SELF'] . " method='post'>"; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - echo "<table class=selection>"; + echo '<table class=selection>'; + echo '</select></td></tr>'; + echo '<tr><td>' . _('Inventory Category') . ':</td><td><select name="CategoryID">'; + echo '<option selected value="All">' . _('All Stock Categories'); + $sql = 'SELECT categoryid, + categorydescription + FROM stockcategory'; + $result = DB_query($sql,$db); + while ($myrow = DB_fetch_array($result)) { + echo '<option value="' . $myrow['categoryid'] . '">' . $myrow['categoryid'] . ' - ' .$myrow['categorydescription'] . '</option>'; + } //end while loop echo '<tr><td>' . _('Sort') . ":</td><td><select name='Sort'>"; - echo "<option selected value='extcost'>" . _('Extended Shortage Dollars')."</option>"; - echo "<option value='stockid'>" . _('Part Number')."</option>"; + echo "<option selected value='extcost'>" . _('Extended Shortage Dollars').'</option>'; + echo "<option value='stockid'>" . _('Part Number').'</option>'; echo '</select></td></tr>'; echo '<tr><td>' . _('Print Option') . ":</td><td><select name='Fill'>"; - echo "<option selected value='yes'>" . _('Print With Alternating Highlighted Lines')."</option>"; - echo "<option value='no'>" . _('Plain Print')."</option>"; + echo "<option selected value='yes'>" . _('Print With Alternating Highlighted Lines').'</option>'; + echo "<option value='no'>" . _('Plain Print').'</option>'; echo '</select></td></tr>'; echo "</table><br><div class='centre'><input type=submit name='PrintPDF' value='" . _('Print PDF') . "'></div>"; Modified: trunk/PDFQuotation.php =================================================================== --- trunk/PDFQuotation.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/PDFQuotation.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -1,10 +1,7 @@ <?php /* $Id$*/ -/* $Revision: 1.11 $ */ -//$PageSecurity = 2; - include('includes/session.inc'); include('includes/SQL_CommonFunctions.inc'); Modified: trunk/StockUsage.php =================================================================== --- trunk/StockUsage.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/StockUsage.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -2,7 +2,6 @@ /* $Id$*/ -//$PageSecurity = 2; include('includes/session.inc'); @@ -93,32 +92,38 @@ /*HideMovt ==1 if the movement was only created for the purpose of a transaction but is not a physical movement eg. A price credit will create a movement record for the purposes of display on a credit note but there is no physical stock movement - it makes sense honest ??? */ + +$CurrentPeriod = GetPeriod(Date($_SESSION['DefaultDateFormat']),$db); + if (isset($_POST['ShowUsage'])){ if($_POST['StockLocation']=='All'){ $sql = "SELECT periods.periodno, periods.lastdate_in_period, - SUM(-stockmoves.qty) AS qtyused - FROM stockmoves INNER JOIN periods - ON stockmoves.prd=periods.periodno - WHERE (stockmoves.type=10 OR stockmoves.type=11 OR stockmoves.type=28) - AND stockmoves.hidemovt=0 - AND stockmoves.stockid = '" . $StockID . "' + SUM(CASE WHEN (stockmoves.type=10 Or stockmoves.type=11 OR stockmoves.type=28) + AND stockmoves.hidemovt=0 + AND stockmoves.stockid = '" . $StockID . "' + THEN -stockmoves.qty ELSE 0 END) AS qtyused + FROM periods LEFT JOIN stockmoves + ON periods.periodno=stockmoves.prd + WHERE periods.periodno <='" . $CurrentPeriod . "' GROUP BY periods.periodno, periods.lastdate_in_period ORDER BY periodno DESC LIMIT " . $_SESSION['NumberOfPeriodsOfStockUsage']; } else { $sql = "SELECT periods.periodno, periods.lastdate_in_period, - SUM(-stockmoves.qty) AS qtyused - FROM stockmoves INNER JOIN periods - ON stockmoves.prd=periods.periodno - WHERE (stockmoves.type=10 Or stockmoves.type=11 OR stockmoves.type=28) - AND stockmoves.hidemovt=0 - AND stockmoves.loccode='" . $_POST['StockLocation'] . "' - AND stockmoves.stockid = '" . $StockID . "' + SUM(CASE WHEN (stockmoves.type=10 Or stockmoves.type=11 OR stockmoves.type=28) + AND stockmoves.hidemovt=0 + AND stockmoves.stockid = '" . $StockID . "' + AND stockmoves.loccode='" . $_POST['StockLocation'] . "' + THEN -stockmoves.qty ELSE 0 END) AS qtyused + FROM periods LEFT JOIN stockmoves + ON periods.periodno=stockmoves.prd + WHERE periods.periodno <='" . $CurrentPeriod . "' GROUP BY periods.periodno, periods.lastdate_in_period ORDER BY periodno DESC LIMIT " . $_SESSION['NumberOfPeriodsOfStockUsage']; + } $MovtsResult = DB_query($sql, $db); if (DB_error_no($db) !=0) { Modified: trunk/WorkOrderEntry.php =================================================================== --- trunk/WorkOrderEntry.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/WorkOrderEntry.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -2,8 +2,6 @@ /* $Id$*/ -//$PageSecurity = 10; - include('includes/session.inc'); $title = _('Work Order Entry'); include('includes/header.inc'); @@ -252,9 +250,9 @@ if (isset($_POST['submit'])) { //The update button has been clicked - echo '<div class=centre><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '">' . _('Enter a new work order') . '</a>'; - echo '<br><a href="' . $rootpath . '/SelectWorkOrder.php?' . SID . '">' . _('Select an existing work order') . '</a>'; - echo '<br><a href="'. $rootpath . '/WorkOrderCosting.php?' . SID . '&WO=' . $_REQUEST['WO'] . '">' . _('Go to Costing'). '</a></div>'; + echo '<div class=centre><a href="' . $_SERVER['PHP_SELF'] .'">' . _('Enter a new work order') . '</a>'; + echo '<br><a href="' . $rootpath . '/SelectWorkOrder.php">' . _('Select an existing work order') . '</a>'; + echo '<br><a href="'. $rootpath . '/WorkOrderCosting.php&WO=' . $_REQUEST['WO'] . '">' . _('Go to Costing'). '</a></div>'; $Input_Error = false; //hope for the best for ($i=1;$i<=$_POST['NumberOfOutputs'];$i++){ @@ -659,9 +657,6 @@ echo "<script>defaultControl(document.forms[0].OutputQty".$_GET['Line'].");</script>"; } - echo '</form>'; - include('includes/footer.inc'); - ?> \ No newline at end of file Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/doc/Change.log.html 2011-02-27 09:18:42 UTC (rev 4500) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php </p> <p>27/2/11: Phil fix units deletion issue reported by Exson in UnitsOfMeasure.php script - checked for none existant units field in contracts table - removed the check</p> <p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> <p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-02-27 09:18:49
|
Revision: 4500 http://web-erp.svn.sourceforge.net/web-erp/?rev=4500&view=rev Author: daintree Date: 2011-02-27 09:18:42 +0000 (Sun, 27 Feb 2011) Log Message: ----------- various Modified Paths: -------------- trunk/GoodsReceived.php trunk/MRPShortages.php trunk/PDFQuotation.php trunk/StockUsage.php trunk/WorkOrderEntry.php trunk/doc/Change.log.html Modified: trunk/GoodsReceived.php =================================================================== --- trunk/GoodsReceived.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/GoodsReceived.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -4,8 +4,6 @@ /* $Revision: 1.44 $ */ -//$PageSecurity = 11; now stored in the database - /* Session started in header.inc for password checking and authorisation level check */ include('includes/DefinePOClass.php'); include('includes/DefineSerialItems.php'); @@ -72,6 +70,7 @@ if (!isset($_POST['ProcessGoodsReceived'])) { if (!isset($_POST['DefaultReceivedDate'])){ + /* This is meant to be the date the goods are received - it does not make sense to set this to the date that we requested delivery in the purchase order - I have not applied your change here Tim for this reason - let me know if I have it wrong - Phil */ $_POST['DefaultReceivedDate'] = Date($_SESSION['DefaultDateFormat']); } Modified: trunk/MRPShortages.php =================================================================== --- trunk/MRPShortages.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/MRPShortages.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -1,20 +1,20 @@ <?php /*$Id$ */ - -/* $Revision: 1.7 $ */ // MRPShortages.php - Report of parts with demand greater than supply as determined by MRP -//$PageSecurity = 2; + include('includes/session.inc'); +//ANSI SQL??? $sql='show tables where Tables_in_'.$_SESSION['DatabaseName'].'="mrprequirements"'; + $result=DB_query($sql,$db); if (DB_num_rows($result)==0) { - $title='MRP error'; + $title=_('MRP error'); include('includes/header.inc'); echo '<br>'; - prnMsg( _('The MRP calculation must be run before you can run this report').'<br>'. - _('To run the MRP calculation click').' '.'<a href='.$rootpath .'/MRP.php?' . SID .'>'._('here').'</a>', 'error'); + prnMsg( _('The MRP calculation must be run before you can run this report').'<br />'. + _('To run the MRP calculation click').' '.'<a href="'.$rootpath .'/MRP.php">'._('here').'</a>', 'error'); include('includes/footer.inc'); exit; } @@ -103,7 +103,14 @@ extcost HAVING demand > supply ORDER BY '" . $_POST['Sort']."'"; - $sql = "SELECT stockmaster.stockid, + + if ($_POST['CategoryID'] == 'All'){ + $SQLCategory = ' '; + }else{ + $SQLCategory = "WHERE stockmaster.categoryid = '" . $_POST['CategoryID'] . "'"; + } + + $sql = "SELECT stockmaster.stockid, stockmaster.description, stockmaster.mbflag, stockmaster.actualcost, @@ -117,8 +124,9 @@ stockmaster.overheadcost ) as extcost FROM stockmaster LEFT JOIN demandtotal ON stockmaster.stockid = demandtotal.part - LEFT JOIN supplytotal ON stockmaster.stockid = supplytotal.part - GROUP BY stockmaster.stockid, + LEFT JOIN supplytotal ON stockmaster.stockid = supplytotal.part " + . $SQLCategory . + "GROUP BY stockmaster.stockid, stockmaster.description, stockmaster.mbflag, stockmaster.actualcost, @@ -137,9 +145,9 @@ $title = _('MRP Shortages') . ' - ' . _('Problem Report'); include('includes/header.inc'); prnMsg( _('The MRP shortages could not be retrieved by the SQL because') . ' ' . DB_error_msg($db),'error'); - echo "</br><a href='" .$rootpath .'/index.php?' . SID . "'>" . _('Back to the menu') . '</a>'; + echo '<br/><a href="' .$rootpath .'/index.php">' . _('Back to the menu') . '</a>'; if ($debug==1){ - echo "</br>$sql"; + echo '<br/>' . $sql; } include('includes/footer.inc'); exit; @@ -149,9 +157,9 @@ $title = _('MRP Shortages') . ' - ' . _('Problem Report'); include('includes/header.inc'); prnMsg( _('No MRP shortages retrieved'), 'warn'); - echo "</br><a href='" .$rootpath .'/index.php?' . SID . "'>" . _('Back to the menu') . '</a>'; + echo '<br /><a href="' .$rootpath .'/index.php">' . _('Back to the menu') . '</a>'; if ($debug==1){ - echo "</br>$sql"; + echo "<br />$sql"; } include('includes/footer.inc'); exit; @@ -216,28 +224,7 @@ $pdf->addTextWrap(300,$YPos,180,$FontSize,_('Total Extended Shortage:'), 'right'); $DisplayTotalVal = number_format($Total_Shortage,2); $pdf->addTextWrap(510,$YPos,60,$FontSize,$DisplayTotalVal, 'right'); -/* UldisN - $pdfcode = $pdf->output(); - $len = strlen($pdfcode); - if ($len<=20){ - $title = _('Print MRP Shortages Error'); - include('includes/header.inc'); - prnMsg(_('There were no items with demand greater than supply'),'error'); - echo "</br><a href='$rootpath/index.php?" . SID . "'>" . _('Back to the menu') . '</a>'; - include('includes/footer.inc'); - exit; - } else { - header('Content-type: application/pdf'); - header("Content-Length: " . $len); - header('Content-Disposition: inline; filename=MRPShortages.pdf'); - header('Expires: 0'); - header('Cache-Control: private, post-check=0, pre-check=0'); - header('Pragma: public'); - - $pdf->Output('MRPShortages.pdf', 'I'); - } -*/ $pdf->OutputD($_SESSION['DatabaseName'] . '_MRPShortages_' . date('Y-m-d').'.pdf');//UldisN $pdf->__destruct(); //UldisN } else { /*The option to print PDF was not hit so display form */ @@ -250,14 +237,24 @@ echo '<form action=' . $_SERVER['PHP_SELF'] . " method='post'>"; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - echo "<table class=selection>"; + echo '<table class=selection>'; + echo '</select></td></tr>'; + echo '<tr><td>' . _('Inventory Category') . ':</td><td><select name="CategoryID">'; + echo '<option selected value="All">' . _('All Stock Categories'); + $sql = 'SELECT categoryid, + categorydescription + FROM stockcategory'; + $result = DB_query($sql,$db); + while ($myrow = DB_fetch_array($result)) { + echo '<option value="' . $myrow['categoryid'] . '">' . $myrow['categoryid'] . ' - ' .$myrow['categorydescription'] . '</option>'; + } //end while loop echo '<tr><td>' . _('Sort') . ":</td><td><select name='Sort'>"; - echo "<option selected value='extcost'>" . _('Extended Shortage Dollars')."</option>"; - echo "<option value='stockid'>" . _('Part Number')."</option>"; + echo "<option selected value='extcost'>" . _('Extended Shortage Dollars').'</option>'; + echo "<option value='stockid'>" . _('Part Number').'</option>'; echo '</select></td></tr>'; echo '<tr><td>' . _('Print Option') . ":</td><td><select name='Fill'>"; - echo "<option selected value='yes'>" . _('Print With Alternating Highlighted Lines')."</option>"; - echo "<option value='no'>" . _('Plain Print')."</option>"; + echo "<option selected value='yes'>" . _('Print With Alternating Highlighted Lines').'</option>'; + echo "<option value='no'>" . _('Plain Print').'</option>'; echo '</select></td></tr>'; echo "</table><br><div class='centre'><input type=submit name='PrintPDF' value='" . _('Print PDF') . "'></div>"; Modified: trunk/PDFQuotation.php =================================================================== --- trunk/PDFQuotation.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/PDFQuotation.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -1,10 +1,7 @@ <?php /* $Id$*/ -/* $Revision: 1.11 $ */ -//$PageSecurity = 2; - include('includes/session.inc'); include('includes/SQL_CommonFunctions.inc'); Modified: trunk/StockUsage.php =================================================================== --- trunk/StockUsage.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/StockUsage.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -2,7 +2,6 @@ /* $Id$*/ -//$PageSecurity = 2; include('includes/session.inc'); @@ -93,32 +92,38 @@ /*HideMovt ==1 if the movement was only created for the purpose of a transaction but is not a physical movement eg. A price credit will create a movement record for the purposes of display on a credit note but there is no physical stock movement - it makes sense honest ??? */ + +$CurrentPeriod = GetPeriod(Date($_SESSION['DefaultDateFormat']),$db); + if (isset($_POST['ShowUsage'])){ if($_POST['StockLocation']=='All'){ $sql = "SELECT periods.periodno, periods.lastdate_in_period, - SUM(-stockmoves.qty) AS qtyused - FROM stockmoves INNER JOIN periods - ON stockmoves.prd=periods.periodno - WHERE (stockmoves.type=10 OR stockmoves.type=11 OR stockmoves.type=28) - AND stockmoves.hidemovt=0 - AND stockmoves.stockid = '" . $StockID . "' + SUM(CASE WHEN (stockmoves.type=10 Or stockmoves.type=11 OR stockmoves.type=28) + AND stockmoves.hidemovt=0 + AND stockmoves.stockid = '" . $StockID . "' + THEN -stockmoves.qty ELSE 0 END) AS qtyused + FROM periods LEFT JOIN stockmoves + ON periods.periodno=stockmoves.prd + WHERE periods.periodno <='" . $CurrentPeriod . "' GROUP BY periods.periodno, periods.lastdate_in_period ORDER BY periodno DESC LIMIT " . $_SESSION['NumberOfPeriodsOfStockUsage']; } else { $sql = "SELECT periods.periodno, periods.lastdate_in_period, - SUM(-stockmoves.qty) AS qtyused - FROM stockmoves INNER JOIN periods - ON stockmoves.prd=periods.periodno - WHERE (stockmoves.type=10 Or stockmoves.type=11 OR stockmoves.type=28) - AND stockmoves.hidemovt=0 - AND stockmoves.loccode='" . $_POST['StockLocation'] . "' - AND stockmoves.stockid = '" . $StockID . "' + SUM(CASE WHEN (stockmoves.type=10 Or stockmoves.type=11 OR stockmoves.type=28) + AND stockmoves.hidemovt=0 + AND stockmoves.stockid = '" . $StockID . "' + AND stockmoves.loccode='" . $_POST['StockLocation'] . "' + THEN -stockmoves.qty ELSE 0 END) AS qtyused + FROM periods LEFT JOIN stockmoves + ON periods.periodno=stockmoves.prd + WHERE periods.periodno <='" . $CurrentPeriod . "' GROUP BY periods.periodno, periods.lastdate_in_period ORDER BY periodno DESC LIMIT " . $_SESSION['NumberOfPeriodsOfStockUsage']; + } $MovtsResult = DB_query($sql, $db); if (DB_error_no($db) !=0) { Modified: trunk/WorkOrderEntry.php =================================================================== --- trunk/WorkOrderEntry.php 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/WorkOrderEntry.php 2011-02-27 09:18:42 UTC (rev 4500) @@ -2,8 +2,6 @@ /* $Id$*/ -//$PageSecurity = 10; - include('includes/session.inc'); $title = _('Work Order Entry'); include('includes/header.inc'); @@ -252,9 +250,9 @@ if (isset($_POST['submit'])) { //The update button has been clicked - echo '<div class=centre><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '">' . _('Enter a new work order') . '</a>'; - echo '<br><a href="' . $rootpath . '/SelectWorkOrder.php?' . SID . '">' . _('Select an existing work order') . '</a>'; - echo '<br><a href="'. $rootpath . '/WorkOrderCosting.php?' . SID . '&WO=' . $_REQUEST['WO'] . '">' . _('Go to Costing'). '</a></div>'; + echo '<div class=centre><a href="' . $_SERVER['PHP_SELF'] .'">' . _('Enter a new work order') . '</a>'; + echo '<br><a href="' . $rootpath . '/SelectWorkOrder.php">' . _('Select an existing work order') . '</a>'; + echo '<br><a href="'. $rootpath . '/WorkOrderCosting.php&WO=' . $_REQUEST['WO'] . '">' . _('Go to Costing'). '</a></div>'; $Input_Error = false; //hope for the best for ($i=1;$i<=$_POST['NumberOfOutputs'];$i++){ @@ -659,9 +657,6 @@ echo "<script>defaultControl(document.forms[0].OutputQty".$_GET['Line'].");</script>"; } - echo '</form>'; - include('includes/footer.inc'); - ?> \ No newline at end of file Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-27 04:53:34 UTC (rev 4499) +++ trunk/doc/Change.log.html 2011-02-27 09:18:42 UTC (rev 4500) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php </p> <p>27/2/11: Phil fix units deletion issue reported by Exson in UnitsOfMeasure.php script - checked for none existant units field in contracts table - removed the check</p> <p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> <p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-03 09:13:19
|
Revision: 4501 http://web-erp.svn.sourceforge.net/web-erp/?rev=4501&view=rev Author: daintree Date: 2011-03-03 09:13:12 +0000 (Thu, 03 Mar 2011) Log Message: ----------- Tim launchpad revisions to 4441 excluding price units stuff Modified Paths: -------------- trunk/ConfirmDispatchControlled_Invoice.php trunk/ConfirmDispatch_Invoice.php trunk/DeliveryDetails.php trunk/GoodsReceived.php trunk/GoodsReceivedControlled.php trunk/SelectCompletedOrder.php trunk/SelectCustomer.php trunk/SelectSupplier.php trunk/StockCheck.php trunk/StockSerialItems.php trunk/SupplierCredit.php trunk/Suppliers.php trunk/doc/Change.log.html trunk/includes/Add_SerialItems.php trunk/includes/Add_SerialItemsOut.php trunk/includes/DefineSerialItems.php trunk/includes/InputSerialItems.php trunk/includes/InputSerialItemsKeyed.php trunk/includes/PDFStockCheckPageHeader.inc Modified: trunk/ConfirmDispatchControlled_Invoice.php =================================================================== --- trunk/ConfirmDispatchControlled_Invoice.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/ConfirmDispatchControlled_Invoice.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -66,7 +66,7 @@ $InOutModifier=1; $ShowExisting=false; -include ('includes/InputSerialItems.php'); +include ('includes/OutputSerialItems.php'); /*TotalQuantity set inside this include file from the sum of the bundles of the item selected for dispatch */ Modified: trunk/ConfirmDispatch_Invoice.php =================================================================== --- trunk/ConfirmDispatch_Invoice.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/ConfirmDispatch_Invoice.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -219,18 +219,24 @@ } foreach ($_SESSION['Items']->LineItems as $Itm) { - if (is_numeric($_POST[$Itm->LineNumber . '_QtyDispatched' ])AND $_POST[$Itm->LineNumber . '_QtyDispatched'] <= ($_SESSION['Items']->LineItems[$Itm->LineNumber]->Quantity - $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyInv)){ + if (sizeOf($Itm->SerialItems) > 0) { + $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyDispatched = 0; //initialise QtyDispatched + foreach ($Itm->SerialItems as $SerialItem) { //calculate QtyDispatched from bundle quantities + $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyDispatched += $SerialItem->BundleQty; + } + } else if (is_numeric($_POST[$Itm->LineNumber . '_QtyDispatched' ])AND $_POST[$Itm->LineNumber . '_QtyDispatched'] <= ($_SESSION['Items']->LineItems[$Itm->LineNumber]->Quantity - $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyInv)){ $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyDispatched = $_POST[$Itm->LineNumber . '_QtyDispatched']; } + + foreach ($Itm->Taxes as $TaxLine) { if (isset($_POST[$Itm->LineNumber . $TaxLine->TaxCalculationOrder . '_TaxRate'])){ $_SESSION['Items']->LineItems[$Itm->LineNumber]->Taxes[$TaxLine->TaxCalculationOrder]->TaxRate = $_POST[$Itm->LineNumber . $TaxLine->TaxCalculationOrder . '_TaxRate']/100; } } + } //end foreach lineitem - } - } /* Always display dispatch quantities and recalc freight for items being dispatched */ @@ -382,15 +388,15 @@ echo '<td class="number">'.$DisplayTaxAmount.'</td><td class="number">'.$DisplayGrossLineTotal.'</td>'; if ($LnItm->Controlled==1){ - - echo '<td><a href="' . $rootpath . '/ConfirmDispatchControlled_Invoice.php?' . SID . '&LineNo='. $LnItm->LineNumber.'">'; - - if ($LnItm->Serialised==1){ - echo _("Enter Serial Numbers"); - } else { /*Just batch/roll/lot control */ - echo _('Enter Batch/Roll/Lot #'); + if (!isset($_POST['ProcessInvoice'])) { + echo '<td><a href="' . $rootpath . '/ConfirmDispatchControlled_Invoice.php?' . SID . '&LineNo='. $LnItm->LineNumber.'">'; + if ($LnItm->Serialised==1){ + echo _('Enter Serial Numbers'); + } else { /*Just batch/roll/lot control */ + echo _('Enter Batch/Roll/Lot #'); + } + echo '</a></td>'; } - echo '</a></td>'; } echo '</tr>'; if (strlen($LnItm->Narrative)>1){ @@ -717,7 +723,7 @@ /*Start an SQL transaction */ -DB_Txn_Begin($db); + DB_Txn_Begin($db); if ($DefaultShipVia != $_SESSION['Items']->ShipVia){ $SQL = "UPDATE custbranch Modified: trunk/DeliveryDetails.php =================================================================== --- trunk/DeliveryDetails.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/DeliveryDetails.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -580,8 +580,8 @@ } else { /*link to print the quotation */ - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation') .'</a></td></tr></table>'; - + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?' . SID .'identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation (Landscape)') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotationPortrait.php?' . SID .'identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation (Portrait)') .'</a></td></tr></table>'; } echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="'. $rootpath .'/SelectOrderItems.php?identifier='.$identifier . '&NewOrder=Yes">'. _('Add Another Sales Order') .'</a></td></tr></table>'; } else { Modified: trunk/GoodsReceived.php =================================================================== --- trunk/GoodsReceived.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/GoodsReceived.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -516,11 +516,13 @@ loccode, serialno, qualitytext, + expirationdate, quantity) VALUES ('" . $OrderLine->StockID . "', '" . $_SESSION['PO'.$identifier]->Location . "', '" . $Item->BundleRef . "', '', + '" . FormatDateForSQL($Item->ExpiryDate) . "', '" . $Item->BundleQty . "')"; } Modified: trunk/GoodsReceivedControlled.php =================================================================== --- trunk/GoodsReceivedControlled.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/GoodsReceivedControlled.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -4,8 +4,6 @@ include('includes/DefinePOClass.php'); include('includes/DefineSerialItems.php'); -//$PageSecurity = 11; - include('includes/session.inc'); $title = _('Receive Controlled Items'); @@ -32,7 +30,7 @@ exit; } -if (isset($_GET['LineNo'])){ +if (isset($_GET['LineNo']) AND $_GET['LineNo']>0){ $LineNo = $_GET['LineNo']; } elseif (isset($_POST['LineNo'])){ $LineNo = $_POST['LineNo']; Modified: trunk/SelectCompletedOrder.php =================================================================== --- trunk/SelectCompletedOrder.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SelectCompletedOrder.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -64,8 +64,16 @@ if (isset($OrderNumber)) { echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Sales Order') . '" alt="" />' . ' ' . _('Order Number') . ' - ' . $OrderNumber . '</p>'; + if (strlen($_SESSION['UserBranch'])>1){ + echo _('For customer') . ': ' . $SelectedCustomer; + echo "<input type=hidden name='SelectedCustomer' value='".$SelectedCustomer."'>"; + } } elseif (isset($CustomerRef)) { echo _('Customer Ref') . ' - ' . $CustomerRef; + if (strlen($_SESSION['UserBranch'])>1){ + echo ' ' . _('and for customer') . ': ' . $SelectedCustomer .' ' . _('and') . ' '; + echo "<input type=hidden name='SelectedCustomer' value='".$SelectedCustomer."'>"; + } } else { if (isset($SelectedCustomer)) { echo _('For customer') . ': ' . $SelectedCustomer .' ' . _('and') . ' '; @@ -212,13 +220,42 @@ $SelectedStockItem = $myrow[0]; $_POST['SearchOrders']='True'; unset($StockItemsResult); - echo '<br>' . _('For the part') . ': ' . $SelectedStockItem . ' ' . _('and') . " <input type=hidden name='SelectedStockItem' value='$SelectedStockItem'>"; + echo '<br />' . _('For the part') . ': ' . $SelectedStockItem . ' ' . _('and') . " <input type=hidden name='SelectedStockItem' value='$SelectedStockItem'>"; } } } else if (isset($_POST['SearchOrders']) AND Is_Date($_POST['OrdersAfterDate'])==1) { //figure out the SQL required from the inputs available if (isset($OrderNumber)) { + if (isset($SelectedCustomer)) { + $SQL = "SELECT salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto, SUM(salesorderdetails.unitprice*salesorderdetails.quantity*(1-salesorderdetails.discountpercent)) AS ordervalue + FROM salesorders, + salesorderdetails, + debtorsmaster, + custbranch + WHERE salesorders.orderno = salesorderdetails.orderno + AND salesorders.branchcode = custbranch.branchcode + AND salesorders.debtorno = debtorsmaster.debtorno + AND debtorsmaster.debtorno = custbranch.debtorno + AND salesorders.debtorno='" . $SelectedCustomer ."' + AND salesorders.orderno='". $OrderNumber ."' + AND salesorders.quotation=0 + AND salesorderdetails.completed".$completed." + GROUP BY salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto + ORDER BY salesorders.orderno"; + } else { //Set order number and SelectedCustomer not set $SQL = "SELECT salesorders.orderno, debtorsmaster.name, custbranch.brname, @@ -245,7 +282,9 @@ salesorders.deliverydate, salesorders.deliverto ORDER BY salesorders.orderno"; + } } elseif (isset($CustomerRef)) { + if (isset($SelectedCustomer)) { $SQL = "SELECT salesorders.orderno, debtorsmaster.name, custbranch.brname, @@ -261,6 +300,7 @@ AND salesorders.branchcode = custbranch.branchcode AND salesorders.debtorno = debtorsmaster.debtorno AND debtorsmaster.debtorno = custbranch.debtorno + AND salesorders.debtorno='" . $SelectedCustomer ."' AND salesorders.customerref like '%". $CustomerRef."%' AND salesorders.quotation=0 AND salesorderdetails.completed".$completed." @@ -272,6 +312,34 @@ salesorders.deliverydate, salesorders.deliverto ORDER BY salesorders.orderno"; + } else { //customer not selected + $SQL = "SELECT salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto, SUM(salesorderdetails.unitprice*salesorderdetails.quantity*(1-salesorderdetails.discountpercent)) AS ordervalue + FROM salesorders, + salesorderdetails, + debtorsmaster, + custbranch + WHERE salesorders.orderno = salesorderdetails.orderno + AND salesorders.branchcode = custbranch.branchcode + AND salesorders.debtorno = debtorsmaster.debtorno + AND debtorsmaster.debtorno = custbranch.debtorno + AND salesorders.customerref like '%". $CustomerRef."%' + AND salesorders.quotation=0 + AND salesorderdetails.completed".$completed." + GROUP BY salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto + ORDER BY salesorders.orderno"; + } } else { $DateAfterCriteria = FormatDateforSQL($_POST['OrdersAfterDate']); @@ -399,8 +467,8 @@ $SalesOrdersResult = DB_query($SQL,$db); if (DB_error_no($db) !=0) { - echo '<br>' . _('No orders were returned by the SQL because') . ' ' . DB_error_msg($db); - echo "<br>$SQL"; + echo '<br />' . _('No orders were returned by the SQL because') . ' ' . DB_error_msg($db); + echo "<br />$SQL"; } }//end of which button clicked options @@ -416,22 +484,22 @@ echo "<tr><td></td>"; } -if (!isset($OrderNumber) or $OrderNumber==''){ - echo '<td>' . _('Order Number') . ':</td><td>' . "<input type='text' name='OrderNumber' maxlength =8 size=9></td><td>" . _('for all orders placed after') . - ": </td><td><input type='text' class='date' alt='".$_SESSION['DefaultDateFormat']."' name='OrdersAfterDate' maxlength =10 size=11 value=" . $_POST['OrdersAfterDate'] . "></td><td>" . - "<input type='submit' name='SearchOrders' value='" . _('Search Orders') . "'></td></tr>"; - echo '<tr><td></td><td>' . _('Customer Ref') . ':</td><td>' . "<input type='text' name='CustomerRef' maxlength =8 size=9></td> +echo '<td>' . _('Order Number') . ':</td> + <td>' . "<input type='text' name='OrderNumber' maxlength =8 size=9 value ='" . $_POST['OrderNumber'] . "'></td> + <td>" . _('for all orders placed after') . ": </td><td><input type='text' class='date' alt='".$_SESSION['DefaultDateFormat']."' name='OrdersAfterDate' maxlength =10 size=11 value=" . $_POST['OrdersAfterDate'] . "></td> + <td>" . "<input type='submit' name='SearchOrders' value='" . _('Search Orders') . "'></td></tr>"; +echo '<tr><td></td><td>' . _('Customer Ref') . ':</td><td>' . "<input type='text' name='CustomerRef' maxlength =8 size=9></td> <td></td><td colspan=2><input type='checkbox' ".$ShowChecked." name='completed' />"._('Show Completed orders only') . "</td></tr>"; -} + echo '</table>'; if (!isset($SelectedStockItem)) { $SQL='SELECT categoryid, categorydescription FROM stockcategory ORDER BY categorydescription'; $result1 = DB_query($SQL,$db); - echo '<br>'; + echo '<br />'; echo '<div class="page_help_text"><font size=1>' . _('To search for sales orders for a specific part use the part selection facilities below') . ' </font></div>'; - echo '<br><table class=selection>'; + echo '<br /><table class=selection>'; echo '<tr><td><font size=1>' . _('Select a stock category') . ':</font>'; echo '<select name="StockCat">'; @@ -461,7 +529,7 @@ If (isset($StockItemsResult)) { - echo '<br><table cellpadding=2 colspan=7 class=selection>'; + echo '<br /><table cellpadding=2 colspan=7 class=selection>'; $TableHeadings = "<tr><th>" . _('Code') . "</th>" . "<th>" . _('Description') . "</th>" . @@ -511,7 +579,7 @@ /*show a table of the orders returned by the SQL */ - echo '<br><table cellpadding=2 colspan=6 width=90% class=selection>'; + echo '<br /><table cellpadding=2 colspan=6 width=90% class=selection>'; $tableheader = "<tr><th>" . _('Order') . " #</th> <th>" . _('Customer') . "</th> Modified: trunk/SelectCustomer.php =================================================================== --- trunk/SelectCustomer.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SelectCustomer.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -1,6 +1,6 @@ <?php /* $Id$*/ -//$PageSecurity = 2; + include ('includes/session.inc'); $title = _('Search Customers'); include ('includes/header.inc'); @@ -119,8 +119,9 @@ custbranch.phoneno, custbranch.faxno FROM debtorsmaster LEFT JOIN custbranch - ON debtorsmaster.debtorno = custbranch.debtorno, debtortype - WHERE debtorsmaster.typeid = debtortype.typeid"; + ON debtorsmaster.debtorno = custbranch.debtorno + INNER JOIN debtortype + ON debtorsmaster.typeid = debtortype.typeid"; } else { if (strlen($_POST['Keywords']) > 0) { //using the customer name Modified: trunk/SelectSupplier.php =================================================================== --- trunk/SelectSupplier.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SelectSupplier.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -166,7 +166,7 @@ echo '</td><td valign=top class="select">'; /* Supplier Transactions */ echo "<a href=\"$rootpath/PO_Header.php?" . SID . '&NewOrder=Yes&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Purchase Order for This Supplier') . '</a><br>'; echo "<a href=\"$rootpath/SupplierInvoice.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Suppliers Invoice') . '</a><br>'; - echo "<a href=\"$rootpath/SupplierCredit.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Suppliers Credit Note') . '</a><br>'; + echo "<a href=\"$rootpath/SupplierCredit.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . '&New=True' . "\">" . _('Enter a Suppliers Credit Note') . '</a><br>'; echo "<a href=\"$rootpath/Payments.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Payment to, or Receipt from the Supplier') . '</a><br>'; echo '<br>'; echo "<br><a href='$rootpath/ReverseGRN.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "'>" . _('Reverse an Outstanding Goods Received Note (GRN)') . '</a>'; Modified: trunk/StockCheck.php =================================================================== --- trunk/StockCheck.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/StockCheck.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -175,8 +175,9 @@ $FontSize=10; $YPos -=$line_height; - if ($_POST['ShowInfo']==true){ + if (isset($_POST['ShowInfo']) and $_POST['ShowInfo']==true){ + $SQL = "SELECT SUM(salesorderdetails.quantity - salesorderdetails.qtyinvoiced) AS qtydemand FROM salesorderdetails, salesorders Modified: trunk/StockSerialItems.php =================================================================== --- trunk/StockSerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/StockSerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -1,8 +1,8 @@ <?php /* $Id$*/ -//$PageSecurity = 2; + include('includes/session.inc'); $title = _('Stock Of Controlled Items'); include('includes/header.inc'); @@ -28,21 +28,23 @@ mbflag, decimalplaces, serialised, - controlled + controlled, + perishable FROM stockmaster WHERE stockid='".$StockID."'", $db, _('Could not retrieve the requested item because')); -$myrow = DB_fetch_row($result); +$myrow = DB_fetch_array($result); -$Description = $myrow[0]; -$UOM = $myrow[1]; -$DecimalPlaces = $myrow[3]; -$Serialised = $myrow[4]; -$Controlled = $myrow[5]; +$Description = $myrow['description']; +$UOM = $myrow['units']; +$DecimalPlaces = $myrow['decimalplaces']; +$Serialised = $myrow['serialised']; +$Controlled = $myrow['controlled']; +$Perishable = $myrow['perishable']; -if ($myrow[2]=='K' OR $myrow[2]=='A' OR $myrow[2]=='D'){ +if ($myrow['mbflag']=='K' OR $myrow['mbflag']=='A' OR $myrow['mbflag']=='D'){ prnMsg(_('This item is either a kitset or assembly or a dummy part and cannot have a stock holding') . '. ' . _('This page cannot be displayed') . '. ' . _('Only serialised or controlled items can be displayed in this page'),'error'); include('includes/footer.inc'); @@ -59,7 +61,8 @@ $myrow = DB_fetch_row($result); $sql = "SELECT serialno, - quantity + quantity, + expirationdate FROM stockserialitems WHERE loccode='" . $_GET['Location'] . "' AND stockid = '" . $StockID . "' @@ -72,30 +75,48 @@ echo '<table cellpadding=2 class=selection>'; if ($Serialised==1){ - echo '<tr<th colspan=3><font color=navy size=2>' . _('Serialised items in') . ' '; + echo '<tr><th colspan="5"><font color=navy size=2>' . _('Serialised items in') . ' '; } else { - echo '<tr<th colspan=3><font color=navy size=2>' . _('Controlled items in') . ' '; + echo '<tr><th colspan="11"><font color=navy size=2>' . _('Controlled items in') . ' '; } echo $myrow[0]. '</font></th></tr>'; -echo "<tr><th colspan=3><font color=navy size=2>".$StockID ."-". $Description ."</b> (" . _('In units of') . ' ' . $UOM . ')</font></th></tr>'; +echo "<tr><th colspan=11><font color=navy size=2>".$StockID ."-". $Description ."</b> (" . _('In units of') . ' ' . $UOM . ')</font></th></tr>'; if ($Serialised == 1){ - $tableheader = "<tr> - <th>" . _('Serial Number') . "</th> - <th>" . _('Serial Number') . "</th> - <th>" . _('Serial Number') . "</th> - </tr>"; -} else { - $tableheader = "<tr> - <th>" . _('Batch/Bundle Ref') . "</th> - <th>" . _('Quantity On Hand') . "</th> - <th>" . _('Batch/Bundle Ref') . "</th> - <th>" . _('Quantity On Hand') . "</th> - <th>" . _('Batch/Bundle Ref') . "</th> - <th>" . _('Quantity On Hand') . "</th> + $tableheader = '<tr> + <th>' . _('Serial Number') . '</th> + <th></th> + <th>' . _('Serial Number') . '</th> + <th></th> + <th>' . _('Serial Number') . '</th> + </tr>'; +} else if ($Serialised == 0 and $Perishable==0){ + $tableheader = '<tr> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> </tr>"; +} else if ($Serialised == 0 and $Perishable==1){ + $tableheader = '<tr> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th>' . _('Expiry Date') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th>' . _('Expiry Date') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th>' . _('Expiry Date') . '</th> + </tr>'; } echo $tableheader; $TotalQuantity =0; @@ -115,15 +136,17 @@ $TotalQuantity += $myrow['quantity']; if ($Serialised == 1){ - printf('<td>%s</td>', - $myrow['serialno'] - ); - } else { - printf("<td>%s</td> - <td class=number>%s</td>", - $myrow['serialno'], - number_format($myrow['quantity'],$DecimalPlaces) - ); + echo '<td>'.$myrow['serialno'].'/td>'; + echo '<th></th>'; + } else if ($Serialised == 0 and $Perishable==0) { + echo '<td>'.$myrow['serialno'].'</td> + <td class="number">'.number_format($myrow['quantity'],$DecimalPlaces).'</td>'; + echo '<th></th>'; + } else if ($Serialised == 0 and $Perishable==1){ + echo '<td>'.$myrow['serialno'].'</td> + <td class="number">'.number_format($myrow['quantity'],$DecimalPlaces). '</td> + <td>' . ConvertSQLDate($myrow['expirationdate']). '</td>'; + echo '<th></th>'; } $j++; If ($j == 36){ @@ -144,5 +167,4 @@ echo '</form>'; include('includes/footer.inc'); - ?> \ No newline at end of file Modified: trunk/SupplierCredit.php =================================================================== --- trunk/SupplierCredit.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SupplierCredit.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -35,6 +35,10 @@ //this is available from the menu on this page already //echo "<a href='" . $rootpath . '/SelectSupplier.php?' . SID . "'>" . _('Back to Suppliers') . '</a><br>'; +if (isset($_GET['New'])) { + unset($_SESSION['SuppTrans']); +} + if (!isset($_SESSION['SuppTrans']->SupplierName)) { $sql='SELECT suppname FROM suppliers WHERE supplierid="'.$_GET['SupplierID'].'"'; $result = DB_query($sql,$db); Modified: trunk/Suppliers.php =================================================================== --- trunk/Suppliers.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/Suppliers.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -444,11 +444,11 @@ } if (!isset($_POST['New'])) { - $supptranssql = "SELECT COUNT(supplierno) - FROM supptrans - WHERE supplierno='".$SupplierID ."'"; + $supptranssql = "SELECT supplierno + FROM supptrans + WHERE supplierno='".$SupplierID ."'"; $suppresult = DB_query($supptranssql, $db); - $supptrans = DB_fetch_row($suppresult); + $supptrans = DB_num_rows($suppresult); $suppcurrssql = "SELECT currcode FROM suppliers @@ -481,7 +481,7 @@ WHERE supplierid = '".$SupplierID."'"; } else { if ($suppcurr[0] != $_POST['CurrCode']) { - prnMsg( _('Cannot change currency code as transactions already exist'), info); + prnMsg( _('Cannot change currency code as transactions already exist'), 'info'); } $sql = "UPDATE suppliers SET suppname='" . $_POST['SuppName'] . "', address1='" . $_POST['Address1'] . "', Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/doc/Change.log.html 2011-03-03 09:13:12 UTC (rev 4501) @@ -1,6 +1,9 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> -<p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php </p> +<p>3/3/11: Exson/Baran/Phil fix to customer login to ensure that other customers orders are not displayed when searching by customer ref or order no</p> +<p>3/3/11: Tim launchpad mods to revision 4441 including change to allow supplier currency to be changed if there are no transactions already against the supplier. Ensure credit note session variable is unset before attempting to create a new credit note from the supplier form. Tim's work to add perisable expiry dates to the serial items logic - affects quite a few scripts. Headings to stock check script even if no quantity is shown. Portrait quotations. Not included change to default delivery date to the date the customer requested - left to be the current day's date. Not included Tim's unit pricing work .. yet launchpad revisions 4442-4447 inclusive</p> +<p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php links with matching quotes in WorkOrderEntry</p> +<p>27/2/11: Phil StockUsage.php now totals usage each month even in months where there was none - average now includes months with no usage</p> <p>27/2/11: Phil fix units deletion issue reported by Exson in UnitsOfMeasure.php script - checked for none existant units field in contracts table - removed the check</p> <p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> <p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> Modified: trunk/includes/Add_SerialItems.php =================================================================== --- trunk/includes/Add_SerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/Add_SerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -66,7 +66,7 @@ } if (!$SerialError){ - $LineItem->SerialItems[$NewSerialNo] = new SerialItem ($_POST['SerialNo' . $i], $NewQty); + $LineItem->SerialItems[$NewSerialNo] = new SerialItem ($_POST['SerialNo' . $i], $NewQty, $_POST['ExpiryDate' . $i]); } } } /* end if posted Serialno . i is not blank */ @@ -75,7 +75,8 @@ if (!isset($_POST['Bundles'])) { $_POST['Bundles']=0; } - for ($i=0;$i < count($_POST['Bundles']);$i++){ /*there is an entry in the multi select list box */ + echo count($_POST['Bundles']); + for ($i=0;$i < count($_POST['Bundles'])-1;$i++){ /*there is an entry in the multi select list box */ if ($LineItem->Serialised==1){ /*only if the item is serialised */ $LineItem->SerialItems[$_POST['Bundles'][$i]] = new SerialItem ($_POST['Bundles'][$i], ($InOutModifier>0?1:-1) ); } else { Modified: trunk/includes/Add_SerialItemsOut.php =================================================================== --- trunk/includes/Add_SerialItemsOut.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/Add_SerialItemsOut.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -3,11 +3,10 @@ /*ProcessSerialItems.php takes the posted variables and adds to the SerialItems array in either the cartclass->LineItems->SerialItems or the POClass->LineItems->SerialItems */ - if (isset($_POST['AddBatches'])){ for ($i=0;$i < 10;$i++){ - if(strlen($_POST['SerialNo' . $i])>0){ + if(isset($_POST['SerialNo' . $i]) and strlen($_POST['SerialNo' . $i])>0){ $ExistingBundleQty = ValidBundleRef($StockID, $LocationOut, $_POST['SerialNo' . $i]); if ($ExistingBundleQty >0){ $AddThisBundle = true; @@ -15,30 +14,31 @@ the first entered one - no warning given though ? */ if ($_POST['Qty' . $i] > $ExistingBundleQty){ if ($LineItem->Serialised ==1){ - echo "<BR>" . $_POST['SerialNo' . $i] . " " . _('has already been sold'); + echo "<br />" . $_POST['SerialNo' . $i] . " " . _('has already been sold'); $AddThisBundle = false; } elseif ($ExistingBundleQty==0) { /* and its a batch */ - echo "<BR>There is none of " . $_POST['SerialNo' . $i] . " left."; + echo "<br />There is none of " . $_POST['SerialNo' . $i] . " left."; $AddThisBundle = false; } else { - echo '<BR>' . _('There is only') . ' ' . $ExistingBundleQty . ' ' . _('of') . ' ' . $_POST['SerialNo' . $i] . ' ' . _('remaining') . '. ' . _('The entered quantity will be reduced to the remaining amount left of this batch/bundle/roll'); + echo '<br />' . _('There is only') . ' ' . $ExistingBundleQty . ' ' . _('of') . ' ' . $_POST['SerialNo' . $i] . + ' ' . _('remaining') . '. ' . _('The entered quantity will be reduced to the remaining amount left of this batch/bundle/roll'); $_POST['Qty' . $i] = $ExistingBundleQty; $AddThisBundle = true; } } - if ($AddThisBundle==true){ - $LineItem->SerialItems[$_POST['SerialNo' . $i]] = new SerialItem ($_POST['SerialNo' . $i], $_POST['Qty' . $i]); + if ($AddThisBundle==true and $_POST['Qty' . $i]>0){ + $LineItem->SerialItems[$_POST['SerialNo' . $i]] = new SerialItem ($_POST['SerialNo' . $i], $_POST['Qty' . $i], $_POST['ExpiryDate' . $i]); } } /*end if ExistingBundleQty >0 */ } /* end if posted Serialno . i is not blank */ } /* end of the loop aroung the form input fields */ - for ($i=0;$i < count($_POST['Bundles']);$i++){ /*there is an entry in the multi select list box */ - if ($LineItem->Serialised==1){ /*only if the item is serialised */ - $LineItem->SerialItems[$_POST['Bundles'][$i]] = new SerialItem ($_POST['Bundles'][$i], 1); - } - } +// for ($i=0;$i < count($_POST['Bundles']);$i++){ /*there is an entry in the multi select list box */ +// if ($LineItem->Serialised==1){ /*only if the item is serialised */ +// $LineItem->SerialItems[$_POST['Bundles'][$i]] = new SerialItem ($_POST['Bundles'][$i], 1); +// } +// } } /*end if the user hit the enter button */ @@ -47,4 +47,8 @@ unset($LineItem->SerialItems[$_GET['Delete']]); } +if (isset($_GET['DELETEALL'])){ + $LineItem->SerialItems=array(); +} + ?> Modified: trunk/includes/DefineSerialItems.php =================================================================== --- trunk/includes/DefineSerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/DefineSerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -4,10 +4,10 @@ function ValidBundleRef ($StockID, $LocCode, $BundleRef){ global $db; - $SQL = "SELECT quantity - FROM stockserialitems - WHERE stockid='" . $StockID . "' - AND loccode ='" . $LocCode . "' + $SQL = "SELECT quantity + FROM stockserialitems + WHERE stockid='" . $StockID . "' + AND loccode ='" . $LocCode . "' AND serialno='" . $BundleRef . "'"; $Result = DB_query($SQL, $db); if (DB_num_rows($Result)==0){ @@ -22,12 +22,14 @@ var $BundleRef; var $BundleQty; + var $ExpiryDate; //Constructor - function SerialItem($BundleRef, $BundleQty){ + function SerialItem($BundleRef, $BundleQty, $ExpiryDate='0000-00-00'){ $this->BundleRef = $BundleRef; $this->BundleQty = $BundleQty; + $this->ExpiryDate = $ExpiryDate; } }//class SerialItem ?> \ No newline at end of file Modified: trunk/includes/InputSerialItems.php =================================================================== --- trunk/includes/InputSerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/InputSerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -88,15 +88,27 @@ '&LineNo=' . $LineNo .'">'. _('Edit'). '</a> | '; $RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&DELETEALL=YES&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Remove All'). '</a><br></div>'; +$sql="SELECT perishable + FROM stockmaster + WHERE stockid='".$StockID."'"; +$result=DB_query($sql, $db); +$myrow=DB_fetch_array($result); +$Perishable=$myrow['perishable']; if ($LineItem->Serialised==1){ $tableheader .= '<tr> <th>'. _('Serial No').'</th> - </Tr>'; + </tr>'; +} else if ($LineItem->Serialised==0 and $Perishable==1){ + $tableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Quantity'). '</th> + <th>'. _('Expiry Date'). '</th> + </tr>'; } else { - $tableheader = '<TR> + $tableheader = '<tr> <th>'. _('Batch/Roll/Bundle'). ' #</th> - <th class=tableheader>'. _('Quantity'). '</th> - </tr>'; + <th>'. _('Quantity'). '</th> + </tr>'; } echo $EditLink . $RemoveLink; Modified: trunk/includes/InputSerialItemsKeyed.php =================================================================== --- trunk/includes/InputSerialItemsKeyed.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/InputSerialItemsKeyed.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -47,8 +47,11 @@ echo '<td>' . $Bundle->BundleRef . '</td>'; - if ($LineItem->Serialised==0){ + if ($LineItem->Serialised==0 and $Perishable==0){ echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + } else if ($LineItem->Serialised==0 and $Perishable==1){ + echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + echo '<td class=number>' . $Bundle->ExpiryDate . '</td>'; } echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&Delete=' . $Bundle->BundleRef . '&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Delete'). '</a></td></tr>'; @@ -81,7 +84,7 @@ <input type=hidden name=StockID value="' . $StockID . '"> <input type=hidden name="identifier" value="' . $identifier . '"> <input type=hidden name=EntryType value="KEYED">'; - echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; +echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; if ( isset($_GET['EditControlled']) ) { $EditControlled = isset($_GET['EditControlled'])?$_GET['EditControlled']:false; } elseif ( isset($_POST['EditControlled']) ){ @@ -102,6 +105,9 @@ if ($LineItem->Serialised==1){ echo '<input type=hidden name="Qty' . $StartAddingAt .'" Value=1></TR>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 + value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; } else { echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; @@ -120,6 +126,10 @@ if ($LineItem->Serialised==1){ echo '<input type=hidden name="Qty' . ($StartAddingAt+$i) .'" Value=1></tr>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$i) .'" size=11 maxlength=10></td>'; + echo '<td><input type=text class="date" name="ExpiryDate' . ($StartAddingAt+$i) .'" size=11 + value="" alt="'.$_SESSION['DefaultDateFormat'].'" maxlength=10></td></tr>'; } else { echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$i) .'" size=11 maxlength=10></tr>'; } @@ -136,4 +146,4 @@ document.Ga6uF5Wa.SerialNo0.focus(); //]]> </script>'; /*end of nested table */ -?> +?> \ No newline at end of file Modified: trunk/includes/PDFStockCheckPageHeader.inc =================================================================== --- trunk/includes/PDFStockCheckPageHeader.inc 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/PDFStockCheckPageHeader.inc 2011-03-03 09:13:12 UTC (rev 4501) @@ -28,16 +28,22 @@ $Xpos = $Left_Margin+1; /*draw vertical lines */ -$pdf->line(350, $YPos-$line_height,350, $Bottom_Margin+24); -$pdf->line(415, $YPos-$line_height,415, $Bottom_Margin+24); -$pdf->line(475, $YPos-$line_height,475, $Bottom_Margin+24); +$pdf->line(370, $YPos+$BoxHeight,370, $Bottom_Margin+24); $LeftOvers = $pdf->addTextWrap($Xpos,$YPos,300-$Left_Margin,$FontSize,_('Item'), 'centre'); -if ($_POST['ShowInfo']==true){ +if (isset($_POST['ShowInfo']) and $_POST['ShowInfo']==true){ + /*draw vertical lines */ + $pdf->line(415, $YPos-$line_height,415, $Bottom_Margin+24); + $pdf->line(475, $YPos-$line_height,475, $Bottom_Margin+24); $LeftOvers = $pdf->addTextWrap(341,$YPos,60,$FontSize,_('QOH'), 'centre'); $LeftOvers = $pdf->addTextWrap(341+61,$YPos,80,$FontSize,_('Cust Ords'), 'centre'); $LeftOvers = $pdf->addTextWrap(341+61+61,$YPos,80,$FontSize,_('Available'), 'centre'); - } +} else { + /*draw vertical lines */ + $pdf->line(435, $YPos+$BoxHeight,435, $Bottom_Margin+24); + $LeftOvers = $pdf->addTextWrap(371,$YPos,60,$FontSize,_('Quantity'), 'centre'); + $LeftOvers = $pdf->addTextWrap(341+61+61,$YPos,80,$FontSize,_('Remarks'), 'centre'); +} $FontSize=10; $YPos -=($line_height); ?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-03 09:13:19
|
Revision: 4501 http://web-erp.svn.sourceforge.net/web-erp/?rev=4501&view=rev Author: daintree Date: 2011-03-03 09:13:12 +0000 (Thu, 03 Mar 2011) Log Message: ----------- Tim launchpad revisions to 4441 excluding price units stuff Modified Paths: -------------- trunk/ConfirmDispatchControlled_Invoice.php trunk/ConfirmDispatch_Invoice.php trunk/DeliveryDetails.php trunk/GoodsReceived.php trunk/GoodsReceivedControlled.php trunk/SelectCompletedOrder.php trunk/SelectCustomer.php trunk/SelectSupplier.php trunk/StockCheck.php trunk/StockSerialItems.php trunk/SupplierCredit.php trunk/Suppliers.php trunk/doc/Change.log.html trunk/includes/Add_SerialItems.php trunk/includes/Add_SerialItemsOut.php trunk/includes/DefineSerialItems.php trunk/includes/InputSerialItems.php trunk/includes/InputSerialItemsKeyed.php trunk/includes/PDFStockCheckPageHeader.inc Modified: trunk/ConfirmDispatchControlled_Invoice.php =================================================================== --- trunk/ConfirmDispatchControlled_Invoice.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/ConfirmDispatchControlled_Invoice.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -66,7 +66,7 @@ $InOutModifier=1; $ShowExisting=false; -include ('includes/InputSerialItems.php'); +include ('includes/OutputSerialItems.php'); /*TotalQuantity set inside this include file from the sum of the bundles of the item selected for dispatch */ Modified: trunk/ConfirmDispatch_Invoice.php =================================================================== --- trunk/ConfirmDispatch_Invoice.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/ConfirmDispatch_Invoice.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -219,18 +219,24 @@ } foreach ($_SESSION['Items']->LineItems as $Itm) { - if (is_numeric($_POST[$Itm->LineNumber . '_QtyDispatched' ])AND $_POST[$Itm->LineNumber . '_QtyDispatched'] <= ($_SESSION['Items']->LineItems[$Itm->LineNumber]->Quantity - $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyInv)){ + if (sizeOf($Itm->SerialItems) > 0) { + $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyDispatched = 0; //initialise QtyDispatched + foreach ($Itm->SerialItems as $SerialItem) { //calculate QtyDispatched from bundle quantities + $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyDispatched += $SerialItem->BundleQty; + } + } else if (is_numeric($_POST[$Itm->LineNumber . '_QtyDispatched' ])AND $_POST[$Itm->LineNumber . '_QtyDispatched'] <= ($_SESSION['Items']->LineItems[$Itm->LineNumber]->Quantity - $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyInv)){ $_SESSION['Items']->LineItems[$Itm->LineNumber]->QtyDispatched = $_POST[$Itm->LineNumber . '_QtyDispatched']; } + + foreach ($Itm->Taxes as $TaxLine) { if (isset($_POST[$Itm->LineNumber . $TaxLine->TaxCalculationOrder . '_TaxRate'])){ $_SESSION['Items']->LineItems[$Itm->LineNumber]->Taxes[$TaxLine->TaxCalculationOrder]->TaxRate = $_POST[$Itm->LineNumber . $TaxLine->TaxCalculationOrder . '_TaxRate']/100; } } + } //end foreach lineitem - } - } /* Always display dispatch quantities and recalc freight for items being dispatched */ @@ -382,15 +388,15 @@ echo '<td class="number">'.$DisplayTaxAmount.'</td><td class="number">'.$DisplayGrossLineTotal.'</td>'; if ($LnItm->Controlled==1){ - - echo '<td><a href="' . $rootpath . '/ConfirmDispatchControlled_Invoice.php?' . SID . '&LineNo='. $LnItm->LineNumber.'">'; - - if ($LnItm->Serialised==1){ - echo _("Enter Serial Numbers"); - } else { /*Just batch/roll/lot control */ - echo _('Enter Batch/Roll/Lot #'); + if (!isset($_POST['ProcessInvoice'])) { + echo '<td><a href="' . $rootpath . '/ConfirmDispatchControlled_Invoice.php?' . SID . '&LineNo='. $LnItm->LineNumber.'">'; + if ($LnItm->Serialised==1){ + echo _('Enter Serial Numbers'); + } else { /*Just batch/roll/lot control */ + echo _('Enter Batch/Roll/Lot #'); + } + echo '</a></td>'; } - echo '</a></td>'; } echo '</tr>'; if (strlen($LnItm->Narrative)>1){ @@ -717,7 +723,7 @@ /*Start an SQL transaction */ -DB_Txn_Begin($db); + DB_Txn_Begin($db); if ($DefaultShipVia != $_SESSION['Items']->ShipVia){ $SQL = "UPDATE custbranch Modified: trunk/DeliveryDetails.php =================================================================== --- trunk/DeliveryDetails.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/DeliveryDetails.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -580,8 +580,8 @@ } else { /*link to print the quotation */ - echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation') .'</a></td></tr></table>'; - + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotation.php?' . SID .'identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation (Landscape)') .'</a></td></tr></table>'; + echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/reports.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="' . $rootpath . '/PDFQuotationPortrait.php?' . SID .'identifier='.$identifier . '&QuotationNo=' . $OrderNo . '">'. _('Print Quotation (Portrait)') .'</a></td></tr></table>'; } echo '<br><table class=selection><tr><td><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Order') . '" alt=""></td><td>' . ' ' . '<a href="'. $rootpath .'/SelectOrderItems.php?identifier='.$identifier . '&NewOrder=Yes">'. _('Add Another Sales Order') .'</a></td></tr></table>'; } else { Modified: trunk/GoodsReceived.php =================================================================== --- trunk/GoodsReceived.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/GoodsReceived.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -516,11 +516,13 @@ loccode, serialno, qualitytext, + expirationdate, quantity) VALUES ('" . $OrderLine->StockID . "', '" . $_SESSION['PO'.$identifier]->Location . "', '" . $Item->BundleRef . "', '', + '" . FormatDateForSQL($Item->ExpiryDate) . "', '" . $Item->BundleQty . "')"; } Modified: trunk/GoodsReceivedControlled.php =================================================================== --- trunk/GoodsReceivedControlled.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/GoodsReceivedControlled.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -4,8 +4,6 @@ include('includes/DefinePOClass.php'); include('includes/DefineSerialItems.php'); -//$PageSecurity = 11; - include('includes/session.inc'); $title = _('Receive Controlled Items'); @@ -32,7 +30,7 @@ exit; } -if (isset($_GET['LineNo'])){ +if (isset($_GET['LineNo']) AND $_GET['LineNo']>0){ $LineNo = $_GET['LineNo']; } elseif (isset($_POST['LineNo'])){ $LineNo = $_POST['LineNo']; Modified: trunk/SelectCompletedOrder.php =================================================================== --- trunk/SelectCompletedOrder.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SelectCompletedOrder.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -64,8 +64,16 @@ if (isset($OrderNumber)) { echo '<p class="page_title_text"><img src="'.$rootpath.'/css/'.$theme.'/images/sales.png" title="' . _('Sales Order') . '" alt="" />' . ' ' . _('Order Number') . ' - ' . $OrderNumber . '</p>'; + if (strlen($_SESSION['UserBranch'])>1){ + echo _('For customer') . ': ' . $SelectedCustomer; + echo "<input type=hidden name='SelectedCustomer' value='".$SelectedCustomer."'>"; + } } elseif (isset($CustomerRef)) { echo _('Customer Ref') . ' - ' . $CustomerRef; + if (strlen($_SESSION['UserBranch'])>1){ + echo ' ' . _('and for customer') . ': ' . $SelectedCustomer .' ' . _('and') . ' '; + echo "<input type=hidden name='SelectedCustomer' value='".$SelectedCustomer."'>"; + } } else { if (isset($SelectedCustomer)) { echo _('For customer') . ': ' . $SelectedCustomer .' ' . _('and') . ' '; @@ -212,13 +220,42 @@ $SelectedStockItem = $myrow[0]; $_POST['SearchOrders']='True'; unset($StockItemsResult); - echo '<br>' . _('For the part') . ': ' . $SelectedStockItem . ' ' . _('and') . " <input type=hidden name='SelectedStockItem' value='$SelectedStockItem'>"; + echo '<br />' . _('For the part') . ': ' . $SelectedStockItem . ' ' . _('and') . " <input type=hidden name='SelectedStockItem' value='$SelectedStockItem'>"; } } } else if (isset($_POST['SearchOrders']) AND Is_Date($_POST['OrdersAfterDate'])==1) { //figure out the SQL required from the inputs available if (isset($OrderNumber)) { + if (isset($SelectedCustomer)) { + $SQL = "SELECT salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto, SUM(salesorderdetails.unitprice*salesorderdetails.quantity*(1-salesorderdetails.discountpercent)) AS ordervalue + FROM salesorders, + salesorderdetails, + debtorsmaster, + custbranch + WHERE salesorders.orderno = salesorderdetails.orderno + AND salesorders.branchcode = custbranch.branchcode + AND salesorders.debtorno = debtorsmaster.debtorno + AND debtorsmaster.debtorno = custbranch.debtorno + AND salesorders.debtorno='" . $SelectedCustomer ."' + AND salesorders.orderno='". $OrderNumber ."' + AND salesorders.quotation=0 + AND salesorderdetails.completed".$completed." + GROUP BY salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto + ORDER BY salesorders.orderno"; + } else { //Set order number and SelectedCustomer not set $SQL = "SELECT salesorders.orderno, debtorsmaster.name, custbranch.brname, @@ -245,7 +282,9 @@ salesorders.deliverydate, salesorders.deliverto ORDER BY salesorders.orderno"; + } } elseif (isset($CustomerRef)) { + if (isset($SelectedCustomer)) { $SQL = "SELECT salesorders.orderno, debtorsmaster.name, custbranch.brname, @@ -261,6 +300,7 @@ AND salesorders.branchcode = custbranch.branchcode AND salesorders.debtorno = debtorsmaster.debtorno AND debtorsmaster.debtorno = custbranch.debtorno + AND salesorders.debtorno='" . $SelectedCustomer ."' AND salesorders.customerref like '%". $CustomerRef."%' AND salesorders.quotation=0 AND salesorderdetails.completed".$completed." @@ -272,6 +312,34 @@ salesorders.deliverydate, salesorders.deliverto ORDER BY salesorders.orderno"; + } else { //customer not selected + $SQL = "SELECT salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto, SUM(salesorderdetails.unitprice*salesorderdetails.quantity*(1-salesorderdetails.discountpercent)) AS ordervalue + FROM salesorders, + salesorderdetails, + debtorsmaster, + custbranch + WHERE salesorders.orderno = salesorderdetails.orderno + AND salesorders.branchcode = custbranch.branchcode + AND salesorders.debtorno = debtorsmaster.debtorno + AND debtorsmaster.debtorno = custbranch.debtorno + AND salesorders.customerref like '%". $CustomerRef."%' + AND salesorders.quotation=0 + AND salesorderdetails.completed".$completed." + GROUP BY salesorders.orderno, + debtorsmaster.name, + custbranch.brname, + salesorders.customerref, + salesorders.orddate, + salesorders.deliverydate, + salesorders.deliverto + ORDER BY salesorders.orderno"; + } } else { $DateAfterCriteria = FormatDateforSQL($_POST['OrdersAfterDate']); @@ -399,8 +467,8 @@ $SalesOrdersResult = DB_query($SQL,$db); if (DB_error_no($db) !=0) { - echo '<br>' . _('No orders were returned by the SQL because') . ' ' . DB_error_msg($db); - echo "<br>$SQL"; + echo '<br />' . _('No orders were returned by the SQL because') . ' ' . DB_error_msg($db); + echo "<br />$SQL"; } }//end of which button clicked options @@ -416,22 +484,22 @@ echo "<tr><td></td>"; } -if (!isset($OrderNumber) or $OrderNumber==''){ - echo '<td>' . _('Order Number') . ':</td><td>' . "<input type='text' name='OrderNumber' maxlength =8 size=9></td><td>" . _('for all orders placed after') . - ": </td><td><input type='text' class='date' alt='".$_SESSION['DefaultDateFormat']."' name='OrdersAfterDate' maxlength =10 size=11 value=" . $_POST['OrdersAfterDate'] . "></td><td>" . - "<input type='submit' name='SearchOrders' value='" . _('Search Orders') . "'></td></tr>"; - echo '<tr><td></td><td>' . _('Customer Ref') . ':</td><td>' . "<input type='text' name='CustomerRef' maxlength =8 size=9></td> +echo '<td>' . _('Order Number') . ':</td> + <td>' . "<input type='text' name='OrderNumber' maxlength =8 size=9 value ='" . $_POST['OrderNumber'] . "'></td> + <td>" . _('for all orders placed after') . ": </td><td><input type='text' class='date' alt='".$_SESSION['DefaultDateFormat']."' name='OrdersAfterDate' maxlength =10 size=11 value=" . $_POST['OrdersAfterDate'] . "></td> + <td>" . "<input type='submit' name='SearchOrders' value='" . _('Search Orders') . "'></td></tr>"; +echo '<tr><td></td><td>' . _('Customer Ref') . ':</td><td>' . "<input type='text' name='CustomerRef' maxlength =8 size=9></td> <td></td><td colspan=2><input type='checkbox' ".$ShowChecked." name='completed' />"._('Show Completed orders only') . "</td></tr>"; -} + echo '</table>'; if (!isset($SelectedStockItem)) { $SQL='SELECT categoryid, categorydescription FROM stockcategory ORDER BY categorydescription'; $result1 = DB_query($SQL,$db); - echo '<br>'; + echo '<br />'; echo '<div class="page_help_text"><font size=1>' . _('To search for sales orders for a specific part use the part selection facilities below') . ' </font></div>'; - echo '<br><table class=selection>'; + echo '<br /><table class=selection>'; echo '<tr><td><font size=1>' . _('Select a stock category') . ':</font>'; echo '<select name="StockCat">'; @@ -461,7 +529,7 @@ If (isset($StockItemsResult)) { - echo '<br><table cellpadding=2 colspan=7 class=selection>'; + echo '<br /><table cellpadding=2 colspan=7 class=selection>'; $TableHeadings = "<tr><th>" . _('Code') . "</th>" . "<th>" . _('Description') . "</th>" . @@ -511,7 +579,7 @@ /*show a table of the orders returned by the SQL */ - echo '<br><table cellpadding=2 colspan=6 width=90% class=selection>'; + echo '<br /><table cellpadding=2 colspan=6 width=90% class=selection>'; $tableheader = "<tr><th>" . _('Order') . " #</th> <th>" . _('Customer') . "</th> Modified: trunk/SelectCustomer.php =================================================================== --- trunk/SelectCustomer.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SelectCustomer.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -1,6 +1,6 @@ <?php /* $Id$*/ -//$PageSecurity = 2; + include ('includes/session.inc'); $title = _('Search Customers'); include ('includes/header.inc'); @@ -119,8 +119,9 @@ custbranch.phoneno, custbranch.faxno FROM debtorsmaster LEFT JOIN custbranch - ON debtorsmaster.debtorno = custbranch.debtorno, debtortype - WHERE debtorsmaster.typeid = debtortype.typeid"; + ON debtorsmaster.debtorno = custbranch.debtorno + INNER JOIN debtortype + ON debtorsmaster.typeid = debtortype.typeid"; } else { if (strlen($_POST['Keywords']) > 0) { //using the customer name Modified: trunk/SelectSupplier.php =================================================================== --- trunk/SelectSupplier.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SelectSupplier.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -166,7 +166,7 @@ echo '</td><td valign=top class="select">'; /* Supplier Transactions */ echo "<a href=\"$rootpath/PO_Header.php?" . SID . '&NewOrder=Yes&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Purchase Order for This Supplier') . '</a><br>'; echo "<a href=\"$rootpath/SupplierInvoice.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Suppliers Invoice') . '</a><br>'; - echo "<a href=\"$rootpath/SupplierCredit.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Suppliers Credit Note') . '</a><br>'; + echo "<a href=\"$rootpath/SupplierCredit.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . '&New=True' . "\">" . _('Enter a Suppliers Credit Note') . '</a><br>'; echo "<a href=\"$rootpath/Payments.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "\">" . _('Enter a Payment to, or Receipt from the Supplier') . '</a><br>'; echo '<br>'; echo "<br><a href='$rootpath/ReverseGRN.php?" . SID . '&SupplierID=' . $_SESSION['SupplierID'] . "'>" . _('Reverse an Outstanding Goods Received Note (GRN)') . '</a>'; Modified: trunk/StockCheck.php =================================================================== --- trunk/StockCheck.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/StockCheck.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -175,8 +175,9 @@ $FontSize=10; $YPos -=$line_height; - if ($_POST['ShowInfo']==true){ + if (isset($_POST['ShowInfo']) and $_POST['ShowInfo']==true){ + $SQL = "SELECT SUM(salesorderdetails.quantity - salesorderdetails.qtyinvoiced) AS qtydemand FROM salesorderdetails, salesorders Modified: trunk/StockSerialItems.php =================================================================== --- trunk/StockSerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/StockSerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -1,8 +1,8 @@ <?php /* $Id$*/ -//$PageSecurity = 2; + include('includes/session.inc'); $title = _('Stock Of Controlled Items'); include('includes/header.inc'); @@ -28,21 +28,23 @@ mbflag, decimalplaces, serialised, - controlled + controlled, + perishable FROM stockmaster WHERE stockid='".$StockID."'", $db, _('Could not retrieve the requested item because')); -$myrow = DB_fetch_row($result); +$myrow = DB_fetch_array($result); -$Description = $myrow[0]; -$UOM = $myrow[1]; -$DecimalPlaces = $myrow[3]; -$Serialised = $myrow[4]; -$Controlled = $myrow[5]; +$Description = $myrow['description']; +$UOM = $myrow['units']; +$DecimalPlaces = $myrow['decimalplaces']; +$Serialised = $myrow['serialised']; +$Controlled = $myrow['controlled']; +$Perishable = $myrow['perishable']; -if ($myrow[2]=='K' OR $myrow[2]=='A' OR $myrow[2]=='D'){ +if ($myrow['mbflag']=='K' OR $myrow['mbflag']=='A' OR $myrow['mbflag']=='D'){ prnMsg(_('This item is either a kitset or assembly or a dummy part and cannot have a stock holding') . '. ' . _('This page cannot be displayed') . '. ' . _('Only serialised or controlled items can be displayed in this page'),'error'); include('includes/footer.inc'); @@ -59,7 +61,8 @@ $myrow = DB_fetch_row($result); $sql = "SELECT serialno, - quantity + quantity, + expirationdate FROM stockserialitems WHERE loccode='" . $_GET['Location'] . "' AND stockid = '" . $StockID . "' @@ -72,30 +75,48 @@ echo '<table cellpadding=2 class=selection>'; if ($Serialised==1){ - echo '<tr<th colspan=3><font color=navy size=2>' . _('Serialised items in') . ' '; + echo '<tr><th colspan="5"><font color=navy size=2>' . _('Serialised items in') . ' '; } else { - echo '<tr<th colspan=3><font color=navy size=2>' . _('Controlled items in') . ' '; + echo '<tr><th colspan="11"><font color=navy size=2>' . _('Controlled items in') . ' '; } echo $myrow[0]. '</font></th></tr>'; -echo "<tr><th colspan=3><font color=navy size=2>".$StockID ."-". $Description ."</b> (" . _('In units of') . ' ' . $UOM . ')</font></th></tr>'; +echo "<tr><th colspan=11><font color=navy size=2>".$StockID ."-". $Description ."</b> (" . _('In units of') . ' ' . $UOM . ')</font></th></tr>'; if ($Serialised == 1){ - $tableheader = "<tr> - <th>" . _('Serial Number') . "</th> - <th>" . _('Serial Number') . "</th> - <th>" . _('Serial Number') . "</th> - </tr>"; -} else { - $tableheader = "<tr> - <th>" . _('Batch/Bundle Ref') . "</th> - <th>" . _('Quantity On Hand') . "</th> - <th>" . _('Batch/Bundle Ref') . "</th> - <th>" . _('Quantity On Hand') . "</th> - <th>" . _('Batch/Bundle Ref') . "</th> - <th>" . _('Quantity On Hand') . "</th> + $tableheader = '<tr> + <th>' . _('Serial Number') . '</th> + <th></th> + <th>' . _('Serial Number') . '</th> + <th></th> + <th>' . _('Serial Number') . '</th> + </tr>'; +} else if ($Serialised == 0 and $Perishable==0){ + $tableheader = '<tr> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> </tr>"; +} else if ($Serialised == 0 and $Perishable==1){ + $tableheader = '<tr> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th>' . _('Expiry Date') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th>' . _('Expiry Date') . '</th> + <th></th> + <th>' . _('Batch/Bundle Ref') . '</th> + <th>' . _('Quantity On Hand') . '</th> + <th>' . _('Expiry Date') . '</th> + </tr>'; } echo $tableheader; $TotalQuantity =0; @@ -115,15 +136,17 @@ $TotalQuantity += $myrow['quantity']; if ($Serialised == 1){ - printf('<td>%s</td>', - $myrow['serialno'] - ); - } else { - printf("<td>%s</td> - <td class=number>%s</td>", - $myrow['serialno'], - number_format($myrow['quantity'],$DecimalPlaces) - ); + echo '<td>'.$myrow['serialno'].'/td>'; + echo '<th></th>'; + } else if ($Serialised == 0 and $Perishable==0) { + echo '<td>'.$myrow['serialno'].'</td> + <td class="number">'.number_format($myrow['quantity'],$DecimalPlaces).'</td>'; + echo '<th></th>'; + } else if ($Serialised == 0 and $Perishable==1){ + echo '<td>'.$myrow['serialno'].'</td> + <td class="number">'.number_format($myrow['quantity'],$DecimalPlaces). '</td> + <td>' . ConvertSQLDate($myrow['expirationdate']). '</td>'; + echo '<th></th>'; } $j++; If ($j == 36){ @@ -144,5 +167,4 @@ echo '</form>'; include('includes/footer.inc'); - ?> \ No newline at end of file Modified: trunk/SupplierCredit.php =================================================================== --- trunk/SupplierCredit.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/SupplierCredit.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -35,6 +35,10 @@ //this is available from the menu on this page already //echo "<a href='" . $rootpath . '/SelectSupplier.php?' . SID . "'>" . _('Back to Suppliers') . '</a><br>'; +if (isset($_GET['New'])) { + unset($_SESSION['SuppTrans']); +} + if (!isset($_SESSION['SuppTrans']->SupplierName)) { $sql='SELECT suppname FROM suppliers WHERE supplierid="'.$_GET['SupplierID'].'"'; $result = DB_query($sql,$db); Modified: trunk/Suppliers.php =================================================================== --- trunk/Suppliers.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/Suppliers.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -444,11 +444,11 @@ } if (!isset($_POST['New'])) { - $supptranssql = "SELECT COUNT(supplierno) - FROM supptrans - WHERE supplierno='".$SupplierID ."'"; + $supptranssql = "SELECT supplierno + FROM supptrans + WHERE supplierno='".$SupplierID ."'"; $suppresult = DB_query($supptranssql, $db); - $supptrans = DB_fetch_row($suppresult); + $supptrans = DB_num_rows($suppresult); $suppcurrssql = "SELECT currcode FROM suppliers @@ -481,7 +481,7 @@ WHERE supplierid = '".$SupplierID."'"; } else { if ($suppcurr[0] != $_POST['CurrCode']) { - prnMsg( _('Cannot change currency code as transactions already exist'), info); + prnMsg( _('Cannot change currency code as transactions already exist'), 'info'); } $sql = "UPDATE suppliers SET suppname='" . $_POST['SuppName'] . "', address1='" . $_POST['Address1'] . "', Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/doc/Change.log.html 2011-03-03 09:13:12 UTC (rev 4501) @@ -1,6 +1,9 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> -<p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php </p> +<p>3/3/11: Exson/Baran/Phil fix to customer login to ensure that other customers orders are not displayed when searching by customer ref or order no</p> +<p>3/3/11: Tim launchpad mods to revision 4441 including change to allow supplier currency to be changed if there are no transactions already against the supplier. Ensure credit note session variable is unset before attempting to create a new credit note from the supplier form. Tim's work to add perisable expiry dates to the serial items logic - affects quite a few scripts. Headings to stock check script even if no quantity is shown. Portrait quotations. Not included change to default delivery date to the date the customer requested - left to be the current day's date. Not included Tim's unit pricing work .. yet launchpad revisions 4442-4447 inclusive</p> +<p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php links with matching quotes in WorkOrderEntry</p> +<p>27/2/11: Phil StockUsage.php now totals usage each month even in months where there was none - average now includes months with no usage</p> <p>27/2/11: Phil fix units deletion issue reported by Exson in UnitsOfMeasure.php script - checked for none existant units field in contracts table - removed the check</p> <p>22/2/11: Phil fix PDFTopItems.php for changed variable names - now using CamelCase tried to rework to conform</p> <p>22/2/11: Phil remove options for PDFLanguage that are not unique in WWW_Users.php - make it default to the users settings in the SESSION for UserSettings.php</p> Modified: trunk/includes/Add_SerialItems.php =================================================================== --- trunk/includes/Add_SerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/Add_SerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -66,7 +66,7 @@ } if (!$SerialError){ - $LineItem->SerialItems[$NewSerialNo] = new SerialItem ($_POST['SerialNo' . $i], $NewQty); + $LineItem->SerialItems[$NewSerialNo] = new SerialItem ($_POST['SerialNo' . $i], $NewQty, $_POST['ExpiryDate' . $i]); } } } /* end if posted Serialno . i is not blank */ @@ -75,7 +75,8 @@ if (!isset($_POST['Bundles'])) { $_POST['Bundles']=0; } - for ($i=0;$i < count($_POST['Bundles']);$i++){ /*there is an entry in the multi select list box */ + echo count($_POST['Bundles']); + for ($i=0;$i < count($_POST['Bundles'])-1;$i++){ /*there is an entry in the multi select list box */ if ($LineItem->Serialised==1){ /*only if the item is serialised */ $LineItem->SerialItems[$_POST['Bundles'][$i]] = new SerialItem ($_POST['Bundles'][$i], ($InOutModifier>0?1:-1) ); } else { Modified: trunk/includes/Add_SerialItemsOut.php =================================================================== --- trunk/includes/Add_SerialItemsOut.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/Add_SerialItemsOut.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -3,11 +3,10 @@ /*ProcessSerialItems.php takes the posted variables and adds to the SerialItems array in either the cartclass->LineItems->SerialItems or the POClass->LineItems->SerialItems */ - if (isset($_POST['AddBatches'])){ for ($i=0;$i < 10;$i++){ - if(strlen($_POST['SerialNo' . $i])>0){ + if(isset($_POST['SerialNo' . $i]) and strlen($_POST['SerialNo' . $i])>0){ $ExistingBundleQty = ValidBundleRef($StockID, $LocationOut, $_POST['SerialNo' . $i]); if ($ExistingBundleQty >0){ $AddThisBundle = true; @@ -15,30 +14,31 @@ the first entered one - no warning given though ? */ if ($_POST['Qty' . $i] > $ExistingBundleQty){ if ($LineItem->Serialised ==1){ - echo "<BR>" . $_POST['SerialNo' . $i] . " " . _('has already been sold'); + echo "<br />" . $_POST['SerialNo' . $i] . " " . _('has already been sold'); $AddThisBundle = false; } elseif ($ExistingBundleQty==0) { /* and its a batch */ - echo "<BR>There is none of " . $_POST['SerialNo' . $i] . " left."; + echo "<br />There is none of " . $_POST['SerialNo' . $i] . " left."; $AddThisBundle = false; } else { - echo '<BR>' . _('There is only') . ' ' . $ExistingBundleQty . ' ' . _('of') . ' ' . $_POST['SerialNo' . $i] . ' ' . _('remaining') . '. ' . _('The entered quantity will be reduced to the remaining amount left of this batch/bundle/roll'); + echo '<br />' . _('There is only') . ' ' . $ExistingBundleQty . ' ' . _('of') . ' ' . $_POST['SerialNo' . $i] . + ' ' . _('remaining') . '. ' . _('The entered quantity will be reduced to the remaining amount left of this batch/bundle/roll'); $_POST['Qty' . $i] = $ExistingBundleQty; $AddThisBundle = true; } } - if ($AddThisBundle==true){ - $LineItem->SerialItems[$_POST['SerialNo' . $i]] = new SerialItem ($_POST['SerialNo' . $i], $_POST['Qty' . $i]); + if ($AddThisBundle==true and $_POST['Qty' . $i]>0){ + $LineItem->SerialItems[$_POST['SerialNo' . $i]] = new SerialItem ($_POST['SerialNo' . $i], $_POST['Qty' . $i], $_POST['ExpiryDate' . $i]); } } /*end if ExistingBundleQty >0 */ } /* end if posted Serialno . i is not blank */ } /* end of the loop aroung the form input fields */ - for ($i=0;$i < count($_POST['Bundles']);$i++){ /*there is an entry in the multi select list box */ - if ($LineItem->Serialised==1){ /*only if the item is serialised */ - $LineItem->SerialItems[$_POST['Bundles'][$i]] = new SerialItem ($_POST['Bundles'][$i], 1); - } - } +// for ($i=0;$i < count($_POST['Bundles']);$i++){ /*there is an entry in the multi select list box */ +// if ($LineItem->Serialised==1){ /*only if the item is serialised */ +// $LineItem->SerialItems[$_POST['Bundles'][$i]] = new SerialItem ($_POST['Bundles'][$i], 1); +// } +// } } /*end if the user hit the enter button */ @@ -47,4 +47,8 @@ unset($LineItem->SerialItems[$_GET['Delete']]); } +if (isset($_GET['DELETEALL'])){ + $LineItem->SerialItems=array(); +} + ?> Modified: trunk/includes/DefineSerialItems.php =================================================================== --- trunk/includes/DefineSerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/DefineSerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -4,10 +4,10 @@ function ValidBundleRef ($StockID, $LocCode, $BundleRef){ global $db; - $SQL = "SELECT quantity - FROM stockserialitems - WHERE stockid='" . $StockID . "' - AND loccode ='" . $LocCode . "' + $SQL = "SELECT quantity + FROM stockserialitems + WHERE stockid='" . $StockID . "' + AND loccode ='" . $LocCode . "' AND serialno='" . $BundleRef . "'"; $Result = DB_query($SQL, $db); if (DB_num_rows($Result)==0){ @@ -22,12 +22,14 @@ var $BundleRef; var $BundleQty; + var $ExpiryDate; //Constructor - function SerialItem($BundleRef, $BundleQty){ + function SerialItem($BundleRef, $BundleQty, $ExpiryDate='0000-00-00'){ $this->BundleRef = $BundleRef; $this->BundleQty = $BundleQty; + $this->ExpiryDate = $ExpiryDate; } }//class SerialItem ?> \ No newline at end of file Modified: trunk/includes/InputSerialItems.php =================================================================== --- trunk/includes/InputSerialItems.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/InputSerialItems.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -88,15 +88,27 @@ '&LineNo=' . $LineNo .'">'. _('Edit'). '</a> | '; $RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&DELETEALL=YES&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Remove All'). '</a><br></div>'; +$sql="SELECT perishable + FROM stockmaster + WHERE stockid='".$StockID."'"; +$result=DB_query($sql, $db); +$myrow=DB_fetch_array($result); +$Perishable=$myrow['perishable']; if ($LineItem->Serialised==1){ $tableheader .= '<tr> <th>'. _('Serial No').'</th> - </Tr>'; + </tr>'; +} else if ($LineItem->Serialised==0 and $Perishable==1){ + $tableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Quantity'). '</th> + <th>'. _('Expiry Date'). '</th> + </tr>'; } else { - $tableheader = '<TR> + $tableheader = '<tr> <th>'. _('Batch/Roll/Bundle'). ' #</th> - <th class=tableheader>'. _('Quantity'). '</th> - </tr>'; + <th>'. _('Quantity'). '</th> + </tr>'; } echo $EditLink . $RemoveLink; Modified: trunk/includes/InputSerialItemsKeyed.php =================================================================== --- trunk/includes/InputSerialItemsKeyed.php 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/InputSerialItemsKeyed.php 2011-03-03 09:13:12 UTC (rev 4501) @@ -47,8 +47,11 @@ echo '<td>' . $Bundle->BundleRef . '</td>'; - if ($LineItem->Serialised==0){ + if ($LineItem->Serialised==0 and $Perishable==0){ echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + } else if ($LineItem->Serialised==0 and $Perishable==1){ + echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + echo '<td class=number>' . $Bundle->ExpiryDate . '</td>'; } echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?identifier=' . $identifier . '&Delete=' . $Bundle->BundleRef . '&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Delete'). '</a></td></tr>'; @@ -81,7 +84,7 @@ <input type=hidden name=StockID value="' . $StockID . '"> <input type=hidden name="identifier" value="' . $identifier . '"> <input type=hidden name=EntryType value="KEYED">'; - echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; +echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; if ( isset($_GET['EditControlled']) ) { $EditControlled = isset($_GET['EditControlled'])?$_GET['EditControlled']:false; } elseif ( isset($_POST['EditControlled']) ){ @@ -102,6 +105,9 @@ if ($LineItem->Serialised==1){ echo '<input type=hidden name="Qty' . $StartAddingAt .'" Value=1></TR>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 + value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; } else { echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; @@ -120,6 +126,10 @@ if ($LineItem->Serialised==1){ echo '<input type=hidden name="Qty' . ($StartAddingAt+$i) .'" Value=1></tr>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$i) .'" size=11 maxlength=10></td>'; + echo '<td><input type=text class="date" name="ExpiryDate' . ($StartAddingAt+$i) .'" size=11 + value="" alt="'.$_SESSION['DefaultDateFormat'].'" maxlength=10></td></tr>'; } else { echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$i) .'" size=11 maxlength=10></tr>'; } @@ -136,4 +146,4 @@ document.Ga6uF5Wa.SerialNo0.focus(); //]]> </script>'; /*end of nested table */ -?> +?> \ No newline at end of file Modified: trunk/includes/PDFStockCheckPageHeader.inc =================================================================== --- trunk/includes/PDFStockCheckPageHeader.inc 2011-02-27 09:18:42 UTC (rev 4500) +++ trunk/includes/PDFStockCheckPageHeader.inc 2011-03-03 09:13:12 UTC (rev 4501) @@ -28,16 +28,22 @@ $Xpos = $Left_Margin+1; /*draw vertical lines */ -$pdf->line(350, $YPos-$line_height,350, $Bottom_Margin+24); -$pdf->line(415, $YPos-$line_height,415, $Bottom_Margin+24); -$pdf->line(475, $YPos-$line_height,475, $Bottom_Margin+24); +$pdf->line(370, $YPos+$BoxHeight,370, $Bottom_Margin+24); $LeftOvers = $pdf->addTextWrap($Xpos,$YPos,300-$Left_Margin,$FontSize,_('Item'), 'centre'); -if ($_POST['ShowInfo']==true){ +if (isset($_POST['ShowInfo']) and $_POST['ShowInfo']==true){ + /*draw vertical lines */ + $pdf->line(415, $YPos-$line_height,415, $Bottom_Margin+24); + $pdf->line(475, $YPos-$line_height,475, $Bottom_Margin+24); $LeftOvers = $pdf->addTextWrap(341,$YPos,60,$FontSize,_('QOH'), 'centre'); $LeftOvers = $pdf->addTextWrap(341+61,$YPos,80,$FontSize,_('Cust Ords'), 'centre'); $LeftOvers = $pdf->addTextWrap(341+61+61,$YPos,80,$FontSize,_('Available'), 'centre'); - } +} else { + /*draw vertical lines */ + $pdf->line(435, $YPos+$BoxHeight,435, $Bottom_Margin+24); + $LeftOvers = $pdf->addTextWrap(371,$YPos,60,$FontSize,_('Quantity'), 'centre'); + $LeftOvers = $pdf->addTextWrap(341+61+61,$YPos,80,$FontSize,_('Remarks'), 'centre'); +} $FontSize=10; $YPos -=($line_height); ?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-03 09:14:52
|
Revision: 4502 http://web-erp.svn.sourceforge.net/web-erp/?rev=4502&view=rev Author: daintree Date: 2011-03-03 09:14:45 +0000 (Thu, 03 Mar 2011) Log Message: ----------- New Portrait quotation OutputSerialItems Added Paths: ----------- trunk/PDFQuotationPortrait.php trunk/includes/OutputSerialItems.php trunk/includes/PDFQuotationPortraitPageHeader.inc Added: trunk/PDFQuotationPortrait.php =================================================================== --- trunk/PDFQuotationPortrait.php (rev 0) +++ trunk/PDFQuotationPortrait.php 2011-03-03 09:14:45 UTC (rev 4502) @@ -0,0 +1,252 @@ +<?php + +/* $Id: PDFQuotationPortrait.php 4491 2011-02-15 06:31:08Z daintree $ */ + + +include('includes/session.inc'); +include('includes/SQL_CommonFunctions.inc'); + +//Get Out if we have no order number to work with +If (!isset($_GET['QuotationNo']) || $_GET['QuotationNo']==""){ + $title = _('Select Quotation To Print'); + include('includes/header.inc'); + echo '<div class="centre"><br><br><br>'; + prnMsg( _('Select a Quotation to Print before calling this page') , 'error'); + echo '<br><br><br><table class="table_index"><tr><td class="menu_group_item"> + <li><a href="'. $rootpath . '/SelectSalesOrder.php?'. SID .'&Quotations=Quotes_Only">' . _('Quotations') . '</a></li> + </td></tr></table></div><br><br><br>'; + include('includes/footer.inc'); + exit(); +} + +/*retrieve the order details from the database to print */ +$ErrMsg = _('There was a problem retrieving the quotation header details for Order Number') . ' ' . $_GET['QuotationNo'] . ' ' . _('from the database'); + +$sql = "SELECT salesorders.customerref, + salesorders.comments, + salesorders.orddate, + salesorders.deliverto, + salesorders.deladd1, + salesorders.deladd2, + salesorders.deladd3, + salesorders.deladd4, + salesorders.deladd5, + salesorders.deladd6, + debtorsmaster.name, + debtorsmaster.address1, + debtorsmaster.address2, + debtorsmaster.address3, + debtorsmaster.address4, + debtorsmaster.address5, + debtorsmaster.address6, + shippers.shippername, + salesorders.printedpackingslip, + salesorders.datepackingslipprinted, + salesorders.branchcode, + locations.taxprovinceid, + locations.locationname + FROM salesorders, + debtorsmaster, + shippers, + locations + WHERE salesorders.debtorno=debtorsmaster.debtorno + AND salesorders.shipvia=shippers.shipper_id + AND salesorders.fromstkloc=locations.loccode + AND salesorders.quotation=1 + AND salesorders.orderno='" . $_GET['QuotationNo'] ."'"; + +$result=DB_query($sql,$db, $ErrMsg); + +//If there are no rows, there's a problem. +if (DB_num_rows($result)==0){ + $title = _('Print Quotation Error'); + include('includes/header.inc'); + echo '<div class="centre"><br><br><br>'; + prnMsg( _('Unable to Locate Quotation Number') . ' : ' . $_GET['QuotationNo'] . ' ', 'error'); + echo '<br><br><br><table class="table_index"><tr><td class="menu_group_item"> + <li><a href="'. $rootpath . '/SelectSalesOrder.php?'. SID .'&Quotations=Quotes_Only">' . _('Outstanding Quotations') . '</a></li> + </td></tr></table></div><br><br><br>'; + include('includes/footer.inc'); + exit; +} elseif (DB_num_rows($result)==1){ /*There is only one order header returned - thats good! */ + + $myrow = DB_fetch_array($result); +} + +/*retrieve the order details from the database to print */ + +/* Then there's an order to print and its not been printed already (or its been flagged for reprinting/ge_Width=807; +) +LETS GO */ +$PaperSize = 'A4'; +include('includes/PDFStarter.php'); +$pdf->addInfo('Title', _('Customer Quotation') ); +$pdf->addInfo('Subject', _('Quotation') . ' ' . $_GET['QuotationNo']); +$FontSize=12; +$PageNumber = 1; +$line_height=24; +// $pdf->selectFont('./fonts/Helvetica.afm'); + +/* Now ... Has the order got any line items still outstanding to be invoiced */ + +$ErrMsg = _('There was a problem retrieving the quotation line details for quotation Number') . ' ' . + $_GET['QuotationNo'] . ' ' . _('from the database'); + +$sql = "SELECT salesorderdetails.stkcode, + stockmaster.description, + salesorderdetails.quantity, + salesorderdetails.qtyinvoiced, + salesorderdetails.unitprice, + salesorderdetails.discountpercent, + stockmaster.taxcatid, + salesorderdetails.narrative + FROM salesorderdetails INNER JOIN stockmaster + ON salesorderdetails.stkcode=stockmaster.stockid + WHERE salesorderdetails.orderno='" . $_GET['QuotationNo'] . "'"; + +$result=DB_query($sql,$db, $ErrMsg); + +$ListCount = 0; // UldisN + +if (DB_num_rows($result)>0){ + /*Yes there are line items to start the ball rolling with a page header */ + include('includes/PDFQuotationPortraitPageHeader.inc'); + + $QuotationTotal =0; + $QuotationTotalEx=0; + $TaxTotal=0; + + while ($myrow2=DB_fetch_array($result)){ + + $ListCount ++; + + if ((strlen($myrow2['narrative']) >200 AND $YPos-$line_height <= 75) + OR (strlen($myrow2['narrative']) >1 AND $YPos-$line_height <= 62) + OR $YPos-$line_height <= 50){ + /* We reached the end of the page so finsih off the page and start a newy */ + $PageNumber++; + include ('includes/PDFQuotationPageHeader.inc'); + + } //end if need a new page headed up + + $DisplayQty = number_format($myrow2['quantity'],2); + $DisplayPrevDel = number_format($myrow2['qtyinvoiced'],2); + $DisplayPrice = number_format($myrow2['unitprice'],2); + $DisplayDiscount = number_format($myrow2['discountpercent']*100,2) . '%'; + $SubTot = $myrow2['unitprice']*$myrow2['quantity']*(1-$myrow2['discountpercent']); + $TaxProv = $myrow['taxprovinceid']; + $TaxCat = $myrow2['taxcatid']; + $Branch = $myrow['branchcode']; + $sql3 = " select taxgrouptaxes.taxauthid from taxgrouptaxes INNER JOIN custbranch ON taxgrouptaxes.taxgroupid=custbranch.taxgroupid WHERE custbranch.branchcode='" .$Branch ."'"; + $result3=DB_query($sql3,$db, $ErrMsg); + while ($myrow3=DB_fetch_array($result3)){ + $TaxAuth = $myrow3['taxauthid']; + } + + $sql4 = "SELECT * FROM taxauthrates WHERE dispatchtaxprovince='" .$TaxProv ."' AND taxcatid='" .$TaxCat ."' AND taxauthority='" .$TaxAuth ."'"; + $result4=DB_query($sql4,$db, $ErrMsg); + while ($myrow4=DB_fetch_array($result4)){ + $TaxClass = 100 * $myrow4['taxrate']; + } + + $DisplayTaxClass = $TaxClass . "%"; + $TaxAmount = (($SubTot/100)*(100+$TaxClass))-$SubTot; + $DisplayTaxAmount = number_format($TaxAmount,2); + + $LineTotal = $SubTot + $TaxAmount; + $DisplayTotal = number_format($LineTotal,2); + + $FontSize=10; + + $LeftOvers = $pdf->addTextWrap($XPos+1,$YPos,100,$FontSize,$myrow2['stkcode']); + $LeftOvers = $pdf->addTextWrap(120,$YPos,295,$FontSize,$myrow2['description']); + $LeftOvers = $pdf->addTextWrap(180,$YPos,85,$FontSize,$DisplayQty,'right'); + $LeftOvers = $pdf->addTextWrap(230,$YPos,85,$FontSize,$DisplayPrice,'right'); + if ($DisplayDiscount > 0){ + $LeftOvers = $pdf->addTextWrap(280,$YPos,85,$FontSize,$DisplayDiscount,'right'); + } + $LeftOvers = $pdf->addTextWrap(330,$YPos,85,$FontSize,$DisplayTaxClass,'right'); + $LeftOvers = $pdf->addTextWrap(410,$YPos,85,$FontSize,$DisplayTaxAmount,'center'); + $LeftOvers = $pdf->addTextWrap(460,$YPos,90,$FontSize,$DisplayTotal,'right'); + if (strlen($myrow2['narrative'])>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos+1,$YPos,750,10,$myrow2['narrative']); + if (strlen($LeftOvers>1)){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos+1,$YPos,750,10,$LeftOvers); + } + } + $QuotationTotal +=$LineTotal; + $QuotationTotalEx +=$SubTot; + $TaxTotal +=$TaxAmount; + + /*increment a line down for the next line item */ + $YPos -= ($line_height); + + } //end while there are line items to print out + if ((strlen($myrow['comments']) >200 AND $YPos-$line_height <= 75) + OR (strlen($myrow['comments']) >1 AND $YPos-$line_height <= 62) + OR $YPos-$line_height <= 50){ + /* We reached the end of the page so finsih off the page and start a newy */ + $PageNumber++; + include ('includes/PDFQuotationPageHeader.inc'); + + } //end if need a new page headed up + + $LeftOvers = $pdf->addTextWrap($XPos,$YPos-80,200,10,_('Notes:')); + $LeftOvers = $pdf->addText($XPos,$YPos-95,10,$myrow['comments']); + + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,10,$FontSize,$LeftOvers); + } + } + } + } + $YPos -= ($line_height); + $LeftOvers = $pdf->addTextWrap(40,$YPos,655,$FontSize,_('Total Tax'),'right'); + $LeftOvers = $pdf->addTextWrap(700,$YPos,90,$FontSize,number_format($TaxTotal,2),'right'); + $YPos -= 12; + $LeftOvers = $pdf->addTextWrap(40,$YPos,655,$FontSize,_('Quotation Excluding Tax'),'right'); + $LeftOvers = $pdf->addTextWrap(700,$YPos,90,$FontSize,number_format($QuotationTotalEx,2),'right'); + $YPos -= 12; + $LeftOvers = $pdf->addTextWrap(40,$YPos,655,$FontSize,_('Quotation Including Tax'),'right'); + $LeftOvers = $pdf->addTextWrap(700,$YPos,90,$FontSize,number_format($QuotationTotal,2),'right'); + +} /*end if there are line details to show on the quotation*/ + + +//$pdfcode = $pdf->output('PDFQuotation.pdf', 'I'); +//$len = strlen($pdfcode); +if ($ListCount == 0){ + $title = _('Print Quotation Error'); + include('includes/header.inc'); + echo '<p>'. _('There were no items on the quotation') . '. ' . _('The quotation cannot be printed'). + '<br><a href="' . $rootpath . '/SelectSalesOrder.php?' . SID . '&Quotation=Quotes_only">'. _('Print Another Quotation'). + '</a>' . '<br>'. '<a href="' . $rootpath . '/index.php?' . SID . '">' . _('Back to the menu') . '</a>'; + include('includes/footer.inc'); + exit; +} else { +/* + header('Content-type: application/pdf'); + header('Content-Length: ' . $len); + header('Content-Disposition: inline; filename=Quotation.pdf'); + header('Expires: 0'); + header('Cache-Control: must-revalidate, post-check=0, pre-check=0'); + header('Pragma: public'); +//echo 'here'; + $pdf->Output('PDFQuotation.pdf', 'I'); +*/ + $pdf->OutputI($_SESSION['DatabaseName'] . '_Quotation_' . date('Y-m-d') . '.pdf');//UldisN + $pdf->__destruct(); //UldisN +} +?> Added: trunk/includes/OutputSerialItems.php =================================================================== --- trunk/includes/OutputSerialItems.php (rev 0) +++ trunk/includes/OutputSerialItems.php 2011-03-03 09:14:45 UTC (rev 4502) @@ -0,0 +1,210 @@ +<?php +/* $Id$*/ +/*Input Serial Items - used for inputing serial numbers or batch/roll/bundle references +for controlled items - used in: +- ConfirmDispatchControlledInvoice.php +- GoodsReceivedControlled.php +- StockAdjustments.php +- StockTransfers.php +- CreditItemsControlled.php + +*/ + +//we start with a batch or serial no header and need to display something for verification... +global $tableheader; + +include ('includes/Add_SerialItemsOut.php'); + +global $tableheader; +/* Link to clear the list and start from scratch */ +$EditLink = '<br><div class="centre"><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&EditControlled=true&StockID=' . $LineItem->StockID . + '&LineNo=' . $LineNo .'">'. _('Edit'). '</a> | '; +$RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&DELETEALL=YES&StockID=' . $LineItem->StockID . + '&LineNo=' . $LineNo .'">'. _('Remove All'). '</a><br></div>'; +$sql="SELECT perishable + FROM stockmaster + WHERE stockid='".$StockID."'"; +$result=DB_query($sql, $db); +$myrow=DB_fetch_array($result); +$Perishable=$myrow['perishable']; +if ($LineItem->Serialised==1){ + $tableheader .= '<tr> + <th>'. _('Serial No').'</th> + </tr>'; + $listtableheader=$tableheader; +} else if ($LineItem->Serialised==0 and $Perishable==1){ + $tableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Available'). '</th> + <th>'. _('Quantity'). '</th> + <th>'. _('Expiry Date'). '</th> + </tr>'; + $listtableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Quantity'). '</th> + <th>'. _('Expiry Date'). '</th> + </tr>'; +} else { + $tableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Quantity'). '</th> + </tr>'; + $listtableheader=$tableheader; +} + +echo $EditLink . $RemoveLink; + +if (isset($_GET['LineNo'])){ + $LineNo = $_GET['LineNo']; +} elseif (isset($_POST['LineNo'])){ + $LineNo = $_POST['LineNo']; +} + +/*Display the batches already entered with quantities if not serialised */ + +echo '<table class=selection><tr><td valign=top><table class=selection>'; +echo $listtableheader; + +$TotalQuantity = 0; /*Variable to accumulate total quantity received */ +$RowCounter =0; + +$k=0; +foreach ($LineItem->SerialItems as $Bundle){ + + if ($RowCounter == 10){ + echo $listtableheader; + $RowCounter =0; + } else { + $RowCounter++; + } + + if ($k==1){ + echo '<tr bgcolor="#CCCCCC">'; + $k=0; + } else { + echo '<tr bgcolor="#EEEEEE">'; + $k=1; + } + + echo '<td>' . $Bundle->BundleRef . '</td>'; + + if ($LineItem->Serialised==0 and $Perishable==0){ + echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + } else if ($LineItem->Serialised==0 and $Perishable==1){ + echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + echo '<td class=number>' . $Bundle->ExpiryDate . '</td>'; + } + + echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . 'Delete=' . $Bundle->BundleRef . '&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Delete'). '</a></td></tr>'; + + $TotalQuantity += $Bundle->BundleQty; +} + + +/*Display the totals and rule off before allowing new entries */ +if ($LineItem->Serialised==1){ + echo '<tr><td class=number><B>'. _('Total Quantity'). ': ' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; +} else { + echo '<tr><td class=number><B>'. _('Total Quantity'). ':</b></td><td class=number><b>' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; +} + +/*Close off old table */ +echo '</table></td><td valign=top>'; + +/*Start a new table for the Serial/Batch ref input in one column (as a sub table +then the multi select box for selection of existing bundle/serial nos for dispatch if applicable*/ +//echo '<TABLE><TR><TD valign=TOP>'; + +/*in the first column add a table for the input of newies */ +echo '<table class=selection>'; +echo $tableheader; + + +echo '<form action="' . $_SERVER['PHP_SELF'] . '?=' . SID . '" name="Ga6uF5Wa" method="post"> + <input type=hidden name=LineNo value="' . $LineNo . '"> + <input type=hidden name=StockID value="' . $StockID . '"> + <input type=hidden name=EntryType value="KEYED">'; +echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; +if ( isset($_GET['EditControlled']) ) { + $EditControlled = isset($_GET['EditControlled'])?$_GET['EditControlled']:false; +} elseif ( isset($_POST['EditControlled']) ){ + $EditControlled = isset($_POST['EditControlled'])?$_POST['EditControlled']:false; +} else { + $EditControlled=false; +} +$TotalQuantity = 0; /*Variable to accumulate total quantity received */ +$RowCounter =0; + +$k=0; + +$StartAddingAt = 0; +if ($EditControlled){ + foreach ($LineItem->SerialItems as $Bundle){ + + echo '<tr><td valign=top><input type=text name="SerialNo'. $StartAddingAt .'" + value="'.$Bundle->BundleRef.'" size=21 maxlength=20></td>'; + + /*if the item is controlled not serialised - batch quantity required so just enter bundle refs + into the form for entry of quantities manually */ + + if ($LineItem->Serialised==1){ + echo '<input type=hidden name="Qty' . $StartAddingAt .'" Value=1></TR>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 + value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; + } else { + echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 + value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; + } + + $StartAddingAt++; + } +} + +$sql="SELECT serialno, + quantity, + expirationdate + FROM stockserialitems + WHERE stockid='".$StockID."' + AND loccode='".$_SESSION['Items']->Location."'"; +$result=DB_query($sql, $db); + +$RowNumber=0; +while ($myrow=DB_fetch_array($result)){ + + echo '<tr><td valign=top>'.$myrow['serialno'].'<input type=hidden name="SerialNo'. ($RowNumber) .'" size=21 value="'.$myrow['serialno'].'" maxlength=20></td>'; + + /*if the item is controlled not serialised - batch quantity required so just enter bundle refs + into the form for entry of quantities manually */ + + if ($LineItem->Serialised==1){ + echo '<input type=hidden name="Qty' . ($StartAddingAt+$RowNumber) .'" Value=1></tr>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + if (isset($LineItem->SerialItems[$myrow['serialno']])) { + echo '<td class=number>'.number_format($myrow['quantity']-$LineItem->SerialItems[$myrow['serialno']]->BundleQty,$LineItem->DecimalPlaces).'</td>'; + } else { + echo '<td class=number>'.number_format($myrow['quantity'],$LineItem->DecimalPlaces).'</td>'; + } + echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$RowNumber) .'" size=11 value="0" maxlength=10></td>'; + echo '<td><input type=hidden class="date" name="ExpiryDate' . ($StartAddingAt+$RowNumber) .'" size=11 + value="'.ConvertSQLDate($myrow['expirationdate']).'" alt="'.$_SESSION['DefaultDateFormat'].'" maxlength=10>'.ConvertSQLDate($myrow['expirationdate']).'</td></tr>'; + } else { + echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$RowNumber) .'" size=11 value="'.$myrow['quantity'].'" maxlength=10></tr>'; + } + $RowNumber++; +} + +echo '</table>'; +echo '<br><div class=centre><input type=submit name="AddBatches" value="'. _('Enter'). '"></div>'; +echo '</form></td><td valign=top>'; +$ShowExisting=True; +$_POST['EntryType']='Sequential'; +if ($ShowExisting){ + include('includes/InputSerialItemsExisting.php'); +} +echo '</td></tr></table><script type="text/javascript"> +//<![CDATA[ +document.Ga6uF5Wa.SerialNo0.focus(); +//]]> +</script>'; /*end of nested table */ +?> \ No newline at end of file Added: trunk/includes/PDFQuotationPortraitPageHeader.inc =================================================================== --- trunk/includes/PDFQuotationPortraitPageHeader.inc (rev 0) +++ trunk/includes/PDFQuotationPortraitPageHeader.inc 2011-03-03 09:14:45 UTC (rev 4502) @@ -0,0 +1,136 @@ +<?php +/* $Id: PDFQuotationPortrait.php 4491 2011-02-15 06:31:08Z daintree $ */ + +if ($PageNumber>1){ + $pdf->newPage(); +} + +$XPos = $Page_Width/2 - 140; +$pdf->addJpegFromFile($_SESSION['LogoFile'],$XPos+90,720,0,60); + +$XPos = $XPos + 130; + +$FontSize=18; +$pdf->addText($XPos,820,$FontSize, _('Quotation')); +$FontSize=12; +$YPos = 720; +$pdf->addText($XPos, $YPos,$FontSize, $_SESSION['CompanyRecord']['coyname']); +$FontSize =10; +$pdf->addText($XPos, $YPos-12,$FontSize, $_SESSION['CompanyRecord']['regoffice1']); +$pdf->addText($XPos, $YPos-21,$FontSize, $_SESSION['CompanyRecord']['regoffice2']); +$pdf->addText($XPos, $YPos-30,$FontSize, $_SESSION['CompanyRecord']['regoffice3'] . ' ' . $_SESSION['CompanyRecord']['regoffice4'] . ' ' . $_SESSION['CompanyRecord']['regoffice5']); +$pdf->addText($XPos, $YPos-39,$FontSize, _('Ph') . ': ' . $_SESSION['CompanyRecord']['telephone'] . ' ' . _('Fax'). ': ' . $_SESSION['CompanyRecord']['fax']); +$pdf->addText($XPos, $YPos-48,$FontSize, $_SESSION['CompanyRecord']['email']); + + +$XPos = 46; +$YPos = 770; + +$FontSize=12; +$pdf->addText($XPos, $YPos+10,$FontSize, _('Delivery To').':' ); +$pdf->addText($XPos, $YPos- 3,$FontSize, $myrow['deliverto']); +$pdf->addText($XPos, $YPos-15,$FontSize, $myrow['deladd1']); +$pdf->addText($XPos, $YPos-30,$FontSize, $myrow['deladd2']); +$pdf->addText($XPos, $YPos-45,$FontSize, $myrow['deladd3'] . ' ' . $myrow['deladd4'] . ' ' . $myrow['deladd5']); + +$YPos -= 80; + +$pdf->addText($XPos, $YPos,$FontSize, _('Quotation For').':'); +$pdf->addText($XPos, $YPos-15,$FontSize, $myrow['name']); +$pdf->addText($XPos, $YPos-30,$FontSize, $myrow['address1']); +$pdf->addText($XPos, $YPos-45,$FontSize, $myrow['address2']); +$pdf->addText($XPos, $YPos-60,$FontSize, $myrow['address3'] . ' ' . $myrow['address4'] . ' ' . $myrow['address5']); + + +$XPos= 50; +$YPos += 25; +/*draw a nice curved corner box around the delivery details */ +/*from the top right */ +$pdf->partEllipse($XPos+200,$YPos+60,0,90,10,10); +/*line to the top left */ +$pdf->line($XPos+200, $YPos+70,$XPos, $YPos+70); +/*Dow top left corner */ +$pdf->partEllipse($XPos, $YPos+60,90,180,10,10); +/*Do a line to the bottom left corner */ +$pdf->line($XPos-10, $YPos+60,$XPos-10, $YPos); +/*Now do the bottom left corner 180 - 270 coming back west*/ +$pdf->partEllipse($XPos, $YPos,180,270,10,10); +/*Now a line to the bottom right */ +$pdf->line($XPos, $YPos-10,$XPos+200, $YPos-10); +/*Now do the bottom right corner */ +$pdf->partEllipse($XPos+200, $YPos,270,360,10,10); +/*Finally join up to the top right corner where started */ +$pdf->line($XPos+210, $YPos,$XPos+210, $YPos+60); + + +$YPos -= 90; +/*draw a nice curved corner box around the billing details */ +/*from the top right */ +$pdf->partEllipse($XPos+200,$YPos+60,0,90,10,10); +/*line to the top left */ +$pdf->line($XPos+200, $YPos+70,$XPos, $YPos+70); +/*Dow top left corner */ +$pdf->partEllipse($XPos, $YPos+60,90,180,10,10); +/*Do a line to the bottom left corner */ +$pdf->line($XPos-10, $YPos+60,$XPos-10, $YPos); +/*Now do the bottom left corner 180 - 270 coming back west*/ +$pdf->partEllipse($XPos, $YPos,180,270,10,10); +/*Now a line to the bottom right */ +$pdf->line($XPos, $YPos-10,$XPos+200, $YPos-10); +/*Now do the bottom right corner */ +$pdf->partEllipse($XPos+200, $YPos,270,360,10,10); +/*Finally join up to the top right corner where started */ +$pdf->line($XPos+210, $YPos,$XPos+210, $YPos+60); + + +$pdf->addText(490, 790,$FontSize, _('Number'). ':'); +$pdf->addText(535, 790,$FontSize, $_GET['QuotationNo']); +$pdf->addText(490, 790-15,$FontSize, _('Your Ref'). ':'); +$pdf->addText(520, 790-15,$FontSize, $myrow['customerref']); +$pdf->addText(490, 790-30,$FontSize, _('Date'). ':'); +$pdf->addText(520, 790-30,$FontSize, ConvertSQLDate($myrow['orddate'])); +$pdf->addText(490, 790-45,$FontSize, _('Page'). ':'); +$pdf->addText(520, 790-45,$FontSize, $PageNumber); + +$YPos -= 45; +$XPos = 40; + +$FontSize=10; +$LeftOvers = $pdf->addTextWrap($XPos+2,$YPos,100,$FontSize, _('Item Code'),'left'); +$LeftOvers = $pdf->addTextWrap(120,$YPos,235,$FontSize, _('Item Description'),'left'); +$LeftOvers = $pdf->addTextWrap(180,$YPos,85,$FontSize, _('Quantity'),'right'); +$LeftOvers = $pdf->addTextWrap(230,$YPos,85,$FontSize,_('Price'),'right'); +$LeftOvers = $pdf->addTextWrap(280,$YPos,85,$FontSize, _('Discount'),'right'); +$LeftOvers = $pdf->addTextWrap(330,$YPos,85,$FontSize, _('Tax Class'),'right'); +$LeftOvers = $pdf->addTextWrap(400,$YPos,85,$FontSize, _('Tax Amount'),'right'); +$LeftOvers = $pdf->addTextWrap(450,$YPos,90,$FontSize, _('Total'),'right'); + + +/*draw a box with nice round corner for entering line items */ +/*90 degree arc at top right of box 0 degrees starts a bottom */ +$pdf->partEllipse($Page_Width-$Right_Margin-0, $Bottom_Margin+560,0,90,10,10); +/*line to the top left */ +$pdf->line($Page_Width-$Right_Margin-0, $Bottom_Margin+570,$Left_Margin+10, $Bottom_Margin+570); + +/*line under headings to top left */ +$pdf->line($Page_Width-$Right_Margin+10, $Bottom_Margin+538,$Left_Margin, $Bottom_Margin+538); + + +/*Dow top left corner */ +$pdf->partEllipse($Left_Margin+10, $Bottom_Margin+560,90,180,10,10); +/*Do a line to the bottom left corner */ +$pdf->line($Left_Margin, $Bottom_Margin+560,$Left_Margin, $Bottom_Margin+10); +/*Now do the bottom left corner 180 - 270 coming back west*/ +$pdf->partEllipse($Left_Margin+10, $Bottom_Margin+10,180,270,10,10); +/*Now a line to the bottom right */ +$pdf->line($Left_Margin+10, $Bottom_Margin,$Page_Width-$Right_Margin-0, $Bottom_Margin); +/*Now do the bottom right corner */ +$pdf->partEllipse($Page_Width-$Right_Margin-0, $Bottom_Margin+10,270,360,10,10); +/*Finally join up to the top right corner where started */ +$pdf->line($Page_Width-$Right_Margin+10, $Bottom_Margin+10,$Page_Width-$Right_Margin+10, $Bottom_Margin+560); + +$YPos -= $line_height; + +$FontSize =12; + +?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-03 09:14:52
|
Revision: 4502 http://web-erp.svn.sourceforge.net/web-erp/?rev=4502&view=rev Author: daintree Date: 2011-03-03 09:14:45 +0000 (Thu, 03 Mar 2011) Log Message: ----------- New Portrait quotation OutputSerialItems Added Paths: ----------- trunk/PDFQuotationPortrait.php trunk/includes/OutputSerialItems.php trunk/includes/PDFQuotationPortraitPageHeader.inc Added: trunk/PDFQuotationPortrait.php =================================================================== --- trunk/PDFQuotationPortrait.php (rev 0) +++ trunk/PDFQuotationPortrait.php 2011-03-03 09:14:45 UTC (rev 4502) @@ -0,0 +1,252 @@ +<?php + +/* $Id: PDFQuotationPortrait.php 4491 2011-02-15 06:31:08Z daintree $ */ + + +include('includes/session.inc'); +include('includes/SQL_CommonFunctions.inc'); + +//Get Out if we have no order number to work with +If (!isset($_GET['QuotationNo']) || $_GET['QuotationNo']==""){ + $title = _('Select Quotation To Print'); + include('includes/header.inc'); + echo '<div class="centre"><br><br><br>'; + prnMsg( _('Select a Quotation to Print before calling this page') , 'error'); + echo '<br><br><br><table class="table_index"><tr><td class="menu_group_item"> + <li><a href="'. $rootpath . '/SelectSalesOrder.php?'. SID .'&Quotations=Quotes_Only">' . _('Quotations') . '</a></li> + </td></tr></table></div><br><br><br>'; + include('includes/footer.inc'); + exit(); +} + +/*retrieve the order details from the database to print */ +$ErrMsg = _('There was a problem retrieving the quotation header details for Order Number') . ' ' . $_GET['QuotationNo'] . ' ' . _('from the database'); + +$sql = "SELECT salesorders.customerref, + salesorders.comments, + salesorders.orddate, + salesorders.deliverto, + salesorders.deladd1, + salesorders.deladd2, + salesorders.deladd3, + salesorders.deladd4, + salesorders.deladd5, + salesorders.deladd6, + debtorsmaster.name, + debtorsmaster.address1, + debtorsmaster.address2, + debtorsmaster.address3, + debtorsmaster.address4, + debtorsmaster.address5, + debtorsmaster.address6, + shippers.shippername, + salesorders.printedpackingslip, + salesorders.datepackingslipprinted, + salesorders.branchcode, + locations.taxprovinceid, + locations.locationname + FROM salesorders, + debtorsmaster, + shippers, + locations + WHERE salesorders.debtorno=debtorsmaster.debtorno + AND salesorders.shipvia=shippers.shipper_id + AND salesorders.fromstkloc=locations.loccode + AND salesorders.quotation=1 + AND salesorders.orderno='" . $_GET['QuotationNo'] ."'"; + +$result=DB_query($sql,$db, $ErrMsg); + +//If there are no rows, there's a problem. +if (DB_num_rows($result)==0){ + $title = _('Print Quotation Error'); + include('includes/header.inc'); + echo '<div class="centre"><br><br><br>'; + prnMsg( _('Unable to Locate Quotation Number') . ' : ' . $_GET['QuotationNo'] . ' ', 'error'); + echo '<br><br><br><table class="table_index"><tr><td class="menu_group_item"> + <li><a href="'. $rootpath . '/SelectSalesOrder.php?'. SID .'&Quotations=Quotes_Only">' . _('Outstanding Quotations') . '</a></li> + </td></tr></table></div><br><br><br>'; + include('includes/footer.inc'); + exit; +} elseif (DB_num_rows($result)==1){ /*There is only one order header returned - thats good! */ + + $myrow = DB_fetch_array($result); +} + +/*retrieve the order details from the database to print */ + +/* Then there's an order to print and its not been printed already (or its been flagged for reprinting/ge_Width=807; +) +LETS GO */ +$PaperSize = 'A4'; +include('includes/PDFStarter.php'); +$pdf->addInfo('Title', _('Customer Quotation') ); +$pdf->addInfo('Subject', _('Quotation') . ' ' . $_GET['QuotationNo']); +$FontSize=12; +$PageNumber = 1; +$line_height=24; +// $pdf->selectFont('./fonts/Helvetica.afm'); + +/* Now ... Has the order got any line items still outstanding to be invoiced */ + +$ErrMsg = _('There was a problem retrieving the quotation line details for quotation Number') . ' ' . + $_GET['QuotationNo'] . ' ' . _('from the database'); + +$sql = "SELECT salesorderdetails.stkcode, + stockmaster.description, + salesorderdetails.quantity, + salesorderdetails.qtyinvoiced, + salesorderdetails.unitprice, + salesorderdetails.discountpercent, + stockmaster.taxcatid, + salesorderdetails.narrative + FROM salesorderdetails INNER JOIN stockmaster + ON salesorderdetails.stkcode=stockmaster.stockid + WHERE salesorderdetails.orderno='" . $_GET['QuotationNo'] . "'"; + +$result=DB_query($sql,$db, $ErrMsg); + +$ListCount = 0; // UldisN + +if (DB_num_rows($result)>0){ + /*Yes there are line items to start the ball rolling with a page header */ + include('includes/PDFQuotationPortraitPageHeader.inc'); + + $QuotationTotal =0; + $QuotationTotalEx=0; + $TaxTotal=0; + + while ($myrow2=DB_fetch_array($result)){ + + $ListCount ++; + + if ((strlen($myrow2['narrative']) >200 AND $YPos-$line_height <= 75) + OR (strlen($myrow2['narrative']) >1 AND $YPos-$line_height <= 62) + OR $YPos-$line_height <= 50){ + /* We reached the end of the page so finsih off the page and start a newy */ + $PageNumber++; + include ('includes/PDFQuotationPageHeader.inc'); + + } //end if need a new page headed up + + $DisplayQty = number_format($myrow2['quantity'],2); + $DisplayPrevDel = number_format($myrow2['qtyinvoiced'],2); + $DisplayPrice = number_format($myrow2['unitprice'],2); + $DisplayDiscount = number_format($myrow2['discountpercent']*100,2) . '%'; + $SubTot = $myrow2['unitprice']*$myrow2['quantity']*(1-$myrow2['discountpercent']); + $TaxProv = $myrow['taxprovinceid']; + $TaxCat = $myrow2['taxcatid']; + $Branch = $myrow['branchcode']; + $sql3 = " select taxgrouptaxes.taxauthid from taxgrouptaxes INNER JOIN custbranch ON taxgrouptaxes.taxgroupid=custbranch.taxgroupid WHERE custbranch.branchcode='" .$Branch ."'"; + $result3=DB_query($sql3,$db, $ErrMsg); + while ($myrow3=DB_fetch_array($result3)){ + $TaxAuth = $myrow3['taxauthid']; + } + + $sql4 = "SELECT * FROM taxauthrates WHERE dispatchtaxprovince='" .$TaxProv ."' AND taxcatid='" .$TaxCat ."' AND taxauthority='" .$TaxAuth ."'"; + $result4=DB_query($sql4,$db, $ErrMsg); + while ($myrow4=DB_fetch_array($result4)){ + $TaxClass = 100 * $myrow4['taxrate']; + } + + $DisplayTaxClass = $TaxClass . "%"; + $TaxAmount = (($SubTot/100)*(100+$TaxClass))-$SubTot; + $DisplayTaxAmount = number_format($TaxAmount,2); + + $LineTotal = $SubTot + $TaxAmount; + $DisplayTotal = number_format($LineTotal,2); + + $FontSize=10; + + $LeftOvers = $pdf->addTextWrap($XPos+1,$YPos,100,$FontSize,$myrow2['stkcode']); + $LeftOvers = $pdf->addTextWrap(120,$YPos,295,$FontSize,$myrow2['description']); + $LeftOvers = $pdf->addTextWrap(180,$YPos,85,$FontSize,$DisplayQty,'right'); + $LeftOvers = $pdf->addTextWrap(230,$YPos,85,$FontSize,$DisplayPrice,'right'); + if ($DisplayDiscount > 0){ + $LeftOvers = $pdf->addTextWrap(280,$YPos,85,$FontSize,$DisplayDiscount,'right'); + } + $LeftOvers = $pdf->addTextWrap(330,$YPos,85,$FontSize,$DisplayTaxClass,'right'); + $LeftOvers = $pdf->addTextWrap(410,$YPos,85,$FontSize,$DisplayTaxAmount,'center'); + $LeftOvers = $pdf->addTextWrap(460,$YPos,90,$FontSize,$DisplayTotal,'right'); + if (strlen($myrow2['narrative'])>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos+1,$YPos,750,10,$myrow2['narrative']); + if (strlen($LeftOvers>1)){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos+1,$YPos,750,10,$LeftOvers); + } + } + $QuotationTotal +=$LineTotal; + $QuotationTotalEx +=$SubTot; + $TaxTotal +=$TaxAmount; + + /*increment a line down for the next line item */ + $YPos -= ($line_height); + + } //end while there are line items to print out + if ((strlen($myrow['comments']) >200 AND $YPos-$line_height <= 75) + OR (strlen($myrow['comments']) >1 AND $YPos-$line_height <= 62) + OR $YPos-$line_height <= 50){ + /* We reached the end of the page so finsih off the page and start a newy */ + $PageNumber++; + include ('includes/PDFQuotationPageHeader.inc'); + + } //end if need a new page headed up + + $LeftOvers = $pdf->addTextWrap($XPos,$YPos-80,200,10,_('Notes:')); + $LeftOvers = $pdf->addText($XPos,$YPos-95,10,$myrow['comments']); + + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); + if (strlen($LeftOvers)>1){ + $YPos -= 10; + $LeftOvers = $pdf->addTextWrap($XPos,$YPos,10,$FontSize,$LeftOvers); + } + } + } + } + $YPos -= ($line_height); + $LeftOvers = $pdf->addTextWrap(40,$YPos,655,$FontSize,_('Total Tax'),'right'); + $LeftOvers = $pdf->addTextWrap(700,$YPos,90,$FontSize,number_format($TaxTotal,2),'right'); + $YPos -= 12; + $LeftOvers = $pdf->addTextWrap(40,$YPos,655,$FontSize,_('Quotation Excluding Tax'),'right'); + $LeftOvers = $pdf->addTextWrap(700,$YPos,90,$FontSize,number_format($QuotationTotalEx,2),'right'); + $YPos -= 12; + $LeftOvers = $pdf->addTextWrap(40,$YPos,655,$FontSize,_('Quotation Including Tax'),'right'); + $LeftOvers = $pdf->addTextWrap(700,$YPos,90,$FontSize,number_format($QuotationTotal,2),'right'); + +} /*end if there are line details to show on the quotation*/ + + +//$pdfcode = $pdf->output('PDFQuotation.pdf', 'I'); +//$len = strlen($pdfcode); +if ($ListCount == 0){ + $title = _('Print Quotation Error'); + include('includes/header.inc'); + echo '<p>'. _('There were no items on the quotation') . '. ' . _('The quotation cannot be printed'). + '<br><a href="' . $rootpath . '/SelectSalesOrder.php?' . SID . '&Quotation=Quotes_only">'. _('Print Another Quotation'). + '</a>' . '<br>'. '<a href="' . $rootpath . '/index.php?' . SID . '">' . _('Back to the menu') . '</a>'; + include('includes/footer.inc'); + exit; +} else { +/* + header('Content-type: application/pdf'); + header('Content-Length: ' . $len); + header('Content-Disposition: inline; filename=Quotation.pdf'); + header('Expires: 0'); + header('Cache-Control: must-revalidate, post-check=0, pre-check=0'); + header('Pragma: public'); +//echo 'here'; + $pdf->Output('PDFQuotation.pdf', 'I'); +*/ + $pdf->OutputI($_SESSION['DatabaseName'] . '_Quotation_' . date('Y-m-d') . '.pdf');//UldisN + $pdf->__destruct(); //UldisN +} +?> Added: trunk/includes/OutputSerialItems.php =================================================================== --- trunk/includes/OutputSerialItems.php (rev 0) +++ trunk/includes/OutputSerialItems.php 2011-03-03 09:14:45 UTC (rev 4502) @@ -0,0 +1,210 @@ +<?php +/* $Id$*/ +/*Input Serial Items - used for inputing serial numbers or batch/roll/bundle references +for controlled items - used in: +- ConfirmDispatchControlledInvoice.php +- GoodsReceivedControlled.php +- StockAdjustments.php +- StockTransfers.php +- CreditItemsControlled.php + +*/ + +//we start with a batch or serial no header and need to display something for verification... +global $tableheader; + +include ('includes/Add_SerialItemsOut.php'); + +global $tableheader; +/* Link to clear the list and start from scratch */ +$EditLink = '<br><div class="centre"><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&EditControlled=true&StockID=' . $LineItem->StockID . + '&LineNo=' . $LineNo .'">'. _('Edit'). '</a> | '; +$RemoveLink = '<a href="' . $_SERVER['PHP_SELF'] . '?' . SID . '&DELETEALL=YES&StockID=' . $LineItem->StockID . + '&LineNo=' . $LineNo .'">'. _('Remove All'). '</a><br></div>'; +$sql="SELECT perishable + FROM stockmaster + WHERE stockid='".$StockID."'"; +$result=DB_query($sql, $db); +$myrow=DB_fetch_array($result); +$Perishable=$myrow['perishable']; +if ($LineItem->Serialised==1){ + $tableheader .= '<tr> + <th>'. _('Serial No').'</th> + </tr>'; + $listtableheader=$tableheader; +} else if ($LineItem->Serialised==0 and $Perishable==1){ + $tableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Available'). '</th> + <th>'. _('Quantity'). '</th> + <th>'. _('Expiry Date'). '</th> + </tr>'; + $listtableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Quantity'). '</th> + <th>'. _('Expiry Date'). '</th> + </tr>'; +} else { + $tableheader = '<tr> + <th>'. _('Batch/Roll/Bundle'). ' #</th> + <th>'. _('Quantity'). '</th> + </tr>'; + $listtableheader=$tableheader; +} + +echo $EditLink . $RemoveLink; + +if (isset($_GET['LineNo'])){ + $LineNo = $_GET['LineNo']; +} elseif (isset($_POST['LineNo'])){ + $LineNo = $_POST['LineNo']; +} + +/*Display the batches already entered with quantities if not serialised */ + +echo '<table class=selection><tr><td valign=top><table class=selection>'; +echo $listtableheader; + +$TotalQuantity = 0; /*Variable to accumulate total quantity received */ +$RowCounter =0; + +$k=0; +foreach ($LineItem->SerialItems as $Bundle){ + + if ($RowCounter == 10){ + echo $listtableheader; + $RowCounter =0; + } else { + $RowCounter++; + } + + if ($k==1){ + echo '<tr bgcolor="#CCCCCC">'; + $k=0; + } else { + echo '<tr bgcolor="#EEEEEE">'; + $k=1; + } + + echo '<td>' . $Bundle->BundleRef . '</td>'; + + if ($LineItem->Serialised==0 and $Perishable==0){ + echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + } else if ($LineItem->Serialised==0 and $Perishable==1){ + echo '<td class=number>' . number_format($Bundle->BundleQty, $LineItem->DecimalPlaces) . '</td>'; + echo '<td class=number>' . $Bundle->ExpiryDate . '</td>'; + } + + echo '<td><a href="' . $_SERVER['PHP_SELF'] . '?' . SID . 'Delete=' . $Bundle->BundleRef . '&StockID=' . $LineItem->StockID . '&LineNo=' . $LineNo .'">'. _('Delete'). '</a></td></tr>'; + + $TotalQuantity += $Bundle->BundleQty; +} + + +/*Display the totals and rule off before allowing new entries */ +if ($LineItem->Serialised==1){ + echo '<tr><td class=number><B>'. _('Total Quantity'). ': ' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; +} else { + echo '<tr><td class=number><B>'. _('Total Quantity'). ':</b></td><td class=number><b>' . number_format($TotalQuantity,$LineItem->DecimalPlaces) . '</b></td></tr>'; +} + +/*Close off old table */ +echo '</table></td><td valign=top>'; + +/*Start a new table for the Serial/Batch ref input in one column (as a sub table +then the multi select box for selection of existing bundle/serial nos for dispatch if applicable*/ +//echo '<TABLE><TR><TD valign=TOP>'; + +/*in the first column add a table for the input of newies */ +echo '<table class=selection>'; +echo $tableheader; + + +echo '<form action="' . $_SERVER['PHP_SELF'] . '?=' . SID . '" name="Ga6uF5Wa" method="post"> + <input type=hidden name=LineNo value="' . $LineNo . '"> + <input type=hidden name=StockID value="' . $StockID . '"> + <input type=hidden name=EntryType value="KEYED">'; +echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; +if ( isset($_GET['EditControlled']) ) { + $EditControlled = isset($_GET['EditControlled'])?$_GET['EditControlled']:false; +} elseif ( isset($_POST['EditControlled']) ){ + $EditControlled = isset($_POST['EditControlled'])?$_POST['EditControlled']:false; +} else { + $EditControlled=false; +} +$TotalQuantity = 0; /*Variable to accumulate total quantity received */ +$RowCounter =0; + +$k=0; + +$StartAddingAt = 0; +if ($EditControlled){ + foreach ($LineItem->SerialItems as $Bundle){ + + echo '<tr><td valign=top><input type=text name="SerialNo'. $StartAddingAt .'" + value="'.$Bundle->BundleRef.'" size=21 maxlength=20></td>'; + + /*if the item is controlled not serialised - batch quantity required so just enter bundle refs + into the form for entry of quantities manually */ + + if ($LineItem->Serialised==1){ + echo '<input type=hidden name="Qty' . $StartAddingAt .'" Value=1></TR>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 + value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; + } else { + echo '<td><input type=text class="number" name="Qty' . $StartAddingAt .'" size=11 + value="'. number_format($Bundle->BundleQty, $LineItem->DecimalPlaces). '" maxlength=10></tr>'; + } + + $StartAddingAt++; + } +} + +$sql="SELECT serialno, + quantity, + expirationdate + FROM stockserialitems + WHERE stockid='".$StockID."' + AND loccode='".$_SESSION['Items']->Location."'"; +$result=DB_query($sql, $db); + +$RowNumber=0; +while ($myrow=DB_fetch_array($result)){ + + echo '<tr><td valign=top>'.$myrow['serialno'].'<input type=hidden name="SerialNo'. ($RowNumber) .'" size=21 value="'.$myrow['serialno'].'" maxlength=20></td>'; + + /*if the item is controlled not serialised - batch quantity required so just enter bundle refs + into the form for entry of quantities manually */ + + if ($LineItem->Serialised==1){ + echo '<input type=hidden name="Qty' . ($StartAddingAt+$RowNumber) .'" Value=1></tr>'; + } else if ($LineItem->Serialised==0 and $Perishable==1) { + if (isset($LineItem->SerialItems[$myrow['serialno']])) { + echo '<td class=number>'.number_format($myrow['quantity']-$LineItem->SerialItems[$myrow['serialno']]->BundleQty,$LineItem->DecimalPlaces).'</td>'; + } else { + echo '<td class=number>'.number_format($myrow['quantity'],$LineItem->DecimalPlaces).'</td>'; + } + echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$RowNumber) .'" size=11 value="0" maxlength=10></td>'; + echo '<td><input type=hidden class="date" name="ExpiryDate' . ($StartAddingAt+$RowNumber) .'" size=11 + value="'.ConvertSQLDate($myrow['expirationdate']).'" alt="'.$_SESSION['DefaultDateFormat'].'" maxlength=10>'.ConvertSQLDate($myrow['expirationdate']).'</td></tr>'; + } else { + echo '<td><input type=text class="number" name="Qty' . ($StartAddingAt+$RowNumber) .'" size=11 value="'.$myrow['quantity'].'" maxlength=10></tr>'; + } + $RowNumber++; +} + +echo '</table>'; +echo '<br><div class=centre><input type=submit name="AddBatches" value="'. _('Enter'). '"></div>'; +echo '</form></td><td valign=top>'; +$ShowExisting=True; +$_POST['EntryType']='Sequential'; +if ($ShowExisting){ + include('includes/InputSerialItemsExisting.php'); +} +echo '</td></tr></table><script type="text/javascript"> +//<![CDATA[ +document.Ga6uF5Wa.SerialNo0.focus(); +//]]> +</script>'; /*end of nested table */ +?> \ No newline at end of file Added: trunk/includes/PDFQuotationPortraitPageHeader.inc =================================================================== --- trunk/includes/PDFQuotationPortraitPageHeader.inc (rev 0) +++ trunk/includes/PDFQuotationPortraitPageHeader.inc 2011-03-03 09:14:45 UTC (rev 4502) @@ -0,0 +1,136 @@ +<?php +/* $Id: PDFQuotationPortrait.php 4491 2011-02-15 06:31:08Z daintree $ */ + +if ($PageNumber>1){ + $pdf->newPage(); +} + +$XPos = $Page_Width/2 - 140; +$pdf->addJpegFromFile($_SESSION['LogoFile'],$XPos+90,720,0,60); + +$XPos = $XPos + 130; + +$FontSize=18; +$pdf->addText($XPos,820,$FontSize, _('Quotation')); +$FontSize=12; +$YPos = 720; +$pdf->addText($XPos, $YPos,$FontSize, $_SESSION['CompanyRecord']['coyname']); +$FontSize =10; +$pdf->addText($XPos, $YPos-12,$FontSize, $_SESSION['CompanyRecord']['regoffice1']); +$pdf->addText($XPos, $YPos-21,$FontSize, $_SESSION['CompanyRecord']['regoffice2']); +$pdf->addText($XPos, $YPos-30,$FontSize, $_SESSION['CompanyRecord']['regoffice3'] . ' ' . $_SESSION['CompanyRecord']['regoffice4'] . ' ' . $_SESSION['CompanyRecord']['regoffice5']); +$pdf->addText($XPos, $YPos-39,$FontSize, _('Ph') . ': ' . $_SESSION['CompanyRecord']['telephone'] . ' ' . _('Fax'). ': ' . $_SESSION['CompanyRecord']['fax']); +$pdf->addText($XPos, $YPos-48,$FontSize, $_SESSION['CompanyRecord']['email']); + + +$XPos = 46; +$YPos = 770; + +$FontSize=12; +$pdf->addText($XPos, $YPos+10,$FontSize, _('Delivery To').':' ); +$pdf->addText($XPos, $YPos- 3,$FontSize, $myrow['deliverto']); +$pdf->addText($XPos, $YPos-15,$FontSize, $myrow['deladd1']); +$pdf->addText($XPos, $YPos-30,$FontSize, $myrow['deladd2']); +$pdf->addText($XPos, $YPos-45,$FontSize, $myrow['deladd3'] . ' ' . $myrow['deladd4'] . ' ' . $myrow['deladd5']); + +$YPos -= 80; + +$pdf->addText($XPos, $YPos,$FontSize, _('Quotation For').':'); +$pdf->addText($XPos, $YPos-15,$FontSize, $myrow['name']); +$pdf->addText($XPos, $YPos-30,$FontSize, $myrow['address1']); +$pdf->addText($XPos, $YPos-45,$FontSize, $myrow['address2']); +$pdf->addText($XPos, $YPos-60,$FontSize, $myrow['address3'] . ' ' . $myrow['address4'] . ' ' . $myrow['address5']); + + +$XPos= 50; +$YPos += 25; +/*draw a nice curved corner box around the delivery details */ +/*from the top right */ +$pdf->partEllipse($XPos+200,$YPos+60,0,90,10,10); +/*line to the top left */ +$pdf->line($XPos+200, $YPos+70,$XPos, $YPos+70); +/*Dow top left corner */ +$pdf->partEllipse($XPos, $YPos+60,90,180,10,10); +/*Do a line to the bottom left corner */ +$pdf->line($XPos-10, $YPos+60,$XPos-10, $YPos); +/*Now do the bottom left corner 180 - 270 coming back west*/ +$pdf->partEllipse($XPos, $YPos,180,270,10,10); +/*Now a line to the bottom right */ +$pdf->line($XPos, $YPos-10,$XPos+200, $YPos-10); +/*Now do the bottom right corner */ +$pdf->partEllipse($XPos+200, $YPos,270,360,10,10); +/*Finally join up to the top right corner where started */ +$pdf->line($XPos+210, $YPos,$XPos+210, $YPos+60); + + +$YPos -= 90; +/*draw a nice curved corner box around the billing details */ +/*from the top right */ +$pdf->partEllipse($XPos+200,$YPos+60,0,90,10,10); +/*line to the top left */ +$pdf->line($XPos+200, $YPos+70,$XPos, $YPos+70); +/*Dow top left corner */ +$pdf->partEllipse($XPos, $YPos+60,90,180,10,10); +/*Do a line to the bottom left corner */ +$pdf->line($XPos-10, $YPos+60,$XPos-10, $YPos); +/*Now do the bottom left corner 180 - 270 coming back west*/ +$pdf->partEllipse($XPos, $YPos,180,270,10,10); +/*Now a line to the bottom right */ +$pdf->line($XPos, $YPos-10,$XPos+200, $YPos-10); +/*Now do the bottom right corner */ +$pdf->partEllipse($XPos+200, $YPos,270,360,10,10); +/*Finally join up to the top right corner where started */ +$pdf->line($XPos+210, $YPos,$XPos+210, $YPos+60); + + +$pdf->addText(490, 790,$FontSize, _('Number'). ':'); +$pdf->addText(535, 790,$FontSize, $_GET['QuotationNo']); +$pdf->addText(490, 790-15,$FontSize, _('Your Ref'). ':'); +$pdf->addText(520, 790-15,$FontSize, $myrow['customerref']); +$pdf->addText(490, 790-30,$FontSize, _('Date'). ':'); +$pdf->addText(520, 790-30,$FontSize, ConvertSQLDate($myrow['orddate'])); +$pdf->addText(490, 790-45,$FontSize, _('Page'). ':'); +$pdf->addText(520, 790-45,$FontSize, $PageNumber); + +$YPos -= 45; +$XPos = 40; + +$FontSize=10; +$LeftOvers = $pdf->addTextWrap($XPos+2,$YPos,100,$FontSize, _('Item Code'),'left'); +$LeftOvers = $pdf->addTextWrap(120,$YPos,235,$FontSize, _('Item Description'),'left'); +$LeftOvers = $pdf->addTextWrap(180,$YPos,85,$FontSize, _('Quantity'),'right'); +$LeftOvers = $pdf->addTextWrap(230,$YPos,85,$FontSize,_('Price'),'right'); +$LeftOvers = $pdf->addTextWrap(280,$YPos,85,$FontSize, _('Discount'),'right'); +$LeftOvers = $pdf->addTextWrap(330,$YPos,85,$FontSize, _('Tax Class'),'right'); +$LeftOvers = $pdf->addTextWrap(400,$YPos,85,$FontSize, _('Tax Amount'),'right'); +$LeftOvers = $pdf->addTextWrap(450,$YPos,90,$FontSize, _('Total'),'right'); + + +/*draw a box with nice round corner for entering line items */ +/*90 degree arc at top right of box 0 degrees starts a bottom */ +$pdf->partEllipse($Page_Width-$Right_Margin-0, $Bottom_Margin+560,0,90,10,10); +/*line to the top left */ +$pdf->line($Page_Width-$Right_Margin-0, $Bottom_Margin+570,$Left_Margin+10, $Bottom_Margin+570); + +/*line under headings to top left */ +$pdf->line($Page_Width-$Right_Margin+10, $Bottom_Margin+538,$Left_Margin, $Bottom_Margin+538); + + +/*Dow top left corner */ +$pdf->partEllipse($Left_Margin+10, $Bottom_Margin+560,90,180,10,10); +/*Do a line to the bottom left corner */ +$pdf->line($Left_Margin, $Bottom_Margin+560,$Left_Margin, $Bottom_Margin+10); +/*Now do the bottom left corner 180 - 270 coming back west*/ +$pdf->partEllipse($Left_Margin+10, $Bottom_Margin+10,180,270,10,10); +/*Now a line to the bottom right */ +$pdf->line($Left_Margin+10, $Bottom_Margin,$Page_Width-$Right_Margin-0, $Bottom_Margin); +/*Now do the bottom right corner */ +$pdf->partEllipse($Page_Width-$Right_Margin-0, $Bottom_Margin+10,270,360,10,10); +/*Finally join up to the top right corner where started */ +$pdf->line($Page_Width-$Right_Margin+10, $Bottom_Margin+10,$Page_Width-$Right_Margin+10, $Bottom_Margin+560); + +$YPos -= $line_height; + +$FontSize =12; + +?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-04 19:40:53
|
Revision: 4503 http://web-erp.svn.sourceforge.net/web-erp/?rev=4503&view=rev Author: daintree Date: 2011-03-04 19:40:47 +0000 (Fri, 04 Mar 2011) Log Message: ----------- Kovacs Attila fixes GROUP BY clauses in SQL and laguage binding always UTF-8 Modified Paths: -------------- trunk/Stocks.php trunk/doc/Change.log.html trunk/includes/LanguageSetup.php Modified: trunk/Stocks.php =================================================================== --- trunk/Stocks.php 2011-03-03 09:14:45 UTC (rev 4502) +++ trunk/Stocks.php 2011-03-04 19:40:47 UTC (rev 4503) @@ -2,8 +2,6 @@ /* $Id$ */ -//$PageSecurity = 11; - include('includes/session.inc'); $title = _('Item Maintenance'); include('includes/header.inc'); @@ -19,7 +17,7 @@ } if (isset($StockID) and !isset($_POST['UpdateCategories'])) { - $sql = "SELECT COUNT(stockid) FROM stockmaster WHERE stockid='".$StockID."'"; + $sql = "SELECT COUNT(stockid) FROM stockmaster WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]==0) { @@ -48,7 +46,7 @@ } elseif ( $_FILES['ItemPicture']['size'] > ($_SESSION['MaxImageSize']*1024)) { //File Size Check prnMsg(_('The file size is over the maximum allowed. The maximum size allowed in KB is') . ' ' . $_SESSION['MaxImageSize'],'warn'); $UploadTheFile ='No'; - } elseif ( $_FILES['ItemPicture']['type'] == "text/plain" ) { //File Type Check + } elseif ( $_FILES['ItemPicture']['type'] == 'text/plain' ) { //File Type Check prnMsg( _('Only graphics files can be uploaded'),'warn'); $UploadTheFile ='No'; } elseif (file_exists($filename)){ @@ -219,7 +217,7 @@ $OldControlled = $myrow[1]; $OldSerialised = $myrow[2]; - $sql = "SELECT SUM(locstock.quantity) FROM locstock WHERE stockid='".$StockID."'"; + $sql = "SELECT SUM(locstock.quantity) FROM locstock WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $stkqtychk = DB_fetch_row($result); @@ -268,7 +266,7 @@ /*now check that if it was a Manufactured, Kitset, Phantom or Assembly and is being changed to a purchased or dummy - that no BOM exists */ if (($OldMBFlag=='M' OR $OldMBFlag =='K' OR $OldMBFlag=='A' OR $OldMBFlag=='G') AND ($_POST['MBFlag']=='B' OR $_POST['MBFlag']=='D')) { - $sql = "SELECT COUNT(*) FROM bom WHERE parent = '".$StockID."'"; + $sql = "SELECT COUNT(*) FROM bom WHERE parent = '".$StockID."' GROUP BY parent"; $result = DB_query($sql,$db); $ChkBOM = DB_fetch_row($result); if ($ChkBOM[0]!=0){ @@ -279,7 +277,7 @@ /*now check that if it was Manufac, Phantom or Purchased and is being changed to assembly or kitset, it is not a component on an existing BOM */ if (($OldMBFlag=='M' OR $OldMBFlag =='B' OR $OldMBFlag=='D' OR $OldMBFlag=='G') AND ($_POST['MBFlag']=='A' OR $_POST['MBFlag']=='K')) { - $sql = "SELECT COUNT(*) FROM bom WHERE component = '".$StockID."'"; + $sql = "SELECT COUNT(*) FROM bom WHERE component = '".$StockID."' GROUP BY component"; $result = DB_query($sql,$db); $ChkBOM = DB_fetch_row($result); if ($ChkBOM[0]!=0){ @@ -462,7 +460,7 @@ // PREVENT DELETES IF DEPENDENT RECORDS IN 'StockMoves' - $sql= "SELECT COUNT(*) FROM stockmoves WHERE stockid='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM stockmoves WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -471,7 +469,7 @@ echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('stock movements that refer to this item'); } else { - $sql= "SELECT COUNT(*) FROM bom WHERE component='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM bom WHERE component='".$StockID."' GROUP BY component"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -479,7 +477,7 @@ prnMsg( _('Cannot delete this item record because there are bills of material that require this part as a component'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('bills of material that require this part as a component'); } else { - $sql= "SELECT COUNT(*) FROM salesorderdetails WHERE stkcode='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM salesorderdetails WHERE stkcode='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -487,7 +485,7 @@ prnMsg( _('Cannot delete this item record because there are existing sales orders for this part'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('sales order items against this part'); } else { - $sql= "SELECT COUNT(*) FROM salesanalysis WHERE stockid='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM salesanalysis WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -495,7 +493,7 @@ prnMsg(_('Cannot delete this item because sales analysis records exist for it'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('sales analysis records against this part'); } else { - $sql= "SELECT COUNT(*) FROM purchorderdetails WHERE itemcode='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM purchorderdetails WHERE itemcode='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -503,7 +501,7 @@ prnMsg(_('Cannot delete this item because there are existing purchase order items for it'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('purchase order item record relating to this part'); } else { - $sql = "SELECT SUM(quantity) AS qoh FROM locstock WHERE stockid='".$StockID."'"; + $sql = "SELECT SUM(quantity) AS qoh FROM locstock WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]!=0) { Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-03-03 09:14:45 UTC (rev 4502) +++ trunk/doc/Change.log.html 2011-03-04 19:40:47 UTC (rev 4503) @@ -1,5 +1,7 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>5/3/11: Kovács Attila fix to Stocks.php to use ANSI GROUP BY for aggregate functions SQL</p> +<p>5/3/11: Kovács Attila fix to LanguageSetup.php to use utf-8 not ISO-8859-1. Phil hardcoded UTF- now as no dynamic changing of character set required all translations are utf-8</p> <p>3/3/11: Exson/Baran/Phil fix to customer login to ensure that other customers orders are not displayed when searching by customer ref or order no</p> <p>3/3/11: Tim launchpad mods to revision 4441 including change to allow supplier currency to be changed if there are no transactions already against the supplier. Ensure credit note session variable is unset before attempting to create a new credit note from the supplier form. Tim's work to add perisable expiry dates to the serial items logic - affects quite a few scripts. Headings to stock check script even if no quantity is shown. Portrait quotations. Not included change to default delivery date to the date the customer requested - left to be the current day's date. Not included Tim's unit pricing work .. yet launchpad revisions 4442-4447 inclusive</p> <p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php links with matching quotes in WorkOrderEntry</p> Modified: trunk/includes/LanguageSetup.php =================================================================== --- trunk/includes/LanguageSetup.php 2011-03-03 09:14:45 UTC (rev 4502) +++ trunk/includes/LanguageSetup.php 2011-03-04 19:40:47 UTC (rev 4503) @@ -37,7 +37,7 @@ //putenv('LANG=$Language_Country'); bindtextdomain ('messages', $PathPrefix . 'locale'); textdomain ('messages'); - bind_textdomain_codeset('messages', _('ISO-8859-1')); + bind_textdomain_codeset('messages', 'UTF-8'); $locale_info = localeconv(); } else { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-04 19:40:54
|
Revision: 4503 http://web-erp.svn.sourceforge.net/web-erp/?rev=4503&view=rev Author: daintree Date: 2011-03-04 19:40:47 +0000 (Fri, 04 Mar 2011) Log Message: ----------- Kovacs Attila fixes GROUP BY clauses in SQL and laguage binding always UTF-8 Modified Paths: -------------- trunk/Stocks.php trunk/doc/Change.log.html trunk/includes/LanguageSetup.php Modified: trunk/Stocks.php =================================================================== --- trunk/Stocks.php 2011-03-03 09:14:45 UTC (rev 4502) +++ trunk/Stocks.php 2011-03-04 19:40:47 UTC (rev 4503) @@ -2,8 +2,6 @@ /* $Id$ */ -//$PageSecurity = 11; - include('includes/session.inc'); $title = _('Item Maintenance'); include('includes/header.inc'); @@ -19,7 +17,7 @@ } if (isset($StockID) and !isset($_POST['UpdateCategories'])) { - $sql = "SELECT COUNT(stockid) FROM stockmaster WHERE stockid='".$StockID."'"; + $sql = "SELECT COUNT(stockid) FROM stockmaster WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]==0) { @@ -48,7 +46,7 @@ } elseif ( $_FILES['ItemPicture']['size'] > ($_SESSION['MaxImageSize']*1024)) { //File Size Check prnMsg(_('The file size is over the maximum allowed. The maximum size allowed in KB is') . ' ' . $_SESSION['MaxImageSize'],'warn'); $UploadTheFile ='No'; - } elseif ( $_FILES['ItemPicture']['type'] == "text/plain" ) { //File Type Check + } elseif ( $_FILES['ItemPicture']['type'] == 'text/plain' ) { //File Type Check prnMsg( _('Only graphics files can be uploaded'),'warn'); $UploadTheFile ='No'; } elseif (file_exists($filename)){ @@ -219,7 +217,7 @@ $OldControlled = $myrow[1]; $OldSerialised = $myrow[2]; - $sql = "SELECT SUM(locstock.quantity) FROM locstock WHERE stockid='".$StockID."'"; + $sql = "SELECT SUM(locstock.quantity) FROM locstock WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $stkqtychk = DB_fetch_row($result); @@ -268,7 +266,7 @@ /*now check that if it was a Manufactured, Kitset, Phantom or Assembly and is being changed to a purchased or dummy - that no BOM exists */ if (($OldMBFlag=='M' OR $OldMBFlag =='K' OR $OldMBFlag=='A' OR $OldMBFlag=='G') AND ($_POST['MBFlag']=='B' OR $_POST['MBFlag']=='D')) { - $sql = "SELECT COUNT(*) FROM bom WHERE parent = '".$StockID."'"; + $sql = "SELECT COUNT(*) FROM bom WHERE parent = '".$StockID."' GROUP BY parent"; $result = DB_query($sql,$db); $ChkBOM = DB_fetch_row($result); if ($ChkBOM[0]!=0){ @@ -279,7 +277,7 @@ /*now check that if it was Manufac, Phantom or Purchased and is being changed to assembly or kitset, it is not a component on an existing BOM */ if (($OldMBFlag=='M' OR $OldMBFlag =='B' OR $OldMBFlag=='D' OR $OldMBFlag=='G') AND ($_POST['MBFlag']=='A' OR $_POST['MBFlag']=='K')) { - $sql = "SELECT COUNT(*) FROM bom WHERE component = '".$StockID."'"; + $sql = "SELECT COUNT(*) FROM bom WHERE component = '".$StockID."' GROUP BY component"; $result = DB_query($sql,$db); $ChkBOM = DB_fetch_row($result); if ($ChkBOM[0]!=0){ @@ -462,7 +460,7 @@ // PREVENT DELETES IF DEPENDENT RECORDS IN 'StockMoves' - $sql= "SELECT COUNT(*) FROM stockmoves WHERE stockid='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM stockmoves WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -471,7 +469,7 @@ echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('stock movements that refer to this item'); } else { - $sql= "SELECT COUNT(*) FROM bom WHERE component='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM bom WHERE component='".$StockID."' GROUP BY component"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -479,7 +477,7 @@ prnMsg( _('Cannot delete this item record because there are bills of material that require this part as a component'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('bills of material that require this part as a component'); } else { - $sql= "SELECT COUNT(*) FROM salesorderdetails WHERE stkcode='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM salesorderdetails WHERE stkcode='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -487,7 +485,7 @@ prnMsg( _('Cannot delete this item record because there are existing sales orders for this part'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('sales order items against this part'); } else { - $sql= "SELECT COUNT(*) FROM salesanalysis WHERE stockid='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM salesanalysis WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -495,7 +493,7 @@ prnMsg(_('Cannot delete this item because sales analysis records exist for it'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('sales analysis records against this part'); } else { - $sql= "SELECT COUNT(*) FROM purchorderdetails WHERE itemcode='".$StockID."'"; + $sql= "SELECT COUNT(*) FROM purchorderdetails WHERE itemcode='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]>0) { @@ -503,7 +501,7 @@ prnMsg(_('Cannot delete this item because there are existing purchase order items for it'),'warn'); echo '<br>' . _('There are') . ' ' . $myrow[0] . ' ' . _('purchase order item record relating to this part'); } else { - $sql = "SELECT SUM(quantity) AS qoh FROM locstock WHERE stockid='".$StockID."'"; + $sql = "SELECT SUM(quantity) AS qoh FROM locstock WHERE stockid='".$StockID."' GROUP BY stockid"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); if ($myrow[0]!=0) { Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-03-03 09:14:45 UTC (rev 4502) +++ trunk/doc/Change.log.html 2011-03-04 19:40:47 UTC (rev 4503) @@ -1,5 +1,7 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>5/3/11: Kovács Attila fix to Stocks.php to use ANSI GROUP BY for aggregate functions SQL</p> +<p>5/3/11: Kovács Attila fix to LanguageSetup.php to use utf-8 not ISO-8859-1. Phil hardcoded UTF- now as no dynamic changing of character set required all translations are utf-8</p> <p>3/3/11: Exson/Baran/Phil fix to customer login to ensure that other customers orders are not displayed when searching by customer ref or order no</p> <p>3/3/11: Tim launchpad mods to revision 4441 including change to allow supplier currency to be changed if there are no transactions already against the supplier. Ensure credit note session variable is unset before attempting to create a new credit note from the supplier form. Tim's work to add perisable expiry dates to the serial items logic - affects quite a few scripts. Headings to stock check script even if no quantity is shown. Portrait quotations. Not included change to default delivery date to the date the customer requested - left to be the current day's date. Not included Tim's unit pricing work .. yet launchpad revisions 4442-4447 inclusive</p> <p>27/2/11: Phil/Tim/Peter launchpad added category option for MRPShortages.php links with matching quotes in WorkOrderEntry</p> Modified: trunk/includes/LanguageSetup.php =================================================================== --- trunk/includes/LanguageSetup.php 2011-03-03 09:14:45 UTC (rev 4502) +++ trunk/includes/LanguageSetup.php 2011-03-04 19:40:47 UTC (rev 4503) @@ -37,7 +37,7 @@ //putenv('LANG=$Language_Country'); bindtextdomain ('messages', $PathPrefix . 'locale'); textdomain ('messages'); - bind_textdomain_codeset('messages', _('ISO-8859-1')); + bind_textdomain_codeset('messages', 'UTF-8'); $locale_info = localeconv(); } else { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-08 07:38:52
|
Revision: 4504 http://web-erp.svn.sourceforge.net/web-erp/?rev=4504&view=rev Author: daintree Date: 2011-03-08 07:38:45 +0000 (Tue, 08 Mar 2011) Log Message: ----------- Sales Analysis fix Modified Paths: -------------- trunk/SalesAnalysis_UserDefined.php trunk/doc/Change.log.html trunk/includes/PDFSalesAnalysis.inc Modified: trunk/SalesAnalysis_UserDefined.php =================================================================== --- trunk/SalesAnalysis_UserDefined.php 2011-03-04 19:40:47 UTC (rev 4503) +++ trunk/SalesAnalysis_UserDefined.php 2011-03-08 07:38:45 UTC (rev 4504) @@ -2,7 +2,7 @@ /* $Id$ */ -//$PageSecurity = 2; + include('includes/session.inc'); if (!in_array($PageSecurity,$_SESSION['AllowedPageSecurityTokens'])){ @@ -18,9 +18,9 @@ if ($Counter >0) { $pdf->OutputD('SalesAnalysis_' . date('Y-m-d') . '.pdf'); - $pdf-> __destruct(); + $pdf->__destruct(); } else { - $pdf-> __destruct(); + $pdf->__destruct(); $title = _('User Defined Sales Analysis Problem'); include('includes/header.inc'); echo '<p>' . _('The report did not have any none zero lines of information to show and so it has not been created'); @@ -46,5 +46,4 @@ echo '<p>' . _('You should automatically be forwarded to the CSV Sales Analysis file when it is ready') . '. ' . _('If this does not happen') . ' <a href="' . $rootpath . '/' . $_SESSION['reports_dir'] . '/SalesAnalysis.csv">' . _('click here') . '</a> ' . _('to continue') . '<br />'; include('includes/footer.inc'); } - -?> +?> \ No newline at end of file Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-03-04 19:40:47 UTC (rev 4503) +++ trunk/doc/Change.log.html 2011-03-08 07:38:45 UTC (rev 4504) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>8/3/11:Phil fix SalesAnalysis reports for TCPDF as reported by Joe Zhou</p> <p>5/3/11: Kovács Attila fix to Stocks.php to use ANSI GROUP BY for aggregate functions SQL</p> <p>5/3/11: Kovács Attila fix to LanguageSetup.php to use utf-8 not ISO-8859-1. Phil hardcoded UTF- now as no dynamic changing of character set required all translations are utf-8</p> <p>3/3/11: Exson/Baran/Phil fix to customer login to ensure that other customers orders are not displayed when searching by customer ref or order no</p> Modified: trunk/includes/PDFSalesAnalysis.inc =================================================================== --- trunk/includes/PDFSalesAnalysis.inc 2011-03-04 19:40:47 UTC (rev 4503) +++ trunk/includes/PDFSalesAnalysis.inc 2011-03-08 07:38:45 UTC (rev 4504) @@ -4,23 +4,23 @@ include ('includes/class.pdf.php'); -/* A4_Landscape */ +/* A4_Landscape */ +$DocumentPaper = 'A4'; +$DocumentOrientation ='L'; $Page_Width=842; $Page_Height=595; -$Top_Margin=20; -$Bottom_Margin=20; -$Left_Margin=25; -$Right_Margin=22; +$Top_Margin=30; +$Bottom_Margin=30; +$Left_Margin=40; +$Right_Margin=30; -// Javier: now I use the native constructor -// $PageSize = array(0,0,$Page_Width,$Page_Height); +$pdf = new Cpdf($DocumentOrientation, 'pt', $DocumentPaper); +$pdf->SetAutoPageBreak(true, 0); +$pdf->SetPrintHeader(false); +$pdf->AddPage(); +$pdf->cMargin = 0; -// Javier: better to not use references -// $pdf = & new Cpdf($PageSize); - $pdf = new Cpdf('L', 'pt', 'A4'); - - /* Standard PDF file creation header stuff */ $pdf->addInfo('Author','webERP ' . $Version); @@ -41,278 +41,269 @@ /*Make an array to hold accumulators for */ $AccumLvl1 = array(); +$AccumLvl2 = array(); +$AccumLvl3 = array(); +$AccumLvl4 = array(); + for ($i=0;$i<=10;$i++){ -$AccumLvl1[$i]=0; + $AccumLvl1[$i]=0; + $AccumLvl2[$i]=0; + $AccumLvl3[$i]=0; + $AccumLvl4[$i]=0; } -$AccumLvl2= array(); -for ($i=0;$i<=10;$i++){ -$AccumLvl2[$i]=0; -} -$AccumLvl3=array(); -for ($i=0;$i<=10;$i++){ -$AccumLvl3[$i]=0; -} -$AccumLvl4=array(); -for ($i=0;$i<=10;$i++){ -$AccumLvl4[$i]=0; -} While ($myrow = DB_fetch_array($result)){ /*First off check that at least one of the columns of data has some none zero amounts */ -DB_data_seek($ColsResult,0); /*go back to the beginning */ -$ThisLineHasOutput=False; /*assume no output to start with */ -while ($Cols = DB_fetch_array($ColsResult)){ - $ColumnNo ='col' . ((int) $Cols['colno'] + 8); - if (abs($myrow[$ColumnNo])>0.5){ - $ThisLineHasOutput = True; + DB_data_seek($ColsResult,0); /*go back to the beginning */ + $ThisLineHasOutput=False; /*assume no output to start with */ + while ($Cols = DB_fetch_array($ColsResult)){ + $ColumnNo ='col' . ((int) $Cols['colno'] + 8); + if (abs($myrow[$ColumnNo])>0.5){ + $ThisLineHasOutput = True; + } } -} -if ($ThisLineHasOutput==True){ + if ($ThisLineHasOutput==True){ - if ($myrow['col5']!=$GrpData3 && $myrow['col5']!='0' && $myrow['col7']!='0'){ - /*Totals only relevant to GrpByLevel 3 if GrpByLevel 4 also used */ - if ($Counter > 0){ /*Dont want to print totals if this is the first record */ - $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col5'] . ' - ' . $LastLine['col6'],0,33); - $LeftOvers = $pdf->addTextWrap(40,$Ypos,180,$FontSize,$TotalText); + if ($myrow['col5']!=$GrpData3 && $myrow['col5']!='0' && $myrow['col7']!='0'){ + /*Totals only relevant to GrpByLevel 3 if GrpByLevel 4 also used */ + if ($Counter > 0){ /*Dont want to print totals if this is the first record */ + $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col5'] . ' - ' . $LastLine['col6'],0,33); + $LeftOvers = $pdf->addTextWrap(40,$Ypos,180,$FontSize,$TotalText); - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + $Cols['colno']*60; - if ($Cols['calculation']==0){ - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, number_format($AccumLvl3[$Cols['colno']]),'right'); - } else { /* its a calculation need to re-perform on the totals*/ + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + $Cols['colno']*60; + if ($Cols['calculation']==0){ + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, number_format($AccumLvl3[$Cols['colno']]),'right'); + } else { /* its a calculation need to re-perform on the totals*/ - switch ($Cols['calcoperator']) { - case '/': - if ($AccumLvl3[$Cols['coldenominator']]==0){ - $TotalCalculation = 0; + switch ($Cols['calcoperator']) { + case '/': + if ($AccumLvl3[$Cols['coldenominator']]==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $AccumLvl3[$Cols['coldenominator']]; + } + break; + case '+': + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; + break; + case '-': + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; + break; + case '*': + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] * $Cols['constant']; + break; + case 'C': + if ($Cols['constant']==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $Cols['constant']; + } + break; + } /*end of switch stmt block*/ + if ($Cols['valformat']=='P'){ + $TotalCalculation = number_format($TotalCalculation * 100) . '%'; } else { - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $AccumLvl3[$Cols['coldenominator']]; + $TotalCalculation = number_format($TotalCalculation); } - break; - case '+': - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; - break; - case '-': - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; - break; - case '*': - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] * $Cols['constant']; - break; - case 'C': - if ($Cols['constant']==0){ - $TotalCalculation = 0; - } else { - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $Cols['constant']; - } - break; - } /*end of switch stmt block*/ - if ($Cols['valformat']=='P'){ - $TotalCalculation = number_format($TotalCalculation * 100) . '%'; - } else { - $TotalCalculation = number_format($TotalCalculation); + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); } + $Ypos -=(2*$line_height); + /*reset the accumulators to 0 */ + for ($i=0;$i<=10;$i++){ + $AccumLvl3[$i]=0; + } } - $Ypos -=(2*$line_height); - /*reset the accumulators to 0 */ - for ($i=0;$i<=10;$i++){ - $AccumLvl3[$i]=0; - } } - } - - if ($myrow['col3']!=$GrpData2 && $myrow['col3']!='0' && $myrow['col5']!='0'){ + if ($myrow['col3']!=$GrpData2 && $myrow['col3']!='0' && $myrow['col5']!='0'){ /*Totals only relevant to GrpByLevel 2 if GrpByLevel 3 also used */ - if ($Counter > 0){ /*Dont want to print totals if this is the first record */ - $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col3'] . ' - ' . $LastLine['col4'],0,43); - $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$TotalText); - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + $Cols['colno']*60; - if ($Cols['calculation']==0){ - $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl2[$Cols['colno']]),'right'); - } else { /* its a calculation need to re-perform on the totals*/ + if ($Counter > 0){ /*Dont want to print totals if this is the first record */ + $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col3'] . ' - ' . $LastLine['col4'],0,43); + $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$TotalText); + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + $Cols['colno']*60; + if ($Cols['calculation']==0){ + $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl2[$Cols['colno']]),'right'); + } else { /* its a calculation need to re-perform on the totals*/ - switch ($Cols['calcoperator']) { - case '/': - if ($AccumLvl2[$Cols['coldenominator']]==0){ - $TotalCalculation = 0; + switch ($Cols['calcoperator']) { + case '/': + if ($AccumLvl2[$Cols['coldenominator']]==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $AccumLvl2[$Cols['coldenominator']]; + } + break; + case '+': + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; + break; + case '-': + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; + break; + case '*': + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] * $Cols['constant']; + break; + case 'C': + if ($Cols['constant']==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $Cols['constant']; + } + break; + } /*end of switch stmt block*/ + if ($Cols['valformat']=='P'){ + $TotalCalculation = number_format($TotalCalculation * 100) . '%'; } else { - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $AccumLvl2[$Cols['coldenominator']]; + $TotalCalculation = number_format($TotalCalculation); } - break; - case '+': - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; - break; - case '-': - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; - break; - case '*': - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] * $Cols['constant']; - break; - case 'C': - if ($Cols['constant']==0){ - $TotalCalculation = 0; - } else { - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $Cols['constant']; - } - break; - } /*end of switch stmt block*/ - if ($Cols['valformat']=='P'){ - $TotalCalculation = number_format($TotalCalculation * 100) . '%'; - } else { - $TotalCalculation = number_format($TotalCalculation); - } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + }/*end if not a calculation column*/ + }/*end while loop through column definitions */ + $Ypos -=(2*$line_height); + /*reset the accumulators to 0 */ + for ($i=0;$i<=10;$i++){ + $AccumLvl2[$i]=0; } - - } - $Ypos -=(2*$line_height); - /*reset the accumulators to 0 */ - for ($i=0;$i<=10;$i++){ - $AccumLvl2[$i]=0; - } + }/*end if Counter > 0 */ } - } - if ($myrow['col1']!=$GrpData1 && $myrow['col3']!='0'){ - /*Totals only relevant to GrpByLevel 1 if GrpByLevel 2 also used */ - if ($Counter > 0){ /*Dont want to print totals if this is the first record */ - $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col1'] . ' - ' . $LastLine['col2'],0,46); - $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$TotalText); - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + $Cols['colno']*60; - if ($Cols['calculation']==0){ - $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl1[$Cols['colno']]),'right'); - } else { /* its a calculation need to re-perform on the totals*/ - - switch ($Cols['calcoperator']) { - Case '/': - if ($AccumLvl1[$Cols['coldenominator']]==0){ - $TotalCalculation = 0; + if ($myrow['col1']!=$GrpData1 && $myrow['col3']!='0'){ + /*Totals only relevant to GrpByLevel 1 if GrpByLevel 2 also used */ + if ($Counter > 0){ /*Dont want to print totals if this is the first record */ + $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col1'] . ' - ' . $LastLine['col2'],0,46); + $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$TotalText); + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + $Cols['colno']*60; + if ($Cols['calculation']==0){ + $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl1[$Cols['colno']]),'right'); + } else { /* its a calculation need to re-perform on the totals*/ + + switch ($Cols['calcoperator']) { + Case '/': + if ($AccumLvl1[$Cols['coldenominator']]==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $AccumLvl1[$Cols['coldenominator']]; + } + break; + Case '+': + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; + break; + Case '-': + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; + break; + Case '*': + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] * $Cols['constant']; + break; + Case 'C': + if ($Cols['constant']==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $Cols['constant']; + } + break; + } /*end of switch stmt block*/ + if ($Cols['valformat']=='P'){ + $TotalCalculation = number_format($TotalCalculation * 100) . '%'; } else { - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $AccumLvl1[$Cols['coldenominator']]; + $TotalCalculation = number_format($TotalCalculation); } - break; - Case '+': - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; - break; - Case '-': - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; - break; - Case '*': - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] * $Cols['constant']; - break; - Case 'C': - if ($Cols['constant']==0){ - $TotalCalculation = 0; - } else { - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $Cols['constant']; - } - break; - } /*end of switch stmt block*/ - if ($Cols['valformat']=='P'){ - $TotalCalculation = number_format($TotalCalculation * 100) . '%'; - } else { - $TotalCalculation = number_format($TotalCalculation); - } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + }/*end if its not a calculation */ + } /* end loop around column defintions */ + $Ypos -=(2*$line_height); + + /*reset the accumulators to 0 */ + for ($i=0;$i<=10;$i++){ + $AccumLvl1[$i]=0; } + }/* end if counter>0 */ + } + + $NewHeading =0; + if ($myrow['col1']!=$GrpData1){ /*Need a new heading for Level 1 */ + $NewHeading = 1; + if ($ReportSpec['newpageafter1']==1){ + include ('includes/PDFSalesAnalPageHeader.inc'); } - $Ypos -=(2*$line_height); + $GroupHeadingText = substr($myrow['col1'] . ' - ' . $myrow['col2'],0,50); + $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$GroupHeadingText); - /*reset the accumulators to 0 */ - for ($i=0;$i<=10;$i++){ - $AccumLvl1[$i]=0; + if ($myrow['col3']!='0'){ + $Ypos-=$line_height; } } - } - $NewHeading =0; + if (($myrow['col3']!=$GrpData2 OR $NewHeading ==1) AND $myrow['col3']!='0'){ + /*Need a new heading for Level 2 */ + $NewHeading = 1; + if ($ReportSpec['newpageafter2']==1){ + include ('includes/PDFSalesAnalPageHeader.inc'); + } + $GroupHeadingText = substr($myrow['col3'] . ' - ' . $myrow['col4'],0,46); + $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); - if ($myrow['col1']!=$GrpData1){ /*Need a new heading for Level 1 */ - $NewHeading = 1; - if ($ReportSpec['newpageafter1']==1){ - include ('includes/PDFSalesAnalPageHeader.inc'); - } - $GroupHeadingText = substr($myrow['col1'] . ' - ' . $myrow['col2'],0,50); - $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$GroupHeadingText); - - if ($myrow['col3']!='0'){ + if ($myrow['col5']!='0'){ $Ypos-=$line_height; + } } - } + if (($myrow['col5']!=$GrpData3 OR $NewHeading ==1) AND $myrow['col5']!='0'){ + /*Need a new heading for Level 3 */ - if (($myrow['col3']!=$GrpData2 OR $NewHeading ==1) AND $myrow['col3']!='0'){ - /*Need a new heading for Level 2 */ - $NewHeading = 1; - if ($ReportSpec['newpageafter2']==1){ - include ('includes/PDFSalesAnalPageHeader.inc'); - } - $GroupHeadingText = substr($myrow['col3'] . ' - ' . $myrow['col4'],0,46); - $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); + if ($ReportSpec['newpageafter3']==1){ + include ('includes/PDFSalesAnalPageHeader.inc'); + } + $GroupHeadingText = substr($myrow['col5'] . ' - ' . $myrow['col6'],0,46); + $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); - if ($myrow['col5']!='0'){ - $Ypos-=$line_height; + if ($myrow['col7']!='0'){ + $Ypos-=$line_height; + } } - } - if (($myrow['col5']!=$GrpData3 OR $NewHeading ==1) AND $myrow['col5']!='0'){ - /*Need a new heading for Level 3 */ - if ($ReportSpec['newpageafter3']==1){ - include ('includes/PDFSalesAnalPageHeader.inc'); - } - $GroupHeadingText = substr($myrow['col5'] . ' - ' . $myrow['col6'],0,46); - $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); - if ($myrow['col7']!='0'){ - $Ypos-=$line_height; + /*show titles */ + $GroupHeadingText = substr($myrow['col7'] . ' - ' . $myrow['col8'], 0, 40); + $LeftOvers = $pdf->addTextWrap(55,$Ypos,135,$FontSize,$GroupHeadingText); + } - } - if ($myrow['col7']!='0'){ - /*show titles */ - $GroupHeadingText = substr($myrow['col7'] . ' - ' . $myrow['col8'], 0, 40); - $LeftOvers = $pdf->addTextWrap(55,$Ypos,135,$FontSize,$GroupHeadingText); + /*NOW SHOW THE LINE OF DATA */ + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + ($Cols['colno']*60); + $ColumnNo = 'col' . (string) (($Cols['colno']) +8); + if ($Cols['valformat']=='P'){ + $DisplayValue = number_format($myrow[$ColumnNo] *100) . '%'; + } else { + $DisplayValue = number_format($myrow[$ColumnNo]); + } + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize,$DisplayValue, 'right'); - } - - /*NOW SHOW THE LINE OF DATA */ - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + ($Cols['colno']*60); - $ColumnNo = 'col' . (string) (($Cols['colno']) +8); - if ($Cols['valformat']=='P'){ - $DisplayValue = number_format($myrow[$ColumnNo] *100) . '%'; - } else { - $DisplayValue = number_format($myrow[$ColumnNo]); + $AccumLvl1[$Cols['colno']] += $myrow[$ColumnNo]; + $AccumLvl2[$Cols['colno']] += $myrow[$ColumnNo]; + $AccumLvl3[$Cols['colno']] += $myrow[$ColumnNo]; + $AccumLvl4[$Cols['colno']] += $myrow[$ColumnNo]; } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize,$DisplayValue, 'right'); - $AccumLvl1[$Cols['colno']] += $myrow[$ColumnNo]; - $AccumLvl2[$Cols['colno']] += $myrow[$ColumnNo]; - $AccumLvl3[$Cols['colno']] += $myrow[$ColumnNo]; - $AccumLvl4[$Cols['colno']] += $myrow[$ColumnNo]; - } + $Ypos -=$line_height; - $Ypos -=$line_height; - - if ($Ypos - (2*$line_height) < $Bottom_Margin){ - include ('includes/PDFSalesAnalPageHeader.inc'); - }//end if need a new page headed up - $GrpData1 = $myrow['col1']; - $GrpData2 = $myrow['col3']; - $GrpData3 = $myrow['col5']; - $Counter++; - $LastLine = $myrow; /*remember the last line that had some output in an array called last line*/ + if ($Ypos - (2*$line_height) < $Bottom_Margin){ + include ('includes/PDFSalesAnalPageHeader.inc'); + }//end if need a new page headed up + $GrpData1 = $myrow['col1']; + $GrpData2 = $myrow['col3']; + $GrpData3 = $myrow['col5']; + $Counter++; + $LastLine = $myrow; /*remember the last line that had some output in an array called last line*/ } /*The line has some positive amount on it */ - } /*end of the data loop to print lines */ if ($LastLine['col5']!='0' && $LastLine['col7']!='0'){ @@ -514,8 +505,6 @@ } - - if ($_GET['ProduceCVSFile']==True){ function stripcomma($str) { //because we're using comma as a delimiter This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dai...@us...> - 2011-03-08 07:38:52
|
Revision: 4504 http://web-erp.svn.sourceforge.net/web-erp/?rev=4504&view=rev Author: daintree Date: 2011-03-08 07:38:45 +0000 (Tue, 08 Mar 2011) Log Message: ----------- Sales Analysis fix Modified Paths: -------------- trunk/SalesAnalysis_UserDefined.php trunk/doc/Change.log.html trunk/includes/PDFSalesAnalysis.inc Modified: trunk/SalesAnalysis_UserDefined.php =================================================================== --- trunk/SalesAnalysis_UserDefined.php 2011-03-04 19:40:47 UTC (rev 4503) +++ trunk/SalesAnalysis_UserDefined.php 2011-03-08 07:38:45 UTC (rev 4504) @@ -2,7 +2,7 @@ /* $Id$ */ -//$PageSecurity = 2; + include('includes/session.inc'); if (!in_array($PageSecurity,$_SESSION['AllowedPageSecurityTokens'])){ @@ -18,9 +18,9 @@ if ($Counter >0) { $pdf->OutputD('SalesAnalysis_' . date('Y-m-d') . '.pdf'); - $pdf-> __destruct(); + $pdf->__destruct(); } else { - $pdf-> __destruct(); + $pdf->__destruct(); $title = _('User Defined Sales Analysis Problem'); include('includes/header.inc'); echo '<p>' . _('The report did not have any none zero lines of information to show and so it has not been created'); @@ -46,5 +46,4 @@ echo '<p>' . _('You should automatically be forwarded to the CSV Sales Analysis file when it is ready') . '. ' . _('If this does not happen') . ' <a href="' . $rootpath . '/' . $_SESSION['reports_dir'] . '/SalesAnalysis.csv">' . _('click here') . '</a> ' . _('to continue') . '<br />'; include('includes/footer.inc'); } - -?> +?> \ No newline at end of file Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2011-03-04 19:40:47 UTC (rev 4503) +++ trunk/doc/Change.log.html 2011-03-08 07:38:45 UTC (rev 4504) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p> +<p>8/3/11:Phil fix SalesAnalysis reports for TCPDF as reported by Joe Zhou</p> <p>5/3/11: Kovács Attila fix to Stocks.php to use ANSI GROUP BY for aggregate functions SQL</p> <p>5/3/11: Kovács Attila fix to LanguageSetup.php to use utf-8 not ISO-8859-1. Phil hardcoded UTF- now as no dynamic changing of character set required all translations are utf-8</p> <p>3/3/11: Exson/Baran/Phil fix to customer login to ensure that other customers orders are not displayed when searching by customer ref or order no</p> Modified: trunk/includes/PDFSalesAnalysis.inc =================================================================== --- trunk/includes/PDFSalesAnalysis.inc 2011-03-04 19:40:47 UTC (rev 4503) +++ trunk/includes/PDFSalesAnalysis.inc 2011-03-08 07:38:45 UTC (rev 4504) @@ -4,23 +4,23 @@ include ('includes/class.pdf.php'); -/* A4_Landscape */ +/* A4_Landscape */ +$DocumentPaper = 'A4'; +$DocumentOrientation ='L'; $Page_Width=842; $Page_Height=595; -$Top_Margin=20; -$Bottom_Margin=20; -$Left_Margin=25; -$Right_Margin=22; +$Top_Margin=30; +$Bottom_Margin=30; +$Left_Margin=40; +$Right_Margin=30; -// Javier: now I use the native constructor -// $PageSize = array(0,0,$Page_Width,$Page_Height); +$pdf = new Cpdf($DocumentOrientation, 'pt', $DocumentPaper); +$pdf->SetAutoPageBreak(true, 0); +$pdf->SetPrintHeader(false); +$pdf->AddPage(); +$pdf->cMargin = 0; -// Javier: better to not use references -// $pdf = & new Cpdf($PageSize); - $pdf = new Cpdf('L', 'pt', 'A4'); - - /* Standard PDF file creation header stuff */ $pdf->addInfo('Author','webERP ' . $Version); @@ -41,278 +41,269 @@ /*Make an array to hold accumulators for */ $AccumLvl1 = array(); +$AccumLvl2 = array(); +$AccumLvl3 = array(); +$AccumLvl4 = array(); + for ($i=0;$i<=10;$i++){ -$AccumLvl1[$i]=0; + $AccumLvl1[$i]=0; + $AccumLvl2[$i]=0; + $AccumLvl3[$i]=0; + $AccumLvl4[$i]=0; } -$AccumLvl2= array(); -for ($i=0;$i<=10;$i++){ -$AccumLvl2[$i]=0; -} -$AccumLvl3=array(); -for ($i=0;$i<=10;$i++){ -$AccumLvl3[$i]=0; -} -$AccumLvl4=array(); -for ($i=0;$i<=10;$i++){ -$AccumLvl4[$i]=0; -} While ($myrow = DB_fetch_array($result)){ /*First off check that at least one of the columns of data has some none zero amounts */ -DB_data_seek($ColsResult,0); /*go back to the beginning */ -$ThisLineHasOutput=False; /*assume no output to start with */ -while ($Cols = DB_fetch_array($ColsResult)){ - $ColumnNo ='col' . ((int) $Cols['colno'] + 8); - if (abs($myrow[$ColumnNo])>0.5){ - $ThisLineHasOutput = True; + DB_data_seek($ColsResult,0); /*go back to the beginning */ + $ThisLineHasOutput=False; /*assume no output to start with */ + while ($Cols = DB_fetch_array($ColsResult)){ + $ColumnNo ='col' . ((int) $Cols['colno'] + 8); + if (abs($myrow[$ColumnNo])>0.5){ + $ThisLineHasOutput = True; + } } -} -if ($ThisLineHasOutput==True){ + if ($ThisLineHasOutput==True){ - if ($myrow['col5']!=$GrpData3 && $myrow['col5']!='0' && $myrow['col7']!='0'){ - /*Totals only relevant to GrpByLevel 3 if GrpByLevel 4 also used */ - if ($Counter > 0){ /*Dont want to print totals if this is the first record */ - $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col5'] . ' - ' . $LastLine['col6'],0,33); - $LeftOvers = $pdf->addTextWrap(40,$Ypos,180,$FontSize,$TotalText); + if ($myrow['col5']!=$GrpData3 && $myrow['col5']!='0' && $myrow['col7']!='0'){ + /*Totals only relevant to GrpByLevel 3 if GrpByLevel 4 also used */ + if ($Counter > 0){ /*Dont want to print totals if this is the first record */ + $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col5'] . ' - ' . $LastLine['col6'],0,33); + $LeftOvers = $pdf->addTextWrap(40,$Ypos,180,$FontSize,$TotalText); - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + $Cols['colno']*60; - if ($Cols['calculation']==0){ - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, number_format($AccumLvl3[$Cols['colno']]),'right'); - } else { /* its a calculation need to re-perform on the totals*/ + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + $Cols['colno']*60; + if ($Cols['calculation']==0){ + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, number_format($AccumLvl3[$Cols['colno']]),'right'); + } else { /* its a calculation need to re-perform on the totals*/ - switch ($Cols['calcoperator']) { - case '/': - if ($AccumLvl3[$Cols['coldenominator']]==0){ - $TotalCalculation = 0; + switch ($Cols['calcoperator']) { + case '/': + if ($AccumLvl3[$Cols['coldenominator']]==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $AccumLvl3[$Cols['coldenominator']]; + } + break; + case '+': + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; + break; + case '-': + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; + break; + case '*': + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] * $Cols['constant']; + break; + case 'C': + if ($Cols['constant']==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $Cols['constant']; + } + break; + } /*end of switch stmt block*/ + if ($Cols['valformat']=='P'){ + $TotalCalculation = number_format($TotalCalculation * 100) . '%'; } else { - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $AccumLvl3[$Cols['coldenominator']]; + $TotalCalculation = number_format($TotalCalculation); } - break; - case '+': - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; - break; - case '-': - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] + $AccumLvl3[$Cols['coldenominator']]; - break; - case '*': - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] * $Cols['constant']; - break; - case 'C': - if ($Cols['constant']==0){ - $TotalCalculation = 0; - } else { - $TotalCalculation = $AccumLvl3[$Cols['colnumerator']] / $Cols['constant']; - } - break; - } /*end of switch stmt block*/ - if ($Cols['valformat']=='P'){ - $TotalCalculation = number_format($TotalCalculation * 100) . '%'; - } else { - $TotalCalculation = number_format($TotalCalculation); + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); } + $Ypos -=(2*$line_height); + /*reset the accumulators to 0 */ + for ($i=0;$i<=10;$i++){ + $AccumLvl3[$i]=0; + } } - $Ypos -=(2*$line_height); - /*reset the accumulators to 0 */ - for ($i=0;$i<=10;$i++){ - $AccumLvl3[$i]=0; - } } - } - - if ($myrow['col3']!=$GrpData2 && $myrow['col3']!='0' && $myrow['col5']!='0'){ + if ($myrow['col3']!=$GrpData2 && $myrow['col3']!='0' && $myrow['col5']!='0'){ /*Totals only relevant to GrpByLevel 2 if GrpByLevel 3 also used */ - if ($Counter > 0){ /*Dont want to print totals if this is the first record */ - $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col3'] . ' - ' . $LastLine['col4'],0,43); - $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$TotalText); - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + $Cols['colno']*60; - if ($Cols['calculation']==0){ - $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl2[$Cols['colno']]),'right'); - } else { /* its a calculation need to re-perform on the totals*/ + if ($Counter > 0){ /*Dont want to print totals if this is the first record */ + $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col3'] . ' - ' . $LastLine['col4'],0,43); + $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$TotalText); + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + $Cols['colno']*60; + if ($Cols['calculation']==0){ + $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl2[$Cols['colno']]),'right'); + } else { /* its a calculation need to re-perform on the totals*/ - switch ($Cols['calcoperator']) { - case '/': - if ($AccumLvl2[$Cols['coldenominator']]==0){ - $TotalCalculation = 0; + switch ($Cols['calcoperator']) { + case '/': + if ($AccumLvl2[$Cols['coldenominator']]==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $AccumLvl2[$Cols['coldenominator']]; + } + break; + case '+': + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; + break; + case '-': + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; + break; + case '*': + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] * $Cols['constant']; + break; + case 'C': + if ($Cols['constant']==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $Cols['constant']; + } + break; + } /*end of switch stmt block*/ + if ($Cols['valformat']=='P'){ + $TotalCalculation = number_format($TotalCalculation * 100) . '%'; } else { - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $AccumLvl2[$Cols['coldenominator']]; + $TotalCalculation = number_format($TotalCalculation); } - break; - case '+': - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; - break; - case '-': - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] + $AccumLvl2[$Cols['coldenominator']]; - break; - case '*': - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] * $Cols['constant']; - break; - case 'C': - if ($Cols['constant']==0){ - $TotalCalculation = 0; - } else { - $TotalCalculation = $AccumLvl2[$Cols['colnumerator']] / $Cols['constant']; - } - break; - } /*end of switch stmt block*/ - if ($Cols['valformat']=='P'){ - $TotalCalculation = number_format($TotalCalculation * 100) . '%'; - } else { - $TotalCalculation = number_format($TotalCalculation); - } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + }/*end if not a calculation column*/ + }/*end while loop through column definitions */ + $Ypos -=(2*$line_height); + /*reset the accumulators to 0 */ + for ($i=0;$i<=10;$i++){ + $AccumLvl2[$i]=0; } - - } - $Ypos -=(2*$line_height); - /*reset the accumulators to 0 */ - for ($i=0;$i<=10;$i++){ - $AccumLvl2[$i]=0; - } + }/*end if Counter > 0 */ } - } - if ($myrow['col1']!=$GrpData1 && $myrow['col3']!='0'){ - /*Totals only relevant to GrpByLevel 1 if GrpByLevel 2 also used */ - if ($Counter > 0){ /*Dont want to print totals if this is the first record */ - $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col1'] . ' - ' . $LastLine['col2'],0,46); - $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$TotalText); - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + $Cols['colno']*60; - if ($Cols['calculation']==0){ - $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl1[$Cols['colno']]),'right'); - } else { /* its a calculation need to re-perform on the totals*/ - - switch ($Cols['calcoperator']) { - Case '/': - if ($AccumLvl1[$Cols['coldenominator']]==0){ - $TotalCalculation = 0; + if ($myrow['col1']!=$GrpData1 && $myrow['col3']!='0'){ + /*Totals only relevant to GrpByLevel 1 if GrpByLevel 2 also used */ + if ($Counter > 0){ /*Dont want to print totals if this is the first record */ + $TotalText = substr(_('TOTAL') . ' ' . $LastLine['col1'] . ' - ' . $LastLine['col2'],0,46); + $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$TotalText); + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + $Cols['colno']*60; + if ($Cols['calculation']==0){ + $LeftOvers = $pdf->addTextWrap($Xpos, $Ypos,60,$FontSize, number_format($AccumLvl1[$Cols['colno']]),'right'); + } else { /* its a calculation need to re-perform on the totals*/ + + switch ($Cols['calcoperator']) { + Case '/': + if ($AccumLvl1[$Cols['coldenominator']]==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $AccumLvl1[$Cols['coldenominator']]; + } + break; + Case '+': + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; + break; + Case '-': + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; + break; + Case '*': + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] * $Cols['constant']; + break; + Case 'C': + if ($Cols['constant']==0){ + $TotalCalculation = 0; + } else { + $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $Cols['constant']; + } + break; + } /*end of switch stmt block*/ + if ($Cols['valformat']=='P'){ + $TotalCalculation = number_format($TotalCalculation * 100) . '%'; } else { - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $AccumLvl1[$Cols['coldenominator']]; + $TotalCalculation = number_format($TotalCalculation); } - break; - Case '+': - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; - break; - Case '-': - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] + $AccumLvl1[$Cols['coldenominator']]; - break; - Case '*': - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] * $Cols['constant']; - break; - Case 'C': - if ($Cols['constant']==0){ - $TotalCalculation = 0; - } else { - $TotalCalculation = $AccumLvl1[$Cols['colnumerator']] / $Cols['constant']; - } - break; - } /*end of switch stmt block*/ - if ($Cols['valformat']=='P'){ - $TotalCalculation = number_format($TotalCalculation * 100) . '%'; - } else { - $TotalCalculation = number_format($TotalCalculation); - } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize, $TotalCalculation,'right'); + }/*end if its not a calculation */ + } /* end loop around column defintions */ + $Ypos -=(2*$line_height); + + /*reset the accumulators to 0 */ + for ($i=0;$i<=10;$i++){ + $AccumLvl1[$i]=0; } + }/* end if counter>0 */ + } + + $NewHeading =0; + if ($myrow['col1']!=$GrpData1){ /*Need a new heading for Level 1 */ + $NewHeading = 1; + if ($ReportSpec['newpageafter1']==1){ + include ('includes/PDFSalesAnalPageHeader.inc'); } - $Ypos -=(2*$line_height); + $GroupHeadingText = substr($myrow['col1'] . ' - ' . $myrow['col2'],0,50); + $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$GroupHeadingText); - /*reset the accumulators to 0 */ - for ($i=0;$i<=10;$i++){ - $AccumLvl1[$i]=0; + if ($myrow['col3']!='0'){ + $Ypos-=$line_height; } } - } - $NewHeading =0; + if (($myrow['col3']!=$GrpData2 OR $NewHeading ==1) AND $myrow['col3']!='0'){ + /*Need a new heading for Level 2 */ + $NewHeading = 1; + if ($ReportSpec['newpageafter2']==1){ + include ('includes/PDFSalesAnalPageHeader.inc'); + } + $GroupHeadingText = substr($myrow['col3'] . ' - ' . $myrow['col4'],0,46); + $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); - if ($myrow['col1']!=$GrpData1){ /*Need a new heading for Level 1 */ - $NewHeading = 1; - if ($ReportSpec['newpageafter1']==1){ - include ('includes/PDFSalesAnalPageHeader.inc'); - } - $GroupHeadingText = substr($myrow['col1'] . ' - ' . $myrow['col2'],0,50); - $LeftOvers = $pdf->addTextWrap(15,$Ypos,205,$FontSize,$GroupHeadingText); - - if ($myrow['col3']!='0'){ + if ($myrow['col5']!='0'){ $Ypos-=$line_height; + } } - } + if (($myrow['col5']!=$GrpData3 OR $NewHeading ==1) AND $myrow['col5']!='0'){ + /*Need a new heading for Level 3 */ - if (($myrow['col3']!=$GrpData2 OR $NewHeading ==1) AND $myrow['col3']!='0'){ - /*Need a new heading for Level 2 */ - $NewHeading = 1; - if ($ReportSpec['newpageafter2']==1){ - include ('includes/PDFSalesAnalPageHeader.inc'); - } - $GroupHeadingText = substr($myrow['col3'] . ' - ' . $myrow['col4'],0,46); - $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); + if ($ReportSpec['newpageafter3']==1){ + include ('includes/PDFSalesAnalPageHeader.inc'); + } + $GroupHeadingText = substr($myrow['col5'] . ' - ' . $myrow['col6'],0,46); + $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); - if ($myrow['col5']!='0'){ - $Ypos-=$line_height; + if ($myrow['col7']!='0'){ + $Ypos-=$line_height; + } } - } - if (($myrow['col5']!=$GrpData3 OR $NewHeading ==1) AND $myrow['col5']!='0'){ - /*Need a new heading for Level 3 */ - if ($ReportSpec['newpageafter3']==1){ - include ('includes/PDFSalesAnalPageHeader.inc'); - } - $GroupHeadingText = substr($myrow['col5'] . ' - ' . $myrow['col6'],0,46); - $LeftOvers = $pdf->addTextWrap(30,$Ypos,190,$FontSize,$GroupHeadingText); - if ($myrow['col7']!='0'){ - $Ypos-=$line_height; + /*show titles */ + $GroupHeadingText = substr($myrow['col7'] . ' - ' . $myrow['col8'], 0, 40); + $LeftOvers = $pdf->addTextWrap(55,$Ypos,135,$FontSize,$GroupHeadingText); + } - } - if ($myrow['col7']!='0'){ - /*show titles */ - $GroupHeadingText = substr($myrow['col7'] . ' - ' . $myrow['col8'], 0, 40); - $LeftOvers = $pdf->addTextWrap(55,$Ypos,135,$FontSize,$GroupHeadingText); + /*NOW SHOW THE LINE OF DATA */ + DB_data_seek($ColsResult,0); + while ($Cols = DB_fetch_array($ColsResult)){ + $Xpos = 160 + ($Cols['colno']*60); + $ColumnNo = 'col' . (string) (($Cols['colno']) +8); + if ($Cols['valformat']=='P'){ + $DisplayValue = number_format($myrow[$ColumnNo] *100) . '%'; + } else { + $DisplayValue = number_format($myrow[$ColumnNo]); + } + $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize,$DisplayValue, 'right'); - } - - /*NOW SHOW THE LINE OF DATA */ - DB_data_seek($ColsResult,0); - while ($Cols = DB_fetch_array($ColsResult)){ - $Xpos = 160 + ($Cols['colno']*60); - $ColumnNo = 'col' . (string) (($Cols['colno']) +8); - if ($Cols['valformat']=='P'){ - $DisplayValue = number_format($myrow[$ColumnNo] *100) . '%'; - } else { - $DisplayValue = number_format($myrow[$ColumnNo]); + $AccumLvl1[$Cols['colno']] += $myrow[$ColumnNo]; + $AccumLvl2[$Cols['colno']] += $myrow[$ColumnNo]; + $AccumLvl3[$Cols['colno']] += $myrow[$ColumnNo]; + $AccumLvl4[$Cols['colno']] += $myrow[$ColumnNo]; } - $LeftOvers = $pdf->addTextWrap($Xpos,$Ypos,60,$FontSize,$DisplayValue, 'right'); - $AccumLvl1[$Cols['colno']] += $myrow[$ColumnNo]; - $AccumLvl2[$Cols['colno']] += $myrow[$ColumnNo]; - $AccumLvl3[$Cols['colno']] += $myrow[$ColumnNo]; - $AccumLvl4[$Cols['colno']] += $myrow[$ColumnNo]; - } + $Ypos -=$line_height; - $Ypos -=$line_height; - - if ($Ypos - (2*$line_height) < $Bottom_Margin){ - include ('includes/PDFSalesAnalPageHeader.inc'); - }//end if need a new page headed up - $GrpData1 = $myrow['col1']; - $GrpData2 = $myrow['col3']; - $GrpData3 = $myrow['col5']; - $Counter++; - $LastLine = $myrow; /*remember the last line that had some output in an array called last line*/ + if ($Ypos - (2*$line_height) < $Bottom_Margin){ + include ('includes/PDFSalesAnalPageHeader.inc'); + }//end if need a new page headed up + $GrpData1 = $myrow['col1']; + $GrpData2 = $myrow['col3']; + $GrpData3 = $myrow['col5']; + $Counter++; + $LastLine = $myrow; /*remember the last line that had some output in an array called last line*/ } /*The line has some positive amount on it */ - } /*end of the data loop to print lines */ if ($LastLine['col5']!='0' && $LastLine['col7']!='0'){ @@ -514,8 +505,6 @@ } - - if ($_GET['ProduceCVSFile']==True){ function stripcomma($str) { //because we're using comma as a delimiter This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |