stock wrong help text

Bug #890193 reported by Ferdinand
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Wishlist
OpenERP R&D Addons Team 2

Bug Description

IMHO the help text is wrong for both accounts
in must match in and out must match out

stock/stock.py

        'valuation_in_account_id': fields.many2one('account.account', 'Stock Input Account',domain = [('type','=','other')], help='This account will be used to value stock moves that have this location as destination, instead of the stock output account from the product.'),
        'valuation_out_account_id': fields.many2one('account.account', 'Stock Output Account',domain = [('type','=','other')], help='This account will be used to value stock moves that have this location as source, instead of the stock input account from the product.'),

Related branches

Amit Parik (amit-parik)
Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 2 (openerp-dev-addons2)
importance: Undecided → Low
status: New → Confirmed
Revision history for this message
Kirti Savalia(OpenERP) (ksa-openerp) wrote :

Hello,

IMHO the help text for both account
stock input account is used when goods come to the stock location.It is incoming ,so stock move would have this location as destination.
as same way for stock output account,we use this account against our customer, for that sending goods to them using this location,so in stock move this location will be used as source.
Can you please share your views ?
Thanks and waiting for your reply!

Revision history for this message
Ferdinand (office-chricar) wrote :

I printed the words to change in capitals

        'valuation_in_account_id': fields.many2one('account.account', 'Stock Input Account',domain = [('type','=','other')], help='This account will be used to value stock moves that have this location as destination, instead of the stock INPUT account from the product.'),
        'valuation_out_account_id': fields.many2one('account.account', 'Stock Output Account',domain = [('type','=','other')], help='This account will be used to value stock moves that have this location as source, instead of the stock OUTPUT account from the product.'),

Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
Kirti Savalia(OpenERP) (ksa-openerp) wrote :

Hello,

Thanks For Your Suggestion.
It has been Fixed in http://bazaar.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-890193-ksa
revision-id: <email address hidden>
revno: 5686
It will be available in trunk soon.

Thanks.

Changed in openobject-addons:
status: In Progress → Fix Committed
Changed in openobject-addons:
status: Fix Committed → Confirmed
Revision history for this message
Kirti Savalia(OpenERP) (ksa-openerp) wrote :

Hello,

If there is an input valuation account on a location used as destination of a stock move, it means the stock move is incoming into that lcoation. and we must replace the output account from the product by this one.
As the same way for output valuation account on a location used as a source of a stock move,it means the stock move is sending the goods into that location.so we must replace the input account form the product by this one.
I hope now this is clear to you.

Thanks.

Changed in openobject-addons:
status: Confirmed → Invalid
Revision history for this message
Ferdinand (office-chricar) wrote :

thanks, but sorry I do not agree (yet)

product_template:
        'property_stock_account_input': fields.property('account.account',
            type='many2one', relation='account.account',
            string='Stock Input Account', view_load=True,
            help='When doing real-time inventory valuation, counterpart Journal Items for all incoming stock moves will be posted in this account. If not set on the product, the one from the product category is used.'),

product_category
        'property_stock_account_input_categ': fields.property('account.account',
            type='many2one', relation='account.account',
            string='Stock Input Account', view_load=True,
            help='When doing real-time inventory valuation, counterpart Journal Items for all incoming stock moves will be posted in this account. This is the default value for all products in this category, it can also directly be set on each product.'),

        'valuation':fields.selection([('manual_periodic', 'Periodical (manual)'),
                                        ('real_time','Real Time (automated)'),], 'Inventory Valuation',
                                        help="If real-time valuation is enabled for a product, the system will automatically write journal entries corresponding to stock moves." \
                                             "The inventory variation account set on the product category will represent the current inventory value, and the stock input and stock output account will hold the counterpart moves for incoming and outgoing products."
                                        , required=True),

stock_location
        'valuation_in_account_id': fields.many2one('account.account', 'Stock Input Account',domain = [('type','=','other')], help='This account will be used to value stock moves that have this location as destination, instead of the stock output account from the product.'),

the following account move should be created in real time accounting
receipt:
debit: valuation
credit: valuation_in_account_id or property_stock_account_input or property_stock_account_input_categ
invoice
debit: valuation_in_account_id or property_stock_account_input or property_stock_account_input_categ
credit: "Account Payable" from partner

I do not see a good reason of using the valuation_out_account_id instead of valuation_in_account_id especially as the label
"Stock Input Account"
indicates the same purpose for all 3 fields.

the definition of the valuation_in_account_id seems to be there only to allow separate treatment of incoming goods for each stock_location whereas the valuation is again defined for the product category.

