Ir al contenido
Odoo Menú
  • Iniciar 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
    • Aprobaciones
    • 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 bienes inmuebles
    • 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
  • Odoo Community
    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

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Contabilidad
  • Inventario
  • PoS
  • Proyectos
  • MRP
All apps
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

Select custom supplier when creating sale.order.line

Suscribirse

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

Se marcó esta pregunta
sale.order.linepurchase_orderodooV8odoo8.0
2 Respuestas
5861 Vistas
Avatar
Juanma

Hello,

I have the following issue with odoo 8:

When I create a sale.order with sale.order.lines with multiple product.supplierinfo for a product, if two or more suppliers have the same criteria, always the first one is selected (and the purchase.order created from the invoice is always for the first supplier), my issue is that i need to be able to select the supplier when creating the sale.order because sometimes the supplier selection is related with external factors from odoo (supplier availability or other business logic not related with odoo)


I have few knowledges with odoo and with odoo modules so can someone give me some tips about how to develop this with python or if there is any module that can help me achieve this?


regards,

juanma.

0
Avatar
Descartar
Avatar
Denis Baranov
Mejor respuesta

Hi,

it would be quite hard, since when purchase orders are created you do not have info about a sales order.

Generally, what you should do:

  1. Add in sale.order.line info about a supplier as m2o to supplier info (the same as in a product)

  2. Somehow transfer SO this info through procurement. E.g. have a look at the method _prepare_order_line_procurement of sale.order and at how a chain of procurements is generated in the module 'procurement'. 

  3. Then in the purchase.order method _check_supplier_info add a check from this info, instead of getting it from a product.

Simplier way would be to define some logical parameter how to select a supplier. So, you add some extra parameter to supplier.info (such as availability for example) and use this parameter to _check_supplier_info to select a proper vendor.

Hope that helps.



 


0
Avatar
Descartar
Avatar
Juanma
Autor Mejor respuesta

I can't edit the topic so I will explain again my issue:

When I create a sale.order, when adding a product in the sale.order.lines the supplier is selected automatically depending on some criteria, that is ok, the common behaviour, but if two or more suppliers have the same criteria, always the first one is selected (and the purchase.order created automatically from MRP module is always for the first supplier), my issue is that i need to be able to select the supplier within the same criteria when creating the sale.order because sometimes the supplier selection is related with external apart away from odoo (supplier availability or other business logic not related with odoo)

0
Avatar
Descartar
Denis Baranov

And the answer is still the same: you need to-rework procurement, what is quite hard

¿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
Sale order page configuration
sale.order.line purchase_order
Avatar
Avatar
1
may 25
1694
Let Delivery Order create one PURCHASE ORDER per Source Doc / not multiple sources in one P.O Resuelto
purchase_order odooV8
Avatar
Avatar
1
jun 21
6780
Using with_context in super call turns into infinite call in odoo Resuelto
odooV8 odoo8.0
Avatar
Avatar
Avatar
2
ene 20
16125
Edit inherited field definition in odoo 8 Resuelto
odooV8 odoo8.0
Avatar
Avatar
Avatar
Avatar
Avatar
16
ago 19
11507
display field depending the value of another field in the view (odoo 8) Resuelto
odooV8 odoo8.0
Avatar
Avatar
1
ene 19
6114
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 ภาษาไทย 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.

Website made with

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