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

Payment method in invoice

Suscribirse

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

Se marcó esta pregunta
invoicecustomstudioodoo16features
2 Respuestas
3426 Vistas
Avatar
Aymerick Cotche

Hello there,

I would like to display an array with payments details in my customer's invocies.

Can someone helps me to achieve this with Odoo studio or with a selfmade custom module ?

I want to display the payment date, amount and payment method of each payment for 1 invoice at the end of my invoice's report.

I'm using Odoo 16 on Odoo SH.

Thank you in advance,


Aymerick

0
Avatar
Descartar
Avatar
Danizan Che Din
Mejor respuesta

Hi Cybrosys,

Thanks for the code.

I created a custom module for v18 CE to test and managed to install it.

When displaying front end invoice i got this error :

Error while render the template
AttributeError: 'account.move' object has no attribute 'payment_details'
Template: account.report_invoice_document
Path: /t/t/div[2]/div/div[4]/t[2]/t
Node: <t t-esc="o._get_name_invoice_report()"/>

0
Avatar
Descartar
Avatar
Cybrosys Techno Solutions Pvt.Ltd
Mejor respuesta

Hi

Add this code of invoice template.xml to your custom module

<template id="report_invoice_inherits"
            inherit_id="account.report_invoice_document">

      <xpath expr="//div[@name='payment_term']" position="after">
              <t t-if="o.payment_details">
                 <center><strong style="font-size:20px;">Payment Details</strong></center>
                  <t t-esc="o._get_name_invoice_report()"></t>
                  <br/>
                  <table class="table table-sm o_main_table" name="payment_details_table" style="background-color: #F1F1F1; font-family:Verdana, Arial,sans-serif; color: #454748; width: 100%; border-collapse:separate;">
                      <thead>
                          <tr>
                              <th name="th_sl_no" class="text-center" style="width:50px"><span>SL No</span></th>
                              <th name="th_payment_reference" t-attf-class="text-center {{ 'd-none d-md-table-cell' if report_type == 'html' else '' }}" style="width:200px"><span>Payment Ref</span></th>
                              <th name="th_payment_date" t-attf-class="text-center {{ 'd-none d-md-table-cell' if report_type == 'html' else '' }}" style="width:100px"><span>Date</span></th>
                              <th name="th_payment_method" t-attf-class="text-center {{ 'd-none d-md-table-cell' if report_type == 'html' else '' }}" style="width:140px"><span>Payment Method</span></th>
                              <th name="th_amount_paid" t-attf-class="text-center {{ 'd-none d-md-table-cell' if report_type == 'html' else '' }}" style="width:110px"><span>Amount Paid</span></th>
                          </tr>
                      </thead>
                      <tbody class="payment_details_table">
                          <t t-foreach="payments_vals" t-as="value">
                              <tr>
                                  <td><t t-esc="value_index+1"/></td>
                                  <td><t t-esc="value.get('ref')"/></td>
                                  <td><t t-esc="value.get('date')"/></td>
                                  <td><t t-esc="value.get('journal_name')"/></td>
                                  <td><t t-esc="value.get('amount')"/></td>
                              </tr>
                          </t>
                      </tbody>
                  </table>
              </t>
      </xpath>
  </template>





Hope it helps

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
Add a "last page" in invoices with terms & conditions
invoice studio
Avatar
Avatar
2
mar 25
2062
Default value from a other field in Studio
studio odoo16features
Avatar
Avatar
1
abr 24
4262
Odoo Studio - can't drag & drop columns or tabs in form view (v16+e)
studio odoo16features
Avatar
Avatar
Avatar
2
feb 24
4689
Edit invoice payment widget on odoo SH v16 with Studio or custom module
invoice module studio OdooSH odoo16features
Avatar
Avatar
1
feb 24
2898
Add bank account number under company details of a invoice - Odoo 16 Community Edition Resuelto
invoice odoo16features
Avatar
Avatar
1
mar 24
1476
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.

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