|
From: <dai...@us...> - 2012-08-20 09:21:50
|
Revision: 5603
http://web-erp.svn.sourceforge.net/web-erp/?rev=5603&view=rev
Author: daintree
Date: 2012-08-20 09:21:43 +0000 (Mon, 20 Aug 2012)
Log Message:
-----------
added barcode entry of stock counts
Modified Paths:
--------------
trunk/CounterSales.php
trunk/SelectOrderItems.php
trunk/StockCounts.php
trunk/doc/Change.log
Modified: trunk/CounterSales.php
===================================================================
--- trunk/CounterSales.php 2012-08-19 07:04:01 UTC (rev 5602)
+++ trunk/CounterSales.php 2012-08-20 09:21:43 UTC (rev 5603)
@@ -244,7 +244,7 @@
stockmaster.decimalplaces
FROM stockmaster INNER JOIN stockcategory
ON stockmaster.categoryid=stockcategory.categoryid
- WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D')
+ WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D' OR stockcategory.stocktype='L')
AND stockmaster.mbflag <>'G'
AND stockmaster.controlled <> 1
AND stockmaster.description " . LIKE . " '" . $SearchString . "'
@@ -257,7 +257,7 @@
stockmaster.decimalplaces
FROM stockmaster INNER JOIN stockcategory
ON stockmaster.categoryid=stockcategory.categoryid
- WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D')
+ WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D' OR stockcategory.stocktype='L')
AND stockmaster.mbflag <>'G'
AND stockmaster.controlled <> 1
AND stockmaster.discontinued=0
@@ -278,7 +278,7 @@
stockmaster.decimalplaces
FROM stockmaster INNER JOIN stockcategory
ON stockmaster.categoryid=stockcategory.categoryid
- WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D')
+ WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D' OR stockcategory.stocktype='L')
AND stockmaster.stockid " . LIKE . " '" . $SearchString . "'
AND stockmaster.mbflag <>'G'
AND stockmaster.controlled <> 1
@@ -291,7 +291,7 @@
stockmaster.decimalplaces
FROM stockmaster INNER JOIN stockcategory
ON stockmaster.categoryid=stockcategory.categoryid
- AND (stockcategory.stocktype='F' OR stockcategory.stocktype='D')
+ AND (stockcategory.stocktype='F' OR stockcategory.stocktype='D' OR stockcategory.stocktype='L')
AND stockmaster.stockid " . LIKE . " '" . $SearchString . "'
AND stockmaster.mbflag <>'G'
AND stockmaster.controlled <> 1
@@ -308,7 +308,7 @@
stockmaster.decimalplaces
FROM stockmaster INNER JOIN stockcategory
ON stockmaster.categoryid=stockcategory.categoryid
- WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D')
+ WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D' OR stockcategory.stocktype='L')
AND stockmaster.mbflag <>'G'
AND stockmaster.controlled <> 1
AND stockmaster.discontinued=0
@@ -320,7 +320,7 @@
stockmaster.decimalplaces
FROM stockmaster INNER JOIN stockcategory
ON stockmaster.categoryid=stockcategory.categoryid
- WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D')
+ WHERE (stockcategory.stocktype='F' OR stockcategory.stocktype='D' OR stockcategory.stocktype='L')
AND stockmaster.mbflag <>'G'
AND stockmaster.controlled <> 1
AND stockmaster.discontinued=0
Modified: trunk/SelectOrderItems.php
===================================================================
--- trunk/SelectOrderItems.php 2012-08-19 07:04:01 UTC (rev 5602)
+++ trunk/SelectOrderItems.php 2012-08-20 09:21:43 UTC (rev 5603)
@@ -858,7 +858,6 @@
if (DB_num_rows($SearchResult)<$_SESSION['DisplayRecordsMax']){
$Offset=0;
}
-
} //end of if search
#Always do the stuff below if not looking for a customerid
Modified: trunk/StockCounts.php
===================================================================
--- trunk/StockCounts.php 2012-08-19 07:04:01 UTC (rev 5602)
+++ trunk/StockCounts.php 2012-08-20 09:21:43 UTC (rev 5603)
@@ -29,9 +29,9 @@
echo '<table class="selection"><tr>';
if ($_GET['Action']=='View'){
- echo '<td><a href="' . $rootpath . '/StockCounts.php?' . SID . '&Action=Enter">' . _('Resuming Entering Counts') . '</a> </td><td>' . _('Viewing Entered Counts') . '</td>';
+ echo '<td><a href="' . $rootpath . '/StockCounts.php?&Action=Enter">' . _('Resuming Entering Counts') . '</a> </td><td>' . _('Viewing Entered Counts') . '</td>';
} else {
- echo '<td>'._('Entering Counts') .'</td><td> <a href="' . $rootpath . '/StockCounts.php?' . SID . '&Action=View">' . _('View Entered Counts') . '</a></td>';
+ echo '<td>'._('Entering Counts') .'</td><td> <a href="' . $rootpath . '/StockCounts.php?&Action=View">' . _('View Entered Counts') . '</a></td>';
}
echo '</tr></table><br />';
@@ -44,8 +44,22 @@
$InputError =False; //always assume the best to start with
$Quantity = 'Qty_' . $i;
+ $BarCode = 'BarCode_' . $i;
$StockID = 'StockID_' . $i;
$Reference = 'Ref_' . $i;
+
+ if (strlen($_POST[$BarCode])>0){
+ $sql = "SELECT stockmaster.stockid
+ FROM stockmaster
+ WHERE stockmaster.barcode='". $_POST[$BarCode] ."'";
+
+ $ErrMsg = _('Could not determine if the part being ordered was a kitset or not because');
+ $DbgMsg = _('The sql that was used to determine if the part being ordered was a kitset or not was ');
+ $KitResult = DB_query($sql, $db,$ErrMsg,$DbgMsg);
+ $myrow=DB_fetch_array($KitResult);
+
+ $_POST[$StockID] = strtoupper($myrow['stockid']);
+ }
if (mb_strlen($_POST[$StockID])>0){
if (!is_numeric($_POST[$Quantity])){
@@ -94,21 +108,29 @@
}
}
echo '</select></th></tr>';
- echo "<tr>
- <th>" . _('Stock Code') . "</th>
- <th>" . _('Quantity') . "</th>
- <th>" . _('Reference') . '</th></tr>';
+ echo '<tr>
+ <th>' . _('Bar Code') . '</th>
+ <th>' . _('Stock Code') . '</th>
+ <th>' . _('Quantity') . '</th>
+ <th>' . _('Reference') . '</th>
+ </tr>';
for ($i=1;$i<=10;$i++){
echo '<tr>
- <td><input type="text" name="StockID_' . $i . '" maxlength="20" size="20" /></td>
- <td><input type="text" name="Qty_' . $i . '" maxlength="10" size="10" /></td>
- <td><input type="text" name="Ref_' . $i . '" maxlength="20" size="20" /></td></tr>';
+ <td><input type="text" name="BarCode_' . $i . '" maxlength="20" size="20" /></td>
+ <td><input type="text" name="StockID_' . $i . '" maxlength="20" size="20" /></td>
+ <td><input type="text" name="Qty_' . $i . '" maxlength="10" size="10" /></td>
+ <td><input type="text" name="Ref_' . $i . '" maxlength="20" size="20" /></td>
+ </tr>';
}
- echo '</table><br /><div class="centre"><input type="submit" name="EnterCounts" value="' . _('Enter Above Counts') . '" /></div>';
+ echo '</table>
+ <br />
+ <div class="centre">
+ <input type="submit" name="EnterCounts" value="' . _('Enter Above Counts') . '" />
+ </div>';
//END OF action=ENTER
} elseif ($_GET['Action']=='View'){
Modified: trunk/doc/Change.log
===================================================================
--- trunk/doc/Change.log 2012-08-19 07:04:01 UTC (rev 5602)
+++ trunk/doc/Change.log 2012-08-20 09:21:43 UTC (rev 5603)
@@ -1,4 +1,7 @@
webERP Change Log
+
+20/8/2012 Phil: StockCounts.php now allows entry Bar Codes or stock codes
+20/8/2012 Phil: Now allow labour type category items to be selected searched for in CounterSales.php and SelectOrderItems.php
30/7/2012 Exson: fixed that the shipper will change sometime when modify the PO by modify file PO_ReadInOrder.inc. Reported by Craig.
29/7/2012 Phil: install/save.php now uses date_default_timezone_set function to set the time-zone to avoid all the nasty warnings
29/7/2012 Hindra Joshua: Updates to Professional and Professional-rtl themes - tidy up images not used
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|