Ir al contenido
Odoo Menú
  • Inicia sesión
  • Pruébalo gratis
  • Aplicaciones
    Finanzas
    • Contabilidad
    • Facturación
    • Gastos
    • Hoja de cálculo (BI)
    • Documentos
    • Firma electrónica
    Ventas
    • CRM
    • Ventas
    • PdV para tiendas
    • PdV para restaurantes
    • Suscripciones
    • Alquiler
    Sitios web
    • Creador de sitios web
    • Comercio electrónico
    • Blog
    • Foro
    • Chat en vivo
    • eLearning
    Cadena de suministro
    • Inventario
    • Manufactura
    • PLM
    • Compras
    • Mantenimiento
    • Calidad
    Recursos humanos
    • Empleados
    • Reclutamiento
    • Vacaciones
    • Evaluaciones
    • Referencias
    • Flotilla
    Marketing
    • Redes sociales
    • Marketing por correo
    • Marketing por SMS
    • Eventos
    • Automatización de marketing
    • Encuestas
    Servicios
    • Proyectos
    • Registro de horas
    • Servicio externo
    • Soporte al cliente
    • Planeación
    • Citas
    Productividad
    • Conversaciones
    • Inteligencia artificial
    • IoT
    • VoIP
    • Artículos
    • WhatsApp
    Aplicaciones externas Studio de Odoo Plataforma de Odoo en la nube
  • Industrias
    Venta minorista
    • Librería
    • Tienda de ropa
    • Mueblería
    • Tienda de abarrotes
    • Ferretería
    • Juguetería
    Alimentos y hospitalidad
    • Bar y pub
    • Restaurante
    • Comida rápida
    • Casa de huéspedes
    • Distribuidora de bebidas
    • Hotel
    Bienes inmuebles
    • Agencia inmobiliaria
    • Estudio de arquitectura
    • Construcción
    • Gestión de propiedades
    • Jardinería
    • Asociación de propietarios
    Consultoría
    • Firma contable
    • Partner de Odoo
    • Agencia de marketing
    • Bufete de abogados
    • Adquisición de talentos
    • Auditorías y certificaciones
    Manufactura
    • Textil
    • Metal
    • Muebles
    • Comida
    • Cervecería
    • Regalos corporativos
    Salud y ejercicio
    • Club deportivo
    • Óptica
    • Gimnasio
    • Especialistas en bienestar
    • Farmacia
    • Peluquería
    Trades
    • Personal de mantenimiento
    • Hardware y soporte de TI
    • Sistemas de energía solar
    • Zapateros y fabricantes de calzado
    • Servicios de limpieza
    • Servicios de calefacción, ventilación y aire acondicionado
    Otros
    • Organización sin fines de lucro
    • Agencia para la protección del medio ambiente
    • Alquiler de anuncios publicitarios
    • Fotografía
    • Alquiler de bicicletas
    • Distribuidor de software
    Descubre todas las industrias
  • Comunidad
    Aprende
    • Tutoriales
    • Documentación
    • Certificaciones
    • Capacitación
    • Blog
    • Podcast
    Fortalece la educación
    • Programa educativo
    • Scale Up! El juego empresarial
    • Visita Odoo
    Obtén el software
    • Descargar
    • Compara ediciones
    • Versiones
    Colabora
    • GitHub
    • Foro
    • Eventos
    • Traducciones
    • Conviértete en partner
    • Servicios para partners
    • Registra tu firma contable
    Obtén servicios
    • Encuentra un partner
    • Encuentra un contador
    • Contacta a un consultor
    • Servicios de implementación
    • Referencias de clientes
    • Soporte
    • Actualizaciones
    GitHub YouTube Twitter LinkedIn Instagram Facebook Spotify
    +1 (650) 691-3277
    Solicita una demostración
  • Precios
  • Ayuda
Debe estar registrado para interactuar con la comunidad.
Todas las publicaciones Personas Insignias
Etiquetas (Ver todo)
odoo accounting v14 pos v15
Acerca de este foro
Debe estar registrado para interactuar con la comunidad.
Todas las publicaciones Personas Insignias
Etiquetas (Ver todo)
odoo accounting v14 pos v15
Acerca de este foro
Ayuda

Sale price computed based on BOM

Suscribirse

Reciba una notificación cuando haya actividad en esta publicación