IMHO in any case the help text for product and prod category must be modified to describe, that the account is in any case overwritten by 'valuation_in/out_account_id' of stock_location.

Changed in openobject-addons:
status: Invalid → New
Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

> I do not see a good reason of using the valuation_out_account_id instead of
> valuation_in_account_id especially as the label "Stock Input Account"
> indicates the same purpose for all 3 fields.

Here is the reason: these fields are in fact the exact opposite of the "Stock output account"/"Stock input account" on a product, as Kirti tried to explain. Perhaps they should better be named "Stock Valuation Account (Incoming)" and "Stock Valuation Account (Outgoing)", and have a better tooltip explaining that they represent specific Stock Valuation Accounts to use for *virtual* locations only. This would indeed avoid confusion due to similar labels.

More details:

The addition of these fields is a modified replacement of the unique "account_id" from v5 which was the equivalent of the new "property_stock_valuation_account_id" that is located on the product category. We had a request to be able to specify a different valuation account for incoming and outgoing moves, typically in order to have separate "Inventory Loss" and "Inventory Recovery" accounts (-> bug 697273)

As of 6.0. any move that makes goods enter or exit the company can trigger a valuation move that does the following:
- For incoming: debit/increase the valuation account, credit/decrease the counterpart account (Stock Input Account)
- For outgoing: credit/decrease the valuation account, debit/increase the counterpart account (Stock Output Account)
(For internal moves: no valuation entry)

Taking an example of inventory loss event, we expect to see the following valuation moves:

1. Without any counterpart account set on the locations
-------------------------------------------------------
STOCK MOVE:
Internal Location | Inventory Loss Location
   -2 PCE | +2 PCE

ACCOUNT MOVE:
 Valuation Acct | Stock Output Acct
  Credit 2*cost | Debit 2*cost

2. With an "Inventory Loss Acct" set as "valuation_in_account_id" on "Inventory Loss" location
-------------------------------------------------------------------------------------------------
STOCK MOVE:
Internal Location | Inventory Loss Location
   -2 PCE | +2 PCE

ACCOUNT MOVE:
 Valuation Acct | Inventory Loss Acct
  Credit 2*cost | Debit 2*cost

As we can see the "valuation_in_account_id" property represents the equivalent of a "Stock Valuation Account" that would hold the value of the "Inventory Loss" location, and would thus increase (be debited) when new goods come INTO the Inventory Loss location.
So yes, it will replace the generic "Stock output account", but it derives from a *specific INPUT* rule, rather than a *generic OUTPUT* rule. A "Stock Output Account" is a *generic* counterpart for goods *leaving* the company, while "valuation_in_account_id" is a *specific* valuation account for a given virtual location receiving *incoming* goods.

The code logic seem correct to me, and the technical name of the column as well. But we need to find a better label and tooltip to avoid confusion.

Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

The labels and tooltips were improved in addons revision 5837 revid: <email address hidden>, hopefully making this less confusing for new users.

Thanks,

Changed in openobject-addons:
importance: Low → Wishlist
milestone: none → 6.1
status: New → Fix Released
Revision history for this message
Ferdinand (office-chricar) wrote :

thanks for the explanation,

IMHO in this case the group "Accounting Information" should be invisible for all other usage types.

Revision history for this message
Ferdinand (office-chricar) wrote :

in stock.py
        'property_stock_account_input': fields.property('account.account',
            type='many2one', relation='account.account',
            string='Stock Input Account', view_load=True,
            help="When doing real-time inventory valuation, counterpart journal items for all incoming stock moves will be posted in this account, unless "
                 "there is a specific valuation account set on the source location. When not set on the product, the one from the product category is used."),

we just learned that the valuation accounts are only used for virtual locations - it probably should be mentioned here too
... specific valuation account set on the VIRTUAL source location (PRODUCTION,INVENTORY)....

In German we have distinct names for all these accounts.
see also http://www.principlesofaccounting.com/
Asset accounts
* stock valuation account (Lagerbestandskonto) - which holds the value of the products, ONLY defined in product category
* picking in/out valuation (Bewertete Eingangs/Ausgangs Lieferscheine) - which is the counter account to all stock moves which are invoiced - these are TRANSIT accounts
P&L
* Cost of goods (Warenverbrauch) - value of products used in production
* cost of goods sold - Inventory Change (Bestandsveränderung)
** value of produced products (IN)
** value of sold products (OUT)
* inventory difference (Inventurdifferenzkonto) - value of inventory differences (BTW which can not be posted currently in stock moves if it's value only correction)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.