Availability |
Odoo Online
Odoo.sh
On Premise
|
Odoo Apps Dependencies |
•
Discuss (mail)
• Inventory (stock) • Invoicing (account) |
Lines of code | 72 |
Technical Name |
wm_hide_product_cost |
License | OPL-1 |
Versions | 17.0 18.0 |
Hide Product Cost per User
This module enhances Odoo's access control by allowing administrators to selectively hide product cost prices (standard_price) from specific users. By utilizing a dedicated user group, you can ensure that only authorized personnel can view cost information on product and inventory report views, thereby improving data confidentiality and internal controls.
This module introduces a new security group named "View Product Cost". Users who are NOT part of this group will have the 'Cost' field hidden from their view on product templates, product variants,Lot and serial number and inventory reports.
- Installation: Upon installing the module, the "View Product Cost" group is automatically created. By default, all users (except administrator) will not be part of this group, meaning the cost price will be hidden for them.
-
Granting Access: To allow a user to see the product cost, an administrator needs to:
- Enable developer mode.
- Navigate to Settings > Users & Companies > Users.
- Select the desired user.
- Under the "Access Rights" tab (or similar, depending on Odoo version and other modules), find the application section for this module or the "Other Rights" section.
- Check the box for "View Product Cost".
- Save the changes.
Users in this group will see the 'Cost' field on product forms and in product list views.
(Illustrative image: User settings showing the 'View Product Cost' group)
-
Viewing Product Cost (User with Access): A user who is a member of the "View Product Cost" group will see the 'Cost' field as usual in the product template, product variant,Lot and Serial Number and inventory reports views.
(Illustrative image: Product template list view showing the 'Cost' field for an authorized user)
(Illustrative image: Product template form view showing the 'Cost' field for an authorized user)
(Illustrative image: Product variant list view showing the 'Cost' field for an authorized user)
(Illustrative image: Product variant form view showing the 'Cost' field for an authorized user)
(Illustrative image: Product variant easy edit form view showing the 'Cost' field for an authorized user)
(Illustrative image: Lot and Serial Number form view showing the 'Cost' field for an authorized user)
(Illustrative image: Stock report view showing the 'Cost' field for an authorized user)
(Illustrative image: Locations report view showing the 'Cost' field for an authorized user)
(Illustrative image: Valuation report view showing the 'Cost' field for an authorized user)
(Illustrative image: Export wizard showing the 'Cost' field for an authorized user)
-
Cost Hidden (User without Access): A user who is NOT a member of the "View Product Cost" group will not see the 'Cost' field. The field will be entirely hidden from their view on product templates, product variants,Lot and serial number and inventory reports.
(Illustrative image: Product template list view the 'Cost' field hidden for an authorized user)
(Illustrative image: Product template form view the 'Cost' field hidden for an authorized user)
(Illustrative image: Product variant list view the 'Cost' field hidden for an authorized user)
(Illustrative image: Product variant form view the 'Cost' field hidden for an authorized user)
(Illustrative image: Product variant easy edit form view the 'Cost' field hidden for an authorized user)
(Illustrative image: Lot and Serial Number form view the 'Cost' field hidden for an authorized user)
(Illustrative image: Stock report view the 'Cost' field hidden for an authorized user)
(Illustrative image: Locations report view the 'Cost' field hidden for an authorized user)
(Illustrative image: Valuation report view the 'Cost' field hidden for an authorized user)
(Illustrative image: Export wizard with 'Cost' field hidden for an authorized user)
This provides a straightforward way to manage who can see sensitive product cost information within your Odoo system.
Version:1.0.0 Date:15-May-2025
- Initial Code.
Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module