Se marcó esta pregunta
salesmanufacturing
1 Responder
1422 Vistas
Avatar
Ysaline Van Wallendael
In Odoo, I can already recompute the cost of a manufactured product using the standard server action (action_bom_cost).
I would like to achieve a similar behavior, but instead of recomputing the cost, I want to recompute the sale price of the finished product.
The idea is:
  • each component in the BOM already has its own sale price (margin included)
  • the sale price of the finished product should be the sum of the sale prices of the BOM components, multiplied by their quantities
Is there an existing method or best practice in Odoo to do this (server action, override, computed field), similar to action_bom_cost?
Any guidance would be greatly appreciated.
0
Avatar
Descartar
Avatar
Ysaline Van Wallendael
Autor Mejor respuesta

I finally found a solution that works well without custom development, using Odoo Studio + Automations.

Context

The goal was to compute the sale price of a manufactured product based on the sale prices of its BOM components (margin already included at component level), similar to what action_bom_cost does for costs.

Add a sale price column on the BOM lines

First, I added a sale price column on the BOM lines (coming from the component product).

⚠️ Important point:

All BOM quantities must use the same Unit of Measure as the product sale UoM.

Odoo Studio does not handle UoM conversions automatically.

Example:

  • Product sold in hours

  • BOM needs 15 minutes → use 0.25 hours in the BOM

Create a computed Studio field on the BOM

I created a Studio computed field on the BOM (e.g. x_studio_prix_de_vente_calcule) with this Python code:

for record in self:

total = 0.0


for line in record.bom_line_ids:

unit_price = line.product_id.list_price or 0.0

qty = line.product_qty or 0.0

total += unit_price * qty


record['x_studio_prix_de_vente_calcule'] = total

Dependencies used:

bom_line_ids

This ensures the value is recalculated whenever BOM lines are modified.

Use an Automation to update the product sale price

Then, I used an Automated Action on the product to compute the final sale price from the BOM(s):

sum(

line['x_studio_prix_de_vente_calcule']

for line in record.bom_ids

)

This value is then written into the product’s sale price field.

Result

  • Sale price of the finished product = sum of sale prices of BOM components

  • No margin recalculation at product level

  • Fully compatible with Odoo Studio

  • No custom module required

  • Works reliably as long as UoMs are consistent

Notes

This approach is intentionally simple and avoids deep dependency chains (bom_line_ids.product_id.list_price) that are not supported in Studio.

For more advanced scenarios (multi-BOM logic, automatic UoM conversion, complex pricing rules), a custom module would be required.

0
Avatar
Descartar
¿Le interesa esta conversación? ¡Participe en ella!

Cree una cuenta para poder utilizar funciones exclusivas e interactuar con la comunidad.

Registrarse
Publicaciones relacionadas Respuestas Vistas Actividad
Air France Téléphone France
sales manufacturing
Avatar
0
abr 26
33
How get a report about the Consumption of raw materials to delivery orders per month?
sales manufacturing
Avatar
Avatar
1
jun 23
5665
How to group and filter order lines for manufacturing order?
sales manufacturing
Avatar
0
ene 23
4309
How to do sale of per-customer custom-product that spawns manufacturing order. Resuelto
sales manufacturing
Avatar
Avatar
1
jun 22
5013
BOM configuration with Variants "AND" connections
sales manufacturing bom
Avatar
Avatar
Avatar
2
jun 26
447
Comunidad
  • Tutoriales
  • Documentación
  • Foro
Código abierto
  • Descargar
  • GitHub
  • Runbot
  • Traducciones
Servicios
  • Alojamiento en Odoo.sh
  • Soporte
  • Actualizaciones del software
  • Desarrollos personalizados
  • Educación
  • Encuentra un contador
  • Encuentra un partner
  • Conviértete en partner
Sobre nosotros
  • Nuestra empresa
  • Activos de marca
  • Contáctanos
  • Empleos
  • Eventos
  • Podcast
  • Blog
  • Clientes
  • Legal • Privacidad
  • Seguridad
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk Slovenščina Español (América Latina) Español Svenska ภาษาไทย Türkçe українська Tiếng Việt

Odoo es un conjunto de aplicaciones de código abierto que cubren todas las necesidades de tu empresa: CRM, comercio electrónico, contabilidad, inventario, punto de venta, gestión de proyectos, etc.

La propuesta única de valor de Odoo es ser muy fácil de usar y estar totalmente integrado.

Sitio web hecho con

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now