Vauxoo / addons-vauxoo

All our modules related to developments that solves generic issues on Odoo, or that solve internal problems on Odoo Core, if something is here, maybe it is solving an issue in your company, try it and report what you see.
http://www.vauxoo.com
193 stars 288 forks source link

[FIX] stock_manual_transfer: Avoid Unit of Measure validation error without group #1655

Closed allanpa88 closed 4 months ago

allanpa88 commented 4 months ago

A validation error is raised when a user without the "Manage Multiple Units of Measure" access tries to save or validate a manual transfer.

This fix allows any user to create manual transfers, but only users with "Units of Measure" access can modify this attribute on the lines.

This is the answer to the request suggested by German here: https://github.com/Vauxoo/addons-vauxoo/pull/1652#discussion_r1602424134

I think this is a great solution, better than giving the user access.

Here you can see evidence of the function test:

  1. User without group User without group

  2. Without the fix we cannot save or validate the Manual Transfer. 1  Error trying to save without uom permission

  3. With the fix any user could create and modify the lines: validated without permision

allanpa88 commented 4 months ago

Hi @luisg123v could you review this please.

cc: @xmglord