Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Stock adjustment improvement needed
01-15-2013, 05:12 PM,
#1
Stock adjustment improvement needed
Hi all:

In StockAdjustments.php we control the differences between weberp stock and real stock.

Well, several reasons can trigger an stock adjustment and would be great to be able to control so:
- Broken
- Unsellable item
- Stolen
- shrinkage (in case of components)
- expired
- etc...

How can it be controlled? Besides improving StockAdjustments.php to include these reasons, adding a field in stockmoves seems obvious but there are many other stockmoves we do bnot need this detail. Should we create a table for this?


Regards,
Pak Ricard
Reply
01-15-2013, 05:53 PM, (This post was last modified: 01-15-2013, 05:55 PM by phil.)
#2
RE: Stock adjustment improvement needed
Yes I think a stock adjustments reason table would be a nice addition. Ideally also, a table similar to cogsglpostings (perhaps called adjustmentsglpostings) that has fields for:

categoryid,
loccode,
reasonid,
glcode

so the glcode can be derived for different stock category/location/reason combinations.
We could then lose the adjustment gl code from the stockcategories table ... but would need alterations to a number of scripts that use it currently. Cost roll ups, stock checks are two I can think of - would need to grep to be pick up and rework all the scripts necessary
Phil Daintree
webERP Admin
Logic Works Ltd
http://www.logicworks.co.nz
Reply
01-28-2013, 02:20 PM, (This post was last modified: 01-28-2013, 02:28 PM by PakRicard.)
#3
RE: Stock adjustment improvement needed
Hi Phil:

What if we can start with a list of reasons. Currently we have a field "Comments on why" which is really short, so I propose:
1) Turn it into a dropdown with a series of reasons
2) Add a field with the tabulated reasons and enlarge this field to have the extra comments if needed.

I can code any of both. For the proposal on your previous post, it's out of my knowledge and implications, but my proposal could be the first step toward your bigger picture.

Currently, in StockAdjustments.php the "comments on why" is stored on the field reference, instead of narrative (which is also available).

Would it be a sensible change to use reference as the tabulated reason, and narrative as the free text?
Regards,
Pak Ricard
Reply
01-28-2013, 02:45 PM,
#4
RE: Stock adjustment improvement needed
Need to think a bit more ... Off the top of my head - if we add a field to stock moves this creates waste on every other stockmove record - and it's a big table so need to be careful not to bloat by mistake.

Perhaps we add a stockadjustments reasons table that links to the stockmoves table id so we only create records for the stockadjustments - needs to be done for stock checks too.
We also need a new table with the reasons - which will need a new form to define the reasons.

CREATE TABLE stockadjustmentreasons (
reasonid,
reasondescription
);

Then the new table of

CREATE TABLE stockadjustreasonglpostings (
reasonid,
loccode,
categoryid,
accountcode
PRIMARY_KEY(reasonid,loccode,categoryid));

We will also need to create a form for input of these as per COGSGLPostings.php or SalesGLPostings.php
Also a new function in SQL_CommonFunctions.inc to

GetStockAdjustmentGLCode (reasonid, loccode, categoryid)

so we can just modify as little as possible of the existing adjustment/stock check scripts

Sorry logged in as testing - but this is Phil :-)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)