From: <rc...@us...> - 2014-08-14 04:25:03
|
Revision: 6813 http://sourceforge.net/p/web-erp/reponame/6813 Author: rchacon Date: 2014-08-14 04:24:48 +0000 (Thu, 14 Aug 2014) Log Message: ----------- In CustomerInquiry.php: Adds class ascending and reorganizes columns Date, Type, Number and Reference; Regroups table-datacel format-strings, completes the datacel quantity by table-row; makes translatable the systypes.typename. Modified Paths: -------------- trunk/CustomerInquiry.php trunk/doc/Change.log Modified: trunk/CustomerInquiry.php =================================================================== --- trunk/CustomerInquiry.php 2014-08-13 18:14:57 UTC (rev 6812) +++ trunk/CustomerInquiry.php 2014-08-14 04:24:48 UTC (rev 6813) @@ -1,26 +1,23 @@ <?php +/* $Id$*/ -/* $Id$*/ - -include('includes/SQL_CommonFunctions.inc'); - include('includes/session.inc'); $Title = _('Customer Inquiry'); +$ViewTopic = 'ARInquiries';// Filename in ManualContents.php's TOC. +$BookMark = 'CustomerInquiry';// Anchor's id in the manual's html document. +include('includes/header.inc'); -$ViewTopic = 'ARInquiries'; -$BookMark = 'CustomerInquiry'; +include('includes/SQL_CommonFunctions.inc'); -include('includes/header.inc'); - // always figure out the SQL required from the inputs available -if(!isset($_GET['CustomerID']) AND !isset($_SESSION['CustomerID'])){ +if(!isset($_GET['CustomerID']) AND !isset($_SESSION['CustomerID'])) { prnMsg(_('To display the enquiry a customer must first be selected from the customer selection screen'),'info'); echo '<br /><div class="centre"><a href="'. $RootPath . '/SelectCustomer.php?' . SID . '">' . _('Select a Customer to Inquire On') . '</a><br /></div>'; include('includes/footer.inc'); exit; } else { - if (isset($_GET['CustomerID'])){ + if (isset($_GET['CustomerID'])) { $_SESSION['CustomerID'] = $_GET['CustomerID']; } $CustomerID = $_SESSION['CustomerID']; @@ -94,7 +91,7 @@ $ErrMsg = _('The customer details could not be retrieved by the SQL because'); $CustomerResult = DB_query($SQL,$db,$ErrMsg); -if (DB_num_rows($CustomerResult)==0){ +if (DB_num_rows($CustomerResult)==0) { /*Because there is no balance - so just retrieve the header information about the customer - the choice is do one query to get the balance and transactions for those customers who have a balance and two queries for those who don't have a balance OR always do two queries - I opted for the former */ @@ -125,7 +122,7 @@ $CustomerRecord = DB_fetch_array($CustomerResult); -if ($NIL_BALANCE==True){ +if ($NIL_BALANCE==True) { $CustomerRecord['balance']=0; $CustomerRecord['due']=0; $CustomerRecord['overdue1']=0; @@ -136,7 +133,7 @@ _('Customer') . ': ' . $CustomerID . ' - ' . $CustomerRecord['name'] . '<br />' . _('All amounts stated in') . ': ' . - $CustomerRecord['currency'] . '<br />' . // To be replaced by: + $CustomerRecord['currency'] . '<br />' . // To be replaced by: /* $CustomerRecord['currcode'] . ' - ' . $CurrencyName[$CustomerRecord['currcode']] . '<br />' . // <-- Replacement */ _('Terms') . ': ' . $CustomerRecord['terms'] . '<br />' . @@ -145,7 +142,7 @@ _('Credit Status') . ': ' . $CustomerRecord['reasondescription'] . '</p>'; -if ($CustomerRecord['dissallowinvoices']!=0){ +if ($CustomerRecord['dissallowinvoices']!=0) { echo '<br /><font color="red" size="4"><b>' . _('ACCOUNT ON HOLD') . '</font></b><br />'; } @@ -206,346 +203,202 @@ $ErrMsg = _('No transactions were returned by the SQL because'); $TransResult = DB_query($SQL,$db,$ErrMsg); -if (DB_num_rows($TransResult)==0){ +if (DB_num_rows($TransResult)==0) { echo '<div class="centre">' . _('There are no transactions to display since') . ' ' . $_POST['TransAfterDate'] . '</div>'; include('includes/footer.inc'); exit; } -/*show a table of the invoices returned by the SQL */ +/* Show a table of the invoices returned by the SQL. */ -echo '<table class="selection">'; +echo '<table class="selection"> + <tr> + <th class="ascending">• ' . _('Date') . '</th> + <th class="ascending">• ' . _('Type') . '</th> + <th class="ascending">• ' . _('Number') . '</th> + <th class="ascending">• ' . _('Reference') . '</th> + <th>' . _('Branch') . '</th> + <th>' . _('Comments') . '</th> + <th>' . _('Order') . '</th> + <th>' . _('Total') . '</th> + <th>' . _('Allocated') . '</th> + <th>' . _('Balance') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + </tr>'; -$tableheader = '<tr> - <th>' . _('Type') . '</th> - <th>' . _('Number') . '</th> - <th>' . _('Date') . '</th> - <th>' . _('Branch') . '</th> - <th>' . _('Reference') . '</th> - <th>' . _('Comments') . '</th> - <th>' . _('Order') . '</th> - <th>' . _('Total') . '</th> - <th>' . _('Allocated') . '</th> - <th>' . _('Balance') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - </tr>'; - -echo $tableheader; - $j = 1; -$k=0; //row colour counter +$k = 0;// Row colour counter. while ($myrow=DB_fetch_array($TransResult)) { - if ($k==1){ + if ($k==1) { echo '<tr class="EvenTableRows">'; - $k=0; + $k = 0; } else { echo '<tr class="OddTableRows">'; - $k=1; + $k = 1; } - $FormatedTranDate = ConvertSQLDate($myrow['trandate']); +/* $FormatedTranDate = ConvertSQLDate($myrow['trandate']);*/ - if ($_SESSION['InvoicePortraitFormat']==1){ //Invoice/credits in portrait + if ($_SESSION['InvoicePortraitFormat']==1){// Invoice/credits in portrait. $PrintCustomerTransactionScript = 'PrintCustTransPortrait.php'; - } else { //produce pdfs in landscape + } else {// Produce pdfs in landscape. $PrintCustomerTransactionScript = 'PrintCustTrans.php'; } - $BaseFormatString = '<td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td> - <td style="width:200px">%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td class="number">%s</td>'; + // All table-row (tag tr) must have 15 table-datacells (tag td). + $BaseTD10 = '<td>' . ConvertSQLDate($myrow['trandate']) . '</td> + <td>' . _($myrow['typename']) . '</td> + <td class="number">' . $myrow['transno'] . '</td> + <td>' . $myrow['reference'] . '</td> + <td>' . $myrow['branchcode'] . '</td> + <td style="width:200px">' . $myrow['invtext'] . '</td> + <td class="number">' . $myrow['order_'] . '</td> + <td class="number">' . locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']) . '</td> + <td class="number">' . locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']) . '</td> + <td class="number">' . locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']) . '</td>'; - $CreditInvoiceFormatString = '<td><a href="%s/Credit_Invoice.php?InvoiceNumber=%s">' . _('Credit ') . '<img src="%s/credit.gif" title="' . _('Click to credit the invoice') . '" alt="" /></a></td>'; + $CreditInvoiceTD1 = '<td><a href="' . $RootPath . '/Credit_Invoice.php?InvoiceNumber=%s" title="' . + _('Click to credit the invoice') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/credit.gif" /> ' . _('Credit') . '</a></td>'; - $PreviewInvoiceFormatString = '<td><a href="%s/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice">' . _('HTML ') . '<img src="%s/preview.gif" title="' . _('Click to preview the invoice') . '" alt="" /></a></td> - <td><a href="%s/%s?FromTransNo=%s&InvOrCredit=Invoice&PrintPDF=True">' . _('PDF ') . '<img src="%s/css/' . $Theme . '/images/pdf.png" title="' . _('Click for PDF') . '" alt="" /></a></td> - <td><a href="%s/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice">' . _('Email ') . '<img src="%s/email.gif" title="' . _('Click to email the invoice') . '" alt="" /></a></td>'; + $AllocationTD1 = '<td><a href="' . $RootPath . '/CustomerAllocations.php?AllocTrans=%s" title="' . + _('Click to allocate funds') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/allocation.png" /> ' . _('Allocation') . '</a></td>'; - $PreviewCreditFormatString = '<td><a href="%s/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Credit">' . _('HTML ') . ' <IMG SRC="%s/preview.gif" title="' . _('Click to preview the credit note') . '" /></a></td> - <td><a href="%s/%s?FromTransNo=%s&InvOrCredit=Credit&PrintPDF=True">' . _('PDF ') . '<img src="%s/css/' . $Theme . '/images/pdf.png" title="' . _('Click for PDF') . '" alt="" /></a></td> - <td><a href="%s/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Credit">' . _('Email') . ' <img src="%s/email.gif" title="' . _('Click to email the credit note') . '" alt="" /></a></td>'; + $PreviewInvoiceTD3 = '<td><a href="' . $RootPath . '/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice" title="' . + _('Click to preview the invoice') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/preview.gif" /> ' . _('HTML') . '</a></td> + <td><a href="' . $RootPath .'/%s?FromTransNo=%s&InvOrCredit=Invoice&PrintPDF=True" title="' . + _('Click for PDF') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/pdf.png" /> ' . _('PDF') . ' </a></td> + <td><a href="' . $RootPath .'/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice" title="' . + _('Click to email the invoice') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/email.gif" /> ' . _('Email') . '</a></td>'; + $PreviewCreditTD3 = '<td><a href="' . $RootPath . '/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Credit" title="' . + _('Click to preview the credit note') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/preview.gif" /> ' . _('HTML') . '</a></td> + <td><a href="' . $RootPath . '/%s?FromTransNo=%s&InvOrCredit=Credit&PrintPDF=True" title="' . + _('Click for PDF') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/pdf.png" /> ' . _('PDF') . ' </a></td> + <td><a href="' . $RootPath . '/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Credit" title="' . + _('Click to email the credit note') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/email.gif" /> ' . _('Email') . '</a></td>'; + + $GLEntriesTD1 = '<td><a href="' . $RootPath . '/GLTransInquiry.php?TypeID=%s&TransNo=%s" title="' . + _('Click to view the GL entries') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/gl.png" width="16" /> ' . _('GL Entries') . '</a></td>'; + /* assumed allowed page security token 3 allows the user to create credits for invoices */ - if (in_array(3,$_SESSION['AllowedPageSecurityTokens']) AND $myrow['type']==10){ + if (in_array(3,$_SESSION['AllowedPageSecurityTokens']) AND $myrow['type']==10) { /*Show a link to allow an invoice to be credited */ /* assumed allowed page security token 8 allows the user to see GL transaction information */ - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ - + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { /* format string with GL inquiry options and for invoice to be credited */ - - printf($BaseFormatString . $CreditInvoiceFormatString . $PreviewInvoiceFormatString . - '<td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' - <img src="' .$RootPath. '/css/'.$Theme.'/images/gl.png" title="' . _('View the GL Entries') . '" alt="" /></a></td> - </tr>', - //$BaseFormatString parameters - $myrow['typename'], + printf($BaseTD10 . $CreditInvoiceTD1 . $PreviewInvoiceTD3 . $GLEntriesTD1 . '</tr>', + // $CreditInvoiceTD1 parameters: $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - //$CreditInvoiceFormatString parameters - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - //$PreviewInvoiceFormatString parameters - $RootPath, + // $PreviewInvoiceTD3 parameters: $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], - $RootPath, - $RootPath, $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - //Parameter for string for GL Trans Inquiries - $RootPath, + // $GLEntriesTD1 parameters: $myrow['type'], $myrow['transno']); - } else { //user does not have privileges to see GL inquiry stuff - printf($BaseFormatString . $CreditInvoiceFormatString . $PreviewInvoiceFormatString . '</tr>', - //BaseFormatString parameters - $myrow['typename'], + } else {// No permission to view GL entries. + printf($BaseTD10 . $CreditInvoiceTD1 . $PreviewInvoiceTD3 . '<td> </td></tr>', + // $CreditInvoiceTD1 parameters: $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - //CreditInvoiceFormatString parameters - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - //$PreviewInvoiceFormatString parameters - $RootPath, + // $PreviewInvoiceTD3 parameters: $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], - $RootPath, - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images'); + $myrow['transno']); + } - } elseif($myrow['type']==10) { /*its an invoice but not high enough priveliges to credit it */ - - printf($BaseFormatString . - $PreviewInvoiceFormatString . - '</tr>', - //$BaseFormatString parameters - $myrow['typename'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - //$PreviewInvoiceFormatString parameters - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - $RootPath, + printf($BaseTD10 . '<td> </td>' . $PreviewInvoiceTD3 . '<td> </td></tr>', + // $PreviewInvoiceTD3 parameters: + $myrow['transno'], $PrintCustomerTransactionScript, $myrow['transno'], - $RootPath, - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images'); + $myrow['transno']); } elseif ($myrow['type']==11) { /*its a credit note */ - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ - printf($BaseFormatString . - $PreviewCreditFormatString . - '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="' .$RootPath .'/css/' . $Theme .'/images/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> - <td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <a><img src="' .$RootPath.'/css/'.$Theme.'/images/gl.png" title="' . _('View the GL Entries') . '" alt="" /></a></td></tr>', - //$BaseFormatString parameters - $myrow['typename'], + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { + printf($BaseTD10 . $AllocationTD1 . $PreviewCreditTD3 . $GLEntriesTD1 . '</tr>', + // $AllocationTD1 parameters: + $myrow['id'], + // $PreviewCreditTD3 parameters: $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - //$PreviewCreditFormatString parameters - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], - $RootPath, - $RootPath, $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - // hand coded format string for Allocations and GLTrans Inquiry parameters - $RootPath, - $myrow['id'], - $RootPath, + // $GLEntriesTD1 parameters: $myrow['type'], $myrow['transno']); - } else { - printf($BaseFormatString . - $PreviewCreditFormatString . - '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="%s/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> - </tr>', - $myrow['typename'], + + } else {// No permission to view GL entries. + printf($BaseTD10 . $AllocationTD1 . $PreviewCreditTD3 . '<td> </td></tr>', + // $AllocationTD1 parameters: + $myrow['id'], + // $PreviewCreditTD3 parameters: $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - //$PreviewCreditFormatString parameters - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], - $RootPath, - $RootPath, - $myrow['transno'], - $RootPath.'/css/'.$Theme.'/images', - //Parameters for hand coded string to show allocations - $RootPath, - $myrow['id'], - $RootPath.'/css/'.$Theme.'/images'); + $myrow['transno']); + } } elseif ($myrow['type']==12 AND $myrow['totalamount']<0) { /*its a receipt which could have an allocation*/ //If security token 8 in the allowed page security tokens then assumed ok for GL trans inquiries - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ - printf($BaseFormatString . - '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="' .$RootPath . '/css/' . $Theme .'/images/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> - <td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <img src="' .$RootPath . '/css/' . $Theme .'/images/gl.png" title="' . _('View the GL Entries') . '" alt="" /></a></td> - </tr>', - $myrow['typename'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - $RootPath, + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { + printf($BaseTD10 . $AllocationTD1 . '<td> </td><td> </td><td> </td>' . $GLEntriesTD1 . '</tr>', + // $AllocationTD1 parameters: $myrow['id'], - $RootPath, + // $GLEntriesTD1 parameters: $myrow['type'], $myrow['transno']); - } else { //no permission for GLTrans Inquiries - printf($BaseFormatString . - '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="' .$RootPath . '/css/' . $Theme .'/images/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> - </tr>', - $myrow['typename'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - $RootPath, + + } else {// No permission to view GL entries. + printf($BaseTD10 . $AllocationTD1 . '<td> </td><td> </td><td> </td><td> </td></tr>', + // $AllocationTD1 parameters: $myrow['id']); + } } elseif ($myrow['type']==12 AND $myrow['totalamount']>0) { /*its a negative receipt */ //If security token 8 in the allowed page security tokens then assumed ok for GL trans inquiries - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ - printf($BaseFormatString . - '<td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <a></td></tr>', - $myrow['typename'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - $RootPath, + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { + printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td>' . $GLEntriesTD1 . '</tr>', + // $GLEntriesTD1 parameters: $myrow['type'], $myrow['transno']); - } else { //no permission for GLTrans Inquiries - printf($BaseFormatString . '<td></tr>', - $myrow['typename'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces'])); + + } else {// No permission to view GL entries. + printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td><td> </td></tr>' + ); + } } else { //If security token 8 in the allowed page security tokens then assumed ok for GL trans inquiries - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ - printf($BaseFormatString . - '<td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <a></td></tr>', - $myrow['typename'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), - $RootPath, + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { + printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td>' . $GLEntriesTD1 . '</tr>', + // $GLEntriesTD1 parameters: $myrow['type'], $myrow['transno']); + } else { - printf($BaseFormatString . '</tr>', - $myrow['typename'], - $myrow['transno'], - ConvertSQLDate($myrow['trandate']), - $myrow['branchcode'], - $myrow['reference'], - $myrow['invtext'], - $myrow['order_'], - locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces'])); + printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td><td> </td></tr>' + ); } } @@ -554,4 +407,4 @@ echo '</table>'; include('includes/footer.inc'); -?> \ No newline at end of file +?> Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-13 18:14:57 UTC (rev 6812) +++ trunk/doc/Change.log 2014-08-14 04:24:48 UTC (rev 6813) @@ -1,5 +1,6 @@ webERP Change Log +13/08/14 RChacon: In CustomerInquiry.php: Adds class ascending and reorganizes columns Date, Type, Number and Reference; Regroups table-datacel format-strings, completes the datacel quantity by table-row; makes translatable the systypes.typename. 12/08/14 RChacon: In SupplierInquiry.php: makes the field systypes.typename be translatable. 12/08/14 RChacon: In Z_poRebuildDefault.php: extends title, improves comments, sets file to pot, updates $FilesToInclude, renames old pot file to bak extension. Minor improvements. 08/08/14 Andrew Galuski: Add SQL and maintenance screens for Location based security. added new report aged controlled stock. additional scripts to follow as time allows |
From: <dai...@us...> - 2014-08-14 08:45:48
|
Revision: 6815 http://sourceforge.net/p/web-erp/reponame/6815 Author: daintree Date: 2014-08-14 08:45:43 +0000 (Thu, 14 Aug 2014) Log Message: ----------- Rafael: DatabaseTranslations.php for translating systypes Modified Paths: -------------- trunk/doc/Change.log Added Paths: ----------- trunk/includes/DatabaseTranslations.php Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-14 05:21:05 UTC (rev 6814) +++ trunk/doc/Change.log 2014-08-14 08:45:43 UTC (rev 6815) @@ -1,5 +1,6 @@ webERP Change Log +13/08/14 RChacon: includes/DatabaseTranslations.php used to store the fields of tables that are used from the database so that they can be translated in particular systypes for the types of transactions invoice credit note payment receipt etc. Can be extended for scripts and other tables where the data from the table is static and used to display 13/08/14 RChacon: In CustomerInquiry.php: Adds class ascending and reorganizes columns Date, Type, Number and Reference; Regroups table-datacel format-strings, completes the datacel quantity by table-row; makes translatable the systypes.typename. 12/08/14 RChacon: In SupplierInquiry.php: makes the field systypes.typename be translatable. 12/08/14 RChacon: In Z_poRebuildDefault.php: extends title, improves comments, sets file to pot, updates $FilesToInclude, renames old pot file to bak extension. Minor improvements. Added: trunk/includes/DatabaseTranslations.php =================================================================== --- trunk/includes/DatabaseTranslations.php (rev 0) +++ trunk/includes/DatabaseTranslations.php 2014-08-14 08:45:43 UTC (rev 6815) @@ -0,0 +1,60 @@ +<?php +/* $Id: DatabaseTranslations.php 6651 2014-08-13 19:52:39Z rchacon $*/ +/******************************************************************************* +The script install/DatabaseTranslations.php is a locale language file for the +contents of the fields in the database. The purpose of this file is to translate +the database fields that appears in screens and reports. This script is only +used at the time that the system default language file is language file is +rebuilt. RChacon. +*******************************************************************************/ + +// scripts.description: +// RChacon: It could be taken from each php script? + +// securityroles.secrolename: +// RChacon: It can be directly modified by the user. + +// securitytokens.tokenname: +// RChacon: It can be directly modified by the user. + +// systypes.typename: +$systypes_typename[0] = _('Journal - GL'); +$systypes_typename[1] = _('Payment - GL'); +$systypes_typename[2] = _('Receipt - GL'); +$systypes_typename[3] = _('Standing Journal'); +$systypes_typename[10] = _('Sales Invoice'); +$systypes_typename[11] = _('Credit Note'); +$systypes_typename[12] = _('Receipt'); +$systypes_typename[15] = _('Journal - Debtors'); +$systypes_typename[16] = _('Location Transfer'); +$systypes_typename[17] = _('Stock Adjustment'); +$systypes_typename[18] = _('Purchase Order'); +$systypes_typename[19] = _('Picking List'); +$systypes_typename[20] = _('Purchase Invoice'); +$systypes_typename[21] = _('Debit Note'); +$systypes_typename[22] = _('Creditors Payment'); +$systypes_typename[23] = _('Creditors Journal'); +$systypes_typename[25] = _('Purchase Order Delivery'); +$systypes_typename[26] = _('Work Order Receipt'); +$systypes_typename[28] = _('Work Order Issue'); +$systypes_typename[29] = _('Work Order Variance'); +$systypes_typename[30] = _('Sales Order'); +$systypes_typename[31] = _('Shipment Close'); +$systypes_typename[32] = _('Contract Close'); +$systypes_typename[35] = _('Cost Update'); +$systypes_typename[36] = _('Exchange Difference'); +$systypes_typename[37] = _('Tenders'); +$systypes_typename[38] = _('Stock Requests'); +$systypes_typename[40] = _('Work Order'); +$systypes_typename[41] = _('Asset Addition'); +$systypes_typename[42] = _('Asset Category Change'); +$systypes_typename[43] = _('Delete w/down asset'); +$systypes_typename[44] = _('Depreciation'); +$systypes_typename[49] = _('Import Fixed Assets'); +$systypes_typename[50] = _('Opening Balance'); +$systypes_typename[500] = _('Auto Debtor Number'); + +// General purpose: +$General_purpose = _('Default'); + +?> |
From: <dai...@us...> - 2014-08-14 09:12:42
|
Revision: 6816 http://sourceforge.net/p/web-erp/reponame/6816 Author: daintree Date: 2014-08-14 09:12:29 +0000 (Thu, 14 Aug 2014) Log Message: ----------- Kelo: fix SupplierBalsAtPeriodEnd Modified Paths: -------------- trunk/SupplierBalsAtPeriodEnd.php trunk/doc/Change.log Modified: trunk/SupplierBalsAtPeriodEnd.php =================================================================== --- trunk/SupplierBalsAtPeriodEnd.php 2014-08-14 08:45:43 UTC (rev 6815) +++ trunk/SupplierBalsAtPeriodEnd.php 2014-08-14 09:12:29 UTC (rev 6816) @@ -77,8 +77,7 @@ $FXBalance = $SupplierBalances['fxbalance'] - $SupplierBalances['fxafterdatetrans']; if (ABS($Balance)>0.009 OR ABS($FXBalance)>0.009) { - - $DisplayBalance = locale_number_format($SupplierBalances['balance'] - $SupplierBalances['afterdatetrans'],$_SESSION['CompanyRecord']['decimalplaces']); + $DisplayBalance = locale_number_format($SupplierBalances['balance'] - $SupplierBalances['afterdatetrans'] + $SupplierBalances['afterdatediffonexch'],$_SESSION['CompanyRecord']['decimalplaces']); $DisplayFXBalance = locale_number_format($SupplierBalances['fxbalance'] - $SupplierBalances['fxafterdatetrans'],$SupplierBalances['currdecimalplaces']); $TotBal += $Balance; Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-14 08:45:43 UTC (rev 6815) +++ trunk/doc/Change.log 2014-08-14 09:12:29 UTC (rev 6816) @@ -1,5 +1,6 @@ webERP Change Log +13/08/14 kelo: SupplierBalsAtPeriodEnd.php fix calculation to take into account fx differences on after date transactions 13/08/14 RChacon: includes/DatabaseTranslations.php used to store the fields of tables that are used from the database so that they can be translated in particular systypes for the types of transactions invoice credit note payment receipt etc. Can be extended for scripts and other tables where the data from the table is static and used to display 13/08/14 RChacon: In CustomerInquiry.php: Adds class ascending and reorganizes columns Date, Type, Number and Reference; Regroups table-datacel format-strings, completes the datacel quantity by table-row; makes translatable the systypes.typename. 12/08/14 RChacon: In SupplierInquiry.php: makes the field systypes.typename be translatable. |
From: <rc...@us...> - 2014-08-14 22:27:36
|
Revision: 6819 http://sourceforge.net/p/web-erp/reponame/6819 Author: rchacon Date: 2014-08-14 22:27:32 +0000 (Thu, 14 Aug 2014) Log Message: ----------- In SupplierInquiry.php: Reorganizes columns Date, Type, Number, Reference and Comments, and regroups table-datacel format-strings as in CustomerInquiry.php code. Modified Paths: -------------- trunk/CustomerInquiry.php trunk/SupplierInquiry.php trunk/doc/Change.log Modified: trunk/CustomerInquiry.php =================================================================== --- trunk/CustomerInquiry.php 2014-08-14 22:21:48 UTC (rev 6818) +++ trunk/CustomerInquiry.php 2014-08-14 22:27:32 UTC (rev 6819) @@ -212,12 +212,12 @@ echo '<table class="selection"> <tr> - <th class="ascending">• ' . _('Date') . '</th> - <th class="ascending">• ' . _('Type') . '</th> - <th class="ascending">• ' . _('Number') . '</th> - <th class="ascending">• ' . _('Reference') . '</th> + <th class="ascending">' . _('Date') . '</th> + <th class="ascending">' . _('Type') . '</th> + <th class="ascending">' . _('Number') . '</th> + <th class="ascending">' . _('Reference') . '</th> + <th>' . _('Comments') . '</th> <th>' . _('Branch') . '</th> - <th>' . _('Comments') . '</th> <th>' . _('Order') . '</th> <th>' . _('Total') . '</th> <th>' . _('Allocated') . '</th> @@ -255,8 +255,8 @@ <td>' . _($myrow['typename']) . '</td> <td class="number">' . $myrow['transno'] . '</td> <td>' . $myrow['reference'] . '</td> + <td>' . $myrow['invtext'] . '</td> <td>' . $myrow['branchcode'] . '</td> - <td style="width:200px">' . $myrow['invtext'] . '</td> <td class="number">' . $myrow['order_'] . '</td> <td class="number">' . locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']) . '</td> <td class="number">' . locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']) . '</td> @@ -290,7 +290,7 @@ _('Click to email the credit note') . '"><img alt="" src="' . $RootPath . '/css/' . $Theme . '/images/email.gif" /> ' . _('Email') . '</a></td>'; - $GLEntriesTD1 = '<td><a href="' . $RootPath . '/GLTransInquiry.php?TypeID=%s&TransNo=%s" title="' . + $GLEntriesTD1 = '<td><a href="' . $RootPath . '/GLTransInquiry.php?TypeID=%s&TransNo=%s" target="_blank" title="' . _('Click to view the GL entries') . '"><img alt="" src="' . $RootPath . '/css/' . $Theme . '/images/gl.png" width="16" /> ' . _('GL Entries') . '</a></td>'; Modified: trunk/SupplierInquiry.php =================================================================== --- trunk/SupplierInquiry.php 2014-08-14 22:21:48 UTC (rev 6818) +++ trunk/SupplierInquiry.php 2014-08-14 22:27:32 UTC (rev 6819) @@ -3,7 +3,7 @@ include('includes/session.inc'); $Title = _('Supplier Inquiry'); -$ViewTopic = 'AccountsPayable'; /* RChacon: Is there any content for Supplier Inquiry? */ +$ViewTopic = 'AccountsPayable';// Filename in ManualContents.php's TOC./* RChacon: Is there any content for Supplier Inquiry? */ $BookMark = 'AccountsPayable';// Anchor's id in the manual's html document. include('includes/header.inc'); @@ -11,7 +11,7 @@ // always figure out the SQL required from the inputs available -if(!isset($_GET['SupplierID']) AND !isset($_SESSION['SupplierID'])){ +if(!isset($_GET['SupplierID']) AND !isset($_SESSION['SupplierID'])) { echo '<br />' . _('To display the enquiry a Supplier must first be selected from the Supplier selection screen') . '<br /> <div class="centre"> @@ -20,13 +20,13 @@ include('includes/footer.inc'); exit; } else { - if (isset($_GET['SupplierID'])){ + if (isset($_GET['SupplierID'])) { $_SESSION['SupplierID'] = $_GET['SupplierID']; } $SupplierID = $_SESSION['SupplierID']; } -if (isset($_GET['FromDate'])){ +if (isset($_GET['FromDate'])) { $_POST['TransAfterDate']=$_GET['FromDate']; } if (!isset($_POST['TransAfterDate']) OR !Is_Date($_POST['TransAfterDate'])) { @@ -79,7 +79,7 @@ $SupplierResult = DB_query($SQL, $db, $ErrMsg, $DbgMsg); -if (DB_num_rows($SupplierResult) == 0){ +if (DB_num_rows($SupplierResult) == 0) { /*Because there is no balance - so just retrieve the header information about the Supplier - the choice is do one query to get the balance and transactions for those Suppliers who have a balance and two queries for those who don't have a balance OR always do two queries - I opted for the former */ @@ -107,7 +107,7 @@ $SupplierRecord = DB_fetch_array($SupplierResult); -if ($NIL_BALANCE == True){ +if ($NIL_BALANCE == True) { $SupplierRecord['balance'] = 0; $SupplierRecord['due'] = 0; $SupplierRecord['overdue1'] = 0; @@ -122,13 +122,13 @@ _('Terms') . ': ' . $SupplierRecord['terms'] . '</p>'; -if (isset($_GET['HoldType']) AND isset($_GET['HoldTrans'])){ +if (isset($_GET['HoldType']) AND isset($_GET['HoldTrans'])) { - if ($_GET['HoldStatus'] == _('Hold')){ + if ($_GET['HoldStatus'] == _('Hold')) { $SQL = "UPDATE supptrans SET hold=1 WHERE type='" . $_GET['HoldType'] . "' AND transno='" . $_GET['HoldTrans'] . "'"; - } elseif ($_GET['HoldStatus'] == _('Release')){ + } elseif ($_GET['HoldStatus'] == _('Release')) { $SQL = "UPDATE supptrans SET hold=0 WHERE type='" . $_GET['HoldType'] . "' AND transno='" . $_GET['HoldTrans'] . "'"; @@ -140,13 +140,13 @@ } -echo '<table width="90%" class="selection"> - <tr><th>' . _('Total Balance') . '</th> - <th>' . _('Current') . '</th> - <th>' . _('Now Due') . '</th> - <th>' . $_SESSION['PastDueDays1'] . '-' . $_SESSION['PastDueDays2'] . ' ' . _('Days Overdue') . '</th> - <th>' . _('Over') . ' ' . $_SESSION['PastDueDays2'] . ' ' . _('Days Overdue') . '</th> - </tr>'; +echo '<table class="selection"> + <tr><th>' . _('Total Balance') . '</th> + <th>' . _('Current') . '</th> + <th>' . _('Now Due') . '</th> + <th>' . $_SESSION['PastDueDays1'] . '-' . $_SESSION['PastDueDays2'] . ' ' . _('Days Overdue') . '</th> + <th>' . _('Over') . ' ' . $_SESSION['PastDueDays2'] . ' ' . _('Days Overdue') . '</th> + </tr>'; echo '<tr> <td class="number">' . locale_number_format($SupplierRecord['balance'],$SupplierRecord['currdecimalplaces']) . '</td> @@ -195,7 +195,7 @@ $TransResult = DB_query($SQL, $db, $ErrMsg, $DbgMsg); -if (DB_num_rows($TransResult) == 0){ +if (DB_num_rows($TransResult) == 0) { echo '<br /><div class="centre">' . _('There are no transactions to display since') . ' ' . $_POST['TransAfterDate']; echo '</div>'; include('includes/footer.inc'); @@ -204,35 +204,34 @@ /*show a table of the transactions returned by the SQL */ -echo '<table width="90%" class="selection">'; -$TableHeader = '<tr> - <th class="ascending">• ' . _('Type') . '</th> - <th class="ascending">• ' . _('Number') . '</th> - <th class="ascending">• ' . _('Reference') . '</th> - <th class="ascending">• ' . _('Date') . '</th> - <th class="ascending">• ' . _('Total') . '</th> - <th class="ascending">• ' . _('Allocated') . '</th> - <th class="ascending">• ' . _('Balance') . '</th> - <th class="ascending">• ' . _('Comments') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - </tr>'; -echo $TableHeader; +echo '<table width="90%" class="selection"> + <tr> + <th class="ascending">' . _('Date') . '</th> + <th class="ascending">' . _('Type') . '</th> + <th class="ascending">' . _('Number') . '</th> + <th class="ascending">' . _('Reference') . '</th> + <th class="ascending">' . _('Comments') . '</th> + <th class="ascending">' . _('Total') . '</th> + <th class="ascending">' . _('Allocated') . '</th> + <th class="ascending">' . _('Balance') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + </tr>'; $j = 1; -$k = 0; //row colour counter +$k = 0;// Row colour counter. while ($myrow=DB_fetch_array($TransResult)) { - if ($myrow['hold'] == 0 AND $myrow['settled'] == 0){ + if ($myrow['hold'] == 0 AND $myrow['settled'] == 0) { $HoldValue = _('Hold'); } elseif ($myrow['settled'] == 1) { $HoldValue = ''; }else { $HoldValue = _('Release'); } - if ($myrow['hold'] == 1){ + if ($myrow['hold'] == 1) { // echo "<tr bgcolor='#DD99BB'>"; - }elseif ($k == 1){ + }elseif ($k == 1) { echo '<tr class="EvenTableRows">'; $k = 0; } else { @@ -242,43 +241,53 @@ $FormatedTranDate = ConvertSQLDate($myrow['trandate']); - if ($myrow['type'] == 20){ /*Show a link to allow GL postings to be viewed but no link to allocate */ + // All table-row (tag tr) must have 10 table-datacells (tag td). - if ($_SESSION['CompanyRecord']['gllink_creditors'] == True){ - if ($myrow['totalamount'] - $myrow['allocated'] == 0){ + $BaseTD8 = '<td>' . ConvertSQLDate($myrow['trandate']) . '</td> + <td>' . _($myrow['typename']) . '</td> + <td class="number">' . $myrow['transno'] . '</td> + <td>' . $myrow['suppreference'] . '</td> + <td>' . $myrow['transtext'] . '</td> + <td class="number">' . locale_number_format($myrow['totalamount'],$SupplierRecord['currdecimalplaces']) . '</td> + <td class="number">' . locale_number_format($myrow['allocated'],$SupplierRecord['currdecimalplaces']) . '</td> + <td class="number">' . locale_number_format($myrow['totalamount']-$myrow['allocated'],$SupplierRecord['currdecimalplaces']) . '</td>'; - /*The trans is settled so don't show option to hold */ + $PaymentTD1 = '<td><a href="' . $RootPath . '/PaymentAllocations.php?SuppID=%s&InvID=%s" title="' . + _('Click to view payments') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/money_delete.png" width="16"/> ' . _('Payments') . '</a></td>'; - echo '<td>' . _($myrow['typename']) . '</td> - <td class="number">' . $myrow['transno'] . '</td> - <td>' . $myrow['suppreference'] . '</td> - <td>' . ConvertSQLDate($myrow['trandate']) . '</td> - <td class="number">' . locale_number_format($myrow['totalamount'],$SupplierRecord['currdecimalplaces']) . '</td> - <td class="number">' . locale_number_format($myrow['allocated'],$SupplierRecord['currdecimalplaces']) . '</td> - <td class="number">' . locale_number_format($myrow['totalamount']-$myrow['allocated'],$SupplierRecord['currdecimalplaces']) . '</td> - <td>' . $myrow['transtext'] . '</td> - <td><a href="' . $RootPath . '/PaymentAllocations.php?SuppID=' . $myrow['supplierno'] . '&InvID=' . $myrow['suppreference'] .'">' . _('View Payments') . '</a></td> - <td><a target="_blank" href="' . $RootPath . '/GLTransInquiry.php?TypeID=' . $myrow['type'] . '&TransNo=' . $myrow['transno'] .'">' . _('View GL Postings') . '</a></td> - </tr>'; +/* To do: $HoldValueTD1*/ + + $AllocationTD1 = '<td><a href="' . $RootPath . '/SupplierAllocations.php?AllocTrans=%s" title="' . + _('Click to allocate funds') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/allocation.png" /> ' . _('Allocation') . '</a></td>'; + + $GLEntriesTD1 = '<td><a href="' . $RootPath . '/GLTransInquiry.php?TypeID=%s&TransNo=%s" target="_blank" title="' . + _('Click to view the GL entries') . '"><img alt="" src="' . $RootPath . + '/css/' . $Theme . '/images/gl.png" width="16" /> ' . _('GL Entries') . '</a></td>'; + + if ($myrow['type'] == 20) { /*Show a link to allow GL postings to be viewed but no link to allocate */ + + if ($_SESSION['CompanyRecord']['gllink_creditors'] == True) { + if ($myrow['totalamount'] - $myrow['allocated'] == 0) { + /*The trans is settled so don't show option to hold */ + printf($BaseTD8 . $PaymentTD1 . $GLEntriesTD1 . '</tr>', + // $PaymentTD1 parameters: + $myrow['supplierno'], + $myrow['suppreference'], + // $GLEntriesTD1 parameters: + $myrow['type'], + $myrow['transno']); + } else { - echo '<td>' . _($myrow['typename']) . '</td> - <td class="number">' . $myrow['transno'] . '</td> - <td>' . $myrow['suppreference'] . '</td> - <td>' . ConvertSQLDate($myrow['trandate']) . '</td> - <td class="number">' . locale_number_format($myrow['totalamount'],$SupplierRecord['currdecimalplaces']) . '</td> - <td class="number">' .locale_number_format($myrow['allocated'],$SupplierRecord['currdecimalplaces']) . '</td> - <td class="number">' . locale_number_format($myrow['totalamount'] - $myrow['allocated'],$SupplierRecord['currdecimalplaces']) . '</td> - <td>' . $myrow['transtext'] . '</td>'; - $AuthSQL="SELECT offhold FROM purchorderauth WHERE userid='" . $_SESSION['UserID'] . "' AND currabrev='" . $SupplierRecord['currcode']."'"; - $AuthResult=DB_query($AuthSQL, $db); - $AuthRow=DB_fetch_array($AuthResult); + printf($BaseTD8); if ($AuthRow[0]==0) { echo '<td><a href="' .htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?HoldType=' . $myrow['type'] . '&HoldTrans=' . $myrow['transno']. '&HoldStatus=' . $HoldValue . '&FromDate=' . $_POST['TransAfterDate'].'">' . $HoldValue . '</a></td>'; } else { @@ -288,103 +297,42 @@ echo '<td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8'). '?HoldType=' . $myrow['type'] .'&HoldTrans=' . $myrow['transno'] . '&HoldStatus=' . $HoldValue . '&FromDate=' . $_POST['TransAfterDate'] .'">' . $HoldValue . '</a></td>'; } } - echo '<td><a href="' . $RootPath . '/GLTransInquiry.php?TypeID=' . $myrow['type'] . '&TransNo=' . $myrow['transno'] . - '" target="_blank">' ._('View GL Postings') . '</a></td></tr>'; + printf($GLEntriesTD1 . '</tr>', + // $GLEntriesTD1 parameters: + $myrow['type'], + $myrow['transno']); + } } else { + if ($myrow['totalamount'] - $myrow['allocated'] == 0) { + /*The trans is settled so don't show option to hold */ + printf($BaseTD8 . '<td> </td><td> </td></tr>'); - if ($myrow['totalamount'] - $myrow['allocated'] == 0){ - - /*The trans is settled so don't show option to hold */ - - printf('<td>%s</td> - <td class="number">%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td>%s</td> - <td> </td> - <td> </td> - </tr>', - _($myrow['typename']), - $myrow['transno'], - $myrow['suppreference'], - ConvertSQLDate($myrow['trandate']), - locale_number_format($myrow['totalamount'],$SupplierRecord['currdecimalplaces']), - locale_number_format($myrow['allocated'],$SupplierRecord['currdecimalplaces']), - locale_number_format($myrow['totalamount'] - $myrow['allocated'],$SupplierRecord['currdecimalplaces']), - $myrow['transtext']); - } else { - echo ' <td>' . _($myrow['typename']) . '</td> - <td class="number">' . $myrow['transno'] . '</td> - <td>' . $myrow['suppreference'] . '</td> - <td>' . ConvertSQLDate($myrow['trandate']) . '</td> - <td class="number">' . locale_number_format($myrow['totalamount'], $SupplierRecord['currdecimalplaces']) . '</td> - <td class="number">' . locale_number_format($myrow['allocated'], $SupplierRecord['currdecimalplaces']) . '</td> - <td class="number">' . locale_number_format($myrow['totalamount']-$myrow['allocated'], $SupplierRecord['currdecimalplaces']) . '</td> - <td align=left>' . $myrow['transtext'] . '</td> - <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES,'UTF-8') . '/PaymentAllocations.php?SuppID=' . - $myrow['type'] . '&InvID=' . $myrow['transno'] . '">' . _('View Payments') . '</a></td> - <td><a href="' . $HoldValue . '?HoldType=' . $_POST['TransAfterDate'] . '&HoldTrans=' . $HoldValue . '&HoldStatus=' . - $RootPath . '&FromDate='. $myrow['supplierno'] . '">' . $myrow['suppreference'] . '</a></td> - </tr>'; + printf($BaseTD8); + echo ' + <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES,'UTF-8') . '/PaymentAllocations.php?SuppID=' . + $myrow['type'] . '&InvID=' . $myrow['transno'] . '">' . _('View Payments') . '</a></td> + <td><a href="' . $HoldValue . '?HoldType=' . $_POST['TransAfterDate'] . '&HoldTrans=' . $HoldValue . '&HoldStatus=' . + $RootPath . '&FromDate='. $myrow['supplierno'] . '">' . $myrow['suppreference'] . '</a></td></tr>'; } } } else { /*its a credit note or a payment */ - if ($_SESSION['CompanyRecord']['gllink_creditors'] == True){ + if ($_SESSION['CompanyRecord']['gllink_creditors'] == True) { + printf($BaseTD8 . $AllocationTD1 . $GLEntriesTD1 . '</tr>', + // $AllocationTD1 parameters: + $myrow['id'], + // $GLEntriesTD1 parameters: + $myrow['type'], + $myrow['transno']); - printf('<td>%s</td> - <td class="number">%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td>%s</td> - <td><a href="%s/SupplierAllocations.php?AllocTrans=%s">' . _('View Allocations') . '</a></td> - <td><a target="_blank" href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Postings') . '</a></td> - </tr>', - _($myrow['typename']), - $myrow['transno'], - $myrow['suppreference'], - ConvertSQLDate($myrow['trandate']), - locale_number_format($myrow['totalamount'],$SupplierRecord['currdecimalplaces']), - locale_number_format($myrow['allocated'],$SupplierRecord['currdecimalplaces']), - locale_number_format($myrow['totalamount']-$myrow['allocated'],$SupplierRecord['currdecimalplaces']), - $myrow['transtext'], - $RootPath, - $myrow['id'], - $RootPath, - $myrow['type'], - $myrow['transno'] ); + } else { /*Not linked to GL */ + printf($BaseTD8 . $AllocationTD1 . '<td> </td></tr>', + // $AllocationTD1 parameters: + $myrow['id']); - } else { /*Not linked to GL */ - printf('<td>%s</td> - <td class="number">%s</td> - <td>%s</td> - <td>%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td class="number">%s</td> - <td>%s</td> - <td><a href="%s/SupplierAllocations.php?AllocTrans=%s">' . _('View Allocations') . '</a></td> - <td> </td> - </tr>', - _($myrow['typename']), - $myrow['transno'], - $myrow['suppreference'], - ConvertSQLDate($myrow['trandate']), - locale_number_format($myrow['totalamount'],$SupplierRecord['currdecimalplaces']), - locale_number_format($myrow['allocated'],$SupplierRecord['currdecimalplaces']), - locale_number_format($myrow['totalamount'] - $myrow['allocated'],$SupplierRecord['currdecimalplaces']), - $myrow['transtext'], - $RootPath, - $myrow['id']); } }// End of page full new headings if }// End of while loop Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-14 22:21:48 UTC (rev 6818) +++ trunk/doc/Change.log 2014-08-14 22:27:32 UTC (rev 6819) @@ -1,5 +1,6 @@ webERP Change Log +14/08/14 RChacon: In SupplierInquiry.php: Reorganizes columns Date, Type, Number, Reference and Comments, and regroups table-datacel format-strings as in CustomerInquiry.php code. 13/08/14 kelo: SupplierBalsAtPeriodEnd.php fix calculation to take into account fx differences on after date transactions 13/08/14 RChacon: includes/DatabaseTranslations.php used to store the fields of tables that are used from the database so that they can be translated in particular systypes for the types of transactions invoice credit note payment receipt etc. Can be extended for scripts and other tables where the data from the table is static and used to display 13/08/14 RChacon: In CustomerInquiry.php: Adds class ascending and reorganizes columns Date, Type, Number and Reference; Regroups table-datacel format-strings, completes the datacel quantity by table-row; makes translatable the systypes.typename. |
From: <rc...@us...> - 2014-08-15 00:34:26
|
Revision: 6820 http://sourceforge.net/p/web-erp/reponame/6820 Author: rchacon Date: 2014-08-15 00:34:13 +0000 (Fri, 15 Aug 2014) Log Message: ----------- In CustomerInquiry.php and SupplierInquiry.php makes translatable the systypes.typename. Modified Paths: -------------- trunk/CustomerAllocations.php trunk/SupplierAllocations.php trunk/doc/Change.log Modified: trunk/CustomerAllocations.php =================================================================== --- trunk/CustomerAllocations.php 2014-08-14 22:27:32 UTC (rev 6819) +++ trunk/CustomerAllocations.php 2014-08-15 00:34:13 UTC (rev 6820) @@ -1,22 +1,19 @@ <?php +/* $Id$*/ -/* $Id$*/ - -/* -Call this page with: +/* Call this page with: 1. A TransID to show the make up and to modify existing allocations. 2. A DebtorNo to show all outstanding receipts or credits yet to be allocated. 3. No parameters to show all outstanding credits and receipts yet to be allocated. */ -include('includes/DefineCustAllocsClass.php'); include('includes/session.inc'); $Title = _('Customer Receipt') . '/' . _('Credit Note Allocations'); - $ViewTopic= 'ARTransactions'; $BookMark = 'CustomerAllocations'; +include('includes/header.inc'); -include('includes/header.inc'); +include('includes/DefineCustAllocsClass.php'); include('includes/SQL_CommonFunctions.inc'); if ( isset($_POST['Cancel']) ) { @@ -26,10 +23,12 @@ if (isset($_POST['UpdateDatabase']) OR isset($_POST['RefreshAllocTotal'])) { if (!isset($_SESSION['Alloc'])) { - prnMsg(_('Allocations can not be processed again') . '. ' . - _('If you hit refresh on this page after having just processed an allocation') . ', ' . - _('try to use the navigation links provided rather than the back button') . ', ' . - _('to avoid this message in future'),'info'); + prnMsg( + _('Allocations can not be processed again') . '. ' . + _('If you hit refresh on this page after having just processed an allocation') . ', ' . + _('try to use the navigation links provided rather than the back button') . ', ' . + _('to avoid this message in future'), + 'info'); include('includes/footer.inc'); exit; } @@ -38,7 +37,7 @@ $TotalAllocated = 0; $TotalDiffOnExch = 0; - for ($AllocCounter=0;$AllocCounter < $_POST['TotalNumberOfAllocs']; $AllocCounter++) { + for ($AllocCounter=0; $AllocCounter < $_POST['TotalNumberOfAllocs']; $AllocCounter++) { // loop through amounts allocated using AllocnItm->ID for each record if (isset($_POST['Amt' . $AllocCounter])) { @@ -247,7 +246,7 @@ $_SESSION['Alloc']->DebtorNo = $myrow['debtorno']; $_SESSION['Alloc']->CustomerName = $myrow['name']; $_SESSION['Alloc']->TransType = $myrow['type']; - $_SESSION['Alloc']->TransTypeName = $myrow['typename']; + $_SESSION['Alloc']->TransTypeName = _($myrow['typename']); $_SESSION['Alloc']->TransNo = $myrow['transno']; $_SESSION['Alloc']->TransExRate = $myrow['rate']; $_SESSION['Alloc']->TransAmt = $myrow['total']; @@ -279,7 +278,7 @@ while ($myrow=DB_fetch_array($Result)) { $_SESSION['Alloc']->add_to_AllocsAllocn ($myrow['id'], - $myrow['typename'], + _($myrow['typename']), $myrow['transno'], ConvertSQLDate($myrow['trandate']), 0, @@ -321,7 +320,7 @@ while ($myrow=DB_fetch_array($Result)) { $DiffOnExchThisOne = ($myrow['amt']/$myrow['rate']) - ($myrow['amt']/$_SESSION['Alloc']->TransExRate); $_SESSION['Alloc']->add_to_AllocsAllocn ($myrow['id'], - $myrow['typename'], + _($myrow['typename']), $myrow['transno'], ConvertSQLDate($myrow['trandate']), $myrow['amt'], @@ -400,8 +399,8 @@ } echo '<td>' . $AllocnItem->TransType . '</td> - <td>' . $AllocnItem->TypeNo . '</td> - <td class="number">' . $AllocnItem->TransDate . '</td> + <td class="number">' . $AllocnItem->TypeNo . '</td> + <td>' . $AllocnItem->TransDate . '</td> <td class="number">' . locale_number_format($AllocnItem->TransAmount,$_SESSION['Alloc']->CurrDecimalPlaces) . '</td> <td class="number">' . locale_number_format($YetToAlloc,$_SESSION['Alloc']->CurrDecimalPlaces) . '</td>'; $j++; @@ -504,7 +503,7 @@ echo '<tr class="OddTableRows">';; $k++; } - echo '<td>' . $myrow['typename'] . '</td> + echo '<td>' . _($myrow['typename']) . '</td> <td>' . $myrow['name'] . '</td> <td>' . $myrow['debtorno'] . '</td> <td>' . $myrow['transno'] . '</td> @@ -597,7 +596,7 @@ $k++; } - echo '<td>' . $myrow['typename'] . '</td> + echo '<td>' . _($myrow['typename']) . '</td> <td>' . $myrow['name'] . '</td> <td>' . $myrow['debtorno'] . '</td> <td>' . $myrow['transno'] . '</td> Modified: trunk/SupplierAllocations.php =================================================================== --- trunk/SupplierAllocations.php 2014-08-14 22:27:32 UTC (rev 6819) +++ trunk/SupplierAllocations.php 2014-08-15 00:34:13 UTC (rev 6820) @@ -1,10 +1,8 @@ <?php +/* $Id$*/ -/* $Id$*/ +/* This page can be called with... -/* - This page can be called with... - 1. A SuppTrans TransNo and Type The page will then show potential allocations for the transaction called with, this page can be called from the supplier enquiry to show the make up and to modify @@ -18,12 +16,13 @@ allocated */ -include('includes/DefineSuppAllocsClass.php'); include('includes/session.inc'); - $Title = _('Supplier Payment') . '/' . _('Credit Note Allocations'); +$ViewTopic = 'ARTransactions';// Filename in ManualContents.php's TOC./* RChacon: To do ManualAPInquiries.html from ManualARInquiries.html */ +$BookMark = 'SupplierAllocations';// Anchor's id in the manual's html document. +include('includes/header.inc'); -include('includes/header.inc'); +include('includes/DefineSuppAllocsClass.php'); include('includes/SQL_CommonFunctions.inc'); echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/transactions.png" title="' . @@ -31,12 +30,12 @@ if (isset($_POST['UpdateDatabase']) OR isset($_POST['RefreshAllocTotal'])) { - //initialise no input errors assumed initially before we test - - $InputError = 0; - if (!isset($_SESSION['Alloc'])){ - prnMsg( _('Allocations can not be processed again') . '. ' . _('If you hit refresh on this page after having just processed an allocation') . ', ' . _('try to use the navigation links provided rather than the back button, to avoid this message in future'),'warn'); + prnMsg( + _('Allocations can not be processed again') . '. ' . + _('If you hit refresh on this page after having just processed an allocation') . ', ' . + _('try to use the navigation links provided rather than the back button, to avoid this message in future'), + 'warn'); include('includes/footer.inc'); exit; } @@ -46,6 +45,7 @@ AllocnItm->ID for each record of the array - and PHP sets the value of the form variable on a post*/ + $InputError = 0; $TotalAllocated = 0; $TotalDiffOnExch = 0; @@ -330,7 +330,7 @@ $_SESSION['Alloc']->SupplierID = $myrow['supplierno']; $_SESSION['Alloc']->SuppName = $myrow['suppname'];; $_SESSION['Alloc']->TransType = $myrow['type']; - $_SESSION['Alloc']->TransTypeName = $myrow['typename']; + $_SESSION['Alloc']->TransTypeName = _($myrow['typename']); $_SESSION['Alloc']->TransNo = $myrow['transno']; $_SESSION['Alloc']->TransExRate = $myrow['rate']; $_SESSION['Alloc']->TransAmt = $myrow['total']; @@ -364,7 +364,7 @@ while ($myrow=DB_fetch_array($Result)){ $_SESSION['Alloc']->add_to_AllocsAllocn ($myrow['id'], - $myrow['typename'], + _($myrow['typename']), $myrow['transno'], ConvertSQLDate($myrow['trandate']), $myrow['suppreference'], @@ -410,7 +410,7 @@ $DiffOnExchThisOne = ($myrow['amt']/$myrow['rate']) - ($myrow['amt']/$_SESSION['Alloc']->TransExRate); $_SESSION['Alloc']->add_to_AllocsAllocn ($myrow['id'], - $myrow['typename'], + _($myrow['typename']), $myrow['transno'], ConvertSQLDate($myrow['trandate']), $myrow['suppreference'], $myrow['amt'], $myrow['total'], @@ -486,7 +486,7 @@ $YetToAlloc = ($AllocnItem->TransAmount - $AllocnItem->PrevAlloc); echo '<td>' . $AllocnItem->TransType . '</td> - <td>' . $AllocnItem->TypeNo . '</td> + <td class="number">' . $AllocnItem->TypeNo . '</td> <td>' . $AllocnItem->TransDate . '</td> <td>' . $AllocnItem->SuppRef . '</td> <td class="number">' . locale_number_format($AllocnItem->TransAmount,$_SESSION['Alloc']->CurrDecimalPlaces) . '</td> @@ -594,7 +594,7 @@ <td class="number">%s</td> <td><a href="%sAllocTrans=%s">' . _('Allocate') . '</a></td> </tr>', - $myrow['typename'], + _($myrow['typename']), $myrow['suppname'], $myrow['transno'], ConvertSQLDate($myrow['trandate']), @@ -670,7 +670,7 @@ <td class="number">%s</td> <td><a href="%sAllocTrans=%s">' . _('Allocate') . '</a></td> </tr>', - $myrow['typename'], + _($myrow['typename']), $myrow['suppname'], $myrow['transno'], ConvertSQLDate($myrow['trandate']), Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-14 22:27:32 UTC (rev 6819) +++ trunk/doc/Change.log 2014-08-15 00:34:13 UTC (rev 6820) @@ -1,5 +1,6 @@ webERP Change Log +14/08/14 RChacon: In CustomerInquiry.php and SupplierInquiry.php makes translatable the systypes.typename. 14/08/14 RChacon: In SupplierInquiry.php: Reorganizes columns Date, Type, Number, Reference and Comments, and regroups table-datacel format-strings as in CustomerInquiry.php code. 13/08/14 kelo: SupplierBalsAtPeriodEnd.php fix calculation to take into account fx differences on after date transactions 13/08/14 RChacon: includes/DatabaseTranslations.php used to store the fields of tables that are used from the database so that they can be translated in particular systypes for the types of transactions invoice credit note payment receipt etc. Can be extended for scripts and other tables where the data from the table is static and used to display |
From: <rc...@us...> - 2014-08-15 20:25:06
|
Revision: 6822 http://sourceforge.net/p/web-erp/reponame/6822 Author: rchacon Date: 2014-08-15 20:24:57 +0000 (Fri, 15 Aug 2014) Log Message: ----------- Fixes double line feed in PDFQuotationPortrait.php reported by Arwan Galaya. Uniforms code between PDFQuotation.php and PDFQuotationPortrait.php. Modified Paths: -------------- trunk/PDFQuotation.php trunk/PDFQuotationPortrait.php trunk/doc/Change.log trunk/includes/PDFQuotationPageHeader.inc trunk/includes/PDFQuotationPortraitPageHeader.inc trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po Modified: trunk/PDFQuotation.php =================================================================== --- trunk/PDFQuotation.php 2014-08-15 00:58:02 UTC (rev 6821) +++ trunk/PDFQuotation.php 2014-08-15 20:24:57 UTC (rev 6822) @@ -1,6 +1,8 @@ <?php +/* $Id$*/ -/* $Id$*/ +/* Please note that addTextWrap prints a font-size-height further down than + addText and other functions.*/ include('includes/session.inc'); include('includes/SQL_CommonFunctions.inc'); @@ -112,10 +114,9 @@ include('includes/PDFStarter.php'); $pdf->addInfo('Title', _('Customer Quotation') ); $pdf->addInfo('Subject', _('Quotation') . ' ' . $_GET['QuotationNo']); -$FontSize=12; -$line_height=15; +$FontSize = 12; +$line_height = 12;// Recommended: $line_height = $x * $FontSize. - /* 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') . ' ' . @@ -142,20 +143,21 @@ /*Yes there are line items to start the ball rolling with a page header */ include('includes/PDFQuotationPageHeader.inc'); - $QuotationTotal =0; - $QuotationTotalEx=0; - $TaxTotal=0; + $QuotationTotal = 0; + $QuotationTotalEx = 0; + $TaxTotal = 0; while ($myrow2=DB_fetch_array($result)){ $ListCount ++; + $YPos -= $line_height;// Increment a line down for the next line item. + if ((mb_strlen($myrow2['narrative']) >200 AND $YPos-$line_height <= 75) OR (mb_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 */ include ('includes/PDFQuotationPageHeader.inc'); - } //end if need a new page headed up $DisplayQty = locale_number_format($myrow2['quantity'],$myrow2['decimalplaces']); @@ -191,40 +193,41 @@ $LineTotal = $SubTot + $TaxAmount; $DisplayTotal = locale_number_format($LineTotal,$myrow['currdecimalplaces']); - $FontSize=10; + $FontSize = 10;// Font size for the line item. - $LeftOvers = $pdf->addTextWrap($XPos+1,$YPos,100,$FontSize,$myrow2['stkcode']); - $LeftOvers = $pdf->addTextWrap(145,$YPos,295,$FontSize,$myrow2['description']); - $LeftOvers = $pdf->addTextWrap(420,$YPos,85,$FontSize,$DisplayQty,'right'); - $LeftOvers = $pdf->addTextWrap(485,$YPos,85,$FontSize,$DisplayPrice,'right'); + $LeftOvers = $pdf->addText($Left_Margin, $YPos+$FontSize, $FontSize, $myrow2['stkcode']); + $LeftOvers = $pdf->addText(145, $YPos+$FontSize, $FontSize, $myrow2['description']); + $LeftOvers = $pdf->addTextWrap(420, $YPos,85,$FontSize,$DisplayQty,'right'); + $LeftOvers = $pdf->addTextWrap(485, $YPos,85,$FontSize,$DisplayPrice,'right'); if ($DisplayDiscount > 0) { - $LeftOvers = $pdf->addTextWrap(535,$YPos,85,$FontSize,$DisplayDiscount,'right'); + $LeftOvers = $pdf->addTextWrap(535, $YPos,85,$FontSize,$DisplayDiscount,'right'); } - $LeftOvers = $pdf->addTextWrap(585,$YPos,85,$FontSize,$DisplayTaxClass,'right'); - $LeftOvers = $pdf->addTextWrap(650,$YPos,85,$FontSize,$DisplayTaxAmount,'right'); + $LeftOvers = $pdf->addTextWrap(585, $YPos,85,$FontSize,$DisplayTaxClass,'right'); + $LeftOvers = $pdf->addTextWrap(650, $YPos,85,$FontSize,$DisplayTaxAmount,'right'); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, $DisplayTotal,'right'); - // Print salesorderdetails.narrative - $line_height = 10;// Line height to print salesorderdetails.narrative - $LeftOvers = str_replace('\n', ' ', $myrow2['narrative']);// Get salesorders.comments and replace line feed character. '<br />' works? + // Prints salesorderdetails.narrative: + $FontSize2 = $FontSize*0.8;// Font size to print salesorderdetails.narrative. + $Width2 = $Page_Width-$Right_Margin-145;// Width to print salesorderdetails.narrative. + $LeftOvers = trim($myrow2['narrative']); + //********** + $LeftOvers = str_replace('\n', ' ', $LeftOvers);// Replaces line feed character. $LeftOvers = str_replace('\r', '', $LeftOvers);// Delete carriage return character $LeftOvers = str_replace('\t', '', $LeftOvers);// Delete tabulator character - while (mb_strlen($LeftOvers) > 0) { - $YPos -= $line_height;// Suggestion: $line_height = $FontSize; - if ($YPos < ($Bottom_Margin)) {// Begin new page + //********** + while (mb_strlen($LeftOvers) > 1) { + $YPos -= $FontSize2; + if ($YPos < ($Bottom_Margin)) {// Begins new page. include ('includes/PDFQuotationPageHeader.inc'); } - $LeftOvers = $pdf->addTextWrap(40, $YPos, 772, $FontSize, $LeftOvers, 'left'); + $LeftOvers = $pdf->addTextWrap(145, $YPos, $Width2, $FontSize2, $LeftOvers); } - $line_height = 15;// Back to the default line height - $QuotationTotal +=$LineTotal; - $QuotationTotalEx +=$SubTot; - $TaxTotal +=$TaxAmount; + $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 + }// Ends while there are line items to print out. if ((mb_strlen($myrow['comments']) >200 AND $YPos-$line_height <= 75) OR (mb_strlen($myrow['comments']) >1 AND $YPos-$line_height <= 62) @@ -233,31 +236,34 @@ include ('includes/PDFQuotationPageHeader.inc'); } //end if need a new page headed up - $YPos -= $line_height; + $FontSize = 10; + $YPos -= $line_height; $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90-655, $YPos, 655, $FontSize, _('Quotation Excluding Tax'),'right'); - $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($QuotationTotalEx,$myrow['currdecimalplaces']), 'right'); - $YPos -= 12; + $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($QuotationTotalEx,$myrow['currdecimalplaces']), 'right'); + $YPos -= $FontSize; $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90-655, $YPos, 655, $FontSize, _('Total Tax'), 'right'); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($TaxTotal,$myrow['currdecimalplaces']), 'right'); - $YPos -= 12; + $YPos -= $FontSize; $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90-655, $YPos, 655, $FontSize, _('Quotation Including Tax'),'right'); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($QuotationTotal,$myrow['currdecimalplaces']), 'right'); - // Print salesorders.comments - $line_height = 10;// Line height to print salesorders.comments - $YPos -= $line_height; - $pdf->addText($XPos, $YPos+10, $FontSize, _('Notes').':');// Comment: addText Y-Coordinate is to top left corner (add a FontSize mesure to equal addTextWrap Y-Coordinate) - $LeftOvers = str_replace('\n', ' ', $myrow['comments']);// Get salesorders.comments and replace line feed character. '<br />' works? + // Print salesorders.comments: + $YPos -= $FontSize*2; + $pdf->addText($XPos, $YPos+$FontSize, $FontSize, _('Notes').':'); + $Width2 = $Page_Width-$Right_Margin-120;// Width to print salesorders.comments. + $LeftOvers = trim($myrow['comments']); + //********** + $LeftOvers = str_replace('\n', ' ', $LeftOvers);// Replaces line feed character. $LeftOvers = str_replace('\r', '', $LeftOvers);// Delete carriage return character $LeftOvers = str_replace('\t', '', $LeftOvers);// Delete tabulator character - while (mb_strlen($LeftOvers) > 0) { - $YPos -= $line_height;// Suggestion: $line_height = $FontSize; - if ($YPos < ($Bottom_Margin)) {// Begin new page + //********** + while(mb_strlen($LeftOvers) > 1) { + $YPos -= $FontSize; + if ($YPos < ($Bottom_Margin)) {// Begins new page. include ('includes/PDFQuotationPageHeader.inc'); } - $LeftOvers = $pdf->addTextWrap(40, $YPos, 772, $FontSize, $LeftOvers, 'left'); + $LeftOvers = $pdf->addTextWrap(40, $YPos, $Width2, $FontSize, $LeftOvers); } - $line_height = 15;// Back to the default line height } /*end if there are line details to show on the quotation*/ Modified: trunk/PDFQuotationPortrait.php =================================================================== --- trunk/PDFQuotationPortrait.php 2014-08-15 00:58:02 UTC (rev 6821) +++ trunk/PDFQuotationPortrait.php 2014-08-15 20:24:57 UTC (rev 6822) @@ -1,6 +1,8 @@ <?php +/* $Id: PDFQuotationPortrait.php 4491 2011-02-15 06:31:08Z daintree $ */ -/* $Id: PDFQuotationPortrait.php 4491 2011-02-15 06:31:08Z daintree $ */ +/* Please note that addTextWrap prints a font-size-height further down than + addText and other functions.*/ include('includes/session.inc'); include('includes/SQL_CommonFunctions.inc'); @@ -111,11 +113,11 @@ LETS GO */ $PaperSize = 'A4'; include('includes/PDFStarter.php'); +/*$PageNumber = 1;// RChacon: PDFStarter.php sets $PageNumber = 0.*/ $pdf->addInfo('Title', _('Customer Quotation') ); $pdf->addInfo('Subject', _('Quotation') . ' ' . $_GET['QuotationNo']); -$FontSize=12; -$PageNumber = 1; -$line_height=24; +$FontSize = 12; +$line_height = 12;// Recommended: $line_height = $x * $FontSize. /* Now ... Has the order got any line items still outstanding to be invoiced */ @@ -143,21 +145,21 @@ /*Yes there are line items to start the ball rolling with a page header */ include('includes/PDFQuotationPortraitPageHeader.inc'); - $QuotationTotal =0; - $QuotationTotalEx=0; - $TaxTotal=0; + $QuotationTotal = 0; + $QuotationTotalEx = 0; + $TaxTotal = 0; while ($myrow2=DB_fetch_array($result)){ $ListCount ++; + $YPos -= $line_height;// Increment a line down for the next line item. + if ((mb_strlen($myrow2['narrative']) >200 AND $YPos-$line_height <= 75) OR (mb_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'); - + include('includes/PDFQuotationPortraitPageHeader.inc'); } //end if need a new page headed up $DisplayQty = locale_number_format($myrow2['quantity'],$myrow2['decimalplaces']); @@ -186,83 +188,75 @@ $TaxClass = 100 * $myrow4['taxrate']; } - $DisplayTaxClass = $TaxClass . "%"; + $DisplayTaxClass = $TaxClass . '%'; $TaxAmount = (($SubTot/100)*(100+$TaxClass))-$SubTot; $DisplayTaxAmount = locale_number_format($TaxAmount,$myrow['currdecimalplaces']); $LineTotal = $SubTot + $TaxAmount; $DisplayTotal = locale_number_format($LineTotal,$myrow['currdecimalplaces']); - $FontSize=10; + $FontSize = 10;// Font size for the line item. - $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'); + $LeftOvers = $pdf->addText($Left_Margin, $YPos+$FontSize, $FontSize, $myrow2['stkcode']); + $LeftOvers = $pdf->addText(120, $YPos+$FontSize, $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(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(330, $YPos,85,$FontSize,$DisplayTaxClass,'right'); + $LeftOvers = $pdf->addTextWrap(410, $YPos,85,$FontSize,$DisplayTaxAmount,'center');// RChacon: To review align to right.********** $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, $DisplayTotal,'right'); - // Prints salesorderdetails.narrative - $Split = explode("\r\n", wordwrap($myrow2['narrative'], 130, "\r\n")); - foreach ($Split as $TextLine) { - $YPos -= $line_height; // rchacon's suggestion: $YPos -= $FontSize; - if ($YPos < ($Bottom_Margin + $line_height)){ // Begins new page - $PageNumber++; - include ('includes/PDFQuotationPageHeader.inc'); + // Prints salesorderdetails.narrative: + $FontSize2 = $FontSize*0.8;// Font size to print salesorderdetails.narrative. + $Width2 = $Page_Width-$Right_Margin-120;// Width to print salesorderdetails.narrative. + $LeftOvers = trim($myrow2['narrative']); + while(mb_strlen($LeftOvers) > 1) { + $YPos -= $FontSize2; + if ($YPos < ($Bottom_Margin)) {// Begins new page. + include('includes/PDFQuotationPortraitPageHeader.inc'); } - $LeftOvers = $pdf->addTextWrap($XPos+1, $YPos, 750, 10, $TextLine); + $LeftOvers = $pdf->addTextWrap(120, $YPos, $Width2, $FontSize2, $LeftOvers); } - $YPos -= $line_height; - $QuotationTotal +=$LineTotal; - $QuotationTotalEx +=$SubTot; - $TaxTotal +=$TaxAmount; + $QuotationTotal += $LineTotal; + $QuotationTotalEx += $SubTot; + $TaxTotal += $TaxAmount; - /*increment a line down for the next line item */ - $YPos -= ($line_height); + }// Ends while there are line items to print out. - } //end while there are line items to print out if ((mb_strlen($myrow['comments']) >200 AND $YPos-$line_height <= 75) OR (mb_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'); + include('includes/PDFQuotationPortraitPageHeader.inc'); } //end if need a new page headed up - $LeftOvers = $pdf->addTextWrap($XPos,$YPos-80,30,10,_('Notes:')); - $LeftOvers = $pdf->addText($XPos,$YPos-95,10,$myrow['comments']); - - if (mb_strlen($LeftOvers)>1){ - $YPos -= 10; - $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); - if (mb_strlen($LeftOvers)>1){ - $YPos -= 10; - $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); - if (mb_strlen($LeftOvers)>1){ - $YPos -= 10; - $LeftOvers = $pdf->addTextWrap($XPos,$YPos,700,10,$LeftOvers); - if (mb_strlen($LeftOvers)>1){ - $YPos -= 10; - $LeftOvers = $pdf->addTextWrap($XPos,$YPos,10,$FontSize,$LeftOvers); - } - } - } - } - $YPos -= ($line_height); + $FontSize = 10; + $YPos -= $line_height; $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90-655, $YPos, 655, $FontSize, _('Quotation Excluding Tax'),'right'); - $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($QuotationTotalEx,$myrow['currdecimalplaces']), 'right'); - $YPos -= 12; + $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($QuotationTotalEx,$myrow['currdecimalplaces']), 'right'); + $YPos -= $FontSize; $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90-655, $YPos, 655, $FontSize, _('Total Tax'), 'right'); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($TaxTotal,$myrow['currdecimalplaces']), 'right'); - $YPos -= 12; + $YPos -= $FontSize; $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90-655, $YPos, 655, $FontSize, _('Quotation Including Tax'),'right'); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, locale_number_format($QuotationTotal,$myrow['currdecimalplaces']), 'right'); + // Print salesorders.comments: + $YPos -= $FontSize*2; + $pdf->addText($XPos, $YPos+$FontSize, $FontSize, _('Notes').':'); + $Width2 = $Page_Width-$Right_Margin-120;// Width to print salesorders.comments. + $LeftOvers = trim($myrow['comments']); + while(mb_strlen($LeftOvers) > 1) { + $YPos -= $FontSize; + if ($YPos < ($Bottom_Margin)) {// Begins new page. + include ('includes/PDFQuotationPageHeader.inc'); + } + $LeftOvers = $pdf->addTextWrap(40, $YPos, $Width2, $FontSize, $LeftOvers); + } + } /*end if there are line details to show on the quotation*/ Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-15 00:58:02 UTC (rev 6821) +++ trunk/doc/Change.log 2014-08-15 20:24:57 UTC (rev 6822) @@ -1,5 +1,6 @@ webERP Change Log +15/08/14 RChacon: Fixes double line feed in PDFQuotationPortrait.php reported by Arwan Galaya. Uniforms code between PDFQuotation.php and PDFQuotationPortrait.php. 14/08/14 RChacon: In CustomerInquiry.php and SupplierInquiry.php makes translatable the systypes.typename. 14/08/14 RChacon: In SupplierInquiry.php: Reorganizes columns Date, Type, Number, Reference and Comments, and regroups table-datacel format-strings as in CustomerInquiry.php code. 13/08/14 kelo: SupplierBalsAtPeriodEnd.php fix calculation to take into account fx differences on after date transactions Modified: trunk/includes/PDFQuotationPageHeader.inc =================================================================== --- trunk/includes/PDFQuotationPageHeader.inc 2014-08-15 00:58:02 UTC (rev 6821) +++ trunk/includes/PDFQuotationPageHeader.inc 2014-08-15 20:24:57 UTC (rev 6822) @@ -1,12 +1,13 @@ <?php -/* $Id$*/ +/* $Id$*/ /* pdf-php by R&OS code to set up a new sales order page */ -// The $PageNumber variable is initialised in 0 by PDFStarter.php -// This page header increments variable $PageNumber before printing it. -$PageNumber++; -// Inserts a page break if it is not the first page -if ($PageNumber>1) { +/* Please note that addTextWrap prints a font-size-height further down than + addText and other functions.*/ + +// $PageNumber is initialised in 0 by includes/PDFStarter.php. +$PageNumber ++;// Increments $PageNumber before printing. +if ($PageNumber>1) {// Inserts a page break if it is not the first page. $pdf->newPage(); } @@ -62,14 +63,16 @@ $YPos -= 82; $pdf->RoundRectangle($XPos-10, $YPos+60+10, 225+10+10, 60+10+10, 10, 10);// Function RoundRectangle from includes/class.pdf.php -// Print the currency name -include($PathPrefix . 'includes/CurrenciesArray.php'); // To get the currency name from the currency code. -$pdf->addText($Page_Width/2-60, $YPos-5, $FontSize, _('All amounts stated in') . ' - ' . $myrow['currcode'] . ' ' . $CurrencyName[$myrow['currcode']]); +$FontSize=10; -// Print table header +// Prints the currency name: +require_once('includes/CurrenciesArray.php');// To get the currency name from the currency code. +$pdf->addText($Page_Width/2-60, $YPos-5, $FontSize, + _('All amounts stated in') . ' ' . $myrow['currcode'] . ' - ' . $CurrencyName[$myrow['currcode']]); + +// Prints table header: $XPos = 40; $YPos -= 37; -$FontSize=10; $LeftOvers = $pdf->addTextWrap( 42, $YPos,103, $FontSize, _('Item Code'),'left'); if (strlen($LeftOvers) > 0) { // If translated text is greater than 103, prints remainder $LeftOvers = $pdf->addTextWrap(585,$YPos-$FontSize,65, $FontSize, $LeftOvers,'left'); @@ -88,28 +91,19 @@ } $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $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-10, $Bottom_Margin+350,0,90,10,10); -/*line to the top left */ -$pdf->line($Page_Width-$Right_Margin-10, $Bottom_Margin+360,$Left_Margin+10, $Bottom_Margin+360); +// Draws a box with round corners around line items: +$pdf->RoundRectangle( + $Left_Margin,// RoundRectangle $XPos. + $YPos+$FontSize+5,// RoundRectangle $YPos. + $Page_Width-$Left_Margin-$Right_Margin,// RoundRectangle $Width. + $YPos+$FontSize-$Bottom_Margin+5,// RoundRectangle $Height. + 10,// RoundRectangle $RadiusX. + 10);// RoundRectangle $RadiusY. -/*line under headings to top left */ -$pdf->line($Page_Width-$Right_Margin, $Bottom_Margin+335,$Left_Margin, $Bottom_Margin+335); +// Line under table headings: +$LineYPos = $YPos - $FontSize -1; +$pdf->line($Page_Width-$Right_Margin, $LineYPos, $Left_Margin, $LineYPos); +$YPos -= $FontSize;// This is to use addTextWrap's $YPos instead of normal $YPos. -/*Dow top left corner */ -$pdf->partEllipse($Left_Margin+10, $Bottom_Margin+350,90,180,10,10); -/*Do a line to the bottom left corner */ -$pdf->line($Left_Margin, $Bottom_Margin+350,$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-10, $Bottom_Margin); -/*Now do the bottom right corner */ -$pdf->partEllipse($Page_Width-$Right_Margin-10, $Bottom_Margin+10,270,350,10,10); -/*Finally join up to the top right corner where started */ -$pdf->line($Page_Width-$Right_Margin, $Bottom_Margin+10,$Page_Width-$Right_Margin, $Bottom_Margin+350); - -$YPos -= (2*$line_height); ?> Modified: trunk/includes/PDFQuotationPortraitPageHeader.inc =================================================================== --- trunk/includes/PDFQuotationPortraitPageHeader.inc 2014-08-15 00:58:02 UTC (rev 6821) +++ trunk/includes/PDFQuotationPortraitPageHeader.inc 2014-08-15 20:24:57 UTC (rev 6822) @@ -1,7 +1,12 @@ <?php -/* $Id: PDFQuotationPortraitPageHeader.inc 4491 2011-02-15 06:31:08Z daintree $ */ +/* $Id: PDFQuotationPortraitPageHeader.inc 4491 2011-02-15 06:31:08Z daintree $ */ -if ($PageNumber>1){ +/* Please note that addTextWrap prints a font-size-height further down than + addText and other functions.*/ + +// $PageNumber is initialised in 0 by includes/PDFStarter.php. +$PageNumber ++;// Increments $PageNumber before printing. +if ($PageNumber>1) {// Inserts a page break if it is not the first page. $pdf->newPage(); } @@ -88,12 +93,16 @@ $pdf->addTextWrap($Page_Width-$Right_Margin-200, $Page_Height-$Top_Margin-$FontSize*3, 200, $FontSize, _('Date'). ': '.ConvertSQLDate($myrow['quotedate']), 'right'); $pdf->addTextWrap($Page_Width-$Right_Margin-200, $Page_Height-$Top_Margin-$FontSize*4, 200, $FontSize, _('Page').': '.$PageNumber, 'right'); -$pdf->addText($Page_Width/2-10, $YPos+15, $FontSize, _('All amounts stated in') . ' - ' . $myrow['currcode']); +$FontSize=10; +// Prints the currency name: +require_once('includes/CurrenciesArray.php');// To get the currency name from the currency code. +$pdf->addText($Page_Width/2-10, $YPos+5, $FontSize, + _('All amounts stated in') . ' ' . $myrow['currcode'] . ' - ' . $CurrencyName[$myrow['currcode']]); + +// Prints table header: $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'); @@ -103,32 +112,19 @@ $LeftOvers = $pdf->addTextWrap(400,$YPos,85,$FontSize, _('Tax Amount'),'right'); $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-90, $YPos, 90, $FontSize, _('Total'),'right'); +// Draws a box with round corners around line items: +$pdf->RoundRectangle( + $Left_Margin,// RoundRectangle $XPos. + $YPos+$FontSize+5,// RoundRectangle $YPos. + $Page_Width-$Left_Margin-$Right_Margin,// RoundRectangle $Width. + $YPos+$FontSize-$Bottom_Margin+5,// RoundRectangle $Height. + 10,// RoundRectangle $RadiusX. + 10);// RoundRectangle $RadiusY. -/*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 table headings: +$LineYPos = $YPos - $FontSize -1; +$pdf->line($Page_Width-$Right_Margin, $LineYPos, $Left_Margin, $LineYPos); -/*line under headings to top left */ -$pdf->line($Page_Width-$Right_Margin+10, $Bottom_Margin+538,$Left_Margin, $Bottom_Margin+538); +$YPos -= $FontSize;// This is to use addTextWrap's $YPos instead of normal $YPos. - -/*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; - ?> Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-15 00:58:02 UTC (rev 6821) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-15 20:24:57 UTC (rev 6822) @@ -8,7 +8,7 @@ "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2014-08-14 18:43-0600\n" -"PO-Revision-Date: 2014-08-14 08:28-0600\n" +"PO-Revision-Date: 2014-08-15 14:04-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -726,7 +726,7 @@ #: PcReportTab.php:336 SelectCustomer.php:613 ShopParameters.php:198 #: SystemParameters.php:363 WOSerialNos.php:298 WOSerialNos.php:304 msgid "Notes" -msgstr "Descripción" +msgstr "Notas" #: AddCustomerContacts.php:149 SupplierContacts.php:166 #, php-format |
From: <rc...@us...> - 2014-08-17 20:52:01
|
Revision: 6825 http://sourceforge.net/p/web-erp/reponame/6825 Author: rchacon Date: 2014-08-17 20:51:57 +0000 (Sun, 17 Aug 2014) Log Message: ----------- Minor changes (add comments). Modified Paths: -------------- trunk/doc/Manual/ManualARTransactions.html trunk/includes/PDFTransPageHeader.inc trunk/includes/PDFTransPageHeaderPortrait.inc trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po Modified: trunk/doc/Manual/ManualARTransactions.html =================================================================== --- trunk/doc/Manual/ManualARTransactions.html 2014-08-16 05:13:40 UTC (rev 6824) +++ trunk/doc/Manual/ManualARTransactions.html 2014-08-17 20:51:57 UTC (rev 6825) @@ -30,8 +30,15 @@ <li>Updating the stock quantities for all lines of the invoice and the components of all assemblies included on the order.</li> </ul> -<p>If the order is not to be invoiced to the customer or branch specified in the order, or pricing is to be changed then the order must be changed. These elements cannot be altered at the time of invoice, they must be altered in the order before it is confirmed for invoicing. Once an invoice is created it cannot be deleted or modified. The order is also updated with the invoice number that it was dispatched on.</p><!-- Help End: SelectSalesOrder --> +<p>If the order is not to be invoiced to the customer or branch specified in the order, or pricing is to be changed then the order must be changed. These elements cannot be altered at the time of invoice, they must be altered in the order before it is confirmed for invoicing. Once an invoice is created it cannot be deleted or modified. The order is also updated with the invoice number that it was dispatched on.</p> +<p>Fields:</p> +<ul> +<li><b>Invoice Text</b>: This is the comment text of the invoice. It goes after the items lines and before the footer (Subtotal, Freight, Tax, Total invoice). Later, it will be shown in the "<i>Customer Inquiry</i>" on the "<i>Comments</i>" column. Database field: debtortrans.invtext.</li> +</ul> + +<!-- Help End: SelectSalesOrder --> + <div class="floatright"> <a class="minitext" href="#top">⬆ Top</a> </div><!-- Help Begin: SelectCreditItems --> Modified: trunk/includes/PDFTransPageHeader.inc =================================================================== --- trunk/includes/PDFTransPageHeader.inc 2014-08-16 05:13:40 UTC (rev 6824) +++ trunk/includes/PDFTransPageHeader.inc 2014-08-17 20:51:57 UTC (rev 6825) @@ -1,13 +1,20 @@ <?php - /* $Id$ */ -if (!$FirstPage){ /* only initiate a new page if its not the first */ +/* Please note that addTextWrap() prints a font-size-height further down than + addText() and other functions. Use addText() instead of addTextWrap() to + print left aligned elements.*/ + +// $PageNumber is initialised in 0 by includes/PDFStarter.php. +$PageNumber ++;// Increments $PageNumber before printing. +// Only initiate a new page if its not the first: +if ($FirstPage) { + $FirstPage = False; +} else { $pdf->newPage(); } +$YPos = $Page_Height-$Top_Margin; -$YPos = $Page_Height - $Top_Margin; - $pdf->addJpegFromFile($_SESSION['LogoFile'],$Page_Width/2 -120,$YPos-40,0,60); $FontSize =15; if ($InvOrCredit=='Invoice') { @@ -36,6 +43,14 @@ $pdf->partEllipse($XPos+225, $YPos+5,270,360,10,10); /*Finally join up to the top right corner where started */ $pdf->line($XPos+235, $YPos+5,$XPos+235, $YPos+100); +/*// Draws a nice curved corner box around the billing details: +$pdf->RoundRectangle( + $Left_Margin,// RoundRectangle $XPos. + $YPos+$FontSize+5,// RoundRectangle $YPos. + $Page_Width-$Left_Margin-$Right_Margin,// RoundRectangle $Width. + $YPos+$FontSize-$Bottom_Margin+5,// RoundRectangle $Height. + 10,// RoundRectangle $RadiusX. + 10);// RoundRectangle $RadiusY.*/ $YPos = $Page_Height - $Top_Margin - 10; @@ -219,4 +234,4 @@ $YPos -= ($line_height); -?> \ No newline at end of file +?> Modified: trunk/includes/PDFTransPageHeaderPortrait.inc =================================================================== --- trunk/includes/PDFTransPageHeaderPortrait.inc 2014-08-16 05:13:40 UTC (rev 6824) +++ trunk/includes/PDFTransPageHeaderPortrait.inc 2014-08-17 20:51:57 UTC (rev 6825) @@ -1,80 +1,83 @@ <?php - /* $Id$ */ +/* Please note that addTextWrap() prints a font-size-height further down than + addText() and other functions. Use addText() instead of addTextWrap() to + print left aligned elements.*/ -if (!$FirstPage){ /* only initiate a new page if its not the first */ +// $PageNumber is initialised in 0 by includes/PDFStarter.php. +$PageNumber ++;// Increments $PageNumber before printing. +if ($PageNumber>1) {// Inserts a page break if it is not the first page. $pdf->newPage(); } +/*// Only initiate a new page if its not the first: +if ($FirstPage) { + $FirstPage = False; +} else { + $pdf->newPage();*/ +} +$YPos = $Page_Height-$Top_Margin; -$YPos = $Page_Height - $Top_Margin; - // Company Logo $pdf->addJpegFromFile($_SESSION['LogoFile'],$Page_Width/2 -118,$YPos-60,0,35); $FontSize =15; if ($InvOrCredit=='Invoice') { - - $pdf->addText($Page_Width/2 - 60, $YPos, $FontSize, _('TAX INVOICE') . ' '); + $pdf->addText($Page_Width/2 - 60, $YPos, $FontSize, _('TAX INVOICE') . ' '); } else { $pdf->addText($Page_Width/2 - 60, $YPos, $FontSize, _('TAX CREDIT NOTE') . ' '); } -// Prints page number +// Prints page number: $FontSize = 10; $YPos -= $FontSize; //Downs one line height mesure (addText position is from left-bottom). -$pdf->addTextWrap($Page_Width-$Left_Margin-72, $YPos, 72, $FontSize, _('Page').' '.$PageNumber, 'right'); +$pdf->addTextWrap($Page_Width-$Right_Margin-100, $YPos, 100, $FontSize, + _('Page') . ' ' . $PageNumber, 'right'); $XPos = $Page_Width - 265; $YPos -= 85; -/*draw a nice curved corner box around the billing details */ -/*from the top right */ -$pdf->partEllipse($XPos+225,$YPos+67,0,90,10,10); -/*line to the top left */ -$pdf->line($XPos+225, $YPos+77,$XPos, $YPos+77); -/*Do top left corner */ -$pdf->partEllipse($XPos, $YPos+67,90,180,10,10); -/*Do a line to the bottom left corner */ -$pdf->line($XPos-10, $YPos+67,$XPos-10, $YPos-10); -/*Now do the bottom left corner 180 - 270 coming back west*/ -$pdf->partEllipse($XPos, $YPos-10,180,270,10,10); -/*Now a line to the bottom right */ -$pdf->line($XPos, $YPos-20,$XPos+225, $YPos-20); -/*Now do the bottom right corner */ -$pdf->partEllipse($XPos+225, $YPos-10,270,360,10,10); -/*Finally join up to the top right corner where started */ -$pdf->line($XPos+235, $YPos-10,$XPos+235, $YPos+67); +// Draws a nice curved corner box around the billing details: +$pdf->RoundRectangle($XPos-10, $Page_Height-$Top_Margin-15, 245, 101, 10, 10); +/*// Draws a nice curved corner box around the billing details: +$pdf->RoundRectangle( + $Left_Margin,// RoundRectangle $XPos. + $YPos+$FontSize+5,// RoundRectangle $YPos. + $Page_Width-$Left_Margin-$Right_Margin,// RoundRectangle $Width. + $YPos+$FontSize-$Bottom_Margin+5,// RoundRectangle $Height. + 10,// RoundRectangle $RadiusX. + 10);// RoundRectangle $RadiusY.*/ + +$XPos = $Page_Width-268; $YPos = $Page_Height - $Top_Margin - 10; - $FontSize = 10; $LineHeight = 13; -$LineCount = 1; -$pdf->addText($Page_Width-268, $YPos-$LineCount*$LineHeight, $FontSize, _('Number')); -$pdf->addText($Page_Width-180, $YPos-$LineCount*$LineHeight, $FontSize, $FromTransNo); -$LineCount += 1; -$pdf->addText($Page_Width-268, $YPos-$LineCount*$LineHeight, $FontSize, _('Customer Code')); -$pdf->addText($Page_Width-180, $YPos-$LineCount*$LineHeight, $FontSize, $myrow['debtorno'] . ' ' . _('Branch') . ' ' . $myrow['branchcode']); -$LineCount += 1; -$pdf->addText($Page_Width-268, $YPos-$LineCount*$LineHeight, $FontSize, _('Date')); -$pdf->addText($Page_Width-180, $YPos-$LineCount*$LineHeight, $FontSize, ConvertSQLDate($myrow['trandate'])); +$YPos -= $LineHeight; +$pdf->addText($XPos, $YPos, $FontSize, _('Number')); +$pdf->addText($XPos+88, $YPos, $FontSize, $FromTransNo); +$YPos -= $LineHeight; +$pdf->addText($XPos, $YPos, $FontSize, _('Customer Code')); +$pdf->addText($XPos+88, $YPos, $FontSize, $myrow['debtorno'] . ' ' . _('Branch') . ' ' . $myrow['branchcode']); +$YPos -= $LineHeight; +$pdf->addText($XPos, $YPos, $FontSize, _('Date')); +$pdf->addText($XPos+88, $YPos, $FontSize, ConvertSQLDate($myrow['trandate'])); + if ($InvOrCredit=='Invoice') { - $LineCount += 1; - $pdf->addText($Page_Width-268, $YPos-$LineCount*$LineHeight, $FontSize, _('Order No')); - $pdf->addText($Page_Width-180, $YPos-$LineCount*$LineHeight, $FontSize, $myrow['orderno']); - $LineCount += 1; - $pdf->addText($Page_Width-268, $YPos-$LineCount*$LineHeight, $FontSize, _('Order Date')); - $pdf->addText($Page_Width-180, $YPos-$LineCount*$LineHeight, $FontSize, ConvertSQLDate($myrow['orddate'])); - $LineCount += 1; - $pdf->addText($Page_Width-268, $YPos-$LineCount*$LineHeight, $FontSize, _('Dispatch Detail')); - $pdf->addText($Page_Width-180, $YPos-$LineCount*$LineHeight, $FontSize, $myrow['shippername'] . '-' . $myrow['consignment']); - $LineCount += 1; - $pdf->addText($Page_Width-268, $YPos-$LineCount*$LineHeight, $FontSize, _('Dispatched From')); - $pdf->addText($Page_Width-180, $YPos-$LineCount*$LineHeight, $FontSize, $myrow['locationname']); + $YPos -= $LineHeight; + $pdf->addText($XPos, $YPos, $FontSize, _('Order No')); + $pdf->addText($XPos+88, $YPos, $FontSize, $myrow['orderno']); + $YPos -= $LineHeight; + $pdf->addText($XPos, $YPos, $FontSize, _('Order Date')); + $pdf->addText($XPos+88, $YPos, $FontSize, ConvertSQLDate($myrow['orddate'])); + $YPos -= $LineHeight; + $pdf->addText($XPos, $YPos, $FontSize, _('Dispatch Detail')); + $pdf->addText($XPos+88, $YPos, $FontSize, $myrow['shippername'] . '-' . $myrow['consignment']); + $YPos -= $LineHeight; + $pdf->addText($XPos, $YPos, $FontSize, _('Dispatched From')); + $pdf->addText($XPos+88, $YPos, $FontSize, $myrow['locationname']); } - /*End of the text in the right side box */ /*Now print out company info at the top left */ @@ -147,7 +150,6 @@ $pdf->addText($XPos, $YPos-$LineCount*$LineHeight, $FontSize, html_entity_decode($myrow['brpostaddr3']) . ' ' . html_entity_decode($myrow['brpostaddr4']) . ' ' . html_entity_decode($myrow['brpostaddr5']) . ' ' . html_entity_decode($myrow['brpostaddr6'])); } -//$XPos = $Page_Width/2; $XPos = $Page_Width - 265; $YPos = $Page_Height - $Top_Margin - 120; @@ -157,8 +159,8 @@ if ($InvOrCredit=='Invoice') { $pdf->addText($XPos, $YPos-$LineCount*$LineHeight, $FontSize, _('Delivered To (check Dispatch Detail)') . ':'); - $FontSize = 10; - $LineHeight = 13; + $FontSize = 10; + $LineHeight = 13; $XPos +=20; $LineCount += 1; // Before trying to call htmlspecialchars_decode, check that its supported, if not substitute a compatible version @@ -203,58 +205,42 @@ } $XPos = $Left_Margin; - $YPos = $Page_Height - $Top_Margin - 190; -$XPos = $Left_Margin; +/*$XPos = $Left_Margin;*/ $FontSize = 8; include($PathPrefix . 'includes/CurrenciesArray.php'); // To get the currency name from the currency code. -$pdf->addText($Left_Margin, $YPos-8, $FontSize, _('All amounts stated in') . ': ' . $myrow['currcode'] . ' ' . $CurrencyName[$myrow['currcode']]); +$pdf->addText($Left_Margin, $YPos-8, $FontSize, _('All amounts stated in') . ': ' . $myrow['currcode'] . ' - ' . $CurrencyName[$myrow['currcode']]); -$BoxHeight = $Page_Height-282; -/*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-10, $Bottom_Margin+$BoxHeight,0,90,10,10); -/*line to the top left */ -$pdf->line($Page_Width-$Right_Margin-10, $Bottom_Margin+$BoxHeight+10,$Left_Margin+10, $Bottom_Margin+$BoxHeight+10); -/*Dow top left corner */ -$pdf->partEllipse($Left_Margin+10, $Bottom_Margin+$BoxHeight,90,180,10,10); -/*Do a line to the bottom left corner */ -$pdf->line($Left_Margin, $Bottom_Margin+$BoxHeight,$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-10, $Bottom_Margin); -/*Now do the bottom right corner */ -$pdf->partEllipse($Page_Width-$Right_Margin-10, $Bottom_Margin+10,270,360,10,10); -/*Finally join up to the top right corner where started */ -$pdf->line($Page_Width-$Right_Margin, $Bottom_Margin+10,$Page_Width-$Right_Margin, $Bottom_Margin+$BoxHeight); +$BoxHeight = $Page_Height-282; +// Draws a box with nice round corner for entering line items: +$pdf->RoundRectangle($Left_Margin, $Bottom_Margin+$BoxHeight+10, $Page_Width-$Right_Margin-$Left_Margin, $BoxHeight+10, 10, 10); -$YPos -= 35; /*Set up headings */ -$FontSize=10; +$YPos -= 11; +$FontSize = 10; $LineHeight = 12; -$LineCount = 0; -$pdf->addText($Left_Margin+2, ($YPos+$LineHeight)-$LineCount*$LineHeight, $FontSize, _('Cust. Tax Ref') . ':'); +$YPos -= $LineHeight; +$pdf->addText($Left_Margin+2, $YPos, $FontSize, _('Cust. Tax Ref') . ':'); /*Print a vertical line */ -$pdf->line($Left_Margin+178, $YPos+$LineHeight,$Left_Margin+178, $YPos-$LineHeight*2+4); -$pdf->addText($Left_Margin+180, ($YPos+$LineHeight)-$LineCount*$LineHeight, $FontSize, _('Cust. Reference No.') . ':'); +$pdf->line($Left_Margin+178, $YPos,$Left_Margin+178, $YPos-$LineHeight*3+4); +$pdf->addText($Left_Margin+180, $YPos, $FontSize, _('Cust. Reference No.') . ':'); /*Print a vertical line */ -$pdf->line($Left_Margin+358, $YPos+$LineHeight,$Left_Margin+358, $YPos-$LineHeight*2+4); -$pdf->addText($Left_Margin+360, ($YPos+$LineHeight)-$LineCount*$LineHeight, $FontSize, _('Sales Person') . ':'); -$LineCount += 1; -$pdf->addText($Left_Margin+12, ($YPos+$LineHeight)-$LineCount*$LineHeight, $FontSize, $myrow['taxref']); -if ($InvOrCredit=='Invoice'){ - $pdf->addText($Left_Margin+190, ($YPos+$LineHeight)-$LineCount*$LineHeight, $FontSize, $myrow['customerref']); +$pdf->line($Left_Margin+358, $YPos,$Left_Margin+358, $YPos-$LineHeight*3+4); +$pdf->addText($Left_Margin+360, $YPos, $FontSize, _('Sales Person') . ':'); + +$YPos -= $LineHeight; +$pdf->addText($Left_Margin+12, $YPos, $FontSize, $myrow['taxref']); +if ($InvOrCredit=='Invoice') { + $pdf->addText($Left_Margin+190, $YPos, $FontSize, $myrow['customerref']); } -$pdf->addText($Left_Margin+370, ($YPos+$LineHeight)-$LineCount*$LineHeight, $FontSize, $myrow['salesmanname']); +$pdf->addText($Left_Margin+370, $YPos, $FontSize, $myrow['salesmanname']); +/*draw a line */ $YPos -= 20; - -/*draw a line */ $pdf->line($XPos, $YPos,$Page_Width-$Right_Margin, $YPos); $YPos -= 12; @@ -269,11 +255,10 @@ $pdf->addText($Left_Margin+420, $YPos+12, $FontSize, _('Disc.')); $pdf->addTextWrap($Page_Width-$Left_Margin-72, $YPos, 72, $FontSize, _('Price'), 'right'); +/*draw a line */ $YPos-=0; - -/*draw a line */ $pdf->line($XPos, $YPos,$Page_Width-$Right_Margin, $YPos); $YPos -= ($line_height); -?> \ No newline at end of file +?> Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-16 05:13:40 UTC (rev 6824) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-17 20:51:57 UTC (rev 6825) @@ -8,7 +8,7 @@ "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2014-08-14 18:43-0600\n" -"PO-Revision-Date: 2014-08-15 14:04-0600\n" +"PO-Revision-Date: 2014-08-16 12:00-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -7332,7 +7332,7 @@ #: Credit_Invoice.php:404 msgid "Are you sure you wish to delete this item from the credit?" -msgstr "" +msgstr "¿Está seguro de que quiere borrar este artículo del crédito?" #: Credit_Invoice.php:422 msgid "Freight cost charged on invoice" @@ -7543,11 +7543,11 @@ #: Credit_Invoice.php:1592 msgid "Credit note text" -msgstr "Texto de nota de Crédito" +msgstr "Texto de la nota de crédito" #: Credit_Invoice.php:1604 msgid "Process Credit" -msgstr "Procesar nota de Crédito" +msgstr "Procesar crédito" #: Currencies.php:6 includes/MainMenuLinksArray.php:441 msgid "Currencies Maintenance" @@ -10138,7 +10138,7 @@ #: Customers.php:1101 msgid "Contact Deleted" -msgstr "Contacto Eliminado" +msgstr "Contacto suprimido" #: Customers.php:1133 msgid "Add Contact" @@ -10155,7 +10155,7 @@ #: Customers.php:1195 msgid "Delete Customer" -msgstr "Eliminar cliente" +msgstr "Suprimir cliente" #: DailyBankTransactions.php:6 msgid "Bank Transactions Inquiry" @@ -10245,7 +10245,7 @@ #: DailyBankTransactions.php:173 GLJournalInquiry.php:126 msgid "Select Another Date" -msgstr "Seleccione Otra Fecha" +msgstr "Seleccione otra fecha" #: DailySalesInquiry.php:6 includes/MainMenuLinksArray.php:56 msgid "Daily Sales Inquiry" @@ -10261,7 +10261,7 @@ #: DailySalesInquiry.php:26 msgid "Month to Show" -msgstr "Meses a Mostrar" +msgstr "Mes a mostrar" #: DailySalesInquiry.php:70 msgid "Show Daily Sales For The Selected Month" @@ -10385,7 +10385,7 @@ #: Dashboard.php:359 PrintCustTrans.php:811 PrintCustTransPortrait.php:857 #: SalesInquiry.php:1087 SupplierInvoice.php:632 msgid "Invoice Date" -msgstr "Fecha Factura" +msgstr "Fecha factura" #: Dashboard.php:361 msgid "Amount Due" @@ -10442,7 +10442,7 @@ #: Dashboard.php:672 FTP_RadioBeacon.php:55 SelectCompletedOrder.php:560 #: SelectSalesOrder.php:701 SelectSalesOrder.php:718 msgid "Req Del Date" -msgstr "Fecha de Entrega Solicitada" +msgstr "Fecha de entrega solicitada" #: Dashboard.php:673 FTP_RadioBeacon.php:56 PO_Header.php:881 #: PO_Header.php:1134 SelectCompletedOrder.php:561 SelectSalesOrder.php:702 |
From: <rc...@us...> - 2014-08-18 15:32:02
|
Revision: 6829 http://sourceforge.net/p/web-erp/reponame/6829 Author: rchacon Date: 2014-08-18 15:31:53 +0000 (Mon, 18 Aug 2014) Log Message: ----------- Adds anchors for Manual help. Modified Paths: -------------- trunk/LocationUsers.php trunk/Locations.php trunk/doc/Manual/ManualInventory.html Modified: trunk/LocationUsers.php =================================================================== --- trunk/LocationUsers.php 2014-08-18 13:43:49 UTC (rev 6828) +++ trunk/LocationUsers.php 2014-08-18 15:31:53 UTC (rev 6829) @@ -1,8 +1,10 @@ <?php -/* $Id: LocationUsers.php 6806 2013-09-28 05:10:46Z daintree $*/ +/* $Id: LocationUsers.php 6806 2013-09-28 05:10:46Z daintree $*/ include('includes/session.inc'); $Title = _('Maintenance Of Location Authorised Users'); +$ViewTopic = 'Inventory';// Filename in ManualContents.php's TOC. +$BookMark = 'LocationUsers';// Anchor's id in the manual's html document. include('includes/header.inc'); echo '<p class="page_title_text"><img src="' . $RootPath . '/css/' . $Theme . '/images/money_add.png" title="' . _('Location Authorised Users') . '" alt="" />' . ' ' . $Title . '</p>'; Modified: trunk/Locations.php =================================================================== --- trunk/Locations.php 2014-08-18 13:43:49 UTC (rev 6828) +++ trunk/Locations.php 2014-08-18 15:31:53 UTC (rev 6829) @@ -1,12 +1,12 @@ <?php - /* $Id$*/ include('includes/session.inc'); - $Title = _('Location Maintenance'); +$ViewTopic = 'Inventory';// Filename in ManualContents.php's TOC. +$BookMark = 'Locations';// Anchor's id in the manual's html document. +include('includes/header.inc'); -include('includes/header.inc'); include('includes/CountriesArray.php'); if (isset($_GET['SelectedLocation'])){ Modified: trunk/doc/Manual/ManualInventory.html =================================================================== --- trunk/doc/Manual/ManualInventory.html 2014-08-18 13:43:49 UTC (rev 6828) +++ trunk/doc/Manual/ManualInventory.html 2014-08-18 15:31:53 UTC (rev 6829) @@ -133,6 +133,7 @@ <h3>Part Descriptions</h3> <p>A description of the stock item - can be up to 50 characters long. A description is required for each stock item. This description is used in the look up boxes provided each time the stock item is invoiced, credited or adjusted. There is also the facility to enter long descriptions for each part which show on the screens that customers could access to place orders. This field allows very long descriptions or even features and benefits to be described for the item. The intention for this field is that it could be used for producing a company catalogue or for online ordering by customers who may need more information about a product. It is only the description (short) that displays on invoices and credit notes.</p> + <p>The description translations can be maintained within the same parameters above. The translations that can be maintained are set in the system configuration screen. Any number of translations can be maintained. These translations are used to print on customer invoices if the customer is set up to use one of the languages for which translations are maintained. If not translation is available then the fall back is to the default description.</p> <h3>Categories</h3> @@ -324,8 +325,10 @@ <p>Only transactions entered after the charge will be created at the new cost. Sales analysis will refer to the costs as at the time when the transactions are created.</p> - <p>There is a utility available from the Z_index.php page that allows the sales analysis for a specified period to be updated with the current costs. This utility takes the quantity sold and multiplies the current standard cost by the quantity to re-calculate the cost of each sales analysis record in the period selected - the sales analysis data is updated. This will mean that the general ledger costs will then differ to the sales analysis cost for the period since the general ledger postings are created at the time of invoicing/crediting. <!-- Help End: StockCostUpdate --></p><!-- Help Begin: SelectProduct --> + <p>There is a utility available from the Z_index.php page that allows the sales analysis for a specified period to be updated with the current costs. This utility takes the quantity sold and multiplies the current standard cost by the quantity to re-calculate the cost of each sales analysis record in the period selected - the sales analysis data is updated. This will mean that the general ledger costs will then differ to the sales analysis cost for the period since the general ledger postings are created at the time of invoicing/crediting. <!-- Help End: StockCostUpdate --></p> +<!-- Help Begin: SelectProduct --> + <div class="floatright"> <a class="minitext" href="#top">⬆ Top</a> </div> @@ -445,71 +448,104 @@ <p>This field declares the type of resource that the stock category represents and is one of Finished Goods, Raw Materials, Labour or Dummy Inventory. This field is used to distinguish labour type stock items from other components for the purposes of calculating work centre overhead in the cost roll up. It is also used for ordering stock reports to ensure raw materials and finished goods are grouped together. <!-- Help End: StockCategories --></p> - <p><!-- Help Begin: Locations --></p> + <p><!-- Help Begin: Inventory Locations Maintenance --></p> <div class="floatright"> <a class="minitext" href="#top">⬆ Top</a> </div> - <h2>Inventory Location Maintenance</h2> + <h2><a id="Locations">Inventory Locations Maintenance</a></h2> <p>A table of locations is maintained which contains a location code of 5 characters and the location description (up to 20 characters). The description is the field used in lookups on invoicing and crediting. To keep the database as compact as possible it is the code which is stored against stock movement transactions. As many locations as required can be set up. When a new location is defined, location records for all items in the database are created. When a location is deleted, so too are all the item location records. However, a location record cannot be deleted if there are stock movements or stock held for any part in the location. Since the location represents the physical location from where goods/services are supplied it is important for determining the tax applicable on a sale. The governing tax authority must specified with the location record. It is used in the calculation of the applicable rate of tax in conjunction with the tax authority of the customer branch being delivered to and the tax level of the item being sold.</p> - <p>Note: Location codes cannot be modified retrospectively. Neither can they be deleted if there are stock movements, users (default location) or customer branch records set up to receive stock from the location. <!-- Help End: Locations --></p><!-- Help Begin: StockAdjustments --> + <p>Note: Location codes cannot be modified retrospectively. Neither can they be deleted if there are stock movements, users (default location) or customer branch records set up to receive stock from the location.</p> +<!-- Help End: Inventory Locations Maintenance --> + +<!-- Help Begin: Inventory Location Authorised Users Maintenance --> + <div class="floatright"> + <a class="minitext" href="#top">⬆ Top</a> + </div> + + <h2><a id="LocationUsers">Inventory Location Authorised Users Maintenance</a></h2> + + <p>.</p> + +<!-- Help End: Inventory Location Authorised Users Maintenance --> + +<!-- Help Begin: StockAdjustments --> + <div class="floatright"> + <a class="minitext" href="#top">⬆ Top</a> + </div> <h2><a id="InventoryAdjustments">Inventory Adjustments</a></h2> + <p>Inventory can be written on or off for individual stock items using this option. Corrections to physical stocks and deliveries of stock can be entered using this option. Adjustments can be entered by selecting the link on the SelectProduct.php page or directly from the menu under transactions. Using the second link, the item code must be known, there is no facility to select an item code from this page.</p> <p>If Stock GL integration is enabled from the company preferences page (under the setup tab), then the system creates the necessary journals in the general ledger to update the stock account and the profit and loss account stock adjustment account specified in the stock category record. (see Inventory Categories above and also see General Ledger Integration later)</p> <p>Note: Inventory Adjustments are not possible with kit set, assembly or dummy stock items since no stock record is maintained for these items.</p> - <p>Inventory adjustments for controlled items must select the batches/serial numbers being adjusted. <!-- Help End: StockAdjustments --></p><!-- Help Begin: StockTransfers --> + <p>Inventory adjustments for controlled items must select the batches/serial numbers being adjusted.</p> - <p>Bulk inventory transfers consisting of many parts can be set up. These allow a docket to be produced to be sent with the dispatch of the goods. The transfer is not actually effected until the transfer is received in by the receiving stock location. <!-- Help End: StockTransfers --></p> +<!-- Help End: StockAdjustments --> + + + <div class="floatright"> - <a class="minitext" href="#top">? Top</a> + <a class="minitext" href="#top">⬆ Top</a> </div> + <h2><a id="InventoryRequests">Internal Stock Requests</a></h2> - <h2><a id="InventoryRequests">Internal Stock Requests</a></h2> - <p>Internal departments of an organisation to make requests for consumable items from a particular stock location.</p> - <p>Departments are created via the Inventory section of the setup module. The name of the department must be entered, and the userid of the person who will be responsible for authorising the requests from that department must be selected here.</p> - <p>Each user can be given permission to create internal stock requests for a particular department, or they can have permission to create requests for all departments.</p> - <p>Individual stock locations have a flag that can be set to allow or disallow internal stock requests to be fulfilled from that location.</p> - <p>Also each user role, can have specific stock categories assigned to it for which intyernal stock requests can be created. These are created in the Maintain Internal Stock Categories to User Roles section of the setup module.</p> + <p>Departments are created via the Inventory section of the setup module. The name of the department must be entered, and the userid of the person who will be responsible for authorising the requests from that department must be selected here.</p> + + <p>Each user can be given permission to create internal stock requests for a particular department, or they can have permission to create requests for all departments.</p> + + <p>Individual stock locations have a flag that can be set to allow or disallow internal stock requests to be fulfilled from that location.</p> + + <p>Also each user role, can have specific stock categories assigned to it for which intyernal stock requests can be created. These are created in the Maintain Internal Stock Categories to User Roles section of the setup module.</p> + <ul> <li> <h3><a id="CreateRequest">Create a New Internal Stock Request</a></h3> <p>An internal stock request is created in two parts. Firstly the header, which contains the Department that requires the items, the location that you wish the request to be fulfilled from, the date by which you require the items, and any narrative you wish to add to the request.</p> + <p>Secondly the items required are selected and the quantities required are entered.</p> + <p>Once you are happy that you have all the items and quantities enetered, submit the request for authorisation.</p> + </li> <li> <h3><a id="AuthoriseRequest">Authorise Internal Stock Requests</a></h3> <p>When a user chooses this option they will see all unauthorised stock requests that they are allowed to authorise. No other requests will appear. By ticking the authorise checkbox, and clicking on the update button they will authorise this request to be fulfilled.</p> + </li> <li> <h3><a id="FulfilRequest">Fulfil Internal Stock Requests</a></h3> <p>When the warehouse open this option for their own warehouse, they will see any internal stock requests that are awaiting fulfillment. They can either fulfil all or part of a request. If not all of the request is fulfilled, but the rest will not be, the request can be marked as completed. Also a GL tag can be chosen to tag that entry against.</p> + </li> </ul> +<!-- Help Begin: StockTransfers --> <div class="floatright"> <a class="minitext" href="#top">⬆ Top</a> </div> - <h2><a id="LocationTransfers">Inventory Location Transfers</a></h2> <p>Transfers of inventory between locations need to take stock off the sending location and increase the stock in the receiving location. This is effected in one transaction by entering a stock transfer. In the same way as adjustments these can be accessed either from the SelectProduct.php page which is linked to from every page on the top header banner or directly from the menu - inventory tab under the transactions section. All that is required is the location from and to, the date and the quantity being sent. If the business wishes to record inventory in transit an additional in transit location needs to be established and a transfer to the transit location performed when the stock is dispatched and a further location transfer from the transit location to the receiving location when the stock is received. Stock location transfers are shown on stock movement inquiries.</p> <p>Note: Inventory Location Transfers are not possible with kit set, assembly or dummy stock items since no stock record is maintained for these items.</p> - <p>Bulk inventory transfers consisting of many parts can be set up effective from 2.9. These allow a docket to be produced to be sent with the dispatch of the goods. The transfer is not actually effected until the transfer is received in by the receiving stock location. <!-- Help End: StockTransfers --></p> + <p>Bulk inventory transfers consisting of many parts can be set up. These allow a docket to be produced to be sent with the dispatch of the goods. The transfer is not actually effected until the transfer is received in by the receiving stock location.</p> +<!-- Help End: StockTransfers --> + + + <div class="floatright"> <a class="minitext" href="#top">⬆ Top</a> </div> @@ -526,8 +562,10 @@ <li>Inventory Usage</li> </ul> - <p>All stock inquiries are performed from the product selection form. Once a product has been selected the links to the various relevant inquiries will show.</p><!-- Help Begin: StockStatus --> + <p>All stock inquiries are performed from the product selection form. Once a product has been selected the links to the various relevant inquiries will show.</p> +<!-- Help Begin: StockStatus --> + <h3>Inventory Status inquiries</h3> <p>Shows the detail of how much stock is held and where the stock is (i.e. how much at each location) together with the total quantity of sales orders for the part outstanding and the quantity of the item on outstanding purchase orders can also be viewed from this inquiry. Not only are outstanding sales orders for this part accumulated but all the demand for parent assembly parts as extended by the quantity required per unit of the parent. This ensures that all demand for the part is shown.</p> @@ -546,8 +584,10 @@ <p>Note: Inventory movement inquiries are possible on dummy and assembly stock items. However, since dummy items are not physical stock items, no record of the amount of stock and the location of where held (there is none held) are maintained. The location inquiry will always be zero for a dummy/assembly and kit set items. When a dummy stock item, or an assembly or kit set item is selected the link to the stock status inquiry is not available.</p> - <p>If the stock movement was an invoice or a credit the customer and the price in the currency invoiced or credited will show. <!-- Help End: StockMovements --></p><!-- Help Begin: StockUsage --> + <p>If the stock movement was an invoice or a credit the customer and the price in the currency invoiced or credited will show. <!-- Help End: StockMovements --></p> +<!-- Help Begin: StockUsage --> + <h3>Inventory Usage inquiries</h3> <p>This inquiry shows the quantity of the stock item that has been consumed either in sales net of credit notes and adjustments by month from each location. Transfers between locations are ignored as are deliveries. Usage of an item adds all the stock movement quantities for the part so that stock movements related to the sale of assembly items requiring the part under review as a component are included. Usage can be seen by location and also the total usage from all locations.</p> @@ -566,8 +606,10 @@ <p>-0 0 1 * * root /usr/bin/wget <a href="http://localhost/web-erp/MailInventoryValuation.php">http://localhost/web-erp/MailInventoryValuation.php</a></p> - <p>since the page has no output - it would be pointless running it in a web browser although it would initiate another email to the defined recipients. <!-- Help End: InventoryValuation --></p><!-- Help Begin: InventoryPlanning --> + <p>since the page has no output - it would be pointless running it in a web browser although it would initiate another email to the defined recipients. <!-- Help End: InventoryValuation --></p> +<!-- Help Begin: InventoryPlanning --> + <h3><a id="PlanningReport">Inventory Planning Report</a></h3> <p>This report shows the usage of stock items over the previous four months together with the current stock, outstanding sales orders and outstanding purchase orders. It suggests a re-order quantity based on a selectable number of months stock to have in the supply chain multiplied by the maximum of the previous four months monthly stock usage (from all stock locations), less the on hand stock and purchase orders. It will not suit all purposes but certainly does provide good information from which to base purchasing decisions.</p> @@ -584,8 +626,10 @@ </ul> <p> - <p>The Inventory Planning Reports are run from the Inventory tab of the main menu under the Inquiries and Reports section. <!-- Help End: InventoryPlanning --></p><!-- Help Begin: StockCheck --> + <p>The Inventory Planning Reports are run from the Inventory tab of the main menu under the Inquiries and Reports section. <!-- Help End: InventoryPlanning --></p> +<!-- Help Begin: StockCheck --> + <div class="floatright"> <a class="minitext" href="#top">⬆ Top</a> </div> @@ -631,6 +675,7 @@ <p>Once happy that the adjustments to be made are correct the report can be run again with the option to Report and Close the Inventory Comparison File and Process Adjustments as Necessary.</p> <p>There is no going back on this process - if you didn't mean to process these adjustments they must all be reversed manually. Be very sure when running the comparison in this mode.</p> + <h4>Additional Notes on Stock Checks:</h4> @@ -639,9 +684,11 @@ <p>It doesn't matter how many times you enter the same item code all entries are added together for the same stock item to accumulate to a total and the comparison report shows each entry - and you can reference to an aisle/row etc and/or the count sheet/counter if you want to go back and double check a count and/or the input. There is no need to manually add stock of the same part counted in for example 12 different places throughout the warehouse (although such a warehouse might need a bit of reorganisation) as the system does this for you.</p> <p>When you create the stock check it looks at the system quantity at the location being counted and stores that quantity - subsequent movements are ignored. If you carry on selling then these will not be taken into account - you need to count at the time when you create the stock check. All deliveries should be entered in - selling must stop (there is just no other way to ensure an accurate count). Ideally stock checks should be done after hours. Once the count is complete for all the quantitities, selling can resume. There is no panic with the data entry as the stock take adjustments created are derived based on the stock at the time the stock check was created (and the stock counted). You can only count one location at a time.</p> + <p>Creating a new stock check will over-write an existing stock check - so if you have entered counts and then create a new stock check it is possible to wipe out a lot of work - only create a new stock check once the previous one has been updated. You can run the comparison report without updating to see what adjustments would be created - and do any necessary double counts if need be. If need be additional quantities can be entered for items that were missed or negative quantities for errors where stock was over counted. The comparison can then be rerun. Finally when happy run the comparison report in update mode to complete the stock check.</p> <p>The only problem with doing the data input at your leisure subsequently is that any recheck will potentially be after the stock has moved by additional sales or arrivals of new stock. However, the stock check can be run again for those items that need a recount</p> + <!-- Help End: StockCheck --> </div> |
From: <rc...@us...> - 2014-08-18 20:14:13
|
Revision: 6830 http://sourceforge.net/p/web-erp/reponame/6830 Author: rchacon Date: 2014-08-18 20:14:05 +0000 (Mon, 18 Aug 2014) Log Message: ----------- Translates Dashboard.php and updates *.po. Modified Paths: -------------- trunk/Dashboard.php trunk/LocationUsers.php trunk/locale/ar_EG.utf8/LC_MESSAGES/messages.mo trunk/locale/ar_EG.utf8/LC_MESSAGES/messages.po 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_CA.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_CA.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/vi_VN.utf8/LC_MESSAGES/messages.mo trunk/locale/vi_VN.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/locale/zh_TW.utf8/LC_MESSAGES/messages.mo trunk/locale/zh_TW.utf8/LC_MESSAGES/messages.po Modified: trunk/Dashboard.php =================================================================== --- trunk/Dashboard.php 2014-08-18 15:31:53 UTC (rev 6829) +++ trunk/Dashboard.php 2014-08-18 20:14:05 UTC (rev 6830) @@ -1,5 +1,4 @@ <?php - /* $Id: Dashboard.php 6338 2013-09-28 05:10:46Z daintree $*/ include('includes/session.inc'); @@ -296,7 +295,7 @@ <td class="number" style="color:orange;">%s</td> <td class="number" style="color:red;">%s</td> <td class="number" style="color:red;">%s</td>', - $DetailTrans['typename'], + _($DetailTrans['typename']), $DetailTrans['transno'], $DisplayTranDate, $DisplayDueDate, @@ -483,7 +482,7 @@ <td>%s</td> <td class="number"' . $DisplayFormat . '>%s</td> <td' . $DisplayFormat . '>%s</td>', - $DetailTrans['typename'], + _($DetailTrans['typename']), $DislayTranDate, $PayNow, locale_number_format($DetailTrans['balance'],$CurrDecimalPlaces), @@ -524,7 +523,7 @@ } //PayeeSecurity if (in_array($CashSecurity, $_SESSION['AllowedPageSecurityTokens']) OR !isset($CashSecurity)) { include('includes/GLPostings.inc'); - echo '<br /><b>Bank and Credit Card Balances</b> + echo '<br /><b>' . _('Bank and Credit Card Balances') . '</b> <table class="selection"><tbody>'; $FirstPeriodSelected = GetPeriod(date($_SESSION['DefaultDateFormat']), $db); $LastPeriodSelected = GetPeriod(date($_SESSION['DefaultDateFormat']), $db); @@ -651,7 +650,7 @@ } //CashSecurity if (in_array($OrderSecurity, $_SESSION['AllowedPageSecurityTokens']) OR !isset($OrderSecurity)) { - echo '<br /><b>Outstanding Orders</b>'; + echo '<br /><b>' . _('Outstanding Orders') . '</b>'; echo '<table cellpadding="2" width="95%" class="selection">'; $RecentDate = Date(($_SESSION['DefaultDateFormat']), strtotime($RecentDate . ' - 1 days')); @@ -802,4 +801,4 @@ } //rows > 0 } //OrderSecurity include('includes/footer.inc'); -?> \ No newline at end of file +?> Modified: trunk/LocationUsers.php =================================================================== --- trunk/LocationUsers.php 2014-08-18 15:31:53 UTC (rev 6829) +++ trunk/LocationUsers.php 2014-08-18 20:14:05 UTC (rev 6830) @@ -2,7 +2,7 @@ /* $Id: LocationUsers.php 6806 2013-09-28 05:10:46Z daintree $*/ include('includes/session.inc'); -$Title = _('Maintenance Of Location Authorised Users'); +$Title = _('Inventory Location Authorised Users Maintenance'); $ViewTopic = 'Inventory';// Filename in ManualContents.php's TOC. $BookMark = 'LocationUsers';// Anchor's id in the manual's html document. include('includes/header.inc'); Modified: trunk/locale/ar_EG.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/ar_EG.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/ar_EG.utf8/LC_MESSAGES/messages.po 2014-08-18 15:31:53 UTC (rev 6829) +++ trunk/locale/ar_EG.utf8/LC_MESSAGES/messages.po 2014-08-18 20:14:05 UTC (rev 6830) @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: web-erp\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-14 18:43-0600\n" +"POT-Creation-Date: 2014-08-18 13:21-0600\n" "PO-Revision-Date: 2013-06-01 11:19-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: Arabic <ar...@li...>\n" @@ -691,19 +691,20 @@ #: SelectCustomer.php:612 SelectSupplier.php:288 SupplierContacts.php:156 #: SupplierContacts.php:277 UserSettings.php:184 WWW_Users.php:297 #: includes/PDFPickingListHeader.inc:25 includes/PDFStatementPageHeader.inc:67 -#: includes/PDFTransPageHeader.inc:82 -#: includes/PDFTransPageHeaderPortrait.inc:111 includes/PDFWOPageHeader.inc:19 +#: includes/PDFTransPageHeader.inc:85 +#: includes/PDFTransPageHeaderPortrait.inc:114 includes/PDFWOPageHeader.inc:19 #: includes/PO_PDFOrderPageHeader.inc:29 ../webSHOP/Checkout.php:298 #: ../webSHOP/Register.php:595 msgid "Email" msgstr "" #: AddCustomerContacts.php:130 AddCustomerContacts.php:250 Customers.php:1123 -#: Customers.php:1131 PDFQuotation.php:249 PcAssignCashToTab.php:242 -#: PcAssignCashToTab.php:380 PcAuthorizeExpenses.php:97 -#: PcClaimExpensesFromTab.php:238 PcClaimExpensesFromTab.php:405 -#: PcReportTab.php:336 SelectCustomer.php:613 ShopParameters.php:198 -#: SystemParameters.php:363 WOSerialNos.php:298 WOSerialNos.php:304 +#: Customers.php:1131 PDFQuotation.php:252 PDFQuotationPortrait.php:249 +#: PcAssignCashToTab.php:242 PcAssignCashToTab.php:380 +#: PcAuthorizeExpenses.php:97 PcClaimExpensesFromTab.php:238 +#: PcClaimExpensesFromTab.php:405 PcReportTab.php:336 SelectCustomer.php:613 +#: ShopParameters.php:198 SystemParameters.php:363 WOSerialNos.php:298 +#: WOSerialNos.php:304 msgid "Notes" msgstr "" @@ -729,8 +730,8 @@ #: PO_Header.php:1022 PO_Header.php:1107 SelectCreditItems.php:245 #: SelectCustomer.php:425 SelectOrderItems.php:597 #: SupplierTenderCreate.php:395 includes/PDFStatementPageHeader.inc:63 -#: includes/PDFTransPageHeader.inc:81 -#: includes/PDFTransPageHeaderPortrait.inc:107 ../webSHOP/Checkout.php:389 +#: includes/PDFTransPageHeader.inc:84 +#: includes/PDFTransPageHeaderPortrait.inc:110 ../webSHOP/Checkout.php:389 #: ../webSHOP/Register.php:255 ../webSHOP/Register.php:723 msgid "Phone" msgstr "" @@ -772,8 +773,8 @@ #: AddCustomerTypeNotes.php:111 AddCustomerTypeNotes.php:211 #: AgedControlledInventory.php:47 BankMatching.php:282 #: BankReconciliation.php:217 BankReconciliation.php:294 -#: ContractCosting.php:177 CustomerAllocations.php:347 -#: CustomerAllocations.php:377 CustomerInquiry.php:215 +#: ContractCosting.php:177 CustomerAllocations.php:348 +#: CustomerAllocations.php:378 CustomerInquiry.php:215 #: CustomerTransInquiry.php:106 GLAccountInquiry.php:174 #: GLAccountReport.php:343 GLTransInquiry.php:42 MRPCalendar.php:219 #: PDFRemittanceAdvice.php:308 PaymentAllocations.php:66 @@ -785,11 +786,11 @@ #: StockSerialItemResearch.php:82 SupplierAllocations.php:456 #: SupplierAllocations.php:569 SupplierAllocations.php:644 #: SupplierInquiry.php:209 SupplierTransInquiry.php:105 -#: includes/PDFQuotationPageHeader.inc:19 -#: includes/PDFQuotationPortraitPageHeader.inc:88 +#: includes/PDFQuotationPageHeader.inc:23 +#: includes/PDFQuotationPortraitPageHeader.inc:80 #: includes/PDFStatementPageHeader.inc:169 includes/PDFTaxPageHeader.inc:36 -#: includes/PDFTransPageHeader.inc:48 -#: includes/PDFTransPageHeaderPortrait.inc:60 +#: includes/PDFTransPageHeader.inc:51 +#: includes/PDFTransPageHeaderPortrait.inc:63 #: reportwriter/languages/en_US/reports.php:64 msgid "Date" msgstr "" @@ -962,8 +963,8 @@ #: includes/PDFOstdgGRNsPageHeader.inc:38 #: includes/PDFStockLocTransferHeader.inc:65 #: includes/PDFStockTransferHeader.inc:36 includes/PDFTopItemsHeader.inc:50 -#: includes/PDFTransPageHeader.inc:208 -#: includes/PDFTransPageHeaderPortrait.inc:265 +#: includes/PDFTransPageHeader.inc:211 +#: includes/PDFTransPageHeaderPortrait.inc:267 #: includes/DefineLabelClass.php:12 includes/DefineLabelClass.php:45 #: ../webSHOP/includes/PlaceOrder.php:236 msgid "Description" @@ -989,7 +990,7 @@ #: ConfirmDispatch_Invoice.php:309 CounterReturns.php:676 #: CounterReturns.php:756 CounterSales.php:759 CounterSales.php:853 #: CounterSales.php:855 Credit_Invoice.php:298 Credit_Invoice.php:302 -#: CustomerAllocations.php:348 CustomerAllocations.php:378 +#: CustomerAllocations.php:349 CustomerAllocations.php:379 #: CustomerInquiry.php:222 DeliveryDetails.php:876 DeliveryDetails.php:945 #: GLBalanceSheet.php:191 GLBalanceSheet.php:203 GLBalanceSheet.php:293 #: GLBalanceSheet.php:302 GLBudgets.php:213 GLJournal.php:435 @@ -1011,8 +1012,8 @@ #: SupplierCredit.php:407 SupplierInquiry.php:214 #: Z_CheckDebtorsControl.php:149 api/api_debtortransactions.php:1271 #: api/api_debtortransactions.php:1284 api/api_debtortransactions.php:1581 -#: includes/PDFQuotationPageHeader.inc:89 -#: includes/PDFQuotationPortraitPageHeader.inc:104 +#: includes/PDFQuotationPageHeader.inc:109 +#: includes/PDFQuotationPortraitPageHeader.inc:100 #: includes/PO_PDFOrderPageHeader.inc:81 #: reportwriter/languages/en_US/reports.php:107 #: ../webSHOP/includes/DisplayShoppingCart.php:7 @@ -1064,7 +1065,7 @@ msgstr "" #: AgedDebtors.php:269 CustomerInquiry.php:91 CustomerInquiry.php:116 -#: CustomerPurchases.php:25 Dashboard.php:143 DebtorsAtPeriodEnd.php:59 +#: CustomerPurchases.php:25 Dashboard.php:142 DebtorsAtPeriodEnd.php:59 msgid "The customer details could not be retrieved by the SQL because" msgstr "" @@ -1072,8 +1073,8 @@ #: AgedSuppliers.php:111 AgedSuppliers.php:198 BOMExtendedQty.php:157 #: BOMExtendedQty.php:244 BOMIndented.php:155 BOMIndented.php:236 #: BOMIndentedReverse.php:144 BOMIndentedReverse.php:222 BOMListing.php:45 -#: Credit_Invoice.php:201 Dashboard.php:144 Dashboard.php:255 -#: Dashboard.php:426 DebtorsAtPeriodEnd.php:60 DebtorsAtPeriodEnd.php:72 +#: Credit_Invoice.php:201 Dashboard.php:143 Dashboard.php:254 +#: Dashboard.php:425 DebtorsAtPeriodEnd.php:60 DebtorsAtPeriodEnd.php:72 #: FTP_RadioBeacon.php:187 GLBalanceSheet.php:112 GLBalanceSheet.php:150 #: GLBalanceSheet.php:329 GLProfit_Loss.php:188 GLProfit_Loss.php:200 #: GLTagProfit_Loss.php:198 GLTagProfit_Loss.php:211 GLTrialBalance.php:168 @@ -1095,8 +1096,8 @@ #: OutstandingGRNs.php:49 OutstandingGRNs.php:62 PDFCustomerList.php:235 #: PDFCustomerList.php:247 PDFFGLabel.php:217 PDFGLJournal.php:100 #: PDFGrn.php:176 PDFLowGP.php:59 PDFLowGP.php:71 PDFPriceList.php:143 -#: PDFPrintLabel.php:45 PDFQALabel.php:116 PDFQuotation.php:270 -#: PDFQuotationPortrait.php:274 PDFRemittanceAdvice.php:83 +#: PDFPrintLabel.php:45 PDFQALabel.php:116 PDFQuotation.php:276 +#: PDFQuotationPortrait.php:268 PDFRemittanceAdvice.php:83 #: PDFSellThroughSupportClaim.php:74 PDFSellThroughSupportClaim.php:86 #: PDFStockCheckComparison.php:37 PDFStockCheckComparison.php:63 #: PDFStockCheckComparison.php:269 PDFWOPrint.php:109 PO_PDFPurchOrder.php:31 @@ -1126,11 +1127,11 @@ msgid "Back to the menu" msgstr "" -#: AgedDebtors.php:371 Dashboard.php:254 +#: AgedDebtors.php:371 Dashboard.php:253 msgid "The details of outstanding transactions for customer" msgstr "" -#: AgedDebtors.php:371 AgedSuppliers.php:197 Dashboard.php:254 +#: AgedDebtors.php:371 AgedSuppliers.php:197 Dashboard.php:253 #: GLAccountCSV.php:175 GLAccountInquiry.php:162 GLAccountReport.php:97 #: PO_Items.php:451 PO_Items.php:580 PO_Items.php:605 #: PurchaseByPrefSupplier.php:29 PurchaseByPrefSupplier.php:54 @@ -1147,7 +1148,7 @@ #: Credit_Invoice.php:747 Credit_Invoice.php:768 CustItem.php:73 #: CustItem.php:86 CustItem.php:197 CustomerReceipt.php:574 #: CustomerReceipt.php:724 CustomerReceipt.php:752 CustomerTransInquiry.php:97 -#: Dashboard.php:257 Dashboard.php:428 DeliveryDetails.php:409 +#: Dashboard.php:256 Dashboard.php:427 DeliveryDetails.php:409 #: GLProfit_Loss.php:609 GLTagProfit_Loss.php:515 PDFRemittanceAdvice.php:85 #: Payments.php:362 PurchData.php:114 PurchData.php:132 PurchData.php:360 #: RecurringSalesOrders.php:267 ReverseGRN.php:192 ReverseGRN.php:206 @@ -1480,7 +1481,7 @@ msgid "Containing text" msgstr "" -#: AuditTrail.php:90 InternalStockRequest.php:593 LocationUsers.php:173 +#: AuditTrail.php:90 InternalStockRequest.php:593 LocationUsers.php:176 #: MRPReport.php:779 PO_SelectPurchOrder.php:432 SelectContract.php:187 #: SelectProduct.php:815 msgid "View" @@ -1491,13 +1492,13 @@ msgstr "" #: AuditTrail.php:176 BankAccountUsers.php:71 BankAccountUsers.php:84 -#: LocationUsers.php:74 LocationUsers.php:87 LocationUsers.php:97 +#: LocationUsers.php:77 LocationUsers.php:90 LocationUsers.php:100 #: PcReportTab.php:268 includes/header.inc:59 msgid "User" msgstr "" #: AuditTrail.php:177 BankReconciliation.php:218 BankReconciliation.php:295 -#: CustWhereAlloc.php:21 CustWhereAlloc.php:111 CustomerAllocations.php:375 +#: CustWhereAlloc.php:21 CustWhereAlloc.php:111 CustomerAllocations.php:376 #: CustomerInquiry.php:216 CustomerPurchases.php:77 #: CustomerTransInquiry.php:25 CustomerTransInquiry.php:104 #: DailyBankTransactions.php:130 GLAccountInquiry.php:172 @@ -1611,13 +1612,13 @@ #: includes/PDFInventoryValnPageHeader.inc:39 #: includes/PDFOrderPageHeader_generic.inc:93 #: includes/PDFPeriodStockTransListingPageHeader.inc:50 -#: includes/PDFPickingListHeader.inc:74 includes/PDFQuotationPageHeader.inc:78 -#: includes/PDFQuotationPortraitPageHeader.inc:99 +#: includes/PDFPickingListHeader.inc:74 includes/PDFQuotationPageHeader.inc:98 +#: includes/PDFQuotationPortraitPageHeader.inc:95 #: includes/PDFSalesOrder_generic.inc:95 #: includes/PDFSellThroughSupportClaimPageHeader.inc:27 #: includes/PDFStockCheckPageHeader.inc:36 #: includes/PDFStockNegativesHeader.inc:33 -#: includes/PDFStockTransferHeader.inc:39 includes/PDFTransPageHeader.inc:210 +#: includes/PDFStockTransferHeader.inc:39 includes/PDFTransPageHeader.inc:213 #: includes/PO_PDFOrderPageHeader.inc:77 includes/InputSerialItems.php:131 #: includes/InputSerialItems.php:137 includes/InputSerialItemsFile.php:200 #: includes/OutputSerialItems.php:38 includes/OutputSerialItems.php:43 @@ -1731,8 +1732,8 @@ #: includes/PDFPeriodStockTransListingPageHeader.inc:25 #: includes/PDFPickingListHeader.inc:69 #: includes/PDFProfitAndLossPageHeader.inc:28 -#: includes/PDFQuotationPageHeader.inc:20 -#: includes/PDFQuotationPortraitPageHeader.inc:89 +#: includes/PDFQuotationPageHeader.inc:24 +#: includes/PDFQuotationPortraitPageHeader.inc:81 #: includes/PDFSalesAnalPageHeader.inc:15 #: includes/PDFSalesOrder_generic.inc:85 #: includes/PDFSellThroughSupportClaimPageHeader.inc:16 @@ -1748,8 +1749,8 @@ #: includes/PDFTabReportHeader.inc:15 #: includes/PDFTagProfitAndLossPageHeader.inc:30 #: includes/PDFTaxPageHeader.inc:21 includes/PDFTopItemsHeader.inc:34 -#: includes/PDFTransPageHeader.inc:65 -#: includes/PDFTransPageHeaderPortrait.inc:26 +#: includes/PDFTransPageHeader.inc:68 +#: includes/PDFTransPageHeaderPortrait.inc:29 #: includes/PDFTrialBalancePageHeader.inc:18 includes/PDFWOPageHeader.inc:12 #: includes/PO_PDFOrderPageHeader.inc:17 #: reportwriter/languages/en_US/reports.php:86 @@ -2365,7 +2366,7 @@ msgstr "" #: BOMs.php:563 BOMs.php:701 Contracts.php:876 FixedAssetRegister.php:89 -#: InventoryQuantities.php:247 LocationUsers.php:150 Locations.php:368 +#: InventoryQuantities.php:247 LocationUsers.php:153 Locations.php:368 #: MRP.php:564 MRP.php:597 NoSalesItems.php:192 PDFOrderStatus.php:296 #: PDFOrdersInvoiced.php:296 ReorderLevel.php:290 ReorderLevel.php:299 #: ReorderLevelLocation.php:164 StockCounts.php:214 StockReorderLevel.php:58 @@ -2531,7 +2532,7 @@ msgid "You have not selected an user to be authorised to use this bank account" msgstr "" -#: BankAccountUsers.php:63 LocationUsers.php:62 +#: BankAccountUsers.php:63 LocationUsers.php:65 msgid "The user" msgstr "" @@ -2561,7 +2562,7 @@ #: BankAccountUsers.php:105 BankAccountUsers.php:205 #: InternalStockCategoriesByRole.php:120 InternalStockCategoriesByRole.php:209 -#: LocationUsers.php:116 LocationUsers.php:227 PcClaimExpensesFromTab.php:157 +#: LocationUsers.php:119 LocationUsers.php:230 PcClaimExpensesFromTab.php:157 #: PcClaimExpensesFromTab.php:377 PcExpenses.php:310 PcExpensesTypeTab.php:123 #: PcExpensesTypeTab.php:212 PurchaseByPrefSupplier.php:317 #: StockCounts.php:121 @@ -2572,7 +2573,7 @@ #: CustomerReceipt.php:1159 CustomerTypes.php:269 ExchangeRateTrend.php:51 #: FreightCosts.php:60 GLJournal.php:139 GLJournal.php:377 #: InternalStockCategoriesByRole.php:136 InternalStockCategoriesByRole.php:226 -#: LocationUsers.php:133 LocationUsers.php:246 OffersReceived.php:114 +#: LocationUsers.php:136 LocationUsers.php:249 OffersReceived.php:114 #: Payments.php:1072 PcAssignCashToTab.php:181 PcAssignCashToTab.php:398 #: PcAuthorizeExpenses.php:334 PcClaimExpensesFromTab.php:174 #: PcClaimExpensesFromTab.php:422 PcExpenses.php:350 PcExpensesTypeTab.php:139 @@ -2582,19 +2583,19 @@ msgstr "" #: BankAccountUsers.php:124 BankAccountUsers.php:223 -#: CustomerAllocations.php:449 CustomerReceipt.php:1160 +#: CustomerAllocations.php:450 CustomerReceipt.php:1160 #: InternalStockCategoriesByRole.php:137 InternalStockCategoriesByRole.php:227 -#: LocationUsers.php:134 LocationUsers.php:247 Payments.php:1073 +#: LocationUsers.php:137 LocationUsers.php:250 Payments.php:1073 #: PcAssignCashToTab.php:182 PcAssignCashToTab.php:399 #: PcAuthorizeExpenses.php:335 PcClaimExpensesFromTab.php:175 #: PcClaimExpensesFromTab.php:423 PcExpenses.php:351 PcExpensesTypeTab.php:140 #: PcExpensesTypeTab.php:230 PcTabs.php:488 PcTypeTabs.php:254 -#: SalesTypes.php:274 Z_CheckDebtorsControl.php:62 +#: SalesTypes.php:274 SelectCreditItems.php:957 Z_CheckDebtorsControl.php:62 #: reportwriter/languages/en_US/reports.php:134 msgid "Cancel" msgstr "" -#: BankAccountUsers.php:141 LocationUsers.php:150 +#: BankAccountUsers.php:141 LocationUsers.php:153 msgid "Authorised users for" msgstr "" @@ -2602,27 +2603,27 @@ msgid "Authorised users for bank account" msgstr "" -#: BankAccountUsers.php:161 LocationUsers.php:171 +#: BankAccountUsers.php:161 LocationUsers.php:174 msgid "User Code" msgstr "" -#: BankAccountUsers.php:162 LocationUsers.php:172 +#: BankAccountUsers.php:162 LocationUsers.php:175 #: PO_AuthorisationLevels.php:125 PcTabs.php:206 PcTabs.php:307 #: SMTPServer.php:110 UserSettings.php:117 msgid "User Name" msgstr "" -#: BankAccountUsers.php:178 LocationUsers.php:199 +#: BankAccountUsers.php:178 LocationUsers.php:202 #, php-format msgid "Are you sure you wish to un-authorise this user?" msgstr "" -#: BankAccountUsers.php:178 LocationUsers.php:199 +#: BankAccountUsers.php:178 LocationUsers.php:202 #, php-format msgid "Un-authorise" msgstr "" -#: BankAccountUsers.php:196 LocationUsers.php:219 +#: BankAccountUsers.php:196 LocationUsers.php:222 msgid "Select User" msgstr "" @@ -2703,11 +2704,11 @@ msgid "Bank account deleted" msgstr "" -#: BankAccounts.php:185 Dashboard.php:547 +#: BankAccounts.php:185 Dashboard.php:546 msgid "The bank accounts set up could not be retrieved because" msgstr "" -#: BankAccounts.php:186 Dashboard.php:548 +#: BankAccounts.php:186 Dashboard.php:547 msgid "The SQL used to retrieve the bank account details was" msgstr "" @@ -2732,7 +2733,7 @@ msgstr "" #: BankAccounts.php:196 Currencies.php:449 CustItem.php:299 CustItem.php:415 -#: CustomerAllocations.php:350 CustomerReceipt.php:836 +#: CustomerAllocations.php:351 CustomerReceipt.php:836 #: CustomerTransInquiry.php:114 OffersReceived.php:112 #: PO_AuthorisationLevels.php:126 PO_AuthorisationLevels.php:210 #: PO_AuthorisationLevels.php:216 PO_AuthoriseMyOrders.php:115 @@ -2977,7 +2978,7 @@ msgstr "" #: BankMatching.php:284 ConfirmDispatch_Invoice.php:308 Credit_Invoice.php:301 -#: CustWhereAlloc.php:115 CustomerAllocations.php:378 CustomerReceipt.php:964 +#: CustWhereAlloc.php:115 CustomerAllocations.php:379 CustomerReceipt.php:964 #: CustomerTransInquiry.php:113 GLJournalInquiry.php:85 #: ImportBankTransAnalysis.php:208 ImportBankTransAnalysis.php:288 #: PaymentAllocations.php:67 Payments.php:1060 Payments.php:1065 @@ -3109,8 +3110,8 @@ msgstr "" #: BankReconciliation.php:219 BankReconciliation.php:296 -#: CustWhereAlloc.php:112 CustomerAllocations.php:346 -#: CustomerAllocations.php:376 CustomerInquiry.php:217 +#: CustWhereAlloc.php:112 CustomerAllocations.php:347 +#: CustomerAllocations.php:377 CustomerInquiry.php:217 #: CustomerTransInquiry.php:105 EmailCustTrans.php:15 GLAccountInquiry.php:173 #: ImportBankTrans.php:538 PrintCustTrans.php:511 PrintCustTrans.php:735 #: PrintCustTrans.php:968 PrintCustTrans.php:1017 @@ -3119,18 +3120,18 @@ #: StockMovements.php:98 SupplierAllocations.php:455 #: SupplierAllocations.php:568 SupplierAllocations.php:643 #: SupplierInquiry.php:211 SupplierTransInquiry.php:103 Z_CheckAllocs.php:63 -#: Z_CheckGLTransBalance.php:12 includes/PDFQuotationPageHeader.inc:17 -#: includes/PDFQuotationPortraitPageHeader.inc:86 +#: Z_CheckGLTransBalance.php:12 includes/PDFQuotationPageHeader.inc:21 +#: includes/PDFQuotationPortraitPageHeader.inc:78 #: includes/PDFStatementPageHeader.inc:168 -#: includes/PDFStatementPageHeader.inc:179 includes/PDFTransPageHeader.inc:44 -#: includes/PDFTransPageHeaderPortrait.inc:54 +#: includes/PDFStatementPageHeader.inc:179 includes/PDFTransPageHeader.inc:47 +#: includes/PDFTransPageHeaderPortrait.inc:57 msgid "Number" msgstr "" #: BankReconciliation.php:220 BankReconciliation.php:297 #: ContractCosting.php:176 CustWhereAlloc.php:113 CustomerInquiry.php:218 #: CustomerPurchases.php:84 CustomerReceipt.php:928 -#: CustomerTransInquiry.php:109 DailyBankTransactions.php:131 Dashboard.php:55 +#: CustomerTransInquiry.php:109 DailyBankTransactions.php:131 Dashboard.php:54 #: GLAccountReport.php:342 PDFRemittanceAdvice.php:309 #: PaymentAllocations.php:64 PaymentAllocations.php:65 Payments.php:921 #: ShiptsList.php:37 StockCounts.php:144 StockCounts.php:169 @@ -3266,7 +3267,7 @@ msgid "Are you sure you wish to delete this COGS GL posting record?" msgstr "" -#: COGSGLPostings.php:200 CustomerReceipt.php:1091 Dashboard.php:533 +#: COGSGLPostings.php:200 CustomerReceipt.php:1091 Dashboard.php:532 #: GLJournal.php:388 GLTransInquiry.php:44 Payments.php:1082 #: SupplierTransInquiry.php:172 TaxAuthorities.php:148 TaxAuthorities.php:149 msgid "GL Account" @@ -3564,14 +3565,14 @@ #: GoodsReceived.php:270 GoodsReceived.php:766 ImportBankTransAnalysis.php:154 #: ImportBankTransAnalysis.php:185 InternalStockRequest.php:250 #: InternalStockRequestAuthorisation.php:123 -#: InternalStockRequestFulfill.php:362 LocationUsers.php:174 +#: InternalStockRequestFulfill.php:362 LocationUsers.php:177 #: MRPCalendar.php:315 PO_AuthoriseMyOrders.php:142 Payments.php:933 #: PcAuthorizeExpenses.php:108 PcAuthorizeExpenses.php:293 #: PricesByCost.php:223 PurchData.php:758 ReorderLevelLocation.php:140 -#: SMTPServer.php:122 SecurityTokens.php:97 SellThroughSupport.php:476 -#: ShopParameters.php:610 StockCostUpdate.php:195 StockReorderLevel.php:111 -#: Stocks.php:1403 SystemParameters.php:1140 TaxAuthorityRates.php:84 -#: WOSerialNos.php:337 WorkOrderEntry.php:659 +#: SMTPServer.php:122 SecurityTokens.php:97 SelectCreditItems.php:956 +#: SellThroughSupport.php:476 ShopParameters.php:610 StockCostUpdate.php:195 +#: StockReorderLevel.php:111 Stocks.php:1403 SystemParameters.php:1140 +#: TaxAuthorityRates.php:84 WOSerialNos.php:337 WorkOrderEntry.php:659 #: reportwriter/languages/en_US/reports.php:156 msgid "Update" msgstr "" @@ -3621,7 +3622,7 @@ msgstr "" #: ConfirmDispatchControlled_Invoice.php:66 CounterSales.php:1323 -#: Dashboard.php:360 DeliveryDetails.php:610 DeliveryDetails.php:831 +#: Dashboard.php:359 DeliveryDetails.php:610 DeliveryDetails.php:831 #: EmailCustTrans.php:9 PaymentAllocations.php:31 SelectSalesOrder.php:695 #: SelectSalesOrder.php:767 SelectSalesOrder.php:794 #: Z_SalesIntegrityCheck.php:46 @@ -3698,12 +3699,12 @@ msgstr "" #: ConfirmDispatch_Invoice.php:279 Contracts.php:778 CustItem.php:144 -#: CustLoginSetup.php:32 CustomerAllocations.php:344 CustomerBranches.php:403 +#: CustLoginSetup.php:32 CustomerAllocations.php:345 CustomerBranches.php:403 #: CustomerBranches.php:586 CustomerBranches.php:633 CustomerInquiry.php:132 #: CustomerInquiry.php:133 CustomerPurchases.php:30 CustomerReceipt.php:966 #: CustomerReceipt.php:1022 CustomerReceipt.php:1170 #: CustomerTransInquiry.php:107 Customers.php:25 Customers.php:348 -#: Dashboard.php:54 Dashboard.php:668 DeliveryDetails.php:850 +#: Dashboard.php:53 Dashboard.php:667 DeliveryDetails.php:850 #: FTP_RadioBeacon.php:51 PDFOrderStatus.php:293 PDFOrdersInvoiced.php:292 #: PricesByCost.php:154 SalesGraph.php:185 SalesTopCustomersInquiry.php:214 #: SelectCompletedOrder.php:556 SelectContract.php:148 @@ -3730,8 +3731,8 @@ #: SalesInquiry.php:951 SalesInquiry.php:966 SalesInquiry.php:972 #: SalesInquiry.php:1230 WWW_Users.php:298 WWW_Users.php:540 #: Z_ChangeBranchCode.php:202 includes/PDFStatementPageHeader.inc:112 -#: includes/PDFTransPageHeader.inc:46 -#: includes/PDFTransPageHeaderPortrait.inc:57 +#: includes/PDFTransPageHeader.inc:49 +#: includes/PDFTransPageHeaderPortrait.inc:60 msgid "Customer Code" msgstr "" @@ -3771,12 +3772,12 @@ #: SupplierInvoice.php:663 SupplierTenders.php:122 SupplierTenders.php:528 #: SupplierTenders.php:530 Z_ItemsWithoutPicture.php:32 #: includes/PDFOrderPageHeader_generic.inc:91 -#: includes/PDFPickingListHeader.inc:72 includes/PDFQuotationPageHeader.inc:73 -#: includes/PDFQuotationPortraitPageHeader.inc:97 +#: includes/PDFPickingListHeader.inc:72 includes/PDFQuotationPageHeader.inc:93 +#: includes/PDFQuotationPortraitPageHeader.inc:93 #: includes/PDFSalesOrder_generic.inc:93 #: includes/PDFStockLocTransferHeader.inc:64 -#: includes/PDFTransPageHeader.inc:207 -#: includes/PDFTransPageHeaderPortrait.inc:264 +#: includes/PDFTransPageHeader.inc:210 +#: includes/PDFTransPageHeaderPortrait.inc:266 msgid "Item Code" msgstr "" @@ -3795,8 +3796,8 @@ #: SpecialOrder.php:627 StockLocTransferReceive.php:455 #: SupplierTenders.php:123 SupplierTenders.php:529 #: includes/PDFOrderPageHeader_generic.inc:92 -#: includes/PDFPickingListHeader.inc:73 includes/PDFQuotationPageHeader.inc:77 -#: includes/PDFQuotationPortraitPageHeader.inc:98 +#: includes/PDFPickingListHeader.inc:73 includes/PDFQuotationPageHeader.inc:97 +#: includes/PDFQuotationPortraitPageHeader.inc:94 #: includes/PDFSalesOrder_generic.inc:94 #: includes/PDFStockNegativesHeader.inc:32 includes/PDFWOPageHeader.inc:43 #: includes/PDFWOPageHeader.inc:70 includes/PO_PDFOrderPageHeader.inc:76 @@ -3841,9 +3842,9 @@ #: SuppCreditGRNs.php:197 SuppCreditGRNs.php:293 SuppCreditGRNs.php:294 #: SuppPriceList.php:311 SupplierPriceList.php:534 SupplierTenders.php:127 #: SupplierTenders.php:329 SupplierTenders.php:537 SupplierTenders.php:691 -#: api/api_xml-rpc.php:981 includes/PDFQuotationPageHeader.inc:79 -#: includes/PDFQuotationPortraitPageHeader.inc:100 -#: includes/PDFTransPageHeaderPortrait.inc:270 +#: api/api_xml-rpc.php:981 includes/PDFQuotationPageHeader.inc:99 +#: includes/PDFQuotationPortraitPageHeader.inc:96 +#: includes/PDFTransPageHeaderPortrait.inc:272 #: includes/PO_PDFOrderPageHeader.inc:80 includes/DefineLabelClass.php:49 #: ../webSHOP/includes/DisplayShoppingCart.php:9 #: ../webSHOP/includes/Functions.php:59 @@ -3858,9 +3859,9 @@ #: PurchData.php:700 PurchData.php:701 RecurringSalesOrders.php:334 #: SalesAnalReptCols.php:41 SalesAnalReptCols.php:43 SelectCreditItems.php:691 #: SelectOrderItems.php:1298 StockLocMovements.php:97 StockMovements.php:105 -#: StockStatus.php:365 includes/PDFQuotationPageHeader.inc:80 -#: includes/PDFQuotationPortraitPageHeader.inc:101 -#: includes/PDFTransPageHeader.inc:212 +#: StockStatus.php:365 includes/PDFQuotationPageHeader.inc:100 +#: includes/PDFQuotationPortraitPageHeader.inc:97 +#: includes/PDFTransPageHeader.inc:215 msgid "Discount" msgstr "" @@ -4717,7 +4718,7 @@ #: ConfirmDispatch_Invoice.php:1650 ConfirmDispatch_Invoice.php:1652 #: ContractBOM.php:299 CounterReturns.php:1601 CounterReturns.php:1603 #: CounterSales.php:2067 CounterSales.php:2069 CustomerReceipt.php:579 -#: Dashboard.php:748 DeliveryDetails.php:601 DeliveryDetails.php:605 +#: Dashboard.php:747 DeliveryDetails.php:601 DeliveryDetails.php:605 #: DeliveryDetails.php:823 DeliveryDetails.php:827 GLBalanceSheet.php:22 #: GLJournalInquiry.php:113 GLProfit_Loss.php:25 GLTagProfit_Loss.php:25 #: GLTagProfit_Loss.php:523 GLTags.php:54 GLTransInquiry.php:36 @@ -4902,8 +4903,8 @@ #: ContractBOM.php:244 InternalStockRequest.php:274 #: SupplierTenderCreate.php:436 SupplierTenders.php:328 -#: includes/PDFTransPageHeader.inc:211 -#: includes/PDFTransPageHeaderPortrait.inc:268 +#: includes/PDFTransPageHeader.inc:214 +#: includes/PDFTransPageHeaderPortrait.inc:270 msgid "UOM" msgstr "" @@ -5087,7 +5088,7 @@ msgid "Budgeted Other Costs" msgstr "" -#: ContractCosting.php:175 Dashboard.php:358 OffersReceived.php:106 +#: ContractCosting.php:175 Dashboard.php:357 OffersReceived.php:106 #: OutstandingGRNs.php:177 PO_AuthoriseMyOrders.php:59 #: PO_SelectOSPurchOrder.php:515 PO_SelectPurchOrder.php:433 PurchData.php:271 #: ReprintGRN.php:83 SelectProduct.php:354 SelectSupplier.php:161 @@ -5668,7 +5669,7 @@ msgstr "" #: Contracts.php:779 CustomerInquiry.php:220 CustomerTransInquiry.php:108 -#: Dashboard.php:669 FTP_RadioBeacon.php:52 PDFOrderStatus.php:294 +#: Dashboard.php:668 FTP_RadioBeacon.php:52 PDFOrderStatus.php:294 #: PDFOrdersInvoiced.php:293 PDFPriceList.php:390 PricesByCost.php:155 #: Prices_Customer.php:263 Prices_Customer.php:337 PrintCustTrans.php:846 #: PrintCustTransPortrait.php:892 SelectCompletedOrder.php:557 @@ -5677,8 +5678,8 @@ #: SelectSalesOrder.php:715 StockMovements.php:101 #: StockSerialItemResearch.php:84 includes/PDFDIFOTPageHeader.inc:44 #: includes/PDFDeliveryDifferencesPageHeader.inc:45 -#: includes/PDFOrderPageHeader.inc:50 includes/PDFTransPageHeader.inc:47 -#: includes/PDFTransPageHeaderPortrait.inc:58 +#: includes/PDFOrderPageHeader.inc:50 includes/PDFTransPageHeader.inc:50 +#: includes/PDFTransPageHeaderPortrait.inc:61 msgid "Branch" msgstr "" @@ -5691,11 +5692,11 @@ #: Factors.php:242 PDFCustomerList.php:344 PDFRemittanceAdvice.php:249 #: SelectCreditItems.php:246 SelectCustomer.php:426 SelectOrderItems.php:598 #: includes/PDFOrderPageHeader_generic.inc:32 -#: includes/PDFPickingListHeader.inc:24 includes/PDFQuotationPageHeader.inc:34 -#: includes/PDFQuotationPortraitPageHeader.inc:22 +#: includes/PDFPickingListHeader.inc:24 includes/PDFQuotationPageHeader.inc:40 +#: includes/PDFQuotationPortraitPageHeader.inc:34 #: includes/PDFSalesOrder_generic.inc:34 -#: includes/PDFStatementPageHeader.inc:65 includes/PDFTransPageHeader.inc:81 -#: includes/PDFTransPageHeaderPortrait.inc:109 includes/PDFWOPageHeader.inc:18 +#: includes/PDFStatementPageHeader.inc:65 includes/PDFTransPageHeader.inc:84 +#: includes/PDFTransPageHeaderPortrait.inc:112 includes/PDFWOPageHeader.inc:18 #: includes/PO_PDFOrderPageHeader.inc:28 msgid "Fax" msgstr "" @@ -5703,10 +5704,10 @@ #: Contracts.php:829 CustomerInquiry.php:135 CustomerReceipt.php:1022 #: PDFRemittanceAdvice.php:275 PO_Header.php:606 PrintCustTrans.php:883 #: PrintCustTransPortrait.php:933 SupplierInquiry.php:120 -#: includes/PDFQuotationPageHeader.inc:67 -#: includes/PDFQuotationPortraitPageHeader.inc:91 -#: includes/PDFStatementPageHeader.inc:116 includes/PDFTransPageHeader.inc:159 -#: includes/PDFTransPageHeaderPortrait.inc:212 +#: includes/PDFQuotationPageHeader.inc:88 +#: includes/PDFQuotationPortraitPageHeader.inc:88 +#: includes/PDFStatementPageHeader.inc:116 includes/PDFTransPageHeader.inc:162 +#: includes/PDFTransPageHeaderPortrait.inc:214 #: includes/PO_PDFOrderPageHeader.inc:71 msgid "All amounts stated in" msgstr "" @@ -5974,8 +5975,8 @@ msgid "against customer code" msgstr "" -#: CounterReturns.php:154 CounterSales.php:168 Dashboard.php:602 -#: Dashboard.php:621 DeliveryDetails.php:163 GLAccountCSV.php:189 +#: CounterReturns.php:154 CounterSales.php:168 Dashboard.php:601 +#: Dashboard.php:620 DeliveryDetails.php:163 GLAccountCSV.php:189 #: GLAccountCSV.php:218 GLAccountInquiry.php:195 GLAccountInquiry.php:233 #: GLAccountReport.php:118 SelectOrderItems.php:432 msgid "could not be retrieved" @@ -6147,7 +6148,7 @@ msgstr "" #: CounterReturns.php:787 CounterSales.php:884 Credit_Invoice.php:1570 -#: DeliveryDetails.php:1110 +#: DeliveryDetails.php:1110 SelectCreditItems.php:924 msgid "Sales person" msgstr "" @@ -6924,7 +6925,7 @@ msgid "The credit quantity for the line for" msgstr "" -#: Credit_Invoice.php:506 +#: Credit_Invoice.php:506 SelectCreditItems.php:952 msgid "" "The GL code to write off the credit value to must be specified. Please " "select the appropriate GL code for the selection box" @@ -7069,7 +7070,7 @@ msgid "Goods returned to location" msgstr "" -#: Credit_Invoice.php:1544 +#: Credit_Invoice.php:1544 SelectCreditItems.php:902 msgid "Write off the cost of the goods to" msgstr "" @@ -7860,157 +7861,157 @@ msgid "Receipt" msgstr "" -#: CustWhereAlloc.php:156 CustomerAllocations.php:74 +#: CustWhereAlloc.php:156 CustomerAllocations.php:75 #: SupplierAllocations.php:92 msgid "Total allocated" msgstr "" -#: CustomerAllocations.php:11 +#: CustomerAllocations.php:13 msgid "Customer Receipt" msgstr "" -#: CustomerAllocations.php:11 SupplierAllocations.php:20 +#: CustomerAllocations.php:13 SupplierAllocations.php:20 msgid "Credit Note Allocations" msgstr "" -#: CustomerAllocations.php:27 SupplierAllocations.php:35 +#: CustomerAllocations.php:28 SupplierAllocations.php:35 msgid "Allocations can not be processed again" msgstr "" -#: CustomerAllocations.php:28 SupplierAllocations.php:36 +#: CustomerAllocations.php:29 SupplierAllocations.php:36 msgid "" "If you hit refresh on this page after having just processed an allocation" msgstr "" -#: CustomerAllocations.php:29 +#: CustomerAllocations.php:30 msgid "try to use the navigation links provided rather than the back button" msgstr "" -#: CustomerAllocations.php:30 +#: CustomerAllocations.php:31 msgid "to avoid this message in future" msgstr "" -#: CustomerAllocations.php:50 +#: CustomerAllocations.php:51 msgid "Amount entered was negative" msgstr "" -#: CustomerAllocations.php:50 +#: CustomerAllocations.php:51 msgid "Only positive amounts are allowed" msgstr "" -#: CustomerAllocations.php:74 +#: CustomerAllocations.php:75 msgid "" "Allocation could not be processed because the amount allocated is more than " "the" msgstr "" -#: CustomerAllocations.php:74 SupplierAllocations.php:92 +#: CustomerAllocations.php:75 SupplierAllocations.php:92 msgid "being allocated" msgstr "" -#: CustomerAllocations.php:74 +#: CustomerAllocations.php:75 msgid "and the total amount of the" msgstr "" -#: CustomerAllocations.php:74 +#: CustomerAllocations.php:75 msgid "was" msgstr "" -#: CustomerAllocations.php:92 +#: CustomerAllocations.php:93 msgid "Could not delete old allocation record" msgstr "" -#: CustomerAllocations.php:110 +#: CustomerAllocations.php:111 msgid "Could not change allocation record" msgstr "" -#: CustomerAllocations.php:123 +#: CustomerAllocations.php:124 msgid "Could not update difference on exchange" msgstr "" -#: CustomerAllocations.php:139 +#: CustomerAllocations.php:140 msgid "Could not update receipt or credit note" msgstr "" -#: CustomerAllocations.php:168 +#: CustomerAllocations.php:169 msgid "Could not update exchange difference in General Ledger" msgstr "" -#: CustomerAllocations.php:189 +#: CustomerAllocations.php:190 msgid "Could not update debtors control in General Ledger" msgstr "" -#: CustomerAllocations.php:339 +#: CustomerAllocations.php:340 msgid "Allocate Receipt" msgstr "" -#: CustomerAllocations.php:339 CustomerReceipt.php:580 +#: CustomerAllocations.php:340 CustomerReceipt.php:580 msgid "Allocate Receipts" msgstr "" -#: CustomerAllocations.php:343 PDFRemittanceAdvice.php:307 +#: CustomerAllocations.php:344 PDFRemittanceAdvice.php:307 #: SupplierAllocations.php:566 SupplierAllocations.php:641 #: includes/PDFStatementPageHeader.inc:167 msgid "Trans Type" msgstr "" -#: CustomerAllocations.php:345 +#: CustomerAllocations.php:346 msgid "Cust No" msgstr "" -#: CustomerAllocations.php:349 SupplierAllocations.php:571 +#: CustomerAllocations.php:350 SupplierAllocations.php:571 #: SupplierAllocations.php:646 msgid "To Alloc" msgstr "" -#: CustomerAllocations.php:351 ReprintGRN.php:90 +#: CustomerAllocations.php:352 ReprintGRN.php:90 #: includes/PDFWOPageHeader.inc:68 msgid "Action" msgstr "" -#: CustomerAllocations.php:370 +#: CustomerAllocations.php:371 msgid "Amount in customer currency" msgstr "" -#: CustomerAllocations.php:370 SupplierAllocations.php:443 +#: CustomerAllocations.php:371 SupplierAllocations.php:443 msgid "converted into local currency at an exchange rate of" msgstr "" -#: CustomerAllocations.php:375 CustomerAllocations.php:376 -#: CustomerAllocations.php:377 SupplierAllocations.php:455 +#: CustomerAllocations.php:376 CustomerAllocations.php:377 +#: CustomerAllocations.php:378 SupplierAllocations.php:455 #: SupplierAllocations.php:456 includes/PDFLowGPPageHeader.inc:43 #: includes/PDFStatementPageHeader.inc:178 msgid "Trans" msgstr "" -#: CustomerAllocations.php:379 SupplierAllocations.php:459 +#: CustomerAllocations.php:380 SupplierAllocations.php:459 msgid "Yet to" msgstr "" -#: CustomerAllocations.php:379 CustomerAllocations.php:514 -#: CustomerAllocations.php:562 CustomerReceipt.php:268 CustomerReceipt.php:580 +#: CustomerAllocations.php:380 CustomerAllocations.php:515 +#: CustomerAllocations.php:563 CustomerReceipt.php:268 CustomerReceipt.php:580 #: SupplierAllocations.php:459 SupplierAllocations.php:595 #: SupplierAllocations.php:671 #, php-format msgid "Allocate" msgstr "" -#: CustomerAllocations.php:380 SupplierAllocations.php:460 +#: CustomerAllocations.php:381 SupplierAllocations.php:460 msgid "This" msgstr "" -#: CustomerAllocations.php:380 CustomerInquiry.php:271 +#: CustomerAllocations.php:381 CustomerInquiry.php:271 #: SupplierAllocations.php:460 SupplierInquiry.php:263 msgid "Allocation" msgstr "" -#: CustomerAllocations.php:381 +#: CustomerAllocations.php:382 msgid "Running" msgstr "" -#: CustomerAllocations.php:381 CustomerAllocations.php:569 -#: CustomerAllocations.php:621 CustomerInquiry.php:224 Dashboard.php:58 -#: Dashboard.php:535 GLAccountInquiry.php:178 SupplierInquiry.php:216 +#: CustomerAllocations.php:382 CustomerAllocations.php:570 +#: CustomerAllocations.php:622 CustomerInquiry.php:224 Dashboard.php:57 +#: Dashboard.php:534 GLAccountInquiry.php:178 SupplierInquiry.php:216 #: includes/PDFAgedDebtorsPageHeader.inc:49 #: includes/PDFAgedSuppliersPageHeader.inc:35 #: includes/PDFDebtorBalsPageHeader.inc:31 @@ -8019,43 +8020,43 @@ msgid "Balance" msgstr "" -#: CustomerAllocations.php:393 +#: CustomerAllocations.php:394 msgid "Being allocated" msgstr "" -#: CustomerAllocations.php:415 +#: CustomerAllocations.php:416 msgid "" "Check this box to allocate the entire amouunt of this transaction. Just " "enter the amount without ticking this check box for a partial allocation" msgstr "" -#: CustomerAllocations.php:424 +#: CustomerAllocations.php:425 msgid "" "Enter the amount of this transaction to be allocated. Nothing should be " "entered here if the entire transaction is to be allocated, use the check box" msgstr "" -#: CustomerAllocations.php:434 SupplierAllocations.php:506 +#: CustomerAllocations.php:435 SupplierAllocations.php:506 msgid "Total Allocated" msgstr "" -#: CustomerAllocations.php:438 SupplierAllocations.php:519 +#: CustomerAllocations.php:439 SupplierAllocations.php:519 msgid "Recalculate Total To Allocate" msgstr "" -#: CustomerAllocations.php:441 SupplierAllocations.php:511 +#: CustomerAllocations.php:442 SupplierAllocations.php:511 msgid "Left to allocate" msgstr "" -#: CustomerAllocations.php:448 SupplierAllocations.php:520 +#: CustomerAllocations.php:449 SupplierAllocations.php:520 msgid "Process Allocations" msgstr "" -#: CustomerAllocations.php:491 +#: CustomerAllocations.php:492 msgid "No outstanding receipts or credits to be allocated for this customer" msgstr "" -#: CustomerAllocations.php:616 SupplierAllocations.php:688 +#: CustomerAllocations.php:617 SupplierAllocations.php:688 msgid "There are no allocations to be done" msgstr "" @@ -8559,7 +8560,7 @@ msgid "Total Balance" msgstr "" -#: CustomerInquiry.php:152 CustomerReceipt.php:1033 Dashboard.php:59 +#: CustomerInquiry.php:152 CustomerReceipt.php:1033 Dashboard.php:58 #: PrintCustStatements.php:394 SalesPeople.php:206 Shipments.php:406 #: StockClone.php:871 StockClone.php:873 Stocks.php:1180 Stocks.php:1182 #: SupplierInquiry.php:145 includes/PDFAgedDebtorsPageHeader.inc:50 @@ -9729,38 +9730,38 @@ msgid "Avg Daily Sales" msgstr "" -#: Dashboard.php:7 Dashboard.php:11 +#: Dashboard.php:6 Dashboard.php:10 msgid "Dashboard" msgstr "" -#: Dashboard.php:16 Dashboard.php:43 +#: Dashboard.php:15 Dashboard.php:42 msgid "The security for Aging Debtors cannot be retrieved because" msgstr "" -#: Dashboard.php:17 Dashboard.php:26 Dashboard.php:35 Dashboard.php:44 +#: Dashboard.php:16 Dashboard.php:25 Dashboard.php:34 Dashboard.php:43 #: SalesPeople.php:125 msgid "The SQL that was used and failed was" msgstr "" -#: Dashboard.php:25 +#: Dashboard.php:24 msgid "The security for upcoming payments cannot be retrieved because" msgstr "" -#: Dashboard.php:34 +#: Dashboard.php:33 msgid "The security for G/L Accounts cannot be retrieved because" msgstr "" -#: Dashboard.php:50 +#: Dashboard.php:49 msgid "Overdue Customer Balances" msgstr "" -#: Dashboard.php:56 includes/PDFCustTransListingPageHeader.inc:50 +#: Dashboard.php:55 includes/PDFCustTransListingPageHeader.inc:50 #: includes/PDFPeriodStockTransListingPageHeader.inc:49 #: includes/PDFSuppTransListingPageHeader.inc:50 msgid "Trans Date" msgstr "" -#: Dashboard.php:57 Dashboard.php:362 EmailConfirmation.php:221 +#: Dashboard.php:56 Dashboard.php:361 EmailConfirmation.php:221 #: EmailConfirmation.php:351 MRPDemands.php:298 MRPDemands.php:399 #: MRPPlannedPurchaseOrders.php:339 MRPPlannedWorkOrders.php:260 #: MRPPlannedWorkOrders.php:393 MRPReport.php:414 MRPReport.php:420 @@ -9769,46 +9770,50 @@ msgid "Due Date" msgstr "" -#: Dashboard.php:60 includes/PDFAgedDebtorsPageHeader.inc:51 +#: Dashboard.php:59 includes/PDFAgedDebtorsPageHeader.inc:51 #: includes/PDFAgedSuppliersPageHeader.inc:37 msgid "Due Now" msgstr "" -#: Dashboard.php:61 Dashboard.php:62 includes/PDFAgedDebtorsPageHeader.inc:52 +#: Dashboard.php:60 Dashboard.php:61 includes/PDFAgedDebtorsPageHeader.inc:52 #: includes/PDFAgedDebtorsPageHeader.inc:53 #: includes/PDFAgedSuppliersPageHeader.inc:38 #: includes/PDFAgedSuppliersPageHeader.inc:39 msgid "Days Over" msgstr "" -#: Dashboard.php:334 POReport.php:610 POReport.php:697 POReport.php:810 +#: Dashboard.php:333 POReport.php:610 POReport.php:697 POReport.php:810 #: SalesInquiry.php:911 SalesInquiry.php:927 SalesInquiry.php:1038 #: WorkOrderCosting.php:302 msgid "Totals" msgstr "" -#: Dashboard.php:353 +#: Dashboard.php:352 msgid "Supplier Invoices Due within 1 Month" msgstr "" -#: Dashboard.php:359 PrintCustTrans.php:811 PrintCustTransPortrait.php:857 +#: Dashboard.php:358 PrintCustTrans.php:811 PrintCustTransPortrait.php:857 #: SalesInquiry.php:1087 SupplierInvoice.php:632 msgid "Invoice Date" msgstr "" -#: Dashboard.php:361 +#: Dashboard.php:360 msgid "Amount Due" msgstr "" -#: Dashboard.php:425 SuppPaymentRun.php:111 +#: Dashboard.php:424 SuppPaymentRun.php:111 msgid "The details of supplier invoices due could not be retrieved because" msgstr "" -#: Dashboard.php:516 SuppPaymentRun.php:226 +#: Dashboard.php:515 SuppPaymentRun.php:226 msgid "Grand Total Payments Due" msgstr "" -#: Dashboard.php:534 GLAccounts.php:243 GLAccounts.php:296 +#: Dashboard.php:526 +msgid "Bank and Credit Card Balances" +msgstr "" + +#: Dashboard.php:533 GLAccounts.php:243 GLAccounts.php:296 #: GLBalanceSheet.php:402 GLCodesInquiry.php:27 GLProfit_Loss.php:621 #: GLTagProfit_Loss.php:537 GLTrialBalance.php:453 SelectGLAccount.php:113 #: SupplierCredit.php:459 SupplierInvoice.php:827 @@ -9819,61 +9824,65 @@ msgid "Account Name" msgstr "" -#: Dashboard.php:602 Dashboard.php:621 GLAccountCSV.php:189 +#: Dashboard.php:601 Dashboard.php:620 GLAccountCSV.php:189 #: GLAccountCSV.php:218 GLAccountInquiry.php:195 GLAccountInquiry.php:233 #: GLAccountReport.php:118 msgid "The chart details for account" msgstr "" -#: Dashboard.php:662 ../webSHOP/includes/Functions.php:64 +#: Dashboard.php:653 +msgid "Outstanding Orders" +msgstr "" + +#: Dashboard.php:661 ../webSHOP/includes/Functions.php:64 #: ../webSHOP/includes/header.php:226 msgid "View Order" msgstr "" -#: Dashboard.php:670 FTP_RadioBeacon.php:53 SelectCompletedOrder.php:558 +#: Dashboard.php:669 FTP_RadioBeacon.php:53 SelectCompletedOrder.php:558 #: SelectRecurringSalesOrder.php:93 SelectSalesOrder.php:699 msgid "Cust Order" msgstr "" -#: Dashboard.php:671 FTP_RadioBeacon.php:54 MRPReschedules.php:196 +#: Dashboard.php:670 FTP_RadioBeacon.php:54 MRPReschedules.php:196 #: POReport.php:540 POReport.php:626 POReport.php:1306 POReport.php:1357 #: POReport.php:1514 PO_SelectOSPurchOrder.php:512 PO_SelectPurchOrder.php:436 #: PrintCustTrans.php:810 PrintCustTransPortrait.php:856 SalesInquiry.php:827 #: SalesInquiry.php:846 SalesInquiry.php:1086 SelectCompletedOrder.php:559 #: SelectSalesOrder.php:700 includes/PDFOrderPageHeader_generic.inc:77 -#: includes/PDFSalesOrder_generic.inc:79 includes/PDFTransPageHeader.inc:56 -#: includes/PDFTransPageHeaderPortrait.inc:68 +#: includes/PDFSalesOrder_generic.inc:79 includes/PDFTransPageHeader.inc:59 +#: includes/PDFTransPageHeaderPortrait.inc:71 #: includes/PO_PDFOrderPageHeader.inc:51 msgid "Order Date" msgstr "" -#: Dashboard.php:672 FTP_RadioBeacon.php:55 SelectCompletedOrder.php:560 +#: Dashboard.php:671 FTP_RadioBeacon.php:55 SelectCompletedOrder.php:560 #: SelectSalesOrder.php:701 SelectSalesOrder.php:718 msgid "Req Del Date" msgstr "" -#: Dashboard.php:673 FTP_RadioBeacon.php:56 PO_Header.php:881 +#: Dashboard.php:672 FTP_RadioBeacon.php:56 PO_Header.php:881 #: PO_Header.php:1134 SelectCompletedOrder.php:561 SelectSalesOrder.php:702 -#: SelectSalesOrder.php:719 includes/PDFQuotationPageHeader.inc:42 -#: includes/PDFQuotationPortraitPageHeader.inc:31 +#: SelectSalesOrder.php:719 includes/PDFQuotationPageHeader.inc:48 +#: includes/PDFQuotationPortraitPageHeader.inc:42 msgid "Delivery To" msgstr "" -#: Dashboard.php:674 FTP_RadioBeacon.php:57 PO_SelectOSPurchOrder.php:519 +#: Dashboard.php:673 FTP_RadioBeacon.php:57 PO_SelectOSPurchOrder.php:519 #: PO_SelectPurchOrder.php:439 SelectCompletedOrder.php:562 #: SelectRecurringSalesOrder.php:97 SelectSalesOrder.php:703 msgid "Order Total" msgstr "" -#: Dashboard.php:707 SelectSalesOrder.php:674 +#: Dashboard.php:706 SelectSalesOrder.php:674 msgid "No orders or quotations were returned by the SQL because" msgstr "" -#: Dashboard.php:750 SelectSalesOrder.php:759 +#: Dashboard.php:749 SelectSalesOrder.php:759 msgid "Reprint" msgstr "" -#: Dashboard.php:797 SelectSalesOrder.php:852 +#: Dashboard.php:796 SelectSalesOrder.php:852 msgid "Total Order(s) Value in" msgstr "" @@ -11137,8 +11146,8 @@ msgstr "" #: EmailConfirmation.php:43 FTP_RadioBeacon.php:178 PDFPickingList.php:224 -#: PDFQuotation.php:35 PDFQuotation.php:122 PDFQuotationPortrait.php:37 -#: PDFQuotationPortrait.php:123 PDFWOPrint.php:144 PDFWOPrint.php:264 +#: PDFQuotation.php:37 PDFQuotation.php:123 PDFQuotationPortrait.php:39 +#: PDFQuotationPortrait.php:125 PDFWOPrint.php:144 PDFWOPrint.php:264 #: PO_PDFPurchOrder.php:78 PO_PDFPurchOrder.php:209 PrintCustOrder.php:39 #: PrintCustOrder.php:136 PrintCustOrder_generic.php:38 #: PrintCustOrder_generic.php:163 PrintCustStatements.php:116 @@ -11225,7 +11234,7 @@ #: EmailConfirmation.php:186 EmailConfirmation.php:307 PrintCustTrans.php:784 #: PrintCustTransPortrait.php:829 includes/PDFOrderPageHeader_generic.inc:40 -#: includes/PDFSalesOrder_generic.inc:42 includes/PDFTransPageHeader.inc:112 +#: includes/PDFSalesOrder_generic.inc:42 includes/PDFTransPageHeader.inc:115 msgid "Delivered To" msgstr "" @@ -15302,75 +15311,75 @@ msgid "Print Labels" msgstr "" -#: LocationUsers.php:4 -msgid "Maintenance Of Location Authorised Users" +#: LocationUsers.php:5 includes/MainMenuLinksArray.php:507 +msgid "Inventory Location Authorised Users Maintenance" msgstr "" -#: LocationUsers.php:7 +#: LocationUsers.php:10 msgid "Location Authorised Users" msgstr "" -#: LocationUsers.php:30 +#: LocationUsers.php:33 msgid "You have not selected any Location" msgstr "" -#: LocationUsers.php:43 +#: LocationUsers.php:46 msgid "You have not selected an user to be authorised to use this Location" msgstr "" -#: LocationUsers.php:62 +#: LocationUsers.php:65 msgid "is already authorised to use this location" msgstr "" -#: LocationUsers.php:74 +#: LocationUsers.php:77 msgid "authority to use the" msgstr "" -#: LocationUsers.php:74 +#: LocationUsers.php:77 msgid "location has been changed" msgstr "" -#: LocationUsers.php:85 LocationUsers.php:95 +#: LocationUsers.php:88 LocationUsers.php:98 msgid "The Location user record could not be deleted because" msgstr "" -#: LocationUsers.php:87 +#: LocationUsers.php:90 msgid "has had their authority to use the" msgstr "" -#: LocationUsers.php:87 LocationUsers.php:97 +#: LocationUsers.php:90 LocationUsers.php:100 msgid "location removed" msgstr "" -#: LocationUsers.php:97 +#: LocationUsers.php:100 msgid "has had their authority to update" msgstr "" -#: LocationUsers.php:109 NoSalesItems.php:19 TopItems.php:22 +#: LocationUsers.php:112 NoSalesItems.php:19 TopItems.php:22 msgid "Select Location" msgstr "" -#: LocationUsers.php:168 +#: LocationUsers.php:171 msgid "Authorised users for Location" msgstr "" -#: LocationUsers.php:189 +#: LocationUsers.php:192 msgid "Are you sure you wish to remove Update for this user?" msgstr "" -#: LocationUsers.php:189 +#: LocationUsers.php:192 msgid "Remove Update" msgstr "" -#: LocationUsers.php:191 +#: LocationUsers.php:194 msgid "Are you sure you wish to add Update for this user?" msgstr "" -#: LocationUsers.php:191 +#: LocationUsers.php:194 msgid "Add Update" msgstr "" -#: Locations.php:7 +#: Locations.php:5 msgid "Location Maintenance" msgstr "" @@ -17180,8 +17189,8 @@ msgstr "" #: OutstandingGRNs.php:183 SpecialOrder.php:736 -#: includes/PDFTransPageHeader.inc:209 -#: includes/PDFTransPageHeaderPortrait.inc:266 +#: includes/PDFTransPageHeader.inc:212 +#: includes/PDFTransPageHeaderPortrait.inc:268 #: ../webSHOP/includes/PlaceOrder.php:238 msgid "Unit Price" msgstr "" @@ -17424,8 +17433,8 @@ msgstr "" #: PDFCustomerList.php:343 includes/PDFOrderPageHeader_generic.inc:32 -#: includes/PDFQuotationPageHeader.inc:34 -#: includes/PDFQuotationPortraitPageHeader.inc:22 +#: includes/PDFQuotationPageHeader.inc:39 +#: includes/PDFQuotationPortraitPageHeader.inc:33 #: includes/PDFSalesOrder_generic.inc:34 msgid "Ph" msgstr "" @@ -18138,80 +18147,76 @@ msgid "QA Label" msgstr "" -#: PDFQuotation.php:10 PDFQuotationPortrait.php:10 +#: PDFQuotation.php:12 PDFQuotationPortrait.php:12 msgid "Select Quotation To Print" msgstr "" -#: PDFQuotation.php:16 PDFQuotationPortrait.php:16 +#: PDFQuotation.php:18 PDFQuotationPortrait.php:18 msgid "Select a Quotation to Print before calling this page" msgstr "" -#: PDFQuotation.php:23 PDFQuotationPortrait.php:23 +#: PDFQuotation.php:25 PDFQuotationPortrait.php:25 msgid "Quotations" msgstr "" -#: PDFQuotation.php:35 PDFQuotationPortrait.php:37 +#: PDFQuotation.php:37 PDFQuotationPortrait.php:39 msgid "" "There was a problem retrieving the quotation header details for Order Number" msgstr "" -#: PDFQuotation.php:78 PDFQuotation.php:266 PDFQuotationPortrait.php:80 -#: PDFQuotationPortrait.php:270 +#: PDFQuotation.php:80 PDFQuotation.php:272 PDFQuotationPortrait.php:82 +#: PDFQuotationPortrait.php:264 msgid "Print Quotation Error" msgstr "" -#: PDFQuotation.php:84 PDFQuotationPortrait.php:86 +#: PDFQuotation.php:86 PDFQuotationPortrait.php:88 msgid "Unable to Locate Quotation Number" msgstr "" -#: PDFQuotation.php:91 PDFQuotationPortrait.php:93 +#: PDFQuotation.php:93 PDFQuotationPortrait.php:95 msgid "Outstanding Quotations" msgstr "" -#: PDFQuotation.php:113 PDFQuotationPortrait.php:114 +#: PDFQuotation.php:115 PDFQuotationPortrait.php:117 msgid "Customer Quotation" msgstr "" -#: PDFQuotation.php:114 PDFQuotationPortrait.php:115 SalesInquiry.php:1078 -#: includes/PDFQuotationPageHeader.inc:14 -#: includes/PDFQuotationPortraitPageHeader.inc:14 +#: PDFQuotation.php:116 PDFQuotationPortrait.php:118 SalesInquiry.php:1078 +#: includes/PDFQuotationPageHeader.inc:18 +#: includes/PDFQuotationPortraitPageHeader.inc:18 msgid "Quotation" msgstr "" -#: PDFQuotation.php:121 PDFQuotationPortrait.php:122 +#: PDFQuotation.php:122 PDFQuotationPortrait.php:124 msgid "" "There was a problem retrieving the quotation line details for quotation " "Number" msgstr "" -#: PDFQuotation.php:237 PDFQuotationPortrait.php:257 +#: PDFQuotation.php:241 PDFQuotationPortrait.php:238 msgid "Quotation Excluding Tax" msgstr "" -#: PDFQuotation.php:240 PDFQuotationPortrait.php:260 +#: PDFQuotation.php:244 PDFQuotationPortrait.php:241 msgid "Total Tax" msgstr "" -#: PDFQuotation.php:243 PDFQuotationPortrait.php:263 +#: PDFQuotation.php:247 PDFQuotationPortrait.php:244 msgid "Quotation Including Tax" msgstr "" -#: PDFQuotation.php:268 PDFQuotationPortrait.php:272 +#: PDFQuotation.php:274 PDFQuotationPortrait.php:266 msgid "There were no items on the quotation" msgstr "" -#: PDFQuotation.php:268 PDFQuotationPortrait.php:272 +#: PDFQuotation.php:274 PDFQuotationPortrait.php:266 msgid "The quotation cannot be printed" msgstr "" -#: PDFQuotation.php:269 PDFQuotationPortrait.php:273 +#: PDFQuotation.php:275 PDFQuotationPortrait.php:267 msgid "Print Another Quotation" msgstr "" -#: PDFQuotationPortrait.php:237 -msgid "Notes:" -msgstr "" - #: PDFReceipt.php:9 msgid "Sales Receipt" msgstr "" @@ -18653,7 +18658,7 @@ #: POReport.php:764 POReport.php:1268 POReport.php:1311 POReport.php:1362 #: POReport.php:1439 POReport.php:1451 POReport.php:1624 SalesInquiry.php:770 #: SalesInquiry.php:833 SalesInquiry.php:852 SalesInquiry.php:999 -#: SalesInquiry.php:1229 includes/PDFTransPageHeader.inc:213 +#: SalesInquiry.php:1229 includes/PDFTransPageHeader.inc:216 msgid "Extended Price" msgstr "" @@ -18717,8 +18722,8 @@ #: includes/PDFOrderPageHeader.inc:39 #: includes/PDFOrderPageHeader_generic.inc:73 #: includes/PDFPickingListHeader.inc:44 includes/PDFSalesOrder_generic.inc:75 -#: includes/PDFTransPageHeader.inc:54 -#: includes/PDFTransPageHeaderPortrait.inc:65 +#: includes/PDFTransPageHeader.inc:57 +#: includes/PDFTransPageHeaderPortrait.inc:68 msgid "Order No" msgstr "" @@ -22152,14 +22157,14 @@ #: PrintCustTrans.php:731 PrintCustTrans.php:964 PrintCustTrans.php:1013 #: PrintCustTransPortrait.php:771 PrintCustTransPortrait.php:1019 -#: PrintCustTransPortrait.php:1074 includes/PDFTransPageHeader.inc:15 -#: includes/PDFTransPageHeaderPortrait.inc:18 +#: PrintCustTransPortrait.php:1074 includes/PDFTransPageHeader.inc:18 +#: includes/PDFTransPageHeaderPortrait.inc:20 msgid "TAX INVOICE" msgstr "" #: PrintCustTrans.php:733 PrintCustTrans.php:966 PrintCustTrans.php:1015 #: PrintCustTransPortrait.php:773 PrintCustTransPortrait.php:1021 -#: PrintCustTransPortrait.php:1076 includes/PDFTransPageHeaderPortrait.inc:20 +#: PrintCustTransPortrait.php:1076 includes/PDFTransPageHeaderPortrait.inc:22 msgid "TAX CREDIT NOTE" msgstr "" @@ -22179,8 +22184,8 @@ msgstr "" #: PrintCustTrans.php:783 PrintCustTransPortrait.php:828 -#: includes/PDFTransPageHeader.inc:138 -#: includes/PDFTransPageHeaderPortrait.inc:190 +#: includes/PDFTransPageHeader.inc:141 +#: includes/PDFTransPageHeaderPortrait.inc:192 msgid "Charge Branch" msgstr "" @@ -22195,8 +22200,8 @@ #: PrintCustTrans.php:812 PrintCustTrans.php:859 #: PrintCustTransPortrait.php:858 PrintCustTransPortrait.php:908 #: SalesAnalRepts.php:50 SalesAnalRepts.php:52 -#: includes/PDFTransPageHeader.inc:196 -#: includes/PDFTransPageHeaderPortrait.inc:247 +#: includes/PDFTransPageHeader.inc:199 +#: includes/PDFTransPageHeaderPortrait.inc:249 msgid "Sales Person" msgstr "" @@ -24975,6 +24980,10 @@ msgid "Goods Returned to Location" msgstr "" +#: SelectCreditItems.php:944 +msgid "Credit Note Text" +msgstr "" + #: SelectCreditItems.php:957 msgid "Are you sure you wish to cancel the whole of this credit note?" msgstr "" @@ -41097,8 +41106,8 @@ msgstr "" #: includes/PDFCustTransListingPageHeader.inc:52 -#: includes/PDFQuotationPageHeader.inc:85 -#: includes/PDFQuotationPortraitPageHeader.inc:103 +#: includes/PDFQuotationPageHeader.inc:105 +#: includes/PDFQuotationPortraitPageHeader.inc:99 #: includes/PDFSuppTransListingPageHeader.inc:52 msgid "Tax Amount" msgstr "" @@ -41244,7 +41253,7 @@ #: includes/PDFInventoryPlanPageHeader.inc:54 #: includes/PDFInventoryPlanPageHeader.inc:55 #: includes/PDFInventoryPlanPageHeader.inc:56 -#: includes/PDFTransPageHeaderPortrait.inc:267 +#: includes/PDFTransPageHeaderPortrait.inc:269 msgid "Qty" msgstr "" @@ -41278,8 +41287,8 @@ #: includes/PDFOrderPageHeader.inc:40 #: includes/PDFOrderPageHeader_generic.inc:75 -#: includes/PDFQuotationPageHeader.inc:18 -#: includes/PDFQuotationPortraitPageHeader.inc:87 ... [truncated message content] |
From: <ser...@us...> - 2014-08-19 11:44:28
|
Revision: 6832 http://sourceforge.net/p/web-erp/reponame/6832 Author: serakfalcon Date: 2014-08-19 11:44:16 +0000 (Tue, 19 Aug 2014) Log Message: ----------- Security update, changes algorithm for password hashing to be more secure for PHP versions 5.3.7+. For new installs,the $CryptFunction global is removed and is no longer needed. For existing installs, $CryptFunction will be needed until all users have logged in at least once or have had their password reset. Modified Paths: -------------- trunk/UserSettings.php trunk/api/api_session.inc trunk/config.distrib.php trunk/includes/UserLogin.php trunk/includes/session.inc trunk/sql/mysql/country_sql/default.sql trunk/sql/mysql/country_sql/demo.sql trunk/sql/mysql/country_sql/weberpchina.sql Modified: trunk/UserSettings.php =================================================================== --- trunk/UserSettings.php 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/UserSettings.php 2014-08-19 11:44:16 UTC (rev 6832) @@ -2,11 +2,11 @@ /* $Id$*/ -include('includes/session.inc'); +include('includes/session_views.inc'); $Title = _('User Settings'); -include('includes/header.inc'); +include('includes/header_views.inc'); -echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/user.png" title="' . +echo '<p class="page_title_text"><img src="'.$MainView->getStyleLink() .'/images/user.png" title="' . _('User Settings') . '" alt="" />' . ' ' . _('User Settings') . '</p>'; $PDFLanguages = array(_('Latin Western Languages - Times'), @@ -90,76 +90,58 @@ // update the session variables to reflect user changes on-the-fly $_SESSION['DisplayRecordsMax'] = $_POST['DisplayRecordsMax']; $_SESSION['Theme'] = trim($_POST['Theme']); /*already set by session.inc but for completeness */ - $Theme = $_SESSION['Theme']; + $_SESSION['Style'] = trim($_POST['Style']); + $Theme = $_SESSION['Style']; $_SESSION['Language'] = trim($_POST['Language']); $_SESSION['PDFLanguage'] = $_POST['PDFLanguage']; include ('includes/LanguageSetup.php'); // After last changes in LanguageSetup.php, is it required to update? } } -echo '<form method="post" action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">'; -echo '<div>'; -echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; -If (!isset($_POST['DisplayRecordsMax']) OR $_POST['DisplayRecordsMax']=='') { +$UserForm = $MainView->createForm(); +$UserForm->setAction(htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8')); +$UserForm->addHiddenControl('RealName',$_SESSION['UsersRealName']); +//addControl($key,$tabindex,$type,$caption = null,$settings = null,$htmlclass = null,$row = null,$order = null,$dimensions = null) +$UserForm->addControl(1,-1,'static',_('User ID') . ':',array('text' => $_SESSION['UserID']),null,1); +$UserForm->addControl(2,-1,'static',_('User Name') . ':',array('text' => $_SESSION['UsersRealName']),null,1); +if (!isset($_POST['DisplayRecordsMax']) OR $_POST['DisplayRecordsMax']=='') { + $_POST['DisplayRecordsMax'] = $_SESSION['DefaultDisplayRecordsMax']; } - -echo '<table class="selection"> - <tr> - <td>' . _('User ID') . ':</td> - <td>' . $_SESSION['UserID'] . '</td> - </tr>'; - -echo '<tr> - <td>' . _('User Name') . ':</td> - <td>' . $_SESSION['UsersRealName'] . ' - <input type="hidden" name="RealName" value="'.$_SESSION['UsersRealName'].'" /></td></tr>'; - -echo '<tr> - <td>' . _('Maximum Number of Records to Display') . ':</td> - <td><input type="text" class="integer" required="required" title="'._('The input must be positive integer').'" name="DisplayRecordsMax" size="3" maxlength="3" value="' . $_POST['DisplayRecordsMax'] . '" /></td> - </tr>'; - - -echo '<tr> - <td>' . _('Language') . ':</td> - <td><select name="Language">'; - +//addControl($key,$tabindex,$type,$caption = null,$settings = null,$htmlclass = null,$row = null,$order = null,$dimensions = null) +$UserForm->addControl(3,1,'text',_('Maximum Number of Records to Display') . ':',array( 'value' => $_POST['DisplayRecordsMax'], + 'name' => 'DisplayRecordsMax', + 'size' => 3, + 'maxlength' => 3, + 'required' => true),'integer'); + +$UserForm->addControl(4,2,'select', _('Language') . ':',array('name' => 'Language')); if (!isset($_POST['Language'])){ $_POST['Language']=$_SESSION['Language']; } - +//addControlOption($key,$text,$value,$isSelected = null,$id = null) foreach ($LanguagesArray as $LanguageEntry => $LanguageName){ - if (isset($_POST['Language']) AND $_POST['Language'] == $LanguageEntry){ - echo '<option selected="selected" value="' . $LanguageEntry . '">' . $LanguageName['LanguageName'] . '</option>'; - } elseif (!isset($_POST['Language']) AND $LanguageEntry == $DefaultLanguage) { - echo '<option selected="selected" value="' . $LanguageEntry . '">' . $LanguageName['LanguageName'] . '</option>'; - } else { - echo '<option value="' . $LanguageEntry . '">' . $LanguageName['LanguageName'] . '</option>'; - } + //is this language selected? + $UserForm->addControlOption(4,$LanguageName['LanguageName'],$LanguageEntry,((isset($_POST['Language']) AND $_POST['Language'] == $LanguageEntry) || (!isset($_POST['Language']) AND $LanguageEntry == $DefaultLanguage))); } -echo '</select></td></tr>'; - -echo '<tr> - <td>' . _('Theme') . ':</td> - <td><select name="Theme">'; - -$ThemeDirectories = scandir('css/'); - - -foreach ($ThemeDirectories as $ThemeName) { - - if (is_dir('css/' . $ThemeName) AND $ThemeName != '.' AND $ThemeName != '..' AND $ThemeName != '.svn'){ - - if ($_SESSION['Theme'] == $ThemeName){ - echo '<option selected="selected" value="' . $ThemeName . '">' . $ThemeName . '</option>'; - } else { - echo '<option value="' . $ThemeName . '">' . $ThemeName . '</option>'; - } - } +//addControl($key,$tabindex,$type,$caption = null,$settings = null,$htmlclass = null,$row = null,$order = null,$dimensions = null) +$UserForm->addControl(5,3,'select',_('Theme') . ':',array('name' => 'Theme', 'childselect' => 'StylesID')); +$UserForm->addControl(6,4,'select',_('Styles') . ':',array('name' => 'Style', 'id' => 'StylesID', 'hasparent' => true)); +$allThemes = $MainView->getTemplates(true); +$styleOptions = array(); +$i = 0; +foreach ($allThemes as $aTheme) { + //addControlOption($key,$text,$value,$isSelected = null,$parentID = null,$id = null) + $UserForm->addControlOption(5,$aTheme['themename'],$aTheme['themefolder'],($MainView->getTheme() == 'themes/' . $aTheme['themefolder']),null,$i); + if (is_array($aTheme['styles'])) { + foreach($aTheme['styles'] as $key => $style) { + $UserForm->addControlOption(6,$style,$style,($MainView->getTheme() == 'themes/' . $aTheme['themefolder'] && $MainView->getStyle() == $style),$i); + } + } + $i++; } if (!isset($_POST['PasswordCheck'])) { @@ -168,53 +150,46 @@ if (!isset($_POST['Password'])) { $_POST['Password']=''; } -echo '</select></td></tr> - <tr> - <td>' . _('New Password') . ':</td> - <td><input type="password" name="Password" pattern="(?!^'.$_SESSION['UserID'].'$).{5,}" title="'._('Must be more than 5 characters and cannot be as same as userid').'" placeholder="'._('More than 5 characters').'" size="20" value="' . $_POST['Password'] . '" /></td> - </tr> - <tr> - <td>' . _('Confirm Password') . ':</td> - <td><input type="password" name="PasswordCheck" pattern="(?!^'.$_SESSION['UserID'].'$).{5,}" title="'._('Must be more than 5 characters and cannot be as same as userid').'" placeholder="'._('More than 5 characters').'" size="20" value="' . $_POST['PasswordCheck'] . '" /></td> - </tr> - <tr> - <td colspan="2" align="center"><i>' . _('If you leave the password boxes empty your password will not change') . '</i></td> - </tr> - <tr> - <td>' . _('Email') . ':</td>'; +$controlsettings['name'] = 'Password'; +$controlsettings['value'] = $_POST['Password']; +$controlsettings['pattern'] = '(?!^'.$_SESSION['UserID'].'$).{5,}'; +$controlsettings['title'] = _('Must be more than 5 characters and cannot be as same as userid'); +$controlsettings['placeholder'] = _('More than 5 characters'); +$controlsettings['size'] ='20'; + +//addControl($key,$tabindex,$type,$caption = null,$settings = null,$htmlclass = null,$row = null,$order = null,$dimensions = null) +$UserForm->addControl(7,5,'password',_('New Password') . ':',$controlsettings); +$controlsettings['name'] = 'PasswordCheck'; +$controlsettings['value'] = $_POST['PasswordCheck']; +$UserForm->addControl(8,6,'password',_('Confirm Password') . ':',$controlsettings); +$UserForm->addControl(9,-1,'content',null,array( 'align' => 'center', + 'text' => '<i>' . _('If you leave the password boxes empty your password will not change') . '</i>' + )); $sql = "SELECT email from www_users WHERE userid = '" . $_SESSION['UserID'] . "'"; $result = DB_query($sql,$db); $myrow = DB_fetch_array($result); if(!isset($_POST['email'])){ $_POST['email'] = $myrow['email']; } - -echo '<td><input type="email" name="email" size="40" value="' . $_POST['email'] . '" /></td> - </tr>'; - + +$UserForm->addControl(10,7,'email', _('Email') . ':',array( 'name' => 'email', + 'size' => 40, + 'value' => $_POST['email'])); + if (!isset($_POST['PDFLanguage'])){ $_POST['PDFLanguage']=$_SESSION['PDFLanguage']; } -echo '<tr> - <td>' . _('PDF Language Support') . ': </td> - <td><select name="PDFLanguage">'; +$UserForm->addControl(11,8,'select',_('PDF Language Support') . ':',array('name' => 'PDFLanguage')); -for($i=0;$i<count($PDFLanguages);$i++){ - if ($_POST['PDFLanguage']==$i){ - echo '<option selected="selected" value="' . $i .'">' . $PDFLanguages[$i] . '</option>'; - } else { - echo '<option value="' . $i .'">' . $PDFLanguages[$i]. '</option>'; - } +foreach($PDFLanguages as $i => $Lang){ + //addControlOption($key,$text,$value,$isSelected = null,$id = null) + $UserForm->addControlOption(11,$Lang,$i,($_POST['PDFLanguage']==$i)); } -echo '</select></td> - </tr> - </table> - <br /> - <div class="centre"><input type="submit" name="Modify" value="' . _('Modify') . '" /></div> - </div> - </form>'; -include('includes/footer.inc'); -?> \ No newline at end of file +$UserForm->addControl(12,9,'submit',_('Modify'),array('name' => 'Modify', + 'value' => _('Modify'))); +$UserForm->display(); +include('includes/footer_views.inc'); +?> Modified: trunk/api/api_session.inc =================================================================== --- trunk/api/api_session.inc 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/api/api_session.inc 2014-08-19 11:44:16 UTC (rev 6832) @@ -47,15 +47,23 @@ function CryptPass( $Password ) { - global $CryptFunction; - if ( $CryptFunction == 'sha1' ) { - return sha1($Password); - } elseif ( $CryptFunction == 'md5' ) { - return md5($Password); - } else { - return $Password; - } + if (PHP_VERSION_ID < 50500) { + $salt = base64_encode(mcrypt_create_iv(22, MCRYPT_DEV_URANDOM)); + $salt = str_replace('+', '.', $salt); + $hash = crypt($Password, '$2y$10$'.$salt.'$'); + } else { + $hash = password_hash($Password,PASSWORD_DEFAULT); + } + return $hash; } + + function VerifyPass($Password,$Hash) { + if(PHP_VERSION_ID < 50500) { + return (crypt($Password,$Hash)==$Hash); + } else { + return password_verify($Password,$Hash); + } + } // API wrapper for DB issues - no HTML output, AND remember any error message function api_DB_query( $sql, $db, $EMsg= '', $DMsg= '', $Transaction='', $TrapErrors=false ) Modified: trunk/config.distrib.php =================================================================== --- trunk/config.distrib.php 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/config.distrib.php 2014-08-19 11:44:16 UTC (rev 6832) @@ -70,11 +70,6 @@ //this can be left commented out //$SessionSavePath = '/tmp'; -// which encryption function should be used -//$CryptFunction = 'md5'; // MD5 Hash -$CryptFunction = 'sha1'; // SHA1 Hash -//$CryptFunction = ''; // Plain Text - //Setting to 12 or 24 determines the format of the clock display at the end of all screens $DefaultClock = 12; //$DefaultClock = 24; Modified: trunk/includes/UserLogin.php =================================================================== --- trunk/includes/UserLogin.php 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/includes/UserLogin.php 2014-08-19 11:44:16 UTC (rev 6832) @@ -41,16 +41,54 @@ } /* The SQL to get the user info must use the * syntax because the field name could change between versions if the fields are specifed directly then the sql fails and the db upgrade will fail */ $sql = "SELECT * - FROM www_users - WHERE www_users.userid='" . $Name . "' - AND (www_users.password='" . CryptPass($Password) . "' - OR www_users.password='" . $Password . "')"; + FROM www_users + WHERE www_users.userid='" . $Name . "'"; + $ErrMsg = _('Could not retrieve user details on login because'); $debug =1; + $continue = false; $Auth_Result = DB_query($sql, $db,$ErrMsg); + + if (DB_num_rows($Auth_Result) > 0) { + $myrow = DB_fetch_array($Auth_Result); + if (VerifyPass($Password,$myrow['password'])) { + $continue = true; + } elseif (isset($GLOBALS['CryptFunction'])) { + /*if the password stored in the DB was compiled the old way, + * the previous comparison will fail, + * try again with the old hashing algorithm, + * then re-hash the password using the new algorithm. + * The next version should not have $CryptFunction any more for new installs. + */ + switch ($GLOBALS['CryptFunction']) { + case 'sha1': + if ($myrow['password'] == sha1($Password)) { + $continue = true; + } + break; + case 'md5': + if ($myrow['password'] == md5($Password)) { + $continue = true; + } + break; + default: + if ($myrow['password'] == $Password) { + $continue = true; + } + } + if ($continue) { + $sql = "UPDATE www_users SET password = '".CryptPass($Password)."'" + . " WHERE userid = '".$Name."';"; + DB_query($sql,$db); + } + + } + } + + // Populate session variables with data base results - if (DB_num_rows($Auth_Result) > 0) { - $myrow = DB_fetch_array($Auth_Result); + if ($continue) { + if ($myrow['blocked']==1){ //the account is blocked return UL_BLOCKED; Modified: trunk/includes/session.inc =================================================================== --- trunk/includes/session.inc 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/includes/session.inc 2014-08-19 11:44:16 UTC (rev 6832) @@ -99,7 +99,7 @@ $Theme = (isset($_SESSION['Theme'])) ? $_SESSION['Theme'] : 'gel'; switch ($rc) { case UL_OK; //user logged in successfully - include($PathPrefix . 'includes/LanguageSetup.php'); //set up the language of the user + include($PathPrefix . 'includes/LanguageSetup.php'); //set up the language break; case UL_SHOWLOGIN: @@ -294,15 +294,23 @@ $debug = 0; //don't allow debug messages } function CryptPass( $Password ) { - global $CryptFunction; - if ( $CryptFunction == 'sha1' ) { - return sha1($Password); - } elseif ( $CryptFunction == 'md5' ) { - return md5($Password); - } else { - return $Password; - } + if (PHP_VERSION_ID < 50500) { + $salt = base64_encode(mcrypt_create_iv(22, MCRYPT_DEV_URANDOM)); + $salt = str_replace('+', '.', $salt); + $hash = crypt($Password, '$2y$10$'.$salt.'$'); + } else { + $hash = password_hash($Password,PASSWORD_DEFAULT); + } + return $hash; } + + function VerifyPass($Password,$Hash) { + if(PHP_VERSION_ID < 50500) { + return (crypt($Password,$Hash)==$Hash); + } else { + return password_verify($Password,$Hash); + } + } if (sizeof($_POST) > 0 AND !isset($AllowAnyone)) { Modified: trunk/sql/mysql/country_sql/default.sql =================================================================== --- trunk/sql/mysql/country_sql/default.sql 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/sql/mysql/country_sql/default.sql 2014-08-19 11:44:16 UTC (rev 6832) @@ -4894,8 +4894,8 @@ -- Dumping data for table `www_users` -- -INSERT INTO `www_users` VALUES ('admin','f0f77a7f88e7c1e93ab4e316b4574c7843b00ea4','Demonstration user','','','','','ad...@we...','MEL',8,1,'2014-02-08 15:26:35','','A4','1,1,1,1,1,1,1,1,1,1,1,',0,50,'fluid','en_GB.utf8',3,0); -INSERT INTO `www_users` VALUES ('WEB0000017','f0f77a7f88e7c1e93ab4e316b4574c7843b00ea4','Phil Daintree','WEB0000017','','','+64(0)275567890','ph...@lo...','TOR',7,0,NULL,'WEB0000017','A4','0,0,0,0,0,0,0,0,0,0,0',0,30,'silverwolf','en_GB.utf8',0,0); +INSERT INTO `www_users` VALUES ('admin','$2y$10$dXQ1ehIVzIS8i9G3sK34ROkJCxHO.O0pRlgmRLj.YL2rYH5DF45Ri','Demonstration user','','','','','ad...@we...','MEL',8,1,'2014-02-08 15:26:35','','A4','1,1,1,1,1,1,1,1,1,1,1,',0,50,'fluid','en_GB.utf8',3,0); +INSERT INTO `www_users` VALUES ('WEB0000017','$2y$10$dXQ1ehIVzIS8i9G3sK34ROkJCxHO.O0pRlgmRLj.YL2rYH5DF45Ri','Phil Daintree','WEB0000017','','','+64(0)275567890','ph...@lo...','TOR',7,0,NULL,'WEB0000017','A4','0,0,0,0,0,0,0,0,0,0,0',0,30,'silverwolf','en_GB.utf8',0,0); -- -- Dumping data for table `edi_orders_segs` Modified: trunk/sql/mysql/country_sql/demo.sql =================================================================== --- trunk/sql/mysql/country_sql/demo.sql 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/sql/mysql/country_sql/demo.sql 2014-08-19 11:44:16 UTC (rev 6832) @@ -9191,8 +9191,8 @@ -- Dumping data for table `www_users` -- -INSERT INTO `www_users` VALUES ('admin','f0f77a7f88e7c1e93ab4e316b4574c7843b00ea4','Demonstration user','','','','','ad...@we...','MEL',8,1,'2014-02-08 15:26:35','','A4','1,1,1,1,1,1,1,1,1,1,1,',0,50,'fluid','en_GB.utf8',3,0); -INSERT INTO `www_users` VALUES ('WEB0000017','f0f77a7f88e7c1e93ab4e316b4574c7843b00ea4','Phil Daintree','WEB0000017','','','+64(0)275567890','ph...@lo...','TOR',7,0,NULL,'WEB0000017','A4','0,0,0,0,0,0,0,0,0,0,0',0,30,'silverwolf','en_GB.utf8',0,0); +INSERT INTO `www_users` VALUES ('admin','$2y$10$dXQ1ehIVzIS8i9G3sK34ROkJCxHO.O0pRlgmRLj.YL2rYH5DF45Ri','Demonstration user','','','','','ad...@we...','MEL',8,1,'2014-02-08 15:26:35','','A4','1,1,1,1,1,1,1,1,1,1,1,',0,50,'fluid','en_GB.utf8',3,0); +INSERT INTO `www_users` VALUES ('WEB0000017','$2y$10$dXQ1ehIVzIS8i9G3sK34ROkJCxHO.O0pRlgmRLj.YL2rYH5DF45Ri','Phil Daintree','WEB0000017','','','+64(0)275567890','ph...@lo...','TOR',7,0,NULL,'WEB0000017','A4','0,0,0,0,0,0,0,0,0,0,0',0,30,'silverwolf','en_GB.utf8',0,0); /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; Modified: trunk/sql/mysql/country_sql/weberpchina.sql =================================================================== --- trunk/sql/mysql/country_sql/weberpchina.sql 2014-08-19 07:53:01 UTC (rev 6831) +++ trunk/sql/mysql/country_sql/weberpchina.sql 2014-08-19 11:44:16 UTC (rev 6832) @@ -4813,7 +4813,7 @@ -- Dumping data for table weberpcn.www_users: ~1 rows (approximately) /*!40000 ALTER TABLE `www_users` DISABLE KEYS */; INSERT INTO `www_users` (`userid`, `password`, `realname`, `customerid`, `supplierid`, `salesman`, `phone`, `email`, `defaultlocation`, `fullaccess`, `cancreatetender`, `lastvisitdate`, `branchcode`, `pagesize`, `modulesallowed`, `blocked`, `displayrecordsmax`, `theme`, `language`, `pdflanguage`, `department`) VALUES - ('admin', 'f865b53623b121fd34ee5426c792e5c33af8c227', '张三', '', '', '', '', 'ad...@we...', 'MEL', 8, 1, '2013-11-18 07:50:02', '', 'A4', '1,1,1,1,1,1,1,1,1,1,1,', 0, 50, 'fluid', 'zh_CN.utf8', 2, 0); + ('admin', '$2y$10$e7xelMwFyXZd.Ap5ssqDhutlfNIY3yvckOYFb9EP0vSGG.HkuCVQm', '张三', '', '', '', '', 'ad...@we...', 'MEL', 8, 1, '2013-11-18 07:50:02', '', 'A4', '1,1,1,1,1,1,1,1,1,1,1,', 0, 50, 'fluid', 'zh_CN.utf8', 2, 0); /*!40000 ALTER TABLE `www_users` ENABLE KEYS */; /*!40014 SET FOREIGN_KEY_CHECKS=1 */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; |
From: <rc...@us...> - 2014-08-27 03:14:49
|
Revision: 6846 http://sourceforge.net/p/web-erp/reponame/6846 Author: rchacon Date: 2014-08-27 03:14:38 +0000 (Wed, 27 Aug 2014) Log Message: ----------- Adds code comments, adds PageHeader() print for currabrev and categoryid, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), adds 'Prices excluding tax' warning. Modified Paths: -------------- trunk/PDFPriceList.php trunk/doc/Change.log trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po Modified: trunk/PDFPriceList.php =================================================================== --- trunk/PDFPriceList.php 2014-08-20 06:18:38 UTC (rev 6845) +++ trunk/PDFPriceList.php 2014-08-27 03:14:38 UTC (rev 6846) @@ -10,6 +10,10 @@ * Gross Profit, calculated, len = 8chr * prices.price, decimal(20,4), len = 20chr + 4spaces */ +/* Please note that addTextWrap() YPos is a font-size-height further down than + addText() and other functions. Use addText() instead of addTextWrap() to + print left aligned elements.*/ + include('includes/session.inc'); If (isset($_POST['PrintPDF']) @@ -166,67 +170,73 @@ if ($CurrCode != $PriceList['currabrev']) { $FontSize = 10; - $YPos -= 2*$line_height; + if ($YPos < $Bottom_Margin + $FontSize*3) {// If the next line reaches the bottom margin, do PageHeader(). + PageHeader(); + } + $YPos -= $FontSize;// Jumps additional line before. require_once('includes/CurrenciesArray.php');// To get the currency name from the currency code. - $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos, 300-$Left_Margin, $FontSize, + $pdf->addText($Left_Margin, $YPos, $FontSize, $PriceList['currabrev'] . ' - ' . _($CurrencyName[$PriceList['currabrev']])); $CurrCode = $PriceList['currabrev']; + $YPos -= $FontSize;// End-of-line line-feed. } if ($Category != $PriceList['categoryid']) { $FontSize = 10; - $YPos -= 2*$line_height; - $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos, 300-$Left_Margin, $FontSize, + if ($YPos < $Bottom_Margin + $FontSize*3) {// If the next line reaches the bottom margin, do PageHeader(). + PageHeader(); + } + $YPos -= $FontSize;// Jumps additional line before. + $pdf->addText($Left_Margin, $YPos, $FontSize, $PriceList['categoryid'] . ' - ' . $PriceList['categorydescription']); $Category = $PriceList['categoryid']; + $YPos -= $FontSize;// End-of-line line-feed. } $FontSize = 8; - $YPos -= $line_height; - $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos, 80, $FontSize, - $PriceList['stockid']); - $LeftOvers = $pdf->addTextWrap($Left_Margin+80, $YPos, 200, $FontSize, - $PriceList['description']); - $LeftOvers = $pdf->addTextWrap($Left_Margin+280, $YPos, 40, $FontSize, - ConvertSQLDate($PriceList['startdate'])); + $pdf->addText($Left_Margin, $YPos, $FontSize, $PriceList['stockid']); + $pdf->addText($Left_Margin+80, $YPos, $FontSize, $PriceList['description']); + $pdf->addText($Left_Margin+280, $YPos, $FontSize, ConvertSQLDate($PriceList['startdate'])); if ($PriceList['enddate']!='0000-00-00') { $DisplayEndDate = ConvertSQLDate($PriceList['enddate']); } else { $DisplayEndDate = _('No End Date'); } - $LeftOvers = $pdf->addTextWrap($Left_Margin+320, $YPos, 48, $FontSize, - $DisplayEndDate); + $pdf->addText($Left_Margin+320, $YPos, $FontSize, $DisplayEndDate); // Shows gross profit percentage: if ($_POST['ShowGPPercentages']=='Yes') { $DisplayGPPercent = '-'; if ($PriceList['price']!=0) { $DisplayGPPercent = locale_number_format((($PriceList['price']-$PriceList['standardcost'])*100/$PriceList['price']), 2) . '%'; - } - $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-128, $YPos, 32, $FontSize, + } + /*$LeftOvers = */$pdf->addTextWrap($Page_Width-$Right_Margin-128, $YPos-$FontSize, 32, $FontSize, $DisplayGPPercent, 'right'); } // Displays unit price: - $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-96, $YPos, 96, $FontSize, + /*$LeftOvers = */$pdf->addTextWrap($Page_Width-$Right_Margin-96, $YPos-$FontSize, 96, $FontSize, locale_number_format($PriceList['price'],$PriceList['decimalplaces']), 'right'); if ($_POST['CustomerSpecials']=='Customer Special Prices Only') { /*Need to show to which branch the price relates */ if ($PriceList['branchcode']!='') { - $LeftOvers = $pdf->addTextWrap($Left_Margin+376, $YPos, 160, $FontSize, $PriceList['brname']); + $pdf->addText($Left_Margin+376, $YPos, $FontSize, $PriceList['brname']); } else { - $LeftOvers = $pdf->addTextWrap($Left_Margin+376, $YPos, 160, $FontSize, _('All')); + $pdf->addText($Left_Margin+376, $YPos, $FontSize, _('All')); } + $YPos -= $FontSize;// End-of-line line-feed. - } else If ($_POST['CustomerSpecials']=='Full Description') { + } elseif ($_POST['CustomerSpecials']=='Full Description') { + $YPos -= $FontSize; + // Prints item image: $YPosImage = $YPos;// Initializes the image bottom $YPos. if(file_exists($_SESSION['part_pics_dir'] . '/' .$PriceList['stockid'].'.jpg') ) { $img = imagecreatefromjpeg($_SESSION['part_pics_dir'] . '/' . $PriceList['stockid'] . '.jpg'); if($YPos-36 < $Bottom_Margin) {// If the image bottom reaches the bottom margin, do PageHeader(). PageHeader(); - } - $LeftOvers = $pdf->Image($_SESSION['part_pics_dir'] . '/'.$PriceList['stockid'].'.jpg', + } + $LeftOvers = $pdf->Image($_SESSION['part_pics_dir'] . '/'.$PriceList['stockid'].'.jpg', $Left_Margin+3, $Page_Height-$YPos, 36, 36); $YPosImage = $YPos-36;// Stores the $YPos of the image bottom (see bottom). } @@ -238,17 +248,21 @@ foreach ($Split as $LeftOvers) { $LeftOvers = stripslashes($LeftOvers); while(mb_strlen($LeftOvers)>1) { - $YPos -= $FontSize2; if ($YPos < $Bottom_Margin) {// If the description line reaches the bottom margin, do PageHeader(). PageHeader(); $YPosImage = $YPos;// Resets the image bottom $YPos. } - $LeftOvers = $pdf->addTextWrap($XPos, $YPos, $Width, $FontSize2, $LeftOvers); + $LeftOvers = $pdf->addTextWrap($XPos, $YPos-$FontSize2, $Width, $FontSize2, $LeftOvers); + $YPos -= $FontSize2; } } // Assigns to $YPos the lowest $YPos value between the image and the description: $YPos = min($YPosImage, $YPos); + $YPos -= $FontSize;// Jumps additional line after the image and the description. + } else { + $YPos -= $FontSize;// End-of-line line-feed. + }/* Endif full descriptions*/ if ($YPos < $Bottom_Margin + $line_height) { @@ -350,27 +364,41 @@ if ($PageNumber>1) { $pdf->newPage(); } + $YPos = $Page_Height-$Top_Margin; + $FontSizeExt = $FontSize;// To preserve the main font size. + $FontSize = 10; + $pdf->addText($Left_Margin, $YPos, $FontSize, + $_SESSION['CompanyRecord']['coyname']);// Company name. + $pdf->addTextWrap($Page_Width-$Right_Margin-140, $YPos-$FontSize, 140, $FontSize, + _('Page'). ' ' . $PageNumber, 'right');// Page number. - $FontSize=10; - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,300,$FontSize,$_SESSION['CompanyRecord']['coyname']); - $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-140,$YPos,140,$FontSize, _('Printed').': ' . Date($_SESSION['DefaultDateFormat']) . ' '. _('Page'). ' ' . $PageNumber); - $YPos -= $line_height; - + $YPos -= $FontSize; //Note, this is ok for multilang as this is the value of a Select, text in option is different if ($_POST['CustomerSpecials']==_('Customer Special Prices Only')) { - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,550,$FontSize, $CustomerName . ' ' . _('Prices for Categories').' ' . $_POST['FromCriteria'] . ' - ' . $_POST['ToCriteria'] . ' ' . _('Effective As At') . ' ' . $_POST['EffectiveDate']); + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Price List') . ': ' . $CustomerName); } else { - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,550,$FontSize, $SalesTypeName . ' ' ._('Prices For Categories') . ' ' . $_POST['FromCriteria'] . ' - ' . $_POST['ToCriteria'] . ' ' . _('Effective As At') . ' ' . $_POST['EffectiveDate'] ); + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Price List') . ': ' . $SalesTypeName); } + $pdf->addTextWrap($Page_Width-$Right_Margin-140, $YPos-$FontSize, 140, $FontSize, + _('Printed') . ': ' . date($_SESSION['DefaultDateFormat']), 'right');// Date printed. + $YPos -= $FontSize; + $pdf->addText($Left_Margin, $YPos, $FontSize, + _('Categories') . ': ' . $_POST['FromCriteria'] . ' - ' . $_POST['ToCriteria'] . '. ' . + _('Effective As At') . ' ' . $_POST['EffectiveDate']);// Categories and effective date. + $pdf->addTextWrap($Page_Width-$Right_Margin-140, $YPos-$FontSize, 140, $FontSize, + date('H:i:s'), 'right');// Time printed. + $YPos -=(2*$line_height); - /*Draw a rectangle to put the headings in */ + // Draws a rectangle to put the headings in: + $pdf->Rectangle( + $Left_Margin,// Rectangle $XPos. + $YPos,// Rectangle $YPos. + $Page_Width-$Left_Margin-$Right_Margin,// Rectangle $Width. + $line_height*2);// Rectangle $Height. - $pdf->line($Left_Margin, $YPos+$line_height, $Page_Width-$Right_Margin, $YPos+$line_height); - $pdf->line($Left_Margin, $YPos+$line_height, $Left_Margin, $YPos- $line_height); - $pdf->line($Left_Margin, $YPos-$line_height, $Page_Width-$Right_Margin, $YPos- $line_height); - $pdf->line($Page_Width-$Right_Margin, $YPos+$line_height, $Page_Width-$Right_Margin, $YPos- $line_height); + $YPos -= $line_height; /*set up the headings */ $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos, 80, $FontSize, _('Item Code'));// 20chr @ 8dpi. @@ -385,7 +413,7 @@ if($LeftOvers != '') {// If translated text is greater than column width, prints remainder. $LeftOvers = $pdf->addTextWrap($Left_Margin+280, $YPos-$FontSize, 96, $FontSize, $LeftOvers, 'center'); } - + if ($_POST['CustomerSpecials']=='Customer Special Prices Only') { $LeftOvers = $pdf->addTextWrap($Left_Margin+376, $YPos, 160, $FontSize, _('Branch'));// 40chr @ 8dpd. } @@ -397,7 +425,15 @@ } } $LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-96, $YPos, 96, $FontSize, _('Price') , 'right');// 24chr @ 8dpd. + $YPos -= $FontSize; - $YPos -= (1.5 * $line_height); + // In some countries it is mandatory to clarify that prices do not include taxes: + $pdf->addText($Left_Margin, $YPos, $FontSize, + '* ' . _('Prices excluding tax'));// Warning text. + $YPos -= $FontSize;// End-of-line line-feed.*/ + +/* $YPos -= $FontSize;// Jumps additional line after the table headings.*/ + + $FontSize = $FontSizeExt;// Resets to the main font size. } ?> Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-20 06:18:38 UTC (rev 6845) +++ trunk/doc/Change.log 2014-08-27 03:14:38 UTC (rev 6846) @@ -1,5 +1,6 @@ webERP Change Log +26/08/14 RChacon: In PDFPriceList.php: Adds code comments, adds PageHeader() print for currabrev and categoryid, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), adds 'Prices excluding tax' warning. 15/08/14 RChacon: Fixes double line feed in PDFQuotationPortrait.php reported by Arwan Galaya. Uniforms code between PDFQuotation.php and PDFQuotationPortrait.php. 14/08/14 RChacon: In CustomerInquiry.php and SupplierInquiry.php makes translatable the systypes.typename. 14/08/14 RChacon: In SupplierInquiry.php: Reorganizes columns Date, Type, Number, Reference and Comments, and regroups table-datacel format-strings as in CustomerInquiry.php code. Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-20 06:18:38 UTC (rev 6845) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-27 03:14:38 UTC (rev 6846) @@ -7,8 +7,8 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-18 13:21-0600\n" -"PO-Revision-Date: 2014-08-18 21:45-0600\n" +"POT-Creation-Date: 2014-08-26 18:46-0600\n" +"PO-Revision-Date: 2014-08-26 18:54-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -1116,7 +1116,7 @@ #: MailInventoryValuation.php:242 MailInventoryValuation.php:250 #: OutstandingGRNs.php:49 OutstandingGRNs.php:62 PDFCustomerList.php:235 #: PDFCustomerList.php:247 PDFFGLabel.php:217 PDFGLJournal.php:100 -#: PDFGrn.php:176 PDFLowGP.php:59 PDFLowGP.php:71 PDFPriceList.php:143 +#: PDFGrn.php:176 PDFLowGP.php:59 PDFLowGP.php:71 PDFPriceList.php:147 #: PDFPrintLabel.php:45 PDFQALabel.php:116 PDFQuotation.php:276 #: PDFQuotationPortrait.php:268 PDFRemittanceAdvice.php:83 #: PDFSellThroughSupportClaim.php:74 PDFSellThroughSupportClaim.php:86 @@ -1277,7 +1277,7 @@ #: InventoryValuation.php:295 MRPPlannedPurchaseOrders.php:294 #: MRPPlannedWorkOrders.php:348 MRPReschedules.php:153 MRPShortages.php:303 #: OutstandingGRNs.php:277 PDFCustomerList.php:421 PDFLowGP.php:146 -#: PDFPriceList.php:326 PDFRemittanceAdvice.php:175 +#: PDFPriceList.php:340 PDFRemittanceAdvice.php:175 #: PDFStockCheckComparison.php:371 PrintCustTrans.php:572 #: PrintCustTransPortrait.php:614 ReorderLevel.php:259 StockDispatch.php:447 #: SuppPriceList.php:263 SupplierBalsAtPeriodEnd.php:159 Tax.php:353 @@ -1472,7 +1472,7 @@ #: AuditTrail.php:53 PO_AuthorisationLevels.php:124 #: PO_AuthorisationLevels.php:173 PO_AuthorisationLevels.php:176 -#: UserSettings.php:112 includes/UserLogin.php:135 +#: UserSettings.php:112 includes/UserLogin.php:173 msgid "User ID" msgstr "ID de usuario" @@ -1485,7 +1485,7 @@ #: InventoryQuantities.php:194 InventoryQuantities.php:196 MRP.php:599 #: MRPReport.php:524 MRPReport.php:526 MRPReschedules.php:145 #: NoSalesItems.php:22 NoSalesItems.php:50 NoSalesItems.php:70 -#: NoSalesItems.php:72 PDFPeriodStockTransListing.php:58 PDFPriceList.php:218 +#: NoSalesItems.php:72 PDFPeriodStockTransListing.php:58 PDFPriceList.php:225 #: POReport.php:1586 PO_Items.php:1125 ReorderLevel.php:212 #: ReorderLevel.php:214 ReorderLevel.php:244 ReorderLevel.php:246 #: SalesGraph.php:102 SalesGraph.php:104 SalesGraph.php:124 SalesGraph.php:126 @@ -1703,7 +1703,7 @@ #: GLAccountReport.php:327 InventoryPlanningPrefSupplier.php:58 #: InventoryQuantities.php:234 MRPPlannedPurchaseOrders.php:320 #: MRPPlannedWorkOrders.php:374 MRPReport.php:817 MRPReschedules.php:180 -#: MRPShortages.php:334 PDFOrderStatus.php:323 PDFPriceList.php:357 +#: MRPShortages.php:334 PDFOrderStatus.php:323 PDFPriceList.php:383 #: PDFReceipt.php:34 PO_Header.php:845 PO_PDFPurchOrder.php:64 #: PO_SelectOSPurchOrder.php:547 ReorderLevel.php:283 StockDispatch.php:477 #: SuppPriceList.php:292 Tax.php:244 includes/PDFAgedDebtorsPageHeader.inc:34 @@ -1742,7 +1742,7 @@ #: InventoryPlanningPrefSupplier.php:58 InventoryQuantities.php:235 #: MRPPlannedPurchaseOrders.php:321 MRPPlannedWorkOrders.php:375 #: MRPReport.php:818 MRPReschedules.php:181 MRPShortages.php:335 -#: PDFPriceList.php:357 PDFReceipt.php:34 PDFRemittanceAdvice.php:218 +#: PDFPriceList.php:373 PDFReceipt.php:34 PDFRemittanceAdvice.php:218 #: PrintCustOrder.php:175 PrintCustTrans.php:773 PrintCustTrans.php:982 #: PrintCustTrans.php:1031 PrintCustTransPortrait.php:818 #: PrintCustTransPortrait.php:1040 PrintCustTransPortrait.php:1096 @@ -3405,10 +3405,11 @@ msgstr "Cualquier otro" #: COGSGLPostings.php:316 Customers.php:513 Customers.php:850 -#: EDIProcessOrders.php:386 PDFCustomerList.php:334 PDFPriceList.php:27 -#: PDFPriceList.php:140 PDFPriceList.php:270 PricesBasedOnMarkUp.php:226 -#: PricesByCost.php:268 SalesGLPostings.php:363 SelectOrderItems.php:697 -#: SuppPriceList.php:138 SuppPriceList.php:251 +#: EDIProcessOrders.php:386 PDFCustomerList.php:334 PDFPriceList.php:31 +#: PDFPriceList.php:144 PDFPriceList.php:284 PDFPriceList.php:378 +#: PDFPriceList.php:380 PricesBasedOnMarkUp.php:226 PricesByCost.php:268 +#: SalesGLPostings.php:363 SelectOrderItems.php:697 SuppPriceList.php:138 +#: SuppPriceList.php:251 msgid "Price List" msgstr "Lista de precios" @@ -3906,7 +3907,7 @@ #: CounterReturns.php:1819 CounterSales.php:747 CounterSales.php:2431 #: Credit_Invoice.php:291 DeliveryDetails.php:870 GoodsReceived.php:100 #: InternalStockRequest.php:271 Labels.php:577 Labels.php:579 Labels.php:621 -#: OrderDetails.php:168 OutstandingGRNs.php:179 PDFPriceList.php:376 +#: OrderDetails.php:168 OutstandingGRNs.php:179 PDFPriceList.php:403 #: PDFPrintLabel.php:64 PO_Items.php:715 PO_OrderDetails.php:186 #: PrintCustTrans.php:896 PrintCustTrans.php:985 PrintCustTrans.php:1034 #: PrintCustTransPortrait.php:947 PrintCustTransPortrait.php:1045 @@ -3935,7 +3936,7 @@ #: CounterSales.php:748 Credit_Invoice.php:292 DeliveryDetails.php:871 #: DeliveryDetails.php:941 InternalStockRequest.php:158 #: InternalStockRequest.php:272 Labels.php:582 OrderDetails.php:169 -#: PDFPriceList.php:380 PDFPrintLabel.php:65 PO_Items.php:792 +#: PDFPriceList.php:407 PDFPrintLabel.php:65 PO_Items.php:792 #: PO_OrderDetails.php:187 PrintCustTrans.php:897 PrintCustTrans.php:986 #: PrintCustTrans.php:1035 PrintCustTransPortrait.php:948 #: PrintCustTransPortrait.php:1046 PrintCustTransPortrait.php:1102 @@ -3980,7 +3981,7 @@ #: DeliveryDetails.php:944 GoodsReceived.php:113 Labels.php:592 Labels.php:594 #: Labels.php:624 OffersReceived.php:110 OffersReceived.php:218 #: OffersReceived.php:278 OrderDetails.php:172 PDFOrdersInvoiced.php:378 -#: PDFPriceList.php:399 PDFPrintLabel.php:66 PO_AuthoriseMyOrders.php:116 +#: PDFPriceList.php:426 PDFPrintLabel.php:66 PO_AuthoriseMyOrders.php:116 #: PriceMatrix.php:224 Prices.php:222 Prices.php:334 PricesByCost.php:253 #: Prices_Customer.php:361 PrintCustTrans.php:900 PrintCustTrans.php:989 #: PrintCustTrans.php:1038 PrintCustTransPortrait.php:951 @@ -5995,7 +5996,7 @@ #: Contracts.php:779 CustomerInquiry.php:220 CustomerTransInquiry.php:108 #: Dashboard.php:668 FTP_RadioBeacon.php:52 PDFOrderStatus.php:294 -#: PDFOrdersInvoiced.php:293 PDFPriceList.php:390 PricesByCost.php:155 +#: PDFOrdersInvoiced.php:293 PDFPriceList.php:417 PricesByCost.php:155 #: Prices_Customer.php:263 Prices_Customer.php:337 PrintCustTrans.php:846 #: PrintCustTransPortrait.php:892 SelectCompletedOrder.php:557 #: SelectCreditItems.php:243 SelectCustomer.php:422 SelectOrderItems.php:595 @@ -6120,7 +6121,7 @@ #: Contracts.php:937 GLProfit_Loss.php:321 GLProfit_Loss.php:514 #: GLProfit_Loss.php:816 GLProfit_Loss.php:1173 GLTagProfit_Loss.php:309 #: GLTagProfit_Loss.php:447 GLTagProfit_Loss.php:686 GLTagProfit_Loss.php:885 -#: PDFPriceList.php:394 SalesAnalReptCols.php:31 SalesAnalReptCols.php:33 +#: PDFPriceList.php:421 SalesAnalReptCols.php:31 SalesAnalReptCols.php:33 #: SalesByTypePeriodInquiry.php:362 SalesCategoryPeriodInquiry.php:169 #: SalesGraph.php:192 SalesGraph.php:211 SalesGraph.php:274 #: SelectProduct.php:170 @@ -8185,7 +8186,7 @@ #: CustLoginSetup.php:150 SMTPServer.php:114 SuppLoginSetup.php:133 #: WWW_Users.php:468 includes/Login.php:99 includes/Login.php:100 -#: install/index.php:930 ../webSHOP/Checkout.php:302 +#: install/index.php:929 ../webSHOP/Checkout.php:302 #: ../webSHOP/Register.php:600 ../webSHOP/includes/header.php:239 msgid "Password" msgstr "Contraseña" @@ -12187,7 +12188,7 @@ msgid "ID" msgstr "ID" -#: Factors.php:287 install/index.php:1022 +#: Factors.php:287 install/index.php:1021 #: reportwriter/languages/en_US/reports.php:216 ../webSHOP/Register.php:615 msgid "Company Name" msgstr "Nombre de Empresa" @@ -15804,12 +15805,12 @@ msgid "Inventory Planning Reporting" msgstr "Reporte de Planificación de Inventario" -#: InventoryPlanning.php:400 InventoryValuation.php:238 PDFPriceList.php:288 +#: InventoryPlanning.php:400 InventoryValuation.php:238 PDFPriceList.php:302 #: PDFPrintLabel.php:296 StockCheck.php:272 msgid "From Inventory Category Code" msgstr "Desde el código de categoría de inventario" -#: InventoryPlanning.php:412 InventoryValuation.php:254 PDFPriceList.php:291 +#: InventoryPlanning.php:412 InventoryValuation.php:254 PDFPriceList.php:305 #: PDFPrintLabel.php:305 StockCheck.php:283 msgid "To Inventory Category Code" msgstr "Hasta el código de categoría de inventario" @@ -19032,124 +19033,125 @@ "Hubo un problema al obtener los detalles de línea de la orden para el Número " "de Orden" -#: PDFPriceList.php:26 +#: PDFPriceList.php:30 msgid "Price list by inventory category" msgstr "" -#: PDFPriceList.php:33 PDFPriceList.php:315 PDFPriceList.php:361 +#: PDFPriceList.php:37 PDFPriceList.php:329 PDFPriceList.php:377 msgid "Customer Special Prices Only" msgstr "Solamente Precios Especiales para clientes" -#: PDFPriceList.php:36 PDFPriceList.php:47 +#: PDFPriceList.php:40 PDFPriceList.php:51 msgid "Special price List - No Customer Selected" msgstr "Lista de Precios Especial - Sin cliente Seleccionado" -#: PDFPriceList.php:41 +#: PDFPriceList.php:45 msgid "The customer must first be selected from the select customer link" msgstr "" "Debe primero seleccionar el cliente desde el enlace seleccionar clientes" -#: PDFPriceList.php:41 +#: PDFPriceList.php:45 msgid "Re-run the price list once the customer has been selected" msgstr "" "Vuelva a efectuar la lista de precios una vez que haya seleccionado al " "cliente" -#: PDFPriceList.php:42 PDFPriceList.php:52 PDFPriceList.php:154 +#: PDFPriceList.php:46 PDFPriceList.php:56 PDFPriceList.php:158 #: PDFPrintLabel.php:54 PDFRemittanceAdvice.php:40 PricesByCost.php:224 #: PricesByCost.php:230 msgid "Back" msgstr "Regresar" -#: PDFPriceList.php:51 +#: PDFPriceList.php:55 msgid "The effective date must be entered in the format" msgstr "La fecha de vigencia se debe introducir en el formato" -#: PDFPriceList.php:140 +#: PDFPriceList.php:144 msgid "Problem Report...." msgstr "Informe de Problemas ..." -#: PDFPriceList.php:142 SuppPriceList.php:140 Z_DataExport.php:71 +#: PDFPriceList.php:146 SuppPriceList.php:140 Z_DataExport.php:71 msgid "The Price List could not be retrieved by the SQL because" msgstr "El SQL no pudo obtener la Lista de Precios porque" -#: PDFPriceList.php:145 PDFPrintLabel.php:47 +#: PDFPriceList.php:149 PDFPrintLabel.php:47 msgid "For debugging purposes the SQL used was:" msgstr "Para propósitos de depuración del SQL utilizado fue:" -#: PDFPriceList.php:151 +#: PDFPriceList.php:155 msgid "Print Price List Error" msgstr "Imprimir Errores en lista de precios" -#: PDFPriceList.php:153 +#: PDFPriceList.php:157 msgid "" "There were no price details to print out for the customer or category " "specified" msgstr "" "No hubo detalles de precios a imprimir para el cliente o categoría indicada" -#: PDFPriceList.php:195 Prices.php:240 PricesByCost.php:205 +#: PDFPriceList.php:203 Prices.php:240 PricesByCost.php:205 #: Prices_Customer.php:217 Prices_Customer.php:274 msgid "No End Date" -msgstr "No hay Fecha Final" +msgstr "Sin fecha final" -#: PDFPriceList.php:260 +#: PDFPriceList.php:274 msgid "Price_List" msgstr "Lista_Precios" -#: PDFPriceList.php:266 +#: PDFPriceList.php:280 msgid "Price Listing" msgstr "Listado de precios" -#: PDFPriceList.php:271 +#: PDFPriceList.php:285 msgid "Print a price list by inventory category" -msgstr "Imprimir una lista de precios" +msgstr "Imprimir lista de precios por categoría de inventario" -#: PDFPriceList.php:295 PDFPrintLabel.php:316 Z_DataExport.php:542 +#: PDFPriceList.php:309 PDFPrintLabel.php:316 Z_DataExport.php:542 msgid "For Sales Type/Price List" msgstr "Para Ventas Lista Tipo/Precio" -#: PDFPriceList.php:306 +#: PDFPriceList.php:320 msgid "Show Gross Profit %" msgstr "Mostrar % Ganancias Brutas" -#: PDFPriceList.php:308 +#: PDFPriceList.php:322 msgid "Prices Only" -msgstr "Sólo Precios" +msgstr "Sólo precios" -#: PDFPriceList.php:309 +#: PDFPriceList.php:323 msgid "Show GP % too" msgstr "Muestre tambien el % de GB" -#: PDFPriceList.php:313 +#: PDFPriceList.php:327 msgid "Price Listing Type" msgstr "Tipo de listado de precios" -#: PDFPriceList.php:314 +#: PDFPriceList.php:328 msgid "Default Sales Type Prices" msgstr "Tipo de precios de venta por defecto" -#: PDFPriceList.php:316 +#: PDFPriceList.php:330 msgid "Full Description" msgstr "Descripción completa" -#: PDFPriceList.php:320 PDFPriceList.php:362 PDFPriceList.php:364 -#: PDFPrintLabel.php:345 +#: PDFPriceList.php:334 PDFPriceList.php:388 PDFPrintLabel.php:345 msgid "Effective As At" -msgstr "Efectivo en" +msgstr "Efectivo al" -#: PDFPriceList.php:362 -msgid "Prices for Categories" -msgstr "Precios por Categorías" +#: PDFPriceList.php:387 StockClone.php:1087 Stocks.php:1397 Stocks.php:1404 +#: ../webSHOP/includes/Functions.php:127 +#: ../webSHOP/includes/ShowSalesCategoriesMenu.php:15 +msgid "Categories" +msgstr "Categorías" -#: PDFPriceList.php:364 -msgid "Prices For Categories" -msgstr "Precios por categorías" - -#: PDFPriceList.php:384 +#: PDFPriceList.php:411 msgid "Effective Date Range" -msgstr "Rango de Fechas de Efectividad" +msgstr "Rango de fechas efectivas" +#: PDFPriceList.php:431 +msgid "Prices excluding tax" +msgstr "Precios sin impuesto" + #: PDFPrintLabel.php:44 msgid "The Price Labels could not be retrieved by the SQL because" msgstr "El SQL no pudo obtener las etiquetas de precios porque" @@ -22833,7 +22835,7 @@ #: PricesByCost.php:144 msgid "all Categories" -msgstr "todas las Categorías" +msgstr "todas las categorías" #: PricesByCost.php:147 msgid "Items in" @@ -30026,12 +30028,6 @@ msgid "is expected" msgstr "se espera" -#: StockClone.php:1087 Stocks.php:1397 Stocks.php:1404 -#: ../webSHOP/includes/Functions.php:127 -#: ../webSHOP/includes/ShowSalesCategoriesMenu.php:15 -msgid "Categories" -msgstr "Clases" - #: StockCostUpdate.php:8 msgid "Stock Cost Update" msgstr "Actualizar Costo de Existencia" @@ -39742,7 +39738,7 @@ msgstr "El Campo puede ser nulo" #: Z_DescribeTable.php:15 includes/DatabaseTranslations.php:59 -#: install/index.php:1041 reportwriter/languages/en_US/reports.php:65 +#: install/index.php:1040 reportwriter/languages/en_US/reports.php:65 msgid "Default" msgstr "Predeterminado" @@ -42028,7 +42024,7 @@ "en las siguientes funciones ya no son necesarios. Al llamar a estas " "funciones, deje los dos últimos parámetros fuera." -#: api/api_xml-rpc.php:16 install/index.php:915 +#: api/api_xml-rpc.php:16 install/index.php:914 msgid "Database Name" msgstr "Nombre de Base de Datos" @@ -45051,11 +45047,11 @@ msgid "Security Permissions Problem" msgstr "Problema de Permisos de Seguridad" -#: includes/session.inc:311 ../webSHOP/includes/session.php:147 +#: includes/session.inc:319 ../webSHOP/includes/session.php:147 msgid "Error in form verification" msgstr "" -#: includes/session.inc:313 ../webSHOP/includes/session.php:151 +#: includes/session.inc:321 ../webSHOP/includes/session.php:151 msgid "This form was not submitted with a correct ID" msgstr "Este formulario no se presentó con una identificación correcta" @@ -48022,23 +48018,23 @@ msgid "The SQL that failed was: " msgstr "El SQL que generó el error:" -#: includes/UserLogin.php:48 +#: includes/UserLogin.php:47 msgid "Could not retrieve user details on login because" msgstr "No se pudieron obtener datos de usuario al iniciar sesión debido a que" -#: includes/UserLogin.php:134 +#: includes/UserLogin.php:172 msgid "User access blocked" msgstr "Acceso del usuario bloqueado" -#: includes/UserLogin.php:135 +#: includes/UserLogin.php:173 msgid "has been blocked access at" msgstr "se sido bloqueado el acceso a" -#: includes/UserLogin.php:136 +#: includes/UserLogin.php:174 msgid "from IP" msgstr "Desde el IP" -#: includes/UserLogin.php:136 +#: includes/UserLogin.php:174 msgid "due to too many failed attempts." msgstr "debido a demasiados intentos fallidos." @@ -48066,7 +48062,7 @@ "\" etc" msgstr "" -#: install/index.php:193 install/index.php:539 +#: install/index.php:193 install/index.php:538 msgid "The database name should not be empty" msgstr "" @@ -48123,143 +48119,143 @@ msgid "WebERP Demo Company" msgstr "" -#: install/index.php:400 +#: install/index.php:399 msgid "Cannot open the configuration file" msgstr "" -#: install/index.php:404 +#: install/index.php:403 msgid "Cannot write to the configuration file" msgstr "" -#: install/index.php:415 install/index.php:420 +#: install/index.php:414 install/index.php:419 msgid "Failed to connect the database, the error is " msgstr "" -#: install/index.php:431 install/index.php:433 install/index.php:460 -#: install/index.php:462 +#: install/index.php:430 install/index.php:432 install/index.php:459 +#: install/index.php:461 msgid "Failed to create database " msgstr "" -#: install/index.php:441 install/index.php:443 install/index.php:474 -#: install/index.php:476 +#: install/index.php:440 install/index.php:442 install/index.php:473 +#: install/index.php:475 msgid "Failed to create database weberpdemo and the error is " msgstr "" -#: install/index.php:514 +#: install/index.php:513 msgid "The Host Name is illegal" msgstr "" -#: install/index.php:521 +#: install/index.php:520 msgid "The Host Name should not be empty" msgstr "" -#: install/index.php:533 +#: install/index.php:532 msgid "" "The database name should be lower case and not contains illegal characters " "such as \"/\\?%:|<>\"" msgstr "" -#: install/index.php:561 +#: install/index.php:560 msgid "Please correct the displayed error first" msgstr "" -#: install/index.php:575 install/index.php:985 install/index.php:1012 +#: install/index.php:574 install/index.php:984 install/index.php:1011 msgid "webERP Installation Wizard" msgstr "" -#: install/index.php:592 +#: install/index.php:591 msgid "" "Please set Cookies allowed in your web brower, otherwise webERP cannot run " "properly" msgstr "" -#: install/index.php:601 +#: install/index.php:600 msgid "" "Illegal characters or data has been identified, please see your admistrator " "for help" msgstr "" -#: install/index.php:609 +#: install/index.php:608 msgid "" "Although webERP should work with PHP version 5.1 onwards, a PHP version " "greater than 5.2 is strongly recommended" msgstr "" -#: install/index.php:616 install/index.php:621 +#: install/index.php:615 install/index.php:620 msgid "The directory" msgstr "" -#: install/index.php:616 +#: install/index.php:615 msgid "must be writable by web server" msgstr "" -#: install/index.php:626 +#: install/index.php:625 msgid "The mbstring extension is not availble in your PHP" msgstr "" -#: install/index.php:631 +#: install/index.php:630 msgid "The libxml extension is not available in your PHP" msgstr "" -#: install/index.php:637 +#: install/index.php:636 msgid "There is no MySQL or MySQL extension available" msgstr "" -#: install/index.php:643 +#: install/index.php:642 msgid "" "The PHP MySQLI extension is recommend as MySQL extension has been deprecated " "since PHP 5.5" msgstr "" -#: install/index.php:647 +#: install/index.php:646 msgid "" "The MySQL extension has been deprecated since 5.5. You should install the " "MySQLI extension or downgrade you PHP version to one prior to 5.5" msgstr "" -#: install/index.php:652 +#: install/index.php:651 msgid "The GD extension should be installed in your PHP configuration" msgstr "" -#: install/index.php:750 +#: install/index.php:749 msgid "Welcome to the webERP Installation Wizard" msgstr "" -#: install/index.php:754 +#: install/index.php:753 msgid "During installation you may see different status messages." msgstr "" -#: install/index.php:755 +#: install/index.php:754 msgid "When there is an error message you must correct the error to continue." msgstr "" -#: install/index.php:756 +#: install/index.php:755 msgid "If you see a warning message you should take notice before you proceed." msgstr "" -#: install/index.php:757 +#: install/index.php:756 msgid "If you are unsure of an option value, you may keep the default setting." msgstr "" -#: install/index.php:764 +#: install/index.php:763 msgid "Select your language" msgstr "Seleccione su idioma" -#: install/index.php:767 +#: install/index.php:766 msgid "" "The installer will try and guess your language from your browser, but may " "get it wrong. Please select you preferred language below." msgstr "" -#: install/index.php:771 +#: install/index.php:770 msgid "Language:" msgstr "Idioma" -#: install/index.php:876 install/index.php:951 +#: install/index.php:875 install/index.php:950 msgid "Next Step" msgstr "" -#: install/index.php:882 +#: install/index.php:881 msgid "" "webERP is an open source application licenced under GPL V2 and absolutely " "free to download.<br /> By installing webERP you acknowledge you have read " @@ -48268,181 +48264,181 @@ "information." msgstr "" -#: install/index.php:901 +#: install/index.php:900 msgid "Database settings" msgstr "" -#: install/index.php:904 +#: install/index.php:903 msgid "Please enter your MySQL Database information below." msgstr "" -#: install/index.php:905 install/index.php:1018 +#: install/index.php:904 install/index.php:1017 msgid "* Denotes required field" msgstr "" -#: install/index.php:910 +#: install/index.php:909 msgid "Host Name" msgstr "" -#: install/index.php:911 +#: install/index.php:910 msgid "Enter database host name" msgstr "" -#: install/index.php:912 +#: install/index.php:911 msgid "Commonly: localhost or 127.0.0.1" msgstr "" -#: install/index.php:916 +#: install/index.php:915 msgid "The database name" msgstr "El nombre de la base de datos" -#: install/index.php:917 +#: install/index.php:916 msgid "The database must have a valid name" msgstr "La base de datos debe tener un nombre válido" -#: install/index.php:920 +#: install/index.php:919 msgid "Database Prefix" msgstr "Prefijo de base de datos" -#: install/index.php:921 +#: install/index.php:920 msgid "Useful with shared hosting" msgstr "" -#: install/index.php:922 +#: install/index.php:921 msgid "Optional: in the form of prefix_" msgstr "" -#: install/index.php:925 +#: install/index.php:924 msgid "Database User Name" msgstr "Nombre de usuario de la base de datos" -#: install/index.php:926 +#: install/index.php:925 msgid "A valid database user name" msgstr "Un nombre de usuario la base de datos válido" -#: install/index.php:927 +#: install/index.php:926 msgid "Must be a user that has permission to create a database" msgstr "" -#: install/index.php:931 +#: install/index.php:930 msgid "mySQL user password" msgstr "Contraseña de usuario de MySQL" -#: install/index.php:932 +#: install/index.php:931 msgid "Enter the user password if one exists" msgstr "" -#: install/index.php:964 +#: install/index.php:963 msgid "Check Again" msgstr "Comprobar de nuevo" -#: install/index.php:986 +#: install/index.php:985 msgid "Failed to connect to the database. Please correct the following error:" msgstr "" -#: install/index.php:1013 +#: install/index.php:1012 msgid "" "Please enter the company name and please pay attention the company will be " "as same as the database name" msgstr "" -#: install/index.php:1016 +#: install/index.php:1015 msgid "Company Settings" msgstr "Configuración de la compañía" -#: install/index.php:1024 +#: install/index.php:1023 msgid "" "The name of your company should not contain characters such as |\\?%:<>\"" msgstr "" -#: install/index.php:1027 +#: install/index.php:1026 msgid "Chart of Accounts" msgstr "" -#: install/index.php:1045 +#: install/index.php:1044 msgid "" "A starter Chart of Accounts (use default.sql if having empty db problems)" msgstr "" -#: install/index.php:1048 +#: install/index.php:1047 msgid "Time Zone" msgstr "Huso horario" -#: install/index.php:1052 +#: install/index.php:1051 msgid "Company logo file" msgstr "Archivo del logotipo de la compañía" -#: install/index.php:1053 +#: install/index.php:1052 msgid "A jpg file up to 10k, and not greater than 170px x 80px" msgstr "" -#: install/index.php:1054 +#: install/index.php:1053 msgid "jpg file to 10k, not greater than 170px x 80px" msgstr "" -#: install/index.php:1059 +#: install/index.php:1058 msgid "Installation option" msgstr "" -#: install/index.php:1062 +#: install/index.php:1061 msgid "Install the demo data?" msgstr "" -#: install/index.php:1063 +#: install/index.php:1062 msgid "WebERPDemo site and data will be installed" msgstr "" -#: install/index.php:1068 +#: install/index.php:1067 msgid "Administrator account settings" msgstr "" -#: install/index.php:1072 +#: install/index.php:1071 msgid "The default user name is 'admin' and it cannot be changed." msgstr "" -#: install/index.php:1075 +#: install/index.php:1074 msgid "The default password is 'weberp' which you can change below." msgstr "" -#: install/index.php:1081 +#: install/index.php:1080 msgid "webERP Admin Account" msgstr "Cuenta del administrador del webERP" -#: install/index.php:1085 +#: install/index.php:1084 msgid "Email address" msgstr "Dirección de correo electrónico" -#: install/index.php:1087 +#: install/index.php:1086 msgid "For example: ad...@yo..." msgstr "Por ejemplo: adm...@su..." -#: install/index.php:1090 +#: install/index.php:1089 msgid "webERP Password" msgstr "Contraseña del webERP" -#: install/index.php:1094 +#: install/index.php:1093 msgid "Re-enter Password" msgstr "Reintroduzca la contraseña" -#: install/index.php:1109 +#: install/index.php:1108 msgid "Install" msgstr "Instalar" -#: install/index.php:1132 +#: install/index.php:1131 msgid "Failed to open the new sql file" msgstr "No se pudo abrir el nuevo archivo sql" -#: install/index.php:1137 +#: install/index.php:1136 msgid "Failed to populate the database " msgstr "No se pudo llenar la base de datos" -#: install/index.php:1277 +#: install/index.php:1287 msgid "" "Failed to update the email address and password of the administrator and the " "error is" msgstr "" -#: install/index.php:1285 +#: install/index.php:1295 msgid "Failed to update the company name and the erroris" msgstr "" @@ -50535,5 +50531,11 @@ msgid "Bank Transfer" msgstr "" +#~ msgid "Prices for Categories" +#~ msgstr "Precios por Categorías" + +#~ msgid "Prices For Categories" +#~ msgstr "Precios por categorías" + #~ msgid "Maintenance Of Location Authorised Users" #~ msgstr "Mantenimiento de usuarios autorizados por ubicación" |
From: <rc...@us...> - 2014-08-28 05:26:21
|
Revision: 6847 http://sourceforge.net/p/web-erp/reponame/6847 Author: rchacon Date: 2014-08-28 05:26:07 +0000 (Thu, 28 Aug 2014) Log Message: ----------- Adds code comments, clean-up unneeded variables, simplies and reorder SQL select, reduces if() calls, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), fixes start-date for 'Y/m/d' format, adds start-date for 'Y-m-d' format, adds a summary section for the report, adds ViewTopic and BookMark, adds more NoOfPeriods. Modified Paths: -------------- trunk/PDFPriceList.php trunk/Tax.php trunk/doc/Change.log trunk/includes/PDFTaxPageHeader.inc trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po Modified: trunk/PDFPriceList.php =================================================================== --- trunk/PDFPriceList.php 2014-08-27 03:14:38 UTC (rev 6846) +++ trunk/PDFPriceList.php 2014-08-28 05:26:07 UTC (rev 6847) @@ -210,11 +210,11 @@ if ($PriceList['price']!=0) { $DisplayGPPercent = locale_number_format((($PriceList['price']-$PriceList['standardcost'])*100/$PriceList['price']), 2) . '%'; } - /*$LeftOvers = */$pdf->addTextWrap($Page_Width-$Right_Margin-128, $YPos-$FontSize, 32, $FontSize, + $pdf->addTextWrap($Page_Width-$Right_Margin-128, $YPos-$FontSize, 32, $FontSize, $DisplayGPPercent, 'right'); } // Displays unit price: - /*$LeftOvers = */$pdf->addTextWrap($Page_Width-$Right_Margin-96, $YPos-$FontSize, 96, $FontSize, + $pdf->addTextWrap($Page_Width-$Right_Margin-96, $YPos-$FontSize, 96, $FontSize, locale_number_format($PriceList['price'],$PriceList['decimalplaces']), 'right'); if ($_POST['CustomerSpecials']=='Customer Special Prices Only') { @@ -281,8 +281,8 @@ $ViewTopic = 'SalesTypes';// Filename in ManualContents.php's TOC. $BookMark = 'PDFPriceList';// Anchor's id in the manual's html document. include('includes/header.inc'); - echo '<p class="page_title_text"><img src="' . $RootPath . '/css/' . $Theme . '/images/customer.png" title="' . _('Price List') . '" alt="" /> - ' . ' ' . _('Print a price list by inventory category') . '</p>'; + echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . '/images/customer.png" title="' . + _('Price List') . '" />' . ' ' . _('Print a price list by inventory category') . '</p>'; if (!isset($_POST['FromCriteria']) or !isset($_POST['ToCriteria'])) { /*if $FromCriteria is not set then show a form to allow input */ @@ -360,13 +360,13 @@ global $SalesTypeName; global $CustomerName; - $PageNumber++; - if ($PageNumber>1) { + $PageNumber ++;// Increments $PageNumber before printing. + if ($PageNumber>1) {// Inserts a page break if it is not the first page. $pdf->newPage(); } $YPos = $Page_Height-$Top_Margin; - $FontSizeExt = $FontSize;// To preserve the main font size. + $FontSizeLast = $FontSize;// To preserve the main font size. $FontSize = 10; $pdf->addText($Left_Margin, $YPos, $FontSize, $_SESSION['CompanyRecord']['coyname']);// Company name. @@ -434,6 +434,6 @@ /* $YPos -= $FontSize;// Jumps additional line after the table headings.*/ - $FontSize = $FontSizeExt;// Resets to the main font size. + $FontSize = $FontSizeLast;// Resets to the main font size. } ?> Modified: trunk/Tax.php =================================================================== --- trunk/Tax.php 2014-08-27 03:14:38 UTC (rev 6846) +++ trunk/Tax.php 2014-08-28 05:26:07 UTC (rev 6847) @@ -1,16 +1,13 @@ <?php - /* $Id$*/ include('includes/session.inc'); -if (isset($_POST['TaxAuthority']) AND +if(isset($_POST['TaxAuthority']) AND isset($_POST['PrintPDF']) AND isset($_POST['NoOfPeriods']) AND - isset($_POST['ToPeriod'])){ + isset($_POST['ToPeriod'])) { - include('includes/PDFStarter.php'); - $sql = "SELECT lastdate_in_period FROM periods WHERE periodno='" . $_POST['ToPeriod'] . "'"; @@ -23,131 +20,136 @@ $TaxAuthDescription = DB_fetch_row($result); $TaxAuthorityName = $TaxAuthDescription[0]; - $pdf->addInfo('Title',_('Taxation Report')); - $ReportTitle = $TaxAuthorityName . ' ' . _('Tax Report for') . ' ' . $_POST['NoOfPeriods'] . ' ' . _('months to') . ' ' . $PeriodEnd; - $pdf->addInfo('Subject', $ReportTitle); + include('includes/PDFStarter.php'); + $pdf->addInfo('Title', _('Tax Report') . ': ' . $TaxAuthorityName); + $pdf->addInfo('Subject', $_POST['NoOfPeriods'] . ' ' . _('months to') . ' ' . $PeriodEnd); - $FontSize=12; - $PageNumber=0; - $line_height=12; - /*Now get the invoices for the tax report */ - - /*rchacon: The amounts of taxes are inserted into debtortranstaxes.taxamount in local currency and they are accumulated in debtortrans.ovgst in original currency.*/ - $SQL = "SELECT debtortrans.transno, - debtortrans.type, - systypes.typename, - debtortrans.trandate, - debtortrans.debtorno, - debtorsmaster.name, - debtortrans.branchcode, - debtortrans.order_, - (debtortrans.ovamount+debtortrans.ovfreight)/debtortrans.rate AS netamount, - debtortrans.ovfreight/debtortrans.rate AS freightamount, - debtortranstaxes.taxamount AS tax + /* The amounts of taxes are inserted into debtortranstaxes.taxamount in + local currency and they are accumulated in debtortrans.ovgst in original + currency. */ + $SQL = "SELECT + debtortrans.trandate, + debtortrans.type, + systypes.typename, + debtortrans.transno, + debtortrans.debtorno, + debtorsmaster.name, + debtortrans.branchcode, + (debtortrans.ovamount+debtortrans.ovfreight)/debtortrans.rate AS netamount, + debtortranstaxes.taxamount AS tax FROM debtortrans INNER JOIN debtorsmaster ON debtortrans.debtorno=debtorsmaster.debtorno INNER JOIN systypes ON debtortrans.type=systypes.typeid INNER JOIN debtortranstaxes ON debtortrans.id = debtortranstaxes.debtortransid - WHERE debtortrans.prd >= '" . ($_POST['ToPeriod'] - $_POST['NoOfPeriods'] + 1) . "' + WHERE debtortrans.prd >= '" .($_POST['ToPeriod'] - $_POST['NoOfPeriods'] + 1) . "' AND debtortrans.prd <= '" . $_POST['ToPeriod'] . "' AND (debtortrans.type=10 OR debtortrans.type=11) AND debtortranstaxes.taxauthid = '" . $_POST['TaxAuthority'] . "' - ORDER BY debtortrans.id"; + ORDER BY debtortrans.trandate";// RChacon: ORDER BY debtortrans.recno ? $DebtorTransResult = DB_query($SQL,$db,'','',false,false); //don't trap errors in DB_query - if (DB_error_no($db) !=0) { + if(DB_error_no($db) !=0) { $Title = _('Taxation Reporting Error'); include('includes/header.inc'); prnMsg(_('The accounts receivable transaction details could not be retrieved because') . ' ' . DB_error_msg($db),'error'); echo '<br /><a href="' . $RootPath . '/index.php">' . _('Back to the menu') . '</a>'; - if ($debug==1){ + if($debug==1) { echo '<br />' . $SQL; } include('includes/footer.inc'); exit; } - if ($_POST['DetailOrSummary']=='Detail'){ - include ('includes/PDFTaxPageHeader.inc'); - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,120,$FontSize+2, _('Tax On Sales'),'left'); - $YPos -=$line_height; - } + $SalesCount = 0; + $SalesNet = 0; + $SalesTax = 0; + if($_POST['DetailOrSummary']=='Detail') { + include('includes/PDFTaxPageHeader.inc'); + PageHeaderDetail(); - $Outputs =0; - $OutputTax =0; - $Inputs =0; - $InputTax =0; + $FontSize = 10; + $YPos -= $FontSize;// Jumps additional line. + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Tax On Sales')); + $YPos -= $FontSize; - $ListCount = 0; - - While ($DebtorTransRow = DB_fetch_array($DebtorTransResult,$db)){ - - $ListCount ++; - - if ($_POST['DetailOrSummary']=='Detail'){ - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,60,$FontSize, $DebtorTransRow['typename'],'left'); - $LeftOvers = $pdf->addTextWrap(100,$YPos,40,$FontSize, $DebtorTransRow['transno'],'left'); - $LeftOvers = $pdf->addTextWrap(140,$YPos,60,$FontSize,ConvertSQLDate($DebtorTransRow['trandate']),'left'); - $LeftOvers = $pdf->addTextWrap(200,$YPos,150,$FontSize, $DebtorTransRow['name'],'left'); - $LeftOvers = $pdf->addTextWrap(350,$YPos,60,$FontSize, $DebtorTransRow['branchcode'],'left'); - $LeftOvers = $pdf->addTextWrap(410,$YPos,60,$FontSize, locale_number_format($DebtorTransRow['netamount'],$_SESSION['CompanyRecord']['decimalplaces']),'right'); - $LeftOvers = $pdf->addTextWrap(470,$YPos,60,$FontSize, locale_number_format($DebtorTransRow['tax'],$_SESSION['CompanyRecord']['decimalplaces']),'right'); - - $YPos -=$line_height; - if ($YPos < $Bottom_Margin + $line_height){ + $FontSize = 8; + while($DebtorTransRow = DB_fetch_array($DebtorTransResult,$db)) { + $pdf->addText($Left_Margin, $YPos, $FontSize, ConvertSQLDate($DebtorTransRow['trandate'])); + $pdf->addText(82, $YPos, $FontSize, _($DebtorTransRow['typename'])); + $pdf->addTextWrap(140, $YPos-$FontSize, 40, $FontSize, $DebtorTransRow['transno'], 'right'); + $pdf->addText(180, $YPos, $FontSize, $DebtorTransRow['name']); + $LeftOvers = $pdf->addTextWrap(380, $YPos-$FontSize,60,$FontSize, $DebtorTransRow['branchcode'],'left');// RChacon: This data or debtor.reference ? + $pdf->addTextWrap(450, $YPos-$FontSize, 60, $FontSize, + locale_number_format($DebtorTransRow['netamount'],$_SESSION['CompanyRecord']['decimalplaces']), 'right'); + $pdf->addTextWrap($Page_Width-$Right_Margin-60, $YPos-$FontSize, 60, $FontSize, + locale_number_format($DebtorTransRow['tax'],$_SESSION['CompanyRecord']['decimalplaces']), 'right'); + $YPos -= $FontSize;// End-of-line line-feed. + if($YPos < $Bottom_Margin + $FontSize) { include('includes/PDFTaxPageHeader.inc'); + PageHeaderDetail(); } - } - $Outputs += $DebtorTransRow['netamount']; - $OutputTax += $DebtorTransRow['tax']; - } /*end listing while loop */ + $SalesCount ++;// Counts sales transactions. + $SalesNet += $DebtorTransRow['netamount'];// Accumulates sales net. + $SalesTax += $DebtorTransRow['tax'];// Accumulates sales tax. + } /*end listing while loop */ - if ($_POST['DetailOrSummary']=='Detail'){ - $YPos -=$line_height; - - if ($YPos < $Bottom_Margin + $line_height){ + // Prints out the sales totals: + $FontSize = 10; + if($YPos < $Bottom_Margin + $FontSize*4) { include('includes/PDFTaxPageHeader.inc'); + PageHeaderDetail(); } + $YPos -= $FontSize; + $pdf->line(306, $YPos-$FontSize/2, $Page_Width-$Right_Margin, $YPos-$FontSize/2); + $YPos -= $FontSize; + $pdf->addText(306, $YPos, $FontSize, _('Total Outputs')); + $pdf->addTextWrap(450, $YPos-$FontSize, 60, $FontSize, + locale_number_format($SalesNet,$_SESSION['CompanyRecord']['decimalplaces']), 'right'); + $pdf->addTextWrap($Page_Width-$Right_Margin-60, $YPos-$FontSize, 60, $FontSize, + locale_number_format($SalesTax,$_SESSION['CompanyRecord']['decimalplaces']), 'right'); + $YPos -= $FontSize; + $pdf->line(306, $YPos-$FontSize/2, $Page_Width-$Right_Margin, $YPos-$FontSize/2);// Rule off under output totals. + $YPos -= $FontSize; - $pdf->line(410, $YPos+$line_height,530, $YPos+$line_height); - - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,350,12, _('Total Outputs'),'right'); + } else { + while($DebtorTransRow = DB_fetch_array($DebtorTransResult,$db)) { + $SalesCount ++;// Counts sales transactions. + $SalesNet += $DebtorTransRow['netamount'];// Accumulates sales net. + $SalesTax += $DebtorTransRow['tax'];// Accumulates sales tax. + } /*end listing while loop */ } - - if ($_POST['DetailOrSummary']=='Detail'){ - /*Print out the outputs totals */ - $LeftOvers = $pdf->addTextWrap(410,$YPos,60,8, locale_number_format($Outputs,$_SESSION['CompanyRecord']['decimalplaces']),'right'); - $LeftOvers = $pdf->addTextWrap(470,$YPos,60,8, locale_number_format($OutputTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); - - /*Rule off under output totals */ - $pdf->line(410, $YPos-5,530, $YPos-5); - } - /*Now do the inputs from SuppTrans */ /*Only have dates in SuppTrans no periods so need to get the starting date */ - if (mb_strpos($PeriodEnd,'/')) { + if(mb_strpos($PeriodEnd,'/')) { $Date_Array = explode('/',$PeriodEnd); - } elseif (mb_strpos($PeriodEnd,'.')) { + } elseif(mb_strpos($PeriodEnd,'.')) { $Date_Array = explode('.',$PeriodEnd); + } elseif(mb_strpos($PeriodEnd,'-')) { + $Date_Array = explode('-',$PeriodEnd); } - if ($_SESSION['DefaultDateFormat']=='d/m/Y'){ + if($_SESSION['DefaultDateFormat']=='d/m/Y') { $StartDateSQL = Date('Y-m-d', mktime(0,0,0, (int)$Date_Array[1]-$_POST['NoOfPeriods']+1,1,(int)$Date_Array[2])); - } elseif ($_SESSION['DefaultDateFormat']=='m/d/Y') { + } elseif($_SESSION['DefaultDateFormat']=='m/d/Y') { $StartDateSQL = Date('Y-m-d', mktime(0,0,0, (int)$Date_Array[0]-$_POST['NoOfPeriods']+1,1,(int)$Date_Array[2])); - } elseif ($_SESSION['DefaultDateFormat']=='Y/m/d') { - $StartDateSQL = Date('Y-m-d', mktime(0,0,0, (int)$Date_Array[2]-$_POST['NoOfPeriods']+1,1,(int)$Date_Array[1])); - } elseif ($_SESSION['DefaultDateFormat']=='d.m.Y') { + } elseif($_SESSION['DefaultDateFormat']=='Y/m/d') { + $StartDateSQL = Date('Y-m-d', mktime(0,0,0, (int)$Date_Array[1]-$_POST['NoOfPeriods']+1,1,(int)$Date_Array[0])); + } elseif($_SESSION['DefaultDateFormat']=='d.m.Y') { $StartDateSQL = Date('Y-m-d', mktime(0,0,0, (int)$Date_Array[1]-$_POST['NoOfPeriods']+1,1,(int)$Date_Array[2])); + } elseif($_SESSION['DefaultDateFormat']=='Y-m-d') { + $StartDateSQL = Date('Y-m-d', mktime(0,0,0, (int)$Date_Array[1]-$_POST['NoOfPeriods']+1,1,(int)$Date_Array[0])); } - $SQL = "SELECT supptrans.type, - supptrans.suppreference, + $SQL = + "SELECT + supptrans.trandate, + supptrans.type, systypes.typename, - supptrans.trandate, + supptrans.transno, suppliers.suppname, + supptrans.suppreference, supptrans.ovamount/supptrans.rate AS netamount, supptranstaxes.taxamount/supptrans.rate AS taxamt FROM supptrans @@ -158,123 +160,153 @@ AND supptrans.trandate <= '" . FormatDateForSQL($PeriodEnd) . "' AND (supptrans.type=20 OR supptrans.type=21) AND supptranstaxes.taxauthid = '" . $_POST['TaxAuthority'] . "' - ORDER BY supptrans.trandate"; + ORDER BY supptrans.trandate";// ORDER BY supptrans.recno ? $SuppTransResult = DB_query($SQL,$db,'','',false,false); //doint trap errors in DB_query - if (DB_error_no($db) !=0) { + if(DB_error_no($db) !=0) { $Title = _('Taxation Reporting Error'); include('includes/header.inc'); echo _('The accounts payable transaction details could not be retrieved because') . ' ' . DB_error_msg($db); echo '<br /><a href="' . $RootPath . '/index.php?">' . _('Back to the menu') . '</a>'; - if ($debug==1){ + if($debug==1) { echo '<br />' . $SQL; } include('includes/footer.inc'); exit; } - if ($_POST['DetailOrSummary']=='Detail'){ - include ('includes/PDFTaxPageHeader.inc'); - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,120,$FontSize+2, _('Tax On Purchases'),'left'); - $YPos -=$line_height; - } + $PurchasesCount = 0; + $PurchasesNet = 0; + $PurchasesTax = 0; + if($_POST['DetailOrSummary']=='Detail') { + $FontSize = 10; + $YPos -= $FontSize;// Jumps additional line. + $pdf->addText($Left_Margin, $YPos+$FontSize, $FontSize, _('Tax On Purchases')); + $YPos -= $FontSize; - While ($SuppTransRow = DB_fetch_array($SuppTransResult,$db)){ - - $ListCount ++; - - if ($_POST['DetailOrSummary']=='Detail'){ - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,60,$FontSize, $SuppTransRow['typename'],'left'); - $LeftOvers = $pdf->addTextWrap(100,$YPos,40,$FontSize, $SuppTransRow['suppreference'],'left'); - $LeftOvers = $pdf->addTextWrap(140,$YPos,60,$FontSize,ConvertSQLDate($SuppTransRow['trandate']),'left'); - $LeftOvers = $pdf->addTextWrap(200,$YPos,150,$FontSize, $SuppTransRow['suppname'],'left'); - - $LeftOvers = $pdf->addTextWrap(410,$YPos,60,$FontSize, locale_number_format($SuppTransRow['netamount'],$_SESSION['CompanyRecord']['decimalplaces']),'right'); - $LeftOvers = $pdf->addTextWrap(470,$YPos,60,$FontSize, locale_number_format($SuppTransRow['taxamt'],$_SESSION['CompanyRecord']['decimalplaces']),'right'); - - $YPos -=$line_height; - if ($YPos < $Bottom_Margin + $line_height){ + // Prints out lines: + $FontSize = 8; + while($SuppTransRow = DB_fetch_array($SuppTransResult,$db)) { + $pdf->addText($Left_Margin, $YPos, $FontSize,ConvertSQLDate($SuppTransRow['trandate'])); + $pdf->addText(82, $YPos, $FontSize, _($SuppTransRow['typename'])); + $pdf->addTextWrap(140, $YPos-$FontSize, 40, $FontSize, $SuppTransRow['transno'],'right'); + $pdf->addText(180, $YPos, $FontSize, $SuppTransRow['suppname']); + $pdf->addText(380, $YPos, $FontSize, $SuppTransRow['suppreference']);//****************NEW + $pdf->addTextWrap(450, $YPos-$FontSize, 60, $FontSize, + locale_number_format($SuppTransRow['netamount'],$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $pdf->addTextWrap($Page_Width-$Right_Margin-60, $YPos-$FontSize, 60, $FontSize, + locale_number_format($SuppTransRow['taxamt'],$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $YPos -= $FontSize;// End-of-line line-feed. + if($YPos < $Bottom_Margin + $FontSize) { include('includes/PDFTaxPageHeader.inc'); + PageHeaderDetail(); } - } - $Inputs += $SuppTransRow['netamount']; - $InputTax += $SuppTransRow['taxamt']; - } /*end listing while loop */ + $PurchasesCount ++;// Counts purchases transactions. + $PurchasesNet += $SuppTransRow['netamount'];// Accumulates purchases net. + $PurchasesTax += $SuppTransRow['taxamt'];// Accumulates purchases tax. + } /*end listing while loop */ - if ($_POST['DetailOrSummary']=='Detail'){ - $YPos -=$line_height; - - if ($YPos < $Bottom_Margin + $line_height){ + // Print out the purchases totals: + $FontSize = 10; + if($YPos < $Bottom_Margin + $FontSize*4) { include('includes/PDFTaxPageHeader.inc'); + PageHeaderDetail(); } + $YPos -= $FontSize; + $pdf->line(306, $YPos-$FontSize/2, $Page_Width-$Right_Margin, $YPos-$FontSize/2); + $YPos -= $FontSize; + $pdf->addText(306, $YPos, $FontSize, _('Total Inputs')); + $pdf->addTextWrap(450, $YPos-$FontSize, 60, $FontSize, + locale_number_format($PurchasesNet,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $pdf->addTextWrap($Page_Width-$Right_Margin-60, $YPos-$FontSize, 60, $FontSize, + locale_number_format($PurchasesTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $YPos -= $FontSize; + $pdf->line(306, $YPos-$FontSize/2, $Page_Width-$Right_Margin, $YPos-$FontSize/2);// Rule off under output totals. + $YPos -= $FontSize; - $pdf->line(410, $YPos+$line_height,530, $YPos+$line_height); - - $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,350,12, _('Total Inputs'),'right'); + } else { + while($SuppTransRow = DB_fetch_array($SuppTransResult,$db)) { + $PurchasesCount ++;// Counts purchases transactions. + $PurchasesNet += $SuppTransRow['netamount'];// Accumulates purchases net. + $PurchasesTax += $SuppTransRow['taxamt'];// Accumulates purchases tax. + } /*end listing while loop */ } - /*Accumulate the input totals */ - if ($_POST['DetailOrSummary']=='Detail'){ - /*Print out the input totals */ - $LeftOvers = $pdf->addTextWrap(410,$YPos,60,8, locale_number_format($Inputs,$_SESSION['CompanyRecord']['decimalplaces']),'right'); - $LeftOvers = $pdf->addTextWrap(470,$YPos,60,8, locale_number_format($InputTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); - - /*Rule off under input totals */ - $pdf->line(410, $YPos-5,530, $YPos-5); - - /*New page before summary */ - $PageNumber++; - $pdf->newPage(); - } /*OK and now the summary */ - if ($PageNumber ==0) $PageNumber=1; //when only summary is run. - $FontSize=8; - $YPos= $Page_Height-$Top_Margin; - $pdf->addText($Left_Margin, $YPos,$FontSize, html_entity_decode($_SESSION['CompanyRecord']['coyname'])); + include('includes/PDFTaxPageHeader.inc'); + PageHeaderSummary(); - $YPos -=$line_height; + $FontSize = 10; + $YPos -= $FontSize;// Jumps additional line. - $FontSize =10; - $pdf->addText($Left_Margin, $YPos, $FontSize, $ReportTitle . ' ' . _('Summary')); + // Table headings: + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Transactions')); + $pdf->addTextWrap(150, $YPos-$FontSize, 100, $FontSize, _('Quantity'), 'right'); + $pdf->addTextWrap(250, $YPos-$FontSize, 100, $FontSize, _('Net'), 'right'); + $pdf->addTextWrap(350, $YPos-$FontSize, 100, $FontSize, _('Tax'), 'right'); + $pdf->addTextWrap(450, $YPos-$FontSize, 100, $FontSize, _('Total'), 'right'); + $YPos -= $FontSize; - $FontSize = 8; - $pdf->addText($Page_Width-$Right_Margin-120,$YPos,$FontSize, _('Printed') . ': ' . Date($_SESSION['DefaultDateFormat']) . ' ' . _('Page') . ' ' . $PageNumber); + $YPos -= $FontSize;// Jumps additional line. - $YPos -=(3*$line_height); + // Sales totals: + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Sales')); + $pdf->addTextWrap(150, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesCount), 'right'); + $pdf->addTextWrap(250, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesNet,$_SESSION['CompanyRecord']['decimalplaces']), 'right'); + $pdf->addTextWrap(350, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesTax,$_SESSION['CompanyRecord']['decimalplaces']), 'right'); + $SalesTotal = $SalesNet+$SalesTax; + $pdf->addTextWrap(450, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesTotal,$_SESSION['CompanyRecord']['decimalplaces']), 'right'); + $YPos -= $FontSize; + // Purchases totals: + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Purchases')); + $pdf->addTextWrap(150, $YPos-$FontSize, 100, $FontSize, + locale_number_format($PurchasesCount),'right'); + $pdf->addTextWrap(250, $YPos-$FontSize, 100, $FontSize, + locale_number_format($PurchasesNet,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $pdf->addTextWrap(350, $YPos-$FontSize, 100, $FontSize, + locale_number_format($PurchasesTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $PurchasesTotal = $PurchasesNet+$PurchasesTax; + $pdf->addTextWrap(450, $YPos-$FontSize, 100, $FontSize, + locale_number_format($PurchasesTotal,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $YPos -= $FontSize; - $pdf->line($Page_Width-$Right_Margin, $YPos+$line_height,$Left_Margin, $YPos+$line_height); + $pdf->line(140, $YPos-$FontSize/2, $Page_Width-$Right_Margin, $YPos-$FontSize/2);// Rule off under output totals. + $YPos -= $FontSize; - $YPos =$YPos - $line_height; + // Sales minus Purchases: + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Difference')); + $pdf->addTextWrap(150, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesCount-$PurchasesCount),'right'); + $pdf->addTextWrap(250, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesNet-$PurchasesNet,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $pdf->addTextWrap(350, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesTax-$PurchasesTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $PurchasesTotal = $PurchasesNet+$PurchasesTax; + $pdf->addTextWrap(450, $YPos-$FontSize, 100, $FontSize, + locale_number_format($SalesTotal-$PurchasesTotal,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $YPos -= $FontSize; - $LeftOvers = $pdf->addTextWrap(40,$YPos,180,$FontSize,_('Return Suggested Entries'),'left'); - $YPos -= (2*$line_height); + $YPos -= $FontSize*4;// Jumps additional lines. - $LeftOvers = $pdf->addTextWrap(40,$YPos,180,$FontSize,_('Total Sales and Income (incl Tax)'),'left'); - $LeftOvers = $pdf->addTextWrap(220,$YPos,100,$FontSize,locale_number_format($Outputs+$OutputTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Adjustments for Tax paid to Customs, FBT, entertainments etc must also be entered')); + $YPos -= $FontSize; + $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos-$FontSize, $Page_Width-$Left_Margin-$Right_Margin, $FontSize, + _('This information excludes Tax on journal entries/payments/receipts all Tax should be entered through AR/AP')); + $YPos -= $FontSize; + $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos-$FontSize, $Page_Width-$Left_Margin-$Right_Margin, $FontSize, $LeftOvers); - $YPos -= $line_height; - - $LeftOvers = $pdf->addTextWrap(40,$YPos,180,$FontSize,_('Tax On Liable Sales'),'left'); - $LeftOvers = $pdf->addTextWrap(220,$YPos,100,$FontSize,locale_number_format($OutputTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); - - - $YPos -= $line_height; - $LeftOvers = $pdf->addTextWrap(40,$YPos,200,$FontSize,_('Tax On Purchases'),'left'); - $LeftOvers = $pdf->addTextWrap(220,$YPos,100,$FontSize,locale_number_format($InputTax,$_SESSION['CompanyRecord']['decimalplaces']),'right'); - - $YPos -= (2*$line_height); - $LeftOvers = $pdf->addTextWrap(40,$YPos,500,$FontSize,_('Adjustments for Tax paid to Customs, FBT, entertainments etc must also be entered'),'left'); - $YPos -= $line_height; - $LeftOvers = $pdf->addTextWrap(40,$YPos,500,$FontSize,_('This information excludes Tax on journal entries/payments/receipts all Tax should be entered through AR/AP'),'left'); - - if ($ListCount == 0) { + if($SalesCount+$PurchasesCount == 0) { $Title = _('Taxation Reporting Error'); include('includes/header.inc'); - prnMsg (_('There are no tax entries to list'),'info'); + prnMsg(_('There are no tax entries to list'),'info'); echo '<br /><a href="' . $RootPath . '/index.php">' . _('Back to the menu') . '</a>'; include('includes/footer.inc'); exit; @@ -284,12 +316,13 @@ $pdf->__destruct(); } else { /*The option to print PDF was not hit */ - $Title=_('Tax Reporting'); + $Title =_('Tax Reporting'); + $ViewTopic = 'Tax';// Filename in ManualContents.php's TOC. + $BookMark = 'Tax';// Anchor's id in the manual's html document. include('includes/header.inc'); + echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . '/images/money_delete.png" title="' . + _('Tax Report') . '" />' . ' ' . _('Tax Reporting') . '</p>'; - echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/maintenance.png" title="' . _('Supplier Types') - . '" alt="" />' . $Title. '</p>'; - echo '<form action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post">'; echo '<div>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; @@ -299,21 +332,23 @@ <td><select name="TaxAuthority">'; $result = DB_query("SELECT taxid, description FROM taxauthorities",$db); - while ($myrow = DB_fetch_array($result)){ + while($myrow = DB_fetch_array($result)) { echo '<option value="' . $myrow['taxid'] . '">' . $myrow['description'] . '</option>'; } echo '</select></td></tr>'; echo '<tr> <td>' . _('Return Covering') . ':</td> - <td><select name="NoOfPeriods"> - <option value="1">' . _('One Month') . '</option>' . - '<option selected="selected" value="2">' ._('Two Months') . '</option>' . - '<option value="3">' . _('Quarter') . '</option>' . - '<option value="6">' . _('Six Months') . '</option>' . + <td><select name="NoOfPeriods">' . + '<option selected="selected" value="1">' . _('One Month') . '</option>' . + '<option value="2">' . _('2 Months') . '</option>' . + '<option value="3">' . _('3 Months') . '</option>' . + '<option value="6">' . _('6 Months') . '</option>' . + '<option value="12">' . _('12 Months') . '</option>' . + '<option value="24">' . _('24 Months') . '</option>' . + '<option value="48">' . _('48 Months') . '</option>' . '</select></td> </tr>'; - echo '<tr> <td>' . _('Return To') . ':</td> <td><select name="ToPeriod">'; @@ -327,8 +362,8 @@ $ErrMsg = _('Could not retrieve the period data because'); $Periods = DB_query($sql,$db,$ErrMsg); - while ($myrow = DB_fetch_array($Periods,$db)){ - if ($myrow['periodno']==$DefaultPeriod){ + while($myrow = DB_fetch_array($Periods,$db)) { + if($myrow['periodno']==$DefaultPeriod) { echo '<option selected="selected" value="' . $myrow['periodno'] . '">' . ConvertSQLDate($myrow['lastdate_in_period']) . '</option>'; } else { echo '<option value="' . $myrow['periodno'] . '">' . ConvertSQLDate($myrow['lastdate_in_period']) . '</option>'; @@ -336,18 +371,15 @@ } echo '</select></td> - </tr>'; - - echo '<tr> + </tr> + <tr> <td>' . _('Detail Or Summary Only') . ':</td> <td><select name="DetailOrSummary"> <option value="Detail">' . _('Detail and Summary') . '</option> <option selected="selected" value="Summary">' . _('Summary Only') . '</option> </select></td> - </tr>'; - - - echo '</table> + </tr> + </table> <br /> <div class="centre"> <input type="submit" name="PrintPDF" value="' . _('Print PDF') . '" /> @@ -358,4 +390,48 @@ include('includes/footer.inc'); } /*end of else not PrintPDF */ +function PageHeaderDetail() { + global $pdf; + global $Page_Width; + global $Left_Margin; + global $Right_Margin; + global $YPos; + $FontSize = 8; + // Draws a rectangle to put the headings in: + $pdf->Rectangle( + $Left_Margin,// Rectangle $XPos. + $YPos-$FontSize/2,// Rectangle $YPos. + $Page_Width-$Left_Margin-$Right_Margin,// Rectangle $Width. + $FontSize*2);// Rectangle $Height. + $YPos -= $FontSize; + // Prints the table headings: + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Date')); + $pdf->addText(82, $YPos, $FontSize, _('Type')); + $pdf->addTextWrap(140, $YPos-$FontSize, 40, $FontSize, _('Number'),'right'); + $pdf->addText(180, $YPos, $FontSize, _('Name')); + $pdf->addText(380, $YPos, $FontSize, _('Reference')); + $pdf->addTextWrap(450, $YPos-$FontSize, 60, $FontSize, _('Net'),'right'); + $pdf->addTextWrap($Page_Width-$Right_Margin-60, $YPos-$FontSize, 60, $FontSize, _('Tax'),'right'); + $YPos -= $FontSize*2; +} + +function PageHeaderSummary() { + global $pdf; + global $Page_Width; + global $Left_Margin; + global $Right_Margin; + global $YPos; + $FontSize = 10; + // Draws a rectangle to put the headings in: + $pdf->Rectangle( + $Left_Margin,// Rectangle $XPos. + $YPos-$FontSize/2,// Rectangle $YPos. + $Page_Width-$Left_Margin-$Right_Margin,// Rectangle $Width. + $FontSize*2);// Rectangle $Height. + $YPos -= $FontSize; + // Prints the table headings: + $pdf->addTextWrap($Left_Margin, $YPos-$FontSize, $Page_Width-$Left_Margin-$Right_Margin, $FontSize, _('Summary'),'center'); + $YPos -= $FontSize*2; +} + ?> Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-27 03:14:38 UTC (rev 6846) +++ trunk/doc/Change.log 2014-08-28 05:26:07 UTC (rev 6847) @@ -1,5 +1,6 @@ webERP Change Log +28/08/14 RChacon: In Tax.php: Adds code comments, clean-up unneeded variables, simplies and reorder SQL select, reduces if() calls, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), fixes start-date for 'Y/m/d' format, adds start-date for 'Y-m-d' format, adds a summary section for the report, adds ViewTopic and BookMark, adds more NoOfPeriods. 26/08/14 RChacon: In PDFPriceList.php: Adds code comments, adds PageHeader() print for currabrev and categoryid, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), adds 'Prices excluding tax' warning. 15/08/14 RChacon: Fixes double line feed in PDFQuotationPortrait.php reported by Arwan Galaya. Uniforms code between PDFQuotation.php and PDFQuotationPortrait.php. 14/08/14 RChacon: In CustomerInquiry.php and SupplierInquiry.php makes translatable the systypes.typename. Modified: trunk/includes/PDFTaxPageHeader.inc =================================================================== --- trunk/includes/PDFTaxPageHeader.inc 2014-08-27 03:14:38 UTC (rev 6846) +++ trunk/includes/PDFTaxPageHeader.inc 2014-08-28 05:26:07 UTC (rev 6847) @@ -1,44 +1,37 @@ <?php /* $Id$*/ -/*PDF page header for aged analysis reports */ -$PageNumber++; -if ($PageNumber>1){ +/* Please note that addTextWrap() YPos is a font-size-height further down than + addText() and other functions. Use addText() instead of addTextWrap() to + print left aligned elements.*/ + +// $PageNumber is initialised in 0 by includes/PDFStarter.php. +$PageNumber ++;// Increments $PageNumber before printing. +if ($PageNumber>1) {// Inserts a page break if it is not the first page. $pdf->newPage(); } -$FontSize=8; -$YPos= $Page_Height-$Top_Margin; +$YPos = $Page_Height-$Top_Margin; +$FontSizeLast = $FontSize;// To preserve the main font size. -$pdf->addText($Left_Margin, $YPos,$FontSize, html_entity_decode($_SESSION['CompanyRecord']['coyname'])); +$FontSize = 10; +$pdf->addText($Left_Margin, $YPos, $FontSize, + $_SESSION['CompanyRecord']['coyname']);// Prints company name. +$pdf->addTextWrap($Page_Width-$Right_Margin-140, $YPos-$FontSize, 140, $FontSize, + _('Page'). ' ' . $PageNumber, 'right');// Page number. +$YPos -= $FontSize; -$YPos -=$line_height; +$pdf->addText($Left_Margin, $YPos, $FontSize, + _('Tax Report') . ': ' . $TaxAuthorityName);// Prints tax authority name. +$pdf->addTextWrap($Page_Width-$Right_Margin-140, $YPos-$FontSize, 140, $FontSize, + _('Printed') . ': ' . date($_SESSION['DefaultDateFormat']), 'right');// Date printed. +$YPos -= $FontSize; -$FontSize =10; -$pdf->addText($Left_Margin, $YPos, $FontSize, $ReportTitle); +$pdf->addText($Left_Margin, $YPos, $FontSize, + $_POST['NoOfPeriods'] . ' ' . _('months to') . ' ' . $PeriodEnd);// Prints NoOfPeriods and PeriodEnd. +$pdf->addTextWrap($Page_Width-$Right_Margin-140, $YPos-$FontSize, 140, $FontSize, + date('H:i:s'), 'right');// Time printed. +$YPos -= $FontSize; -$FontSize = 8; -$pdf->addText($Page_Width-$Right_Margin-120,$YPos,$FontSize, _('Printed') . ': ' . Date("d M Y") . ' ' . _('Page') . ' ' . $PageNumber); - -$YPos -=(3*$line_height); - -/*Draw a rectangle to put the headings in */ -$pdf->line($Page_Width-$Right_Margin, $YPos-5,$Left_Margin, $YPos-5); -$pdf->line($Page_Width-$Right_Margin, $YPos+$line_height,$Left_Margin, $YPos+$line_height); -$pdf->line($Page_Width-$Right_Margin, $YPos+$line_height,$Page_Width-$Right_Margin, $YPos-5); -$pdf->line($Left_Margin, $YPos+$line_height,$Left_Margin, $YPos-5); - -/*set up the headings */ -$Xpos = $Left_Margin+1; - -$LeftOvers = $pdf->addTextWrap(40,$YPos,60 - $Left_Margin,$FontSize,_('Type'),'centre'); -$LeftOvers = $pdf->addTextWrap(100,$YPos,40 - $Left_Margin,$FontSize,_('No'),'centre'); -$LeftOvers = $pdf->addTextWrap(140,$YPos,60,$FontSize,_('Date'),'centre'); -$LeftOvers = $pdf->addTextWrap(240,$YPos,60,$FontSize,_('Name'),'centre'); -$LeftOvers = $pdf->addTextWrap(350,$YPos,60,$FontSize,_('Code'),'centre'); -$LeftOvers = $pdf->addTextWrap(450,$YPos,60,$FontSize,_('Net'),'centre'); -$LeftOvers = $pdf->addTextWrap(510,$YPos,60,$FontSize,_('Tax'),'centre'); - -$YPos =$YPos - (2*$line_height); - +$FontSize = $FontSizeLast;// Resets to the main font size. ?> \ No newline at end of file Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-27 03:14:38 UTC (rev 6846) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-28 05:26:07 UTC (rev 6847) @@ -7,8 +7,8 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-26 18:46-0600\n" -"PO-Revision-Date: 2014-08-26 18:54-0600\n" +"POT-Creation-Date: 2014-08-27 22:51-0600\n" +"PO-Revision-Date: 2014-08-27 22:55-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -405,7 +405,6 @@ #: SystemParameters.php:1123 SystemParameters.php:1127 TaxGroups.php:312 #: TaxGroups.php:315 TaxGroups.php:373 WWW_Users.php:504 WWW_Users.php:508 #: WWW_Users.php:677 WWW_Users.php:681 includes/PDFLowGPPageHeader.inc:44 -#: includes/PDFTaxPageHeader.inc:35 #: reportwriter/languages/en_US/reports.php:82 msgid "No" msgstr "No" @@ -683,9 +682,8 @@ #: CustomerBranches.php:408 Customers.php:1119 Customers.php:1127 #: ImportBankTransAnalysis.php:207 SalesPeople.php:200 SelectCustomer.php:609 #: StockDispatch.php:275 StockDispatch.php:286 StockDispatch.php:297 -#: SuppTransGLAnalysis.php:108 SupplierContacts.php:152 -#: includes/PDFTaxPageHeader.inc:37 includes/InputSerialItemsFile.php:92 -#: includes/InputSerialItemsFile.php:144 +#: SuppTransGLAnalysis.php:108 SupplierContacts.php:152 Tax.php:411 +#: includes/InputSerialItemsFile.php:92 includes/InputSerialItemsFile.php:144 msgid "Name" msgstr "Nombre" @@ -806,11 +804,10 @@ #: StockDispatch.php:299 StockLocMovements.php:92 StockMovements.php:99 #: StockSerialItemResearch.php:82 SupplierAllocations.php:456 #: SupplierAllocations.php:569 SupplierAllocations.php:644 -#: SupplierInquiry.php:209 SupplierTransInquiry.php:105 +#: SupplierInquiry.php:209 SupplierTransInquiry.php:105 Tax.php:408 #: includes/PDFQuotationPageHeader.inc:23 #: includes/PDFQuotationPortraitPageHeader.inc:80 -#: includes/PDFStatementPageHeader.inc:169 includes/PDFTaxPageHeader.inc:36 -#: includes/PDFTransPageHeader.inc:51 +#: includes/PDFStatementPageHeader.inc:169 includes/PDFTransPageHeader.inc:51 #: includes/PDFTransPageHeaderPortrait.inc:63 #: reportwriter/languages/en_US/reports.php:64 msgid "Date" @@ -1030,7 +1027,7 @@ #: SuppContractChgs.php:107 SuppFixedAssetChgs.php:97 SuppShiptChgs.php:97 #: SuppTransGLAnalysis.php:139 SupplierAllocations.php:458 #: SupplierAllocations.php:570 SupplierAllocations.php:645 -#: SupplierCredit.php:407 SupplierInquiry.php:214 +#: SupplierCredit.php:407 SupplierInquiry.php:214 Tax.php:250 #: Z_CheckDebtorsControl.php:149 api/api_debtortransactions.php:1271 #: api/api_debtortransactions.php:1284 api/api_debtortransactions.php:1581 #: includes/PDFQuotationPageHeader.inc:109 @@ -1132,7 +1129,7 @@ #: StockDispatch.php:128 StockDispatch.php:141 SuppPaymentRun.php:112 #: SuppPaymentRun.php:122 SuppPaymentRun.php:186 SuppPaymentRun.php:217 #: SuppPriceList.php:142 SupplierBalsAtPeriodEnd.php:54 -#: SupplierBalsAtPeriodEnd.php:65 Tax.php:64 Tax.php:169 Tax.php:278 +#: SupplierBalsAtPeriodEnd.php:65 Tax.php:57 Tax.php:171 Tax.php:310 #: Z_DataExport.php:72 Z_DataExport.php:168 Z_DataExport.php:259 #: Z_DataExport.php:308 Z_DataExport.php:347 Z_DataExport.php:383 #: Z_DataExport.php:419 Z_DataExport.php:471 Z_poRebuildDefault.php:41 @@ -1280,7 +1277,7 @@ #: PDFPriceList.php:340 PDFRemittanceAdvice.php:175 #: PDFStockCheckComparison.php:371 PrintCustTrans.php:572 #: PrintCustTransPortrait.php:614 ReorderLevel.php:259 StockDispatch.php:447 -#: SuppPriceList.php:263 SupplierBalsAtPeriodEnd.php:159 Tax.php:353 +#: SuppPriceList.php:263 SupplierBalsAtPeriodEnd.php:159 Tax.php:385 msgid "Print PDF" msgstr "Imprimir PDF" @@ -1541,11 +1538,10 @@ #: SalesByTypePeriodInquiry.php:356 SelectCustomer.php:424 #: ShipmentCosting.php:536 ShipmentCosting.php:613 StockLocMovements.php:90 #: StockMovements.php:97 SupplierAllocations.php:454 SupplierInquiry.php:210 -#: SupplierTransInquiry.php:20 SupplierTransInquiry.php:102 +#: SupplierTransInquiry.php:20 SupplierTransInquiry.php:102 Tax.php:409 #: Z_CheckAllocationsFrom.php:32 Z_CheckAllocationsFrom.php:57 #: Z_CheckAllocs.php:62 Z_CheckGLTransBalance.php:11 -#: includes/PDFTaxPageHeader.inc:34 includes/InputSerialItemsFile.php:94 -#: includes/InputSerialItemsFile.php:152 +#: includes/InputSerialItemsFile.php:94 includes/InputSerialItemsFile.php:152 #: reportwriter/languages/en_US/reports.php:111 msgid "Type" msgstr "Tipo" @@ -1640,10 +1636,11 @@ #: SuppCreditGRNs.php:291 SuppCreditGRNs.php:292 SupplierCredit.php:318 #: SupplierTenderCreate.php:435 SupplierTenderCreate.php:856 #: SupplierTenders.php:124 SupplierTenders.php:327 SupplierTenders.php:531 -#: SupplierTenders.php:534 SupplierTenders.php:690 WOSerialNos.php:263 -#: WOSerialNos.php:269 WOSerialNos.php:303 WorkOrderReceive.php:956 -#: api/api_xml-rpc.php:2533 api/api_xml-rpc.php:2579 api/api_xml-rpc.php:2775 -#: includes/PDFBOMListingPageHeader.inc:44 includes/PDFDIFOTPageHeader.inc:42 +#: SupplierTenders.php:534 SupplierTenders.php:690 Tax.php:247 +#: WOSerialNos.php:263 WOSerialNos.php:269 WOSerialNos.php:303 +#: WorkOrderReceive.php:956 api/api_xml-rpc.php:2533 api/api_xml-rpc.php:2579 +#: api/api_xml-rpc.php:2775 includes/PDFBOMListingPageHeader.inc:44 +#: includes/PDFDIFOTPageHeader.inc:42 #: includes/PDFDeliveryDifferencesPageHeader.inc:43 #: includes/PDFInventoryValnPageHeader.inc:33 #: includes/PDFInventoryValnPageHeader.inc:39 @@ -1703,10 +1700,10 @@ #: GLAccountReport.php:327 InventoryPlanningPrefSupplier.php:58 #: InventoryQuantities.php:234 MRPPlannedPurchaseOrders.php:320 #: MRPPlannedWorkOrders.php:374 MRPReport.php:817 MRPReschedules.php:180 -#: MRPShortages.php:334 PDFOrderStatus.php:323 PDFPriceList.php:383 +#: MRPShortages.php:334 PDFOrderStatus.php:323 PDFPriceList.php:384 #: PDFReceipt.php:34 PO_Header.php:845 PO_PDFPurchOrder.php:64 #: PO_SelectOSPurchOrder.php:547 ReorderLevel.php:283 StockDispatch.php:477 -#: SuppPriceList.php:292 Tax.php:244 includes/PDFAgedDebtorsPageHeader.inc:34 +#: SuppPriceList.php:292 includes/PDFAgedDebtorsPageHeader.inc:34 #: includes/PDFAgedSuppliersPageHeader.inc:21 #: includes/PDFBOMListingPageHeader.inc:26 #: includes/PDFBalanceSheetPageHeader.inc:25 @@ -1731,7 +1728,7 @@ #: includes/PDFSupplierBalsPageHeader.inc:20 #: includes/PDFTabReportHeader.inc:15 #: includes/PDFTagProfitAndLossPageHeader.inc:29 -#: includes/PDFTaxPageHeader.inc:21 includes/PDFTopItemsHeader.inc:34 +#: includes/PDFTaxPageHeader.inc:27 includes/PDFTopItemsHeader.inc:34 #: includes/PDFTrialBalancePageHeader.inc:18 #: reportwriter/languages/en_US/reports.php:88 msgid "Printed" @@ -1742,12 +1739,12 @@ #: InventoryPlanningPrefSupplier.php:58 InventoryQuantities.php:235 #: MRPPlannedPurchaseOrders.php:321 MRPPlannedWorkOrders.php:375 #: MRPReport.php:818 MRPReschedules.php:181 MRPShortages.php:335 -#: PDFPriceList.php:373 PDFReceipt.php:34 PDFRemittanceAdvice.php:218 +#: PDFPriceList.php:374 PDFReceipt.php:34 PDFRemittanceAdvice.php:218 #: PrintCustOrder.php:175 PrintCustTrans.php:773 PrintCustTrans.php:982 #: PrintCustTrans.php:1031 PrintCustTransPortrait.php:818 #: PrintCustTransPortrait.php:1040 PrintCustTransPortrait.php:1096 #: ReorderLevel.php:284 StockDispatch.php:478 SuppPriceList.php:293 -#: Tax.php:244 includes/PDFAgedDebtorsPageHeader.inc:34 +#: includes/PDFAgedDebtorsPageHeader.inc:34 #: includes/PDFAgedSuppliersPageHeader.inc:21 #: includes/PDFBOMListingPageHeader.inc:26 #: includes/PDFBalanceSheetPageHeader.inc:26 @@ -2058,9 +2055,8 @@ #: SuppPriceList.php:308 SupplierPriceList.php:270 SupplierPriceList.php:455 #: SupplierTenderCreate.php:617 SupplierTenderCreate.php:852 #: SupplierTenders.php:686 TopItems.php:166 WorkOrderEntry.php:732 -#: WorkOrderIssue.php:754 includes/PDFTaxPageHeader.inc:38 -#: includes/PDFTopItemsHeader.inc:49 includes/PO_PDFOrderPageHeader.inc:75 -#: ../webSHOP/ItemDetails.php:72 +#: WorkOrderIssue.php:754 includes/PDFTopItemsHeader.inc:49 +#: includes/PO_PDFOrderPageHeader.inc:75 ../webSHOP/ItemDetails.php:72 msgid "Code" msgstr "Código" @@ -3225,8 +3221,9 @@ #: PrintCustTransPortrait.php:1023 PrintCustTransPortrait.php:1078 #: StockMovements.php:98 SupplierAllocations.php:455 #: SupplierAllocations.php:568 SupplierAllocations.php:643 -#: SupplierInquiry.php:211 SupplierTransInquiry.php:103 Z_CheckAllocs.php:63 -#: Z_CheckGLTransBalance.php:12 includes/PDFQuotationPageHeader.inc:21 +#: SupplierInquiry.php:211 SupplierTransInquiry.php:103 Tax.php:410 +#: Z_CheckAllocs.php:63 Z_CheckGLTransBalance.php:12 +#: includes/PDFQuotationPageHeader.inc:21 #: includes/PDFQuotationPortraitPageHeader.inc:78 #: includes/PDFStatementPageHeader.inc:168 #: includes/PDFStatementPageHeader.inc:179 includes/PDFTransPageHeader.inc:47 @@ -3242,7 +3239,7 @@ #: PaymentAllocations.php:64 PaymentAllocations.php:65 Payments.php:921 #: ShiptsList.php:37 StockCounts.php:144 StockCounts.php:169 #: StockCounts.php:216 StockLocMovements.php:95 StockMovements.php:103 -#: SupplierInquiry.php:212 Z_CheckAllocs.php:64 +#: SupplierInquiry.php:212 Tax.php:412 Z_CheckAllocs.php:64 #: includes/PDFBankingSummaryPageHeader.inc:40 #: includes/PDFCustTransListingPageHeader.inc:49 #: includes/PDFPeriodStockTransListingPageHeader.inc:48 @@ -3406,8 +3403,8 @@ #: COGSGLPostings.php:316 Customers.php:513 Customers.php:850 #: EDIProcessOrders.php:386 PDFCustomerList.php:334 PDFPriceList.php:31 -#: PDFPriceList.php:144 PDFPriceList.php:284 PDFPriceList.php:378 -#: PDFPriceList.php:380 PricesBasedOnMarkUp.php:226 PricesByCost.php:268 +#: PDFPriceList.php:144 PDFPriceList.php:285 PDFPriceList.php:379 +#: PDFPriceList.php:381 PricesBasedOnMarkUp.php:226 PricesByCost.php:268 #: SalesGLPostings.php:363 SelectOrderItems.php:697 SuppPriceList.php:138 #: SuppPriceList.php:251 msgid "Price List" @@ -3907,7 +3904,7 @@ #: CounterReturns.php:1819 CounterSales.php:747 CounterSales.php:2431 #: Credit_Invoice.php:291 DeliveryDetails.php:870 GoodsReceived.php:100 #: InternalStockRequest.php:271 Labels.php:577 Labels.php:579 Labels.php:621 -#: OrderDetails.php:168 OutstandingGRNs.php:179 PDFPriceList.php:403 +#: OrderDetails.php:168 OutstandingGRNs.php:179 PDFPriceList.php:404 #: PDFPrintLabel.php:64 PO_Items.php:715 PO_OrderDetails.php:186 #: PrintCustTrans.php:896 PrintCustTrans.php:985 PrintCustTrans.php:1034 #: PrintCustTransPortrait.php:947 PrintCustTransPortrait.php:1045 @@ -3936,7 +3933,7 @@ #: CounterSales.php:748 Credit_Invoice.php:292 DeliveryDetails.php:871 #: DeliveryDetails.php:941 InternalStockRequest.php:158 #: InternalStockRequest.php:272 Labels.php:582 OrderDetails.php:169 -#: PDFPriceList.php:407 PDFPrintLabel.php:65 PO_Items.php:792 +#: PDFPriceList.php:408 PDFPrintLabel.php:65 PO_Items.php:792 #: PO_OrderDetails.php:187 PrintCustTrans.php:897 PrintCustTrans.php:986 #: PrintCustTrans.php:1035 PrintCustTransPortrait.php:948 #: PrintCustTransPortrait.php:1046 PrintCustTransPortrait.php:1102 @@ -3981,7 +3978,7 @@ #: DeliveryDetails.php:944 GoodsReceived.php:113 Labels.php:592 Labels.php:594 #: Labels.php:624 OffersReceived.php:110 OffersReceived.php:218 #: OffersReceived.php:278 OrderDetails.php:172 PDFOrdersInvoiced.php:378 -#: PDFPriceList.php:426 PDFPrintLabel.php:66 PO_AuthoriseMyOrders.php:116 +#: PDFPriceList.php:427 PDFPrintLabel.php:66 PO_AuthoriseMyOrders.php:116 #: PriceMatrix.php:224 Prices.php:222 Prices.php:334 PricesByCost.php:253 #: Prices_Customer.php:361 PrintCustTrans.php:900 PrintCustTrans.php:989 #: PrintCustTrans.php:1038 PrintCustTransPortrait.php:951 @@ -4033,7 +4030,7 @@ #: Credit_Invoice.php:300 Credit_Invoice.php:301 PrintCustTrans.php:423 #: PrintCustTrans.php:1077 PrintCustTransPortrait.php:480 #: PrintCustTransPortrait.php:1144 SelectCreditItems.php:694 -#: SelectCreditItems.php:695 includes/PDFTaxPageHeader.inc:40 +#: SelectCreditItems.php:695 Tax.php:249 Tax.php:414 msgid "Tax" msgstr "Impuestos" @@ -5996,7 +5993,7 @@ #: Contracts.php:779 CustomerInquiry.php:220 CustomerTransInquiry.php:108 #: Dashboard.php:668 FTP_RadioBeacon.php:52 PDFOrderStatus.php:294 -#: PDFOrdersInvoiced.php:293 PDFPriceList.php:417 PricesByCost.php:155 +#: PDFOrdersInvoiced.php:293 PDFPriceList.php:418 PricesByCost.php:155 #: Prices_Customer.php:263 Prices_Customer.php:337 PrintCustTrans.php:846 #: PrintCustTransPortrait.php:892 SelectCompletedOrder.php:557 #: SelectCreditItems.php:243 SelectCustomer.php:422 SelectOrderItems.php:595 @@ -6121,7 +6118,7 @@ #: Contracts.php:937 GLProfit_Loss.php:321 GLProfit_Loss.php:514 #: GLProfit_Loss.php:816 GLProfit_Loss.php:1173 GLTagProfit_Loss.php:309 #: GLTagProfit_Loss.php:447 GLTagProfit_Loss.php:686 GLTagProfit_Loss.php:885 -#: PDFPriceList.php:421 SalesAnalReptCols.php:31 SalesAnalReptCols.php:33 +#: PDFPriceList.php:422 SalesAnalReptCols.php:31 SalesAnalReptCols.php:33 #: SalesByTypePeriodInquiry.php:362 SalesCategoryPeriodInquiry.php:169 #: SalesGraph.php:192 SalesGraph.php:211 SalesGraph.php:274 #: SelectProduct.php:170 @@ -6445,7 +6442,7 @@ #: CounterReturns.php:674 CounterSales.php:757 PrintCustTrans.php:902 #: PrintCustTrans.php:991 PrintCustTrans.php:1040 #: PrintCustTransPortrait.php:953 PrintCustTransPortrait.php:1051 -#: PrintCustTransPortrait.php:1107 includes/PDFTaxPageHeader.inc:39 +#: PrintCustTransPortrait.php:1107 Tax.php:248 Tax.php:413 msgid "Net" msgstr "Neto" @@ -11245,7 +11242,7 @@ #: EDIMessageFormat.php:224 EDIMessageFormat.php:226 GLBalanceSheet.php:58 #: GLProfit_Loss.php:107 GLTagProfit_Loss.php:120 POReport.php:1507 -#: SalesInquiry.php:1069 Tax.php:241 +#: SalesInquiry.php:1069 Tax.php:433 msgid "Summary" msgstr "Sumario" @@ -14236,7 +14233,8 @@ msgid "Statement of Profit and Loss for the" msgstr "Estado de Ganancias y Pérdidas para el" -#: GLProfit_Loss.php:611 GLTagProfit_Loss.php:529 Tax.php:27 +#: GLProfit_Loss.php:611 GLTagProfit_Loss.php:529 Tax.php:25 +#: includes/PDFTaxPageHeader.inc:31 msgid "months to" msgstr "meses hasta" @@ -15972,16 +15970,15 @@ msgstr "Dos Semanas" #: InventoryPlanningPrefSupplier.php:511 InventoryPlanningPrefSupplier.php:513 -#: Tax.php:309 +#: Tax.php:342 msgid "One Month" msgstr "Un mes" #: InventoryPlanningPrefSupplier.php:516 InventoryPlanningPrefSupplier.php:518 msgid "Six Weeks" -msgstr "Seis Semanas" +msgstr "Seis semanas" #: InventoryPlanningPrefSupplier.php:521 InventoryPlanningPrefSupplier.php:523 -#: Tax.php:310 msgid "Two Months" msgstr "Dos meses" @@ -18400,7 +18397,8 @@ msgid "Customer transaction listing from" msgstr "Lista de transacciones de cliente de" -#: PDFCustTransListing.php:137 PDFSuppTransListing.php:131 index.php:94 +#: PDFCustTransListing.php:137 PDFSuppTransListing.php:131 Tax.php:246 +#: index.php:94 msgid "Transactions" msgstr "Transacciones" @@ -19037,7 +19035,7 @@ msgid "Price list by inventory category" msgstr "" -#: PDFPriceList.php:37 PDFPriceList.php:329 PDFPriceList.php:377 +#: PDFPriceList.php:37 PDFPriceList.php:329 PDFPriceList.php:378 msgid "Customer Special Prices Only" msgstr "Solamente Precios Especiales para clientes" @@ -19134,21 +19132,21 @@ msgid "Full Description" msgstr "Descripción completa" -#: PDFPriceList.php:334 PDFPriceList.php:388 PDFPrintLabel.php:345 +#: PDFPriceList.php:334 PDFPriceList.php:389 PDFPrintLabel.php:345 msgid "Effective As At" msgstr "Efectivo al" -#: PDFPriceList.php:387 StockClone.php:1087 Stocks.php:1397 Stocks.php:1404 +#: PDFPriceList.php:388 StockClone.php:1087 Stocks.php:1397 Stocks.php:1404 #: ../webSHOP/includes/Functions.php:127 #: ../webSHOP/includes/ShowSalesCategoriesMenu.php:15 msgid "Categories" msgstr "Categorías" -#: PDFPriceList.php:411 +#: PDFPriceList.php:412 msgid "Effective Date Range" msgstr "Rango de fechas efectivas" -#: PDFPriceList.php:431 +#: PDFPriceList.php:432 msgid "Prices excluding tax" msgstr "Precios sin impuesto" @@ -24503,7 +24501,7 @@ #: ReverseGRN.php:31 SalesByTypePeriodInquiry.php:356 #: SalesTopCustomersInquiry.php:218 SalesTopItemsInquiry.php:225 -#: SelectSalesOrder.php:403 includes/MainMenuLinksArray.php:22 +#: SelectSalesOrder.php:403 Tax.php:256 includes/MainMenuLinksArray.php:22 msgid "Sales" msgstr "Ventas" @@ -32259,9 +32257,8 @@ "confirmar los cambios a la base de datos porque" #: SuppPaymentRun.php:240 SupplierTypes.php:6 SupplierTypes.php:21 -#: SystemParameters.php:13 Tax.php:290 TaxAuthorities.php:10 -#: TaxAuthorityRates.php:16 TaxCategories.php:10 -#: includes/MainMenuLinksArray.php:477 +#: SystemParameters.php:13 TaxAuthorities.php:10 TaxAuthorityRates.php:16 +#: TaxCategories.php:10 includes/MainMenuLinksArray.php:477 msgid "Supplier Types" msgstr "Tipos de Proveedor" @@ -35582,27 +35579,23 @@ "si escoge Sí en esta selección, puede utilizar el conjunto de SMTP en la " "sección de configuración." -#: Tax.php:17 +#: Tax.php:14 msgid "Could not determine the last date of the period selected" msgstr "No se puede determinar la última fecha del período seleccionado" -#: Tax.php:17 +#: Tax.php:14 msgid "The sql returned the following error" msgstr "El SQL devolvió el siguiente error" -#: Tax.php:26 -msgid "Taxation Report" -msgstr "Informe de Fiscalidad" +#: Tax.php:24 Tax.php:324 includes/PDFTaxPageHeader.inc:25 +msgid "Tax Report" +msgstr "" -#: Tax.php:27 -msgid "Tax Report for" -msgstr "Informe Fiscal de" - -#: Tax.php:61 Tax.php:166 Tax.php:275 +#: Tax.php:54 Tax.php:168 Tax.php:307 msgid "Taxation Reporting Error" msgstr "Error en el Informe de Fiscalidad" -#: Tax.php:63 +#: Tax.php:56 msgid "" "The accounts receivable transaction details could not be retrieved because" msgstr "" @@ -35613,37 +35606,38 @@ msgid "Tax On Sales" msgstr "Impuesto en ventas" -#: Tax.php:116 +#: Tax.php:107 msgid "Total Outputs" msgstr "Egresos Totales" -#: Tax.php:168 +#: Tax.php:170 msgid "The accounts payable transaction details could not be retrieved because" msgstr "" "No se pudieron obtener los detalles de la transacción en cuentas a pagar " "porque" -#: Tax.php:179 Tax.php:266 +#: Tax.php:186 msgid "Tax On Purchases" msgstr "Impuestos en compras" -#: Tax.php:215 +#: Tax.php:220 msgid "Total Inputs" msgstr "Ingresos Totales" -#: Tax.php:253 -msgid "Return Suggested Entries" -msgstr "Volver a los Comentarios Sugeridos" +#: Tax.php:269 includes/MainMenuLinksArray.php:24 +#: reportwriter/languages/en_US/reports.php:241 +#: ../webSHOP/CreditCardPayPalPro.php:90 +#: ../webSHOP/includes/ProcessPayPalPayment.php:8 +#: ../webSHOP/includes/ProcessPayPalPayment.php:10 +#: ../webSHOP/includes/ProcessPayPalPayment.php:45 +msgid "Purchases" +msgstr "Compras" -#: Tax.php:256 -msgid "Total Sales and Income (incl Tax)" -msgstr "Ventas Totales e Ingresos (impuestos incluidos)" +#: Tax.php:285 Z_CheckDebtorsControl.php:77 Z_CheckGLTransBalance.php:14 +msgid "Difference" +msgstr "Diferencia" -#: Tax.php:261 -msgid "Tax On Liable Sales" -msgstr "Impuestos sobre las Ventas Comprometidas" - -#: Tax.php:270 +#: Tax.php:299 msgid "" "Adjustments for Tax paid to Customs, FBT, entertainments etc must also be " "entered" @@ -35651,7 +35645,7 @@ "Deben introducirse los ajustes para los Impuestos pagados a Aduanas. " "entretenimientos, etc." -#: Tax.php:272 +#: Tax.php:302 msgid "" "This information excludes Tax on journal entries/payments/receipts all Tax " "should be entered through AR/AP" @@ -35659,47 +35653,63 @@ "Esta información excluye Impuestos en asientos/pagos/ingresos del diario. " "Todos los Impuestos deberían ser entrados a través de Cuentas a Cobrar/Pagar" -#: Tax.php:277 +#: Tax.php:309 msgid "There are no tax entries to list" msgstr "No hay entradas de impuesto a la lista" -#: Tax.php:287 +#: Tax.php:319 Tax.php:324 msgid "Tax Reporting" msgstr "Informe impositivo" -#: Tax.php:298 +#: Tax.php:331 msgid "Tax Authority To Report On:" msgstr "Declarar a la Autoridad Fiscal:" -#: Tax.php:307 +#: Tax.php:340 msgid "Return Covering" msgstr "Regresar Cubierta" -#: Tax.php:311 -msgid "Quarter" -msgstr "Tres meses" +#: Tax.php:343 +msgid "2 Months" +msgstr "2 meses" -#: Tax.php:312 -msgid "Six Months" -msgstr "Seis meses" +#: Tax.php:344 +msgid "3 Months" +msgstr "3 meses" -#: Tax.php:318 +#: Tax.php:345 +msgid "6 Months" +msgstr "6 meses" + +#: Tax.php:346 +msgid "12 Months" +msgstr "12 meses" + +#: Tax.php:347 +msgid "24 Months" +msgstr "24 meses" + +#: Tax.php:348 +msgid "48 Months" +msgstr "48 meses" + +#: Tax.php:353 msgid "Return To" msgstr "Regresar A" -#: Tax.php:327 +#: Tax.php:362 msgid "Could not retrieve the period data because" msgstr "No se puede obtener el período de fechas porque" -#: Tax.php:342 +#: Tax.php:376 msgid "Detail Or Summary Only" msgstr "Detalle ó Sumario" -#: Tax.php:344 +#: Tax.php:378 msgid "Detail and Summary" msgstr "Detalle y Resumen" -#: Tax.php:345 +#: Tax.php:379 msgid "Summary Only" msgstr "Sólo Sumario" @@ -39060,10 +39070,6 @@ msgid "Calculated" msgstr "Calculado" -#: Z_CheckDebtorsControl.php:77 Z_CheckGLTransBalance.php:14 -msgid "Difference" -msgstr "Diferencia" - #: Z_CheckGLTransBalance.php:5 msgid "Check Period Sales Ledger Control Account" msgstr "Verifique la Cuenta Control Ventas" @@ -47253,15 +47259,6 @@ msgid "Login" msgstr "Ingresar" -#: includes/MainMenuLinksArray.php:24 -#: reportwriter/languages/en_US/reports.php:241 -#: ../webSHOP/CreditCardPayPalPro.php:90 -#: ../webSHOP/includes/ProcessPayPalPayment.php:8 -#: ../webSHOP/includes/ProcessPayPalPayment.php:10 -#: ../webSHOP/includes/ProcessPayPalPayment.php:45 -msgid "Purchases" -msgstr "Compras" - #: includes/MainMenuLinksArray.php:34 msgid "New Sales Order or Quotation" msgstr "Nueva orden de venta o cotización" @@ -50530,12 +50527,3 @@ #: ../webSHOP/includes/session.php:137 msgid "Bank Transfer" msgstr "" - -#~ msgid "Prices for Categories" -#~ msgstr "Precios por Categorías" - -#~ msgid "Prices For Categories" -#~ msgstr "Precios por categorías" - -#~ msgid "Maintenance Of Location Authorised Users" -#~ msgstr "Mantenimiento de usuarios autorizados por ubicación" Modified: trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po 2014-08-27 03:14:38 UTC (rev 6846) +++ trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po 2014-08-28 05:26:07 UTC (rev 6847) @@ -8,8 +8,8 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-18 13:21-0600\n" -"PO-Revision-Date: 2014-08-18 13:55-0600\n" +"POT-Creation-Date: 2014-08-27 22:51-0600\n" +"PO-Revision-Date: 2014-08-27 22:58-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: French <none>\n" "Language: fr_FR\n" @@ -412,7 +412,6 @@ #: SystemParameters.php:1123 SystemParameters.php:1127 TaxGroups.php:312 #: TaxGroups.php:315 TaxGroups.php:373 WWW_Users.php:504 WWW_Users.php:508 #: WWW_Users.php:677 WWW_Users.php:681 includes/PDFLowGPPageHeader.inc:44 -#: includes/PDFTaxPageHeader.inc:35 #: reportwriter/languages/en_US/reports.php:82 msgid "No" msgstr "Non" @@ -692,9 +691,8 @@ #: CustomerBranches.php:408 Customers.php:1119 Customers.php:1127 #: ImportBankTransAnalysis.php:207 SalesPeople.php:200 SelectCustomer.php:609 #: StockDispatch.php:275 StockDispatch.php:286 StockDispatch.php:297 -#: SuppTransGLAnalysis.php:108 SupplierContacts.php:152 -#: includes/PDFTaxPageHeader.inc:37 includes/InputSerialItemsFile.php:92 -#: includes/InputSerialItemsFile.php:144 +#: SuppTransGLAnalysis.php:108 SupplierContacts.php:152 Tax.php:411 +#: includes/InputSerialItemsFile.php:92 includes/InputSerialItemsFile.php:144 msgid "Name" msgstr "Nom" @@ -815,11 +813,10 @@ #: StockDispatch.php:299 StockLocMovements.php:92 StockMovements.php:99 #: StockSerialItemResearch.php:82 SupplierAllocations.php:456 #: SupplierAllocations.php:569 SupplierAllocations.php:644 -#: SupplierInquiry.php:209 SupplierTransInquiry.php:105 +#: SupplierInquiry.php:209 SupplierTransInquiry.php:105 Tax.php:408 #: includes/PDFQuotationPageHeader.inc:23 #: includes/PDFQuotationPortraitPageHeader.inc:80 -#: includes/PDFStatementPageHeader.inc:169 includes/PDFTaxPageHeader.inc:36 -#: includes/PDFTransPageHeader.inc:51 +#: includes/PDFStatementPageHeader.inc:169 includes/PDFTransPageHeader.inc:51 #: includes/PDFTransPageHeaderPortrait.inc:63 #: reportwriter/languages/en_US/reports.php:64 msgid "Date" @@ -1039,7 +1036,7 @@ #: SuppContractChgs.php:107 SuppFixedAssetChgs.php:97 SuppShiptChgs.php:97 #: SuppTransGLAnalysis.php:139 SupplierAllocations.php:458 #: SupplierAllocations.php:570 SupplierAllocations.php:645 -#: SupplierCredit.php:407 SupplierInquiry.php:214 +#: SupplierCredit.php:407 SupplierInquiry.php:214 Tax.php:250 #: Z_CheckDebtorsControl.php:149 api/api_debtortransactions.php:1271 #: api/api_debtortransactions.php:1284 api/api_debtortransactions.php:1581 #: includes/PDFQuotationP... [truncated message content] |
From: <rc...@us...> - 2014-08-28 15:24:38
|
Revision: 6849 http://sourceforge.net/p/web-erp/reponame/6849 Author: rchacon Date: 2014-08-28 15:24:35 +0000 (Thu, 28 Aug 2014) Log Message: ----------- In Tax.php: Fixes SQL select order-by from transaction-date to record-number (primary key). Minor improvements. Modified Paths: -------------- trunk/Tax.php trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po Modified: trunk/Tax.php =================================================================== --- trunk/Tax.php 2014-08-28 15:15:31 UTC (rev 6848) +++ trunk/Tax.php 2014-08-28 15:24:35 UTC (rev 6849) @@ -18,11 +18,11 @@ $result = DB_query("SELECT description FROM taxauthorities WHERE taxid='" . $_POST['TaxAuthority'] . "'",$db); $TaxAuthDescription = DB_fetch_row($result); - $TaxAuthorityName = $TaxAuthDescription[0]; + $TaxAuthorityName = $TaxAuthDescription[0]; include('includes/PDFStarter.php'); $pdf->addInfo('Title', _('Tax Report') . ': ' . $TaxAuthorityName); - $pdf->addInfo('Subject', $_POST['NoOfPeriods'] . ' ' . _('months to') . ' ' . $PeriodEnd); + $pdf->addInfo('Subject', $_POST['NoOfPeriods'] . ' ' . _('months to') . ' ' . $PeriodEnd); /*Now get the invoices for the tax report */ /* The amounts of taxes are inserted into debtortranstaxes.taxamount in @@ -42,11 +42,11 @@ INNER JOIN debtorsmaster ON debtortrans.debtorno=debtorsmaster.debtorno INNER JOIN systypes ON debtortrans.type=systypes.typeid INNER JOIN debtortranstaxes ON debtortrans.id = debtortranstaxes.debtortransid - WHERE debtortrans.prd >= '" .($_POST['ToPeriod'] - $_POST['NoOfPeriods'] + 1) . "' + WHERE debtortrans.prd >= '" . ($_POST['ToPeriod'] - $_POST['NoOfPeriods'] + 1) . "' AND debtortrans.prd <= '" . $_POST['ToPeriod'] . "' AND (debtortrans.type=10 OR debtortrans.type=11) AND debtortranstaxes.taxauthid = '" . $_POST['TaxAuthority'] . "' - ORDER BY debtortrans.trandate";// RChacon: ORDER BY debtortrans.recno ? + ORDER BY debtortrans.id";// Order by debtortrans record number (primary key). $DebtorTransResult = DB_query($SQL,$db,'','',false,false); //don't trap errors in DB_query @@ -62,7 +62,7 @@ exit; } - $SalesCount = 0; + $SalesCount = 0; $SalesNet = 0; $SalesTax = 0; if($_POST['DetailOrSummary']=='Detail') { @@ -90,7 +90,7 @@ include('includes/PDFTaxPageHeader.inc'); PageHeaderDetail(); } - $SalesCount ++;// Counts sales transactions. + $SalesCount ++;// Counts sales transactions. $SalesNet += $DebtorTransRow['netamount'];// Accumulates sales net. $SalesTax += $DebtorTransRow['tax'];// Accumulates sales tax. } /*end listing while loop */ @@ -115,7 +115,7 @@ } else { while($DebtorTransRow = DB_fetch_array($DebtorTransResult,$db)) { - $SalesCount ++;// Counts sales transactions. + $SalesCount ++;// Counts sales transactions. $SalesNet += $DebtorTransRow['netamount'];// Accumulates sales net. $SalesTax += $DebtorTransRow['tax'];// Accumulates sales tax. } /*end listing while loop */ @@ -150,7 +150,7 @@ supptrans.transno, suppliers.suppname, supptrans.suppreference, - supptrans.ovamount/supptrans.rate AS netamount, + supptrans.ovamount/supptrans.rate AS netamount, supptranstaxes.taxamount/supptrans.rate AS taxamt FROM supptrans INNER JOIN suppliers ON supptrans.supplierno=suppliers.supplierid @@ -160,7 +160,7 @@ AND supptrans.trandate <= '" . FormatDateForSQL($PeriodEnd) . "' AND (supptrans.type=20 OR supptrans.type=21) AND supptranstaxes.taxauthid = '" . $_POST['TaxAuthority'] . "' - ORDER BY supptrans.trandate";// ORDER BY supptrans.recno ? + ORDER BY supptrans.id";// Order by supptrans record number (primary key). $SuppTransResult = DB_query($SQL,$db,'','',false,false); //doint trap errors in DB_query @@ -176,7 +176,7 @@ exit; } - $PurchasesCount = 0; + $PurchasesCount = 0; $PurchasesNet = 0; $PurchasesTax = 0; if($_POST['DetailOrSummary']=='Detail') { @@ -203,7 +203,7 @@ include('includes/PDFTaxPageHeader.inc'); PageHeaderDetail(); } - $PurchasesCount ++;// Counts purchases transactions. + $PurchasesCount ++;// Counts purchases transactions. $PurchasesNet += $SuppTransRow['netamount'];// Accumulates purchases net. $PurchasesTax += $SuppTransRow['taxamt'];// Accumulates purchases tax. } /*end listing while loop */ @@ -228,7 +228,7 @@ } else { while($SuppTransRow = DB_fetch_array($SuppTransResult,$db)) { - $PurchasesCount ++;// Counts purchases transactions. + $PurchasesCount ++;// Counts purchases transactions. $PurchasesNet += $SuppTransRow['netamount'];// Accumulates purchases net. $PurchasesTax += $SuppTransRow['taxamt'];// Accumulates purchases tax. } /*end listing while loop */ @@ -296,24 +296,24 @@ $YPos -= $FontSize*4;// Jumps additional lines. - $pdf->addText($Left_Margin, $YPos, $FontSize, _('Adjustments for Tax paid to Customs, FBT, entertainments etc must also be entered')); + $pdf->addText($Left_Margin, $YPos, $FontSize, _('Adjustments for tax paid to Customs, FBT, entertainments, etc. must also be entered.')); $YPos -= $FontSize; $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos-$FontSize, $Page_Width-$Left_Margin-$Right_Margin, $FontSize, - _('This information excludes Tax on journal entries/payments/receipts all Tax should be entered through AR/AP')); + _('This information excludes tax on journal entries/payments/receipts. All tax should be entered through AR/AP.')); $YPos -= $FontSize; $LeftOvers = $pdf->addTextWrap($Left_Margin, $YPos-$FontSize, $Page_Width-$Left_Margin-$Right_Margin, $FontSize, $LeftOvers); - if($SalesCount+$PurchasesCount == 0) { + if($SalesCount+$PurchasesCount == 0) { $Title = _('Taxation Reporting Error'); include('includes/header.inc'); prnMsg(_('There are no tax entries to list'),'info'); echo '<br /><a href="' . $RootPath . '/index.php">' . _('Back to the menu') . '</a>'; include('includes/footer.inc'); exit; - } else { - $pdf->OutputD($_SESSION['DatabaseName'] . '_Tax_Report_' . Date('Y-m-d')); - } - $pdf->__destruct(); + } else { + $pdf->OutputD($_SESSION['DatabaseName'] . '_Tax_Report_' . Date('Y-m-d')); + } + $pdf->__destruct(); } else { /*The option to print PDF was not hit */ $Title =_('Tax Reporting'); @@ -324,11 +324,11 @@ _('Tax Report') . '" />' . ' ' . _('Tax Reporting') . '</p>'; echo '<form action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post">'; - echo '<div>'; - echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; + echo '<div>'; + echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; echo '<table class="selection">'; - echo '<tr><td>' . _('Tax Authority To Report On:') . ':</td> + echo '<tr><td>' . _('Tax Authority To Report On') . ':</td> <td><select name="TaxAuthority">'; $result = DB_query("SELECT taxid, description FROM taxauthorities",$db); @@ -340,12 +340,12 @@ <td>' . _('Return Covering') . ':</td> <td><select name="NoOfPeriods">' . '<option selected="selected" value="1">' . _('One Month') . '</option>' . - '<option value="2">' . _('2 Months') . '</option>' . + '<option value="2">' . _('2 Months') . '</option>' . '<option value="3">' . _('3 Months') . '</option>' . - '<option value="6">' . _('6 Months') . '</option>' . - '<option value="12">' . _('12 Months') . '</option>' . - '<option value="24">' . _('24 Months') . '</option>' . - '<option value="48">' . _('48 Months') . '</option>' . + '<option value="6">' . _('6 Months') . '</option>' . + '<option value="12">' . _('12 Months') . '</option>' . + '<option value="24">' . _('24 Months') . '</option>' . + '<option value="48">' . _('48 Months') . '</option>' . '</select></td> </tr>'; @@ -384,7 +384,7 @@ <div class="centre"> <input type="submit" name="PrintPDF" value="' . _('Print PDF') . '" /> </div> - </div> + </div> </form>'; include('includes/footer.inc'); Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-28 15:15:31 UTC (rev 6848) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-28 15:24:35 UTC (rev 6849) @@ -7,8 +7,8 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-27 22:51-0600\n" -"PO-Revision-Date: 2014-08-27 22:55-0600\n" +"POT-Creation-Date: 2014-08-28 08:46-0600\n" +"PO-Revision-Date: 2014-08-28 09:16-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -11244,7 +11244,7 @@ #: GLProfit_Loss.php:107 GLTagProfit_Loss.php:120 POReport.php:1507 #: SalesInquiry.php:1069 Tax.php:433 msgid "Summary" -msgstr "Sumario" +msgstr "Resumen" #: EDIMessageFormat.php:240 msgid "Line Text" @@ -13785,7 +13785,7 @@ #: GLBalanceSheet.php:56 GLProfit_Loss.php:105 GLTagProfit_Loss.php:118 msgid "Detail Or Summary" -msgstr "Detalle ó Sumario" +msgstr "Detalle o resumen" #: GLBalanceSheet.php:57 msgid "Selecting Summary will show on the totals at the account group level" @@ -35589,7 +35589,7 @@ #: Tax.php:24 Tax.php:324 includes/PDFTaxPageHeader.inc:25 msgid "Tax Report" -msgstr "" +msgstr "Informe de impuestos" #: Tax.php:54 Tax.php:168 Tax.php:307 msgid "Taxation Reporting Error" @@ -35608,7 +35608,7 @@ #: Tax.php:107 msgid "Total Outputs" -msgstr "Egresos Totales" +msgstr "Egresos totales" #: Tax.php:170 msgid "The accounts payable transaction details could not be retrieved because" @@ -35622,7 +35622,7 @@ #: Tax.php:220 msgid "Total Inputs" -msgstr "Ingresos Totales" +msgstr "Ingresos totales" #: Tax.php:269 includes/MainMenuLinksArray.php:24 #: reportwriter/languages/en_US/reports.php:241 @@ -35639,19 +35639,19 @@ #: Tax.php:299 msgid "" -"Adjustments for Tax paid to Customs, FBT, entertainments etc must also be " -"entered" +"Adjustments for tax paid to Customs, FBT, entertainments, etc. must also be " +"entered." msgstr "" -"Deben introducirse los ajustes para los Impuestos pagados a Aduanas. " -"entretenimientos, etc." +"Ajustes por impuestos pagados a la Aduana, FBT, entretenimientos, etc. " +"también se deben introducir." #: Tax.php:302 msgid "" -"This information excludes Tax on journal entries/payments/receipts all Tax " -"should be entered through AR/AP" +"This information excludes tax on journal entries/payments/receipts. All tax " +"should be entered through AR/AP." msgstr "" -"Esta información excluye Impuestos en asientos/pagos/ingresos del diario. " -"Todos los Impuestos deberían ser entrados a través de Cuentas a Cobrar/Pagar" +"Esta información excluye impuesto sobre entradas/pagos/recibos de Diarios. " +"Todo impuesto debe ser introducido mediante CxC/CxP." #: Tax.php:309 msgid "There are no tax entries to list" @@ -35662,12 +35662,12 @@ msgstr "Informe impositivo" #: Tax.php:331 -msgid "Tax Authority To Report On:" -msgstr "Declarar a la Autoridad Fiscal:" +msgid "Tax Authority To Report On" +msgstr "Declarar a la Autoridad Fiscal" #: Tax.php:340 msgid "Return Covering" -msgstr "Regresar Cubierta" +msgstr "Período" #: Tax.php:343 msgid "2 Months" @@ -35695,7 +35695,7 @@ #: Tax.php:353 msgid "Return To" -msgstr "Regresar A" +msgstr "Corte al" #: Tax.php:362 msgid "Could not retrieve the period data because" @@ -35703,15 +35703,15 @@ #: Tax.php:376 msgid "Detail Or Summary Only" -msgstr "Detalle ó Sumario" +msgstr "Solo detalle o resumen" #: Tax.php:378 msgid "Detail and Summary" -msgstr "Detalle y Resumen" +msgstr "Detalle y resumen" #: Tax.php:379 msgid "Summary Only" -msgstr "Sólo Sumario" +msgstr "Sólo resumen" #: TaxAuthorities.php:6 TaxAuthorityRates.php:134 msgid "Tax Authorities" @@ -35805,11 +35805,11 @@ #: TaxAuthorities.php:310 msgid "Bank Name" -msgstr "Nombre del Banco" +msgstr "Nombre del banco" #: TaxAuthorities.php:311 msgid "Not more than 40 chacraters" -msgstr "" +msgstr "No más de 40 caracteres" #: TaxAuthorities.php:314 msgid "Bank Account Type" @@ -35817,7 +35817,7 @@ #: TaxAuthorities.php:315 TaxAuthorities.php:319 msgid "No more than 20 characters" -msgstr "" +msgstr "No más de 20caracteres" #: TaxAuthorities.php:322 msgid "Bank Swift No" @@ -35825,7 +35825,7 @@ #: TaxAuthorities.php:323 msgid "No more than 15 characters" -msgstr "" +msgstr "No más de 15 caracteres" #: TaxAuthorityRates.php:12 msgid "Tax Rates" @@ -35866,7 +35866,7 @@ #: TaxAuthorityRates.php:112 #, php-format msgid "Input must be numeric" -msgstr "" +msgstr "La cantidad debe ser numérica" #: TaxAuthorityRates.php:126 msgid "Update Rates" @@ -50527,3 +50527,20 @@ #: ../webSHOP/includes/session.php:137 msgid "Bank Transfer" msgstr "" + +#~ msgid "Tax Authority To Report On:" +#~ msgstr "Declarar a la Autoridad Fiscal" + +#~ msgid "" +#~ "Adjustments for Tax paid to Customs, FBT, entertainments etc must also be " +#~ "entered" +#~ msgstr "" +#~ "Ajustes por impuestos pagados a la Aduana, FBT, entretenimientos, etc " +#~ "también se deben introducir" + +#~ msgid "" +#~ "This information excludes Tax on journal entries/payments/receipts all " +#~ "Tax should be entered through AR/AP" +#~ msgstr "" +#~ "Esta información excluye impuesto sobre entradas/pagos/recibos de " +#~ "Diarios. Todo impuesto debe ser introducido mediante CxC/CxP." Modified: trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po 2014-08-28 15:15:31 UTC (rev 6848) +++ trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po 2014-08-28 15:24:35 UTC (rev 6849) @@ -8,8 +8,8 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-27 22:51-0600\n" -"PO-Revision-Date: 2014-08-27 22:58-0600\n" +"POT-Creation-Date: 2014-08-28 08:46-0600\n" +"PO-Revision-Date: 2014-08-28 08:50-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: French <none>\n" "Language: fr_FR\n" @@ -34829,23 +34829,23 @@ #: SystemParameters.php:372 msgid "d/m/Y" -msgstr "" +msgstr "j/m/A" #: SystemParameters.php:373 msgid "d.m.Y" -msgstr "" +msgstr "j.m.A" #: SystemParameters.php:374 msgid "m/d/Y" -msgstr "" +msgstr "m/j/A" #: SystemParameters.php:375 msgid "Y/m/d" -msgstr "" +msgstr "A/m/j" #: SystemParameters.php:376 msgid "Y-m-d" -msgstr "" +msgstr "A-m-j" # JDN #: SystemParameters.php:378 @@ -34990,15 +34990,13 @@ msgid "Order Entry allows Line Item Narrative" msgstr "Autoriser les commentaires" -# JDN #: SystemParameters.php:441 msgid "Allow Narrative Entry" -msgstr "Oui" +msgstr "Autoriser l'entrée Narrative" -# JDN #: SystemParameters.php:442 msgid "No Narrative Line" -msgstr "Non" +msgstr "Pas de ligne narrative" # JDN #: SystemParameters.php:444 @@ -35057,7 +35055,7 @@ #: SystemParameters.php:485 msgid "Google" -msgstr "" +msgstr "Google" #: SystemParameters.php:487 msgid "Specify the source to use for exchange rates" @@ -36013,7 +36011,7 @@ #: Tax.php:24 Tax.php:324 includes/PDFTaxPageHeader.inc:25 msgid "Tax Report" -msgstr "" +msgstr "Rapport d'impôts" #: Tax.php:54 Tax.php:168 Tax.php:307 msgid "Taxation Reporting Error" @@ -36059,16 +36057,16 @@ #: Tax.php:299 msgid "" -"Adjustments for Tax paid to Customs, FBT, entertainments etc must also be " -"entered" +"Adjustments for tax paid to Customs, FBT, entertainments, etc. must also be " +"entered." msgstr "" "Ajustements de la taxe payée à la douane, FBT, etc divertissements doivent " "aussi être indiqués" #: Tax.php:302 msgid "" -"This information excludes Tax on journal entries/payments/receipts all Tax " -"should be entered through AR/AP" +"This information excludes tax on journal entries/payments/receipts. All tax " +"should be entered through AR/AP." msgstr "" "Cette information ne comprend pas la taxe sur les entrées du journal / " "paiements / recettes fiscales devraient tous être entré par AR / AP" @@ -36082,12 +36080,12 @@ msgstr "Rapport T.V.A." #: Tax.php:331 -msgid "Tax Authority To Report On:" -msgstr "Administration fiscale à formuler sur:" +msgid "Tax Authority To Report On" +msgstr "Administration fiscale à formuler sur" #: Tax.php:340 msgid "Return Covering" -msgstr "" +msgstr "Retour Couvrant" #: Tax.php:343 msgid "2 Months" @@ -36183,11 +36181,11 @@ #: TaxAuthorities.php:148 msgid "Input Tax" -msgstr "Taxe" +msgstr "Taxes reçues" #: TaxAuthorities.php:149 msgid "Output Tax" -msgstr "" +msgstr "Taxes payées" #: TaxAuthorities.php:152 msgid "Bank Act Type" @@ -50928,3 +50926,20 @@ #: ../webSHOP/includes/session.php:137 msgid "Bank Transfer" msgstr "" + +#~ msgid "Tax Authority To Report On:" +#~ msgstr "Administration fiscale à formuler sur:" + +#~ msgid "" +#~ "Adjustments for Tax paid to Customs, FBT, entertainments etc must also be " +#~ "entered" +#~ msgstr "" +#~ "Ajustements de la taxe payée à la douane, FBT, etc divertissements " +#~ "doivent aussi être indiqués" + +#~ msgid "" +#~ "This information excludes Tax on journal entries/payments/receipts all " +#~ "Tax should be entered through AR/AP" +#~ msgstr "" +#~ "Cette information ne comprend pas la taxe sur les entrées du journal / " +#~ "paiements / recettes fiscales devraient tous être entré par AR / AP" |
From: <rc...@us...> - 2014-08-29 20:42:02
|
Revision: 6855 http://sourceforge.net/p/web-erp/reponame/6855 Author: rchacon Date: 2014-08-29 20:41:58 +0000 (Fri, 29 Aug 2014) Log Message: ----------- In TaxAuthorityRates.php and TaxCategories.php: adds $ViewTopic and $BookMark; Uses gettext() to translate 'Exempt', 'Freight' and 'Handling'. Minor improvements. Modified Paths: -------------- trunk/TaxAuthorityRates.php trunk/TaxCategories.php trunk/doc/Change.log trunk/includes/DatabaseTranslations.php trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po Modified: trunk/TaxAuthorityRates.php =================================================================== --- trunk/TaxAuthorityRates.php 2014-08-29 07:15:02 UTC (rev 6854) +++ trunk/TaxAuthorityRates.php 2014-08-29 20:41:58 UTC (rev 6855) @@ -1,32 +1,33 @@ <?php /* $Id$*/ -if (isset($_POST['TaxAuthority'])){ +include('includes/session.inc'); +$Title = _('Tax Rates'); +$ViewTopic = 'Tax';// Filename in ManualContents.php's TOC. +$BookMark = 'TaxAuthorityRates';// Anchor's id in the manual's html document. +include('includes/header.inc'); +echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . + '/images/maintenance.png" title="' . + _('Tax Rates') . '" />' . ' ' . + _('Tax Rates') . '</p>'; + +if(isset($_POST['TaxAuthority'])) { $TaxAuthority = $_POST['TaxAuthority']; } -if (isset($_GET['TaxAuthority'])){ +if(isset($_GET['TaxAuthority'])) { $TaxAuthority = $_GET['TaxAuthority']; } -include('includes/session.inc'); -$Title = _('Tax Rates'); -include('includes/header.inc'); - -echo '<p class="page_title_text"> - <img src="'.$RootPath.'/css/'.$Theme.'/images/maintenance.png" title="' . _('Supplier Types') - . '" alt="" />' . $Title. ' - </p>'; - - -if (!isset($TaxAuthority)){ - prnMsg(_('This page can only be called after selecting the tax authority to edit the rates for') . '. ' . _('Please select the Rates link from the tax authority page') . '<br /><a href="' . $RootPath . '/TaxAuthorities.php">' . _('click here') . '</a> ' . _('to go to the Tax Authority page'),'error'); +if(!isset($TaxAuthority)) { + prnMsg(_('This page can only be called after selecting the tax authority to edit the rates for') . '. ' . + _('Please select the Rates link from the tax authority page') . '<br /><a href="' . + $RootPath . '/TaxAuthorities.php">' . _('click here') . '</a> ' . + _('to go to the Tax Authority page'), 'error'); include ('includes/footer.inc'); exit; } - -if (isset($_POST['UpdateRates'])){ - +if(isset($_POST['UpdateRates'])) { $TaxRatesResult = DB_query("SELECT taxauthrates.taxcatid, taxauthrates.taxrate, taxauthrates.dispatchtaxprovince @@ -34,7 +35,7 @@ WHERE taxauthrates.taxauthority='" . $TaxAuthority . "'", $db); - while ($myrow=DB_fetch_array($TaxRatesResult)){ + while($myrow=DB_fetch_array($TaxRatesResult)) { $sql = "UPDATE taxauthrates SET taxrate=" . (filter_number_format($_POST[$myrow['dispatchtaxprovince'] . '_' . $myrow['taxcatid']])/100) . " WHERE taxcatid = '" . $myrow['taxcatid'] . "' @@ -45,11 +46,9 @@ prnMsg(_('All rates updated successfully'),'info'); } -/* end of update code -*/ +/* end of update code*/ -/*Display updated rates -*/ +/*Display updated rates*/ $TaxAuthDetail = DB_query("SELECT description FROM taxauthorities WHERE taxid='" . $TaxAuthority . "'",$db); @@ -58,7 +57,6 @@ echo '<form action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post">'; echo '<div>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - echo '<input type="hidden" name="TaxAuthority" value="' . $TaxAuthority . '" />'; $TaxRatesResult = DB_query("SELECT taxauthrates.taxcatid, @@ -77,71 +75,56 @@ taxauthrates.taxcatid", $db); -if (DB_num_rows($TaxRatesResult)>0){ +if(DB_num_rows($TaxRatesResult)>0) { + echo '<div class="centre"><h1>' . $myrow[0] . '</h1></div>';// TaxAuthorityRates table title. - echo '<table class="selection">'; - echo '<tr> - <th colspan="3"><h3>' . _('Update') . ' ' . $myrow[0] . ' ' . _('Rates') . '</h3></th> - </tr>'; - $TableHeader = '<tr> - <th class="ascending">' . _('Deliveries From') . '<br />' . _('Tax Province') . '</th> - <th class="ascending">' . _('Tax Category') . '</th> - <th class="ascending">' . _('Tax Rate') . ' %</th> - </tr>'; - echo $TableHeader; + echo '<table class="selection"><tr> + <th class="ascending">' . _('Deliveries From') . '<br />' . _('Tax Province') . '</th> + <th class="ascending">' . _('Tax Category') . '</th> + <th class="ascending">' . _('Tax Rate') . '</th></tr>'; $j = 1; - $k = 0; //row counter to determine background colour - $OldProvince=''; + $k = 0;// Row counter to determine background colour. - while ($myrow = DB_fetch_array($TaxRatesResult)){ - - if ($OldProvince!=$myrow['dispatchtaxprovince'] AND $OldProvince!=''){ - echo '<tr style="background-color:#555555"><td colspan="3"></td></tr>'; - } - - if ($k==1){ + while($myrow = DB_fetch_array($TaxRatesResult)) { + if($k==1) { echo '<tr class="EvenTableRows">'; - $k=0; + $k = 0; } else { echo '<tr class="OddTableRows">'; - $k=1; + $k = 1; } + printf(' + <td>%s</td> + <td>%s</td> + <td><input class="number" maxlength="5" name="%s" required="required" size="5" title="' . + _('Input must be numeric') . '" type="text" value="%s" /></td></tr>', + // Deliveries From: + $myrow['taxprovincename'], + // Tax Category: + _($myrow['taxcatname']),// Uses gettext() to translate 'Exempt', 'Freight' and 'Handling'. + // Tax Rate: + $myrow['dispatchtaxprovince'] . '_' . $myrow['taxcatid'], + locale_number_format($myrow['taxrate']*100,2)); + }// End of while loop. + echo '</table><br /><div class="centre"> + <input type="submit" name="UpdateRates" value="' . _('Update Rates') . '" />'; +//end if tax taxcatid/rates to show - printf('<td>%s</td> - <td>%s</td> - <td><input type="text" required="required" title="'._('Input must be numeric').'" class="number" name="%s" maxlength="5" size="5" value="%s" /></td> - </tr>', - $myrow['taxprovincename'], - $myrow['taxcatname'], - $myrow['dispatchtaxprovince'] . '_' . $myrow['taxcatid'], - locale_number_format($myrow['taxrate']*100,2)); +} else { + echo '<div class="centre">'; + prnMsg(_('There are no tax rates to show - perhaps the dispatch tax province records have not yet been created?'),'warn'); - $OldProvince = $myrow['dispatchtaxprovince']; - - } -//end of while loop -echo '</table>'; -echo '<br /> - <div class="centre"> - <input type="submit" name="UpdateRates" value="' . _('Update Rates') . '" />'; -} //end if tax taxcatid/rates to show - else { - prnMsg(_('There are no tax rates to show - perhaps the dispatch tax province records have not yet been created?'),'warn'); } -echo '<br /> - <br /> - <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Tax Authorities') . '</a> - <br /> - <a href="' . $RootPath . '/TaxGroups.php">' . _('Tax Groupings') . '</a> - <br /> - <a href="' . $RootPath . '/TaxCategories.php">' . _('Tax Categories') . '</a> - <br /> - <a href="' . $RootPath . '/TaxProvinces.php">' . _('Dispatch Tax Provinces') . '</a> - </div>'; +echo ' <br /> + <br /> + <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Tax Authorities') . '</a><br /> + <a href="' . $RootPath . '/TaxGroups.php">' . _('Tax Groupings') . '</a><br /> + <a href="' . $RootPath . '/TaxCategories.php">' . _('Tax Categories') . '</a><br /> + <a href="' . $RootPath . '/TaxProvinces.php">' . _('Dispatch Tax Provinces') . '</a> + </div> + </div> + </form>'; -echo '</div> - </form>'; - include( 'includes/footer.inc' ); ?> Modified: trunk/TaxCategories.php =================================================================== --- trunk/TaxCategories.php 2014-08-29 07:15:02 UTC (rev 6854) +++ trunk/TaxCategories.php 2014-08-29 20:41:58 UTC (rev 6855) @@ -2,20 +2,21 @@ /* $Id$*/ include('includes/session.inc'); - $Title = _('Tax Categories'); - +$ViewTopic = 'Tax';// Filename in ManualContents.php's TOC. +$BookMark = 'TaxCategories';// Anchor's id in the manual's html document. include('includes/header.inc'); +echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . + '/images/maintenance.png" title="' . + _('Tax Categories') . '" />' . ' ' . + _('Tax Categories') . '</p>'; -echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/maintenance.png" title="' . _('Supplier Types') - . '" alt="" />' . $Title. '</p>'; - -if ( isset($_GET['SelectedTaxCategory']) ) +if( isset($_GET['SelectedTaxCategory']) ) $SelectedTaxCategory = $_GET['SelectedTaxCategory']; -elseif (isset($_POST['SelectedTaxCategory'])) +elseif(isset($_POST['SelectedTaxCategory'])) $SelectedTaxCategory = $_POST['SelectedTaxCategory']; -if (isset($_POST['submit'])) { +if(isset($_POST['submit'])) { //initialise no input errors assumed initially before we test @@ -26,16 +27,16 @@ //first off validate inputs sensible - if (ContainsIllegalCharacters($_POST['TaxCategoryName'])) { + if(ContainsIllegalCharacters($_POST['TaxCategoryName'])) { $InputError = 1; prnMsg( _('The tax category name cannot contain the character') . " '&' " . _('or the character') ." ' " . _('or a space') ,'error'); } - if (trim($_POST['TaxCategoryName']) == '') { + if(trim($_POST['TaxCategoryName']) == '') { $InputError = 1; prnMsg( _('The tax category name may not be empty'), 'error'); } - if ($_POST['SelectedTaxCategory']!='' AND $InputError !=1) { + if($_POST['SelectedTaxCategory']!='' AND $InputError !=1) { /*SelectedTaxCategory could also exist if submit had not been clicked this code would not run in this case cos submit is false of course see the delete code below*/ // Check the name does not clash @@ -44,7 +45,7 @@ AND taxcatname ".LIKE." '" . $_POST['TaxCategoryName'] . "'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ( $myrow[0] > 0 ) { + if( $myrow[0] > 0 ) { $InputError = 1; prnMsg( _('The tax category cannot be renamed because another with the same name already exists.'),'error'); } else { @@ -53,7 +54,7 @@ $sql = "SELECT taxcatname FROM taxcategories WHERE taxcatid = '" . $SelectedTaxCategory . "'"; $result = DB_query($sql,$db); - if ( DB_num_rows($result) != 0 ) { + if( DB_num_rows($result) != 0 ) { // This is probably the safest way there is $myrow = DB_fetch_row($result); $OldTaxCategoryName = $myrow[0]; @@ -68,13 +69,13 @@ } } $msg = _('Tax category name changed'); - } elseif ($InputError !=1) { + } elseif($InputError !=1) { /*SelectedTaxCategory is null cos no item selected on first time round so must be adding a record*/ $sql = "SELECT count(*) FROM taxcategories WHERE taxcatname " .LIKE. " '".$_POST['TaxCategoryName'] ."'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ( $myrow[0] > 0 ) { + if( $myrow[0] > 0 ) { $InputError = 1; prnMsg( _('The tax category cannot be created because another with the same name already exists'),'error'); } else { @@ -103,21 +104,21 @@ $msg = _('New tax category added'); } - if ($InputError!=1){ + if($InputError!=1) { prnMsg($msg,'success'); } unset ($SelectedTaxCategory); unset ($_POST['SelectedTaxCategory']); unset ($_POST['TaxCategoryName']); -} elseif (isset($_GET['delete'])) { +} elseif(isset($_GET['delete'])) { //the link to delete a selected record was clicked instead of the submit button // PREVENT DELETES IF DEPENDENT RECORDS IN 'stockmaster' // Get the original name of the tax category the ID is just a secure way to find the tax category $sql = "SELECT taxcatname FROM taxcategories WHERE taxcatid = '" . $SelectedTaxCategory . "'"; $result = DB_query($sql,$db); - if ( DB_num_rows($result) == 0 ) { + if( DB_num_rows($result) == 0 ) { // This is probably the safest way there is prnMsg( _('Cannot delete this tax category because it no longer exists'),'warn'); } else { @@ -126,7 +127,7 @@ $sql= "SELECT COUNT(*) FROM stockmaster WHERE taxcatid = '" . $SelectedTaxCategory . "'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ($myrow[0]>0) { + if($myrow[0]>0) { prnMsg( _('Cannot delete this tax category because inventory items have been created using this tax category'),'warn'); echo '<br />' . _('There are') . ' ' . $myrow[0] . ' ' . _('inventory items that refer to this tax category') . '</font>'; } else { @@ -144,7 +145,7 @@ unset ($_POST['TaxCategoryName']); } - if (!isset($SelectedTaxCategory)) { + if(!isset($SelectedTaxCategory)) { /* An tax category could be posted when one has been edited and is being updated or GOT when selected for modification @@ -165,33 +166,37 @@ echo '<table class="selection"> <tr> <th class="ascending">' . _('Tax Categories') . '</th> + <th colspan="2">' . _('Maintenance') . '</th> </tr>'; - $k=0; //row colour counter - while ($myrow = DB_fetch_row($result)) { - - if ($k==1){ + $k = 0;// Row counter to determine background colour. + while($myrow = DB_fetch_row($result)) { + if($k==1) { echo '<tr class="EvenTableRows">'; - $k=0; + $k = 0; } else { echo '<tr class="OddTableRows">'; - $k++; + $k ++; } - if($myrow[1]!='Freight'){ - echo '<td>' . $myrow[1] . '</td> - <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxCategory=' . $myrow[0] . '">' . _('Edit') . '</a></td> - <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxCategory=' . $myrow[0] . '&delete=1" onclick="return confirm(\'' . _('Are you sure you wish to delete this tax category?') . '\');">' . _('Delete') . '</a></td> - </tr>'; - }else{ - echo '<td>' . $myrow[1] . '</td><td></td><td></td></tr>'; + if($myrow[1]!='Freight') { + // Uses gettext() to translate 'Exempt' and 'Handling': + echo '<td>' . _($myrow[1]) . '</td> + <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxCategory=' . $myrow[0] . '">' . + _('Edit') . '</a></td> + <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxCategory=' . $myrow[0] . + '&delete=1" onclick="return confirm(\'' . _('Are you sure you wish to delete this tax category?') . '\');">' . + _('Delete') . '</a></td>'; + } else { + echo '<td>' . _($myrow[1]) . '</td><td> </td><td> </td>';// Uses gettext() to translate 'Freight'. } + echo '</tr>'; + } //END WHILE LIST LOOP - } //END WHILE LIST LOOP echo '</table><br />'; } //end of ifs and buts! -if (isset($SelectedTaxCategory)) { +if(isset($SelectedTaxCategory)) { echo '<div class="centre"> <a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">' . _('Review Tax Categories') . '</a> </div>'; @@ -199,13 +204,13 @@ echo '<br />'; -if (! isset($_GET['delete'])) { +if(! isset($_GET['delete'])) { echo '<form method="post" action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">'; echo '<div>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - if (isset($SelectedTaxCategory)) { + if(isset($SelectedTaxCategory)) { //editing an existing section $sql = "SELECT taxcatid, @@ -214,7 +219,7 @@ WHERE taxcatid='" . $SelectedTaxCategory . "'"; $result = DB_query($sql, $db); - if ( DB_num_rows($result) == 0 ) { + if( DB_num_rows($result) == 0 ) { prnMsg( _('Could not retrieve the requested tax category, please try again.'),'warn'); unset($SelectedTaxCategory); } else { Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-29 07:15:02 UTC (rev 6854) +++ trunk/doc/Change.log 2014-08-29 20:41:58 UTC (rev 6855) @@ -1,4 +1,6 @@ webERP Change Log + +29/08/14 RChacon: In TaxAuthorityRates.php and TaxCategories.php: adds $ViewTopic and $BookMark; Uses gettext() to translate 'Exempt', 'Freight' and 'Handling'. 29/08/14 Exson: Fixed the StockLocStatus Serial Number link column shift problem. 28/08/14 RChacon: In Tax.php: Fixes SQL select order-by from transaction-date to record-number (primary key). Minor improvements. 28/08/14 Exson: Fixed the csv file aligned abnormal when there are commas in fields strings. Modified: trunk/includes/DatabaseTranslations.php =================================================================== --- trunk/includes/DatabaseTranslations.php 2014-08-29 07:15:02 UTC (rev 6854) +++ trunk/includes/DatabaseTranslations.php 2014-08-29 20:41:58 UTC (rev 6855) @@ -55,6 +55,11 @@ $systypes_typename[50] = _('Opening Balance'); $systypes_typename[500] = _('Auto Debtor Number'); +// taxcategories.taxcatname: +$taxcategories_taxcatname[4] = _('Exempt'); +$taxcategories_taxcatname[5] = _('Freight'); +$taxcategories_taxcatname[6] = _('Handling'); + // General purpose: $General_purpose = _('Default'); Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-29 07:15:02 UTC (rev 6854) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-29 20:41:58 UTC (rev 6855) @@ -7,8 +7,8 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-28 08:46-0600\n" -"PO-Revision-Date: 2014-08-28 09:16-0600\n" +"POT-Creation-Date: 2014-08-29 11:25-0600\n" +"PO-Revision-Date: 2014-08-29 11:35-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -911,7 +911,7 @@ msgstr "" #: AgedControlledInventory.php:12 InventoryQuantities.php:155 -#: InventoryValuation.php:230 Locations.php:394 Locations.php:455 MRP.php:530 +#: InventoryValuation.php:231 Locations.php:394 Locations.php:455 MRP.php:530 #: MRPCalendar.php:21 MRPCreateDemands.php:196 MRPDemandTypes.php:17 #: MRPDemands.php:27 MRPPlannedPurchaseOrders.php:265 #: MRPPlannedWorkOrders.php:247 MRPPlannedWorkOrders.php:321 @@ -1259,11 +1259,11 @@ msgid "Summary or detailed report" msgstr "Informe detallado o resumen" -#: AgedDebtors.php:519 AgedSuppliers.php:320 InventoryValuation.php:288 +#: AgedDebtors.php:519 AgedSuppliers.php:320 InventoryValuation.php:289 msgid "Summary Report" msgstr "Informe resumen" -#: AgedDebtors.php:520 AgedSuppliers.php:321 InventoryValuation.php:289 +#: AgedDebtors.php:520 AgedSuppliers.php:321 InventoryValuation.php:290 msgid "Detailed Report" msgstr "Informe detallado" @@ -1271,7 +1271,7 @@ #: BOMIndented.php:277 BOMIndentedReverse.php:255 BOMListing.php:131 #: DebtorsAtPeriodEnd.php:168 InventoryPlanning.php:460 #: InventoryPlanningPrefSupplier.php:530 InventoryQuantities.php:210 -#: InventoryValuation.php:295 MRPPlannedPurchaseOrders.php:294 +#: InventoryValuation.php:296 MRPPlannedPurchaseOrders.php:294 #: MRPPlannedWorkOrders.php:348 MRPReschedules.php:153 MRPShortages.php:303 #: OutstandingGRNs.php:277 PDFCustomerList.php:421 PDFLowGP.php:146 #: PDFPriceList.php:340 PDFRemittanceAdvice.php:175 @@ -1344,7 +1344,7 @@ msgid "For suppliers trading in" msgstr "Para proveedores de" -#: AgedSuppliers.php:318 InventoryValuation.php:286 +#: AgedSuppliers.php:318 InventoryValuation.php:287 msgid "Summary or Detailed Report" msgstr "Informe detallado o resumen" @@ -2429,7 +2429,7 @@ #: PDFOrdersInvoiced.php:296 ReorderLevel.php:290 ReorderLevel.php:299 #: ReorderLevelLocation.php:164 StockCounts.php:214 StockReorderLevel.php:58 #: StockSerialItemResearch.php:81 StockStatus.php:88 StockStatus.php:93 -#: SupplierTenderCreate.php:137 WhereUsedInquiry.php:71 WorkCentres.php:129 +#: SupplierTenderCreate.php:137 WhereUsedInquiry.php:74 WorkCentres.php:129 #: WorkCentres.php:226 api/api_xml-rpc.php:2531 api/api_xml-rpc.php:2577 #: api/api_xml-rpc.php:2773 #: includes/PDFPeriodStockTransListingPageHeader.inc:51 @@ -2437,17 +2437,17 @@ msgid "Location" msgstr "Ubicación" -#: BOMs.php:564 WhereUsedInquiry.php:70 includes/MainMenuLinksArray.php:317 +#: BOMs.php:564 WhereUsedInquiry.php:73 includes/MainMenuLinksArray.php:317 msgid "Work Centre" msgstr "Centro de Trabajo" -#: BOMs.php:566 BOMs.php:770 WhereUsedInquiry.php:73 +#: BOMs.php:566 BOMs.php:770 WhereUsedInquiry.php:76 #: includes/PDFBOMListingPageHeader.inc:40 msgid "Effective After" msgstr "Vigente después de" #: BOMs.php:567 BOMs.php:774 PurchData.php:703 SellThroughSupport.php:267 -#: WhereUsedInquiry.php:74 includes/PDFBOMListingPageHeader.inc:41 +#: WhereUsedInquiry.php:77 includes/PDFBOMListingPageHeader.inc:41 msgid "Effective To" msgstr "Vigente Para" @@ -5539,7 +5539,7 @@ #: ContractOtherReqts.php:159 InternalStockRequest.php:273 #: InternalStockRequestAuthorisation.php:105 SelectWorkOrder.php:330 -#: WhereUsedInquiry.php:72 WorkOrderCosting.php:101 +#: WhereUsedInquiry.php:75 WorkOrderCosting.php:101 msgid "Quantity Required" msgstr "Cantidad Requerida" @@ -9096,7 +9096,8 @@ #: CustomerInquiry.php:152 CustomerReceipt.php:1033 Dashboard.php:58 #: PrintCustStatements.php:394 SalesPeople.php:206 Shipments.php:406 #: StockClone.php:871 StockClone.php:873 Stocks.php:1180 Stocks.php:1182 -#: SupplierInquiry.php:145 includes/PDFAgedDebtorsPageHeader.inc:50 +#: SupplierInquiry.php:145 WhereUsedInquiry.php:92 +#: includes/PDFAgedDebtorsPageHeader.inc:50 #: includes/PDFAgedSuppliersPageHeader.inc:36 msgid "Current" msgstr "Actual" @@ -15600,6 +15601,7 @@ #: InternalStockRequest.php:584 SelectProduct.php:81 SelectProduct.php:805 #: StockClone.php:876 StockClone.php:878 Stocks.php:1185 Stocks.php:1187 +#: WhereUsedInquiry.php:90 msgid "Obsolete" msgstr "Obsoleto" @@ -15803,23 +15805,23 @@ msgid "Inventory Planning Reporting" msgstr "Reporte de Planificación de Inventario" -#: InventoryPlanning.php:400 InventoryValuation.php:238 PDFPriceList.php:302 +#: InventoryPlanning.php:400 InventoryValuation.php:239 PDFPriceList.php:302 #: PDFPrintLabel.php:296 StockCheck.php:272 msgid "From Inventory Category Code" msgstr "Desde el código de categoría de inventario" -#: InventoryPlanning.php:412 InventoryValuation.php:254 PDFPriceList.php:305 +#: InventoryPlanning.php:412 InventoryValuation.php:255 PDFPriceList.php:305 #: PDFPrintLabel.php:305 StockCheck.php:283 msgid "To Inventory Category Code" msgstr "Hasta el código de categoría de inventario" #: InventoryPlanning.php:424 InventoryPlanningPrefSupplier.php:486 -#: InventoryValuation.php:267 StockCheck.php:295 +#: InventoryValuation.php:268 StockCheck.php:295 msgid "For Inventory in Location" msgstr "Para inventario en ubicación" #: InventoryPlanning.php:430 InventoryPlanningPrefSupplier.php:492 -#: InventoryValuation.php:277 MRPCreateDemands.php:226 PDFDIFOT.php:68 +#: InventoryValuation.php:278 MRPCreateDemands.php:226 PDFDIFOT.php:68 #: PDFDeliveryDifferences.php:64 PDFOrderStatus.php:63 #: PDFOrdersInvoiced.php:66 StockUsage.php:87 StockUsage.php:89 msgid "All Locations" @@ -16068,11 +16070,11 @@ msgid "Category ID" msgstr "ID de categoría" -#: InventoryValuation.php:222 +#: InventoryValuation.php:223 msgid "Inventory Valuation Reporting" msgstr "Informe de Valoración del Inventario" -#: InventoryValuation.php:296 +#: InventoryValuation.php:297 msgid "Output to CSV" msgstr "Salida a CSV" @@ -18842,7 +18844,7 @@ #: PDFOrderStatus.php:297 PO_AuthoriseMyOrders.php:63 PO_Header.php:829 #: PO_OrderDetails.php:152 PO_SelectOSPurchOrder.php:521 #: PO_SelectPurchOrder.php:440 SelectWorkOrder.php:324 SelectWorkOrder.php:360 -#: WorkOrderCosting.php:104 WorkOrderCosting.php:118 +#: WhereUsedInquiry.php:72 WorkOrderCosting.php:104 WorkOrderCosting.php:118 #: includes/InputSerialItemsFile.php:160 #, php-format msgid "Status" @@ -23354,7 +23356,7 @@ #: PrintCustTrans.php:420 PrintCustTrans.php:1075 #: PrintCustTransPortrait.php:477 PrintCustTransPortrait.php:1142 -#: includes/DefineCartClass.php:377 +#: includes/DatabaseTranslations.php:60 includes/DefineCartClass.php:377 msgid "Freight" msgstr "Flete" @@ -30438,11 +30440,11 @@ msgid "The quantity on order for this product to be received into" msgstr "La cantidad en pedidos de este producto a ser recibida en" -#: StockLocStatus.php:296 StockLocStatus.php:328 StockStatus.php:269 +#: StockLocStatus.php:297 StockLocStatus.php:329 StockStatus.php:269 msgid "Serial Numbers" msgstr "Numeros de Serie" -#: StockLocStatus.php:298 StockLocStatus.php:330 StockStatus.php:271 +#: StockLocStatus.php:299 StockLocStatus.php:331 StockStatus.php:271 #: WorkOrderEntry.php:634 msgid "Batches" msgstr "Lotes" @@ -37150,23 +37152,23 @@ msgid "Show Where Used" msgstr "Mostrar Dónde Usado" -#: WhereUsedInquiry.php:61 +#: WhereUsedInquiry.php:63 msgid "The parents for the selected part could not be retrieved because" msgstr "La base del código seleccionado no se puede obtener porque" -#: WhereUsedInquiry.php:64 +#: WhereUsedInquiry.php:66 msgid "The selected item" msgstr "El artículo seleccionado" -#: WhereUsedInquiry.php:64 +#: WhereUsedInquiry.php:66 msgid "is not used as a component of any other parts" msgstr "no se utiliza como un componente de cualquier otro código" -#: WhereUsedInquiry.php:69 +#: WhereUsedInquiry.php:71 msgid "Used By" msgstr "Usado Por" -#: WhereUsedInquiry.php:87 +#: WhereUsedInquiry.php:94 msgid "Show Bill Of Material" msgstr "Mostrar Lista de Materiales" @@ -39743,7 +39745,7 @@ msgid "Can field be null" msgstr "El Campo puede ser nulo" -#: Z_DescribeTable.php:15 includes/DatabaseTranslations.php:59 +#: Z_DescribeTable.php:15 includes/DatabaseTranslations.php:64 #: install/index.php:1040 reportwriter/languages/en_US/reports.php:65 msgid "Default" msgstr "Predeterminado" @@ -46719,15 +46721,15 @@ #: includes/DatabaseTranslations.php:22 msgid "Journal - GL" -msgstr "" +msgstr "Diario contable" #: includes/DatabaseTranslations.php:23 msgid "Payment - GL" -msgstr "" +msgstr "Pago contable" #: includes/DatabaseTranslations.php:24 msgid "Receipt - GL" -msgstr "" +msgstr "Recibo contable" #: includes/DatabaseTranslations.php:25 msgid "Standing Journal" @@ -46755,23 +46757,23 @@ #: includes/DatabaseTranslations.php:41 msgid "Work Order Variance" -msgstr "" +msgstr "Variación en orden de trabajo" #: includes/DatabaseTranslations.php:43 msgid "Shipment Close" -msgstr "" +msgstr "Cierre de embarque" #: includes/DatabaseTranslations.php:44 msgid "Contract Close" -msgstr "" +msgstr "Cierre de contrato" #: includes/DatabaseTranslations.php:45 msgid "Cost Update" -msgstr "" +msgstr "Actualización de costo" #: includes/DatabaseTranslations.php:46 msgid "Exchange Difference" -msgstr "" +msgstr "Diferencia cambiaria" #: includes/DatabaseTranslations.php:48 msgid "Stock Requests" @@ -46779,7 +46781,7 @@ #: includes/DatabaseTranslations.php:51 msgid "Asset Category Change" -msgstr "" +msgstr "Cambio de categoría de activo" #: includes/DatabaseTranslations.php:52 msgid "Delete w/down asset" @@ -46787,12 +46789,20 @@ #: includes/DatabaseTranslations.php:55 msgid "Opening Balance" -msgstr "" +msgstr "Saldo inicial" #: includes/DatabaseTranslations.php:56 msgid "Auto Debtor Number" msgstr "" +#: includes/DatabaseTranslations.php:59 +msgid "Exempt" +msgstr "Exento" + +#: includes/DatabaseTranslations.php:61 +msgid "Handling" +msgstr "Manejo" + #: includes/DefineCartClass.php:173 msgid "The order line for" msgstr "La línea de pedido para" Modified: trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po 2014-08-29 07:15:02 UTC (rev 6854) +++ trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po 2014-08-29 20:41:58 UTC (rev 6855) @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-28 08:46-0600\n" +"POT-Creation-Date: 2014-08-29 11:25-0600\n" "PO-Revision-Date: 2014-08-28 08:50-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: French <none>\n" @@ -920,7 +920,7 @@ msgstr "" #: AgedControlledInventory.php:12 InventoryQuantities.php:155 -#: InventoryValuation.php:230 Locations.php:394 Locations.php:455 MRP.php:530 +#: InventoryValuation.php:231 Locations.php:394 Locations.php:455 MRP.php:530 #: MRPCalendar.php:21 MRPCreateDemands.php:196 MRPDemandTypes.php:17 #: MRPDemands.php:27 MRPPlannedPurchaseOrders.php:265 #: MRPPlannedWorkOrders.php:247 MRPPlannedWorkOrders.php:321 @@ -1263,11 +1263,11 @@ msgid "Summary or detailed report" msgstr "Sommaire ou rapport détaillé" -#: AgedDebtors.php:519 AgedSuppliers.php:320 InventoryValuation.php:288 +#: AgedDebtors.php:519 AgedSuppliers.php:320 InventoryValuation.php:289 msgid "Summary Report" msgstr "Rapport succinct" -#: AgedDebtors.php:520 AgedSuppliers.php:321 InventoryValuation.php:289 +#: AgedDebtors.php:520 AgedSuppliers.php:321 InventoryValuation.php:290 msgid "Detailed Report" msgstr "Rapport détaillé" @@ -1275,7 +1275,7 @@ #: BOMIndented.php:277 BOMIndentedReverse.php:255 BOMListing.php:131 #: DebtorsAtPeriodEnd.php:168 InventoryPlanning.php:460 #: InventoryPlanningPrefSupplier.php:530 InventoryQuantities.php:210 -#: InventoryValuation.php:295 MRPPlannedPurchaseOrders.php:294 +#: InventoryValuation.php:296 MRPPlannedPurchaseOrders.php:294 #: MRPPlannedWorkOrders.php:348 MRPReschedules.php:153 MRPShortages.php:303 #: OutstandingGRNs.php:277 PDFCustomerList.php:421 PDFLowGP.php:146 #: PDFPriceList.php:340 PDFRemittanceAdvice.php:175 @@ -1347,7 +1347,7 @@ msgstr "Devise fournisseur" # JDN -#: AgedSuppliers.php:318 InventoryValuation.php:286 +#: AgedSuppliers.php:318 InventoryValuation.php:287 msgid "Summary or Detailed Report" msgstr "Type de rapport" @@ -2457,7 +2457,7 @@ #: PDFOrdersInvoiced.php:296 ReorderLevel.php:290 ReorderLevel.php:299 #: ReorderLevelLocation.php:164 StockCounts.php:214 StockReorderLevel.php:58 #: StockSerialItemResearch.php:81 StockStatus.php:88 StockStatus.php:93 -#: SupplierTenderCreate.php:137 WhereUsedInquiry.php:71 WorkCentres.php:129 +#: SupplierTenderCreate.php:137 WhereUsedInquiry.php:74 WorkCentres.php:129 #: WorkCentres.php:226 api/api_xml-rpc.php:2531 api/api_xml-rpc.php:2577 #: api/api_xml-rpc.php:2773 #: includes/PDFPeriodStockTransListingPageHeader.inc:51 @@ -2466,19 +2466,19 @@ msgstr "Site" # JDN -#: BOMs.php:564 WhereUsedInquiry.php:70 includes/MainMenuLinksArray.php:317 +#: BOMs.php:564 WhereUsedInquiry.php:73 includes/MainMenuLinksArray.php:317 msgid "Work Centre" msgstr "Centre de travail" # JDN à compléter éventuellement -#: BOMs.php:566 BOMs.php:770 WhereUsedInquiry.php:73 +#: BOMs.php:566 BOMs.php:770 WhereUsedInquiry.php:76 #: includes/PDFBOMListingPageHeader.inc:40 msgid "Effective After" msgstr "Du" # JDN #: BOMs.php:567 BOMs.php:774 PurchData.php:703 SellThroughSupport.php:267 -#: WhereUsedInquiry.php:74 includes/PDFBOMListingPageHeader.inc:41 +#: WhereUsedInquiry.php:77 includes/PDFBOMListingPageHeader.inc:41 msgid "Effective To" msgstr "Au" @@ -5522,7 +5522,7 @@ # JDN #: ContractOtherReqts.php:159 InternalStockRequest.php:273 #: InternalStockRequestAuthorisation.php:105 SelectWorkOrder.php:330 -#: WhereUsedInquiry.php:72 WorkOrderCosting.php:101 +#: WhereUsedInquiry.php:75 WorkOrderCosting.php:101 msgid "Quantity Required" msgstr "Quantité demandée" @@ -9123,7 +9123,8 @@ #: CustomerInquiry.php:152 CustomerReceipt.php:1033 Dashboard.php:58 #: PrintCustStatements.php:394 SalesPeople.php:206 Shipments.php:406 #: StockClone.php:871 StockClone.php:873 Stocks.php:1180 Stocks.php:1182 -#: SupplierInquiry.php:145 includes/PDFAgedDebtorsPageHeader.inc:50 +#: SupplierInquiry.php:145 WhereUsedInquiry.php:92 +#: includes/PDFAgedDebtorsPageHeader.inc:50 #: includes/PDFAgedSuppliersPageHeader.inc:36 msgid "Current" msgstr "Actif" @@ -15718,6 +15719,7 @@ #: InternalStockRequest.php:584 SelectProduct.php:81 SelectProduct.php:805 #: StockClone.php:876 StockClone.php:878 Stocks.php:1185 Stocks.php:1187 +#: WhereUsedInquiry.php:90 msgid "Obsolete" msgstr "Obsolète" @@ -15923,23 +15925,23 @@ msgid "Inventory Planning Reporting" msgstr "Rapport d'inventaire" -#: InventoryPlanning.php:400 InventoryValuation.php:238 PDFPriceList.php:302 +#: InventoryPlanning.php:400 InventoryValuation.php:239 PDFPriceList.php:302 #: PDFPrintLabel.php:296 StockCheck.php:272 msgid "From Inventory Category Code" msgstr "Du code catégorie" -#: InventoryPlanning.php:412 InventoryValuation.php:254 PDFPriceList.php:305 +#: InventoryPlanning.php:412 InventoryValuation.php:255 PDFPriceList.php:305 #: PDFPrintLabel.php:305 StockCheck.php:283 msgid "To Inventory Category Code" msgstr "Au code catégorie" #: InventoryPlanning.php:424 InventoryPlanningPrefSupplier.php:486 -#: InventoryValuation.php:267 StockCheck.php:295 +#: InventoryValuation.php:268 StockCheck.php:295 msgid "For Inventory in Location" msgstr "Site du stock" #: InventoryPlanning.php:430 InventoryPlanningPrefSupplier.php:492 -#: InventoryValuation.php:277 MRPCreateDemands.php:226 PDFDIFOT.php:68 +#: InventoryValuation.php:278 MRPCreateDemands.php:226 PDFDIFOT.php:68 #: PDFDeliveryDifferences.php:64 PDFOrderStatus.php:63 #: PDFOrdersInvoiced.php:66 StockUsage.php:87 StockUsage.php:89 msgid "All Locations" @@ -16185,11 +16187,11 @@ msgid "Category ID" msgstr "" -#: InventoryValuation.php:222 +#: InventoryValuation.php:223 msgid "Inventory Valuation Reporting" msgstr "Valorisation du stock" -#: InventoryValuation.php:296 +#: InventoryValuation.php:297 msgid "Output to CSV" msgstr "" @@ -19005,7 +19007,7 @@ #: PDFOrderStatus.php:297 PO_AuthoriseMyOrders.php:63 PO_Header.php:829 #: PO_OrderDetails.php:152 PO_SelectOSPurchOrder.php:521 #: PO_SelectPurchOrder.php:440 SelectWorkOrder.php:324 SelectWorkOrder.php:360 -#: WorkOrderCosting.php:104 WorkOrderCosting.php:118 +#: WhereUsedInquiry.php:72 WorkOrderCosting.php:104 WorkOrderCosting.php:118 #: includes/InputSerialItemsFile.php:160 #, php-format msgid "Status" @@ -23568,7 +23570,7 @@ #: PrintCustTrans.php:420 PrintCustTrans.php:1075 #: PrintCustTransPortrait.php:477 PrintCustTransPortrait.php:1142 -#: includes/DefineCartClass.php:377 +#: includes/DatabaseTranslations.php:60 includes/DefineCartClass.php:377 msgid "Freight" msgstr "Transport" @@ -30804,11 +30806,11 @@ msgid "The quantity on order for this product to be received into" msgstr "La quantité à la commande de ce produit pour être reçu dans" -#: StockLocStatus.php:296 StockLocStatus.php:328 StockStatus.php:269 +#: StockLocStatus.php:297 StockLocStatus.php:329 StockStatus.php:269 msgid "Serial Numbers" msgstr "N° de série" -#: StockLocStatus.php:298 StockLocStatus.php:330 StockStatus.php:271 +#: StockLocStatus.php:299 StockLocStatus.php:331 StockStatus.php:271 #: WorkOrderEntry.php:634 msgid "Batches" msgstr "Lots" @@ -37600,25 +37602,25 @@ msgid "Show Where Used" msgstr "Afficher le détail de son utilisation" -#: WhereUsedInquiry.php:61 +#: WhereUsedInquiry.php:63 msgid "The parents for the selected part could not be retrieved because" msgstr "" "Les parents de la partie sélectionnée n'a pas pu être récupérés en raison" -#: WhereUsedInquiry.php:64 +#: WhereUsedInquiry.php:66 msgid "The selected item" msgstr "L'élément sélectionné" # JDN -#: WhereUsedInquiry.php:64 +#: WhereUsedInquiry.php:66 msgid "is not used as a component of any other parts" msgstr "n'est pas utilisé(e) comme un composant de toute autre article" -#: WhereUsedInquiry.php:69 +#: WhereUsedInquiry.php:71 msgid "Used By" msgstr "Utilisé par" -#: WhereUsedInquiry.php:87 +#: WhereUsedInquiry.php:94 msgid "Show Bill Of Material" msgstr "Afficher les nomenclatures" @@ -40158,7 +40160,7 @@ msgid "Can field be null" msgstr "" -#: Z_DescribeTable.php:15 includes/DatabaseTranslations.php:59 +#: Z_DescribeTable.php:15 includes/DatabaseTranslations.php:64 #: install/index.php:1040 reportwriter/languages/en_US/reports.php:65 msgid "Default" msgstr "Par défaut" @@ -47157,6 +47159,14 @@ msgid "Auto Debtor Number" msgstr "" +#: includes/DatabaseTranslations.php:59 +msgid "Exempt" +msgstr "" + +#: includes/DatabaseTranslations.php:61 +msgid "Handling" +msgstr "" + #: includes/DefineCartClass.php:173 msgid "The order line for" msgstr "La ligne de Commande pour" |
From: <dai...@us...> - 2014-08-29 22:33:44
|
Revision: 6856 http://sourceforge.net/p/web-erp/reponame/6856 Author: daintree Date: 2014-08-29 22:33:40 +0000 (Fri, 29 Aug 2014) Log Message: ----------- handle zero count of records returned from search Modified Paths: -------------- trunk/Dashboard.php trunk/WorkOrderEntry.php trunk/doc/Change.log Modified: trunk/Dashboard.php =================================================================== --- trunk/Dashboard.php 2014-08-29 20:41:58 UTC (rev 6855) +++ trunk/Dashboard.php 2014-08-29 22:33:40 UTC (rev 6856) @@ -1,5 +1,5 @@ <?php -/* $Id: Dashboard.php 6338 2013-09-28 05:10:46Z daintree $*/ +/* $Id: Dashboard.php 6843 2014-08-20 06:04:47Z daintree $*/ include('includes/session.inc'); Modified: trunk/WorkOrderEntry.php =================================================================== --- trunk/WorkOrderEntry.php 2014-08-29 20:41:58 UTC (rev 6855) +++ trunk/WorkOrderEntry.php 2014-08-29 22:33:40 UTC (rev 6856) @@ -66,7 +66,7 @@ } else { // new $_POST['WO'] = GetNextTransNo(40,$db); - $sql = "INSERT INTO workorders (wo, + $SQL = "INSERT INTO workorders (wo, loccode, requiredby, startdate) @@ -75,7 +75,7 @@ '" . $LocCode . "', '" . $ReqDate . "', '" . $StartDate. "')"; - $InsWOResult = DB_query($sql,$db); + $InsWOResult = DB_query($SQL,$db); } @@ -190,23 +190,28 @@ ORDER BY stockmaster.stockid"; } } - $sql=$SQL; - $sqlcount = substr($sql,strpos($sql, "FROM")); - $sqlcount = substr($sqlcount,0, strpos($sqlcount, "ORDER")); - $sqlcount = 'SELECT COUNT(*) '.$sqlcount; - $SearchResult = DB_query($sqlcount,$db,$ErrMsg,$DbgMsg); + $SQLCount = substr($SQL,strpos($SQL, "FROM")); + $SQLCount = substr($SQLCount,0, strpos($SQLCount, "ORDER")); + $SQLCount = 'SELECT COUNT(*) '.$SQLCount; + $SearchResult = DB_query($SQLCount,$db,$ErrMsg); + $myrow=DB_fetch_array($SearchResult); DB_free_result($SearchResult); unset($SearchResult); $ListCount = $myrow[0]; - $ListPageMax = ceil($ListCount / $_SESSION['DisplayRecordsMax'])-1; + if ($ListCount>0){ + $ListPageMax = ceil($ListCount / $_SESSION['DisplayRecordsMax'])-1; + } else { + $ListPageMax =1; + } + if (isset($_POST['Next'])) { - $Offset = $_POST['currpage']+1; + $Offset = $_POST['CurrPage']+1; } if (isset($_POST['Prev'])) { - $Offset = $_POST['currpage']-1; + $Offset = $_POST['CurrPage']-1; } if (!isset($Offset)) { $Offset=0; @@ -217,12 +222,9 @@ if($Offset>$ListPageMax){ $Offset=$ListPageMax; } - $sql = $sql . ' LIMIT ' . $_SESSION['DisplayRecordsMax'].' OFFSET ' . strval($_SESSION['DisplayRecordsMax']*$Offset); + $SQL = $SQL . ' LIMIT ' . $_SESSION['DisplayRecordsMax'].' OFFSET ' . strval($_SESSION['DisplayRecordsMax']*$Offset); - $SQL=$sql; - - $ErrMsg = _('There is a problem selecting the part records to display because'); $DbgMsg = _('The SQL used to get the part selection was'); $SearchResult = DB_query($SQL,$db,$ErrMsg, $DbgMsg); @@ -303,7 +305,7 @@ $Result = DB_Txn_Begin($db); // insert parent item info - $sql = "INSERT INTO woitems (wo, + $SQL = "INSERT INTO woitems (wo, stockid, qtyreqd, stdcost) @@ -314,7 +316,7 @@ '" . $Cost . "' )"; $ErrMsg = _('The work order item could not be added'); - $result = DB_query($sql,$db,$ErrMsg); + $result = DB_query($SQL,$db,$ErrMsg); //Recursively insert real component requirements - see includes/SQL_CommonFunctions.in for function WoRealRequirements WoRealRequirements($db, $_POST['WO'], $_POST['StockLocation'], $NewItem); @@ -355,16 +357,16 @@ for ($i=1;$i<=$_POST['NumberOfOutputs'];$i++){ $QtyRecd+=$_POST['RecdQty'.$i]; } - unset($sql); + unset($SQL); if ($QtyRecd==0){ //can only change factory location if Qty Recd is 0 - $sql[] = "UPDATE workorders SET requiredby='" . $SQL_ReqDate . "', + $SQL[] = "UPDATE workorders SET requiredby='" . $SQL_ReqDate . "', startdate='" . FormatDateForSQL($_POST['StartDate']) . "', loccode='" . $_POST['StockLocation'] . "' WHERE wo='" . $_POST['WO'] . "'"; } else { prnMsg(_('The factory where this work order is made can only be updated if the quantity received on all output items is 0'),'warn'); - $sql[] = "UPDATE workorders SET requiredby='" . $SQL_ReqDate . "', + $SQL[] = "UPDATE workorders SET requiredby='" . $SQL_ReqDate . "', startdate='" . FormatDateForSQL($_POST['StartDate']) . "' WHERE wo='" . $_POST['WO'] . "'"; } @@ -376,7 +378,7 @@ if (!isset($_POST['WOComments'.$i])) { $_POST['WOComments'.$i]=''; } - $sql[] = "UPDATE woitems SET comments = '". $_POST['WOComments'.$i] ."' + $SQL[] = "UPDATE woitems SET comments = '". $_POST['WOComments'.$i] ."' WHERE wo='" . $_POST['WO'] . "' AND stockid='" . $_POST['OutputItem'.$i] . "'"; if (isset($_POST['QtyRecd'.$i]) AND $_POST['QtyRecd'.$i]>$_POST['OutputQty'.$i]){ @@ -399,13 +401,13 @@ } else { $Cost = $CostRow['cost']; } - $sql[] = "UPDATE woitems SET qtyreqd = '". $_POST['OutputQty' . $i] . "', + $SQL[] = "UPDATE woitems SET qtyreqd = '". $_POST['OutputQty' . $i] . "', nextlotsnref = '". $_POST['NextLotSNRef'.$i] ."', stdcost ='" . $Cost . "' WHERE wo='" . $_POST['WO'] . "' AND stockid='" . $_POST['OutputItem'.$i] . "'"; } elseif (isset($_POST['HasWOSerialNos'.$i]) AND $_POST['HasWOSerialNos'.$i]==false) { - $sql[] = "UPDATE woitems SET qtyreqd = '". $_POST['OutputQty' . $i] . "', + $SQL[] = "UPDATE woitems SET qtyreqd = '". $_POST['OutputQty' . $i] . "', nextlotsnref = '". $_POST['NextLotSNRef'.$i] ."' WHERE wo='" . $_POST['WO'] . "' AND stockid='" . $_POST['OutputItem'.$i] . "'"; @@ -414,9 +416,9 @@ //run the SQL from either of the above possibilites $ErrMsg = _('The work order could not be added/updated'); - foreach ($sql as $sql_stmt){ - // echo '<br />' . $sql_stmt; - $result = DB_query($sql_stmt,$db,$ErrMsg); + foreach ($SQL as $SQL_stmt){ + // echo '<br />' . $SQL_stmt; + $result = DB_query($SQL_stmt,$db,$ErrMsg); } if (!isset($_POST['Search'])) { @@ -452,19 +454,19 @@ $ErrMsg = _('The work order could not be deleted'); $DbgMsg = _('The SQL used to delete the work order was'); //delete the worequirements - $sql = "DELETE FROM worequirements WHERE wo='" . $_POST['WO'] . "'"; - $result = DB_query($sql,$db,$ErrMsg,$DbgMsg,true); + $SQL = "DELETE FROM worequirements WHERE wo='" . $_POST['WO'] . "'"; + $result = DB_query($SQL,$db,$ErrMsg,$DbgMsg,true); //delete the items on the work order - $sql = "DELETE FROM woitems WHERE wo='" . $_POST['WO'] . "'"; - $result = DB_query($sql,$db,$ErrMsg,$DbgMsg,true); + $SQL = "DELETE FROM woitems WHERE wo='" . $_POST['WO'] . "'"; + $result = DB_query($SQL,$db,$ErrMsg,$DbgMsg,true); //delete the controlled items defined in wip - $sql="DELETE FROM woserialnos WHERE wo='" . $_POST['WO'] . "'"; + $SQL="DELETE FROM woserialnos WHERE wo='" . $_POST['WO'] . "'"; $ErrMsg=_('The work order serial numbers could not be deleted'); - $result = DB_query($sql,$db,$ErrMsg,$DbgMsg,true); + $result = DB_query($SQL,$db,$ErrMsg,$DbgMsg,true); // delete the actual work order - $sql="DELETE FROM workorders WHERE wo='" . $_POST['WO'] . "'"; + $SQL="DELETE FROM workorders WHERE wo='" . $_POST['WO'] . "'"; $ErrMsg=_('The work order could not be deleted'); - $result = DB_query($sql,$db,$ErrMsg,$DbgMsg,true); + $result = DB_query($SQL,$db,$ErrMsg,$DbgMsg,true); DB_Txn_Commit($db); prnMsg(_('The work order has been cancelled'),'success'); @@ -490,7 +492,7 @@ echo '<br /><table class="selection">'; -$sql="SELECT workorders.loccode, +$SQL="SELECT workorders.loccode, requiredby, startdate, costissued, @@ -500,7 +502,7 @@ INNER JOIN locationusers ON locationusers.loccode=workorders.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canupd=1 WHERE workorders.wo='" . $_POST['WO'] . "'"; -$WOResult = DB_query($sql,$db); +$WOResult = DB_query($SQL,$db); if (DB_num_rows($WOResult)==1){ $myrow = DB_fetch_array($WOResult); @@ -714,7 +716,7 @@ if (DB_num_rows($SearchResult)>1){ - $PageBar = '<tr><td><input type="hidden" name="currpage" value="'.$Offset.'">'; + $PageBar = '<tr><td><input type="hidden" name="CurrPage" value="'.$Offset.'">'; if($Offset>0) $PageBar .= '<input type="submit" name="Prev" value="'._('Prev').'" />'; else Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-29 20:41:58 UTC (rev 6855) +++ trunk/doc/Change.log 2014-08-29 22:33:40 UTC (rev 6856) @@ -1,42 +1,43 @@ webERP Change Log -29/08/14 RChacon: In TaxAuthorityRates.php and TaxCategories.php: adds $ViewTopic and $BookMark; Uses gettext() to translate 'Exempt', 'Freight' and 'Handling'. -29/08/14 Exson: Fixed the StockLocStatus Serial Number link column shift problem. -28/08/14 RChacon: In Tax.php: Fixes SQL select order-by from transaction-date to record-number (primary key). Minor improvements. -28/08/14 Exson: Fixed the csv file aligned abnormal when there are commas in fields strings. -28/08/14 RChacon: In Tax.php: Adds code comments, clean-up unneeded variables, simplies and reorder SQL select, reduces if() calls, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), fixes start-date for 'Y/m/d' format, adds start-date for 'Y-m-d' format, adds a summary section for the report, adds ViewTopic and BookMark, adds more NoOfPeriods. -26/08/14 RChacon: In PDFPriceList.php: Adds code comments, adds PageHeader() print for currabrev and categoryid, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), adds 'Prices excluding tax' warning. -15/08/14 RChacon: Fixes double line feed in PDFQuotationPortrait.php reported by Arwan Galaya. Uniforms code between PDFQuotation.php and PDFQuotationPortrait.php. -14/08/14 RChacon: In CustomerInquiry.php and SupplierInquiry.php makes translatable the systypes.typename. -14/08/14 RChacon: In SupplierInquiry.php: Reorganizes columns Date, Type, Number, Reference and Comments, and regroups table-datacel format-strings as in CustomerInquiry.php code. -13/08/14 kelo: SupplierBalsAtPeriodEnd.php fix calculation to take into account fx differences on after date transactions -13/08/14 RChacon: includes/DatabaseTranslations.php used to store the fields of tables that are used from the database so that they can be translated in particular systypes for the types of transactions invoice credit note payment receipt etc. Can be extended for scripts and other tables where the data from the table is static and used to display -13/08/14 RChacon: In CustomerInquiry.php: Adds class ascending and reorganizes columns Date, Type, Number and Reference; Regroups table-datacel format-strings, completes the datacel quantity by table-row; makes translatable the systypes.typename. -12/08/14 RChacon: In SupplierInquiry.php: makes the field systypes.typename be translatable. -12/08/14 RChacon: In Z_poRebuildDefault.php: extends title, improves comments, sets file to pot, updates $FilesToInclude, renames old pot file to bak extension. Minor improvements. -08/08/14 Andrew Galuski: Add SQL and maintenance screens for Location based security. added new report aged controlled stock. additional scripts to follow as time allows +30/8/14 Phil: WorkOrderEntry.php didn't handle no item returned from search correctly - fixed. +29/8/14 RChacon: In TaxAuthorityRates.php and TaxCategories.php: adds $ViewTopic and $BookMark; Uses gettext() to translate 'Exempt', 'Freight' and 'Handling'. +29/8/14 Exson: Fixed the StockLocStatus Serial Number link column shift problem. +28/8/14 RChacon: In Tax.php: Fixes SQL select order-by from transaction-date to record-number (primary key). Minor improvements. +28/8/14 Exson: Fixed the csv file aligned abnormal when there are commas in fields strings. +28/8/14 RChacon: In Tax.php: Adds code comments, clean-up unneeded variables, simplies and reorder SQL select, reduces if() calls, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), fixes start-date for 'Y/m/d' format, adds start-date for 'Y-m-d' format, adds a summary section for the report, adds ViewTopic and BookMark, adds more NoOfPeriods. +26/8/14 RChacon: In PDFPriceList.php: Adds code comments, adds PageHeader() print for currabrev and categoryid, replaces addTextWarp-left-align with addText, replaces line-drawing a box with Rectangle(), adds 'Prices excluding tax' warning. +15/8/14 RChacon: Fixes double line feed in PDFQuotationPortrait.php reported by Arwan Galaya. Uniforms code between PDFQuotation.php and PDFQuotationPortrait.php. +14/8/14 RChacon: In CustomerInquiry.php and SupplierInquiry.php makes translatable the systypes.typename. +14/8/14 RChacon: In SupplierInquiry.php: Reorganizes columns Date, Type, Number, Reference and Comments, and regroups table-datacel format-strings as in CustomerInquiry.php code. +13/8/14 kelo: SupplierBalsAtPeriodEnd.php fix calculation to take into account fx differences on after date transactions +13/8/14 RChacon: includes/DatabaseTranslations.php used to store the fields of tables that are used from the database so that they can be translated in particular systypes for the types of transactions invoice credit note payment receipt etc. Can be extended for scripts and other tables where the data from the table is static and used to display +13/8/14 RChacon: In CustomerInquiry.php: Adds class ascending and reorganizes columns Date, Type, Number and Reference; Regroups table-datacel format-strings, completes the datacel quantity by table-row; makes translatable the systypes.typename. +12/8/14 RChacon: In SupplierInquiry.php: makes the field systypes.typename be translatable. +12/8/14 RChacon: In Z_poRebuildDefault.php: extends title, improves comments, sets file to pot, updates $FilesToInclude, renames old pot file to bak extension. Minor improvements. +08/8/14 Andrew Galuski: Add SQL and maintenance screens for Location based security. added new report aged controlled stock. additional scripts to follow as time allows 2/1/14 Tim: Change columns around on SelectWorkOrder.php -31/07/14 RChacon: Corrects the bottom line of the rectangle. Adds comments (info for developers). -29/07/14 RChacon: In PDFPriceList.php: Adds comments (info for developers), ViewTopic and BookMark, and currency name in locale language; deletes unused lines; reformats for legibility; adjusts column sizes to field sizes; improves printing of stockmaster.longdescription; improves code to reduce execution time (calculation out of loops); links right column positions to right margin; corrects IF for CustomerSpecials (deletes translation). In ManualSalesTypes.html: Adds help info about Print a price list by inventory category. +31/7/14 RChacon: Corrects the bottom line of the rectangle. Adds comments (info for developers). +29/7/14 RChacon: In PDFPriceList.php: Adds comments (info for developers), ViewTopic and BookMark, and currency name in locale language; deletes unused lines; reformats for legibility; adjusts column sizes to field sizes; improves printing of stockmaster.longdescription; improves code to reduce execution time (calculation out of loops); links right column positions to right margin; corrects IF for CustomerSpecials (deletes translation). In ManualSalesTypes.html: Adds help info about Print a price list by inventory category. 27/7/14 Exson: Fixed the PO header lost initiator bugs when locations changed. Report by Akits from www.minghao.hk/bbs/. 25/7/14 Phil: Allow dummy - labour stock type items to be added to purchase orders. 17/7/14 RChacon: Adds ViewTopic and BookMark, adds bullet for class ascending columns, repositions columns Type and Trans, add class number to Trans, completes printf. 16/7/14 Andrew Galuski: Add standard cost to stock movement record for stock adjustments 03/07/14 Exson: Make status comments available in PO_OrderDetails.php to ensure that some important data such as grn reversing can be viewed. And add a return previous page link. 27/06/14 RChacon: Add code-comments, $ViewTopic, $BookMark, page_title_text and code to update NewStockID if OldStockID and SelectedStockItem are the same in Z_ChangeStockCode.php. Add id to the "Change An Inventory Item Code" topic anchor in ManualSpecialUtilities.html. -27/06/14 Exson: Make tel length in PO_Header.php is as same as field definition in sql. -26/06/14 Exson: Fixed the bug that Select Customers search result inconsistence with Customer receipt search result in SelectCustomer.php. -24/06/14 RChacon: Add $ViewTopic, $BookMark to Prices.php and minor improvements. -23/06/14 Tim: Fixed the GL account validation pop up error in MiscFunctions.js. -23/06/14 Exson: Fixed the bug that the sales order line's quantity will be update to zero but it show no change in appearance in SelectOrderItems.php. -22/06/14 Tim: Replace now() with CURRENT_TIMESTAMP in MRP.php to get time stamp to meet ANSI standard. -22/06/14 Exson: Fixed the mrp parameters runtime to datetime instead of date format since MRP running records need more precision. -22/06/14 Benjamin (bpiltz2302) from web-ERP-users mail list report and provide the solution for MRP LevelNetting unusual exit bug. The details can be found here: http://weberp-accounting.1478800.n4.nabble.com/MRP-Error-LevelNetting-td4657425.html -21/06/14 Exson: Add location check in StockAdjustments.php to prevent from users selecting controlled items based on one location but changed the location before submit it to server which make serial not exist check absolutely failed. -17/06/14 Exson: Add Z_ImportDebtors.php into Utilities menu and scripts table. -15/06/14 Akits from minghao.hk/bbs/ fixed the bugs that www_Users.php allowed modules does not matched the one displayed in index.php. -11/06/2014 Exson: Fixed the exported csv files with wrong aligned fields due to comma as part of fields content. -09/06/2014 Exson: Fixed the Delivery Date lossing bugs when change Warehouse. Reported by akits from minghao.hk(weberp) bbs. +27/6/14 Exson: Make tel length in PO_Header.php is as same as field definition in sql. +26/6/14 Exson: Fixed the bug that Select Customers search result inconsistence with Customer receipt search result in SelectCustomer.php. +24/6/14 RChacon: Add $ViewTopic, $BookMark to Prices.php and minor improvements. +23/6/14 Tim: Fixed the GL account validation pop up error in MiscFunctions.js. +23/6/14 Exson: Fixed the bug that the sales order line's quantity will be update to zero but it show no change in appearance in SelectOrderItems.php. +22/6/14 Tim: Replace now() with CURRENT_TIMESTAMP in MRP.php to get time stamp to meet ANSI standard. +22/6/14 Exson: Fixed the mrp parameters runtime to datetime instead of date format since MRP running records need more precision. +22/6/14 Benjamin (bpiltz2302) from web-ERP-users mail list report and provide the solution for MRP LevelNetting unusual exit bug. The details can be found here: http://weberp-accounting.1478800.n4.nabble.com/MRP-Error-LevelNetting-td4657425.html +21/6/14 Exson: Add location check in StockAdjustments.php to prevent from users selecting controlled items based on one location but changed the location before submit it to server which make serial not exist check absolutely failed. +17/6/14 Exson: Add Z_ImportDebtors.php into Utilities menu and scripts table. +15/6/14 Akits from minghao.hk/bbs/ fixed the bugs that www_Users.php allowed modules does not matched the one displayed in index.php. +11/6/2014 Exson: Fixed the exported csv files with wrong aligned fields due to comma as part of fields content. +09/6/2014 Exson: Fixed the Delivery Date lossing bugs when change Warehouse. Reported by akits from minghao.hk(weberp) bbs. 2/6/14 Phil: Added bom effectivity dates into work order creation cost calculations - as spotted by Andrew Galuski 1/6/14 Phil: Fixed bug in POItems.php that resulted in an SQL error when the number of items from the search was zero after previous searches had returned records 27/05/14 RChacon: Add page title text and icon to import scripts. Page title text = menu option. |
From: <rc...@us...> - 2014-08-30 15:03:26
|
Revision: 6857 http://sourceforge.net/p/web-erp/reponame/6857 Author: rchacon Date: 2014-08-30 15:03:16 +0000 (Sat, 30 Aug 2014) Log Message: ----------- In TaxAuthorities.php, adds $ViewTopic and $BookMark, completes table headings, formats number columns to fix sort order, and minor improvements. Modified Paths: -------------- trunk/TaxAuthorities.php trunk/doc/Change.log Modified: trunk/TaxAuthorities.php =================================================================== --- trunk/TaxAuthorities.php 2014-08-29 22:33:40 UTC (rev 6856) +++ trunk/TaxAuthorities.php 2014-08-30 15:03:16 UTC (rev 6857) @@ -1,33 +1,32 @@ <?php - /* $Id$*/ include('includes/session.inc'); $Title = _('Tax Authorities'); +$ViewTopic = 'Tax';// Filename in ManualContents.php's TOC. +$BookMark = 'TaxAuthorities';// Anchor's id in the manual's html document. include('includes/header.inc'); +echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . + '/images/maintenance.png" title="' . + _('Tax Authorities') . '" />' . ' ' . + _('Tax Authorities') . '</p>'; -echo '<p class="page_title_text"> - <img src="'.$RootPath.'/css/'.$Theme.'/images/maintenance.png" title="' . _('Supplier Types') - . '" alt="" />' . $Title. ' - </p>'; - -if (isset($_POST['SelectedTaxAuthID'])){ +if(isset($_POST['SelectedTaxAuthID'])) { $SelectedTaxAuthID =$_POST['SelectedTaxAuthID']; -} elseif(isset($_GET['SelectedTaxAuthID'])){ +} elseif(isset($_GET['SelectedTaxAuthID'])) { $SelectedTaxAuthID =$_GET['SelectedTaxAuthID']; } +if(isset($_POST['submit'])) { -if (isset($_POST['submit'])) { - /* actions to take once the user has clicked the submit button ie the page has called itself with some user input */ - if ( trim( $_POST['Description'] ) == '' ) { + if( trim( $_POST['Description'] ) == '' ) { $InputError = 1; prnMsg( _('The tax type description may not be empty'), 'error'); } - if (isset($SelectedTaxAuthID)) { + if(isset($SelectedTaxAuthID)) { /*SelectedTaxAuthID could also exist if submit had not been clicked this code would not run in this case cos submit is false of course see the @@ -48,7 +47,7 @@ $msg = _('The tax authority for record has been updated'); - } elseif ($InputError !=1) { + } elseif($InputError !=1) { /*Selected tax authority is null cos no item selected on first time round so must be adding a record must be submitting new entries in the new tax authority form */ @@ -92,7 +91,7 @@ $InsertResult = DB_query($sql,$db); } //run the SQL from either of the above possibilites - if (isset($InputError) and $InputError !=1) { + if(isset($InputError) and $InputError !=1) { unset( $_POST['TaxGLCode']); unset( $_POST['PurchTaxGLCode']); unset( $_POST['Description']); @@ -101,7 +100,7 @@ prnMsg($msg); -} elseif (isset($_GET['delete'])) { +} elseif(isset($_GET['delete'])) { //the link to delete a selected record was clicked instead of the submit button // PREVENT DELETES IF DEPENDENT RECORDS IN OTHER TABLES @@ -112,7 +111,7 @@ $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ($myrow[0]>0) { + if($myrow[0]>0) { prnmsg(_('Cannot delete this tax authority because there are tax groups defined that use it'),'warn'); } else { /*Cascade deletes in TaxAuthLevels */ @@ -123,7 +122,7 @@ } // end of related records testing } -if (!isset($SelectedTaxAuthID)) { +if(!isset($SelectedTaxAuthID)) { /* It could still be the second time the page has been run and a record has been selected for modification - SelectedTaxAuthID will exist because it was sent with the new call. If its the first time the page has been displayed with no parameters then none of the above are true and the list of tax authorities will be displayed with links to delete or edit each. These will call the same page again and allow update/input or deletion of the records*/ @@ -151,11 +150,12 @@ <th class="ascending" >' . _('Bank Account') . '</th> <th class="ascending" >' . _('Bank Act Type') . '</th> <th class="ascending" >' . _('Bank Swift') . '</th> + <th colspan="4">' . _('Maintenance') . '</th> </tr>'; $k=0; - while ($myrow = DB_fetch_row($result)) { + while($myrow = DB_fetch_row($result)) { - if ($k==1){ + if($k==1) { echo '<tr class="EvenTableRows">'; $k=0; } else { @@ -163,14 +163,14 @@ $k++; } - printf('<td>%s</td> + printf('<td class="number">%s</td> <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> <td>%s</td> <td>%s</td> <td>%s</td> <td>%s</td> - <td>%s</td> - <td>%s</td> <td><a href="%sSelectedTaxAuthID=%s">' . _('Edit') . '</a></td> <td><a href="%sSelectedTaxAuthID=%s&delete=yes" onclick="return confirm(\'' . _('Are you sure you wish to delete this tax authority?') . '\');">' . _('Delete') . '</a></td> <td><a href="%sTaxAuthority=%s">' . _('Edit Rates') . '</a></td> @@ -200,19 +200,19 @@ -if (isset($SelectedTaxAuthID)) { +if(isset($SelectedTaxAuthID)) { echo '<div class="centre"> <a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') .'">' . _('Review all defined tax authority records') . '</a> </div> - <br />'; - } + <br />'; +} echo '<form method="post" action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">'; echo '<div>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; -if (isset($SelectedTaxAuthID)) { +if(isset($SelectedTaxAuthID)) { //editing an existing tax authority $sql = "SELECT taxglcode, @@ -250,7 +250,7 @@ ORDER BY accountcode"; $result = DB_query($SQL,$db); -if (!isset($_POST['Description'])) { +if(!isset($_POST['Description'])) { $_POST['Description']=''; } echo '<table class="selection"> @@ -262,8 +262,8 @@ <td>' . _('Input tax GL Account') . ':</td> <td><select name="PurchTaxGLCode">'; -while ($myrow = DB_fetch_array($result)) { - if (isset($_POST['PurchTaxGLCode']) and $myrow['accountcode']==$_POST['PurchTaxGLCode']) { +while($myrow = DB_fetch_array($result)) { + if(isset($_POST['PurchTaxGLCode']) and $myrow['accountcode']==$_POST['PurchTaxGLCode']) { echo '<option selected="selected" value="'; } else { echo '<option value="'; @@ -281,8 +281,8 @@ <td>' . _('Output tax GL Account') . ':</td> <td><select name="TaxGLCode">'; -while ($myrow = DB_fetch_array($result)) { - if (isset($_POST['TaxGLCode']) and $myrow['accountcode']==$_POST['TaxGLCode']) { +while($myrow = DB_fetch_array($result)) { + if(isset($_POST['TaxGLCode']) and $myrow['accountcode']==$_POST['TaxGLCode']) { echo '<option selected="selected" value="'; } else { echo '<option value="'; @@ -291,16 +291,16 @@ } //end while loop -if (!isset($_POST['Bank'])) { +if(!isset($_POST['Bank'])) { $_POST['Bank']=''; } -if (!isset($_POST['BankAccType'])) { +if(!isset($_POST['BankAccType'])) { $_POST['BankAccType']=''; } -if (!isset($_POST['BankAcc'])) { +if(!isset($_POST['BankAcc'])) { $_POST['BankAcc']=''; } -if (!isset($_POST['BankSwift'])) { +if(!isset($_POST['BankSwift'])) { $_POST['BankSwift']=''; } @@ -328,7 +328,7 @@ <div class="centre"> <input type="submit" name="submit" value="' . _('Enter Information') . '" /> </div> - </div> + </div> </form>'; include('includes/footer.inc'); Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-29 22:33:40 UTC (rev 6856) +++ trunk/doc/Change.log 2014-08-30 15:03:16 UTC (rev 6857) @@ -1,5 +1,6 @@ webERP Change Log +30/8/14 RChacon: In TaxAuthorities.php, adds $ViewTopic and $BookMark, completes table headings, formats number columns to fix sort order, and minor improvements. 30/8/14 Phil: WorkOrderEntry.php didn't handle no item returned from search correctly - fixed. 29/8/14 RChacon: In TaxAuthorityRates.php and TaxCategories.php: adds $ViewTopic and $BookMark; Uses gettext() to translate 'Exempt', 'Freight' and 'Handling'. 29/8/14 Exson: Fixed the StockLocStatus Serial Number link column shift problem. |
From: <rc...@us...> - 2014-08-30 23:06:11
|
Revision: 6858 http://sourceforge.net/p/web-erp/reponame/6858 Author: rchacon Date: 2014-08-30 23:06:07 +0000 (Sat, 30 Aug 2014) Log Message: ----------- Standardizes page_title_text to main-menu-option, standardizes bottom tax-menu, adds $ViewTopic and $BookMark, completes table header columns, formats data columns in Tax* scripts. Modified Paths: -------------- trunk/TaxAuthorities.php trunk/TaxAuthorityRates.php trunk/TaxCategories.php trunk/TaxGroups.php trunk/TaxProvinces.php trunk/doc/Change.log trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po Modified: trunk/TaxAuthorities.php =================================================================== --- trunk/TaxAuthorities.php 2014-08-30 15:03:16 UTC (rev 6857) +++ trunk/TaxAuthorities.php 2014-08-30 23:06:07 UTC (rev 6858) @@ -8,8 +8,8 @@ include('includes/header.inc'); echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . '/images/maintenance.png" title="' . - _('Tax Authorities') . '" />' . ' ' . - _('Tax Authorities') . '</p>'; + _('Tax Authorities Maintenance') . '" />' . ' ' . + _('Tax Authorities Maintenance') . '</p>'; if(isset($_POST['SelectedTaxAuthID'])) { $SelectedTaxAuthID =$_POST['SelectedTaxAuthID']; @@ -143,14 +143,14 @@ echo '<table class="selection"> <tr> <th class="ascending" >' . _('ID') . '</th> - <th class="ascending" >' . _('Description') . '</th> + <th class="ascending" >' . _('Tax Authority') . '</th> <th class="ascending" >' . _('Input Tax') . '<br />' . _('GL Account') . '</th> <th class="ascending" >' . _('Output Tax') . '<br />' . _('GL Account') . '</th> <th class="ascending" >' . _('Bank') . '</th> <th class="ascending" >' . _('Bank Account') . '</th> <th class="ascending" >' . _('Bank Act Type') . '</th> <th class="ascending" >' . _('Bank Swift') . '</th> - <th colspan="4">' . _('Maintenance') . '</th> + <th colspan="4"> </th> </tr>'; $k=0; while($myrow = DB_fetch_row($result)) { @@ -331,6 +331,12 @@ </div> </form>'; +echo '<br /> + <div class="centre"> + <a href="' . $RootPath . '/TaxGroups.php">' . _('Tax Group Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxProvinces.php">' . _('Dispatch Tax Province Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxCategories.php">' . _('Tax Category Maintenance') . '</a> + </div>'; + include('includes/footer.inc'); - ?> Modified: trunk/TaxAuthorityRates.php =================================================================== --- trunk/TaxAuthorityRates.php 2014-08-30 15:03:16 UTC (rev 6857) +++ trunk/TaxAuthorityRates.php 2014-08-30 23:06:07 UTC (rev 6858) @@ -8,8 +8,8 @@ include('includes/header.inc'); echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . '/images/maintenance.png" title="' . - _('Tax Rates') . '" />' . ' ' . - _('Tax Rates') . '</p>'; + _('Tax Rates Maintenance') . '" />' . ' ' . + _('Tax Rates Maintenance') . '</p>'; if(isset($_POST['TaxAuthority'])) { $TaxAuthority = $_POST['TaxAuthority']; @@ -106,25 +106,24 @@ $myrow['dispatchtaxprovince'] . '_' . $myrow['taxcatid'], locale_number_format($myrow['taxrate']*100,2)); }// End of while loop. - echo '</table><br /><div class="centre"> + echo '</table><br /> + <div class="centre"> <input type="submit" name="UpdateRates" value="' . _('Update Rates') . '" />'; -//end if tax taxcatid/rates to show + //end if tax taxcatid/rates to show } else { echo '<div class="centre">'; prnMsg(_('There are no tax rates to show - perhaps the dispatch tax province records have not yet been created?'),'warn'); - } +echo '</div>';// Closes Submit or prnMsg division. -echo ' <br /> - <br /> - <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Tax Authorities') . '</a><br /> - <a href="' . $RootPath . '/TaxGroups.php">' . _('Tax Groupings') . '</a><br /> - <a href="' . $RootPath . '/TaxCategories.php">' . _('Tax Categories') . '</a><br /> - <a href="' . $RootPath . '/TaxProvinces.php">' . _('Dispatch Tax Provinces') . '</a> - </div> - </div> - </form>'; +echo '<br /> + <div class="centre"> + <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Tax Authorities Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxGroups.php">' . _('Tax Group Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxProvinces.php">' . _('Dispatch Tax Province Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxCategories.php">' . _('Tax Category Maintenance') . '</a> + </div>'; -include( 'includes/footer.inc' ); +include('includes/footer.inc'); ?> Modified: trunk/TaxCategories.php =================================================================== --- trunk/TaxCategories.php 2014-08-30 15:03:16 UTC (rev 6857) +++ trunk/TaxCategories.php 2014-08-30 23:06:07 UTC (rev 6858) @@ -8,8 +8,8 @@ include('includes/header.inc'); echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . '/images/maintenance.png" title="' . - _('Tax Categories') . '" />' . ' ' . - _('Tax Categories') . '</p>'; + _('Tax Category Maintenance') . '" />' . ' ' . + _('Tax Category Maintenance') . '</p>'; if( isset($_GET['SelectedTaxCategory']) ) $SelectedTaxCategory = $_GET['SelectedTaxCategory']; @@ -165,8 +165,8 @@ echo '<table class="selection"> <tr> - <th class="ascending">' . _('Tax Categories') . '</th> - <th colspan="2">' . _('Maintenance') . '</th> + <th class="ascending">' . _('Tax Category') . '</th> + <th colspan="2"> </th> </tr>'; $k = 0;// Row counter to determine background colour. @@ -250,5 +250,12 @@ } //end if record deleted no point displaying form to add record +echo '<br /> + <div class="centre"> + <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Tax Authorities and Rates Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxGroups.php">' . _('Tax Group Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxProvinces.php">' . _('Dispatch Tax Province Maintenance') . '</a> + </div>'; + include('includes/footer.inc'); ?> Modified: trunk/TaxGroups.php =================================================================== --- trunk/TaxGroups.php 2014-08-30 15:03:16 UTC (rev 6857) +++ trunk/TaxGroups.php 2014-08-30 23:06:07 UTC (rev 6858) @@ -2,27 +2,30 @@ /* $Id$*/ include('includes/session.inc'); - $Title = _('Tax Groups'); +$ViewTopic = 'Tax';// Filename in ManualContents.php's TOC. +$BookMark = 'TaxGroups';// Anchor's id in the manual's html document. include('includes/header.inc'); +echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . + '/images/maintenance.png" title="' . + _('Tax Group Maintenance') . '" />' . ' ' . + _('Tax Group Maintenance') . '</p>'; -if (isset($_GET['SelectedGroup'])){ +if(isset($_GET['SelectedGroup'])) { $SelectedGroup = $_GET['SelectedGroup']; -} elseif (isset($_POST['SelectedGroup'])){ +} elseif(isset($_POST['SelectedGroup'])) { $SelectedGroup = $_POST['SelectedGroup']; } -echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/maintenance.png" title="' . _('Search') . '" alt="" />' . ' ' . $Title . '</p><br />'; +if(isset($_POST['submit']) OR isset($_GET['remove']) OR isset($_GET['add']) ) { -if (isset($_POST['submit']) OR isset($_GET['remove']) OR isset($_GET['add']) ) { - //initialise no input errors assumed initially before we test $InputError = 0; /* actions to take once the user has clicked the submit button ie the page has called itself with some user input */ //first off validate inputs sensible - if (isset($_POST['GroupName']) AND mb_strlen($_POST['GroupName'])<4){ + if(isset($_POST['GroupName']) AND mb_strlen($_POST['GroupName'])<4) { $InputError = 1; prnMsg(_('The Group description entered must be at least 4 characters long'),'error'); } @@ -30,7 +33,7 @@ // if $_POST['GroupName'] then it is a modification of a tax group name // else it is either an add or remove of taxgroup unset($sql); - if (isset($_POST['GroupName']) ){ // Update or Add a tax group + if(isset($_POST['GroupName']) ) { // Update or Add a tax group if(isset($SelectedGroup)) { // Update a tax group $sql = "UPDATE taxgroups SET taxgroupdescription = '". $_POST['GroupName'] ."' WHERE taxgroupid = '".$SelectedGroup . "'"; @@ -41,7 +44,7 @@ $result = DB_query("SELECT taxgroupid FROM taxgroups WHERE taxgroupdescription='" . $_POST['GroupName'] . "'",$db); - if (DB_num_rows($result)==1){ + if(DB_num_rows($result)==1) { prnMsg( _('A new tax group could not be added because a tax group already exists for') . ' ' . $_POST['GroupName'],'warn'); unset($sql); } else { @@ -53,7 +56,7 @@ } unset($_POST['GroupName']); unset($SelectedGroup); - } elseif (isset($SelectedGroup) ) { + } elseif(isset($SelectedGroup) ) { $TaxAuthority = $_GET['TaxAuthority']; if( isset($_GET['add']) ) { // adding a tax authority to a tax group $sql = "INSERT INTO taxgrouptaxes ( taxgroupid, @@ -65,7 +68,7 @@ $ErrMsg = _('The addition of the tax failed because'); $SuccessMsg = _('The tax was added.'); - } elseif ( isset($_GET['remove']) ) { // remove a taxauthority from a tax group + } elseif( isset($_GET['remove']) ) { // remove a taxauthority from a tax group $sql = "DELETE FROM taxgrouptaxes WHERE taxgroupid = '".$SelectedGroup."' AND taxauthid = '".$TaxAuthority . "'"; @@ -77,20 +80,20 @@ unset($_GET['TaxAuthority']); } // Need to exec the query - if (isset($sql) AND $InputError != 1 ) { + if(isset($sql) AND $InputError != 1 ) { $result = DB_query($sql,$db,$ErrMsg); if( $result ) { prnMsg( $SuccessMsg,'success'); } } -} elseif (isset($_POST['UpdateOrder'])) { +} elseif(isset($_POST['UpdateOrder'])) { //A calculation order update $sql = "SELECT taxauthid FROM taxgrouptaxes WHERE taxgroupid='" . $SelectedGroup . "'"; $Result = DB_query($sql,$db,_('Could not get tax authorities in the selected tax group')); - while ($myrow=DB_fetch_row($Result)){ + while($myrow=DB_fetch_row($Result)) { - if (is_numeric($_POST['CalcOrder_' . $myrow[0]]) AND $_POST['CalcOrder_' . $myrow[0]] <5){ + if(is_numeric($_POST['CalcOrder_' . $myrow[0]]) AND $_POST['CalcOrder_' . $myrow[0]] <5) { $sql = "UPDATE taxgrouptaxes SET calculationorder='" . $_POST['CalcOrder_' . $myrow[0]] . "', @@ -111,23 +114,22 @@ $Result = DB_query($sql,$db,_('Could not get tax authorities in the selected tax group')); - if (DB_num_rows($Result)>0){ + if(DB_num_rows($Result)>0) { $myrow=DB_fetch_array($Result); - if ($myrow['taxontax']==1){ + if($myrow['taxontax']==1) { prnMsg(_('It is inappropriate to set tax on tax where the tax is the first in the calculation order. The system has changed it back to no tax on tax for this tax authority'),'warning'); $Result = DB_query("UPDATE taxgrouptaxes SET taxontax=0 WHERE taxgroupid='" . $SelectedGroup . "' AND taxauthid='" . $myrow['taxauthid'] . "'",$db); } } -} elseif (isset($_GET['Delete'])) { +} elseif(isset($_GET['Delete'])) { /* PREVENT DELETES IF DEPENDENT RECORDS IN 'custbranch, suppliers */ - $sql= "SELECT COUNT(*) FROM custbranch WHERE taxgroupid='" . $_GET['SelectedGroup'] . "'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ($myrow[0]>0) { + if($myrow[0]>0) { prnMsg( _('Cannot delete this tax group because some customer branches are setup using it'),'warn'); echo '<br />' . _('There are') . ' ' . $myrow[0] . ' ' . _('customer branches referring to this tax group'); } else { @@ -135,7 +137,7 @@ WHERE taxgroupid='" . $_GET['SelectedGroup'] . "'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ($myrow[0]>0) { + if($myrow[0]>0) { prnMsg( _('Cannot delete this tax group because some suppliers are setup using it'),'warn'); echo '<br />' . _('There are') . ' ' . $myrow[0] . ' ' . _('suppliers referring to this tax group'); } else { @@ -153,7 +155,7 @@ unset($_GET['GroupName']); } -if (!isset($SelectedGroup)) { +if(!isset($SelectedGroup)) { /* If its the first time the page has been displayed with no parameters then none of the above are true and the list of tax groups will be displayed with links to delete or edit each. These will call the same page again and allow update/input or deletion of tax group taxes*/ @@ -171,11 +173,12 @@ <tr> <th class="ascending" >' . _('Group No') . '</th> <th class="ascending" >' . _('Tax Group') . '</th> + <th colspan="2" > </th> </tr>'; $k=0; //row colour counter - while ($myrow = DB_fetch_array($result)) { - if ($k==1){ + while($myrow = DB_fetch_array($result)) { + if($k==1) { echo '<tr class="EvenTableRows">'; $k=0; } else { @@ -183,7 +186,7 @@ $k=1; } - printf('<td>%s</td> + printf('<td class="number">%s</td> <td>%s</td> <td><a href="%s&SelectedGroup=%s">' . _('Edit') . '</a></td> <td><a href="%s&SelectedGroup=%s&Delete=1&GroupID=%s" onclick="return confirm(\'' . _('Are you sure you wish to delete this tax group?') . '\');">' . _('Delete') . '</a></td> @@ -201,14 +204,13 @@ } } //end of ifs and buts! - -if (isset($SelectedGroup)) { +if(isset($SelectedGroup)) { echo '<div class="centre"> <a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">' . _('Review Existing Groups') . '</a> </div>'; } -if (isset($SelectedGroup)) { +if(isset($SelectedGroup)) { //editing an existing role $sql = "SELECT taxgroupid, @@ -216,7 +218,7 @@ FROM taxgroups WHERE taxgroupid='" . $SelectedGroup . "'"; $result = DB_query($sql, $db); - if ( DB_num_rows($result) == 0 ) { + if( DB_num_rows($result) == 0 ) { prnMsg( _('The selected tax group is no longer available.'),'warn'); } else { $myrow = DB_fetch_array($result); @@ -233,11 +235,11 @@ } echo '<table class="selection">'; -if (!isset($_POST['GroupName'])) { +if(!isset($_POST['GroupName'])) { $_POST['GroupName']=''; } echo '<tr><td>' . _('Tax Group') . ':</td> - <td><input pattern="(?!^ +$)[^><+-]{4,}" title="'._('The group name must be more 4 and less than 40 characters and cannot be left blank').'" placeholder="'._('4 to 40 legal characters').'" type="text" name="GroupName" size="40" maxlength="40" value="' . $_POST['GroupName'] . '" /></td>'; + <td><input pattern="(?!^ +$)[^><+-] {4,}" title="'._('The group name must be more 4 and less than 40 characters and cannot be left blank').'" placeholder="'._('4 to 40 legal characters').'" type="text" name="GroupName" size="40" maxlength="40" value="' . $_POST['GroupName'] . '" /></td>'; echo '<td><input type="submit" name="submit" value="' . _('Enter Group') . '" /></td> </tr> </table> @@ -245,9 +247,7 @@ </div> </form>'; - -if (isset($SelectedGroup)) { - +if(isset($SelectedGroup)) { $sql = "SELECT taxid, description as taxname FROM taxauthorities @@ -269,14 +269,14 @@ $TaxAuthsUsed = array(); //this array just holds the taxauthid of all authorities in the group $TaxAuthRow = array(); //this array holds all the details of the tax authorities in the group $i=1; - while ($myrow=DB_fetch_array($UsedResult)){ + while($myrow=DB_fetch_array($UsedResult)) { $TaxAuthsUsed[$i] = $myrow['taxauthid']; $TaxAuthRow[$i] = $myrow; $i++; } /* the order and tax on tax will only be an issue if more than one tax authority in the group */ - if (count($TaxAuthsUsed)>0) { + if(count($TaxAuthsUsed)>0) { echo '<form method="post" action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">'; echo '<div>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" /> @@ -292,7 +292,7 @@ </tr>'; $k=0; //row colour counter for ($i=1;$i < count($TaxAuthRow)+1;$i++) { - if ($k==1){ + if($k==1) { echo '<tr class="OddTableRows">'; $k=0; } else { @@ -300,14 +300,14 @@ $k=1; } - if ($TaxAuthRow[$i]['calculationorder']==0){ + if($TaxAuthRow[$i]['calculationorder']==0) { $TaxAuthRow[$i]['calculationorder'] = $i; } echo '<td>' . $TaxAuthRow[$i]['taxname'] . '</td> - <td><input type="text" class="integer" pattern="[1-4]{1}" title="'._('The input must be positive integer and less than 5').'" name="CalcOrder_' . $TaxAuthRow[$i]['taxauthid'] . '" value="' . $TaxAuthRow[$i]['calculationorder'] . '" size="2" maxlength="2" style="width: 100%" /></td> + <td><input type="text" class="integer" pattern="[1-4] {1}" title="'._('The input must be positive integer and less than 5').'" name="CalcOrder_' . $TaxAuthRow[$i]['taxauthid'] . '" value="' . $TaxAuthRow[$i]['calculationorder'] . '" size="2" maxlength="2" style="width: 100%" /></td> <td><select name="TaxOnTax_' . $TaxAuthRow[$i]['taxauthid'] . '" style="width: 100%">'; - if ($TaxAuthRow[$i]['taxontax']==1){ + if($TaxAuthRow[$i]['taxontax']==1) { echo '<option selected="selected" value="1">' . _('Yes') . '</option>'; echo '<option value="0">' . _('No') . '</option>'; } else { @@ -324,61 +324,57 @@ <input type="submit" name="UpdateOrder" value="' . _('Update Order') . '" /> </div>'; } + echo '</div></form>'; - echo '</div> - </form>'; + if(DB_num_rows($Result)>0 ) { + echo '<br /><table class="selection"> + <tr> + <th colspan="4">' . _('Assigned Taxes') . '</th> + <th rowspan="2"> </th> + <th colspan="2">' . _('Available Taxes') . '</th> + </tr> + <tr> + <th>' . _('Tax Auth ID') . '</th> + <th>' . _('Tax Authority Name') . '</th> + <th>' . _('Calculation Order') . '</th> + <th>' . _('Tax on Prior Tax(es)') . '</th> + <th>' . _('Tax Auth ID') . '</th> + <th>' . _('Tax Authority Name') . '</th> + </tr>'; - if (DB_num_rows($Result)>0 ) { - echo '<br />'; - echo '<table class="selection"> - <tr> - <th colspan="4">' . _('Assigned Taxes') . '</th> - <th></th> - <th colspan="2">' . _('Available Taxes') . '</th> - </tr> - <tr> - <th>' . _('Tax Auth ID') . '</th> - <th>' . _('Tax Authority Name') . '</th> - <th>' . _('Calculation Order') . '</th> - <th>' . _('Tax on Prior Tax(es)') . '</th> - <th></th> - <th>' . _('Tax Auth ID') . '</th> - <th>' . _('Tax Authority Name') . '</th> - </tr>'; - } else { - echo '<br /> - <div class="centre">' . - _('There are no tax authorities defined to allocate to this tax group').' - </div>'; + echo '<br /><div class="centre">' . + _('There are no tax authorities defined to allocate to this tax group') . + '</div>'; } $k=0; //row colour counter while($AvailRow = DB_fetch_array($Result)) { - - if ($k==1){ + if($k==1) { echo '<tr class="EvenTableRows">'; $k=0; } else { echo '<tr class="OddTableRows">'; $k=1; } + $TaxAuthUsedPointer = array_search($AvailRow['taxid'],$TaxAuthsUsed); - if ($TaxAuthUsedPointer){ - - if ($TaxAuthRow[$TaxAuthUsedPointer]['taxontax'] ==1){ + if($TaxAuthUsedPointer) { + if($TaxAuthRow[$TaxAuthUsedPointer]['taxontax'] ==1) { $TaxOnTax = _('Yes'); } else { $TaxOnTax = _('No'); } - printf('<td>%s</td> + printf(' + <td class="number">%s</td> <td>%s</td> + <td class="number">%s</td> <td>%s</td> - <td>%s</td> - <td><a href="%sSelectedGroup=%s&remove=1&TaxAuthority=%s" onclick="return confirm(\'' . _('Are you sure you wish to remove this tax authority from the group?') . '\');">' . _('Remove') . '</a></td> - <td> </td> + <td class="centre"><a href="%sSelectedGroup=%s&remove=1&TaxAuthority=%s" onclick="return confirm(\'' . + _('Are you sure you wish to remove this tax authority from the group?') . '\');">' . _('Remove') . '</a></td> + <td class="number"> </td> <td> </td>', $AvailRow['taxid'], $AvailRow['taxname'], @@ -390,26 +386,32 @@ ); } else { - printf('<td> </td> + printf(' + <td class="number"> </td> <td> </td> + <td class="number"> </td> <td> </td> - <td> </td> - <td> </td> - <td>%s</td> - <td>%s</td> - <td><a href="%sSelectedGroup=%s&add=1&TaxAuthority=%s">' . _('Add') . '</a></td>', - $AvailRow['taxid'], - $AvailRow['taxname'], + <td class="centre"><a href="%sSelectedGroup=%s&add=1&TaxAuthority=%s">' . + _('Add') . '</a></td> + <td class="number">%s</td> + <td>%s</td>', htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?', $SelectedGroup, - $AvailRow['taxid'] ); + $AvailRow['taxid'], + $AvailRow['taxid'], + $AvailRow['taxname']); } echo '</tr>'; } echo '</table>'; - } +echo '<br /> + <div class="centre"> + <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Tax Authorities and Rates Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxProvinces.php">' . _('Dispatch Tax Province Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxCategories.php">' . _('Tax Category Maintenance') . '</a> + </div>'; + include('includes/footer.inc'); - ?> Modified: trunk/TaxProvinces.php =================================================================== --- trunk/TaxProvinces.php 2014-08-30 15:03:16 UTC (rev 6857) +++ trunk/TaxProvinces.php 2014-08-30 23:06:07 UTC (rev 6858) @@ -2,21 +2,21 @@ /* $Id$*/ include('includes/session.inc'); - $Title = _('Dispatch Tax Provinces'); - +$ViewTopic = 'Tax';// Filename in ManualContents.php's TOC. +$BookMark = 'TaxProvinces';// Anchor's id in the manual's html document. include('includes/header.inc'); +echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . + '/images/maintenance.png" title="' . + _('Dispatch Tax Province Maintenance') . '" />' . ' ' . + _('Dispatch Tax Province Maintenance') . '</p>'; -echo '<p class="page_title_text"> - <img src="'.$RootPath.'/css/'.$Theme.'/images/maintenance.png" title="' . _('Search') . '" alt="" />' . ' ' . $Title.' - </p>'; - -if ( isset($_GET['SelectedTaxProvince']) ) +if( isset($_GET['SelectedTaxProvince']) ) $SelectedTaxProvince = $_GET['SelectedTaxProvince']; -elseif (isset($_POST['SelectedTaxProvince'])) +elseif(isset($_POST['SelectedTaxProvince'])) $SelectedTaxProvince = $_POST['SelectedTaxProvince']; -if (isset($_POST['submit'])) { +if(isset($_POST['submit'])) { //initialise no input errors assumed initially before we test @@ -27,16 +27,16 @@ //first off validate inputs sensible - if (ContainsIllegalCharacters($_POST['TaxProvinceName'])) { + if(ContainsIllegalCharacters($_POST['TaxProvinceName'])) { $InputError = 1; prnMsg( _('The tax province name cannot contain any of the illegal characters'),'error'); } - if (trim($_POST['TaxProvinceName']) == '') { + if(trim($_POST['TaxProvinceName']) == '') { $InputError = 1; prnMsg( _('The tax province name may not be empty'), 'error'); } - if ($_POST['SelectedTaxProvince']!='' AND $InputError !=1) { + if($_POST['SelectedTaxProvince']!='' AND $InputError !=1) { /*SelectedTaxProvince could also exist if submit had not been clicked this code would not run in this case cos submit is false of course see the delete code below*/ // Check the name does not clash @@ -45,7 +45,7 @@ AND taxprovincename " . LIKE . " '" . $_POST['TaxProvinceName'] . "'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ( $myrow[0] > 0 ) { + if( $myrow[0] > 0 ) { $InputError = 1; prnMsg( _('The tax province cannot be renamed because another with the same name already exists.'),'error'); } else { @@ -53,7 +53,7 @@ $sql = "SELECT taxprovincename FROM taxprovinces WHERE taxprovinceid = '" . $SelectedTaxProvince . "'"; $result = DB_query($sql,$db); - if ( DB_num_rows($result) != 0 ) { + if( DB_num_rows($result) != 0 ) { // This is probably the safest way there is $myrow = DB_fetch_row($result); $OldTaxProvinceName = $myrow[0]; @@ -62,7 +62,7 @@ WHERE taxprovincename ".LIKE." '".$OldTaxProvinceName."'"; $ErrMsg = _('Could not update tax province'); $result = DB_query($sql,$db, $ErrMsg); - if (!$result){ + if(!$result) { prnMsg(_('Tax province name changed'),'success'); } } else { @@ -70,14 +70,14 @@ prnMsg( _('The tax province no longer exists'),'error'); } } - } elseif ($InputError !=1) { + } elseif($InputError !=1) { /*SelectedTaxProvince is null cos no item selected on first time round so must be adding a record*/ $sql = "SELECT count(*) FROM taxprovinces WHERE taxprovincename " .LIKE. " '".$_POST['TaxProvinceName'] ."'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ( $myrow[0] > 0 ) { + if( $myrow[0] > 0 ) { $InputError = 1; prnMsg( _('The tax province cannot be created because another with the same name already exists'),'error'); @@ -98,7 +98,7 @@ $result = DB_query($sql,$db, $ErrMsg); } - if (!$result){ + if(!$result) { prnMsg(_('Errors were encountered adding this tax province'),'error'); } else { prnMsg(_('New tax province added'),'success'); @@ -108,14 +108,14 @@ unset ($_POST['SelectedTaxProvince']); unset ($_POST['TaxProvinceName']); -} elseif (isset($_GET['delete'])) { +} elseif(isset($_GET['delete'])) { //the link to delete a selected record was clicked instead of the submit button // PREVENT DELETES IF DEPENDENT RECORDS IN 'stockmaster' // Get the original name of the tax province the ID is just a secure way to find the tax province $sql = "SELECT taxprovincename FROM taxprovinces WHERE taxprovinceid = '" . $SelectedTaxProvince . "'"; $result = DB_query($sql,$db); - if ( DB_num_rows($result) == 0 ) { + if( DB_num_rows($result) == 0 ) { // This is probably the safest way there is prnMsg( _('Cannot delete this tax province because it no longer exists'),'warn'); } else { @@ -124,7 +124,7 @@ $sql= "SELECT COUNT(*) FROM locations WHERE taxprovinceid = '" . $SelectedTaxProvince . "'"; $result = DB_query($sql,$db); $myrow = DB_fetch_row($result); - if ($myrow[0]>0) { + if($myrow[0]>0) { prnMsg( _('Cannot delete this tax province because at least one stock location is defined to be inside this province'),'warn'); echo '<br />' . _('There are') . ' ' . $myrow[0] . ' ' . _('stock locations that refer to this tax province') . '</font>'; } else { @@ -142,15 +142,15 @@ unset ($_POST['TaxProvinceName']); } - if (!isset($SelectedTaxProvince)) { +if(!isset($SelectedTaxProvince)) { /* An tax province could be posted when one has been edited and is being updated - or GOT when selected for modification - SelectedTaxProvince will exist because it was sent with the page in a GET . - If its the first time the page has been displayed with no parameters - then none of the above are true and the list of account groups will be displayed with - links to delete or edit each. These will call the same page again and allow update/input - or deletion of the records*/ +or GOT when selected for modification +SelectedTaxProvince will exist because it was sent with the page in a GET . +If its the first time the page has been displayed with no parameters +then none of the above are true and the list of account groups will be displayed with +links to delete or edit each. These will call the same page again and allow update/input +or deletion of the records*/ $sql = "SELECT taxprovinceid, taxprovincename @@ -162,13 +162,14 @@ echo '<table class="selection"> <tr> - <th class="ascending">' . _('Tax Provinces') . '</th> + <th class="ascending">' . _('Tax Province') . '</th> + <th colspan="2"> </th> </tr>'; $k=0; //row colour counter - while ($myrow = DB_fetch_row($result)) { + while($myrow = DB_fetch_row($result)) { - if ($k==1){ + if($k==1) { echo '<tr class="EvenTableRows">'; $k=0; } else { @@ -186,20 +187,20 @@ } //end of ifs and buts! -if (isset($SelectedTaxProvince)) { +if(isset($SelectedTaxProvince)) { echo '<div class="centre"> <a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">' . _('Review Tax Provinces') . '</a> </div> - <br />'; +<br />'; } -if (! isset($_GET['delete'])) { +if(! isset($_GET['delete'])) { echo '<form method="post" action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">'; - echo '<div>'; +echo '<div>'; echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; - if (isset($SelectedTaxProvince)) { + if(isset($SelectedTaxProvince)) { //editing an existing section $sql = "SELECT taxprovinceid, @@ -208,7 +209,7 @@ WHERE taxprovinceid='" . $SelectedTaxProvince . "'"; $result = DB_query($sql, $db); - if ( DB_num_rows($result) == 0 ) { + if( DB_num_rows($result) == 0 ) { prnMsg( _('Could not retrieve the requested tax province, please try again.'),'warn'); unset($SelectedTaxProvince); } else { @@ -236,17 +237,15 @@ </div>'; echo '</div> - </form>'; +</form>'; } //end if record deleted no point displaying form to add record -echo '<div class="centre"> - <br /> - <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Edit/Review Tax Authorities') . '</a> - <br /> - <a href="' . $RootPath . '/TaxGroups.php">' . _('Edit/Review Tax Groupings') . '</a> - <br /> - <a href="' . $RootPath . '/TaxCategories.php">' . _('Edit/Review Tax Categories') . '</a> +echo '<br /> + <div class="centre"> + <a href="' . $RootPath . '/TaxAuthorities.php">' . _('Tax Authorities and Rates Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxGroups.php">' . _('Tax Group Maintenance') . '</a><br /> + <a href="' . $RootPath . '/TaxCategories.php">' . _('Tax Category Maintenance') . '</a> </div>'; include('includes/footer.inc'); Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-30 15:03:16 UTC (rev 6857) +++ trunk/doc/Change.log 2014-08-30 23:06:07 UTC (rev 6858) @@ -1,5 +1,6 @@ webERP Change Log +31/8/14 RChacon: Standardizes page_title_text to main-menu-option, standardizes bottom tax-menu, adds $ViewTopic and $BookMark, completes table header columns, formats data columns in Tax* scripts. 30/8/14 RChacon: In TaxAuthorities.php, adds $ViewTopic and $BookMark, completes table headings, formats number columns to fix sort order, and minor improvements. 30/8/14 Phil: WorkOrderEntry.php didn't handle no item returned from search correctly - fixed. 29/8/14 RChacon: In TaxAuthorityRates.php and TaxCategories.php: adds $ViewTopic and $BookMark; Uses gettext() to translate 'Exempt', 'Freight' and 'Handling'. Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-30 15:03:16 UTC (rev 6857) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-30 23:06:07 UTC (rev 6858) @@ -8,7 +8,7 @@ "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2014-08-29 11:25-0600\n" -"PO-Revision-Date: 2014-08-29 11:35-0600\n" +"PO-Revision-Date: 2014-08-30 16:53-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -8788,7 +8788,7 @@ #: CustomerBranches.php:415 CustomerBranches.php:866 SupplierCredit.php:265 #: Suppliers.php:840 Suppliers.php:1094 TaxGroups.php:173 TaxGroups.php:239 msgid "Tax Group" -msgstr "Grupo de Impuestos" +msgstr "Grupo de impuestos" #: CustomerBranches.php:416 msgid "Enabled?" @@ -16527,7 +16527,7 @@ #: Locations.php:400 Locations.php:620 TaxAuthorityRates.php:87 msgid "Tax Province" -msgstr "Jurisdicción Fiscal" +msgstr "Jurisdicción fiscal" #: Locations.php:423 #, php-format @@ -35888,7 +35888,7 @@ #: TaxAuthorityRates.php:138 TaxCategories.php:6 TaxCategories.php:167 msgid "Tax Categories" -msgstr "Clases de Impuestos" +msgstr "Clases de impuestos" #: TaxAuthorityRates.php:140 TaxProvinces.php:6 msgid "Dispatch Tax Provinces" |
From: <rc...@us...> - 2014-09-01 00:00:49
|
Revision: 6859 http://sourceforge.net/p/web-erp/reponame/6859 Author: rchacon Date: 2014-09-01 00:00:37 +0000 (Mon, 01 Sep 2014) Log Message: ----------- In general: Replaces code to determine background colour with TableRows(). Adds comments to ManualNewScripts.html. Fixes manual.css format. In GLTransInquiry.php: Adds $ViewTopic and $BookMark and sorts columns, and minor improvements. Minor translation improvements. Modified Paths: -------------- trunk/GLTransInquiry.php trunk/TaxAuthorities.php trunk/TaxAuthorityRates.php trunk/TaxCategories.php trunk/TaxGroups.php trunk/TaxProvinces.php trunk/doc/Change.log trunk/doc/Manual/ManualNewScripts.html trunk/doc/Manual/style/manual.css trunk/includes/MiscFunctions.php trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.mo trunk/locale/fr_FR.utf8/LC_MESSAGES/messages.po Modified: trunk/GLTransInquiry.php =================================================================== --- trunk/GLTransInquiry.php 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/GLTransInquiry.php 2014-09-01 00:00:37 UTC (rev 6859) @@ -1,14 +1,15 @@ <?php - /* $Id$*/ include ('includes/session.inc'); $Title = _('General Ledger Transaction Inquiry'); +$ViewTopic = 'GeneralLedger';// Filename in ManualContents.php's TOC. +$BookMark = 'GLTransInquiry';// Anchor's id in the manual's html document. include('includes/header.inc'); $MenuURL = '<div><a href="'. $RootPath . '/index.php?&Application=GL">' . _('General Ledger Menu') . '</a></div>'; -if ( !isset($_GET['TypeID']) OR !isset($_GET['TransNo']) ) { +if( !isset($_GET['TypeID']) OR !isset($_GET['TransNo']) ) { prnMsg(_('This page requires a valid transaction type and number'),'warn'); echo $MenuURL; } else { @@ -19,7 +20,7 @@ $TypeResult = DB_query($typeSQL,$db); - if ( DB_num_rows($TypeResult) == 0 ){ + if( DB_num_rows($TypeResult) == 0 ) { prnMsg(_('No transaction of this type with id') . ' ' . $_GET['TypeID'],'error'); echo $MenuURL; } else { @@ -32,62 +33,66 @@ // //========[ SHOW SYNOPSYS ]=========== // - echo '<p class="page_title_text"><img src="'.$RootPath.'/css/' . $Theme . '/images/magnifier.png" title="' - . _('Print') . '" alt="" />' . ' ' . $Title . '</p>'; + echo '<p class="page_title_text"><img alt="" src="' . $RootPath . '/css/' . $Theme . + '/images/magnifier.png" title="' . + _('General Ledger Transaction Inquiry') . '" />' . ' ' . + _('General Ledger Transaction Inquiry') . '</p>'; + echo '<table class="selection">'; //Main table echo '<tr> <th colspan="7"><h2><b>' . _($TransName) . ' ' . $_GET['TransNo'] . '</b></h2></th> </tr> <tr> + <th>' . _('Period') . '</th> <th>' . _('Date') . '</th> - <th>' . _('Period') . '</th> - <th>' . _('GL Account') . '</th> - <th>' . _('Debits') . '</th> - <th>' . _('Credits') . '</th> - <th>' . _('Description') . '</th> - <th>' . _('Posted') . '</th> + <th>' . _('GL Account') . '</th> + <th>' . _('Description') . '</th> + <th>' . _('Debits') . '</th> + <th>' . _('Credits') . '</th> + <th>' . _('Posted') . '</th> </tr>'; - $SQL = "SELECT gltrans.type, - gltrans.trandate, - gltrans.periodno, - gltrans.account, - gltrans.narrative, - gltrans.amount, - gltrans.posted, - chartmaster.accountname, - periods.lastdate_in_period - FROM gltrans INNER JOIN chartmaster - ON gltrans.account = chartmaster.accountcode - INNER JOIN periods - ON periods.periodno=gltrans.periodno - WHERE gltrans.type= '" . $_GET['TypeID'] . "' - AND gltrans.typeno = '" . $_GET['TransNo'] . "' - ORDER BY gltrans.counterindex"; + $SQL = "SELECT + gltrans.periodno, + gltrans.trandate, + gltrans.type, + gltrans.account, + chartmaster.accountname, + gltrans.narrative, + gltrans.amount, + gltrans.posted, + periods.lastdate_in_period + FROM gltrans INNER JOIN chartmaster + ON gltrans.account = chartmaster.accountcode + INNER JOIN periods + ON periods.periodno=gltrans.periodno + WHERE gltrans.type= '" . $_GET['TypeID'] . "' + AND gltrans.typeno = '" . $_GET['TransNo'] . "' + ORDER BY gltrans.counterindex"; $TransResult = DB_query($SQL,$db); $Posted = _('Yes'); $CreditTotal = 0; $DebitTotal = 0; $AnalysisCompleted = 'Not Yet'; - $j=1; - while ( $TransRow = DB_fetch_array($TransResult) ) { + $k = False;// Row counter to determine background colour. + while( $TransRow = DB_fetch_array($TransResult) ) { $TranDate = ConvertSQLDate($TransRow['trandate']); $DetailResult = false; - if ( $TransRow['amount'] > 0) { - $DebitAmount = locale_number_format($TransRow['amount'],$_SESSION['CompanyRecord']['decimalplaces']); - $DebitTotal += $TransRow['amount']; - $CreditAmount = ' '; + if( $TransRow['amount'] > 0) { + $DebitAmount = locale_number_format($TransRow['amount'],$_SESSION['CompanyRecord']['decimalplaces']); + $DebitTotal += $TransRow['amount']; + $CreditAmount = ' '; } else { - $CreditAmount = locale_number_format(-$TransRow['amount'],$_SESSION['CompanyRecord']['decimalplaces']); - $CreditTotal += $TransRow['amount']; - $DebitAmount = ' '; + $CreditAmount = locale_number_format(-$TransRow['amount'],$_SESSION['CompanyRecord']['decimalplaces']); + $CreditTotal += $TransRow['amount']; + $DebitAmount = ' '; } - if ( $TransRow['posted']==0 ){ + if( $TransRow['posted']==0 ) { $Posted = _('No'); } - if ( $TransRow['account'] == $_SESSION['CompanyRecord']['debtorsact'] AND $AnalysisCompleted == 'Not Yet') { + if( $TransRow['account'] == $_SESSION['CompanyRecord']['debtorsact'] AND $AnalysisCompleted == 'Not Yet') { $URL = $RootPath . '/CustomerInquiry.php?CustomerID='; $FromDate = '&TransAfterDate=' . $TranDate; @@ -103,7 +108,7 @@ AND debtortrans.transno = '" . $_GET['TransNo']. "'"; $DetailResult = DB_query($DetailSQL,$db); - } elseif ( $TransRow['account'] == $_SESSION['CompanyRecord']['creditorsact'] AND $AnalysisCompleted == 'Not Yet' ) { + } elseif( $TransRow['account'] == $_SESSION['CompanyRecord']['creditorsact'] AND $AnalysisCompleted == 'Not Yet' ) { $URL = $RootPath . '/SupplierInquiry.php?SupplierID='; $FromDate = '&FromDate=' . $TranDate; @@ -124,29 +129,23 @@ if( mb_strlen($TransRow['narrative'])==0 ) { $TransRow['narrative'] = ' '; } - - if ($j==1) { - echo '<tr class="OddTableRows">'; - $j=0; - } else { - echo '<tr class="EvenTableRows">'; - $j++; - } - echo '<td>' . $TranDate . '</td> - <td>' . MonthAndYearFromSQLDate($TransRow['lastdate_in_period']) . '</td> - <td><a href="' . $URL . '">' . $TransRow['accountname'] . '</a></td> - <td class="number">' . $DebitAmount . '</td> - <td class="number">' . $CreditAmount . '</td> - <td>' . $TransRow['narrative'] . '</td> - <td>' . $Posted . '</td> - </tr>'; + + $k = TableRows($k);// Outputs html table row with class (Odd|Even). + echo ' <td>' . MonthAndYearFromSQLDate($TransRow['lastdate_in_period']) . '</td> + <td>' . $TranDate . '</td> + <td><a href="' . $URL . '">' . $TransRow['accountname'] . '</a></td> + <td>' . $TransRow['narrative'] . '</td> + <td class="number">' . $DebitAmount . '</td> + <td class="number">' . $CreditAmount . '</td> + <td>' . $Posted . '</td> + </tr>'; } - if ($DetailResult AND $AnalysisCompleted == 'Not Yet') { + if($DetailResult AND $AnalysisCompleted == 'Not Yet') { - while ( $DetailRow = DB_fetch_array($DetailResult) ) { - if ( $TransRow['amount'] > 0){ - if ($TransRow['account'] == $_SESSION['CompanyRecord']['debtorsact']) { + while( $DetailRow = DB_fetch_array($DetailResult) ) { + if( $TransRow['amount'] > 0) { + if($TransRow['account'] == $_SESSION['CompanyRecord']['debtorsact']) { $Debit = locale_number_format(($DetailRow['ovamount'] + $DetailRow['ovgst']+ $DetailRow['ovfreight']) / $DetailRow['rate'],$_SESSION['CompanyRecord']['decimalplaces']); $Credit = ' '; } else { @@ -154,7 +153,7 @@ $Credit = ' '; } } else { - if ($TransRow['account'] == $_SESSION['CompanyRecord']['debtorsact']) { + if($TransRow['account'] == $_SESSION['CompanyRecord']['debtorsact']) { $Credit = locale_number_format(-($DetailRow['ovamount'] + $DetailRow['ovgst'] + $DetailRow['ovfreight']) / $DetailRow['rate'],$_SESSION['CompanyRecord']['decimalplaces']); $Debit = ' '; } else { @@ -162,22 +161,17 @@ $Debit = ' '; } } - - if ($j==1) { - echo '<tr class="OddTableRows">'; - $j=0; - } else { - echo '<tr class="EvenTableRows">'; - $j++; - } - echo '<td>' . $TranDate . '</td> - <td>' . MonthAndYearFromSQLDate($TransRow['lastdate_in_period']) . '</td> - <td><a href="' . $URL . $DetailRow['otherpartycode'] . $FromDate . '">' . $TransRow['accountname'] . ' - ' . $DetailRow['otherparty'] . '</a></td> - <td class="number">' . $Debit . '</td> - <td class="number">' . $Credit . '</td> - <td>' . $TransRow['narrative'] . '</td> - <td>' . $Posted . '</td> - </tr>'; + + $k = TableRows($k);// Outputs html table row with class (Odd|Even). + echo ' <td>' . MonthAndYearFromSQLDate($TransRow['lastdate_in_period']) . '</td> + <td>' . $TranDate . '</td> + <td><a href="' . $URL . $DetailRow['otherpartycode'] . $FromDate . '">' . + $TransRow['accountname'] . ' - ' . $DetailRow['otherparty'] . '</a></td> + <td>' . $TransRow['narrative'] . '</td> + <td class="number">' . $Debit . '</td> + <td class="number">' . $Credit . '</td> + <td>' . $Posted . '</td> + </tr>'; } DB_free_result($DetailResult); $AnalysisCompleted = 'Done'; @@ -186,12 +180,14 @@ DB_free_result($TransResult); echo '<tr style="background-color:#FFFFFF"> - <td class="number" colspan="3"><b>' . _('Total') . '</b></td> - <td class="number">' . locale_number_format(($DebitTotal),$_SESSION['CompanyRecord']['decimalplaces']) . '</td> - <td class="number">' . locale_number_format((-$CreditTotal),$_SESSION['CompanyRecord']['decimalplaces']) . '</td> - <td colspan="2"> </td> - </tr>'; - echo '</table>'; + <td class="number" colspan="4"><b>' . _('Total') . '</b></td> + <td class="number"><b>' . + locale_number_format(($DebitTotal),$_SESSION['CompanyRecord']['decimalplaces']) . '</b></td> + <td class="number"><b>' . + locale_number_format((-$CreditTotal),$_SESSION['CompanyRecord']['decimalplaces']) . '</b></td> + <td> </td> + </tr> + </table>'; } } Modified: trunk/TaxAuthorities.php =================================================================== --- trunk/TaxAuthorities.php 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/TaxAuthorities.php 2014-09-01 00:00:37 UTC (rev 6859) @@ -152,17 +152,9 @@ <th class="ascending" >' . _('Bank Swift') . '</th> <th colspan="4"> </th> </tr>'; - $k=0; + $k = False;// Row counter to determine background colour. while($myrow = DB_fetch_row($result)) { - - if($k==1) { - echo '<tr class="EvenTableRows">'; - $k=0; - } else { - echo '<tr class="OddTableRows">'; - $k++; - } - + $k = TableRows($k);// Outputs html table row with class (Odd|Even). printf('<td class="number">%s</td> <td>%s</td> <td class="number">%s</td> Modified: trunk/TaxAuthorityRates.php =================================================================== --- trunk/TaxAuthorityRates.php 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/TaxAuthorityRates.php 2014-09-01 00:00:37 UTC (rev 6859) @@ -82,17 +82,10 @@ <th class="ascending">' . _('Deliveries From') . '<br />' . _('Tax Province') . '</th> <th class="ascending">' . _('Tax Category') . '</th> <th class="ascending">' . _('Tax Rate') . '</th></tr>'; - $j = 1; - $k = 0;// Row counter to determine background colour. + $k = False;// Row counter to determine background colour. while($myrow = DB_fetch_array($TaxRatesResult)) { - if($k==1) { - echo '<tr class="EvenTableRows">'; - $k = 0; - } else { - echo '<tr class="OddTableRows">'; - $k = 1; - } + $k = TableRows($k);// Outputs html table row with class (Odd|Even). printf(' <td>%s</td> <td>%s</td> Modified: trunk/TaxCategories.php =================================================================== --- trunk/TaxCategories.php 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/TaxCategories.php 2014-09-01 00:00:37 UTC (rev 6859) @@ -169,15 +169,9 @@ <th colspan="2"> </th> </tr>'; - $k = 0;// Row counter to determine background colour. + $k = False;// Row counter to determine background colour. while($myrow = DB_fetch_row($result)) { - if($k==1) { - echo '<tr class="EvenTableRows">'; - $k = 0; - } else { - echo '<tr class="OddTableRows">'; - $k ++; - } + $k = TableRows($k);// Outputs html table row with class (Odd|Even). if($myrow[1]!='Freight') { // Uses gettext() to translate 'Exempt' and 'Handling': echo '<td>' . _($myrow[1]) . '</td> Modified: trunk/TaxGroups.php =================================================================== --- trunk/TaxGroups.php 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/TaxGroups.php 2014-09-01 00:00:37 UTC (rev 6859) @@ -176,16 +176,9 @@ <th colspan="2" > </th> </tr>'; - $k=0; //row colour counter + $k = False;// Row counter to determine background colour. while($myrow = DB_fetch_array($result)) { - if($k==1) { - echo '<tr class="EvenTableRows">'; - $k=0; - } else { - echo '<tr class="OddTableRows">'; - $k=1; - } - + $k = TableRows($k);// Outputs html table row with class (Odd|Even). printf('<td class="number">%s</td> <td>%s</td> <td><a href="%s&SelectedGroup=%s">' . _('Edit') . '</a></td> @@ -290,20 +283,14 @@ <th>' . _('Order') . '</th> <th>' . _('Tax on Prior Taxes') . '</th> </tr>'; - $k=0; //row colour counter + $k = False;// Row counter to determine background colour. for ($i=1;$i < count($TaxAuthRow)+1;$i++) { - if($k==1) { - echo '<tr class="OddTableRows">'; - $k=0; - } else { - echo '<tr class="EvenTableRows">'; - $k=1; - } if($TaxAuthRow[$i]['calculationorder']==0) { $TaxAuthRow[$i]['calculationorder'] = $i; } + $k = TableRows($k);// Outputs html table row with class (Odd|Even). echo '<td>' . $TaxAuthRow[$i]['taxname'] . '</td> <td><input type="text" class="integer" pattern="[1-4] {1}" title="'._('The input must be positive integer and less than 5').'" name="CalcOrder_' . $TaxAuthRow[$i]['taxauthid'] . '" value="' . $TaxAuthRow[$i]['calculationorder'] . '" size="2" maxlength="2" style="width: 100%" /></td> <td><select name="TaxOnTax_' . $TaxAuthRow[$i]['taxauthid'] . '" style="width: 100%">'; @@ -348,25 +335,18 @@ '</div>'; } - $k=0; //row colour counter + $k = False;// Row counter to determine background colour. while($AvailRow = DB_fetch_array($Result)) { - if($k==1) { - echo '<tr class="EvenTableRows">'; - $k=0; - } else { - echo '<tr class="OddTableRows">'; - $k=1; - } $TaxAuthUsedPointer = array_search($AvailRow['taxid'],$TaxAuthsUsed); + $k = TableRows($k);// Outputs html table row with class (Odd|Even). if($TaxAuthUsedPointer) { if($TaxAuthRow[$TaxAuthUsedPointer]['taxontax'] ==1) { $TaxOnTax = _('Yes'); } else { $TaxOnTax = _('No'); } - printf(' <td class="number">%s</td> <td>%s</td> Modified: trunk/TaxProvinces.php =================================================================== --- trunk/TaxProvinces.php 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/TaxProvinces.php 2014-09-01 00:00:37 UTC (rev 6859) @@ -166,17 +166,9 @@ <th colspan="2"> </th> </tr>'; - $k=0; //row colour counter + $k = False;// Row counter to determine background colour. while($myrow = DB_fetch_row($result)) { - - if($k==1) { - echo '<tr class="EvenTableRows">'; - $k=0; - } else { - echo '<tr class="OddTableRows">'; - $k++; - } - + $k = TableRows($k);// Outputs html table row with class (Odd|Even). echo '<td>' . $myrow[1] . '</td> <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxProvince=' . $myrow[0] . '">' . _('Edit') . '</a></td> <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxProvince=' . $myrow[0] . '&delete=1">' . _('Delete') . '</a></td> Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/doc/Change.log 2014-09-01 00:00:37 UTC (rev 6859) @@ -1,5 +1,6 @@ webERP Change Log +31/8/14 RChacon: In general: Replaces code to determine background colour with TableRows(). Adds comments to ManualNewScripts.html. Fixes manual.css format. In GLTransInquiry.php: Adds $ViewTopic and $BookMark and sorts columns, and minor improvements. Minor translation improvements. 31/8/14 RChacon: Standardizes page_title_text to main-menu-option, standardizes bottom tax-menu, adds $ViewTopic and $BookMark, completes table header columns, formats data columns in Tax* scripts. 30/8/14 RChacon: In TaxAuthorities.php, adds $ViewTopic and $BookMark, completes table headings, formats number columns to fix sort order, and minor improvements. 30/8/14 Phil: WorkOrderEntry.php didn't handle no item returned from search correctly - fixed. Modified: trunk/doc/Manual/ManualNewScripts.html =================================================================== --- trunk/doc/Manual/ManualNewScripts.html 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/doc/Manual/ManualNewScripts.html 2014-09-01 00:00:37 UTC (rev 6859) @@ -151,3 +151,22 @@ <ul> <li><i>GetNextTransNo</i> - that retrieves the next transaction number for a given transaction type - see the table systypes for a list of the valid transaction type codes.</li> </ul> + +<div class="floatright"> + <a class="minitext" href="#top">⬆ Top</a> +</div> + +<h3>MiscFunctions.php</h3> + +<p>This script holds miscellaneous functions:</p> + +<ul> + <li><i>TableRows</i> - Outputs the table row html tag ("<i><tr></i>") with the class to format the table row ("<i>OddTableRows</i>" or "<i>EvenTableRows</i>") and returns the row counter to determine background colour updated. It requires that the Row counter to determine background colour is initialised before using this function.<br /> + Example:<br /> + <code> + $k = False;// Row counter to determine background colour.<br /> + ...<br /> + $k = TableRows($k);// Outputs html table row with class (Odd|Even). + </code> + </li> +</ul> Modified: trunk/doc/Manual/style/manual.css =================================================================== --- trunk/doc/Manual/style/manual.css 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/doc/Manual/style/manual.css 2014-09-01 00:00:37 UTC (rev 6859) @@ -77,8 +77,8 @@ } .minitext { -margin-right: 1%; -font-size:30%; +margin-right:1%; +font-size:80%; } li.toc { @@ -89,4 +89,4 @@ } p { margin-left: 2%; -} \ No newline at end of file +} Modified: trunk/includes/MiscFunctions.php =================================================================== --- trunk/includes/MiscFunctions.php 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/includes/MiscFunctions.php 2014-09-01 00:00:37 UTC (rev 6859) @@ -1,5 +1,4 @@ <?php - /* $Id$*/ /* ****************************************** */ @@ -449,4 +448,15 @@ echo ' ... ' . _('completed'); } +function TableRows($k) { + // Outputs a html's table row with class (Odd|Even). + if($k) {//Is it an even table row? + echo '<tr class="EvenTableRows">'; + return False; + } else { + echo '<tr class="OddTableRows">'; + return True; + } +}// End function TableRows(). + ?> \ No newline at end of file Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-08-30 23:06:07 UTC (rev 6858) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2014-09-01 00:00:37 UTC (rev 6859) @@ -7,8 +7,8 @@ msgstr "" "Project-Id-Version: webERP 4.11.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2014-08-29 11:25-0600\n" -"PO-Revision-Date: 2014-08-30 16:53-0600\n" +"POT-Creation-Date: 2014-08-30 17:19-0600\n" +"PO-Revision-Date: 2014-08-30 17:36-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -76,7 +76,7 @@ msgid "The account group name cannot contain the character" msgstr "El nombre del grupo contable no puede contener el caracter" -#: AccountGroups.php:87 Departments.php:30 TaxCategories.php:31 +#: AccountGroups.php:87 Departments.php:30 TaxCategories.php:32 msgid "or the character" msgstr "o el caracter" @@ -189,7 +189,7 @@ #: StockCategories.php:209 Stocks.php:738 Stocks.php:747 Stocks.php:755 #: Stocks.php:763 Stocks.php:771 Stocks.php:779 Stocks.php:787 Stocks.php:795 #: SupplierTypes.php:126 Suppliers.php:647 Suppliers.php:656 Suppliers.php:664 -#: TaxCategories.php:131 TaxGroups.php:132 TaxGroups.php:140 +#: TaxCategories.php:132 TaxGroups.php:134 TaxGroups.php:142 #: TaxProvinces.php:129 UnitsOfMeasure.php:135 WWW_Access.php:86 #: WorkCentres.php:89 WorkCentres.php:95 msgid "There are" @@ -285,11 +285,10 @@ #: SupplierPriceList.php:499 SupplierTenderCreate.php:556 #: SupplierTenderCreate.php:664 SupplierTenders.php:322 #: SupplierTenders.php:388 SupplierTransInquiry.php:10 Suppliers.php:305 -#: TaxGroups.php:15 TaxProvinces.php:11 TopItems.php:115 UnitsOfMeasure.php:10 -#: WWW_Access.php:11 WWW_Users.php:36 WhereUsedInquiry.php:18 -#: WorkCentres.php:111 WorkCentres.php:163 WorkOrderCosting.php:22 -#: WorkOrderEntry.php:11 WorkOrderIssue.php:22 WorkOrderReceive.php:31 -#: WorkOrderStatus.php:59 Z_BottomUpCosts.php:57 +#: TopItems.php:115 UnitsOfMeasure.php:10 WWW_Access.php:11 WWW_Users.php:36 +#: WhereUsedInquiry.php:18 WorkCentres.php:111 WorkCentres.php:163 +#: WorkOrderCosting.php:22 WorkOrderEntry.php:11 WorkOrderIssue.php:22 +#: WorkOrderReceive.php:31 WorkOrderStatus.php:59 Z_BottomUpCosts.php:57 #: ../webSHOP/includes/header.php:251 msgid "Search" msgstr "Buscar" @@ -354,7 +353,7 @@ #: SystemParameters.php:1018 SystemParameters.php:1072 #: SystemParameters.php:1084 SystemParameters.php:1086 #: SystemParameters.php:1124 SystemParameters.php:1126 TaxGroups.php:311 -#: TaxGroups.php:314 TaxGroups.php:371 WWW_Users.php:505 WWW_Users.php:507 +#: TaxGroups.php:314 TaxGroups.php:365 WWW_Users.php:505 WWW_Users.php:507 #: WWW_Users.php:678 WWW_Users.php:680 #: reportwriter/languages/en_US/reports.php:114 msgid "Yes" @@ -403,7 +402,7 @@ #: SystemParameters.php:1019 SystemParameters.php:1073 #: SystemParameters.php:1083 SystemParameters.php:1087 #: SystemParameters.php:1123 SystemParameters.php:1127 TaxGroups.php:312 -#: TaxGroups.php:315 TaxGroups.php:373 WWW_Users.php:504 WWW_Users.php:508 +#: TaxGroups.php:315 TaxGroups.php:367 WWW_Users.php:504 WWW_Users.php:508 #: WWW_Users.php:677 WWW_Users.php:681 includes/PDFLowGPPageHeader.inc:44 #: reportwriter/languages/en_US/reports.php:82 msgid "No" @@ -433,8 +432,8 @@ #: SelectGLAccount.php:132 SellThroughSupport.php:298 Shippers.php:144 #: StockCategories.php:289 SuppTransGLAnalysis.php:125 #: SupplierContacts.php:165 SupplierTenderCreate.php:157 SupplierTypes.php:170 -#: TaxAuthorities.php:174 TaxCategories.php:182 TaxGroups.php:188 -#: TaxProvinces.php:180 UnitsOfMeasure.php:185 WWW_Access.php:126 +#: TaxAuthorities.php:174 TaxCategories.php:185 TaxGroups.php:191 +#: TaxProvinces.php:181 UnitsOfMeasure.php:185 WWW_Access.php:126 #: WWW_Users.php:341 WorkCentres.php:142 includes/InputSerialItems.php:110 #: includes/OutputSerialItems.php:20 #: reportwriter/languages/en_US/reports.php:143 @@ -478,7 +477,7 @@ #: SuppInvGRNs.php:147 SuppShiptChgs.php:90 SuppTransGLAnalysis.php:126 #: SupplierContacts.php:166 SupplierTenderCreate.php:422 #: SupplierTenderCreate.php:452 SupplierTypes.php:172 TaxAuthorities.php:175 -#: TaxCategories.php:183 TaxGroups.php:189 TaxProvinces.php:181 +#: TaxCategories.php:188 TaxGroups.php:192 TaxProvinces.php:182 #: UnitsOfMeasure.php:186 WOSerialNos.php:327 WWW_Access.php:127 #: WWW_Users.php:342 WorkCentres.php:143 includes/InputSerialItemsKeyed.php:60 #: includes/OutputSerialItems.php:99 @@ -558,8 +557,8 @@ #: PriceMatrix.php:230 Prices_Customer.php:369 SalesAnalReptCols.php:552 #: SalesAnalRepts.php:519 SalesGLPostings.php:425 SalesPeople.php:373 #: Shippers.php:203 StockCategories.php:646 SuppLoginSetup.php:292 -#: SupplierContacts.php:284 TaxAuthorities.php:329 TaxCategories.php:241 -#: TaxProvinces.php:235 UnitsOfMeasure.php:241 WWW_Users.php:749 +#: SupplierContacts.php:284 TaxAuthorities.php:329 TaxCategories.php:246 +#: TaxProvinces.php:236 UnitsOfMeasure.php:241 WWW_Users.php:749 #: WorkCentres.php:283 msgid "Enter Information" msgstr "Guardar la Información" @@ -973,11 +972,10 @@ #: SupplierPriceList.php:533 SupplierTenderCreate.php:434 #: SupplierTenderCreate.php:695 SupplierTenderCreate.php:853 #: SupplierTenders.php:326 SupplierTenders.php:421 SupplierTenders.php:687 -#: TaxAuthorities.php:147 TopItems.php:167 WorkCentres.php:128 -#: WorkOrderCosting.php:100 WorkOrderCosting.php:132 WorkOrderEntry.php:733 -#: WorkOrderIssue.php:755 Z_ItemsWithoutPicture.php:33 -#: api/api_xml-rpc.php:3489 includes/PDFGrnHeader.inc:29 -#: includes/PDFInventoryPlanPageHeader.inc:51 +#: TopItems.php:167 WorkCentres.php:128 WorkOrderCosting.php:100 +#: WorkOrderCosting.php:132 WorkOrderEntry.php:735 WorkOrderIssue.php:755 +#: Z_ItemsWithoutPicture.php:33 api/api_xml-rpc.php:3489 +#: includes/PDFGrnHeader.inc:29 includes/PDFInventoryPlanPageHeader.inc:51 #: includes/PDFOstdgGRNsPageHeader.inc:38 #: includes/PDFStockLocTransferHeader.inc:65 #: includes/PDFStockTransferHeader.inc:36 includes/PDFTopItemsHeader.inc:50 @@ -1499,7 +1497,7 @@ #: SystemParameters.php:1035 SystemParameters.php:1041 #: SystemParameters.php:1047 SystemParameters.php:1053 #: SystemParameters.php:1059 TopItems.php:30 TopItems.php:46 TopItems.php:68 -#: TopItems.php:70 WorkOrderEntry.php:675 WorkOrderEntry.php:678 +#: TopItems.php:70 WorkOrderEntry.php:677 WorkOrderEntry.php:680 #: WorkOrderIssue.php:710 WorkOrderIssue.php:713 #: reportwriter/languages/en_US/reports.php:54 msgid "All" @@ -1942,13 +1940,13 @@ #: BOMInquiry.php:26 BOMs.php:883 MRPDemands.php:336 #: PO_SelectOSPurchOrder.php:241 PO_SelectPurchOrder.php:190 -#: Shipt_Select.php:169 WorkOrderEntry.php:699 WorkOrderIssue.php:726 +#: Shipt_Select.php:169 WorkOrderEntry.php:701 WorkOrderIssue.php:726 msgid "Enter text extracts in the" msgstr "Indicar una parte del texto de la" #: BOMInquiry.php:26 BOMs.php:883 MRPDemands.php:336 #: PO_SelectOSPurchOrder.php:241 PO_SelectPurchOrder.php:190 -#: Shipt_Select.php:169 WorkOrderEntry.php:699 WorkOrderIssue.php:726 +#: Shipt_Select.php:169 WorkOrderEntry.php:701 WorkOrderIssue.php:726 msgid "description" msgstr "descripción" @@ -1969,14 +1967,14 @@ #: SelectSupplier.php:231 SelectWorkOrder.php:202 SellThroughSupport.php:202 #: Shipt_Select.php:174 SuppFixedAssetChgs.php:126 SupplierPriceList.php:49 #: SupplierPriceList.php:406 SupplierTenderCreate.php:566 -#: SupplierTenderCreate.php:706 SupplierTenders.php:433 WorkOrderEntry.php:704 +#: SupplierTenderCreate.php:706 SupplierTenders.php:433 WorkOrderEntry.php:706 #: WorkOrderIssue.php:731 msgid "OR" msgstr "ó" #: BOMInquiry.php:29 BOMs.php:886 MRPDemands.php:339 #: PO_SelectOSPurchOrder.php:245 PO_SelectPurchOrder.php:195 -#: Shipt_Select.php:174 WorkOrderEntry.php:704 WorkOrderIssue.php:731 +#: Shipt_Select.php:174 WorkOrderEntry.php:706 WorkOrderIssue.php:731 msgid "Enter extract of the" msgstr "Introduzca una parte del" @@ -1992,7 +1990,7 @@ #: StockCounts.php:213 StockMovements.php:36 StockReorderLevel.php:51 #: StockStatus.php:62 StockTransfers.php:48 StockTransfers.php:471 #: StockUsage.php:64 SupplierPriceList.php:49 SupplierTenderCreate.php:706 -#: SupplierTenders.php:433 WorkOrderEntry.php:704 WorkOrderIssue.php:731 +#: SupplierTenders.php:433 WorkOrderEntry.php:706 WorkOrderIssue.php:731 #: Z_ChangeStockCode.php:189 ../webSHOP/includes/PlaceOrder.php:235 msgid "Stock Code" msgstr "Código de inventario" @@ -2006,7 +2004,7 @@ #: SelectProduct.php:569 SelectSupplier.php:241 SelectSupplier.php:274 #: SupplierPriceList.php:61 SupplierTenderCreate.php:572 #: SupplierTenderCreate.php:611 SupplierTenderCreate.php:717 -#: SupplierTenders.php:445 WorkOrderEntry.php:710 WorkOrderIssue.php:738 +#: SupplierTenders.php:445 WorkOrderEntry.php:712 WorkOrderIssue.php:738 msgid "Search Now" msgstr "Buscar ahora" @@ -2054,7 +2052,7 @@ #: Shipt_Select.php:190 SpecialOrder.php:149 StockCategories.php:256 #: SuppPriceList.php:308 SupplierPriceList.php:270 SupplierPriceList.php:455 #: SupplierTenderCreate.php:617 SupplierTenderCreate.php:852 -#: SupplierTenders.php:686 TopItems.php:166 WorkOrderEntry.php:732 +#: SupplierTenders.php:686 TopItems.php:166 WorkOrderEntry.php:734 #: WorkOrderIssue.php:754 includes/PDFTopItemsHeader.inc:49 #: includes/PO_PDFOrderPageHeader.inc:75 ../webSHOP/ItemDetails.php:72 msgid "Code" @@ -2074,7 +2072,7 @@ #: Shipments.php:402 Shipments.php:489 Shipt_Select.php:194 #: StockLocTransferReceive.php:459 SupplierPriceList.php:272 #: SupplierTenderCreate.php:854 SupplierTenders.php:688 TopItems.php:169 -#: WorkOrderCosting.php:102 WorkOrderEntry.php:734 WorkOrderIssue.php:756 +#: WorkOrderCosting.php:102 WorkOrderEntry.php:736 WorkOrderIssue.php:756 #: WorkOrderIssue.php:826 includes/PDFInventoryValnPageHeader.inc:34 #: includes/DefineLabelClass.php:21 msgid "Units" @@ -2238,7 +2236,7 @@ msgstr "El campo de fecha requerida debe ser una fecha con el formato" #: BOMs.php:257 StockAdjustments.php:165 StockTransfers.php:173 -#: WorkOrderEntry.php:338 +#: WorkOrderEntry.php:340 msgid "The quantity entered must be numeric" msgstr "La cantidad introducida debe ser un número" @@ -2709,7 +2707,7 @@ msgid "Bank Accounts Maintenance" msgstr "Administrar cuentas bancarias" -#: BankAccounts.php:12 TaxAuthorities.php:150 +#: BankAccounts.php:12 TaxAuthorities.php:149 #: ../webSHOP/includes/Functions.php:755 msgid "Bank" msgstr "Banco" @@ -2933,7 +2931,7 @@ #: BankMatching.php:100 BankReconciliation.php:113 CounterReturns.php:829 #: Currencies.php:218 CustomerReceipt.php:802 DailyBankTransactions.php:40 -#: PDFChequeListing.php:46 Payments.php:778 TaxAuthorities.php:151 +#: PDFChequeListing.php:46 Payments.php:778 TaxAuthorities.php:150 #: TaxAuthorities.php:318 msgid "Bank Account" msgstr "Cuenta bancaria" @@ -3294,7 +3292,7 @@ #: BankReconciliation.php:366 CounterReturns.php:740 CounterSales.php:836 #: Customers.php:1195 SelectOrderItems.php:1370 Stocks.php:1409 -#: WorkOrderCosting.php:570 WorkOrderEntry.php:661 +#: WorkOrderCosting.php:570 WorkOrderEntry.php:663 msgid "Are You Sure?" msgstr "¿Está seguro?" @@ -3388,7 +3386,7 @@ #: COGSGLPostings.php:200 CustomerReceipt.php:1091 Dashboard.php:532 #: GLJournal.php:388 GLTransInquiry.php:44 Payments.php:1082 -#: SupplierTransInquiry.php:172 TaxAuthorities.php:148 TaxAuthorities.php:149 +#: SupplierTransInquiry.php:172 TaxAuthorities.php:147 TaxAuthorities.php:148 msgid "GL Account" msgstr "Cuenta contable" @@ -3706,7 +3704,7 @@ #: SMTPServer.php:122 SecurityTokens.php:97 SelectCreditItems.php:956 #: SellThroughSupport.php:476 ShopParameters.php:610 StockCostUpdate.php:195 #: StockReorderLevel.php:111 Stocks.php:1403 SystemParameters.php:1140 -#: TaxAuthorityRates.php:84 WOSerialNos.php:337 WorkOrderEntry.php:659 +#: WOSerialNos.php:337 WorkOrderEntry.php:661 #: reportwriter/languages/en_US/reports.php:156 msgid "Update" msgstr "Actualizar" @@ -4018,7 +4016,8 @@ msgstr "Sin impuesto" #: ConfirmDispatch_Invoice.php:306 Credit_Invoice.php:299 -#: SelectCreditItems.php:693 SupplierInvoice.php:607 TaxGroups.php:289 +#: SelectCreditItems.php:693 SupplierInvoice.php:607 TaxAuthorities.php:146 +#: TaxGroups.php:289 msgid "Tax Authority" msgstr "Autoridad fiscal" @@ -4363,7 +4362,7 @@ #: SupplierInvoice.php:1543 SupplierInvoice.php:1561 SupplierInvoice.php:1589 #: SupplierInvoice.php:1610 SupplierInvoice.php:1630 SupplierInvoice.php:1693 #: SupplierInvoice.php:1725 SupplierInvoice.php:1796 SupplierInvoice.php:1826 -#: TaxAuthorities.php:140 WorkOrderCosting.php:375 WorkOrderCosting.php:396 +#: TaxAuthorities.php:139 WorkOrderCosting.php:375 WorkOrderCosting.php:396 #: WorkOrderCosting.php:415 WorkOrderCosting.php:452 WorkOrderCosting.php:471 #: WorkOrderCosting.php:494 WorkOrderCosting.php:513 WorkOrderIssue.php:181 #: WorkOrderIssue.php:212 WorkOrderIssue.php:234 WorkOrderIssue.php:249 @@ -4483,7 +4482,7 @@ #: SupplierInvoice.php:1533 SupplierInvoice.php:1543 SupplierInvoice.php:1561 #: SupplierInvoice.php:1589 SupplierInvoice.php:1610 SupplierInvoice.php:1630 #: SupplierInvoice.php:1693 SupplierInvoice.php:1725 SupplierInvoice.php:1796 -#: SupplierInvoice.php:1826 TaxAuthorities.php:140 WorkOrderCosting.php:375 +#: SupplierInvoice.php:1826 TaxAuthorities.php:139 WorkOrderCosting.php:375 #: WorkOrderCosting.php:396 WorkOrderCosting.php:415 WorkOrderCosting.php:452 #: WorkOrderCosting.php:471 WorkOrderCosting.php:494 WorkOrderCosting.php:513 #: WorkOrderIssue.php:181 WorkOrderIssue.php:212 WorkOrderIssue.php:234 @@ -5053,7 +5052,7 @@ #: SupplierCredit.php:210 SupplierCredit.php:221 SupplierCredit.php:233 #: SupplierCredit.php:243 SupplierCredit.php:253 SupplierInvoice.php:561 #: SupplierInvoice.php:570 SupplierInvoice.php:578 SupplierInvoice.php:586 -#: SupplierInvoice.php:596 TaxAuthorityRates.php:22 +#: SupplierInvoice.php:596 TaxAuthorityRates.php:24 #: includes/PDFSalesAnalysis.inc:547 msgid "click here" msgstr "haga clic aquí" @@ -5072,7 +5071,7 @@ #: ContractBOM.php:144 CounterReturns.php:324 CounterSales.php:352 #: InternalStockRequest.php:500 PO_Items.php:1092 SelectCreditItems.php:390 #: SelectOrderItems.php:781 SupplierTenderCreate.php:834 -#: SupplierTenders.php:667 WorkOrderEntry.php:226 WorkOrderIssue.php:486 +#: SupplierTenders.php:667 WorkOrderEntry.php:228 WorkOrderIssue.php:486 msgid "There is a problem selecting the part records to display because" msgstr "" "Ha ocurrido un problema seleccionando el registro de códigos a mostrar porque" @@ -5232,7 +5231,7 @@ #: SelectOrderItems.php:1468 SelectOrderItems.php:1653 SelectProduct.php:451 #: StockClone.php:100 StockClone.php:710 StockClone.php:715 StockClone.php:720 #: StockClone.php:724 Stocks.php:1025 Stocks.php:1029 Stocks.php:1033 -#: SupplierTenderCreate.php:878 SupplierTenders.php:714 WorkOrderEntry.php:751 +#: SupplierTenderCreate.php:878 SupplierTenders.php:714 WorkOrderEntry.php:753 #: WorkOrderIssue.php:772 reportwriter/languages/en_US/reports.php:270 #, php-format msgid "No Image" @@ -6363,12 +6362,12 @@ msgstr "La Categoría de Stock se usó en la búsqueda" #: CounterReturns.php:325 CounterSales.php:353 InternalStockRequest.php:501 -#: SelectOrderItems.php:782 WorkOrderEntry.php:227 WorkOrderIssue.php:487 +#: SelectOrderItems.php:782 WorkOrderEntry.php:229 WorkOrderIssue.php:487 msgid "The SQL used to get the part selection was" msgstr "El SQL usado para obtener la selección de piezas fue" #: CounterReturns.php:329 CounterSales.php:357 InternalStockRequest.php:505 -#: SelectOrderItems.php:787 WorkOrderEntry.php:231 WorkOrderIssue.php:491 +#: SelectOrderItems.php:787 WorkOrderEntry.php:233 WorkOrderIssue.php:491 msgid "There are no products available meeting the criteria specified" msgstr "No hay productos disponibles que correspondan al criterio especificado" @@ -6653,7 +6652,7 @@ #: CounterReturns.php:1680 CounterReturns.php:1803 CounterSales.php:2288 #: CounterSales.php:2411 InternalStockRequest.php:619 #: InternalStockRequest.php:741 PO_Items.php:1172 PO_Items.php:1174 -#: WorkOrderEntry.php:719 WorkOrderEntry.php:721 +#: WorkOrderEntry.php:721 WorkOrderEntry.php:723 msgid "Prev" msgstr "Anterior" @@ -6668,7 +6667,7 @@ #: SelectCustomer.php:413 SelectCustomer.php:490 SelectOrderItems.php:1641 #: SelectOrderItems.php:1767 SelectProduct.php:769 SelectSupplier.php:271 #: SelectSupplier.php:337 SupplierPriceList.php:261 -#: SupplierTenderCreate.php:608 WorkOrderEntry.php:724 WorkOrderEntry.php:726 +#: SupplierTenderCreate.php:608 WorkOrderEntry.php:726 WorkOrderEntry.php:728 msgid "Next" msgstr "Siguiente" @@ -6846,7 +6845,7 @@ #: DeliveryDetails.php:1098 OrderDetails.php:125 PO_Header.php:1152 #: PO_OrderDetails.php:156 RecurringSalesOrders.php:419 SpecialOrder.php:614 #: SupplierCredit.php:602 SupplierInquiry.php:213 SupplierInvoice.php:950 -#: SupplierTransInquiry.php:107 WorkOrderEntry.php:601 +#: SupplierTransInquiry.php:107 WorkOrderEntry.php:603 #: Z_ImportChartOfAccounts.php:28 Z_ImportGLAccountGroups.php:26 #: Z_ImportGLAccountSections.php:29 Z_ImportPartCodes.php:31 #: includes/PDFOrderPageHeader_generic.inc:58 @@ -6949,7 +6948,7 @@ "esto" #: CounterSales.php:1255 DeliveryDetails.php:531 DeliveryDetails.php:729 -#: WorkOrderEntry.php:316 +#: WorkOrderEntry.php:318 msgid "The work order item could not be added" msgstr "No se pudo agregar el artículo de la orden de trabajo" @@ -7743,7 +7742,7 @@ #: CustEDISetup.php:31 CustLoginSetup.php:51 Customers.php:67 #: InternalStockCategoriesByRole.php:24 StockClone.php:148 Stocks.php:137 -#: SuppLoginSetup.php:51 TaxCategories.php:31 WWW_Users.php:73 +#: SuppLoginSetup.php:51 TaxCategories.php:32 WWW_Users.php:73 #: WorkCentres.php:35 Z_ChangeBranchCode.php:28 Z_ImportDebtors.php:224 #: Z_ImportDebtors.php:298 Z_ImportStocks.php:120 msgid "or a space" @@ -8071,7 +8070,7 @@ #: CustItem.php:455 MailingGroupMaintenance.php:250 PurchData.php:763 #: SellThroughSupport.php:481 Shipments.php:523 StockAdjustments.php:485 -#: TaxGroups.php:400 WOSerialNos.php:275 WWW_Access.php:238 +#: TaxGroups.php:395 WOSerialNos.php:275 WWW_Access.php:238 #: reportwriter/languages/en_US/reports.php:131 #, php-format msgid "Add" @@ -8786,7 +8785,7 @@ msgstr "Numero de Fax" #: CustomerBranches.php:415 CustomerBranches.php:866 SupplierCredit.php:265 -#: Suppliers.php:840 Suppliers.php:1094 TaxGroups.php:173 TaxGroups.php:239 +#: Suppliers.php:840 Suppliers.php:1094 TaxGroups.php:175 TaxGroups.php:241 msgid "Tax Group" msgstr "Grupo de impuestos" @@ -12182,7 +12181,7 @@ msgid "Are you sure you wish to delete this factoring company?" msgstr "¿Confirma que desea eliminar esta compañía financiera?" -#: Factors.php:286 TaxAuthorities.php:146 +#: Factors.php:286 TaxAuthorities.php:145 msgid "ID" msgstr "ID" @@ -12806,7 +12805,7 @@ msgid "Asset Financial Summary" msgstr "Resumen Financiero de Activos" -#: FixedAssetItems.php:597 WorkOrderEntry.php:595 +#: FixedAssetItems.php:597 WorkOrderEntry.php:597 msgid "Accumulated Costs" msgstr "Costos acumulados" @@ -15924,7 +15923,7 @@ msgid "in months" msgstr "en meses" -#: InventoryPlanningPrefSupplier.php:87 WorkOrderEntry.php:602 +#: InventoryPlanningPrefSupplier.php:87 WorkOrderEntry.php:604 #: WorkOrderIssue.php:624 WorkOrderStatus.php:99 msgid "Qty Required" msgstr "Cantidad requerida" @@ -16525,7 +16524,8 @@ msgid "Location Name" msgstr "Nombre Localidad" -#: Locations.php:400 Locations.php:620 TaxAuthorityRates.php:87 +#: Locations.php:400 Locations.php:620 TaxAuthorityRates.php:82 +#: TaxProvinces.php:165 msgid "Tax Province" msgstr "Jurisdicción fiscal" @@ -17635,7 +17635,7 @@ msgstr "¿Está seguro que desea eliminar este usuario de este grupo de correo?" #: MailingGroupMaintenance.php:238 SalesCategories.php:536 -#: StockAdjustments.php:484 SupplierTenders.php:354 TaxGroups.php:380 +#: StockAdjustments.php:484 SupplierTenders.php:354 TaxGroups.php:376 #: WWW_Access.php:223 reportwriter/languages/en_US/reports.php:153 #, php-format msgid "Remove" @@ -18181,7 +18181,7 @@ msgid "PO#" msgstr "OC#" -#: OutstandingGRNs.php:180 WorkOrderEntry.php:603 +#: OutstandingGRNs.php:180 WorkOrderEntry.php:605 #: includes/PDFStockLocTransferHeader.inc:67 msgid "Qty Received" msgstr "Cant. Recibida" @@ -21076,7 +21076,7 @@ #: PO_SelectOSPurchOrder.php:230 PO_SelectPurchOrder.php:181 #: SelectCompletedOrder.php:467 SelectCreditItems.php:983 #: SelectSalesOrder.php:527 SelectWorkOrder.php:189 Shipt_Select.php:158 -#: WorkOrderEntry.php:672 WorkOrderIssue.php:707 +#: WorkOrderEntry.php:674 WorkOrderIssue.php:707 msgid "Select a stock category" msgstr "Seleccionar una clase de existencia" @@ -22534,7 +22534,7 @@ msgstr "Revisar Precio" #: Prices.php:223 PricesByCost.php:156 Prices_Customer.php:354 -#: RecurringSalesOrders.php:428 SelectWorkOrder.php:333 WorkOrderEntry.php:581 +#: RecurringSalesOrders.php:428 SelectWorkOrder.php:333 WorkOrderEntry.php:583 #: WorkOrderStatus.php:86 msgid "Start Date" msgstr "Fecha Inicio" @@ -26443,7 +26443,7 @@ msgstr "" "No hay productos disponibles que coincidan con el criterio especificado" -#: SelectCreditItems.php:396 WorkOrderEntry.php:234 WorkOrderIssue.php:494 +#: SelectCreditItems.php:396 WorkOrderEntry.php:236 WorkOrderIssue.php:494 msgid "The SQL statement used was" msgstr "El SQL usado fue" @@ -30004,7 +30004,8 @@ msgid "Decimal Places for display Quantity" msgstr "Decimales al mostrar cantidades" -#: StockClone.php:964 Stocks.php:1273 TaxAuthorityRates.php:88 +#: StockClone.php:964 Stocks.php:1273 TaxAuthorityRates.php:83 +#: TaxCategories.php:168 msgid "Tax Category" msgstr "Clase de impuesto" @@ -30445,7 +30446,7 @@ msgstr "Numeros de Serie" #: StockLocStatus.php:299 StockLocStatus.php:331 StockStatus.php:271 -#: WorkOrderEntry.php:634 +#: WorkOrderEntry.php:636 msgid "Batches" msgstr "Lotes" @@ -31151,7 +31152,7 @@ msgid "Enter another Transfer" msgstr "Introduzca otra Transferencia" -#: StockTransfers.php:177 WorkOrderEntry.php:341 +#: StockTransfers.php:177 WorkOrderEntry.php:343 msgid "The quantity entered must be a positive number greater than zero" msgstr "La cantidad entrada debe ser positiva y mayor que cero" @@ -32259,8 +32260,7 @@ "confirmar los cambios a la base de datos porque" #: SuppPaymentRun.php:240 SupplierTypes.php:6 SupplierTypes.php:21 -#: SystemParameters.php:13 TaxAuthorities.php:10 TaxAuthorityRates.php:16 -#: TaxCategories.php:10 includes/MainMenuLinksArray.php:477 +#: SystemParameters.php:13 includes/MainMenuLinksArray.php:477 msgid "Supplier Types" msgstr "Tipos de Proveedor" @@ -33835,7 +33835,7 @@ msgid "Tender" msgstr "Licitación" -#: SupplierTenders.php:533 WorkOrderCosting.php:70 WorkOrderEntry.php:590 +#: SupplierTenders.php:533 WorkOrderCosting.php:70 WorkOrderEntry.php:592 #: WorkOrderIssue.php:550 WorkOrderReceive.php:819 WorkOrderStatus.php:72 msgid "Required By" msgstr "Requerido por" @@ -35715,31 +35715,35 @@ msgid "Summary Only" msgstr "Sólo resumen" -#: TaxAuthorities.php:6 TaxAuthorityRates.php:134 +#: TaxAuthorities.php:5 msgid "Tax Authorities" -msgstr "Autoridades Fiscales" +msgstr "Autoridades fiscales" -#: TaxAuthorities.php:27 +#: TaxAuthorities.php:11 TaxAuthorities.php:12 TaxAuthorityRates.php:122 +msgid "Tax Authorities Maintenance" +msgstr "Administrar autoridades fiscales" + +#: TaxAuthorities.php:26 msgid "The tax type description may not be empty" msgstr "La descripción del tipo de impuesto no puede estar vacía" -#: TaxAuthorities.php:46 +#: TaxAuthorities.php:45 msgid "The update of this tax authority failed because" msgstr "No se pudo actualizar esta Autoridad Fiscal porque" -#: TaxAuthorities.php:49 +#: TaxAuthorities.php:48 msgid "The tax authority for record has been updated" msgstr "Se actualizó el registro de la Autoridad Fiscal" -#: TaxAuthorities.php:73 +#: TaxAuthorities.php:72 msgid "The addition of this tax authority failed because" msgstr "No se pudo añadir esta Autoridad Fiscal porque" -#: TaxAuthorities.php:76 +#: TaxAuthorities.php:75 msgid "The new tax authority record has been added to the database" msgstr "Se agregó un registro a la BD para la nueva Autoridad Fiscal" -#: TaxAuthorities.php:116 +#: TaxAuthorities.php:115 msgid "" "Cannot delete this tax authority because there are tax groups defined that " "use it" @@ -35747,33 +35751,33 @@ "No se puede eliminar esta Autoridad Fiscal porque hay Grupos de Impuestos " "que la usan" -#: TaxAuthorities.php:121 +#: TaxAuthorities.php:120 msgid "The selected tax authority record has been deleted" msgstr "Se eliminó el registro de la Autoridad Fiscal seleccionada" -#: TaxAuthorities.php:140 +#: TaxAuthorities.php:139 msgid "The defined tax authorities could not be retrieved because" msgstr "No se pudo obtener las Autoridades Fiscales definidas porque" -#: TaxAuthorities.php:141 +#: TaxAuthorities.php:140 msgid "The following SQL to retrieve the tax authorities was used" msgstr "El SQL usado para obtener las Autoridades Fiscales es el siguiente:" -#: TaxAuthorities.php:148 +#: TaxAuthorities.php:147 msgid "Input Tax" msgstr "Impuestos Repercutidos" -#: TaxAuthorities.php:149 +#: TaxAuthorities.php:148 msgid "Output Tax" msgstr "Impuestos Soportados" -#: TaxAuthorities.php:152 +#: TaxAuthorities.php:151 msgid "Bank Act Type" msgstr "Tipo de cuenta bancaria" -#: TaxAuthorities.php:153 +#: TaxAuthorities.php:152 msgid "Bank Swift" -msgstr "Swift del Banco" +msgstr "Swift del banco" #: TaxAuthorities.php:175 #, php-format @@ -35783,7 +35787,7 @@ #: TaxAuthorities.php:176 #, php-format msgid "Edit Rates" -msgstr "Editar Tasas" +msgstr "Editar tasas" #: TaxAuthorities.php:205 msgid "Review all defined tax authority records" @@ -35791,19 +35795,19 @@ #: TaxAuthorities.php:258 msgid "Tax Type Description" -msgstr "Descripción del Tipo de Impuesto" +msgstr "Descripción del tipo de impuesto" #: TaxAuthorities.php:259 msgid "No illegal characters allowed and should not be blank" -msgstr "" +msgstr "No se permite caracteres no válidos y no deben estar en blanco" #: TaxAuthorities.php:262 msgid "Input tax GL Account" -msgstr "Cuenta de Cobros de Impuestos" +msgstr "Cuenta contable para cobro de impuestos" #: TaxAuthorities.php:281 msgid "Output tax GL Account" -msgstr "Cuenta de Pagos de Impuestos" +msgstr "Cuenta contable para pago de impuestos" #: TaxAuthorities.php:310 msgid "Bank Name" @@ -35829,10 +35833,32 @@ msgid "No more than 15 characters" msgstr "No más de 15 caracteres" -#: TaxAuthorityRates.php:12 +#: TaxAuthorities.php:336 TaxAuthorityRates.php:123 TaxCategories.php:256 +#: TaxGroups.php:11 TaxGroups.php:12 TaxProvinces.php:247 +#: includes/MainMenuLinksArray.php:443 +msgid "Tax Group Maintenance" +msgstr "Administrar grupos de impuestos" + +#: TaxAuthorities.php:337 TaxAuthorityRates.php:124 TaxCategories.php:257 +#: TaxGroups.php:412 TaxProvinces.php:11 TaxProvinces.php:12 +#: includes/MainMenuLinksArray.php:444 +msgid "Dispatch Tax Province Maintenance" +msgstr "Administrar jurisdicciones fiscales" + +#: TaxAuthorities.php:338 TaxAuthorityRates.php:125 TaxCategories.php:11 +#: TaxCategories.php:12 TaxGroups.php:413 TaxProvinces.php:248 +#: includes/MainMenuLinksArray.php:445 +msgid "Tax Category Maintenance" +msgstr "Administrar clases de impuestos" + +#: TaxAuthorityRates.php:5 msgid "Tax Rates" msgstr "Tasas Impositivas" +#: TaxAuthorityRates.php:11 TaxAuthorityRates.php:12 +msgid "Tax Rates Maintenance" +msgstr "Administrar tasas impositivas" + #: TaxAuthorityRates.php:22 msgid "" "This page can only be called after selecting the tax authority to edit the " @@ -35841,40 +35867,36 @@ "Esta página sólo puede usarse después de seleccionar la autoridad tributaria " "para la que editar las tasas" -#: TaxAuthorityRates.php:22 +#: TaxAuthorityRates.php:23 msgid "Please select the Rates link from the tax authority page" msgstr "Por favor seleccione la tasa desde la página de la autoridad de rentas" -#: TaxAuthorityRates.php:22 +#: TaxAuthorityRates.php:25 msgid "to go to the Tax Authority page" msgstr "ir a la página de la autoridad de rentas" -#: TaxAuthorityRates.php:45 +#: TaxAuthorityRates.php:46 msgid "All rates updated successfully" msgstr "Se han actualizado las tasas correctamente" -#: TaxAuthorityRates.php:84 -msgid "Rates" -msgstr "Tasas" - -#: TaxAuthorityRates.php:87 +#: TaxAuthorityRates.php:82 msgid "Deliveries From" msgstr "Entregas Desde" -#: TaxAuthorityRates.php:89 +#: TaxAuthorityRates.php:84 msgid "Tax Rate" msgstr "Tasa impositiva" -#: TaxAuthorityRates.php:112 +#: TaxAuthorityRates.php:100 #, php-format msgid "Input must be numeric" msgstr "La cantidad debe ser numérica" -#: TaxAuthorityRates.php:126 +#: TaxAuthorityRates.php:111 msgid "Update Rates" msgstr "Actualizar tasas" -#: TaxAuthorityRates.php:129 +#: TaxAuthorityRates.php:116 msgid "" "There are no tax rates to show - perhaps the dispatch tax province records " "have not yet been created?" @@ -35882,27 +35904,19 @@ "No hay Tasas de Impuestos que mostrar, quizás los registros de jurisdicción " "fiscal desde donde despacha aún no han sido creados." -#: TaxAuthorityRates.php:136 -msgid "Tax Groupings" -msgstr "Agrupar Impuestos" - -#: TaxAuthorityRates.php:138 TaxCategories.php:6 TaxCategories.php:167 +#: TaxCategories.php:5 msgid "Tax Categories" msgstr "Clases de impuestos" -#: TaxAuthorityRates.php:140 TaxProvinces.php:6 -msgid "Dispatch Tax Provinces" -msgstr "Jurisdicciones Fiscales" - -#: TaxCategories.php:31 +#: TaxCategories.php:32 msgid "The tax category name cannot contain the character" msgstr "El nombre de la clase de impuesto no puede contener el carácter" -#: TaxCategories.php:35 +#: TaxCategories.php:36 msgid "The tax category name may not be empty" msgstr "El nombre de la clase de impuesto no puede estar vacío" -#: TaxCategories.php:49 +#: TaxCategories.php:50 msgid "" "The tax category cannot be renamed because another with the same name " "already exists." @@ -35910,38 +35924,38 @@ "No es posible cambiar el nombre de la clase de impuesto porque existe otra " "con ese nombre" -#: TaxCategories.php:63 +#: TaxCategories.php:64 msgid "The tax category could not be updated" msgstr "No se pudo actualizar la clase de impuesto" -#: TaxCategories.php:67 +#: TaxCategories.php:68 msgid "The tax category no longer exists" msgstr "La categoría de impuestos ya no existe" -#: TaxCategories.php:70 +#: TaxCategories.php:71 msgid "Tax category name changed" msgstr "Cambiaron de el nombre de la categoría de impuesto" -#: TaxCategories.php:79 +#: TaxCategories.php:80 msgid "" "The tax category cannot be created because another with the same name " "already exists" msgstr "" "No se puede crear la clase de impuesto porque existe otra con ese nombre" -#: TaxCategories.php:87 +#: TaxCategories.php:88 msgid "The new tax category could not be added" msgstr "No se pudo crear la nueva clase de impuesto" -#: TaxCategories.php:103 +#: TaxCategories.php:104 msgid "New tax category added" msgstr "Se creó una Nueva Clase de Impuesto" -#: TaxCategories.php:122 +#: TaxCategories.php:123 msgid "Cannot delete this tax category because it no longer exists" msgstr "No se puede eliminar esta clase de impuesto porque no existe" -#: TaxCategories.php:130 +#: TaxCategories.php:131 msgid "" "Cannot delete this tax category because inventory items have been created " "using this tax category" @@ -35949,100 +35963,105 @@ "No se puede eliminar esta categoría de impuestos porque los artículos del " "inventario han sido creados con esta categoría de impuestos" -#: TaxCategories.php:131 +#: TaxCategories.php:132 msgid "inventory items that refer to this tax category" msgstr "Artículos de Inventario con esta clase de Impuesto" -#: TaxCategories.php:137 +#: TaxCategories.php:138 msgid "tax category and any tax rates set for it have been deleted" msgstr "" "Se han eliminado la categoría de impuesto y cualquier tasa de impuestos " "fijada para este último" -#: TaxCategories.php:162 TaxProvinces.php:160 +#: TaxCategories.php:163 TaxProvinces.php:160 msgid "Could not get tax categories because" msgstr "No se pudo obtener las clases de impuestos porque" -#: TaxCategories.php:183 +#: TaxCategories.php:187 msgid "Are you sure you wish to delete this tax category?" msgstr "¿Seguro que desea eliminar esta categoría de impuestos?" -#: TaxCategories.php:196 +#: TaxCategories.php:201 msgid "Review Tax Categories" msgstr "Revisar Clases de Impuestos" -#: TaxCategories.php:218 +#: TaxCategories.php:223 msgid "Could not retrieve the requested tax category, please try again." msgstr "" "No se pudo obtener la clase de impuesto solicitada, por favor, pruebe de " "nuevo" -#: TaxCategories.php:234 +#: TaxCategories.php:239 msgid "Tax Category Name" msgstr "Nombre de la Clase de Impuesto" -#: TaxCategories.php:235 +#: TaxCategories.php:240 msgid "No more than 30 characters" msgstr "" -#: TaxCategories.php:235 +#: TaxCategories.php:240 msgid "No illegal characters allowed and cannot be blank" msgstr "" -#: TaxGroups.php:6 +#: TaxCategories.php:255 TaxGroups.php:411 TaxProvinces.php:246 +#: includes/MainMenuLinksArray.php:442 +msgid "Tax Authorities and Rates Maintenance" +msgstr "Administrar autoridades fiscales y tasas" + +#: TaxGroups.php:5 msgid "Tax Groups" msgstr "Grupos de Impuestos" -#: TaxGroups.php:27 +#: TaxGroups.php:30 msgid "The Group description entered must be at least 4 characters long" msgstr "La descripción del Grupo debe tener al menos 4 caracteres" -#: TaxGroups.php:37 +#: TaxGroups.php:40 msgid "The update of the tax group description failed because" msgstr "Falló la actualización de este grupo de Impuestos porque" -#: TaxGroups.php:38 +#: TaxGroups.php:41 msgid "The tax group description was updated to" msgstr "La descripción del grupo de impuestos se actualizó a" -#: TaxGroups.php:45 +#: TaxGroups.php:48 msgid "" "A new tax group could not be added because a tax group already exists for" msgstr "" "No se pudo añadir un nuevo grupo de impuestos porque ya existe un grupo de " "impuestos para ello" -#: TaxGroups.php:50 +#: TaxGroups.php:53 msgid "The addition of the group failed because" msgstr "Falló la creación del grupo porque" -#: TaxGroups.php:51 +#: TaxGroups.php:54 msgid "Added the new tax group" msgstr "Añadido el nuevo grupo fiscal" -#: TaxGroups.php:66 +#: TaxGroups.php:69 msgid "The addition of the tax failed because" msgstr "No se pudo añadir el Impuesto porque" -#: TaxGroups.php:67 +#: TaxGroups.php:70 msgid "The tax was added." msgstr "Se agregó el Impuesto" -#: TaxGroups.php:72 +#: TaxGroups.php:75 msgid "The removal of this tax failed because" msgstr "No pudo quitarse este Impuesto porque" -#: TaxGroups.php:73 +#: TaxGroups.php:76 msgid "This tax was removed." msgstr "este impuesto fue eliminado." -#: TaxGroups.php:89 TaxGroups.php:112 +#: TaxGroups.php:92 TaxGroups.php:115 msgid "Could not get tax authorities in the selected tax group" msgstr "" "No se pudo obtener las Autoridades Fiscales del grupo de impuestos " "seleccionado" -#: TaxGroups.php:117 +#: TaxGroups.php:120 msgid "" "It is inappropriate to set tax on tax where the tax is the first in the " "calculation order. The system has changed it back to no tax on tax for this " @@ -36052,7 +36071,7 @@ "primero en el orden de cálculo. El sistema lo ha cambiado a no impuesto " "sobre impuesto para esta autoridad fiscal." -#: TaxGroups.php:131 +#: TaxGroups.php:133 msgid "" "Cannot delete this tax group because some customer branches are setup using " "it" @@ -36060,60 +36079,60 @@ "No se pudo eliminar este grupo de impuestos porque algunas Sucursales de " "clientes lo usan" -#: TaxGroups.php:132 +#: TaxGroups.php:134 msgid "customer branches referring to this tax group" msgstr "Sucursales de cliente que hacen referencia a este grupo de impuestos" -#: TaxGroups.php:139 +#: TaxGroups.php:141 msgid "Cannot delete this tax group because some suppliers are setup using it" msgstr "" "No se pudo eliminar este grupo de impuestos porque algunos proveedores lo " "usan" -#: TaxGroups.php:140 +#: TaxGroups.php:142 msgid "suppliers referring to this tax group" msgstr "proveedores referidos a este grupo de Impuestos" -#: TaxGroups.php:149 +#: TaxGroups.php:151 msgid "tax group has been deleted" msgstr "Se eliminó el grupo de impuestos" -#: TaxGroups.php:167 +#: TaxGroups.php:169 msgid "There are no tax groups configured." msgstr "No se han configurado grupos de impuestos" -#: TaxGroups.php:172 +#: TaxGroups.php:174 msgid "Group No" msgstr "Nº del Grupo" -#: TaxGroups.php:189 +#: TaxGroups.php:192 #, php-format msgid "Are you sure you wish to delete this tax group?" msgstr "¿Confirma que desea eliminar este grupo de impuestos?" -#: TaxGroups.php:207 +#: TaxGroups.php:209 msgid "Review Existing Groups" msgstr "Revisar Grupos Existentes" -#: TaxGroups.php:220 +#: TaxGroups.php:222 msgid "The selected tax group is no longer available." msgstr "El grupo de impuestos seleccionado ya no está disponible" -#: TaxGroups.php:240 +#: TaxGroups.php:242 msgid "" "The group name must be more 4 and less than 40 characters and cannot be left " "blank" msgstr "" -#: TaxGroups.php:240 +#: TaxGroups.php:242 msgid "4 to 40 legal characters" msgstr "" -#: TaxGroups.php:241 +#: TaxGroups.php:243 msgid "Enter Group" msgstr "Guardar/Cambiar Nombre" -#: TaxGroups.php:286 TaxGroups.php:342 +#: TaxGroups.php:286 TaxGroups.php:339 msgid "Calculation Order" msgstr "Orden de Cálculo" @@ -36129,37 +36148,41 @@ msgid "Update Order" msgstr "Actualizar Pedidos" -#: TaxGroups.php:335 +#: TaxGroups.php:332 msgid "Assigned Taxes" msgstr "Impuestos Asignados" -#: TaxGroups.php:337 +#: TaxGroups.php:334 msgid "Available Taxes" msgstr "Impuestos Disponibles" -#: TaxGroups.php:340 TaxGroups.php:345 +#: TaxGroups.php:337 TaxGroups.php:341 msgid "Tax Auth ID" msgstr "ID de la Autoridad Fiscal" -#: TaxGroups.php:341 TaxGroups.php:346 +#: TaxGroups.php:338 TaxGroups.php:342 msgid "Tax Authority Name" msgstr "Nombre de la Autoridad Fiscal" -#: TaxGroups.php:343 +#: TaxGroups.php:340 msgid "Tax on Prior Tax(es)" msgstr "Impuesto sobre Impuesto/s Anterior/es" -#: TaxGroups.php:352 +#: TaxGroups.php:347 msgid "There are no tax authorities defined to allocate to this tax group" msgstr "" "No hay definidas Autoridades Fiscales para (a la que) asignar este grupo de " "impuestos" -#: TaxGroups.php:380 +#: TaxGroups.php:376 #, php-format msgid "Are you sure you wish to remove this tax authority from the group?" msgstr "¿Confirma que desea eliminar esta autoridad fiscal del grupo?" +#: TaxProvinces.php:5 +msgid "Dispatch Tax Provinces" +msgstr "Jurisdicciones Fiscales" + #: TaxProvinces.php:32 msgid "The tax province name cannot contain any of the illegal characters" msgstr "" @@ -36242,44 +36265,28 @@ "La provincia de impuesto y cualquier tasa de impuestos fijada para este " "último se han eliminado" -#: TaxProvinces.php:165 -msgid "Tax Provinces" -msgstr "Jurisdicción Fiscal" - -#: TaxProvinces.php:191 +#: TaxProvinces.php:192 msgid "Review Tax Provinces" msgstr "Revisar Jurisdicciones Fiscales" -#: TaxProvinces.php:212 +#: TaxProvinces.php:213 msgid "Could not retrieve the requested tax province, please try again." msgstr "" "No se pudo obtener la jurisdicción fiscal requerida, por favor, pruebe de " "nuevo." -#: TaxProvinces.php:228 +#: TaxProvinces.php:229 msgid "Tax Province Name" msgstr "Nombre de La Jurisdicción Fiscal" -#: TaxProvinces.php:229 +#: TaxProvinces.php:230 msgid "The tax province cannot be left blank and includes illegal characters" msgstr "" -#: TaxProvinces.php:229 +#: TaxProvinces.php:230 msgid "Within 30 legal characters" msgstr "" -#: TaxProvinces.php:245 -msgid "Edit/Review Tax Authorities" -msgst... [truncated message content] |
From: <dai...@us...> - 2014-09-01 09:47:23
|
Revision: 6861 http://sourceforge.net/p/web-erp/reponame/6861 Author: daintree Date: 2014-09-01 09:47:13 +0000 (Mon, 01 Sep 2014) Log Message: ----------- keep more verbose row colour code Modified Paths: -------------- trunk/TaxGroups.php trunk/TaxProvinces.php Modified: trunk/TaxGroups.php =================================================================== --- trunk/TaxGroups.php 2014-09-01 09:43:08 UTC (rev 6860) +++ trunk/TaxGroups.php 2014-09-01 09:47:13 UTC (rev 6861) @@ -176,9 +176,15 @@ <th colspan="2" > </th> </tr>'; - $k = False;// Row counter to determine background colour. + $j = 1; while($myrow = DB_fetch_array($result)) { - $k = TableRows($k);// Outputs html table row with class (Odd|Even). + if ($j==1) { + echo '<tr class="OddTableRows">'; + $j=0; + } else { + echo '<tr class="EvenTableRows">'; + $j++; + } printf('<td class="number">%s</td> <td>%s</td> <td><a href="%s&SelectedGroup=%s">' . _('Edit') . '</a></td> @@ -283,14 +289,20 @@ <th>' . _('Order') . '</th> <th>' . _('Tax on Prior Taxes') . '</th> </tr>'; - $k = False;// Row counter to determine background colour. + $j = 1; for ($i=1;$i < count($TaxAuthRow)+1;$i++) { if($TaxAuthRow[$i]['calculationorder']==0) { $TaxAuthRow[$i]['calculationorder'] = $i; } - $k = TableRows($k);// Outputs html table row with class (Odd|Even). + if ($j==1) { + echo '<tr class="OddTableRows">'; + $j=0; + } else { + echo '<tr class="EvenTableRows">'; + $j++; + } echo '<td>' . $TaxAuthRow[$i]['taxname'] . '</td> <td><input type="text" class="integer" pattern="[1-4] {1}" title="'._('The input must be positive integer and less than 5').'" name="CalcOrder_' . $TaxAuthRow[$i]['taxauthid'] . '" value="' . $TaxAuthRow[$i]['calculationorder'] . '" size="2" maxlength="2" style="width: 100%" /></td> <td><select name="TaxOnTax_' . $TaxAuthRow[$i]['taxauthid'] . '" style="width: 100%">'; @@ -335,12 +347,18 @@ '</div>'; } - $k = False;// Row counter to determine background colour. + $j = 1; while($AvailRow = DB_fetch_array($Result)) { $TaxAuthUsedPointer = array_search($AvailRow['taxid'],$TaxAuthsUsed); - $k = TableRows($k);// Outputs html table row with class (Odd|Even). + if ($j==1) { + echo '<tr class="OddTableRows">'; + $j=0; + } else { + echo '<tr class="EvenTableRows">'; + $j++; + } if($TaxAuthUsedPointer) { if($TaxAuthRow[$TaxAuthUsedPointer]['taxontax'] ==1) { $TaxOnTax = _('Yes'); Modified: trunk/TaxProvinces.php =================================================================== --- trunk/TaxProvinces.php 2014-09-01 09:43:08 UTC (rev 6860) +++ trunk/TaxProvinces.php 2014-09-01 09:47:13 UTC (rev 6861) @@ -166,9 +166,15 @@ <th colspan="2"> </th> </tr>'; - $k = False;// Row counter to determine background colour. + $j = 1; while($myrow = DB_fetch_row($result)) { - $k = TableRows($k);// Outputs html table row with class (Odd|Even). + if ($j==1) { + echo '<tr class="OddTableRows">'; + $j=0; + } else { + echo '<tr class="EvenTableRows">'; + $j++; + } echo '<td>' . $myrow[1] . '</td> <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxProvince=' . $myrow[0] . '">' . _('Edit') . '</a></td> <td><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?SelectedTaxProvince=' . $myrow[0] . '&delete=1">' . _('Delete') . '</a></td> |
From: <te...@us...> - 2014-09-05 02:19:34
|
Revision: 6864 http://sourceforge.net/p/web-erp/reponame/6864 Author: tehonu Date: 2014-09-05 02:19:24 +0000 (Fri, 05 Sep 2014) Log Message: ----------- Added condition to MRP to use / not use reorder level to calculate requirements and some typos fixed. Modified Paths: -------------- trunk/MRP.php trunk/sql/mysql/upgrade4.11-4.12.sql Modified: trunk/MRP.php =================================================================== --- trunk/MRP.php 2014-09-05 01:17:11 UTC (rev 6863) +++ trunk/MRP.php 2014-09-05 02:19:24 UTC (rev 6864) @@ -284,51 +284,52 @@ AND stockmaster.discontinued = 0"; $result = DB_query($sql,$db); - $sql = "INSERT INTO mrprequirements (part, - daterequired, - quantity, - mrpdemandtype, - orderno, - directdemand, - whererequired) - SELECT mrpdemands.stockid, - mrpdemands.duedate, - mrpdemands.quantity, - mrpdemands.mrpdemandtype, - mrpdemands.demandid, - '1', - mrpdemands.stockid - FROM mrpdemands, stockmaster - WHERE mrpdemands.stockid = stockmaster.stockid - AND stockmaster.discontinued = 0"; - if ($_POST['UserMRPDemands'] == 'y') { + if ($_POST['UseMRPDemands'] == 'y') { + $sql = "INSERT INTO mrprequirements (part, + daterequired, + quantity, + mrpdemandtype, + orderno, + directdemand, + whererequired) + SELECT mrpdemands.stockid, + mrpdemands.duedate, + mrpdemands.quantity, + mrpdemands.mrpdemandtype, + mrpdemands.demandid, + '1', + mrpdemands.stockid + FROM mrpdemands, stockmaster + WHERE mrpdemands.stockid = stockmaster.stockid + AND stockmaster.discontinued = 0"; $result = DB_query($sql,$db); prnMsg(_('Loading requirements based on mrpdemands'),'info'); flush(); } - $sql = "INSERT INTO mrprequirements (part, - daterequired, - quantity, - mrpdemandtype, - orderno, - directdemand, - whererequired) - SELECT locstock.stockid, - '" . date('Y-m-d') . "', - (locstock.reorderlevel - locstock.quantity) AS reordqty, - 'REORD', - '1', - '1', - locstock.stockid - FROM locstock, stockmaster - WHERE stockmaster.stockid = locstock.stockid - AND stockmaster.discontinued = 0 - AND reorderlevel > quantity"; - $result = DB_query($sql,$db); - prnMsg(_('Loading requirements based on reorder level'),'info'); - flush(); + if ($_POST['UseRLDemands'] == 'y') { + $sql = "INSERT INTO mrprequirements (part, + daterequired, + quantity, + mrpdemandtype, + orderno, + directdemand, + whererequired) + SELECT locstock.stockid, + '" . date('Y-m-d') . "', + (locstock.reorderlevel - locstock.quantity) AS reordqty, + 'REORD', + '1', + '1', + locstock.stockid + FROM locstock, stockmaster + WHERE stockmaster.stockid = locstock.stockid + AND stockmaster.discontinued = 0 + AND reorderlevel > quantity"; + $result = DB_query($sql,$db); + prnMsg(_('Loading requirements based on reorder level'),'info'); + flush(); + } - // In the following section, create mrpsupplies from open purchase orders, // open work orders, and current quantity onhand from locstock prnMsg(_('Creating supplies table'),'info'); @@ -495,6 +496,7 @@ shrinkageflag varchar(5), eoqflag varchar(5), usemrpdemands varchar(5), + userldemands varchar(5), leeway smallint) DEFAULT CHARSET=utf8"; $result = DB_query($sql,$db); // Create entry for location field from $_POST['location'], which is an array @@ -514,6 +516,7 @@ shrinkageflag, eoqflag, usemrpdemands, + userldemands, leeway) VALUES (CURRENT_TIMESTAMP, '" . $locparm . "', @@ -521,6 +524,7 @@ '" . $_POST['ShrinkageFlag'] . "', '" . $_POST['EOQFlag'] . "', '" . $_POST['UseMRPDemands'] . "', + '" . $_POST['UseRLDemands'] . "', '" . filter_number_format($_POST['Leeway']) . "')"; $result = DB_query($sql,$db); @@ -541,6 +545,10 @@ if ($myrow['usemrpdemands'] == 'y') { $UseMRPDemands = _('Yes'); } + $UseRLDemands = _('No'); + if ($myrow['userldemands'] == 'y') { + $UseRLDemands = _('Yes'); + } $useeoq = _('No'); if ($myrow['eoqflag'] == 'y') { $useeoq = _('Yes'); @@ -570,9 +578,13 @@ </tr> <tr> <td>' . _('Use MRP Demands') . ':</td> - <td>' . $UserMRPDemands . '</td> + <td>' . $UseMRPDemands . '</td> </tr> <tr> + <td>' . _('Use Reorder Level Demands') . ':</td> + <td>' . $UseRLDemands . '</td> + </tr> + <tr> <td>' . _('Use EOQ') . ':</td> <td>' . $useeoq . '</td> </tr> @@ -619,6 +631,10 @@ <td><input type="checkbox" name="UseMRPDemands" value="y" checked="checked" /></td> </tr> <tr> + <td>' ._('Use Reorder Level Demands?') . ':</td> + <td><input type="checkbox" name="UseRLDemands" value="y" checked="checked" /></td> + </tr> + <tr> <td>' ._('Use EOQ?') . ':</td> <td><input type="checkbox" name="EOQFlag" value="y" checked="checked" /></td> </tr> Modified: trunk/sql/mysql/upgrade4.11-4.12.sql =================================================================== --- trunk/sql/mysql/upgrade4.11-4.12.sql 2014-09-05 01:17:11 UTC (rev 6863) +++ trunk/sql/mysql/upgrade4.11-4.12.sql 2014-09-05 02:19:24 UTC (rev 6864) @@ -74,6 +74,8 @@ ON www_users.userid = locationusers.userid AND locations.loccode = locationusers.loccode WHERE locationusers.userid IS NULL; + +ALTER TABLE `mrpparameters` ADD `userldemands` VARCHAR( 5 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT 'use RL requirements or not' AFTER `usemrpdemands`; UPDATE config SET confvalue='4.12' WHERE confname='VersionNumber'; |
From: <te...@us...> - 2014-09-07 15:55:55
|
Revision: 6866 http://sourceforge.net/p/web-erp/reponame/6866 Author: tehonu Date: 2014-09-07 15:55:49 +0000 (Sun, 07 Sep 2014) Log Message: ----------- new script listing all items in running WO that can be produced with available stock in location. Prints also single item production slip with basic BOM, components and image information. Modified Paths: -------------- trunk/includes/MainMenuLinksArray.php trunk/sql/mysql/upgrade4.11-4.12.sql Added Paths: ----------- trunk/PrintWOItemSlip.php trunk/WOCanBeProducedNow.php Added: trunk/PrintWOItemSlip.php =================================================================== --- trunk/PrintWOItemSlip.php (rev 0) +++ trunk/PrintWOItemSlip.php 2014-09-07 15:55:49 UTC (rev 6866) @@ -0,0 +1,214 @@ +<?php + +include('includes/session.inc'); + +if (isset($_GET['WO'])) { + $WO = filter_number_format($_GET['WO']); +} elseif (isset($_POST['WO'])){ + $WO = filter_number_format($_POST['WO']); +} else { + $WO = ''; +} + +if (isset($_GET['StockId'])) { + $StockId = $_GET['StockId']; +} elseif (isset($_POST['StockId'])) { + $StockId = $_POST['StockId']; +} + +if (isset($_GET['Location'])) { + $Location = $_GET['Location']; +} elseif (isset($_POST['Location'])) { + $Location = $_POST['Location']; +} + + +if (isset($WO) AND isset($StockId) AND $WO!=''){ + + $sql = "SELECT woitems.qtyreqd, + woitems.qtyrecd, + stockmaster.description, + stockmaster.decimalplaces, + stockmaster.units + FROM woitems, stockmaster + WHERE stockmaster.stockid = woitems.stockid + AND woitems.wo = '" . $WO . "' + AND woitems.stockid = '" . $StockId . "' "; + + $ErrMsg = _('The SQL to find the details of the item to produce failed'); + $resultItems = DB_query($sql,$db,$ErrMsg); + + if (DB_num_rows($resultItems) != 0){ + include('includes/PDFStarter.php'); + + $pdf->addInfo('Title',_('WO Production Slip')); + $pdf->addInfo('Subject',_('WO Production Slip')); + + while ($myItem = DB_fetch_array($resultItems)) { + // print the info of the parent product + $FontSize=10; + $PageNumber=1; + $line_height=12; + $Xpos = $Left_Margin+1; + $fill = FALSE; + + $QtyPending = $myItem['qtyreqd'] - $myItem['qtyrecd']; + + PrintHeader($pdf,$YPos,$PageNumber,$Page_Height,$Top_Margin,$Left_Margin, + $Page_Width,$Right_Margin,$WO,$StockId,$myItem['description'],$QtyPending,$myItem['units'],$myItem['decimalplaces'],$ReportDate); + + $PartCounter = 0; + + $sqlBOM = "SELECT bom.parent, + bom.component, + bom.quantity AS bomqty, + stockmaster.decimalplaces, + stockmaster.units, + stockmaster.description, + stockmaster.shrinkfactor, + locstock.quantity AS qoh + FROM bom, stockmaster, locstock + WHERE bom.component = stockmaster.stockid + AND bom.component = locstock.stockid + AND locstock.loccode = '". $Location ."' + AND bom.parent = '" . $StockId . "' + AND bom.effectiveafter < '" . Date('Y-m-d') . "' + AND (bom.effectiveto > '" . Date('Y-m-d') . "' + OR bom.effectiveto='0000-00-00')"; + + $ErrMsg = _('The bill of material could not be retrieved because'); + $BOMResult = DB_query ($sqlBOM,$db,$ErrMsg); + while ($myComponent = DB_fetch_array($BOMResult)) { + + $ComponentNeeded = $myComponent['bomqty'] * $QtyPending; + $PrevisionShrinkage = $ComponentNeeded * ($myComponent['shrinkfactor'] / 100); + + $Xpos = $Left_Margin+1; + + $pdf->addTextWrap($Xpos,$YPos,150,$FontSize, $myComponent['component'], 'left'); + $pdf->addTextWrap(150,$YPos,50,$FontSize,locale_number_format($myComponent['bomqty'],$myComponent['decimalplaces']), 'right'); + $pdf->addTextWrap(200,$YPos,30,$FontSize,$myComponent['units'], 'left'); + $pdf->addTextWrap(230,$YPos,50,$FontSize,locale_number_format($ComponentNeeded,$myComponent['decimalplaces']), 'right'); + $pdf->addTextWrap(280,$YPos,30,$FontSize,$myComponent['units'], 'left'); + $pdf->addTextWrap(310,$YPos,50,$FontSize,locale_number_format($PrevisionShrinkage,$myComponent['decimalplaces']), 'right'); + $pdf->addTextWrap(360,$YPos,30,$FontSize,$myComponent['units'], 'left'); + + $YPos -= $line_height; + + if ($YPos < $Bottom_Margin + $line_height){ + PrintHeader($pdf,$YPos,$PageNumber,$Page_Height,$Top_Margin,$Left_Margin,$Page_Width, + $Right_Margin,$WO,$Stockid,$myItem['description'],$QtyPending,$myItem['units'],$myItem['decimalplaces'],$ReportDate); + } + } + } + + // Production Notes + $pdf->addTextWrap($Xpos,$YPos-50,100,$FontSize,_('Incidences / Production Notes :'), 'left'); + $YPos -=(8*$line_height); + + //add components prepared by + $pdf->addTextWrap(40,$YPos-50,100,$FontSize,_('Components Prepared By :'), 'left'); + $pdf->addTextWrap(40,$YPos-70,100,$FontSize,_('Name'), 'left'); + $pdf->addTextWrap(80,$YPos-70,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(40,$YPos-90,100,$FontSize,_('Date'), 'left'); + $pdf->addTextWrap(80,$YPos-90,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(40,$YPos-110,100,$FontSize,_('Hour'), 'left'); + $pdf->addTextWrap(80,$YPos-110,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(40,$YPos-150,100,$FontSize,_('Signature'), 'left'); + $pdf->addTextWrap(80,$YPos-150,200,$FontSize,':__________________','left',0,$fill); + + //add Produced by + $pdf->addTextWrap(200,$YPos-50,100,$FontSize,_('Item Produced By :'), 'left'); + $pdf->addTextWrap(200,$YPos-70,100,$FontSize,_('Name'), 'left'); + $pdf->addTextWrap(240,$YPos-70,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(200,$YPos-90,100,$FontSize,_('Date'), 'left'); + $pdf->addTextWrap(240,$YPos-90,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(200,$YPos-110,100,$FontSize,_('Hour'), 'left'); + $pdf->addTextWrap(240,$YPos-110,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(200,$YPos-150,100,$FontSize,_('Signature'), 'left'); + $pdf->addTextWrap(240,$YPos-150,200,$FontSize,':__________________','left',0,$fill); + + //add Quality Control by + $pdf->addTextWrap(400,$YPos-50,100,$FontSize,_('Quality Control By :'), 'left'); + $pdf->addTextWrap(400,$YPos-70,100,$FontSize,_('Name'), 'left'); + $pdf->addTextWrap(440,$YPos-70,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(400,$YPos-90,100,$FontSize,_('Date'), 'left'); + $pdf->addTextWrap(440,$YPos-90,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(400,$YPos-110,100,$FontSize,_('Hour'), 'left'); + $pdf->addTextWrap(440,$YPos-110,200,$FontSize,':__________________','left',0,$fill); + $pdf->addTextWrap(400,$YPos-150,100,$FontSize,_('Signature'), 'left'); + $pdf->addTextWrap(440,$YPos-150,200,$FontSize,':__________________','left',0,$fill); + + if ($YPos < $Bottom_Margin + $line_height){ + PrintHeader($pdf,$YPos,$PageNumber,$Page_Height,$Top_Margin,$Left_Margin,$Page_Width, + $Right_Margin,$WO,$Stockid,$myItem['description'],$QtyPending,$myItem['units'],$myItem['decimalplaces'],$ReportDate); + } + + $pdf->OutputD('WO-' . $WO . '-' . $StockId . '-' . Date('Y-m-d') . '.pdf'); + $pdf->__destruct(); + }else{ + $Title = _('WO Item production Slip'); + include('includes/header.inc'); + prnMsg(_('There were no items with ready to produce'),'info'); + prnMsg($sql); + echo '<br /><a href="' . $RootPath . '/index.php">' . _('Back to the menu') . '</a>'; + include('includes/footer.inc'); + exit; + + } +} + + +function PrintHeader(&$pdf,&$YPos,&$PageNumber,$Page_Height,$Top_Margin,$Left_Margin, + $Page_Width,$Right_Margin,$WO,$StockId,$Description,$Qty,$UOM,$DecimalPlaces, $ReportDate) { + + /*PDF page header for MRP Planned Work Orders report */ + if ($PageNumber>1){ + $pdf->newPage(); + } + $line_height=12; + $FontSize=10; + $YPos= $Page_Height-$Top_Margin; + + $pdf->addTextWrap($Left_Margin,$YPos,300,$FontSize,$_SESSION['CompanyRecord']['coyname']); + $pdf->addTextWrap(190,$YPos,100,$FontSize,$ReportDate); + $pdf->addTextWrap($Page_Width-$Right_Margin-150,$YPos,160,$FontSize,_('Printed') . ': ' . + Date($_SESSION['DefaultDateFormat']) . ' ' . _('Page') . ' ' . $PageNumber,'left'); + $YPos -=$line_height; + + $pdf->addTextWrap($Left_Margin,$YPos,150,$FontSize,_('Work Order Item Production Slip')); + $YPos -=(2*$line_height); + + $pdf->addTextWrap($Left_Margin,$YPos,150,$FontSize,_('WO'). ': ' . $WO); + $YPos -= $line_height; + + $pdf->addTextWrap($Left_Margin,$YPos,500,$FontSize,_('Item Code'). ': ' . $StockId . ' --> ' . $Description); + $YPos -= $line_height; + + $pdf->addTextWrap($Left_Margin,$YPos,150,$FontSize,_('Quantity'). ': ' . locale_number_format($Qty,$DecimalPlaces) . ' ' . $UOM); + $YPos -=(2*$line_height); + + if(file_exists($_SESSION['part_pics_dir'] . '/' .$StockId.'.jpg') ) { + $pdf->Image($_SESSION['part_pics_dir'] . '/'.$StockId.'.jpg',135,$Page_Height-$Top_Margin-$YPos+10,200,200); + $YPos -=(16*$line_height); + }/*end checked file exist*/ + + + /*set up the headings */ + $Xpos = $Left_Margin+1; + + $pdf->addTextWrap($Xpos,$YPos,150,$FontSize,_('Component Code'), 'left'); + $pdf->addTextWrap(150,$YPos,50,$FontSize,_('Qty BOM'), 'right'); + $pdf->addTextWrap(200,$YPos,30,$FontSize,_(''), 'left'); + $pdf->addTextWrap(230,$YPos,50,$FontSize,_('Qty Needed'), 'right'); + $pdf->addTextWrap(280,$YPos,30,$FontSize,_(''), 'left'); + $pdf->addTextWrap(310,$YPos,50,$FontSize,_('Shrinkage'), 'right'); + $pdf->addTextWrap(360,$YPos,30,$FontSize,_(''), 'left'); + + $FontSize=10; + $YPos -= $line_height; + + $PageNumber++; +} + +?> Added: trunk/WOCanBeProducedNow.php =================================================================== --- trunk/WOCanBeProducedNow.php (rev 0) +++ trunk/WOCanBeProducedNow.php 2014-09-07 15:55:49 UTC (rev 6866) @@ -0,0 +1,250 @@ +<?php + +include('includes/session.inc'); +$Title = _('WO items can be produced with available stock'); +include('includes/header.inc'); + +if (isset($_POST['submit'])) { + submit($db, $RootPath, $_POST['Location']); +} else { + display($db); +} + +//####_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT_SUBMIT#### +function submit(&$db, $RootPath, $Location) { + + $WhereLocation = " AND workorders.loccode >= '". $Location ."' "; + + $sql = "SELECT woitems.wo, + woitems.stockid, + woitems.qtyreqd, + woitems.qtyrecd, + stockmaster.decimalplaces, + stockmaster.units + FROM workorders, woitems, stockmaster + WHERE workorders.wo = woitems.wo + AND stockmaster.stockid = woitems.stockid + AND workorders.closed = 0 + AND woitems.qtyreqd > woitems.qtyrecd ". + $WhereLocation . + "ORDER BY woitems.wo, woitems.stockid" + ; + + $ErrMsg = _('The SQL to find the WO items to produce '); + $resultItems = DB_query($sql,$db,$ErrMsg); + if (DB_num_rows($resultItems) != 0){ + + echo '<p class="page_title_text" align="center"><strong>' . "Items in WO to be produced now in " . $Location . " with available stock" . '</strong></p>'; + echo '<div>'; + echo '<table class="selection">'; + $TableHeader = ' + <tr> + <th>' . _('WO') . '</th> + <th>' . _('Stock ID') . '</th> + <th>' . _('Requested') . '</th> + <th>' . _('Received') . '</th> + <th>' . _('Pending') . '</th> + <th>' . _('UOM') . '</th> + <th>' . _('Component') . '</th> + <th>' . _('QOH') . '</th> + <th>' . _('Needed') . '</th> + <th>' . _('Shrinkage') . '</th> + <th>' . _('UOM') . '</th> + <th>' . _('') . '</th> + <th>' . _('Result') . '</th> + </tr>'; + + while ($myItem = DB_fetch_array($resultItems)) { + echo $TableHeader; + + $QtyPending = $myItem['qtyreqd'] - $myItem['qtyrecd']; + $QtyCanBeProduced = $QtyPending; + + $WOLink = '<a href="' . $RootPath . '/WorkOrderEntry.php?WO=' . $myItem['wo'] . '">' . $myItem['wo'] . '</a>'; + $CodeLink = '<a href="' . $RootPath . '/SelectProduct.php?StockID=' . $myItem['stockid'] . '">' . $myItem['stockid'] . '</a>'; + + printf('<td class="number">%s</td> + <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td>%s</td> + <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td>%s</td> + <td>%s</td> + <td>%s</td> + </tr>', + $WOLink, + $CodeLink, + locale_number_format($myItem['qtyreqd'],$myItem['decimalplaces']), + locale_number_format($myItem['qtyrecd'],$myItem['decimalplaces']), + locale_number_format($QtyPending,$myItem['decimalplaces']), + $myItem['units'], + '', + '', + '', + '', + '', + '', + '' + ); + + // Get the BOM for this item + $sqlBOM = "SELECT bom.parent, + bom.component, + bom.quantity AS bomqty, + stockmaster.decimalplaces, + stockmaster.units, + stockmaster.shrinkfactor, + locstock.quantity AS qoh + FROM bom, stockmaster, locstock + WHERE bom.component = stockmaster.stockid + AND bom.component = locstock.stockid + AND locstock.loccode = '". $Location ."' + AND bom.parent = '" . $myItem['stockid'] . "' + AND bom.effectiveafter < '" . Date('Y-m-d') . "' + AND (bom.effectiveto > '" . Date('Y-m-d') . "' + OR bom.effectiveto='0000-00-00')"; + + $ErrMsg = _('The bill of material could not be retrieved because'); + $BOMResult = DB_query ($sqlBOM,$db,$ErrMsg); + $ItemCanBeproduced = TRUE; + + while ($myComponent = DB_fetch_array($BOMResult)) { + + $ComponentNeeded = $myComponent['bomqty'] * $QtyPending; + $PrevisionShrinkage = $ComponentNeeded * ($myComponent['shrinkfactor'] / 100); + + if ($myComponent['qoh'] >= $ComponentNeeded){ + $Available = "OK"; + }else{ + $Available = ""; + $ItemCanBeproduced = FALSE; + } + + $ComponentLink = '<a href="' . $RootPath . '/SelectProduct.php?StockID=' . $myComponent['component'] . '">' . $myComponent['component'] . '</a>'; + + printf('<td class="number">%s</td> + <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td>%s</td> + <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td>%s</td> + <td>%s</td> + <td>%s</td> + </tr>', + '', + '', + '', + '', + '', + '', + $ComponentLink, + locale_number_format($myComponent['qoh'],$myComponent['decimalplaces']), + locale_number_format($ComponentNeeded,$myComponent['decimalplaces']), + locale_number_format($PrevisionShrinkage,$myComponent['decimalplaces']), + $myComponent['units'], + $Available, + '' + ); + } + if ($ItemCanBeproduced){ + $Action = 'Produce ' . locale_number_format($QtyPending,0) . ' x ' . $myItem['stockid'] . ' for WO ' . locale_number_format($myItem['wo'],0); + $ComponentLink = '<a href="' . $RootPath . '/PrintWOItemSlip.php?StockId=' . $myItem['stockid'] . '&WO='. $myItem['wo'] . '&Location=' . $Location . '">' . $Action . '</a>'; + }else{ + $ComponentLink = ""; + } + printf('<td class="number">%s</td> + <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td>%s</td> + <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td>%s</td> + <td>%s</td> + <td>%s</td> + </tr>', + '', + '', + '', + '', + '', + '', + '', + '', + '', + '', + '', + '', + $ComponentLink + ); + } + echo '</table> + </div>'; + + }else{ + prnMsg('No items waiting to be produced in ' . $Location); + } + +} // End of function submit() + + +function display(&$db) //####DISPLAY_DISPLAY_DISPLAY_DISPLAY_DISPLAY_DISPLAY_##### +{ +// Display form fields. This function is called the first time +// the page is called. + + echo '<form action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post"> + <div> + <br/> + <br/>'; + echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; + + echo '<p class="page_title_text" align="center"><strong>' . "List of items in WO ready to be produced in: " . '</strong></p>'; + + echo '<table>'; + + echo '<tr> + <td>' . _('For Factory Location') . ':</td> + <td><select name="Location">'; + + $sql = "SELECT loccode, + locationname + FROM locations"; + + $LocnResult=DB_query($sql,$db); + + while ($myrow=DB_fetch_array($LocnResult)){ + echo '<option value="' . $myrow['loccode'] . '">' . $myrow['locationname'] . '</option>'; + } + echo '</select></td> + </tr>'; + + + echo '<tr><td> </td></tr> + <tr><td> </td></tr> + <tr> + <td> </td> + <td><input type="submit" name="submit" value="' . _('Search Items To Produce') . '" /></td> + </tr> + </table> + <br />'; + echo '</div> + </form>'; + +} // End of function display() + +include('includes/footer.inc'); +?> \ No newline at end of file Modified: trunk/includes/MainMenuLinksArray.php =================================================================== --- trunk/includes/MainMenuLinksArray.php 2014-09-06 03:14:43 UTC (rev 6865) +++ trunk/includes/MainMenuLinksArray.php 2014-09-07 15:55:49 UTC (rev 6866) @@ -294,6 +294,7 @@ _('List Components Required'), _('List Materials Not Used Anywhere'), _('Indented Where Used Listing'), + _('WO Items ready to produce'), _('MRP'), _('MRP Shortages'), _('MRP Suggested Purchase Orders'), @@ -308,6 +309,7 @@ '/BOMExtendedQty.php', '/MaterialsNotUsed.php', '/BOMIndentedReverse.php', + '/WOCanBeProducedNow.php', '/MRPReport.php', '/MRPShortages.php', '/MRPPlannedPurchaseOrders.php', Modified: trunk/sql/mysql/upgrade4.11-4.12.sql =================================================================== --- trunk/sql/mysql/upgrade4.11-4.12.sql 2014-09-06 03:14:43 UTC (rev 6865) +++ trunk/sql/mysql/upgrade4.11-4.12.sql 2014-09-07 15:55:49 UTC (rev 6866) @@ -77,6 +77,10 @@ ALTER TABLE `mrpparameters` ADD `userldemands` VARCHAR( 5 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT 'use RL requirements or not' AFTER `usemrpdemands`; +INSERT INTO `scripts` ( `script` , `pagesecurity` , `description` ) VALUES ('WOCanBeProducedNow.php', '4', 'List of WO items that can be produced with available stock in location'); +INSERT INTO `scripts` ( `script` , `pagesecurity` , `description` ) VALUES ('PrintWOItemSlip.php', '4', 'PDF WO Item production Slip '); + + UPDATE config SET confvalue='4.12' WHERE confname='VersionNumber'; |
From: <ex...@us...> - 2014-09-11 02:07:07
|
Revision: 6870 http://sourceforge.net/p/web-erp/reponame/6870 Author: exsonqu Date: 2014-09-11 02:07:02 +0000 (Thu, 11 Sep 2014) Log Message: ----------- 11/09/14: Exson: Fixed the prnMsg bug in CustomerReceipt.php and add an inquiry link in it and make a status selectable in Customer inquiry and removed those rowstring definition which caused printf parameters missing. Modified Paths: -------------- trunk/CustomerInquiry.php trunk/CustomerReceipt.php Modified: trunk/CustomerInquiry.php =================================================================== --- trunk/CustomerInquiry.php 2014-09-08 02:05:18 UTC (rev 6869) +++ trunk/CustomerInquiry.php 2014-09-11 02:07:02 UTC (rev 6870) @@ -1,28 +1,43 @@ <?php -/* $Id$*/ +/* $Id$*/ + +include('includes/SQL_CommonFunctions.inc'); + include('includes/session.inc'); $Title = _('Customer Inquiry'); -$ViewTopic = 'ARInquiries';// Filename in ManualContents.php's TOC. -$BookMark = 'CustomerInquiry';// Anchor's id in the manual's html document. + +$ViewTopic = 'ARInquiries'; +$BookMark = 'CustomerInquiry'; + include('includes/header.inc'); -include('includes/SQL_CommonFunctions.inc'); - // always figure out the SQL required from the inputs available -if(!isset($_GET['CustomerID']) AND !isset($_SESSION['CustomerID'])) { +if(!isset($_GET['CustomerID']) AND !isset($_SESSION['CustomerID'])){ prnMsg(_('To display the enquiry a customer must first be selected from the customer selection screen'),'info'); echo '<br /><div class="centre"><a href="'. $RootPath . '/SelectCustomer.php?' . SID . '">' . _('Select a Customer to Inquire On') . '</a><br /></div>'; include('includes/footer.inc'); exit; } else { - if (isset($_GET['CustomerID'])) { + if (isset($_GET['CustomerID'])){ $_SESSION['CustomerID'] = $_GET['CustomerID']; } $CustomerID = $_SESSION['CustomerID']; } - +if(isset($_GET['Status'])){ + if(is_numeric($_GET['Status'])){ + $_POST['Status'] = $_GET['Status']; + } +} +if(isset($_POST['Status'])){ + if($_POST['Status']=='' OR $_POST['Status']==1 OR $_POST['Status']==0){ + $Status = $_POST['Status']; + }else{ + prnMsg(_('The balance status should be all or zero balance or not zero balance'),'error'); + exit; + } +} if (!isset($_POST['TransAfterDate'])) { $sql = "SELECT confvalue FROM `config` @@ -91,7 +106,7 @@ $ErrMsg = _('The customer details could not be retrieved by the SQL because'); $CustomerResult = DB_query($SQL,$db,$ErrMsg); -if (DB_num_rows($CustomerResult)==0) { +if (DB_num_rows($CustomerResult)==0){ /*Because there is no balance - so just retrieve the header information about the customer - the choice is do one query to get the balance and transactions for those customers who have a balance and two queries for those who don't have a balance OR always do two queries - I opted for the former */ @@ -122,7 +137,7 @@ $CustomerRecord = DB_fetch_array($CustomerResult); -if ($NIL_BALANCE==True) { +if ($NIL_BALANCE==True){ $CustomerRecord['balance']=0; $CustomerRecord['due']=0; $CustomerRecord['overdue1']=0; @@ -133,7 +148,7 @@ _('Customer') . ': ' . $CustomerID . ' - ' . $CustomerRecord['name'] . '<br />' . _('All amounts stated in') . ': ' . - $CustomerRecord['currency'] . '<br />' . // To be replaced by: + $CustomerRecord['currency'] . '<br />' . // To be replaced by: /* $CustomerRecord['currcode'] . ' - ' . $CurrencyName[$CustomerRecord['currcode']] . '<br />' . // <-- Replacement */ _('Terms') . ': ' . $CustomerRecord['terms'] . '<br />' . @@ -142,7 +157,7 @@ _('Credit Status') . ': ' . $CustomerRecord['reasondescription'] . '</p>'; -if ($CustomerRecord['dissallowinvoices']!=0) { +if ($CustomerRecord['dissallowinvoices']!=0){ echo '<br /><font color="red" size="4"><b>' . _('ACCOUNT ON HOLD') . '</font></b><br />'; } @@ -162,14 +177,32 @@ <td class="number">' . locale_number_format($CustomerRecord['overdue2'],$CustomerRecord['decimalplaces']) . '</td> </tr> </table>'; - +if(!isset($_POST['Status'])){ + $_POST['Status'] = ''; +} echo '<br /> <div class="centre"> <form action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post"> <div> <input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />' . _('Show all transactions after') . ': <input tabindex="1" type="text" required="required" title="' . _('A date after which all transactions for the customer should be displayed must be entered') . '" class="date" alt="' .$_SESSION['DefaultDateFormat']. '" id="datepicker" name="TransAfterDate" value="' . $_POST['TransAfterDate'] . '" maxlength="10" size="12" /> - <input tabindex="2" type="submit" name="Refresh Inquiry" value="' . _('Refresh Inquiry') . '" /> + <select name="Status">'; + if($_POST['Status']==''){ + echo '<option value="" selected="selected">' . _('All') . '</option>'; + echo '<option value="1">' . _('Invoices not fully allocated') . '</option>'; + echo '<option value="0">' . _('Invoices fully allocated') . '</option>'; + }else{ + $Choice = ($_POST['Status']==1)?_('Invoices fully allocated'):_('Invoices not fully allocated'); + $ChoiceLeft = ($_POST['Status']==1)?_('Invoices not fully allocated'):_('Invoices fully allocated'); + echo '<option value="' . $_POST['Status'] . '" selected="selected">' . $Choice . '</option>'; + $StatusValue = ($_POST['Status']==1)?0:1; + echo '<option value="' . $StatusValue . '">' . $ChoiceLeft . '</option>'; + echo '<option value="">' . _('All') . '</option>'; + + + } + +echo '</select><input tabindex="3" type="submit" name="Refresh Inquiry" value="' . _('Refresh Inquiry') . '" /> </div> </form> </div> @@ -188,7 +221,8 @@ debtortrans.order_, debtortrans.rate, (debtortrans.ovamount + debtortrans.ovgst + debtortrans.ovfreight + debtortrans.ovdiscount) AS totalamount, - debtortrans.alloc AS allocated + debtortrans.alloc AS allocated, + (debtortrans.ovamount + debtortrans.ovgst + debtortrans.ovfreight + debtortrans.ovdiscount - debtortrans.alloc) as balance FROM debtortrans INNER JOIN systypes ON debtortrans.type = systypes.typeid WHERE debtortrans.debtorno = '" . $CustomerID . "' @@ -197,208 +231,356 @@ if ($_SESSION['SalesmanLogin'] != '') { $SQL .= " AND debtortrans.salesperson='" . $_SESSION['SalesmanLogin'] . "'"; } +if (isset($Status) AND $Status != '') { + $SQL .= ($Status==1)?' having balance<=0.00001 ':' having balance>0.00001 '; +} + $SQL .= " ORDER BY debtortrans.id"; $ErrMsg = _('No transactions were returned by the SQL because'); $TransResult = DB_query($SQL,$db,$ErrMsg); -if (DB_num_rows($TransResult)==0) { +if (DB_num_rows($TransResult)==0){ echo '<div class="centre">' . _('There are no transactions to display since') . ' ' . $_POST['TransAfterDate'] . '</div>'; include('includes/footer.inc'); exit; } -/* Show a table of the invoices returned by the SQL. */ +/*show a table of the invoices returned by the SQL */ -echo '<table class="selection"> - <tr> - <th class="ascending">' . _('Date') . '</th> - <th class="ascending">' . _('Type') . '</th> - <th class="ascending">' . _('Number') . '</th> - <th class="ascending">' . _('Reference') . '</th> - <th>' . _('Comments') . '</th> - <th>' . _('Branch') . '</th> - <th>' . _('Order') . '</th> - <th>' . _('Total') . '</th> - <th>' . _('Allocated') . '</th> - <th>' . _('Balance') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - <th>' . _('More Info') . '</th> - </tr>'; +echo '<table class="selection">'; +$tableheader = '<tr> + <th>' . _('Type') . '</th> + <th>' . _('Number') . '</th> + <th>' . _('Date') . '</th> + <th>' . _('Branch') . '</th> + <th>' . _('Reference') . '</th> + <th>' . _('Comments') . '</th> + <th>' . _('Order') . '</th> + <th>' . _('Total') . '</th> + <th>' . _('Allocated') . '</th> + <th>' . _('Balance') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + <th>' . _('More Info') . '</th> + </tr>'; + +echo $tableheader; + $j = 1; -$k = 0;// Row colour counter. +$k=0; //row colour counter while ($myrow=DB_fetch_array($TransResult)) { - if ($k==1) { + if ($k==1){ echo '<tr class="EvenTableRows">'; - $k = 0; + $k=0; } else { echo '<tr class="OddTableRows">'; - $k = 1; + $k=1; } -/* $FormatedTranDate = ConvertSQLDate($myrow['trandate']);*/ + $FormatedTranDate = ConvertSQLDate($myrow['trandate']); - if ($_SESSION['InvoicePortraitFormat']==1){// Invoice/credits in portrait. + if ($_SESSION['InvoicePortraitFormat']==1){ //Invoice/credits in portrait $PrintCustomerTransactionScript = 'PrintCustTransPortrait.php'; - } else {// Produce pdfs in landscape. + } else { //produce pdfs in landscape $PrintCustomerTransactionScript = 'PrintCustTrans.php'; } - // All table-row (tag tr) must have 15 table-datacells (tag td). + $BaseFormatString = '<td>%s</td> + <td>%s</td> + <td>%s</td> + <td>%s</td> + <td>%s</td> + <td style="width:200px">%s</td> + <td>%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td>'; - $BaseTD10 = '<td>' . ConvertSQLDate($myrow['trandate']) . '</td> - <td>' . _($myrow['typename']) . '</td> - <td class="number">' . $myrow['transno'] . '</td> - <td>' . $myrow['reference'] . '</td> - <td>' . $myrow['invtext'] . '</td> - <td>' . $myrow['branchcode'] . '</td> - <td class="number">' . $myrow['order_'] . '</td> - <td class="number">' . locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']) . '</td> - <td class="number">' . locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']) . '</td> - <td class="number">' . locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']) . '</td>'; - $CreditInvoiceTD1 = '<td><a href="' . $RootPath . '/Credit_Invoice.php?InvoiceNumber=%s" title="' . - _('Click to credit the invoice') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/credit.gif" /> ' . _('Credit') . '</a></td>'; + $CreditInvoiceFormatString = '<td><a href="%s/Credit_Invoice.php?InvoiceNumber=%s">' . _('Credit ') . '<img src="%s/credit.gif" title="' . _('Click to credit the invoice') . '" alt="" /></a></td>'; - $AllocationTD1 = '<td><a href="' . $RootPath . '/CustomerAllocations.php?AllocTrans=%s" title="' . - _('Click to allocate funds') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/allocation.png" /> ' . _('Allocation') . '</a></td>'; + $PreviewInvoiceFormatString = '<td><a href="%s/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice">' . _('HTML ') . '<img src="%s/preview.gif" title="' . _('Click to preview the invoice') . '" alt="" /></a></td> + <td><a href="%s/%s?FromTransNo=%s&InvOrCredit=Invoice&PrintPDF=True">' . _('PDF ') . '<img src="%s/css/' . $Theme . '/images/pdf.png" title="' . _('Click for PDF') . '" alt="" /></a></td> + <td><a href="%s/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice">' . _('Email ') . '<img src="%s/email.gif" title="' . _('Click to email the invoice') . '" alt="" /></a></td>'; - $PreviewInvoiceTD3 = '<td><a href="' . $RootPath . '/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice" title="' . - _('Click to preview the invoice') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/preview.gif" /> ' . _('HTML') . '</a></td> - <td><a href="' . $RootPath .'/%s?FromTransNo=%s&InvOrCredit=Invoice&PrintPDF=True" title="' . - _('Click for PDF') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/pdf.png" /> ' . _('PDF') . ' </a></td> - <td><a href="' . $RootPath .'/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Invoice" title="' . - _('Click to email the invoice') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/email.gif" /> ' . _('Email') . '</a></td>'; + $PreviewCreditFormatString = '<td><a href="%s/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Credit">' . _('HTML ') . ' <IMG SRC="%s/preview.gif" title="' . _('Click to preview the credit note') . '" /></a></td> + <td><a href="%s/%s?FromTransNo=%s&InvOrCredit=Credit&PrintPDF=True">' . _('PDF ') . '<img src="%s/css/' . $Theme . '/images/pdf.png" title="' . _('Click for PDF') . '" alt="" /></a></td> + <td><a href="%s/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Credit">' . _('Email') . ' <img src="%s/email.gif" title="' . _('Click to email the credit note') . '" alt="" /></a></td>'; - $PreviewCreditTD3 = '<td><a href="' . $RootPath . '/PrintCustTrans.php?FromTransNo=%s&InvOrCredit=Credit" title="' . - _('Click to preview the credit note') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/preview.gif" /> ' . _('HTML') . '</a></td> - <td><a href="' . $RootPath . '/%s?FromTransNo=%s&InvOrCredit=Credit&PrintPDF=True" title="' . - _('Click for PDF') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/pdf.png" /> ' . _('PDF') . ' </a></td> - <td><a href="' . $RootPath . '/EmailCustTrans.php?FromTransNo=%s&InvOrCredit=Credit" title="' . - _('Click to email the credit note') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/email.gif" /> ' . _('Email') . '</a></td>'; - - $GLEntriesTD1 = '<td><a href="' . $RootPath . '/GLTransInquiry.php?TypeID=%s&TransNo=%s" target="_blank" title="' . - _('Click to view the GL entries') . '"><img alt="" src="' . $RootPath . - '/css/' . $Theme . '/images/gl.png" width="16" /> ' . _('GL Entries') . '</a></td>'; - /* assumed allowed page security token 3 allows the user to create credits for invoices */ - if (in_array(3,$_SESSION['AllowedPageSecurityTokens']) AND $myrow['type']==10) { + if (in_array(3,$_SESSION['AllowedPageSecurityTokens']) AND $myrow['type']==10){ /*Show a link to allow an invoice to be credited */ /* assumed allowed page security token 8 allows the user to see GL transaction information */ - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ + /* format string with GL inquiry options and for invoice to be credited */ - printf($BaseTD10 . $CreditInvoiceTD1 . $PreviewInvoiceTD3 . $GLEntriesTD1 . '</tr>', - // $CreditInvoiceTD1 parameters: + + printf($BaseFormatString . $CreditInvoiceFormatString . $PreviewInvoiceFormatString . + '<td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' + <img src="' .$RootPath. '/css/'.$Theme.'/images/gl.png" title="' . _('View the GL Entries') . '" alt="" /></a></td> + </tr>', + //$BaseFormatString parameters + $myrow['typename'], $myrow['transno'], - // $PreviewInvoiceTD3 parameters: + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + //$CreditInvoiceFormatString parameters + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + //$PreviewInvoiceFormatString parameters + $RootPath, $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], + $RootPath, + $RootPath, $myrow['transno'], - // $GLEntriesTD1 parameters: + $RootPath.'/css/'.$Theme.'/images', + //Parameter for string for GL Trans Inquiries + $RootPath, $myrow['type'], $myrow['transno']); + } else { //user does not have privileges to see GL inquiry stuff - } else {// No permission to view GL entries. - printf($BaseTD10 . $CreditInvoiceTD1 . $PreviewInvoiceTD3 . '<td> </td></tr>', - // $CreditInvoiceTD1 parameters: + printf($BaseFormatString . $CreditInvoiceFormatString . $PreviewInvoiceFormatString . '</tr>', + //BaseFormatString parameters + $myrow['typename'], $myrow['transno'], - // $PreviewInvoiceTD3 parameters: + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + //CreditInvoiceFormatString parameters + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + //$PreviewInvoiceFormatString parameters + $RootPath, $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], - $myrow['transno']); + $RootPath, + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images'); + } - } } elseif($myrow['type']==10) { /*its an invoice but not high enough priveliges to credit it */ - printf($BaseTD10 . '<td> </td>' . $PreviewInvoiceTD3 . '<td> </td></tr>', - // $PreviewInvoiceTD3 parameters: - $myrow['transno'], + + printf($BaseFormatString . + $PreviewInvoiceFormatString . + '</tr>', + //$BaseFormatString parameters + $myrow['typename'], + $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + //$PreviewInvoiceFormatString parameters + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], - $myrow['transno']); + $RootPath, + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images'); } elseif ($myrow['type']==11) { /*its a credit note */ - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { - printf($BaseTD10 . $AllocationTD1 . $PreviewCreditTD3 . $GLEntriesTD1 . '</tr>', - // $AllocationTD1 parameters: - $myrow['id'], - // $PreviewCreditTD3 parameters: + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ + printf($BaseFormatString . + $PreviewCreditFormatString . + '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="' .$RootPath .'/css/' . $Theme .'/images/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> + <td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <a><img src="' .$RootPath.'/css/'.$Theme.'/images/gl.png" title="' . _('View the GL Entries') . '" alt="" /></a></td></tr>', + //$BaseFormatString parameters + $myrow['typename'], $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + //$PreviewCreditFormatString parameters + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], + $RootPath, + $RootPath, $myrow['transno'], - // $GLEntriesTD1 parameters: + $RootPath.'/css/'.$Theme.'/images', + // hand coded format string for Allocations and GLTrans Inquiry parameters + $RootPath, + $myrow['id'], + $RootPath, $myrow['type'], $myrow['transno']); - - } else {// No permission to view GL entries. - printf($BaseTD10 . $AllocationTD1 . $PreviewCreditTD3 . '<td> </td></tr>', - // $AllocationTD1 parameters: - $myrow['id'], - // $PreviewCreditTD3 parameters: + } else { + printf($BaseFormatString . + $PreviewCreditFormatString . + '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="%s/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> + </tr>', + $myrow['typename'], $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + //$PreviewCreditFormatString parameters + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + $RootPath, $PrintCustomerTransactionScript, $myrow['transno'], - $myrow['transno']); - + $RootPath, + $RootPath, + $myrow['transno'], + $RootPath.'/css/'.$Theme.'/images', + //Parameters for hand coded string to show allocations + $RootPath, + $myrow['id'], + $RootPath.'/css/'.$Theme.'/images'); } } elseif ($myrow['type']==12 AND $myrow['totalamount']<0) { /*its a receipt which could have an allocation*/ //If security token 8 in the allowed page security tokens then assumed ok for GL trans inquiries - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { - printf($BaseTD10 . $AllocationTD1 . '<td> </td><td> </td><td> </td>' . $GLEntriesTD1 . '</tr>', - // $AllocationTD1 parameters: + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ + printf($BaseFormatString . + '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="' .$RootPath . '/css/' . $Theme .'/images/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> + <td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <img src="' .$RootPath . '/css/' . $Theme .'/images/gl.png" title="' . _('View the GL Entries') . '" alt="" /></a></td> + </tr>', + $myrow['typename'], + $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + $RootPath, $myrow['id'], - // $GLEntriesTD1 parameters: + $RootPath, $myrow['type'], $myrow['transno']); - - } else {// No permission to view GL entries. - printf($BaseTD10 . $AllocationTD1 . '<td> </td><td> </td><td> </td><td> </td></tr>', - // $AllocationTD1 parameters: + } else { //no permission for GLTrans Inquiries + printf($BaseFormatString . + '<td><a href="%s/CustomerAllocations.php?AllocTrans=%s">' . _('Allocation') . '<img src="' .$RootPath . '/css/' . $Theme .'/images/allocation.png" title="' . _('Click to allocate funds') . '" alt="" /></a></td> + </tr>', + $myrow['typename'], + $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + $RootPath, $myrow['id']); - } } elseif ($myrow['type']==12 AND $myrow['totalamount']>0) { /*its a negative receipt */ //If security token 8 in the allowed page security tokens then assumed ok for GL trans inquiries - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { - printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td>' . $GLEntriesTD1 . '</tr>', - // $GLEntriesTD1 parameters: + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ + printf($BaseFormatString . + '<td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <a></td></tr>', + $myrow['typename'], + $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + $RootPath, $myrow['type'], $myrow['transno']); - - } else {// No permission to view GL entries. - printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td><td> </td></tr>' - ); - + } else { //no permission for GLTrans Inquiries + printf($BaseFormatString . '<td></tr>', + $myrow['typename'], + $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces'])); } } else { //If security token 8 in the allowed page security tokens then assumed ok for GL trans inquiries - if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])) { - printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td>' . $GLEntriesTD1 . '</tr>', - // $GLEntriesTD1 parameters: + if ($_SESSION['CompanyRecord']['gllink_debtors']== 1 AND in_array(8,$_SESSION['AllowedPageSecurityTokens'])){ + printf($BaseFormatString . + '<td><a href="%s/GLTransInquiry.php?TypeID=%s&TransNo=%s">' . _('View GL Entries') . ' <a></td></tr>', + $myrow['typename'], + $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces']), + $RootPath, $myrow['type'], $myrow['transno']); - } else { - printf($BaseTD10 . '<td> </td><td> </td><td> </td><td> </td><td> </td></tr>' - ); + printf($BaseFormatString . '</tr>', + $myrow['typename'], + $myrow['transno'], + ConvertSQLDate($myrow['trandate']), + $myrow['branchcode'], + $myrow['reference'], + $myrow['invtext'], + $myrow['order_'], + locale_number_format($myrow['totalamount'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['allocated'],$CustomerRecord['decimalplaces']), + locale_number_format($myrow['totalamount']-$myrow['allocated'],$CustomerRecord['decimalplaces'])); } } Modified: trunk/CustomerReceipt.php =================================================================== --- trunk/CustomerReceipt.php 2014-09-08 02:05:18 UTC (rev 6869) +++ trunk/CustomerReceipt.php 2014-09-11 02:07:02 UTC (rev 6870) @@ -596,8 +596,10 @@ if ($_POST['Keywords']=='' AND $_POST['CustCode']=='' AND $_POST['CustInvNo']=='') { - - $msg=_('At least one Customer Name keyword OR an extract of a Customer Code must be entered for the search'); + $SQL = "SELECT debtorsmaster.debtorno, + debtorsmaster.name + FROM debtorsmaster + WHERE debtorsmaster.currcode= '" . $_SESSION['ReceiptBatch']->Currency . "'"; } else { if (mb_strlen($_POST['Keywords'])>0) { //insert wildcard characters in spaces @@ -623,7 +625,7 @@ WHERE debtortrans.transno " . LIKE . " '%" . $_POST['CustInvNo'] . "%' AND debtorsmaster.currcode= '" . $_SESSION['ReceiptBatch']->Currency . "'"; } - + } if ($_SESSION['SalesmanLogin'] != '') { $SQL .= " AND EXISTS ( SELECT * @@ -646,7 +648,7 @@ prnMsg( _('No customer records contain the selected text') . ' - ' . _('please alter your search criteria and try again'),'info'); } - } //one of keywords or custcode was more than a zero length string + //one of keywords or custcode was more than a zero length string } //end of if search if (isset($_POST['Select'])){ @@ -1034,6 +1036,7 @@ <th width="20%">' . _('Now Due') . '</th> <th width="20%">' . $_SESSION['PastDueDays1'] . '-' . $_SESSION['PastDueDays2'] . ' ' . _('Days Overdue') . '</th> <th width="20%">' . _('Over') . ' ' . $_SESSION['PastDueDays2'] . ' ' . _('Days Overdue') . '</th> + <th width="20%">' . _('Customer Transaction Inquiry') . '</th> </tr>'; echo '<tr> @@ -1042,6 +1045,7 @@ <td class="number">' . locale_number_format(($_SESSION['CustomerRecord']['due']-$_SESSION['CustomerRecord']['overdue1']),$_SESSION['CustomerRecord']['currdecimalplaces']) . '</td> <td class="number">' . locale_number_format(($_SESSION['CustomerRecord']['overdue1']-$_SESSION['CustomerRecord']['overdue2']) ,$_SESSION['CustomerRecord']['currdecimalplaces']) . '</td> <td class="number">' . locale_number_format($_SESSION['CustomerRecord']['overdue2'],$_SESSION['CustomerRecord']['currdecimalplaces']) . '</td> + <td><a href="CustomerInquiry.php?CustomerID=' . $_POST['CustomerID'] . '&Status=0" target="_blank">' . _('Inquiry') . '</td> </tr> </table> <br />'; @@ -1239,4 +1243,4 @@ echo '</div>'; echo '</form>'; include('includes/footer.inc'); -?> \ No newline at end of file +?> |
From: <te...@us...> - 2014-09-11 02:32:23
|
Revision: 6874 http://sourceforge.net/p/web-erp/reponame/6874 Author: tehonu Date: 2014-09-11 02:32:16 +0000 (Thu, 11 Sep 2014) Log Message: ----------- Empty gettext strings fixed. Reported by Harald. Modified Paths: -------------- trunk/PrintWOItemSlip.php trunk/WOCanBeProducedNow.php Modified: trunk/PrintWOItemSlip.php =================================================================== --- trunk/PrintWOItemSlip.php 2014-09-11 02:15:34 UTC (rev 6873) +++ trunk/PrintWOItemSlip.php 2014-09-11 02:32:16 UTC (rev 6874) @@ -167,11 +167,11 @@ $pdf->addTextWrap($Xpos,$YPos,150,$FontSize,_('Component Code'), 'left'); $pdf->addTextWrap(150,$YPos,50,$FontSize,_('Qty BOM'), 'right'); - $pdf->addTextWrap(200,$YPos,30,$FontSize,_(''), 'left'); + $pdf->addTextWrap(200,$YPos,30,$FontSize,'', 'left'); $pdf->addTextWrap(230,$YPos,50,$FontSize,_('Qty Needed'), 'right'); - $pdf->addTextWrap(280,$YPos,30,$FontSize,_(''), 'left'); + $pdf->addTextWrap(280,$YPos,30,$FontSize,'', 'left'); $pdf->addTextWrap(310,$YPos,50,$FontSize,_('Shrinkage'), 'right'); - $pdf->addTextWrap(360,$YPos,30,$FontSize,_(''), 'left'); + $pdf->addTextWrap(360,$YPos,30,$FontSize,'', 'left'); $FontSize=10; $YPos -= $line_height; Modified: trunk/WOCanBeProducedNow.php =================================================================== --- trunk/WOCanBeProducedNow.php 2014-09-11 02:15:34 UTC (rev 6873) +++ trunk/WOCanBeProducedNow.php 2014-09-11 02:32:16 UTC (rev 6874) @@ -50,7 +50,7 @@ <th>' . _('Needed') . '</th> <th>' . _('Shrinkage') . '</th> <th>' . _('UOM') . '</th> - <th>' . _('') . '</th> + <th>' . '' . '</th> <th>' . _('Result') . '</th> </tr>'; |
From: <te...@us...> - 2014-09-11 09:35:06
|
Revision: 6875 http://sourceforge.net/p/web-erp/reponame/6875 Author: tehonu Date: 2014-09-11 09:34:57 +0000 (Thu, 11 Sep 2014) Log Message: ----------- Added flag "Used for WO Productions" in locations table. On WO related scripts, show only the locations with this flag set to 1 Modified Paths: -------------- trunk/Locations.php trunk/SelectWorkOrder.php trunk/WOCanBeProducedNow.php trunk/WorkOrderEntry.php trunk/sql/mysql/upgrade4.11-4.12.sql Modified: trunk/Locations.php =================================================================== --- trunk/Locations.php 2014-09-11 02:32:16 UTC (rev 6874) +++ trunk/Locations.php 2014-09-11 09:34:57 UTC (rev 6875) @@ -71,7 +71,8 @@ cashsalecustomer ='" . $_POST['CashSaleCustomer'] . "', cashsalebranch ='" . $_POST['CashSaleBranch'] . "', managed = '" . $_POST['Managed'] . "', - internalrequest = '" . $_POST['InternalRequest'] . "' + internalrequest = '" . $_POST['InternalRequest'] . "', + usedforwo = '" . $_POST['UsedForWO'] . "' WHERE loccode = '" . $SelectedLocation . "'"; $ErrMsg = _('An error occurred updating the') . ' ' . $SelectedLocation . ' ' . _('location record because'); @@ -98,6 +99,7 @@ unset($SelectedLocation); unset($_POST['Contact']); unset($_POST['InternalRequest']); + unset($_POST['UsedForWO']); } elseif ($InputError !=1) { @@ -116,6 +118,13 @@ $_POST['InternalRequest'] = 0; } + /* Set the usedToWO field to 1 if it is checked, otherwise 0 */ + if($_POST['UsedForWO'] == 'Yes') { + $_POST['UsedForWO'] = 1; + } else { + $_POST['UsedForWO'] = 0; + } + /*SelectedLocation is null cos no item selected on first time round so must be adding a record must be submitting new entries in the new Location form */ $sql = "INSERT INTO locations (loccode, @@ -134,7 +143,8 @@ cashsalecustomer, cashsalebranch, managed, - internalrequest) + internalrequest, + usedforwo) VALUES ('" . $_POST['LocCode'] . "', '" . $_POST['LocationName'] . "', '" . $_POST['DelAdd1'] ."', @@ -151,7 +161,8 @@ '" . $_POST['CashSaleCustomer'] . "', '" . $_POST['CashSaleBranch'] . "', '" . $_POST['Managed'] . "', - '" . $_POST['InternalRequest'] . "')"; + '" . $_POST['InternalRequest'] ."', + '" . $_POST['UsedForWO'] . "')"; $ErrMsg = _('An error occurred inserting the new location record because'); $DbgMsg = _('The SQL used to insert the location record was'); @@ -212,6 +223,7 @@ unset($SelectedLocation); unset($_POST['Contact']); unset($_POST['InternalRequest']); + unset($_POST['UsedForWO']); } @@ -470,7 +482,8 @@ cashsalecustomer, cashsalebranch, managed, - internalrequest + internalrequest, + usedforwo FROM locations WHERE loccode='" . $SelectedLocation . "'"; @@ -494,6 +507,7 @@ $_POST['CashSaleBranch'] = $myrow['cashsalebranch']; $_POST['Managed'] = $myrow['managed']; $_POST['InternalRequest'] = $myrow['internalrequest']; + $_POST['UsedForWO'] = $myrow['usedforwo']; echo '<input type="hidden" name="SelectedLocation" value="' . $SelectedLocation . '" />'; @@ -652,7 +666,23 @@ } else { echo '<option value="0">' . _('No') . '</option>'; } + echo '</tr>'; + echo '<tr> + <td>' . _('Use for Work Order Productions?') . ':</td> + <td><select name="UsedForWO">'; + if ($_POST['UsedForWO']==1){ + echo '<option selected="selected" value="1">' . _('Yes') . '</option>'; + } else { + echo '<option value="1">' . _('Yes') . '</option>'; + } + if ($_POST['UsedForWO']==0){ + echo '<option selected="selected" value="0">' . _('No') . '</option>'; + } else { + echo '<option value="0">' . _('No') . '</option>'; + } + echo '</tr>'; + /* This functionality is not written yet ... <tr><td><?php echo _('Enable Warehouse Management') . ':'; ?></td> Modified: trunk/SelectWorkOrder.php =================================================================== --- trunk/SelectWorkOrder.php 2014-09-11 02:32:16 UTC (rev 6874) +++ trunk/SelectWorkOrder.php 2014-09-11 09:34:57 UTC (rev 6875) @@ -133,7 +133,11 @@ echo _('Work Order number') . ': <input type="text" name="WO" autofocus="autofocus" maxlength="8" size="9" /> ' . _('Processing at') . ':<select name="StockLocation"> '; $sql = "SELECT locations.loccode, locationname FROM locations - INNER JOIN locationusers ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canview=1"; + INNER JOIN locationusers + ON locationusers.loccode=locations.loccode + AND locationusers.userid='" . $_SESSION['UserID'] . "' + AND locationusers.canview=1 + WHERE locations.usedforwo = 1"; $resultStkLocs = DB_query($sql,$db); Modified: trunk/WOCanBeProducedNow.php =================================================================== --- trunk/WOCanBeProducedNow.php 2014-09-11 02:32:16 UTC (rev 6874) +++ trunk/WOCanBeProducedNow.php 2014-09-11 09:34:57 UTC (rev 6875) @@ -226,7 +226,8 @@ INNER JOIN locationusers ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' - AND locationusers.canview=1"; + AND locationusers.canview=1 + WHERE locations.usedforwo = 1"; $LocnResult=DB_query($sql,$db); Modified: trunk/WorkOrderEntry.php =================================================================== --- trunk/WorkOrderEntry.php 2014-09-11 02:32:16 UTC (rev 6874) +++ trunk/WorkOrderEntry.php 2014-09-11 09:34:57 UTC (rev 6875) @@ -113,7 +113,7 @@ INNER JOIN stockcategory ON stockmaster.categoryid=stockcategory.categoryid WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='M') - AND stockmaster.description " . LIKE . " '$SearchString' + AND stockmaster.description " . LIKE . " '" . $SearchString . "' AND stockmaster.discontinued=0 AND mbflag='M' ORDER BY stockmaster.stockid"; @@ -565,8 +565,12 @@ echo '<tr><td class="label">' . _('Work Order Reference') . ':</td><td>' . $_POST['WO'] . '</td></tr>'; echo '<tr><td class="label">' . _('Factory Location') .':</td> <td><select name="StockLocation" onChange="ReloadForm(form1.submit)">'; -$LocResult = DB_query("SELECT locations.loccode,locationname FROM locations - INNER JOIN locationusers ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canupd=1",$db); +$LocResult = DB_query("SELECT locations.loccode,locationname + FROM locations + INNER JOIN locationusers + ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' + AND locationusers.canupd=1 + WHERE locations.usedforwo = 1",$db); while ($LocRow = DB_fetch_array($LocResult)){ if ($_POST['StockLocation']==$LocRow['loccode']){ echo '<option selected="True" value="' . $LocRow['loccode'] .'">' . $LocRow['locationname'] . '</option>'; Modified: trunk/sql/mysql/upgrade4.11-4.12.sql =================================================================== --- trunk/sql/mysql/upgrade4.11-4.12.sql 2014-09-11 02:32:16 UTC (rev 6874) +++ trunk/sql/mysql/upgrade4.11-4.12.sql 2014-09-11 09:34:57 UTC (rev 6875) @@ -80,6 +80,7 @@ INSERT INTO `scripts` ( `script` , `pagesecurity` , `description` ) VALUES ('WOCanBeProducedNow.php', '4', 'List of WO items that can be produced with available stock in location'); INSERT INTO `scripts` ( `script` , `pagesecurity` , `description` ) VALUES ('PrintWOItemSlip.php', '4', 'PDF WO Item production Slip '); +ALTER TABLE `locations` ADD `usedforwo` TINYINT( 4 ) NOT NULL DEFAULT '1' AFTER `internalrequest`; UPDATE config SET confvalue='4.12' WHERE confname='VersionNumber'; |
From: <te...@us...> - 2014-09-11 09:39:35
|
Revision: 6876 http://sourceforge.net/p/web-erp/reponame/6876 Author: tehonu Date: 2014-09-11 09:39:28 +0000 (Thu, 11 Sep 2014) Log Message: ----------- More on "used for WO Productions" flag Modified Paths: -------------- trunk/WorkOrderIssue.php trunk/WorkOrderReceive.php Modified: trunk/WorkOrderIssue.php =================================================================== --- trunk/WorkOrderIssue.php 2014-09-11 09:34:57 UTC (rev 6875) +++ trunk/WorkOrderIssue.php 2014-09-11 09:39:28 UTC (rev 6876) @@ -581,8 +581,12 @@ <td>'; if (!isset($_POST['IssueItem'])){ - $LocResult = DB_query("SELECT locations.loccode, locationname FROM locations - INNER JOIN locationusers ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canupd=1",$db); + $LocResult = DB_query("SELECT locations.loccode,locationname + FROM locations + INNER JOIN locationusers + ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' + AND locationusers.canupd=1 + WHERE locations.usedforwo = 1",$db); echo '<select name="FromLocation">'; Modified: trunk/WorkOrderReceive.php =================================================================== --- trunk/WorkOrderReceive.php 2014-09-11 09:34:57 UTC (rev 6875) +++ trunk/WorkOrderReceive.php 2014-09-11 09:39:28 UTC (rev 6876) @@ -847,7 +847,12 @@ if (!isset($_POST['IntoLocation'])){ $_POST['IntoLocation']=$WORow['loccode']; } -$LocResult = DB_query("SELECT locations.loccode, locationname FROM locations INNER JOIN locationusers ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canupd=1",$db); +$LocResult = DB_query("SELECT locations.loccode,locationname + FROM locations + INNER JOIN locationusers + ON locationusers.loccode=locations.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' + AND locationusers.canupd=1 + WHERE locations.usedforwo = 1",$db); while ($LocRow = DB_fetch_array($LocResult)){ if ($_POST['IntoLocation'] ==$LocRow['loccode']){ echo '<option selected="selected" value="' . $LocRow['loccode'] .'">' . $LocRow['locationname'] . '</option>'; |