This is a serious upgrade to the currently available "Low Stock Report" module for osCommerce application. The simple version of "Stock Control Report" is almost useless as it doesn't allow redirection to the "edit mode" in order to update stock or edit/delete/move/copy any particular product.
Apart from a basic list of Products with stock levels below a marginal level defined in Configuration/Stock/Stock-Reorder-Level this "extra" version is tested on osCommerce2.2 MS1.
Extra features:
- Ascending or Descending order based on either Product Name or Quantity.
- Redirection to edit mode for any product so you can:
- Update stock levels or edit/delete/move/copy any particular product.
Legend: 
Download

Report
This is a fix for the sql error. if it cant be determined it will skip over the looped query and go onto the next.
This is is not a full package. Replace stats_low_stock.php in your admin directory.
Getting a syntax error when the quantity available is equal or less than 0:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
select parent_id from categories where categories_id =
[TEP STOP]
Sorry, download this one instead.
Included Portuguese language pack.
Repacked full contribution in order to correct the following error in some servers:
Parse error: parse error, unexpected T_REQUIRE in /****/****/*****/*****/catalog/admin/stats_low_stock.php on line 1
This error was caused probably by the software used to edit them, which did not include line breaks, so the files read in one single line.
Thanks to Julie Williams for posting this in the forum.
But I'm still getting a sintax error when the quantity available is equal or less than 0:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
select parent_id from categories where categories_id =
[TEP STOP]
I hope someone can update this nice contribution and fix this error.
Thanks to all that helped.
Repacked full contribution in order to correct the following error in some servers:
Parse error: parse error, unexpected T_REQUIRE in /****/****/*****/*****/catalog/admin/stats_low_stock.php on line 1
This error was caused probably by the software used to edit them, which did not include line breaks, so the files read in one single line.
Thanks to Julie Williams for posting this in the forum.
But I'm still getting a sintax error when the quantity available is equal or less than 0:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
select parent_id from categories where categories_id =
[TEP STOP]
I hope someone can update this nice contribution and fix this error.
Thanks to all that helped.
My first contrib. The idea is to show whether a certain product is part of a bundle and to produce a direct link to that product within the bundle. I hope this helps someone. This is just a single text file so download the full contribution first. I did this in like 5 minutes so remember to backup :)
Re-Coded and updated Version. Works with MS2 now, includes updated German translation, various serious fixes. Hope it helps anyone + there is more code in it to be tidied up.
this is very usefull contrib. Many thanks for delelopers.
When listing, I realized that report shows disabled products, too
If you don't wanna get listed the disabled products just replace the product query at line 115 with following
--------------------------------------
$products_query_raw = "select p.products_id, p.products_quantity, pd.products_name, p.products_model from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = pd.products_id and pd.language_id = '" . $languages_id. "' and p.products_quantity <= " . STOCK_REORDER_LEVEL . " group by pd.products_id order by $db_orderby $sorted";
Full Version
- Reapplied 0 division error fix, apparently some people were still having a problem with this in 2.01
- Fixed the incorrect stock and 60 days estimate caused by the change of the year.
- Added a new feature that filters out items that have more than 60 days stock and have inventory > 0.
QUESTIONS / ANSWERS
FORUM: http://forums.oscommerce.com/index.php?showtopic=164523
UPDATED:
- Update to code fixing 0 division error - Thanks Huey_AU.
- After further research basing your estimated days stock is much more accurate if using 60 days data
instead of 30 days unless you are doing 500+ orders a month. So now it calculates sales in last 60
days and estimated stock off the last 60 days. > 20 days stock is displayed in red now.
- Now displays qty < 0 in stock as red because that means people have backorders!
Full Version Attached
Quick query fix
Full Version attached.
QUESTIONS / ANSWERS
FORUM: http://forums.oscommerce.com/index.php?showtopic=164523
WHATS NEW IN 2.0?
-------------------------
NEW FEATURES:
* It now shows you your sales on this item in the last 30 days so you can
really know if this item is really selling or not
* Estimated days stock, this is based off of the last 30 days of your sales,
if you have 0 in stock it will display NA in red, if you have 15 days or
less it will display the days in red, if you have no sales but stock it
will display +30 Days. Pretty niffty ehh? Much more accurate.
NOTE: It will only display items that need restocked that are at or below your restock level set
in admin -> Stock, regardless of how many estimated days stock you have. This is because it has
to execute a DB query for every item it estimates days of stock for so this is a way of limiting
the queries to the most relevant items (item below restock levels). Maybe someone can further
optimize my queries if they know how...
UPGRADERS FROM v1.x
-------------------------
Just overwrite
/admin/stats_low_stock.php
/admin/includes/languages/english/stats_low_stock.php (sorry only english trans I don't speak other languages, but easy only 3 language lines to change for other languages.)
-------------------------
French translastion now included in this package
Traduction française include dans ce package
Minor tweak to the 'next page' function to retain sort preferences from page to page.
1) added master products functionality
2) changed the max number of listing function
NOTE: Only use this version if you have "master produts contribution" installed.
v1.15 - 2004/11/09 Aaron Hiatt
http://www.scaredrabbit.com
Cleaned up and recoded parts of the low stock page in admin to conform to osCommerce standards and provide extra functionality. This is the full package.
If I click on model in the version Low Stock 1.12 it will be still ordered by products_name in MY 2.2MS2 Version. This is a small change to admin/stats_low_stock.php. Model is the secons row now and the products are ordered by model.
Only replace this file.
v1.12 - 2004/04/01 R Woodgate
Improved report links:
1) Default row link now goes straight to Edit Product
2) Model Link now passes category correctly
Fixed step 5 of install instructions to follow OSC conventions
Added missing Model define into German and Spanish language files
I added in a column to show and sort by the Product Model. This make reordering inventory easier.
This is a serious upgrade to the currently available "Low Stock Report" module for osCommerce application. The simple version of "Stock Control Report" is almost useless as it doesn't allow redirection to the "edit mode" in order to update stock or edit/delete/move/copy any particular product.
Apart from a basic list of Products with stock levels below a marginal level defined in Configuration/Stock/Stock-Reorder-Level this "extra" version is tested on osCommerce2.2 MS1.
Extra features:
- Ascending or Descending order based on either Product Name or Quantity.
- Redirection to edit mode for any product so you can:
- Update stock levels or edit/delete/move/copy any particular product.