This list is closed, nobody may subscribe to it.
2011 |
Jan
(14) |
Feb
(42) |
Mar
(56) |
Apr
(60) |
May
(54) |
Jun
(48) |
Jul
(74) |
Aug
(52) |
Sep
(68) |
Oct
(64) |
Nov
(42) |
Dec
(62) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2012 |
Jan
(142) |
Feb
(270) |
Mar
(374) |
Apr
(230) |
May
(214) |
Jun
(116) |
Jul
(234) |
Aug
(66) |
Sep
(120) |
Oct
(16) |
Nov
(17) |
Dec
(41) |
2013 |
Jan
(19) |
Feb
(18) |
Mar
(8) |
Apr
(40) |
May
(121) |
Jun
(42) |
Jul
(127) |
Aug
(145) |
Sep
(27) |
Oct
(38) |
Nov
(83) |
Dec
(61) |
2014 |
Jan
(33) |
Feb
(35) |
Mar
(59) |
Apr
(41) |
May
(38) |
Jun
(45) |
Jul
(17) |
Aug
(58) |
Sep
(46) |
Oct
(51) |
Nov
(55) |
Dec
(36) |
2015 |
Jan
(57) |
Feb
(67) |
Mar
(70) |
Apr
(34) |
May
(32) |
Jun
(11) |
Jul
(3) |
Aug
(17) |
Sep
(16) |
Oct
(13) |
Nov
(30) |
Dec
(30) |
2016 |
Jan
(17) |
Feb
(12) |
Mar
(17) |
Apr
(20) |
May
(47) |
Jun
(15) |
Jul
(13) |
Aug
(30) |
Sep
(32) |
Oct
(20) |
Nov
(32) |
Dec
(24) |
2017 |
Jan
(16) |
Feb
|
Mar
(11) |
Apr
(11) |
May
(5) |
Jun
(42) |
Jul
(9) |
Aug
(10) |
Sep
(14) |
Oct
(15) |
Nov
(2) |
Dec
(29) |
2018 |
Jan
(28) |
Feb
(49) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <rc...@us...> - 2015-12-28 02:56:25
|
Revision: 7430 http://sourceforge.net/p/web-erp/reponame/7430 Author: rchacon Date: 2015-12-28 02:56:23 +0000 (Mon, 28 Dec 2015) Log Message: ----------- In UserGLAccounts.php, add warning if the user does not have access permissions to GL accounts. Modified Paths: -------------- trunk/UserGLAccounts.php trunk/locale/es_ES.utf8/LC_MESSAGES/messages.mo trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po Modified: trunk/UserGLAccounts.php =================================================================== --- trunk/UserGLAccounts.php 2015-12-27 20:33:43 UTC (rev 7429) +++ trunk/UserGLAccounts.php 2015-12-28 02:56:23 UTC (rev 7430) @@ -43,8 +43,7 @@ if(isset($_POST['Process'])) { prnMsg(_('You have not selected any user'), 'error'); } - echo '<br />', - '<form action="', htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8'), '" method="post">', + echo '<form action="', htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8'), '" method="post">', '<input name="FormID" type="hidden" value="', $_SESSION['FormID'], '" />', '<table class="selection"> <tr> @@ -167,40 +166,42 @@ ON glaccountusers.accountcode=chartmaster.accountcode WHERE glaccountusers.userid='" . $SelectedUser . "' ORDER BY chartmaster.accountcode ASC"); + if(DB_num_rows($Result)>0) {// If the user has access permissions to one or more GL accounts: + $k = 0; //row colour counter + while ($MyRow = DB_fetch_array($Result)) { + if($k == 1) { + echo '<tr class="EvenTableRows">'; + $k = 0; + } else { + echo '<tr class="OddTableRows">'; + $k = 1; + } + echo '<td class="text">', $MyRow['accountcode'], '</td> + <td class="text">', $MyRow['accountname'], '</td> + <td class="centre">'; + if($MyRow['canview'] == 1) { + echo _('Yes'); + } else { + echo _('No'); + } + echo '</td> + <td class="centre">'; - $k = 0; //row colour counter - - while ($MyRow = DB_fetch_array($Result)) { - if($k == 1) { - echo '<tr class="EvenTableRows">'; - $k = 0; - } else { - echo '<tr class="OddTableRows">'; - $k = 1; - } - echo '<td class="text">', $MyRow['accountcode'], '</td> - <td class="text">', $MyRow['accountname'], '</td> - <td class="centre">'; - if($MyRow['canview'] == 1) { - echo _('Yes'); - } else { - echo _('No'); - } - echo '</td> - <td class="centre">'; - - $ScriptName = htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'); - if($MyRow['canupd'] == 1) { - echo _('Yes'), '</td> - <td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&ToggleUpdate=0" onclick="return confirm(\'', _('Are you sure you wish to remove Update for this GL Account?'), '\');">', _('Remove Update'); - } else { - echo _('No'), '</td> - <td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&ToggleUpdate=1" onclick="return confirm(\'', _('Are you sure you wish to add Update for this GL Account?'), '\');">', _('Add Update'); - } - echo '</a></td> - <td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&delete=yes" onclick="return confirm(\'', _('Are you sure you wish to un-authorise this GL Account?'), '\');">', _('Un-authorise'), '</a></td> - </tr>'; - }// End while list loop. + $ScriptName = htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'); + if($MyRow['canupd'] == 1) { + echo _('Yes'), '</td>', + '<td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&ToggleUpdate=0" onclick="return confirm(\'', _('Are you sure you wish to remove Update for this GL Account?'), '\');">', _('Remove Update'); + } else { + echo _('No'), '</td>', + '<td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&ToggleUpdate=1" onclick="return confirm(\'', _('Are you sure you wish to add Update for this GL Account?'), '\');">', _('Add Update'); + } + echo '</a></td>', + '<td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&delete=yes" onclick="return confirm(\'', _('Are you sure you wish to un-authorise this GL Account?'), '\');">', _('Un-authorise'), '</a></td>', + '</tr>'; + }// End while list loop. + } else {// If the user does not have access permissions to GL accounts: + echo '<tr><td class="centre" colspan="6">', _('User does not have access permissions to GL accounts'), '</td></tr>'; + } echo '</tbody></table>', '<br />', '<form action="', htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8'), '" method="post">', 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 2015-12-27 20:33:43 UTC (rev 7429) +++ trunk/locale/es_ES.utf8/LC_MESSAGES/messages.po 2015-12-28 02:56:23 UTC (rev 7430) @@ -8,7 +8,7 @@ "Project-Id-Version: webERP 4.12.2\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2015-09-14 09:07-0600\n" -"PO-Revision-Date: 2015-09-21 09:50-0600\n" +"PO-Revision-Date: 2015-12-27 20:50-0600\n" "Last-Translator: Rafael Chacon <raf...@gm...>\n" "Language-Team: TecnoSoluciones.com <web...@te...>\n" "Language: es_ES\n" @@ -1816,7 +1816,7 @@ #: SupplierTypes.php:132 Suppliers.php:672 Z_DeleteInvoice.php:178 #: includes/DefineOfferClass.php:134 msgid "has been deleted" -msgstr "ha sido eliminado" +msgstr "ha sido suprimido" #: Areas.php:149 Areas.php:222 msgid "Area Name" @@ -3082,7 +3082,7 @@ #: PcExpensesTypeTab.php:212 PurchaseByPrefSupplier.php:317 #: StockCounts.php:121 UserLocations.php:120 UserLocations.php:236 msgid "Not Yet Selected" -msgstr "Aún NO Seleccionado" +msgstr "Aún no seleccionado" #: BankAccountUsers.php:129 BankAccountUsers.php:228 CustomerReceipt.php:947 #: CustomerReceipt.php:1161 CustomerTypes.php:269 ExchangeRateTrend.php:56 @@ -3096,7 +3096,7 @@ #: SalesTypes.php:282 SupplierTypes.php:236 UserLocations.php:137 #: UserLocations.php:255 Z_CheckDebtorsControl.php:61 msgid "Accept" -msgstr "Guardar" +msgstr "Aceptar" #: BankAccountUsers.php:130 BankAccountUsers.php:229 #: CustomerAllocations.php:450 CustomerReceipt.php:1162 @@ -7082,7 +7082,7 @@ #: CounterReturns.php:1659 CounterSales.php:2221 SelectOrderItems.php:1596 msgid "Enter partial Description" -msgstr "Introducir una parte de la descripción" +msgstr "Introducir descripción parcial" #: CounterReturns.php:1667 CounterSales.php:2232 SelectOrderItems.php:1615 msgid "Use Quick Entry" @@ -14521,7 +14521,7 @@ #: GLJournal.php:128 msgid "Enter Another General Ledger Journal" -msgstr "Introduzca otro Diario Contable" +msgstr "Introducir otro diario contable" #: GLJournal.php:154 GLJournal.php:191 msgid "" @@ -15149,7 +15149,7 @@ #: GoodsReceived.php:200 msgid "Enter Serial Nos" -msgstr "Introduzca Números de Serie" +msgstr "Introducir números de serie" #: GoodsReceived.php:203 msgid "Enter Batches" @@ -15748,7 +15748,7 @@ #: ImportBankTransAnalysis.php:53 ImportBankTransAnalysis.php:315 #: SuppTransGLAnalysis.php:29 SuppTransGLAnalysis.php:234 msgid "Enter GL Line" -msgstr "Introduzca Fila Contable" +msgstr "Introducir línea contable" #: ImportBankTransAnalysis.php:61 SuppTransGLAnalysis.php:37 msgid "You must select a general ledger code from the list below" @@ -15806,7 +15806,7 @@ #: ImportBankTransAnalysis.php:142 ImportBankTransAnalysis.php:144 #: Z_ImportGLTransactions.php:238 msgid "GL Payment" -msgstr "" +msgstr "Pago contable" #: ImportBankTransAnalysis.php:164 msgid "Receipt to Customer Account" @@ -15815,11 +15815,11 @@ #: ImportBankTransAnalysis.php:173 ImportBankTransAnalysis.php:175 #: Z_ImportGLTransactions.php:239 msgid "GL Receipt" -msgstr "" +msgstr "Recibo contable" #: ImportBankTransAnalysis.php:203 msgid "General ledger Analysis" -msgstr "" +msgstr "Análisis contable" #: ImportBankTransAnalysis.php:231 msgid "Total of GL Entries" @@ -19509,7 +19509,7 @@ #: PDFOrderStatus.php:325 PO_Header.php:794 PO_OrderDetails.php:142 msgid "Not yet printed" -msgstr "Aún sin imprimir" +msgstr "Aún no impreso" #: PDFOrderStatus.php:353 PDFOrdersInvoiced.php:350 PO_Items.php:766 msgid "Complete" @@ -19673,7 +19673,7 @@ #: PDFPickingList.php:151 msgid "Enter Another Date" -msgstr "Introduzca otra fecha" +msgstr "Introducir otra fecha" #: PDFPickingList.php:204 includes/PDFPickingListHeader.inc:12 #: includes/DatabaseTranslations.php:33 @@ -21454,7 +21454,7 @@ #: PO_Items.php:818 msgid "Not yet purchased" -msgstr "Todavía no ha comprado" +msgstr "Aún no comprado" #: PO_Items.php:825 SuppFixedAssetChgs.php:123 msgid "New Fixed Asset" @@ -22365,7 +22365,7 @@ #: Payments.php:620 msgid "Enter another General Ledger Payment" -msgstr "Introduzca otro pago Contable" +msgstr "Introducir otro pago contable" #: Payments.php:657 msgid "The Cheque/Voucher number has already been used" @@ -22453,7 +22453,7 @@ #: Payments.php:978 Payments.php:983 msgid "Enter GL Account Manually" -msgstr "Introduzca manualmente la cuenta contable" +msgstr "Introducir manualmente la cuenta contable" #: Payments.php:979 Payments.php:984 msgid "The account code" @@ -24893,7 +24893,7 @@ #: PurchaseByPrefSupplier.php:295 msgid "has been created." -msgstr "" +msgstr "ha sido creado." #: PurchaseByPrefSupplier.php:295 msgid "Total order value of" @@ -25040,7 +25040,7 @@ #: QATests.php:248 QATests.php:393 msgid "Group By" -msgstr "" +msgstr "Grupo por" #: QATests.php:249 msgid "" @@ -26142,7 +26142,7 @@ #: SalesAnalRepts.php:55 SalesAnalRepts.php:57 msgid "Not Used" -msgstr "No Usado" +msgstr "No usado" #: SalesAnalRepts.php:84 msgid "The report heading must be more than two characters long" @@ -27319,7 +27319,7 @@ #: SelectAsset.php:71 msgid "Enter partial description" -msgstr "Ingrese la descripción parcial" +msgstr "Introducir descripción parcial" #: SelectAsset.php:104 msgid "Enter partial asset code" @@ -27417,7 +27417,7 @@ #: SelectContract.php:51 msgid "Not Yet Quoted" -msgstr "Aún No Cotizado" +msgstr "Aún no cotizado" #: SelectContract.php:52 msgid "Quoted - No Order Placed" @@ -28044,7 +28044,7 @@ #: SelectOrderItems.php:560 msgid "Enter an Order or Quotation" -msgstr "Indique un pedido o cotización" +msgstr "Introducir un pedido o cotización" #: SelectOrderItems.php:560 msgid "Search for the Customer Branch." @@ -28386,7 +28386,7 @@ #: SelectProduct.php:213 SelectProduct.php:226 SelectProduct.php:227 msgid "Not Set" -msgstr "" +msgstr "No ajustado" #: SelectProduct.php:297 msgid "" @@ -31412,7 +31412,7 @@ #: StockCounts.php:217 msgid "Delete?" -msgstr "¿Suprimir?\t" +msgstr "¿Suprimir?" #: StockCounts.php:232 msgid "Save Changes" @@ -32381,7 +32381,7 @@ #: StockTransfers.php:134 msgid "Enter another Transfer" -msgstr "Introduzca otra Transferencia" +msgstr "Introducir otra transferencia" #: StockTransfers.php:177 WorkOrderEntry.php:339 msgid "The quantity entered must be a positive number greater than zero" @@ -33216,7 +33216,7 @@ #: SuppFixedAssetChgs.php:160 msgid "Enter Fixed Asset" -msgstr "Introduzca el activo fijo" +msgstr "Introducir activo fijo" #: SuppInvGRNs.php:12 msgid "Enter Supplier Invoice Against Goods Received" @@ -34139,7 +34139,7 @@ #: SupplierCredit.php:455 SupplierInvoice.php:825 msgid "General Ledger Analysis" -msgstr "Análisis Contable" +msgstr "Análisis contable" #: SupplierCredit.php:488 SupplierInvoice.php:850 msgid "Total GL Analysis" @@ -34468,7 +34468,7 @@ #: SupplierCredit.php:1330 msgid "Enter another Credit Note for this Supplier" -msgstr "Ingrese otra nota de Crédito para este proveedor" +msgstr "Introducir otra nota de crédito para este proveedor" #: SupplierInquiry.php:6 msgid "Supplier Inquiry" @@ -34854,7 +34854,7 @@ #: SupplierInvoice.php:1886 msgid "Enter another Invoice for this Supplier" -msgstr "Introduzca otra Factura para este proveedor" +msgstr "Introducir otra factura para este proveedor" #: SupplierInvoice.php:1888 msgid "Enter payment" @@ -37480,7 +37480,7 @@ #: TaxGroups.php:242 msgid "Enter Group" -msgstr "Guardar/Cambiar Nombre" +msgstr "Introducir grupo" #: TaxGroups.php:285 TaxGroups.php:338 msgid "Calculation Order" @@ -40328,7 +40328,7 @@ #: Z_ChangeLocationCode.php:246 msgid "Deleting the old location record" -msgstr "Eliminando el antiguo registro de localidad" +msgstr "Suprimiendo el registro de ubicación viejo" #: Z_ChangeLocationCode.php:248 msgid "The SQL to delete the old location record failed" @@ -40431,7 +40431,7 @@ #: Z_ChangeStockCategory.php:103 msgid "Deleting the old stock category record" -msgstr "La eliminación de la categoría del registro de existencias antiguo" +msgstr "Suprimiendo el registro de la categoría de inventario viejo" #: Z_ChangeStockCategory.php:105 msgid "The SQL to delete the old stock category record failed" @@ -40506,7 +40506,7 @@ #: Z_ChangeStockCode.php:191 msgid "Deleting the old stock master record" -msgstr "Eliminando antiguo maestro de existencias" +msgstr "Suprimiendo el registro maestro de inventario viejo" #: Z_ChangeStockCode.php:193 msgid "The SQL to delete the old stock master record failed" @@ -41258,7 +41258,7 @@ #: Z_DeleteSalesTransActions.php:117 msgid "Deleting all Purchase Orders" -msgstr "Borrando todas las Órdenes de Compra" +msgstr "Suprimiendo todas las órdenes de compra" #: Z_DeleteSalesTransActions.php:119 msgid "" @@ -41902,7 +41902,7 @@ #: Z_ImportGLTransactions.php:50 msgid "File contains incorrect headers" -msgstr "" +msgstr "Archivo contiene encabezados incorrectos" #: Z_ImportGLTransactions.php:98 msgid "Account code " @@ -42398,7 +42398,7 @@ #: Z_ReverseSuppPaymentRun.php:32 msgid "Deleting payment number" -msgstr "Eliminado pago número" +msgstr "Suprimiendo número de pago" #: Z_ReverseSuppPaymentRun.php:32 msgid "to supplier code" @@ -46873,7 +46873,7 @@ #: includes/SelectOrderItems_IntoCart.inc:65 msgid "Obsolete Item" -msgstr "Artículo Obsoleto" +msgstr "Artículo obsoleto" #: includes/SelectOrderItems_IntoCart.inc:182 msgid "Sell through support available and applied of" @@ -48754,7 +48754,7 @@ #: includes/DefineCartClass.php:230 msgid "Deleted Line Number" -msgstr "Número de Línea Eliminado" +msgstr "Número de línea suprimido" #: includes/DefineCartClass.php:230 msgid "from existing Order Number" @@ -50519,7 +50519,7 @@ #: reportwriter/languages/en_US/reports.php:68 msgid "Fifth" -msgstr "" +msgstr "Quinto" #: reportwriter/languages/en_US/reports.php:69 msgid "Filter" @@ -50539,7 +50539,7 @@ #: reportwriter/languages/en_US/reports.php:75 msgid "Fourth" -msgstr "" +msgstr "Cuarto" #: reportwriter/languages/en_US/reports.php:78 msgid "Inactive" @@ -50660,7 +50660,7 @@ #: reportwriter/languages/en_US/reports.php:133 msgid "Go Back" -msgstr "" +msgstr "Volver" #: reportwriter/languages/en_US/reports.php:135 msgid "Change" @@ -50728,7 +50728,7 @@ #: reportwriter/languages/en_US/reports.php:160 msgid "Grouped by:" -msgstr "" +msgstr "Agrupado por:" #: reportwriter/languages/en_US/reports.php:161 msgid "Sorted by:" @@ -50877,7 +50877,7 @@ #: reportwriter/languages/en_US/reports.php:198 msgid "Enter a New Field" -msgstr "" +msgstr "Introducir un campo nuevo" #: reportwriter/languages/en_US/reports.php:199 msgid "Field List" @@ -51279,7 +51279,7 @@ #: reportwriter/languages/en_US/reports.php:336 msgid "Green" -msgstr "" +msgstr "Verde" #: reportwriter/languages/en_US/reports.php:337 msgid "White" |
From: <rc...@us...> - 2015-12-27 20:33:46
|
Revision: 7429 http://sourceforge.net/p/web-erp/reponame/7429 Author: rchacon Date: 2015-12-27 20:33:43 +0000 (Sun, 27 Dec 2015) Log Message: ----------- Minor changes. Modified Paths: -------------- trunk/UserBankAccounts.php Modified: trunk/UserBankAccounts.php =================================================================== --- trunk/UserBankAccounts.php 2015-12-27 20:11:43 UTC (rev 7428) +++ trunk/UserBankAccounts.php 2015-12-27 20:33:43 UTC (rev 7429) @@ -1,10 +1,11 @@ <?php +/* $Id: UserBankAccounts.php 7398 2015-11-24 19:59:10Z tehonu $*/ +/* Maintains table bankaccountusers (Authorized users to work with a bank account in webERP). */ include('includes/session.inc'); -$Title = _('Bank Account Users');;// Screen identificator. -$ViewTopic = 'GeneralLedger';// Filename's id in ManualContents.php's TOC. -/* To do this section in the manual. -$BookMark = 'UserBankAccounts';// Anchor's id in the manual's html document.*/ +$Title = _('Bank Account Users'); +$ViewTopic = 'GeneralLedger'; +$BookMark = 'UserBankAccounts'; include('includes/header.inc'); echo '<p class="page_title_text"><img src="' . $RootPath . '/css/' . $Theme . '/images/money_add.png" title="' . _('User Authorised Bank Accounts') . '" alt="" />' . ' ' . $Title . '</p>'; |
From: <rc...@us...> - 2015-12-27 20:11:46
|
Revision: 7428 http://sourceforge.net/p/web-erp/reponame/7428 Author: rchacon Date: 2015-12-27 20:11:43 +0000 (Sun, 27 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/UserGLAccounts.php trunk/doc/Change.log Modified: trunk/UserGLAccounts.php =================================================================== --- trunk/UserGLAccounts.php 2015-12-27 19:59:10 UTC (rev 7427) +++ trunk/UserGLAccounts.php 2015-12-27 20:11:43 UTC (rev 7428) @@ -1,5 +1,5 @@ <?php -/* $Id: UserGLAccounts.php 6806 2013-09-28 05:10:46Z daintree $*/ +/* $Id: UserGLAccounts.php 7427 2015-12-27 19:59:10Z rchacon $*/ /* Maintenance of GL Accounts allowed for a user. */ include('includes/session.inc'); Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-27 19:59:10 UTC (rev 7427) +++ trunk/doc/Change.log 2015-12-27 20:11:43 UTC (rev 7428) @@ -1,6 +1,6 @@ webERP Change Log -27/12/15 RChacon: On UserGLAccounts.php: Fix script name; add $ViewTopic and $BookMark; improve $SelectedUser validation; improve page_title_text; improve select user; regroup modify access permission code (improve logic); add classes to table elements; transalate database "0" and "1" to human "No" and "Yes"; simplify and tide code; modify prnMsg from multiple part sentence to one part sentence (better to trasnlate when language use a different gramar structrure fron English); add "Print This", "Select A Different User" and "Return" buttons. Add info to ManualGeneralLedger.html. +27/12/15 RChacon: On UserGLAccounts.php: Fix script name; add $ViewTopic and $BookMark; improve $SelectedUser validation; improve page_title_text; improve select user; regroup modify access permission code (improve logic); add classes to table elements; translate database "0" and "1" to human "No" and "Yes"; simplify and tide code; modify prnMsg from multiple part sentence to one part sentence (better to translate when language use a different grammar structure from English); add "Print This", "Select A Different User" and "Return" buttons. Add info to ManualGeneralLedger.html. 26/12/2015 Exson: Add items not received information on outstanding po inquiry screen in PO_SelectOSPurchOrder.php. 24/12/15 Exson: Add supplier no as a option for supplier transaction inquiry in SupplierTransInquiry.php. 24/12/15 Exson: Add width of printed text to make day to appear in PDFOstdgGRNsPageHeader.inc. |
From: <rc...@us...> - 2015-12-27 19:59:12
|
Revision: 7427 http://sourceforge.net/p/web-erp/reponame/7427 Author: rchacon Date: 2015-12-27 19:59:10 +0000 (Sun, 27 Dec 2015) Log Message: ----------- On UserGLAccounts.php: Fix script name; add $ViewTopic and $BookMark; improve $SelectedUser validation; improve page_title_text; improve select user; regroup modify access permission code (improve logic); add classes to table elements; transalate database "0" and "1" to human "No" and "Yes"; simplify and tide code; modify prnMsg from multiple part sentence to one part sentence (better to trasnlate when language use a different gramar structrure fron English); add "Print This", "Select A Different User" and "Return" buttons. Add info to ManualGeneralLedger.html. Modified Paths: -------------- trunk/UserGLAccounts.php trunk/doc/Change.log trunk/doc/Manual/ManualGeneralLedger.html Modified: trunk/UserGLAccounts.php =================================================================== --- trunk/UserGLAccounts.php 2015-12-26 10:39:10 UTC (rev 7426) +++ trunk/UserGLAccounts.php 2015-12-27 19:59:10 UTC (rev 7427) @@ -1,262 +1,259 @@ <?php -/* $Id: glaccountusers.php 6806 2013-09-28 05:10:46Z daintree $*/ +/* $Id: UserGLAccounts.php 6806 2013-09-28 05:10:46Z daintree $*/ +/* Maintenance of GL Accounts allowed for a user. */ include('includes/session.inc'); -$Title = _('User Authorised GL Accounts Maintenance'); +$Title = _('User Authorised GL Accounts'); +$ViewTopic = 'GeneralLedger'; +$BookMark = 'UserGLAccounts'; include('includes/header.inc'); -echo '<p class="page_title_text"><img src="' . $RootPath . '/css/' . $Theme . '/images/money_add.png" title="' . _('User Authorised GL Accounts') . '" alt="" />' . ' ' . $Title . '</p>'; +if(isset($_POST['SelectedUser']) and $_POST['SelectedUser']<>'') {//If POST not empty: + $SelectedUser = mb_strtoupper($_POST['SelectedUser']); +} elseif(isset($_GET['SelectedUser']) and $_GET['SelectedUser']<>'') {//If GET not empty: + $SelectedUser = mb_strtoupper($_GET['SelectedUser']); +} else {// Unset empty SelectedUser: + unset($_GET['SelectedUser']); + unset($_POST['SelectedUser']); + unset($SelectedUser); +} -if (isset($_POST['SelectedGLAccount'])) { +if(isset($_POST['SelectedGLAccount'])) { $SelectedGLAccount = mb_strtoupper($_POST['SelectedGLAccount']); -} elseif (isset($_GET['SelectedGLAccount'])) { +} elseif(isset($_GET['SelectedGLAccount'])) { $SelectedGLAccount = mb_strtoupper($_GET['SelectedGLAccount']); } else { $SelectedGLAccount = ''; +/* unset($SelectedGLAccount);*/ } -if (isset($_POST['SelectedUser'])) { - $SelectedUser = mb_strtoupper($_POST['SelectedUser']); -} elseif (isset($_GET['SelectedUser'])) { - $SelectedUser = mb_strtoupper($_GET['SelectedUser']); -} - -if (isset($_POST['Cancel'])) { +if(isset($_GET['Cancel']) or isset($_POST['Cancel'])) { unset($SelectedUser); unset($SelectedGLAccount); } -if (isset($_POST['Process'])) { - if ($_POST['SelectedUser'] == '') { - prnMsg(_('You have not selected any User'), 'error'); - echo '<br />'; - unset($SelectedUser); - unset($_POST['SelectedUser']); - } -} +if(!isset($SelectedUser)) {// If is NOT set a user for GL accounts. + echo '<p class="page_title_text"><img alt="" src="', $RootPath, '/css/', $Theme, + '/images/gl.png" title="',// Icon image. + _('User Authorised GL Accounts'), '" /> ',// Icon title. + _('User Authorised GL Accounts'), '</p>';// Page title. -if (isset($_POST['submit'])) { + /* It could still be the second time the page has been run and a record has been selected for modification - SelectedGLAccount 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. These will call the same page again and allow update/input or deletion of the records.*/ - $InputError = 0; - - if ($_POST['SelectedGLAccount'] == '') { - $InputError = 1; - prnMsg(_('You have not selected an GL Account to be authorised for this user'), 'error'); - echo '<br />'; - unset($SelectedUser); + if(isset($_POST['Process'])) { + prnMsg(_('You have not selected any user'), 'error'); } - - if ($InputError != 1) { - - // First check the user is not being duplicated - - $CheckSql = "SELECT count(*) - FROM glaccountusers - WHERE accountcode= '" . $_POST['SelectedGLAccount'] . "' - AND userid = '" . $_POST['SelectedUser'] . "'"; - - $CheckResult = DB_query($CheckSql); - $CheckRow = DB_fetch_row($CheckResult); - - if ($CheckRow[0] > 0) { - $InputError = 1; - prnMsg(_('The GL Account') . ' ' . $_POST['SelectedGLAccount'] . ' ' . _('is already authorised for this user'), 'error'); - } else { - // Add new record on submit - $SQL = "INSERT INTO glaccountusers (accountcode, - userid, - canview, - canupd) - VALUES ('" . $_POST['SelectedGLAccount'] . "', - '" . $_POST['SelectedUser'] . "', - '1', - '1')"; - - $msg = _('User') . ': ' . $_POST['SelectedUser'] . ' ' . _('authority to use the') . ' ' . $_POST['SelectedGLAccount'] . ' ' . _('GL Account has been changed'); - $Result = DB_query($SQL); - prnMsg($msg, 'success'); - unset($_POST['SelectedGLAccount']); - } - } -} elseif (isset($_GET['delete'])) { - $SQL = "DELETE FROM glaccountusers - WHERE accountcode='" . $SelectedGLAccount . "' - AND userid='" . $SelectedUser . "'"; - - $ErrMsg = _('The GL Account user record could not be deleted because'); - $Result = DB_query($SQL, $ErrMsg); - prnMsg(_('User') . ' ' . $SelectedUser . ' ' . _('has had their authority to use the') . ' ' . $SelectedGLAccount . ' ' . _('GL Account removed'), 'success'); - unset($_GET['delete']); -} elseif (isset($_GET['ToggleUpdate'])) { - $SQL = "UPDATE glaccountusers - SET canupd='" . $_GET['ToggleUpdate'] . "' - WHERE accountcode='" . $SelectedGLAccount . "' - AND userid='" . $SelectedUser . "'"; - - $ErrMsg = _('The GL Account user record could not be deleted because'); - $Result = DB_query($SQL, $ErrMsg); - prnMsg(_('User') . ' ' . $SelectedUser . ' ' . _('has had their authority to update') . ' ' . $SelectedGLAccount . ' ' . _('GL Account removed'), 'success'); - unset($_GET['ToggleUpdate']); -} - -if (!isset($SelectedUser)) { - - /* It could still be the second time the page has been run and a record has been selected for modification - SelectedGLAccount 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. These will call the same page again and allow update/input or deletion of the records*/ - echo '<form method="post" action="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '">'; - echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" /> - <table class="selection"> + echo '<br />', + '<form action="', htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8'), '" method="post">', + '<input name="FormID" type="hidden" value="', $_SESSION['FormID'], '" />', + '<table class="selection"> <tr> - <td>' . _('Select User') . ':</td> - <td><select name="SelectedUser">'; - - $Result = DB_query("SELECT userid, - realname - FROM www_users - ORDER BY userid"); - - echo '<option value="">' . _('Not Yet Selected') . '</option>'; + <td>', _('Select User'), ':</td> + <td><select name="SelectedUser" onchange="this.form.submit()">',// Submit when the value of the select is changed. + '<option value="">', _('Not Yet Selected'), '</option>'; + $Result = DB_query(" + SELECT + userid, + realname + FROM www_users + ORDER BY userid"); while ($MyRow = DB_fetch_array($Result)) { - if (isset($SelectedUser) and $MyRow['userid'] == $SelectedUser) { - echo '<option selected="selected" value="'; - } else { - echo '<option value="'; + echo '<option '; + if(isset($SelectedUser) and $MyRow['userid'] == $SelectedUser) { + echo 'selected="selected" '; } - echo $MyRow['userid'] . '">' . $MyRow['userid'] . ' - ' . $MyRow['realname'] . '</option>'; + echo 'value="', $MyRow['userid'], '">', $MyRow['userid'], ' - ', $MyRow['realname'], '</option>'; + }// End while loop. + echo '</select></td> + </tr> + </table>';//Close Select_User table. - } //end while loop - - echo '</select></td></tr>'; - - echo '</table>'; // close main table DB_free_result($Result); - echo '<div class="centre"> - <input type="submit" name="Process" value="' . _('Accept') . '" /> - <input type="submit" name="Cancel" value="' . _('Cancel') . '" /> - </div>'; + echo '<div class="centre noprint">',// Form buttons: + '<button name="Process" type="submit" value="Accept"><img alt="" src="', $RootPath, '/css/', $Theme, + '/images/user.png" /> ', _('Accept'), '</button> '; // "Accept" button. - echo '</form>'; - -} - -//end of ifs and buts! -if (isset($_POST['process']) or isset($SelectedUser)) { - $SQLName = "SELECT realname - FROM www_users - WHERE userid='" . $SelectedUser . "'"; - $Result = DB_query($SQLName); +} else {// If is set a user for GL accounts ($SelectedUser). + $Result = DB_query(" + SELECT realname + FROM www_users + WHERE userid='" . $SelectedUser . "'"); $MyRow = DB_fetch_array($Result); $SelectedUserName = $MyRow['realname']; + echo '<p class="page_title_text"><img alt="" src="', $RootPath, '/css/', $Theme, + '/images/gl.png" title="',// Icon image. + _('User Authorised GL Accounts'), '" /> ',// Icon title. + _('Authorised GL Accounts for'), ' ', $SelectedUserName, '</p>';// Page title. - echo '<div class="centre"><a href="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '">' . _('Authorised GL Accounts for') . ' ' . $SelectedUserName . '</a></div> - <form method="post" action="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '"> - <input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" /> - <input type="hidden" name="SelectedUser" value="' . $SelectedUser . '" />'; +// BEGIN: Needs $SelectedUser, $SelectedGLAccount: + if (isset($_POST['submit'])) { + $InputError = 0; + if ($_POST['SelectedGLAccount'] == '') { + $InputError = 1; + prnMsg(_('You have not selected an GL Account to be authorised for this user'), 'error'); + unset($SelectedGLAccount); + } + if ($InputError != 1) { + // First check the user is not being duplicated + $CheckResult = DB_query(" + SELECT count(*) + FROM glaccountusers + WHERE accountcode= '" . $_POST['SelectedGLAccount'] . "' + AND userid = '" . $SelectedUser . "'"); + $CheckRow = DB_fetch_row($CheckResult); + if ($CheckRow[0] > 0) { + $InputError = 1; + prnMsg(_('The GL Account') . ' ' . $SelectedGLAccount . ' ' . _('is already authorised for this user'), 'error'); + } else { + // Add new record on submit + $SQL = "INSERT INTO glaccountusers (accountcode, + userid, + canview, + canupd) + VALUES ('" . $SelectedGLAccount . "', + '" . $SelectedUser . "', + '1', + '1')"; + $Result = DB_query($SQL); + prnMsg(_('An access permission to a GL account was added') . '. ' . _('User') . ': ' . $SelectedUser . '. ' . _('GL Account') . ': ' . $SelectedGLAccount . '.', 'success'); + unset($_POST['SelectedGLAccount']); + } + } + } elseif(isset($_GET['delete']) or isset($_POST['delete'])) { + $SQL = "DELETE FROM glaccountusers + WHERE accountcode='" . $SelectedGLAccount . "' + AND userid='" . $SelectedUser . "'"; + $ErrMsg = _('The GL Account user record could not be deleted because'); + $Result = DB_query($SQL, $ErrMsg); + prnMsg(_('An access permission to a GL account was removed') . '. ' . _('User') . ': ' . $SelectedUser . '. ' . _('GL Account') . ': ' . $SelectedGLAccount . '.', 'success'); + unset($_GET['delete']); + unset($_POST['delete']); + } elseif(isset($_GET['ToggleUpdate']) or isset($_POST['ToggleUpdate'])) {// Can update (write) GL accounts flag. + if(isset($_GET['ToggleUpdate']) and $_GET['ToggleUpdate']<>'') {//If GET not empty. + $ToggleUpdate = $_GET['ToggleUpdate']; + } elseif(isset($_POST['ToggleUpdate']) and $_POST['ToggleUpdate']<>'') {//If POST not empty. + $ToggleUpdate = $_POST['ToggleUpdate']; + } + $SQL = "UPDATE glaccountusers + SET canupd='" . $ToggleUpdate . "' + WHERE accountcode='" . $SelectedGLAccount . "' + AND userid='" . $SelectedUser . "'"; + $ErrMsg = _('The GL Account user record could not be updated because'); + $Result = DB_query($SQL, $ErrMsg); + prnMsg(_('The access permission to update a GL account was modified') . '. ' . _('User') . ': ' . $SelectedUser . '. ' . _('GL Account') . ': ' . $SelectedGLAccount . '.', 'success'); + unset($_GET['ToggleUpdate']); + unset($_POST['ToggleUpdate']); + } +// END: Needs $SelectedUser, $SelectedGLAccount. - $SQL = "SELECT glaccountusers.accountcode, - canview, - canupd, - chartmaster.accountname - FROM glaccountusers INNER JOIN chartmaster - ON glaccountusers.accountcode=chartmaster.accountcode - WHERE glaccountusers.userid='" . $SelectedUser . "' - ORDER BY chartmaster.accountcode ASC"; + echo '<table class="selection"> + <thead> + <tr> + <th class="text">', _('Code'), '</th> + <th class="text">', _('Name'), '</th> + <th class="centre">', _('View'), '</th> + <th class="centre">', _('Update'), '</th> + <th class="noprint" colspan="2"> </th> + </tr> + </thead><tbody>'; + $Result = DB_query(" + SELECT + glaccountusers.accountcode, + canview, + canupd, + chartmaster.accountname + FROM glaccountusers INNER JOIN chartmaster + ON glaccountusers.accountcode=chartmaster.accountcode + WHERE glaccountusers.userid='" . $SelectedUser . "' + ORDER BY chartmaster.accountcode ASC"); - $Result = DB_query($SQL); - - echo '<table class="selection">'; - echo '<tr> - <th colspan="6"><h3>' . _('Authorised GL Accounts for User') . ': ' . $SelectedUserName . '</h3></th> - </tr>'; - echo '<tr> - <th>' . _('Code') . '</th> - <th>' . _('Name') . '</th> - <th>' . _('View') . '</th> - <th>' . _('Update') . '</th> - </tr>'; - $k = 0; //row colour counter while ($MyRow = DB_fetch_array($Result)) { - if ($k == 1) { + if($k == 1) { echo '<tr class="EvenTableRows">'; $k = 0; } else { echo '<tr class="OddTableRows">'; $k = 1; } + echo '<td class="text">', $MyRow['accountcode'], '</td> + <td class="text">', $MyRow['accountname'], '</td> + <td class="centre">'; + if($MyRow['canview'] == 1) { + echo _('Yes'); + } else { + echo _('No'); + } + echo '</td> + <td class="centre">'; - if ($MyRow['canupd'] == 1) { - $ToggleText = '<td><a href="%s?SelectedGLAccount=%s&ToggleUpdate=0&SelectedUser=' . $SelectedUser . '" onclick="return confirm(\'' . _('Are you sure you wish to remove Update for this GL Account?') . '\');">' . _('Remove Update') . '</a></td>'; + $ScriptName = htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'); + if($MyRow['canupd'] == 1) { + echo _('Yes'), '</td> + <td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&ToggleUpdate=0" onclick="return confirm(\'', _('Are you sure you wish to remove Update for this GL Account?'), '\');">', _('Remove Update'); } else { - $ToggleText = '<td><a href="%s?SelectedGLAccount=%s&ToggleUpdate=1&SelectedUser=' . $SelectedUser . '" onclick="return confirm(\'' . _('Are you sure you wish to add Update for this GL Account?') . '\');">' . _('Add Update') . '</a></td>'; + echo _('No'), '</td> + <td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&ToggleUpdate=1" onclick="return confirm(\'', _('Are you sure you wish to add Update for this GL Account?'), '\');">', _('Add Update'); } - - printf('<td>%s</td> - <td>%s</td> - <td>%s</td> - <td>%s</td>' . - $ToggleText . ' - <td><a href="%s?SelectedGLAccount=%s&delete=yes&SelectedUser=' . $SelectedUser . '" onclick="return confirm(\'' . _('Are you sure you wish to un-authorise this GL Account?') . '\');">' . _('Un-authorise') . '</a></td> - </tr>', - $MyRow['accountcode'], - $MyRow['accountname'], - $MyRow['canview'], - $MyRow['canupd'], - htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'), - $MyRow['accountcode'], - htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8'), - $MyRow['accountcode']); - } - //END WHILE LIST LOOP - echo '</table>'; - - if (!isset($_GET['delete'])) { - - - echo '<table class="selection">'; //Main table - - echo '<tr> - <td>' . _('Select GL Account') . ':</td> + echo '</a></td> + <td class="noprint"><a href="', $ScriptName, '?SelectedUser=', $SelectedUser, '&SelectedGLAccount=', $MyRow['accountcode'], '&delete=yes" onclick="return confirm(\'', _('Are you sure you wish to un-authorise this GL Account?'), '\');">', _('Un-authorise'), '</a></td> + </tr>'; + }// End while list loop. + echo '</tbody></table>', + '<br />', + '<form action="', htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8'), '" method="post">', + '<input name="FormID" type="hidden" value="', $_SESSION['FormID'], '" />', + '<input name="SelectedUser" type="hidden" value="', $SelectedUser, '" />', + '<br /> + <table class="selection noprint"> + <tr> + <td>'; + $Result = DB_query(" + SELECT + accountcode, + accountname + FROM chartmaster + WHERE NOT EXISTS (SELECT glaccountusers.accountcode + FROM glaccountusers + WHERE glaccountusers.userid='" . $SelectedUser . "' + AND glaccountusers.accountcode=chartmaster.accountcode) + ORDER BY accountcode"); + if(DB_num_rows($Result)>0) {// If the user does not have access permissions to one or more GL accounts: + echo _('Add access permissions to a GL account'), ':</td> <td><select name="SelectedGLAccount">'; - - $Result = DB_query("SELECT accountcode, - accountname - FROM chartmaster - WHERE NOT EXISTS (SELECT glaccountusers.accountcode - FROM glaccountusers - WHERE glaccountusers.userid='" . $SelectedUser . "' - AND glaccountusers.accountcode=chartmaster.accountcode) - ORDER BY accountcode"); - - if (!isset($_POST['SelectedGLAccount'])) { - echo '<option selected="selected" value="">' . _('Not Yet Selected') . '</option>'; + if(!isset($_POST['SelectedGLAccount'])) { + echo '<option selected="selected" value="">', _('Not Yet Selected'), '</option>'; } while ($MyRow = DB_fetch_array($Result)) { - if (isset($_POST['SelectedGLAccount']) and $MyRow['accountcode'] == $_POST['SelectedGLAccount']) { + if(isset($_POST['SelectedGLAccount']) and $MyRow['accountcode'] == $_POST['SelectedGLAccount']) { echo '<option selected="selected" value="'; } else { echo '<option value="'; } - echo $MyRow['accountcode'] . '">' . $MyRow['accountcode'] .' - '. $MyRow['accountname'] . '</option>'; - - } //end while loop - - echo '</select> - </td> - </tr> - </table>'; // close main table - DB_free_result($Result); - - echo '<div class="centre"> - <input type="submit" name="submit" value="' . _('Accept') . '" /> - <input type="submit" name="Cancel" value="' . _('Cancel') . '" /> - </div> - </form>'; - - } // end if user wish to delete + echo $MyRow['accountcode'], '">', $MyRow['accountcode'], ' - ', $MyRow['accountname'], '</option>'; + } + echo '</select></td> + <td><input type="submit" name="submit" value="Accept" />'; + } else {// If the user has access permissions to all GL accounts: + echo _('User has access permissions to all GL accounts'); + } + echo '</td> + </tr> + </table>'; + DB_free_result($Result); + echo '<br>', // Form buttons: + '<div class="centre noprint">', + '<button onclick="javascript:window.print()" type="button"><img alt="" src="', $RootPath, '/css/', $Theme, + '/images/printer.png" /> ', _('Print This'), '</button>', // "Print This" button. + '<button formaction="UserGLAccounts.php?Cancel" type="submit"><img alt="" src="', $RootPath, '/css/', $Theme, + '/images/user.png" /> ', _('Select A Different User'), '</button>'; // "Select A Different User" button. } +echo '<button formaction="index.php?Application=GL" type="submit"><img alt="" src="', $RootPath, '/css/', $Theme, + '/images/previous.png" /> ', _('Return'), '</button>', // "Return" button. + '</div> + </form>'; include('includes/footer.inc'); ?> Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-26 10:39:10 UTC (rev 7426) +++ trunk/doc/Change.log 2015-12-27 19:59:10 UTC (rev 7427) @@ -1,5 +1,6 @@ webERP Change Log +27/12/15 RChacon: On UserGLAccounts.php: Fix script name; add $ViewTopic and $BookMark; improve $SelectedUser validation; improve page_title_text; improve select user; regroup modify access permission code (improve logic); add classes to table elements; transalate database "0" and "1" to human "No" and "Yes"; simplify and tide code; modify prnMsg from multiple part sentence to one part sentence (better to trasnlate when language use a different gramar structrure fron English); add "Print This", "Select A Different User" and "Return" buttons. Add info to ManualGeneralLedger.html. 26/12/2015 Exson: Add items not received information on outstanding po inquiry screen in PO_SelectOSPurchOrder.php. 24/12/15 Exson: Add supplier no as a option for supplier transaction inquiry in SupplierTransInquiry.php. 24/12/15 Exson: Add width of printed text to make day to appear in PDFOstdgGRNsPageHeader.inc. Modified: trunk/doc/Manual/ManualGeneralLedger.html =================================================================== --- trunk/doc/Manual/ManualGeneralLedger.html 2015-12-26 10:39:10 UTC (rev 7426) +++ trunk/doc/Manual/ManualGeneralLedger.html 2015-12-27 19:59:10 UTC (rev 7427) @@ -400,3 +400,28 @@ <p>The report will be run as a pdf file for printing, emailing, archiving etc.</P> </li> </ul> + + + +<div class="floatright"><a class="minitext" href="#top">⬆ Top</a></div> +<h2>Maintenance</h2> + +<!--h3><a id="GLAccountUsers">GL Accounts Authorised Users</a></h3> +<p>.</p--> + +<h3><a id="UserGLAccounts">User Authorised GL Accounts</a></h3> +<p>This software has methods to assign permissions or access rights to specific users and groups of users. The system controls the ability of the users to view or make changes to the contents of the GL accounts.</p> +<p>With this script, you can change a specific user access permissions to GL accounts:</p> +<ul> +<li>You can add or remove the read permission for each GL account that grants or denies the ability of a user to view it.</li> +<li>You can add or remove the write permission for each GL account that grants or denies the ability of a user to update it.</li> +</ul> + +<!--h3><a id="BankAccounts.php">Bank Accounts</a></h3> +<p>.</p--> + +<!--h3><a id="BankAccountUsers.php">Bank Account Authorized Users</a></h3> +<p>.</p--> + +<!--h3><a id="UserBankAccounts.php">User Authorized Bank Accounts</a></h3> +<p>.</p--> |
From: <ex...@us...> - 2015-12-26 10:39:13
|
Revision: 7426 http://sourceforge.net/p/web-erp/reponame/7426 Author: exsonqu Date: 2015-12-26 10:39:10 +0000 (Sat, 26 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-26 10:38:17 UTC (rev 7425) +++ trunk/doc/Change.log 2015-12-26 10:39:10 UTC (rev 7426) @@ -1,5 +1,6 @@ webERP Change Log +26/12/2015 Exson: Add items not received information on outstanding po inquiry screen in PO_SelectOSPurchOrder.php. 24/12/15 Exson: Add supplier no as a option for supplier transaction inquiry in SupplierTransInquiry.php. 24/12/15 Exson: Add width of printed text to make day to appear in PDFOstdgGRNsPageHeader.inc. 2015/12/24 Exson: Add Completed option for PO printed to allowed the order details can be completed in PO_Header.php. |
From: <ex...@us...> - 2015-12-26 10:38:19
|
Revision: 7425 http://sourceforge.net/p/web-erp/reponame/7425 Author: exsonqu Date: 2015-12-26 10:38:17 +0000 (Sat, 26 Dec 2015) Log Message: ----------- 26/12/2015 Exson: Add items not received information on outstanding po inquiry screen in PO_SelectOSPurchOrder.php. Modified Paths: -------------- trunk/PO_SelectOSPurchOrder.php Modified: trunk/PO_SelectOSPurchOrder.php =================================================================== --- trunk/PO_SelectOSPurchOrder.php 2015-12-24 10:13:34 UTC (rev 7424) +++ trunk/PO_SelectOSPurchOrder.php 2015-12-26 10:38:17 UTC (rev 7425) @@ -364,6 +364,7 @@ purchorders.allowprint, suppliers.currcode, currencies.decimalplaces AS currdecimalplaces, + group_concat(CASE WHEN quantityord>quantityrecd THEN CONCAT(itemcode,'--',round(quantityord-quantityrecd)) ELSE '' END) as bal, SUM(purchorderdetails.unitprice*purchorderdetails.quantityord) AS ordervalue FROM purchorders INNER JOIN purchorderdetails ON purchorders.orderno=purchorderdetails.orderno @@ -414,6 +415,7 @@ purchorders.allowprint, suppliers.currcode, currencies.decimalplaces AS currdecimalplaces, + group_concat(CASE WHEN quantityord>quantityrecd THEN CONCAT(itemcode,'--',round(quantityord-quantityrecd)) ELSE '' END) as bal, SUM(purchorderdetails.unitprice*purchorderdetails.quantityord) AS ordervalue FROM purchorders INNER JOIN purchorderdetails ON purchorders.orderno = purchorderdetails.orderno @@ -451,6 +453,7 @@ purchorders.allowprint, suppliers.currcode, currencies.decimalplaces AS currdecimalplaces, + group_concat(CASE WHEN quantityord>quantityrecd THEN CONCAT(itemcode,'--',round(quantityord-quantityrecd)) ELSE '' END) as bal, SUM(purchorderdetails.unitprice*purchorderdetails.quantityord) AS ordervalue FROM purchorders INNER JOIN purchorderdetails ON purchorders.orderno = purchorderdetails.orderno @@ -505,6 +508,7 @@ purchorders.allowprint, suppliers.currcode, currencies.decimalplaces AS currdecimalplaces, + group_concat(CASE WHEN quantityord>quantityrecd THEN CONCAT(itemcode,'--',round(quantityord-quantityrecd)) ELSE '' END) as bal, SUM(purchorderdetails.unitprice*purchorderdetails.quantityord) AS ordervalue FROM purchorders INNER JOIN purchorderdetails ON purchorders.orderno = purchorderdetails.orderno @@ -541,6 +545,7 @@ purchorders.allowprint, suppliers.currcode, currencies.decimalplaces AS currdecimalplaces, + group_concat(CASE WHEN quantityord>quantityrecd THEN CONCAT(itemcode,'--',round(quantityord-quantityrecd)) ELSE '' END) as bal, SUM(purchorderdetails.unitprice*purchorderdetails.quantityord) AS ordervalue FROM purchorders INNER JOIN purchorderdetails ON purchorders.orderno = purchorderdetails.orderno @@ -582,6 +587,7 @@ <th class="ascending">' . _('Delivery Date') . '</th> <th class="ascending">' . _('Initiated by') . '</th> <th class="ascending">' . _('Supplier') . '</th> + <th class="ascending">' . _('Balance') .' ('. _('Stock ID') . '--' . _('Quantity') . ' )</th> <th class="ascending">' . _('Currency') . '</th>'; if (in_array($PricesSecurity, $_SESSION['AllowedPageSecurityTokens']) OR !isset($PricesSecurity)) { @@ -635,6 +641,7 @@ <td>' . $FormatedDeliveryDate . '</td> <td>' . $InitiatorName . '</td> <td>' . $myrow['suppname'] . '</td> + <td width="250" style="word-break:break-all">' . $myrow['bal'] . '</td> <td>' . $myrow['currcode'] . '</td>'; if (in_array($PricesSecurity, $_SESSION['AllowedPageSecurityTokens']) OR !isset($PricesSecurity)) { echo '<td class="number">' . $FormatedOrderValue . '</td>'; |
From: <ex...@us...> - 2015-12-24 10:13:37
|
Revision: 7424 http://sourceforge.net/p/web-erp/reponame/7424 Author: exsonqu Date: 2015-12-24 10:13:34 +0000 (Thu, 24 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-24 10:12:57 UTC (rev 7423) +++ trunk/doc/Change.log 2015-12-24 10:13:34 UTC (rev 7424) @@ -1,5 +1,6 @@ webERP Change Log +24/12/15 Exson: Add supplier no as a option for supplier transaction inquiry in SupplierTransInquiry.php. 24/12/15 Exson: Add width of printed text to make day to appear in PDFOstdgGRNsPageHeader.inc. 2015/12/24 Exson: Add Completed option for PO printed to allowed the order details can be completed in PO_Header.php. 20/12/15 Phil: GoodsReceived.php now shows the supplier's item code as well |
From: <ex...@us...> - 2015-12-24 10:13:00
|
Revision: 7423 http://sourceforge.net/p/web-erp/reponame/7423 Author: exsonqu Date: 2015-12-24 10:12:57 +0000 (Thu, 24 Dec 2015) Log Message: ----------- 24/12/15 Exson: Add supplier no as a option for supplier transaction inquiry in SupplierTransInquiry.php. Modified Paths: -------------- trunk/SupplierTransInquiry.php Modified: trunk/SupplierTransInquiry.php =================================================================== --- trunk/SupplierTransInquiry.php 2015-12-24 08:23:53 UTC (rev 7422) +++ trunk/SupplierTransInquiry.php 2015-12-24 10:12:57 UTC (rev 7423) @@ -48,10 +48,16 @@ if (!isset($_POST['ToDate'])){ $_POST['ToDate'] = Date($_SESSION['DefaultDateFormat']); } +if (!isset($_POST['SupplierNo'])) { + $_POST['SupplierNo'] = ''; +} echo '<td>' . _('From') . ':</td> <td><input type="text" class="date" alt="' . $_SESSION['DefaultDateFormat'] . '" name="FromDate" maxlength="10" size="11" value="' . $_POST['FromDate'] . '" /></td> <td>' . _('To') . ':</td> <td><input type="text" class="date" alt="' . $_SESSION['DefaultDateFormat'] . '" name="ToDate" maxlength="10" size="11" value="' . $_POST['ToDate'] . '" /></td> + <td>' . _('Supplier No') . ':</td> + <td><input type="text" name="SupplierNo" size="11" maxlength="10" value="' . $_POST['SupplierNo'] . '" /> + </td> </tr> </table> <br /> @@ -208,4 +214,4 @@ echo '</table>'; } include('includes/footer.inc'); -?> \ No newline at end of file +?> |
From: <ex...@us...> - 2015-12-24 08:23:55
|
Revision: 7422 http://sourceforge.net/p/web-erp/reponame/7422 Author: exsonqu Date: 2015-12-24 08:23:53 +0000 (Thu, 24 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-24 08:23:20 UTC (rev 7421) +++ trunk/doc/Change.log 2015-12-24 08:23:53 UTC (rev 7422) @@ -1,5 +1,6 @@ webERP Change Log +24/12/15 Exson: Add width of printed text to make day to appear in PDFOstdgGRNsPageHeader.inc. 2015/12/24 Exson: Add Completed option for PO printed to allowed the order details can be completed in PO_Header.php. 20/12/15 Phil: GoodsReceived.php now shows the supplier's item code as well 20/12/15 Phil: SelectProduct.php now allows items to be searched based on the supplier's item code |
From: <ex...@us...> - 2015-12-24 08:23:22
|
Revision: 7421 http://sourceforge.net/p/web-erp/reponame/7421 Author: exsonqu Date: 2015-12-24 08:23:20 +0000 (Thu, 24 Dec 2015) Log Message: ----------- 24/12/15 Exson: Add width of printed text to make day to appear in PDFOstdgGRNsPageHeader.inc. Modified Paths: -------------- trunk/includes/PDFOstdgGRNsPageHeader.inc Modified: trunk/includes/PDFOstdgGRNsPageHeader.inc =================================================================== --- trunk/includes/PDFOstdgGRNsPageHeader.inc 2015-12-24 07:03:16 UTC (rev 7420) +++ trunk/includes/PDFOstdgGRNsPageHeader.inc 2015-12-24 08:23:20 UTC (rev 7421) @@ -13,7 +13,7 @@ $YPos -=$line_height; $LeftOvers = $pdf->addTextWrap($Left_Margin,$YPos,300,$FontSize,_('Outstanding GRNs Valuation for Suppliers between') . ' ' . $_POST['FromCriteria'] . ' ' . _('and') . ' ' . $_POST['ToCriteria']); -$LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-120,$YPos,120,$FontSize,_('Printed') . ': ' . Date($_SESSION['DefaultDateFormat']) . ' ' . _('Page') . ' ' . $PageNumber); +$LeftOvers = $pdf->addTextWrap($Page_Width-$Right_Margin-120,$YPos,220,$FontSize,_('Printed') . ': ' . Date($_SESSION['DefaultDateFormat']) . ' ' . _('Page') . ' ' . $PageNumber); $YPos -=(2*$line_height); @@ -46,4 +46,4 @@ $PageNumber++; $FontSize=8; -?> \ No newline at end of file +?> |
From: <ex...@us...> - 2015-12-24 07:03:18
|
Revision: 7420 http://sourceforge.net/p/web-erp/reponame/7420 Author: exsonqu Date: 2015-12-24 07:03:16 +0000 (Thu, 24 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-24 07:01:43 UTC (rev 7419) +++ trunk/doc/Change.log 2015-12-24 07:03:16 UTC (rev 7420) @@ -1,5 +1,6 @@ webERP Change Log +2015/12/24 Exson: Add Completed option for PO printed to allowed the order details can be completed in PO_Header.php. 20/12/15 Phil: GoodsReceived.php now shows the supplier's item code as well 20/12/15 Phil: SelectProduct.php now allows items to be searched based on the supplier's item code 14/12/15 Exson: Remove retrieving allocated data in Z_AutoCustomerAllocations.php. |
From: <ex...@us...> - 2015-12-24 07:01:46
|
Revision: 7419 http://sourceforge.net/p/web-erp/reponame/7419 Author: exsonqu Date: 2015-12-24 07:01:43 +0000 (Thu, 24 Dec 2015) Log Message: ----------- 2015/12/24 Exson: Add Completed option for PO printed to allowed the order details can be completed in PO_Header.php. Modified Paths: -------------- trunk/PO_Header.php Modified: trunk/PO_Header.php =================================================================== --- trunk/PO_Header.php 2015-12-20 00:49:16 UTC (rev 7418) +++ trunk/PO_Header.php 2015-12-24 07:01:43 UTC (rev 7419) @@ -846,7 +846,8 @@ case 'Printed': echo '<option value="Pending">' . _('Pending') . '</option> <option selected="selected" value="Printed">' . _('Printed') . '</option> - <option value="Cancelled">' . _('Cancelled') . '</option>'; + <option value="Cancelled">' . _('Cancelled') . '</option> + <option value="Completed">' . _('Completed') . '</option>'; break; case 'Completed': echo '<option selected="selected" value="Completed">' . _('Completed') . '</option>'; |
From: <dai...@us...> - 2015-12-20 00:49:19
|
Revision: 7418 http://sourceforge.net/p/web-erp/reponame/7418 Author: daintree Date: 2015-12-20 00:49:16 +0000 (Sun, 20 Dec 2015) Log Message: ----------- Show supplier item code when receiving goods Modified Paths: -------------- trunk/GoodsReceived.php trunk/doc/Change.log Modified: trunk/GoodsReceived.php =================================================================== --- trunk/GoodsReceived.php 2015-12-19 21:40:28 UTC (rev 7417) +++ trunk/GoodsReceived.php 2015-12-20 00:49:16 UTC (rev 7418) @@ -118,6 +118,7 @@ </tr> <tr> <th>' . _('Item Code') . '</th> + <th>' . _('Supplier') . '<br />'. _('Item') . '</th> <th>' . _('Description') . '</th> <th>' . _('Quantity') . '<br />' . _('Ordered') . '</th> <th>' . _('Units') . '</th> @@ -183,6 +184,7 @@ //Now Display LineItem echo '<td><a href="' . $RootPath . '/' . $_SESSION['part_pics_dir'] . '/' . $LnItm->StockID . '.jpg" target="_blank">' . $LnItm->StockID . '</a></td> + <td>' . $LnItm->Suppliers_PartNo . '</td> <td>' . $LnItm->ItemDescription . '</td> <td class="number">' . $DisplaySupplierQtyOrd . '</td> <td>' . $LnItm->SuppliersUnit . '</td> Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-19 21:40:28 UTC (rev 7417) +++ trunk/doc/Change.log 2015-12-20 00:49:16 UTC (rev 7418) @@ -1,5 +1,6 @@ webERP Change Log +20/12/15 Phil: GoodsReceived.php now shows the supplier's item code as well 20/12/15 Phil: SelectProduct.php now allows items to be searched based on the supplier's item code 14/12/15 Exson: Remove retrieving allocated data in Z_AutoCustomerAllocations.php. 11/12/15 Exson: Fixed the default Transaction Disable bug to enable for CustomerBranches.php. |
From: <dai...@us...> - 2015-12-19 21:40:31
|
Revision: 7417 http://sourceforge.net/p/web-erp/reponame/7417 Author: daintree Date: 2015-12-19 21:40:28 +0000 (Sat, 19 Dec 2015) Log Message: ----------- Seach product by supplier item code Modified Paths: -------------- trunk/SelectProduct.php trunk/doc/Change.log trunk/locale/en_US.utf8/LC_MESSAGES/messages.po Modified: trunk/SelectProduct.php =================================================================== --- trunk/SelectProduct.php 2015-12-14 09:59:18 UTC (rev 7416) +++ trunk/SelectProduct.php 2015-12-19 21:40:28 UTC (rev 7417) @@ -167,26 +167,24 @@ echo '<tr> <th class="number">' . _('Price') . ':</th>'; if (DB_num_rows($PriceResult) == 0) { - echo '<td class="select" colspan="6">' . _('No Default Price Set in Home Currency') . '</td> - </tr>'; + echo '<td class="select" colspan="2">' . _('No Default Price Set') . '</td>'; $Price = 0; } else { $PriceRow = DB_fetch_row($PriceResult); $Price = $PriceRow[1]; - echo '<td class="select">' . $PriceRow[0] . '</td> - <td class="select">' . locale_number_format($Price, $_SESSION['CompanyRecord']['decimalplaces']) . '</td> - <th class="number">' . _('Cost') . ':</th> - <td class="select">' . locale_number_format($Cost, $_SESSION['StandardCostDecimalPlaces']) . '</td> - <th class="number">' . _('Gross Profit') . ':</th> - <td class="select">'; - if ($Price > 0) { - echo locale_number_format(($Price - $Cost) * 100 / $Price, 1) . '%'; - } else { - echo _('N/A'); - } - echo '</td> - </tr>'; + echo '<td class="select" colspan="2" style="text-align:right">' . locale_number_format($Price, $_SESSION['CompanyRecord']['decimalplaces']) . '</td>'; } + echo '<th class="number">' . _('Cost') . ':</th> + <td class="select" style="text-align:right">' . locale_number_format($Cost, $_SESSION['StandardCostDecimalPlaces']) . '</td> + <th class="number">' . _('Gross Profit') . ':</th> + <td class="select" style="text-align:right">'; + if ($Price > 0) { + echo locale_number_format(($Price - $Cost) * 100 / $Price, 1) . '%'; + } else { + echo _('N/A'); + } + echo '</td> + </tr>'; } //end of if PricesSecuirty allows viewing of prices echo '</table>'; //end of first nested table // Item Category Property mod: display the item properties @@ -302,15 +300,15 @@ } echo '<tr> <th class="number" style="width:15%">' . _('Quantity On Hand') . ':</th> - <td style="width:17%" class="select">' . $QOH . '</td> - </tr>'; -echo '<tr> + <td style="width:17%; text-align:right" class="select">' . $QOH . '</td> + </tr> + <tr> <th class="number" style="width:15%">' . _('Quantity Demand') . ':</th> - <td style="width:17%" class="select">' . locale_number_format($Demand, $myrow['decimalplaces']) . '</td> - </tr>'; -echo '<tr> + <td style="width:17%; text-align:right" class="select">' . locale_number_format($Demand, $myrow['decimalplaces']) . '</td> + </tr> + <tr> <th class="number" style="width:15%">' . _('Quantity On Order') . ':</th> - <td style="width:17%" class="select">' . $QOO . '</td> + <td style="width:17%; text-align:right" class="select">' . $QOO . '</td> </tr> </table>'; //end of nested table echo '</td>'; //end cell of master table @@ -319,10 +317,10 @@ AND (in_array($SuppliersSecurity, $_SESSION['AllowedPageSecurityTokens']))){ echo '<td style="width:50%" valign="top"><table> - <tr><th style="width:50%">' . _('Supplier') . '</th> + <tr><th style="width:20%">' . _('Supplier') . '</th> + <th stlye="width:15%">' . _('Code') . '</th> <th style="width:15%">' . _('Cost') . '</th> <th style="width:5%">' . _('Curr') . '</th> - <th style="width:15%">' . _('Eff Date') . '</th> <th style="width:10%">' . _('Lead Time') . '</th> <th style="width:10%">' . _('Min Order Qty') . '</th> <th style="width:5%">' . _('Prefer') . '</th></tr>'; @@ -330,25 +328,38 @@ suppliers.currcode, suppliers.supplierid, purchdata.price, - purchdata.effectivefrom, + purchdata.suppliers_partno, purchdata.leadtime, purchdata.conversionfactor, purchdata.minorderqty, purchdata.preferred, - currencies.decimalplaces + currencies.decimalplaces, + MAX(purchdata.effectivefrom) FROM purchdata INNER JOIN suppliers ON purchdata.supplierno=suppliers.supplierid INNER JOIN currencies ON suppliers.currcode=currencies.currabrev WHERE purchdata.stockid = '" . $StockID . "' - ORDER BY purchdata.preferred DESC, purchdata.effectivefrom DESC"); + GROUP BY suppliers.suppname, + suppliers.currcode, + suppliers.supplierid, + purchdata.price, + purchdata.suppliers_partno, + purchdata.leadtime, + purchdata.conversionfactor, + purchdata.minorderqty, + purchdata.preferred, + currencies.decimalplaces + ORDER BY purchdata.preferred DESC"); + while ($SuppRow = DB_fetch_array($SuppResult)) { - echo '<tr><td class="select">' . $SuppRow['suppname'] . '</td> - <td class="select">' . locale_number_format($SuppRow['price'] / $SuppRow['conversionfactor'], $SuppRow['decimalplaces']) . '</td> - <td class="select">' . $SuppRow['currcode'] . '</td> - <td class="select">' . ConvertSQLDate($SuppRow['effectivefrom']) . '</td> - <td class="select">' . $SuppRow['leadtime'] . '</td> - <td class="select">' . $SuppRow['minorderqty'] . '</td>'; + echo '<tr> + <td class="select">' . $SuppRow['suppname'] . '</td> + <td class="select">' . $SuppRow['suppliers_partno'] . '</td> + <td class="select" style="text-align:right">' . locale_number_format($SuppRow['price'] / $SuppRow['conversionfactor'], $SuppRow['decimalplaces']) . '</td> + <td class="select">' . $SuppRow['currcode'] . '</td> + <td class="select" style="text-align:right">' . $SuppRow['leadtime'] . '</td> + <td class="select" style="text-align:right">' . $SuppRow['minorderqty'] . '</td>'; if ($SuppRow['preferred']==1) { //then this is the preferred supplier echo '<td class="select">' . _('Yes') . '</td>'; @@ -362,13 +373,18 @@ echo '</table>'; DB_data_seek($result, 0); } -echo '</td></tr></table><br />'; // end first item details table -echo '<table width="90%"><tr> - <th style="width:33%">' . _('Item Inquiries') . '</th> - <th style="width:33%">' . _('Item Transactions') . '</th> - <th style="width:33%">' . _('Item Maintenance') . '</th> - </tr>'; -echo '<tr><td valign="top" class="select">'; +echo '</td> + </tr> + </table> + <br />'; // end first item details table +echo '<table width="90%"> + <tr> + <th style="width:33%">' . _('Item Inquiries') . '</th> + <th style="width:33%">' . _('Item Transactions') . '</th> + <th style="width:33%">' . _('Item Maintenance') . '</th> + </tr> + <tr> + <td valign="top" class="select">'; /*Stock Inquiry Options */ echo '<a href="' . $RootPath . '/StockMovements.php?StockID=' . $StockID . '">' . _('Show Stock Movements') . '</a><br />'; if ($Its_A_Kitset_Assembly_Or_Dummy == False) { @@ -525,14 +541,26 @@ } else { echo '<input type="text" autofocus="autofocus" name="Keywords" title="' . _('Enter text that you wish to search for in the item description') . '" size="20" maxlength="25" />'; } -echo '</td></tr><tr><td></td>'; -echo '<td><b>' . _('OR') . ' ' . '</b>' . _('Enter partial') . ' <b>' . _('Stock Code') . '</b>:</td>'; -echo '<td>'; +echo '</td> + </tr> + <tr> + <td></td> + <td><b>' . _('OR') . ' ' . '</b>' . _('Enter partial') . ' <b>' . _('Stock Code') . '</b>:</td> + <td>'; if (isset($_POST['StockCode'])) { echo '<input type="text" name="StockCode" value="' . $_POST['StockCode'] . '" title="' . _('Enter text that you wish to search for in the item code') . '" size="15" maxlength="18" />'; } else { echo '<input type="text" name="StockCode" title="' . _('Enter text that you wish to search for in the item code') . '" size="15" maxlength="18" />'; } +echo '<tr> + <td></td> + <td><b>' . _('OR') . ' ' . '</b>' . _('Enter partial') . ' <b>' . _('Supplier Code') . '</b>:</td> + <td>'; +if (isset($_POST['SupplierStockCode'])) { + echo '<input type="text" name="SupplierStockCode" value="' . $_POST['SupplierStockCode'] . '" title="' . _('Enter text that you wish to search for in the supplier\'s item code') . '" size="15" maxlength="18" />'; +} else { + echo '<input type="text" name="SupplierStockCode" title="' . _('Enter text that you wish to search for in the supplier\'s item code') . '" size="15" maxlength="18" />'; +} echo '</td></tr></table><br />'; echo '<div class="centre"><input type="submit" name="Search" value="' . _('Search Now') . '" /></div><br />'; echo '</div> @@ -549,7 +577,7 @@ if ($_POST['Keywords'] AND $_POST['StockCode']) { prnMsg (_('Stock description keywords have been used in preference to the Stock code extract entered'), 'info'); } - if ($_POST['Keywords']) { + if (isset($_POST['Keywords']) AND mb_strlen($_POST['Keywords'])>0) { //insert wildcard characters in spaces $_POST['Keywords'] = mb_strtoupper($_POST['Keywords']); $SearchString = '%' . str_replace(' ', '%', $_POST['Keywords']) . '%'; @@ -597,7 +625,7 @@ stockmaster.decimalplaces ORDER BY stockmaster.discontinued, stockmaster.stockid"; } - } elseif (isset($_POST['StockCode'])) { + } elseif (isset($_POST['StockCode']) AND mb_strlen($_POST['StockCode'])>0) { $_POST['StockCode'] = mb_strtoupper($_POST['StockCode']); if ($_POST['StockCat'] == 'All') { $SQL = "SELECT stockmaster.stockid, @@ -643,7 +671,7 @@ stockmaster.decimalplaces ORDER BY stockmaster.discontinued, stockmaster.stockid"; } - } elseif (!isset($_POST['StockCode']) AND !isset($_POST['Keywords'])) { + } elseif (isset($_POST['SupplierStockCode']) AND mb_strlen($_POST['SupplierStockCode'])>0) { if ($_POST['StockCat'] == 'All') { $SQL = "SELECT stockmaster.stockid, stockmaster.description, @@ -654,7 +682,57 @@ stockmaster.units, stockmaster.decimalplaces FROM stockmaster + INNER JOIN purchdata + ON stockmaster.stockid=purchdata.stockid + INNER JOIN locstock + ON stockmaster.stockid=locstock.stockid LEFT JOIN stockcategory + ON stockmaster.categoryid=stockcategory.categoryid + WHERE purchdata.suppliers_partno " . LIKE . " '%" . $_POST['SupplierStockCode'] . "%' + GROUP BY stockmaster.stockid, + stockmaster.description, + stockmaster.longdescription, + stockmaster.units, + stockmaster.mbflag, + stockmaster.discontinued, + stockmaster.decimalplaces + ORDER BY stockmaster.discontinued, stockmaster.stockid"; + } else { + $SQL = "SELECT stockmaster.stockid, + stockmaster.description, + stockmaster.longdescription, + stockmaster.mbflag, + stockmaster.discontinued, + SUM(locstock.quantity) AS qoh, + stockmaster.units, + stockmaster.decimalplaces + FROM stockmaster INNER JOIN locstock + ON stockmaster.stockid=locstock.stockid + INNER JOIN purchdata + ON stockmaster.stockid=purchdata.stockid + WHERE categoryid='" . $_POST['StockCat'] . "' + AND purchdata.suppliers_partno " . LIKE . " '%" . $_POST['SupplierStockCode'] . "%' + GROUP BY stockmaster.stockid, + stockmaster.description, + stockmaster.longdescription, + stockmaster.units, + stockmaster.mbflag, + stockmaster.discontinued, + stockmaster.decimalplaces + ORDER BY stockmaster.discontinued, stockmaster.stockid"; + } + } else { + if ($_POST['StockCat'] == 'All') { + $SQL = "SELECT stockmaster.stockid, + stockmaster.description, + stockmaster.longdescription, + stockmaster.mbflag, + stockmaster.discontinued, + SUM(locstock.quantity) AS qoh, + stockmaster.units, + stockmaster.decimalplaces + FROM stockmaster + LEFT JOIN stockcategory ON stockmaster.categoryid=stockcategory.categoryid, locstock WHERE stockmaster.stockid=locstock.stockid Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-14 09:59:18 UTC (rev 7416) +++ trunk/doc/Change.log 2015-12-19 21:40:28 UTC (rev 7417) @@ -1,6 +1,7 @@ webERP Change Log -14/12/15 Exson: Remove retrieving allocated data in Z_AutoCustomerAllocations.php. +20/12/15 Phil: SelectProduct.php now allows items to be searched based on the supplier's item code +14/12/15 Exson: Remove retrieving allocated data in Z_AutoCustomerAllocations.php. 11/12/15 Exson: Fixed the default Transaction Disable bug to enable for CustomerBranches.php. 10/12/15 Exson: Add invoice no while reprint GRN in ReprintGRN.php. 10/12/15 Exson: Add multiple work orders total cost inquiry script. Modified: trunk/locale/en_US.utf8/LC_MESSAGES/messages.po =================================================================== --- trunk/locale/en_US.utf8/LC_MESSAGES/messages.po 2015-12-14 09:59:18 UTC (rev 7416) +++ trunk/locale/en_US.utf8/LC_MESSAGES/messages.po 2015-12-19 21:40:28 UTC (rev 7417) @@ -5537,7 +5537,7 @@ #: includes/PDFSuppTransListingPageHeader.inc:48 #: includes/PDFSupplierBalsPageHeader.inc:33 msgid "Supplier" -msgstr "" +msgstr "Vendor" #: ContractCosting.php:180 SuppContractChgs.php:81 msgid "Anticipated" @@ -11620,7 +11620,7 @@ #: EDIProcessOrders.php:437 msgid "This implies that the EDI message is for some other supplier" -msgstr "" +msgstr "This implies that the EDI message is for some other vendor" #: EDIProcessOrders.php:437 msgid "No further processing will be done" @@ -15560,7 +15560,7 @@ #: InventoryPlanningPrefSupplier.php:126 InventoryPlanningPrefSupplier.php:128 msgid "Inventory Planning Based On Lead Time Of Preferred Supplier" -msgstr "" +msgstr "Inventory Planning Based On Lead Time Of Preferred Vendor" #: InventoryPlanningPrefSupplier.php:350 msgid "Nil" @@ -19832,7 +19832,7 @@ #: PO_Header.php:534 msgid "Purchase Order: Select Supplier" -msgstr "" +msgstr "Purchase Order: Select Vendor" #: PO_Header.php:545 msgid "Enter text in the supplier name" |
From: <ex...@us...> - 2015-12-14 09:59:21
|
Revision: 7416 http://sourceforge.net/p/web-erp/reponame/7416 Author: exsonqu Date: 2015-12-14 09:59:18 +0000 (Mon, 14 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-14 09:58:40 UTC (rev 7415) +++ trunk/doc/Change.log 2015-12-14 09:59:18 UTC (rev 7416) @@ -1,4 +1,6 @@ webERP Change Log + +14/12/15 Exson: Remove retrieving allocated data in Z_AutoCustomerAllocations.php. 11/12/15 Exson: Fixed the default Transaction Disable bug to enable for CustomerBranches.php. 10/12/15 Exson: Add invoice no while reprint GRN in ReprintGRN.php. 10/12/15 Exson: Add multiple work orders total cost inquiry script. |
From: <ex...@us...> - 2015-12-14 09:58:42
|
Revision: 7415 http://sourceforge.net/p/web-erp/reponame/7415 Author: exsonqu Date: 2015-12-14 09:58:40 +0000 (Mon, 14 Dec 2015) Log Message: ----------- 14/12/15 Exson: Remove retrieving allocated data in Z_AutoCustomerAllocations.php. Modified Paths: -------------- trunk/Z_AutoCustomerAllocations.php Modified: trunk/Z_AutoCustomerAllocations.php =================================================================== --- trunk/Z_AutoCustomerAllocations.php 2015-12-11 04:04:40 UTC (rev 7414) +++ trunk/Z_AutoCustomerAllocations.php 2015-12-14 09:58:40 UTC (rev 7415) @@ -107,46 +107,7 @@ $BalToAllocate += $ThisAllocation;//since $BalToAllocate is negative } DB_free_result($TransResult); - // Get trans previously allocated to by this trans - this will overwrite incomplete allocations above - $SQL= "SELECT debtortrans.id, - typename, - transno, - trandate, - rate, - ovamount+ovgst+ovfreight+ovdiscount AS total, - diffonexch, - debtortrans.alloc-custallocns.amt AS prevallocs, - amt, - custallocns.id AS allocid - FROM debtortrans INNER JOIN systypes - ON debtortrans.type = systypes.typeid - INNER JOIN custallocns - ON debtortrans.id=custallocns.transid_allocto - WHERE custallocns.transid_allocfrom='" . $_SESSION['Alloc']->AllocTrans . "' - AND debtorno='" . $_SESSION['Alloc']->DebtorNo . "'"; - - if ($_SESSION['SalesmanLogin'] != '') { - $SQL .= " AND debtortrans.salesperson='" . $_SESSION['SalesmanLogin'] . "'"; - } - - $SQL .= " ORDER BY debtortrans.trandate"; - - $Result=DB_query($SQL,$db); - - 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'], - $myrow['total'], - $myrow['rate'], - $DiffOnExchThisOne, - ($myrow['diffonexch'] - $DiffOnExchThisOne), - $myrow['prevallocs'], - $myrow['allocid']); - } + ProcessAllocation(); } echo '</table>'; @@ -163,6 +124,7 @@ $Error = ''; $Result= DB_Txn_Begin(); $AllAllocations = 0; + $TotalDiffOnExch = 0; foreach ($_SESSION['Alloc']->Allocs as $AllocnItem) { if ($AllocnItem->AllocAmt > 0) { @@ -185,6 +147,7 @@ $NewAllocTotal = $AllocnItem->PrevAlloc + $AllocnItem->AllocAmt; $AllAllocations = $AllAllocations + $AllocnItem->AllocAmt; $Settled = (abs($NewAllocTotal-$AllocnItem->TransAmount) < 0.005) ? 1 : 0; + $TotalDiffOnExch += $AllocnItem->DiffOnExch; $SQL = "UPDATE debtortrans SET diffonexch='" . $AllocnItem->DiffOnExch . "', |
From: <ex...@us...> - 2015-12-11 04:04:43
|
Revision: 7414 http://sourceforge.net/p/web-erp/reponame/7414 Author: exsonqu Date: 2015-12-11 04:04:40 +0000 (Fri, 11 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-11 04:04:13 UTC (rev 7413) +++ trunk/doc/Change.log 2015-12-11 04:04:40 UTC (rev 7414) @@ -1,4 +1,5 @@ webERP Change Log +11/12/15 Exson: Fixed the default Transaction Disable bug to enable for CustomerBranches.php. 10/12/15 Exson: Add invoice no while reprint GRN in ReprintGRN.php. 10/12/15 Exson: Add multiple work orders total cost inquiry script. 09/12/05 Exson: Fixed the telephone regular expression bug in SelectCustomer.php. Reported by Terry. |
From: <ex...@us...> - 2015-12-11 04:04:15
|
Revision: 7413 http://sourceforge.net/p/web-erp/reponame/7413 Author: exsonqu Date: 2015-12-11 04:04:13 +0000 (Fri, 11 Dec 2015) Log Message: ----------- 11/12/15 Exson: Fixed the default Transaction Disable bug to enable for CustomerBranches.php. Modified Paths: -------------- trunk/CustomerBranches.php Modified: trunk/CustomerBranches.php =================================================================== --- trunk/CustomerBranches.php 2015-12-10 10:03:48 UTC (rev 7412) +++ trunk/CustomerBranches.php 2015-12-11 04:04:13 UTC (rev 7413) @@ -7,16 +7,15 @@ $ViewTopic = 'AccountsReceivable';// Filename's id in ManualContents.php's TOC. $BookMark = 'NewCustomerBranch';// Anchor's id in the manual's html document. include('includes/header.inc'); - include('includes/CountriesArray.php'); -if(isset($_GET['DebtorNo'])) { +if (isset($_GET['DebtorNo'])) { $DebtorNo = mb_strtoupper($_GET['DebtorNo']); -} elseif(isset($_POST['DebtorNo'])) { +} else if (isset($_POST['DebtorNo'])){ $DebtorNo = mb_strtoupper($_POST['DebtorNo']); } -if(!isset($DebtorNo)) { +if (!isset($DebtorNo)) { prnMsg(_('This page must be called with the debtor code of the customer for whom you wish to edit the branches for').'. <br />' . _('When the pages is called from within the system this will always be the case').' <br />' . _('Select a customer first then select the link to add/edit/delete branches'),'warn'); @@ -24,13 +23,14 @@ exit; } -if(isset($_GET['SelectedBranch'])) { + +if (isset($_GET['SelectedBranch'])){ $SelectedBranch = mb_strtoupper($_GET['SelectedBranch']); -} elseif(isset($_POST['SelectedBranch'])) { +} else if (isset($_POST['SelectedBranch'])){ $SelectedBranch = mb_strtoupper($_POST['SelectedBranch']); } -if(isset($Errors)) { +if (isset($Errors)) { unset($Errors); } @@ -38,7 +38,7 @@ $Errors = array(); $InputError = 0; -if(isset($_POST['submit'])) { +if (isset($_POST['submit'])) { $i=1; @@ -49,53 +49,53 @@ $_POST['BranchCode'] = mb_strtoupper($_POST['BranchCode']); - if($_SESSION['SalesmanLogin'] != '') { + if ($_SESSION['SalesmanLogin'] != '') { $_POST['Salesman'] = $_SESSION['SalesmanLogin']; } - if(ContainsIllegalCharacters($_POST['BranchCode']) OR mb_strstr($_POST['BranchCode'],' ')) { + if (ContainsIllegalCharacters($_POST['BranchCode']) OR mb_strstr($_POST['BranchCode'],' ')) { $InputError = 1; prnMsg(_('The Branch code cannot contain any of the following characters')." - & \' < >",'error'); $Errors[$i] = 'BranchCode'; $i++; } - if(mb_strlen($_POST['BranchCode'])==0) { + if (mb_strlen($_POST['BranchCode'])==0) { $InputError = 1; prnMsg(_('The Branch code must be at least one character long'),'error'); $Errors[$i] = 'BranchCode'; $i++; } - if(!is_numeric($_POST['FwdDate'])) { + if (!is_numeric($_POST['FwdDate'])) { $InputError = 1; prnMsg(_('The date after which invoices are charged to the following month is expected to be a number and a recognised number has not been entered'),'error'); $Errors[$i] = 'FwdDate'; $i++; } - if($_POST['FwdDate'] >30) { + if ($_POST['FwdDate'] >30) { $InputError = 1; prnMsg(_('The date (in the month) after which invoices are charged to the following month should be a number less than 31'),'error'); $Errors[$i] = 'FwdDate'; $i++; } - if(!is_numeric(filter_number_format($_POST['EstDeliveryDays']))) { + if (!is_numeric(filter_number_format($_POST['EstDeliveryDays']))) { $InputError = 1; prnMsg(_('The estimated delivery days is expected to be a number and a recognised number has not been entered'),'error'); $Errors[$i] = 'EstDeliveryDays'; $i++; } - if(filter_number_format($_POST['EstDeliveryDays']) >60) { + if (filter_number_format($_POST['EstDeliveryDays']) >60) { $InputError = 1; prnMsg(_('The estimated delivery days should be a number of days less than 60') . '. ' . _('A package can be delivered by seafreight anywhere in the world normally in less than 60 days'),'error'); $Errors[$i] = 'EstDeliveryDays'; $i++; } - if(!isset($_POST['EstDeliveryDays'])) { + if (!isset($_POST['EstDeliveryDays'])) { $_POST['EstDeliveryDays']=1; } - if(!isset($Latitude)) { + if (!isset($Latitude)) { $Latitude=0.0; $Longitude=0.0; } - if($_SESSION['geocode_integration']==1 ) { + if ($_SESSION['geocode_integration']==1 ){ // Get the lat/long from our geocoding host $SQL = "SELECT * FROM geocode_param WHERE 1"; $ErrMsg = _('An error occurred in retrieving the information'); @@ -105,7 +105,7 @@ $map_host = $row['map_host']; define('MAPS_HOST', $map_host); define('KEY', $api_key); - if($map_host=="") { + if ($map_host=="") { // check that some sane values are setup already in geocode tables, if not skip the geocoding but add the record anyway. echo '<div class="warn">' . _('Warning - Geocode Integration is enabled, but no hosts are setup. Go to Geocode Setup') . '</div>'; } else { @@ -120,7 +120,7 @@ $Longitude = $CoordinatesSplit[0]; $Status = $xml->Response->Status->code; - if(strcmp($Status, '200') == 0) { + if (strcmp($Status, '200') == 0) { // Successful geocode $Geocode_Pending = false; $Coordinates = $xml->Response->Placemark->Point->Coordinates; @@ -136,7 +136,7 @@ } } } - if(isset($SelectedBranch) AND $InputError !=1) { + if (isset($SelectedBranch) AND $InputError !=1) { /*SelectedBranch 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*/ @@ -171,13 +171,13 @@ deliverblind='" . $_POST['DeliverBlind'] . "' WHERE branchcode = '".$SelectedBranch."' AND debtorno='".$DebtorNo."'"; - if($_SESSION['SalesmanLogin'] != '') { + if ($_SESSION['SalesmanLogin'] != '') { $SQL .= " AND custbranch.salesman='" . $_SESSION['SalesmanLogin'] . "'"; } $msg = $_POST['BrName'] . ' '._('branch has been updated.'); - } elseif($InputError !=1) { + } else if ($InputError !=1) { /*Selected branch is null cos no item selected on first time round so must be adding a record must be submitting new entries in the new Customer Branches form */ @@ -250,11 +250,11 @@ //run the SQL from either of the above possibilites $ErrMsg = _('The branch record could not be inserted or updated because'); - if($InputError==0) { + if ($InputError==0) { $result = DB_query($SQL, $ErrMsg); } - if(DB_error_no() ==0 AND $InputError==0) { + if (DB_error_no() ==0 AND $InputError==0) { prnMsg($msg,'success'); unset($_POST['BranchCode']); unset($_POST['BrName']); @@ -286,7 +286,7 @@ unset($_POST['DeliverBlind']); unset($SelectedBranch); } -} elseif(isset($_GET['delete'])) { +} else if (isset($_GET['delete'])) { //the link to delete a selected record was clicked instead of the submit button // PREVENT DELETES IF DEPENDENT RECORDS IN 'DebtorTrans' @@ -295,7 +295,7 @@ $result = DB_query($SQL); $myrow = DB_fetch_row($result); - if($myrow[0]>0) { + if ($myrow[0]>0) { prnMsg(_('Cannot delete this branch because customer transactions have been created to this branch') . '<br />' . _('There are').' ' . $myrow[0] . ' '._('transactions with this Branch Code'),'error'); @@ -305,7 +305,7 @@ $result = DB_query($SQL); $myrow = DB_fetch_row($result); - if($myrow[0]>0) { + if ($myrow[0]>0) { prnMsg(_('Cannot delete this branch because sales analysis records exist for it'),'error'); echo '<br />' . _('There are').' ' . $myrow[0] . ' '._('sales analysis records with this Branch Code/customer'); @@ -315,7 +315,7 @@ $result = DB_query($SQL); $myrow = DB_fetch_row($result); - if($myrow[0]>0) { + if ($myrow[0]>0) { prnMsg(_('Cannot delete this branch because sales orders exist for it') . '. ' . _('Purge old sales orders first'),'warn'); echo '<br />' . _('There are').' ' . $myrow[0] . ' '._('sales orders for this Branch/customer'); } else { @@ -325,7 +325,7 @@ $result = DB_query($SQL); $myrow = DB_fetch_row($result); - if($myrow[0]>0) { + if ($myrow[0]>0) { prnMsg(_('Cannot delete this branch because users exist that refer to it') . '. ' . _('Purge old users first'),'warn'); echo '<br />' . _('There are') . ' ' . $myrow[0] . ' '._('users referring to this Branch/customer'); } else { @@ -335,7 +335,7 @@ $result = DB_query($SQL); $myrow = DB_fetch_row($result); - if($myrow[0]>0) { + if ($myrow[0]>0) { prnMsg(_('Cannot delete this branch because contract have been created that refer to it') . '. ' . _('Purge old contracts first'),'warn'); echo '<br />' . _('There are') . ' ' . $myrow[0] . ' '._('contracts referring to this branch/customer'); } else { @@ -345,16 +345,16 @@ $result = DB_query($SQL); $myrow = DB_fetch_row($result); - if($myrow[0]==1) { + if ($myrow[0]==1) { prnMsg(_('Cannot delete this branch because it is the only branch defined for this customer.'),'warn'); } else { $SQL="DELETE FROM custbranch WHERE branchcode='" . $SelectedBranch . "' AND debtorno='" . $DebtorNo . "'"; - if($_SESSION['SalesmanLogin'] != '') { + if ($_SESSION['SalesmanLogin'] != '') { $SQL .= " AND custbranch.salesman='" . $_SESSION['SalesmanLogin'] . "'"; } $ErrMsg = _('The branch record could not be deleted') . ' - ' . _('the SQL server returned the following message'); $result = DB_query($SQL,$ErrMsg); - if(DB_error_no()==0) { + if (DB_error_no()==0){ prnMsg(_('Branch Deleted'),'success'); } } @@ -365,7 +365,7 @@ }//end ifs to test if the branch can be deleted } -if(!isset($SelectedBranch)) { +if (!isset($SelectedBranch)){ /* It could still be the second time the page has been run and a record has been selected for modification - SelectedBranch 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 branches 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*/ @@ -390,7 +390,7 @@ ON custbranch.taxgroupid=taxgroups.taxgroupid WHERE custbranch.debtorno = '".$DebtorNo."'"; - if($_SESSION['SalesmanLogin'] != '') { + if ($_SESSION['SalesmanLogin'] != '') { $SQL .= " AND custbranch.salesman='" . $_SESSION['SalesmanLogin'] . "'"; } @@ -398,7 +398,7 @@ $myrow = DB_fetch_row($result); $TotalEnable = 0; $TotalDisable = 0; - if($myrow) { + if ($myrow) { echo '<p class="page_title_text"><img alt="" src="', $RootPath, '/css/', $Theme, '/images/customer.png" title="',// Icon image. _('Customer'), '" /> ',// Icon title. @@ -419,7 +419,7 @@ $k=0; do { - if($k==1) { + if ($k==1){ echo '<tr class="EvenTableRows">'; $k=0; } else { @@ -459,7 +459,7 @@ urlencode($myrow[1]), _('Delete Branch')); - if($myrow[10]) { + if ($myrow[10]){ $TotalDisable++; } else { $TotalEnable++; @@ -503,12 +503,12 @@ } } -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($SelectedBranch)) { + if (isset($SelectedBranch)) { //editing an existing branch $SQL = "SELECT branchcode, @@ -543,14 +543,14 @@ WHERE branchcode='".$SelectedBranch."' AND debtorno='".$DebtorNo."'"; - if($_SESSION['SalesmanLogin'] != '') { + if ($_SESSION['SalesmanLogin'] != '') { $SQL .= " AND custbranch.salesman='" . $_SESSION['SalesmanLogin'] . "'"; } $result = DB_query($SQL); $myrow = DB_fetch_array($result); - if($InputError==0) { + if ($InputError==0) { $_POST['BranchCode'] = $myrow['branchcode']; $_POST['BrName'] = $myrow['brname']; $_POST['BrAddress1'] = $myrow['braddress1']; @@ -586,7 +586,7 @@ echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/customer.png" title="' . _('Customer') . '" alt="" /> ' . ' ' . _('Change Details for Branch'). ' '. $SelectedBranch . '</p>'; - if(isset($SelectedBranch)) { + if (isset($SelectedBranch)) { echo '<div class="centre"><a href="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '?DebtorNo=' . $DebtorNo. '">' . _('Show all branches defined for'). ' '. $DebtorNo . '</a></div>'; } echo '<br /> @@ -606,7 +606,7 @@ /* SETUP ANY $_GET VALUES THAT ARE PASSED. This really is just used coming from the Customers.php when a new customer is created. Maybe should only do this when that page is the referrer? */ - if(isset($_GET['BranchCode'])) { + if (isset($_GET['BranchCode'])){ $SQL="SELECT name, address1, address2, @@ -628,7 +628,7 @@ $_POST['BrAddress5'] = $myrow['addrsss5']; $_POST['BrAddress6'] = $myrow['addrsss6']; } - if(!isset($_POST['BranchCode'])) { + if (!isset($_POST['BranchCode'])) { $_POST['BranchCode']=''; } echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/customer.png" title="' . _('Customer') . '" alt="" />' . ' ' . _('Add a Branch') . '</p>'; @@ -647,58 +647,58 @@ echo _('Branch Name').':</td>'; - if(!isset($_POST['BrName'])) {$_POST['BrName']='';} + if (!isset($_POST['BrName'])) {$_POST['BrName']='';} echo '<td><input tabindex="2" type="text" autofocus="autofocus" required="required" name="BrName" title="' . _('The branch name should identify the particular delivery address of the customer and must be entered') . '" minlength="5" size="41" maxlength="40" value="'. $_POST['BrName'].'" /></td> </tr>'; echo '<tr> <td>' . _('Branch Contact').':</td>'; - if(!isset($_POST['ContactName'])) {$_POST['ContactName']='';} + if (!isset($_POST['ContactName'])) {$_POST['ContactName']='';} echo '<td><input tabindex="3" type="text" name="ContactName" required="required" size="41" maxlength="40" value="'. $_POST['ContactName'].'" /></td> </tr>'; echo '<tr><td>' . _('Street Address 1 (Street)').':</td>'; - if(!isset($_POST['BrAddress1'])) { + if (!isset($_POST['BrAddress1'])) { $_POST['BrAddress1']=''; } echo '<td><input tabindex="4" type="text" name="BrAddress1" size="41" maxlength="40" value="'. $_POST['BrAddress1'].'" /></td> </tr> <tr> <td>' . _('Street Address 2 (Street)').':</td>'; - if(!isset($_POST['BrAddress2'])) { + if (!isset($_POST['BrAddress2'])) { $_POST['BrAddress2']=''; } echo '<td><input tabindex="5" type="text" name="BrAddress2" size="41" maxlength="40" value="'. $_POST['BrAddress2'].'" /></td> </tr> <tr> <td>' . _('Street Address 3 (Suburb/City)').':</td>'; - if(!isset($_POST['BrAddress3'])) { + if (!isset($_POST['BrAddress3'])) { $_POST['BrAddress3']=''; } echo '<td><input tabindex="6" type="text" name="BrAddress3" size="41" maxlength="40" value="'. $_POST['BrAddress3'].'" /></td> </tr> <tr> <td>' . _('Street Address 4 (State/Province)').':</td>'; - if(!isset($_POST['BrAddress4'])) { + if (!isset($_POST['BrAddress4'])) { $_POST['BrAddress4']=''; } echo '<td><input tabindex="7" type="text" name="BrAddress4" size="51" maxlength="50" value="'. $_POST['BrAddress4'].'" /></td> </tr> <tr> <td>' . _('Street Address 5 (Postal Code)').':</td>'; - if(!isset($_POST['BrAddress5'])) { + if (!isset($_POST['BrAddress5'])) { $_POST['BrAddress5']=''; } echo '<td><input tabindex="8" type="text" name="BrAddress5" size="21" maxlength="20" value="'. $_POST['BrAddress5'].'" /></td> </tr> <tr> <td>' . _('Country').':</td>'; - if(!isset($_POST['BrAddress6'])) { + if (!isset($_POST['BrAddress6'])) { $_POST['BrAddress6']=''; } echo '<td><select name="BrAddress6">'; - foreach ($CountriesArray as $CountryEntry => $CountryName) { - if(isset($_POST['BrAddress6']) AND ($_POST['BrAddress6'] == $CountryName)) { + foreach ($CountriesArray as $CountryEntry => $CountryName){ + if (isset($_POST['BrAddress6']) AND ($_POST['BrAddress6'] == $CountryName)) { echo '<option selected="selected" value="' . $CountryName . '">' . $CountryName . '</option>'; - } elseif(!isset($_POST['BrAddress6']) AND $CountryName == "") { + } elseif (!isset($_POST['BrAddress6']) AND $CountryName == "") { echo '<option selected="selected" value="' . $CountryName . '">' . $CountryName . '</option>'; } else { echo '<option value="' . $CountryName . '">' . $CountryName . '</option>'; @@ -709,27 +709,27 @@ echo '<tr> <td>' . _('Special Instructions').':</td>'; - if(!isset($_POST['SpecialInstructions'])) { + if (!isset($_POST['SpecialInstructions'])) { $_POST['SpecialInstructions']=''; } echo '<td><input tabindex="10" type="text" name="SpecialInstructions" size="56" value="'. $_POST['SpecialInstructions'].'" /></td> </tr> <tr> <td>' . _('Default days to deliver').':</td>'; - if(!isset($_POST['EstDeliveryDays'])) { + if (!isset($_POST['EstDeliveryDays'])) { $_POST['EstDeliveryDays']=0; } echo '<td><input ' .(in_array('EstDeliveryDays',$Errors) ? 'class="inputerror"' : '' ) .' tabindex="11" type="text" class="integer" name="EstDeliveryDays" size="4" maxlength="2" value="'. $_POST['EstDeliveryDays'].'" /></td> </tr> <tr> <td>' . _('Forward Date After (day in month)').':</td>'; - if(!isset($_POST['FwdDate'])) { + if (!isset($_POST['FwdDate'])) { $_POST['FwdDate']=0; } echo '<td><input ' .(in_array('FwdDate',$Errors) ? 'class="inputerror"' : '' ) .' tabindex="12" class="integer" name="FwdDate" size="4" maxlength="2" value="'. $_POST['FwdDate'].'" /></td> </tr>'; - if($_SESSION['SalesmanLogin'] != '') { + if ($_SESSION['SalesmanLogin'] != '') { echo '<tr> <td>' . _('Salesperson').':</td><td>'; echo $_SESSION['UsersRealName']; @@ -746,7 +746,7 @@ $result = DB_query($SQL); - if(DB_num_rows($result)==0) { + if (DB_num_rows($result)==0){ echo '</table>'; prnMsg(_('There are no sales people defined as yet') . ' - ' . _('customer branches must be allocated to a sales person') . '. ' . _('Please use the link below to define at least one sales person'),'error'); echo '<p align="center"><a href="' . $RootPath . '/SalesPeople.php">' . _('Define Sales People') . '</a>'; @@ -759,7 +759,7 @@ <td><select tabindex="13" name="Salesman">'; while ($myrow = DB_fetch_array($result)) { - if(isset($_POST['Salesman']) AND $myrow['salesmancode']==$_POST['Salesman']) { + if (isset($_POST['Salesman']) AND $myrow['salesmancode']==$_POST['Salesman']) { echo '<option selected="selected" value="'; } else { echo '<option value="'; @@ -775,7 +775,7 @@ } $SQL = "SELECT areacode, areadescription FROM areas ORDER BY areadescription"; $result = DB_query($SQL); - if(DB_num_rows($result)==0) { + if (DB_num_rows($result)==0){ echo '</table>'; prnMsg(_('There are no areas defined as yet') . ' - ' . _('customer branches must be allocated to an area') . '. ' . _('Please use the link below to define at least one sales area'),'error'); echo '<br /><a href="' . $RootPath. '/Areas.php">' . _('Define Sales Areas') . '</a>'; @@ -787,7 +787,7 @@ <td>' . _('Sales Area').':</td> <td><select tabindex="14" name="Area">'; while ($myrow = DB_fetch_array($result)) { - if(isset($_POST['Area']) AND $myrow['areacode']==$_POST['Area']) { + if (isset($_POST['Area']) AND $myrow['areacode']==$_POST['Area']) { echo '<option selected="selected" value="'; } else { echo '<option value="'; @@ -811,7 +811,7 @@ ORDER BY locationname"; $result = DB_query($SQL); - if(DB_num_rows($result)==0) { + if (DB_num_rows($result)==0){ echo '</table>'; prnMsg(_('There are no stock locations defined as yet') . ' - ' . _('customer branches must refer to a default location where stock is normally drawn from') . '. ' . _('Please use the link below to define at least one stock location'),'error'); echo '<br /><a href="', $RootPath, '/Locations.php">', _('Define Stock Locations'), '</a>'; @@ -823,8 +823,8 @@ <td>', _('Draw Stock From'), ':</td> <td><select name="DefaultLocation" tabindex="15">'; - while($myrow = DB_fetch_array($result)) { - if(isset($_POST['DefaultLocation']) AND $myrow['loccode']==$_POST['DefaultLocation']) { + while ($myrow = DB_fetch_array($result)) { + if (isset($_POST['DefaultLocation']) AND $myrow['loccode']==$_POST['DefaultLocation']) { echo '<option selected="selected" value="'; } else { echo '<option value="'; @@ -837,7 +837,7 @@ </tr> <tr> <td>' . _('Phone Number').':</td>'; - if(!isset($_POST['PhoneNo'])) { + if (!isset($_POST['PhoneNo'])) { $_POST['PhoneNo']=''; } echo '<td><input tabindex="16" type="tel" name="PhoneNo" pattern="[0-9+()\s-]*" size="22" maxlength="20" value="'. $_POST['PhoneNo'].'" /></td> @@ -845,13 +845,13 @@ echo '<tr> <td>' . _('Fax Number').':</td>'; - if(!isset($_POST['FaxNo'])) { + if (!isset($_POST['FaxNo'])) { $_POST['FaxNo']=''; } echo '<td><input tabindex="17" type="tel" name="FaxNo" pattern="[0-9+()\s-]*" size="22" maxlength="20" value="'. $_POST['FaxNo'].'" /></td> </tr>'; - if(!isset($_POST['Email'])) { + if (!isset($_POST['Email'])) { $_POST['Email']=''; } echo '<tr> @@ -864,7 +864,7 @@ $SQL = "SELECT taxgroupid, taxgroupdescription FROM taxgroups"; $TaxGroupResults = DB_query($SQL); - if(DB_num_rows($TaxGroupResults)==0) { + if (DB_num_rows($TaxGroupResults)==0){ echo '</table>'; prnMsg(_('There are no tax groups defined - these must be set up first before any branches can be set up') . ' <br /><a href="' . $RootPath . '/TaxGroups.php">' . _('Define Tax Groups') . '</a>','error'); @@ -876,7 +876,7 @@ <td><select tabindex="19" name="TaxGroup">'; while ($myrow = DB_fetch_array($TaxGroupResults)) { - if(isset($_POST['TaxGroup']) AND $myrow['taxgroupid']==$_POST['TaxGroup']) { + if (isset($_POST['TaxGroup']) AND $myrow['taxgroupid']==$_POST['TaxGroup']) { echo '<option selected="selected" value="'; } else { echo '<option value="'; @@ -890,7 +890,7 @@ <tr> <td>' . _('Transactions on this branch') . ':</td> <td><select tabindex="20" name="DisableTrans">'; - if(isset($_POST['DisableTrans']) AND $_POST['DisableTrans']==0) { + if (!isset($_POST['DisableTrans']) OR $_POST['DisableTrans']==0){ echo '<option selected="selected" value="0">' . _('Enabled') . '</option> <option value="1">' . _('Disabled') . '</option>'; } else { @@ -905,7 +905,7 @@ $SQL = "SELECT shipper_id, shippername FROM shippers"; $ShipperResults = DB_query($SQL); - if(DB_num_rows($ShipperResults)==0) { + if (DB_num_rows($ShipperResults)==0){ echo '</table>'; prnMsg(_('There are no shippers defined - these must be set up first before any branches can be set up') . ' <br /><a href="' . $RootPath . '/Shippers.php">' . _('Define Shippers') . '</a>','error'); @@ -915,8 +915,8 @@ echo '<tr> <td>' . _('Default freight/shipper method') . ':</td> <td><select tabindex="21" name="DefaultShipVia">'; - while ($myrow=DB_fetch_array($ShipperResults)) { - if(isset($_POST['DefaultShipVia'])and $myrow['shipper_id']==$_POST['DefaultShipVia']) { + while ($myrow=DB_fetch_array($ShipperResults)){ + if (isset($_POST['DefaultShipVia'])and $myrow['shipper_id']==$_POST['DefaultShipVia']) { echo '<option selected="selected" value="' . $myrow['shipper_id'] . '">' . $myrow['shippername'] . '</option>'; } else { echo '<option value="' . $myrow['shipper_id'] . '">' . $myrow['shippername'] . '</option>'; @@ -932,7 +932,7 @@ echo '<tr> <td>' . _('Default Packlist') . ':</td> <td><select tabindex="22" name="DeliverBlind">'; - if($_POST['DeliverBlind']==2) { + if ($_POST['DeliverBlind']==2){ echo '<option value="1">' . _('Show company details and logo') . '</option> <option selected="selected" value="2">' . _('Hide company details and logo') . '</option>'; } else { @@ -942,23 +942,23 @@ echo '</select></td> </tr>'; - if(!isset($_POST['BrPostAddr1'])) {// Postal address, line 1. Database: custbranch.brpostaddr1, varchar(40) + if (!isset($_POST['BrPostAddr1'])) {// Postal address, line 1. Database: custbranch.brpostaddr1, varchar(40) $_POST['BrPostAddr1']=''; } echo '<tr> - <td>', _('Postal Address 1 (Street)'), ':</td> + <td>' . _('Postal Address 1 (Street)') . ':</td> <td><input maxlength="40" name="BrPostAddr1" size="41" tabindex="23" type="text" value="', $_POST['BrPostAddr1'].'" /></td> </tr>'; - if(!isset($_POST['BrPostAddr2'])) {// Postal address, line 2. Database: custbranch.brpostaddr2, varchar(40) + if (!isset($_POST['BrPostAddr2'])){// Postal address, line 2. Database: custbranch.brpostaddr2, varchar(40) $_POST['BrPostAddr2']=''; } echo '<tr> - <td>', _('Postal Address 2 (Suburb/City)'), ':</td> + <td>' , _('Postal Address 2 (Suburb/City)'), ':</td> <td><input maxlength="40" name="BrPostAddr2" size="41" tabindex="24" type="text" value="', $_POST['BrPostAddr2'].'" /></td> </tr>'; - if(!isset($_POST['BrPostAddr3'])) {// Postal address, line 3. Database: custbranch.brpostaddr3, varchar(40) + if (!isset($_POST['BrPostAddr3'])) {// Postal address, line 3. Database: custbranch.brpostaddr3, varchar(40) $_POST['BrPostAddr3']=''; } echo '<tr> @@ -966,7 +966,7 @@ <td><input maxlength="40" name="BrPostAddr3" size="41" tabindex="25" type="text" value="', $_POST['BrPostAddr3'].'" /></td> </tr>'; - if(!isset($_POST['BrPostAddr4'])) {// Postal address, line 4. Database: custbranch.brpostaddr4, varchar(40) + if (!isset($_POST['BrPostAddr4'])) {// Postal address, line 4. Database: custbranch.brpostaddr4, varchar(40) $_POST['BrPostAddr4']=''; } echo '<tr> @@ -974,7 +974,7 @@ <td><input maxlength="40" name="BrPostAddr4" size="41" tabindex="26" type="text" value="', $_POST['BrPostAddr4'].'" /></td> </tr>'; - if(!isset($_POST['BrPostAddr5'])) {// Postal address, line 5. Database: custbranch.brpostaddr5, varchar(20) + if (!isset($_POST['BrPostAddr5'])) {// Postal address, line 5. Database: custbranch.brpostaddr5, varchar(20) $_POST['BrPostAddr5']=''; } echo '<tr> @@ -1000,4 +1000,4 @@ }//end if record deleted no point displaying form to add record include('includes/footer.inc'); -?> \ No newline at end of file +?> |
From: <ex...@us...> - 2015-12-10 10:03:51
|
Revision: 7412 http://sourceforge.net/p/web-erp/reponame/7412 Author: exsonqu Date: 2015-12-10 10:03:48 +0000 (Thu, 10 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-10 10:03:15 UTC (rev 7411) +++ trunk/doc/Change.log 2015-12-10 10:03:48 UTC (rev 7412) @@ -1,5 +1,5 @@ webERP Change Log - +10/12/15 Exson: Add invoice no while reprint GRN in ReprintGRN.php. 10/12/15 Exson: Add multiple work orders total cost inquiry script. 09/12/05 Exson: Fixed the telephone regular expression bug in SelectCustomer.php. Reported by Terry. 01/12/15 Exson: Remove the wrong foreign key in suppinvstogrn. Reported by rafael. |
From: <ex...@us...> - 2015-12-10 10:03:18
|
Revision: 7411 http://sourceforge.net/p/web-erp/reponame/7411 Author: exsonqu Date: 2015-12-10 10:03:15 +0000 (Thu, 10 Dec 2015) Log Message: ----------- 10/12/15 Exson: Add invoice no while reprint GRN in ReprintGRN.php. Modified Paths: -------------- trunk/ReprintGRN.php Modified: trunk/ReprintGRN.php =================================================================== --- trunk/ReprintGRN.php 2015-12-10 09:35:17 UTC (rev 7410) +++ trunk/ReprintGRN.php 2015-12-10 10:03:15 UTC (rev 7411) @@ -49,16 +49,18 @@ exit; } $sql="SELECT grnbatch, - grnno, + grns.grnno, grns.podetailitem, grns.itemcode, grns.itemdescription, grns.deliverydate, grns.qtyrecd, + suppinvstogrn.suppinv, suppliers.suppname, stockmaster.decimalplaces FROM grns INNER JOIN suppliers ON grns.supplierid=suppliers.supplierid + LEFT JOIN suppinvstogrn ON grns.grnno=suppinvstogrn.grnno INNER JOIN purchorderdetails ON grns.podetailitem=purchorderdetails.podetailitem INNER JOIN purchorders on purchorders.orderno=purchorderdetails.orderno @@ -87,6 +89,7 @@ <th>' . _('Item Description') . '</th> <th>' . _('Delivery Date') . '</th> <th>' . _('Quantity Received') . '</th> + <th>' . _('Invoice No') . '</th> <th>' . _('Action') . '</th> </tr>'; @@ -105,6 +108,7 @@ <td>' . $myrow['itemdescription'] . '</td> <td>' . $myrow['deliverydate'] . '</td> <td class="number">' . locale_number_format($myrow['qtyrecd'], $myrow['decimalplaces']) . '</td> + <td>' . $myrow['suppinv'] . '</td> <td><a href="PDFGrn.php?GRNNo=' . $myrow['grnbatch'] .'&PONo=' . $_POST['PONumber'] . '">' . _('Reprint GRN ') . '</a> <a href="PDFQALabel.php?GRNNo=' . $myrow['grnbatch'] .'&PONo=' . $_POST['PONumber'] . '">' . _('Reprint Labels') . '</a></td> </tr>'; @@ -114,4 +118,4 @@ include('includes/footer.inc'); -?> \ No newline at end of file +?> |
From: <ex...@us...> - 2015-12-10 09:35:19
|
Revision: 7410 http://sourceforge.net/p/web-erp/reponame/7410 Author: exsonqu Date: 2015-12-10 09:35:17 +0000 (Thu, 10 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-10 09:34:34 UTC (rev 7409) +++ trunk/doc/Change.log 2015-12-10 09:35:17 UTC (rev 7410) @@ -1,5 +1,6 @@ webERP Change Log +10/12/15 Exson: Add multiple work orders total cost inquiry script. 09/12/05 Exson: Fixed the telephone regular expression bug in SelectCustomer.php. Reported by Terry. 01/12/15 Exson: Remove the wrong foreign key in suppinvstogrn. Reported by rafael. 26/11/15 Exson: Fixed the rounding error caused extra lines on WO pdf file and 2 number display without locale format in PDFWOPrint.php. |
From: <ex...@us...> - 2015-12-10 09:34:37
|
Revision: 7409 http://sourceforge.net/p/web-erp/reponame/7409 Author: exsonqu Date: 2015-12-10 09:34:34 +0000 (Thu, 10 Dec 2015) Log Message: ----------- 10/12/15 Exson: Add multiple work orders total cost inquiry script. Modified Paths: -------------- trunk/includes/MainMenuLinksArray.php trunk/sql/mysql/upgrade4.12.3-4.13.sql Added Paths: ----------- trunk/CollectiveWorkOrderCost.php Added: trunk/CollectiveWorkOrderCost.php =================================================================== --- trunk/CollectiveWorkOrderCost.php (rev 0) +++ trunk/CollectiveWorkOrderCost.php 2015-12-10 09:34:34 UTC (rev 7409) @@ -0,0 +1,519 @@ +<?php + +include('includes/session.inc'); +$Title = _('Search Work Orders'); +include('includes/header.inc'); + +echo '<p class="page_title_text"><img src="'.$RootPath.'/css/'.$Theme.'/images/magnifier.png" title="' . _('Search') . '" alt="" />' . ' ' . $Title . '</p> + <form action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post"> + <div> + <input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />'; + +if (isset($_POST['Submit'])) {//users have selected the WO to calculate and submit it + $WOSelected = ''; + $i = 0; + foreach ($_POST as $Key=>$Value) { + if (substr($Key,0,3) == 'WO_'){ + if ($i>0) $WOSelected .=","; + if($Value == 'on'){ + $WOSelected .= substr($Key,3); + } + $i++; + } + } + if (empty($WOSelected)) { + prnMsg(_('There are no work orders selected'),'error'); + } else { + //lets do the workorder issued items retrieve + $sql = "SELECT stockmoves.stockid, + stockmaster.description, + stockmaster.decimalplaces, + trandate, + qty, + reference, + stockmoves.standardcost + FROM stockmoves INNER JOIN stockmaster + ON stockmoves.stockid=stockmaster.stockid + WHERE stockmoves.type=28 + AND reference IN (" . $WOSelected . ") + ORDER BY reference"; + $ErrMsg = _('Failed to retrieve wo cost data'); + $result = DB_query($sql,$ErrMsg); + if (DB_num_rows($result)>0) { + echo '<table class="selection"> + <tr><th class="ascending">' . _('Item') . '</th> + <th>' . _('Description') . '</th> + <th class="ascending">' . _('Date Issued') . '</th> + <th class="ascending">' . _('Issued Qty') . '</th> + <th class="ascending">' . _('Issued Cost') . '</th> + <th class="ascending">' . _('Work Order') . '</th> + </tr>'; + $i = 0; + $TotalCost = 0; + while ($myrow = DB_fetch_array($result)){ + if ($i==0) { + echo '<tr class="EvenTableRows">'; + $i = 1; + } else { + echo '<tr class="OddTableRows">'; + $i = 0; + } + $IssuedQty = - $myrow['qty']; + $IssuedCost = $IssuedQty * $myrow['standardcost']; + $TotalCost += $IssuedCost; + echo '<td>' . $myrow['stockid'] . '</td> + <td>' . $myrow['description'] . '</td> + <td>' . $myrow['trandate'] . '</td> + <td class="number">' . locale_number_format($IssuedQty,$myrow['decimalplaces']) . '</td> + <td class="number">' . locale_number_format($IssuedCost,2) . '</td> + <td>' . $myrow['reference'] . '</td> + </tr>'; + } + echo '<tr><td colspan="4"><b>' . _('Total Cost') . '</b></td> + <td colspan="2"><b>' .locale_number_format($TotalCost,2) . '</b></td> + </tr></table>'; + } else { + prnMsg(_('There are no data available'),'error'); + include('includes/footer.inc'); + exit; + } + }//end of the work orders are not empty + echo '<a href="'.htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '">' . _('Select Other Work Orders') . '</a>'; + include('includes/footer.inc'); + exit; + +} + + +if (isset($_GET['WO'])) { + $SelectedWO = $_GET['WO']; +} elseif (isset($_POST['WO'])){ + $SelectedWO = $_POST['WO']; +} else { + unset($SelectedWO); +} + +if (isset($_GET['SelectedStockItem'])) { + $SelectedStockItem = $_GET['SelectedStockItem']; +} elseif (isset($_POST['SelectedStockItem'])){ + $SelectedStockItem = $_POST['SelectedStockItem']; +} else { + unset($SelectedStockItem); +} + + +if (isset($_POST['ResetPart'])){ + unset($SelectedStockItem); +} + +if (isset($SelectedWO) AND $SelectedWO!='') { + $SelectedWO = trim($SelectedWO); + if (!is_numeric($SelectedWO)){ + prnMsg(_('The work order number entered MUST be numeric'),'warn'); + unset ($SelectedWO); + include('includes/footer.inc'); + exit; + } else { + echo _('Work Order Number') . ' - ' . $SelectedWO; + } +} + +if (isset($_POST['SearchParts'])){ + + if ($_POST['Keywords'] AND $_POST['StockCode']) { + echo _('Stock description keywords have been used in preference to the Stock code extract entered'); + } + if ($_POST['Keywords']) { + //insert wildcard characters in spaces + $SearchString = '%' . str_replace(' ', '%', $_POST['Keywords']) . '%'; + + $SQL = "SELECT stockmaster.stockid, + stockmaster.description, + stockmaster.decimalplaces, + SUM(locstock.quantity) AS qoh, + stockmaster.units + FROM stockmaster, + locstock + WHERE stockmaster.stockid=locstock.stockid + AND stockmaster.description " . LIKE . " '" . $SearchString . "' + AND stockmaster.categoryid='" . $_POST['StockCat']. "' + AND stockmaster.mbflag='M' + GROUP BY stockmaster.stockid, + stockmaster.description, + stockmaster.decimalplaces, + stockmaster.units + ORDER BY stockmaster.stockid"; + + } elseif (isset($_POST['StockCode'])){ + $SQL = "SELECT stockmaster.stockid, + stockmaster.description, + stockmaster.decimalplaces, + sum(locstock.quantity) as qoh, + stockmaster.units + FROM stockmaster, + locstock + WHERE stockmaster.stockid=locstock.stockid + AND stockmaster.stockid " . LIKE . " '%" . $_POST['StockCode'] . "%' + AND stockmaster.categoryid='" . $_POST['StockCat'] . "' + AND stockmaster.mbflag='M' + GROUP BY stockmaster.stockid, + stockmaster.description, + stockmaster.decimalplaces, + stockmaster.units + ORDER BY stockmaster.stockid"; + + } elseif (!isset($_POST['StockCode']) AND !isset($_POST['Keywords'])) { + $SQL = "SELECT stockmaster.stockid, + stockmaster.description, + stockmaster.decimalplaces, + sum(locstock.quantity) as qoh, + stockmaster.units + FROM stockmaster, + locstock + WHERE stockmaster.stockid=locstock.stockid + AND stockmaster.categoryid='" . $_POST['StockCat'] ."' + AND stockmaster.mbflag='M' + GROUP BY stockmaster.stockid, + stockmaster.description, + stockmaster.decimalplaces, + stockmaster.units + ORDER BY stockmaster.stockid"; + } + + $ErrMsg = _('No items were returned by the SQL because'); + $DbgMsg = _('The SQL used to retrieve the searched parts was'); + $StockItemsResult = DB_query($SQL,$db,$ErrMsg,$DbgMsg); +} + +if (isset($_POST['StockID'])){ + $StockID = trim(mb_strtoupper($_POST['StockID'])); +} elseif (isset($_GET['StockID'])){ + $StockID = trim(mb_strtoupper($_GET['StockID'])); +} + +if (!isset($StockID)) { + + /* Not appropriate really to restrict search by date since may miss older + ouststanding orders + $OrdersAfterDate = Date('d/m/Y',Mktime(0,0,0,Date('m')-2,Date('d'),Date('Y'))); + */ + + if (!isset($SelectedWO) or ($SelectedWO=='')){ + echo '<table class="selection"><tr><td>'; + if (isset($SelectedStockItem)) { + echo _('For the item') . ': ' . $SelectedStockItem . ' ' . _('and') . ' <input type="hidden" name="SelectedStockItem" value="' . $SelectedStockItem . '" />'; + } + 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 + WHERE locations.usedforwo = 1"; + + $resultStkLocs = DB_query($sql,$db); + + while ($myrow=DB_fetch_array($resultStkLocs)){ + if (isset($_POST['StockLocation'])){ + if ($myrow['loccode'] == $_POST['StockLocation']){ + echo '<option selected="selected" value="' . $myrow['loccode'] . '">' . $myrow['locationname'] . '</option>'; + } else { + echo '<option value="' . $myrow['loccode'] . '">' . $myrow['locationname'] . '</option>'; + } + } elseif ($myrow['loccode']==$_SESSION['UserStockLocation']){ + echo '<option selected="selected" value="' . $myrow['loccode'] . '">' . $myrow['locationname'] . '</option>'; + } else { + echo '<option value="' . $myrow['loccode'] . '">' . $myrow['locationname'] . '</option>'; + } + } + + echo '</select> + <select name="ClosedOrOpen">'; + + if ($_GET['ClosedOrOpen']=='Closed_Only'){ + $_POST['ClosedOrOpen']='Closed_Only'; + } + + if ($_POST['ClosedOrOpen']=='Closed_Only'){ + echo '<option selected="selected" value="Closed_Only">' . _('Closed Work Orders Only') . '</option>'; + echo '<option value="Open_Only">' . _('Open Work Orders Only') . '</option>'; + echo '<option value="All">' . _('All') . '</option>'; + } elseif($_POST['ClosedOrOpen'] == 'Open_Only') { + echo '<option value="Closed_Only">' . _('Closed Work Orders Only') . '</option>'; + echo '<option selected="selected" value="Open_Only">' . _('Open Work Orders Only') . '</option>'; + echo '<option value="All">' . _('All') . '</option>'; + } elseif ($_POST['ClosedOrOpen'] == 'All') { + echo '<option value="Closed_Only">' . _('Closed Work Orders Only') . '</option>'; + echo '<option value="Open_Only">' . _('Open Work Orders Only') . '</option>'; + echo '<option selected="selected" value="All">' . _('All') . '</option>'; + } else { + echo '<option value="Closed_Only">' . _('Closed Work Orders Only') . '</option>'; + echo '<option value="Open_Only">' . _('Open Work Orders Only') . '</option>'; + echo '<option selected="selected" value="All">' . _('All') . '</option>'; + } + if (!isset($_POST['DateFrom'])) { + $_POST['DateFrom'] = ''; + } + if (!isset($_POST['DateTo'])) { + $_POST['DateTo'] = ''; + } + + echo '</select> + </td> + </tr> + <tr> + <td colspan="2">' . _('Start Date From') . ':<input type="text" name="DateFrom" value="' . $_POST['DateFrom'] . '" class="date" alt="' . $_SESSION['DefaultDateFormat'] . '" /> + + ' . _('Start Date To') . ':<input type="text" name="DateTo" value="' . $_POST['DateTo'] . '" class="date" alt="' . $_SESSION['DefaultDateFormat'] . '" /> + </td> + </tr> + </table>'; + echo '<div class="center"> + <input type="submit" name="SearchOrders" value="' . _('Search') . '" /> + <a href="' . $RootPath . '/WorkOrderEntry.php">' . _('New Work Order') . '</a> + </div> + <br />'; + } + + $SQL="SELECT categoryid, + categorydescription + FROM stockcategory + ORDER BY categorydescription"; + + $result1 = DB_query($SQL,$db); + + echo '<table class="selection"> + <tr> + <th colspan="6"><h3>' . _('To search for work orders for a specific item use the item selection facilities below') . '</h3></th> + </tr> + <tr> + <td>' . _('Select a stock category') . ': + <select name="StockCat">'; + + while ($myrow1 = DB_fetch_array($result1)) { + echo '<option value="'. $myrow1['categoryid'] . '">' . $myrow1['categorydescription'] . '</option>'; + } + + echo '</select></td> + <td>' . _('Enter text extract(s) in the description') . ':</td> + <td><input type="text" name="Keywords" size="20" maxlength="25" /></td> + </tr> + <tr> + <td></td> + <td><b>' . _('OR') . ' </b>' . _('Enter extract of the Stock Code') . ':</td> + <td><input type="text" name="StockCode" size="15" maxlength="18" /></td> + </tr> + </table><br />'; + echo '<div class="centre"><input type="submit" name="SearchParts" value="' . _('Search Items Now') . '" /> + <input type="submit" name="ResetPart" value="' . _('Show All') . '" /></div>'; + + if (isset($StockItemsResult)) { + + echo '<br /> + <table cellpadding="2" class="selection"> + <tr> + <th class="ascending">' . _('Code') . '</th> + <th class="ascending">' . _('Description') . '</th> + <th class="ascending">' . _('On Hand') . '</th> + <th>' . _('Units') . '</th> + </tr>'; + $k=0; //row colour counter + + while ($myrow=DB_fetch_array($StockItemsResult)) { + + if ($k==1){ + echo '<tr class="EvenTableRows">'; + $k=0; + } else { + echo '<tr class="OddTableRows">'; + $k++; + } + + printf('<td><input type="submit" name="SelectedStockItem" value="%s" /></td> + <td>%s</td> + <td class="number">%s</td> + <td>%s</td> + </tr>', + $myrow['stockid'], + $myrow['description'], + locale_number_format($myrow['qoh'],$myrow['decimalplaces']), + $myrow['units']); + + }//end of while loop + echo '</table>'; + } + //end if stock search results to show + else { + + if (!isset($_POST['StockLocation'])) { + $_POST['StockLocation'] = ''; + } + + //figure out the SQL required from the inputs available + if (isset($_POST['ClosedOrOpen']) and $_POST['ClosedOrOpen']=='Open_Only'){ + $ClosedOrOpen = ' AND workorders.closed=0'; + } elseif(isset($_POST['ClosedOrOpen']) AND $_POST['ClosedOrOpen'] == 'Closed_Only') { + $ClosedOrOpen = ' AND workorders.closed=1'; + } else { + $ClosedOrOpen = ''; + } + //start date and end date + if (!empty($_POST['DateFrom'])) { + $StartDateFrom = " AND workorders.startdate>='" . FormatDateForSQL($_POST['DateFrom']) . "'"; + } + if (!empty($_POST['DateTo'])) { + $StartDateTo = " AND workorders.startdate<='" . FormatDateForSQL($_POST['DateTo']) . "'"; + } + + if (isset($SelectedWO) AND $SelectedWO !='') { + $SQL = "SELECT workorders.wo, + woitems.stockid, + stockmaster.description, + stockmaster.decimalplaces, + woitems.qtyreqd, + woitems.qtyrecd, + workorders.requiredby, + workorders.startdate + FROM workorders + INNER JOIN woitems ON workorders.wo=woitems.wo + INNER JOIN stockmaster ON woitems.stockid=stockmaster.stockid + INNER JOIN locationusers ON locationusers.loccode=workorders.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canview=1 + WHERE 1 " . $ClosedOrOpen . $StartDateFrom . $StartDateTo . " + AND workorders.wo='". $SelectedWO ."' + ORDER BY workorders.wo, + woitems.stockid"; + } else { + /* $DateAfterCriteria = FormatDateforSQL($OrdersAfterDate); */ + + if (isset($SelectedStockItem)) { + $SQL = "SELECT workorders.wo, + woitems.stockid, + stockmaster.description, + stockmaster.decimalplaces, + woitems.qtyreqd, + woitems.qtyrecd, + workorders.requiredby, + workorders.startdate + FROM workorders + INNER JOIN woitems ON workorders.wo=woitems.wo + INNER JOIN stockmaster ON woitems.stockid=stockmaster.stockid + INNER JOIN locationusers ON locationusers.loccode=workorders.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canview=1 + WHERE 1 " . $ClosedOrOpen . $StartDateFrom . $StartDateTo . " + AND woitems.stockid='". $SelectedStockItem ."' + AND workorders.loccode='" . $_POST['StockLocation'] . "' + ORDER BY workorders.wo, + woitems.stockid"; + } else { + $SQL = "SELECT workorders.wo, + woitems.stockid, + stockmaster.description, + stockmaster.decimalplaces, + woitems.qtyreqd, + woitems.qtyrecd, + workorders.requiredby, + workorders.startdate + FROM workorders + INNER JOIN woitems ON workorders.wo=woitems.wo + INNER JOIN locationusers ON locationusers.loccode=workorders.loccode AND locationusers.userid='" . $_SESSION['UserID'] . "' AND locationusers.canview=1 + INNER JOIN stockmaster ON woitems.stockid=stockmaster.stockid + WHERE 1 " . $ClosedOrOpen . $StartDateFrom . $StartDateTo ." + AND workorders.loccode='" . $_POST['StockLocation'] . "' + ORDER BY workorders.wo, + woitems.stockid"; + } + } //end not order number selected + + $ErrMsg = _('No works orders were returned by the SQL because'); + $WorkOrdersResult = DB_query($SQL,$db,$ErrMsg); + + /*show a table of the orders returned by the SQL */ + if (DB_num_rows($WorkOrdersResult)>0) { + echo '<br /> + <form action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post" id="wos"> + <input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" /> + <table cellpadding="2" width="95%" class="selection"> + <tr> + <th>' . _('Select') . '</th> + <th>' . _('Modify') . '</th> + <th class="ascending">' . _('Status') . '</th> + <th>' . _('Issue To') . '</th> + <th>' . _('Receive') . '</th> + <th>' . _('Costing') . '</th> + <th>' . _('Paperwork') . '</th> + <th class="ascending">' . _('Item') . '</th> + <th class="ascending">' . _('Quantity Required') . '</th> + <th class="ascending">' . _('Quantity Received') . '</th> + <th class="ascending">' . _('Quantity Outstanding') . '</th> + <th class="ascending">' . _('Start Date') . '</th> + <th class="ascending">' . _('Required Date') . '</th> + </tr>'; + + $k=0; //row colour counter + while ($myrow=DB_fetch_array($WorkOrdersResult)) { + + if ($k==1){ + echo '<tr class="EvenTableRows">'; + $k=0; + } else { + echo '<tr class="OddTableRows">'; + $k++; + } + + $ModifyPage = $RootPath . '/WorkOrderEntry.php?WO=' . $myrow['wo']; + $Status_WO = $RootPath . '/WorkOrderStatus.php?WO=' .$myrow['wo'] . '&StockID=' . $myrow['stockid']; + $Receive_WO = $RootPath . '/WorkOrderReceive.php?WO=' .$myrow['wo'] . '&StockID=' . $myrow['stockid']; + $Issue_WO = $RootPath . '/WorkOrderIssue.php?WO=' .$myrow['wo'] . '&StockID=' . $myrow['stockid']; + $Costing_WO =$RootPath . '/WorkOrderCosting.php?WO=' .$myrow['wo']; + $Printing_WO =$RootPath . '/PDFWOPrint.php?WO=' .$myrow['wo'] . '&StockID=' . $myrow['stockid']; + + $FormatedRequiredByDate = ConvertSQLDate($myrow['requiredby']); + $FormatedStartDate = ConvertSQLDate($myrow['startdate']); + + + printf('<td><input type="checkbox" name="WO_%s" /></td> + <td><a href="%s">%s</a></td> + <td><a href="%s">' . _('Status') . '</a></td> + <td><a href="%s">' . _('Issue To') . '</a></td> + <td><a href="%s">' . _('Receive') . '</a></td> + <td><a href="%s">' . _('Costing') . '</a></td> + <td><a href="%s">' . _('Print W/O') . '</a></td> + <td>%s - %s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td class="number">%s</td> + <td>%s</td> + <td>%s</td> + </tr>', + $myrow['wo'], + $ModifyPage, + $myrow['wo'], + $Status_WO, + $Issue_WO, + $Receive_WO, + $Costing_WO, + $Printing_WO, + $myrow['stockid'], + $myrow['description'], + locale_number_format($myrow['qtyreqd'],$myrow['decimalplaces']), + locale_number_format($myrow['qtyrecd'],$myrow['decimalplaces']), + locale_number_format($myrow['qtyreqd']-$myrow['qtyrecd'],$myrow['decimalplaces']), + $FormatedStartDate, + $FormatedRequiredByDate); + //end of page full new headings if + } + //end of while loop + + echo '</table> + <div class="center"> + <input type="submit" value="' . _('Submit') . '" name="Submit" /> + </form>'; + } + } + + echo '</div> + </form>'; +} + +include('includes/footer.inc'); +?> Modified: trunk/includes/MainMenuLinksArray.php =================================================================== --- trunk/includes/MainMenuLinksArray.php 2015-12-09 07:54:12 UTC (rev 7408) +++ trunk/includes/MainMenuLinksArray.php 2015-12-10 09:34:34 UTC (rev 7409) @@ -309,7 +309,8 @@ _('MRP Reschedules Required'), _('Print Product Specification'), _('Print Certificate of Analysis'), - _('Historical QA Test Results')); + _('Historical QA Test Results'), + _('Multiple Work Orders Total Cost Inquiry')); $MenuItems['manuf']['Reports']['URL'] = array( '/SelectWorkOrder.php', '/BOMInquiry.php', @@ -327,7 +328,8 @@ '/MRPReschedules.php', '/PDFProdSpec.php', '/PDFCOA.php', - '/HistoricalTestResults.php'); + '/HistoricalTestResults.php', + '/CollectiveWorkOrderCost.php'); $MenuItems['manuf']['Maintenance']['Caption'] = array( _('Work Centre'), _('Bills Of Material'), Modified: trunk/sql/mysql/upgrade4.12.3-4.13.sql =================================================================== --- trunk/sql/mysql/upgrade4.12.3-4.13.sql 2015-12-09 07:54:12 UTC (rev 7408) +++ trunk/sql/mysql/upgrade4.12.3-4.13.sql 2015-12-10 09:34:34 UTC (rev 7409) @@ -48,6 +48,7 @@ ALTER table stockrequest DROP FOREIGN KEY `stockrequest_ibfk_3`; ALTER table stockrequest DROP FOREIGN KEY `stockrequest_ibfk_4`; +INSERT INTO scripts VALUES('CollectiveWorkOrderCost.php',2,'Multiple work orders cost review'); -- Update version number: |
From: <ex...@us...> - 2015-12-09 07:54:14
|
Revision: 7408 http://sourceforge.net/p/web-erp/reponame/7408 Author: exsonqu Date: 2015-12-09 07:54:12 +0000 (Wed, 09 Dec 2015) Log Message: ----------- Modified Paths: -------------- trunk/doc/Change.log Modified: trunk/doc/Change.log =================================================================== --- trunk/doc/Change.log 2015-12-09 07:53:30 UTC (rev 7407) +++ trunk/doc/Change.log 2015-12-09 07:54:12 UTC (rev 7408) @@ -1,4 +1,6 @@ webERP Change Log + +09/12/05 Exson: Fixed the telephone regular expression bug in SelectCustomer.php. Reported by Terry. 01/12/15 Exson: Remove the wrong foreign key in suppinvstogrn. Reported by rafael. 26/11/15 Exson: Fixed the rounding error caused extra lines on WO pdf file and 2 number display without locale format in PDFWOPrint.php. 21/11/15 Gilberto Dos Santos Alves: Updated Portuguese Brazilian translation |
From: <ex...@us...> - 2015-12-09 07:53:33
|
Revision: 7407 http://sourceforge.net/p/web-erp/reponame/7407 Author: exsonqu Date: 2015-12-09 07:53:30 +0000 (Wed, 09 Dec 2015) Log Message: ----------- 09/12/05 Exson: Fixed the telephone regular expression bug in SelectCustomer.php. Reported by Terry. Modified Paths: -------------- trunk/SelectCustomer.php Modified: trunk/SelectCustomer.php =================================================================== --- trunk/SelectCustomer.php 2015-12-01 15:08:45 UTC (rev 7406) +++ trunk/SelectCustomer.php 2015-12-09 07:53:30 UTC (rev 7407) @@ -289,7 +289,7 @@ if (isset($_POST['CustPhone'])) { echo '<input type="tel" name="CustPhone" pattern="[0-9\-\s()+]*" value="' . $_POST['CustPhone'] . '" size="15" maxlength="18" />'; } else { - echo '<input type="tel" name="CustPhone" pattern="[0-9\-\s()+]* "size="15" maxlength="18" />'; + echo '<input type="tel" name="CustPhone" pattern="[0-9\-\s()+]*" size="15" maxlength="18" />'; } echo '</td>'; echo '<td><b>' . _('OR') . '</b></td> |
From: <rc...@us...> - 2015-12-01 15:08:48
|
Revision: 7406 http://sourceforge.net/p/web-erp/reponame/7406 Author: rchacon Date: 2015-12-01 15:08:45 +0000 (Tue, 01 Dec 2015) Log Message: ----------- Minor changes: regroup MySql commands. Modified Paths: -------------- trunk/sql/mysql/upgrade4.12.3-4.13.sql Modified: trunk/sql/mysql/upgrade4.12.3-4.13.sql =================================================================== --- trunk/sql/mysql/upgrade4.12.3-4.13.sql 2015-11-30 22:52:00 UTC (rev 7405) +++ trunk/sql/mysql/upgrade4.12.3-4.13.sql 2015-12-01 15:08:45 UTC (rev 7406) @@ -1,4 +1,4 @@ -CREATE TABLE `loctransfercancellations` ( +CREATE TABLE IF NOT EXISTS `loctransfercancellations` ( `reference` INT(11) NOT NULL , `stockid` VARCHAR(20) NOT NULL , `cancelqty` DOUBLE NOT NULL , @@ -10,20 +10,21 @@ -- Add new scripts: INSERT INTO `scripts` (`script`, `pagesecurity`, `description`) VALUES ('AnalysisHorizontalIncome.php', '8', 'Shows the horizontal analysis of the statement of comprehensive income'), - ('AnalysisHorizontalPosition.php', '8', 'Shows the horizontal analysis of the statement of financial position'); + ('AnalysisHorizontalPosition.php', '8', 'Shows the horizontal analysis of the statement of financial position'), + ('EmailCustStatements.php','3','Email customer statement to customer'), + ('GLAccountUsers.php', '15', 'Maintenance of users allowed to a GL Account'), + ('SupplierGRNAndInvoiceInquiry.php',5,'Supplier\'s delivery note and grn relationship inquiry'), + ('UserBankAccounts.php', '15', 'Maintains table bankaccountusers (Authorized users to work with a bank account in webERP)') + ('UserGLAccounts.php', '15', 'Maintenance of GL Accounts allowed for a user'); -CREATE TABLE `suppinvstogrn` ( - `suppinv` int(11) NOT NULL, - `grnno` int(11) NOT NULL, +CREATE TABLE IF NOT EXISTS `suppinvstogrn` ( + `suppinv` int(11) NOT NULL, + `grnno` int(11) NOT NULL, PRIMARY KEY (`suppinv`,`grnno`), - KEY `suppinvstogrn_ibfk_2` (`grnno`), - CONSTRAINT `suppinvstogrn_ibfk_1` FOREIGN KEY (`suppinv`) REFERENCES -`supptrans` (`id`), - CONSTRAINT `suppinvstogrn_ibfk_2` FOREIGN KEY (`grnno`) REFERENCES -`grns` (`grnno`) + KEY `suppinvstogrn_ibfk_1` (`grnno`), + CONSTRAINT `suppinvstogrn_ibfk_1` FOREIGN KEY (`grnno`) REFERENCES `grns` (`grnno`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -INSERT INTO scripts VALUES('EmailCustStatements.php','3','Email customer statement to customer'); -INSERT INTO scripts VALUES('SupplierGRNAndInvoiceInquiry.php',5,'Supplier\'s delivery note and grn relationship inquiry'); + ALTER table grns ADD supplierref varchar(30) NOT NULL DEFAULT ''; CREATE TABLE IF NOT EXISTS `glaccountusers` ( @@ -45,14 +46,9 @@ AND chartmaster.accountcode = glaccountusers.accountcode WHERE glaccountusers.userid IS NULL; -INSERT INTO `scripts` (`script`, `pagesecurity`, `description`) VALUES -('GLAccountUsers.php', '15', 'Maintenance of users allowed to a GL Account'), -('UserGLAccounts.php', '15', 'Maintenance of GL Accounts allowed for a user'); ALTER table stockrequest DROP FOREIGN KEY `stockrequest_ibfk_3`; ALTER table stockrequest DROP FOREIGN KEY `stockrequest_ibfk_4`; -INSERT INTO `scripts` (`script`, `pagesecurity`, `description`) VALUES ('UserBankAccounts.php', '15', 'Maintains table bankaccountusers (Authorized users to work with a bank account in webERP)'); -ALTER table suppinvstogrn DROP FOREIGN KEY `suppinvstogrn_ibfk_1`; -- Update version number: UPDATE config SET confvalue='4.13' WHERE confname='VersionNumber'; |