webERP Forum

Full Version: Doubts on "Internal Stock"
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Hi, Tim,

Thank you very much!

We've tested the scripts and I think your design is right. The accountant has no time to handle those request each time. It should be warehouse staff's job.

I think even consumable also should be post to different GL. For instance, some of them issued to manufacture dept and others to accountant dept. We think the solution should be that accountant manually transfer them to the right account at month end. Is it right?

Best regards!

Exson
Thanks Tim:

I see your point about a new type of stock. But just a flag (Y/N) to use some categories as "internal" could do the job. Could be left by default to Yes, so could work as your original design, and some users (me for sure) could flag some as N, so warehouse staff can't use them.

I agree the average warehouse people is not like the average accountant or office staff. That's exactly why they should NOT have access to move certain stock categories. In our particular business (jewellery retail), we really don't care much if one shop is spending too much consumables (pens, wrapping paper, etc) but we do care if warehouse people can access to pearl or silver jewellery stock and treat it as a consumable. We could grant them access to some stockcategories but not others (to prevent expensive stock suddently disappearing)...

If it's OK I could code this (I think it's easy enough I can handle it ;-)


What about a value threshold - this maybe more generically applicable. You may care if your warehouse people consume $30k worth of pens?

If you wish to do it by a flag then think it may be preferable to make a new field up instead of using a field which already has a specific purpose.
e.g. it is possible to have a stock category that is finished goods and should also be restricted to a certain role. Perhaps a comma separated list of roles that have authority to issue?
Hi Tim:

Yes, being able to filter stock categories by users is even more flexible, so for me OK. Only I was thinking, should be by userid or roleid? I think should be role...

Being more work, well I think not so much more, just a table containing roleid(or userid) and stockcategoryid, and doing the selection with a join on this table.

For this function (and some other issues still active on the forum like http://www.weberp.org/forum/showthread.php?tid=31) I'm open to sponsor it ;-), just PM me if interested.
Hi Tim:

I'm coding the restriction of stock categories by user role and modifying the InternalStockRequest.php some doubts arise:

1) Why the user needs to select his department? Isn't it better to have it set up on www-users table? Seems like webERP should know which is the department the user is working at, no need to re question it, right? Or is there any other idea below the surface I can't see?

2) "location from which to request stock" should be also limited? Some locations are probably not intended to dispatch internal requests (retail shops) but some others are (like location Warehouse, or storage room). Could we use a flag (YES/NO) on location table to indicate if the location can or can't receive internal requests?

Thanks
Hi Tim:

Already coded and commited the location flag. Please test and let me know if everything is OK.

Regarding the department, we could leave it as is now, as defaulting it will not prevent user doing requests from not allowed departments. i will think more about it, see if there is another option available...

many thanks!
Hi Tim:

Testing InternalStockRequestFulfill.php I think it accounts with wrong signs.

Created item CS01, standard cost 1.000 qty = 50.

So Value stock should be 50.000
Then created, authorized and fulfilled a request for 10 of these items to one department.
Value stock should be 40.000 if I understood OK.

But after checking the account its value is 60.000. Please check attached files.

I think lines 125 and 147 should change the sign.

Hi Tim:

Already checked and seems OK. I made some small improvments to narrative to betetr identify the tx later on. What I could not get is how to identify the Department when he $Narrative is created. How can I get it? Where is it stored?

Thanks.
(07-13-2012, 04:59 PM)tim_schofield Wrote: [ -> ]Regarding the department I tried to visualise whether there could be organisations where a user might requisition internal requests for more than one department, and decided that could be the case. Would a good compromise be to have that set in www_users and then have the drop down list default to that department?
Hi Tim:

What about a field internaldepartment in www_users that could be set to the department to allow the user ONLY 1 department or set to "Any" to allow the user to create internal request for any department?

I think it satisfies both approaches, and quite easy to code.

Is this idea OK for your requirements?
Would be nice to write up what we have here and how it all works?

Maybe under the stock adjustment section of the manual
Pages: 1 2 3