Ir al contenido
Odoo Menú
  • Identificarse
  • Pruébalo gratis
  • Aplicaciones
    Finanzas
    • Contabilidad
    • Facturación
    • Gastos
    • Hoja de cálculo (BI)
    • Documentos
    • Firma electrónica
    Ventas
    • CRM
    • Ventas
    • TPV para tiendas
    • TPV para restaurantes
    • Suscripciones
    • Alquiler
    Sitios web
    • Creador de sitios web
    • Comercio electrónico
    • Blog
    • Foro
    • Chat en directo
    • e-learning
    Cadena de suministro
    • Inventario
    • Fabricación
    • PLM
    • Compra
    • Mantenimiento
    • Calidad
    Recursos Humanos
    • Empleados
    • Reclutamiento
    • Ausencias
    • Evaluación
    • Referencias
    • Flota
    Marketing
    • Marketing social
    • Marketing por correo electrónico
    • Marketing por SMS
    • Eventos
    • Automatización de marketing
    • Encuestas
    Servicios
    • Proyecto
    • Partes de horas
    • Servicio de campo
    • Servicio de asistencia
    • Planificación
    • Citas
    Productividad
    • Conversaciones
    • Aprobaciones
    • IoT
    • VoIP
    • Conocimientos
    • WhatsApp
    Aplicaciones de terceros Studio de Odoo Plataforma de Odoo Cloud
  • Industrias
    Comercio al por menor
    • Librería
    • Tienda de ropa
    • Tienda de muebles
    • Tienda de ultramarinos
    • Ferretería
    • Juguetería
    Alimentación y hostelería
    • Bar y pub
    • Restaurante
    • Comida rápida
    • Casa de huéspedes
    • Distribuidor de bebidas
    • Hotel
    Inmueble
    • Agencia inmobiliaria
    • Estudio de arquitectura
    • Construcción
    • Gestión inmobiliaria
    • Jardinería
    • Asociación de propietarios
    Consultoría
    • Empresa contable
    • Partner de Odoo
    • Agencia de marketing
    • Bufete de abogados
    • Adquisición de talentos
    • Auditorías y certificaciones
    Fabricación
    • Textil
    • Metal
    • Muebles
    • Alimentos
    • Cervecería
    • Regalos de empresas
    Salud y bienestar
    • Club deportivo
    • Óptica
    • Gimnasio
    • Terapeutas
    • Farmacia
    • Peluquería
    Oficios
    • Handyman
    • Hardware y soporte técnico
    • Sistemas de energía solar
    • Zapatero
    • Servicios de limpieza
    • Servicios de calefacción, ventilación y aire acondicionado
    Otros
    • Organización sin ánimo de lucro
    • Agencia de protección del medio ambiente
    • Alquiler de paneles publicitarios
    • Estudio fotográfico
    • Alquiler de bicicletas
    • Distribuidor de software
    Explorar todos los sectores
  • Comunidad
    Aprender
    • Tutoriales
    • Documentación
    • Certificaciones
    • Formación
    • Blog
    • Podcast
    Potenciar la educación
    • Programa de formación
    • Scale Up! El juego empresarial
    • Visita Odoo
    Obtener el software
    • Descargar
    • Comparar ediciones
    • Versiones
    Colaborar
    • GitHub
    • Foro
    • Eventos
    • Traducciones
    • Convertirse en partner
    • Servicios para partners
    • Registrar tu empresa contable
    Obtener servicios
    • Encontrar un partner
    • Encontrar un asesor fiscal
    • Contacta con un experto
    • Servicios de implementación
    • Referencias de clientes
    • Ayuda
    • Actualizaciones
    GitHub YouTube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Solicitar 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
  • Proyecto
  • 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 gateway module creation howto

Suscribirse

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

Se marcó esta pregunta
modulegatewaypaymenttemplatescaffold
2 Respuestas
9668 Vistas
Avatar
Albert

Hello,

I am digging into creating a payment gateway module in Odoo 10. So far I have done the following:

- Copied the paypal payment module as base

- Changed all occurrences of paypal with pagseguro

- Changed all occurrences of Paypal with PagSeguro

- Renamed files containing *paypal* with *pagseguro*

I was expecting to at least be able to install the module and later understand how it works and write the necessary logic, however I am having this error during installation.

I was wondering if anyone could please guide me on what the problem could be. I also tried the same thing with another payment gateway as base and I had the same error [1].

Alternatively, is there any payment gateway skeleton/scaffold/bob-template so I can start with?

Thank you very much!

[1]: Herewith the installation error

  File "/home/av/repos/volunteering/abba/abba10.odoo/parts/odoo/odoo/models.py", line 3901, in _create
    self._check_selection_field_value(name, val)
  File "/home/av/repos/volunteering/abba/abba10.odoo/parts/odoo/odoo/models.py", line 2116, in _check_selection_field_value
    field.convert_to_cache(value, self)
  File "/home/av/repos/volunteering/abba/abba10.odoo/parts/odoo/odoo/fields.py", line 1739, in convert_to_cache
    raise ValueError("Wrong value for %s: %r" % (self, value))
ParseError: "Wrong value for payment.acquirer.provider: 'pagseguro'" while parsing /home/av/repos/volunteering/abba/abba10.odoo/addons/addons_haevas_payment/payment_pagseguro/data/payment_acquirer_data.xml:4, near
<record id="payment.payment_acquirer_pagseguro" model="payment.acquirer">
            <field name="name">PagSeguro</field>
            <field name="image" type="base64" file="payment_pagseguro/static/src/img/pagseguro_icon.png"/>
            <field name="provider">pagseguro</field>
            <field name="company_id" ref="base.main_company"/>
            <field name="view_template_id" ref="pagseguro_acquirer_button"/>
            <field name="environment">test</field>
            <field name="pre_msg">
&lt;p&gt;You will be redirected to the PagSeguro website after clicking on the payment button.&lt;/p&gt;</field>
            <field name="pagseguro_email_account">dummy</field>
            <field name="pagseguro_token">dummy</field>
            <field name="pagseguro_redirect_url">dummy</field>
            <field name="pagseguro_notification_url">dummy</field>
        </record>
2
Avatar
Descartar
Avatar
phuongtai2020@gmail.com
Mejor respuesta

I also have this problem. After searching code, I find a reason:

    def _check_selection_field_value(self, field, value):

        """ Check whether value is among the valid values for the given

            selection/reference field, and raise an exception if not.

        """

  Therefore, You must override field provider with add_selection:

Example for your instance: 

provider = fields.Selection(selection_add=[('pagseguro', 'Pagseguro')])


0
Avatar
Descartar
Avatar
Rodrigo Velazquez
Mejor respuesta

Cannot comment on this.. I am trying something similar and also get the error:

Wrong value for payment.acquirer.provider

Has anyone been able to successfully resolve this error?


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

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

Inscribirse
Publicaciones relacionadas Respuestas Vistas Actividad
adding custom message to payment confirmation status view
modules module gateway payment acquirer
Avatar
1
nov 20
5042
custom payment acquirer, xml ParseError when parsing acquirer record data
modules module gateway payment acquirer
Avatar
1
nov 20
5144
New Payment gateway integration
module payment
Avatar
Avatar
Avatar
2
ago 17
5562
Assertion Error Template is required when i click the pay button(odoo 18)
payment template Odoo 18
Avatar
Avatar
1
jun 25
2053
Malaysian Payment Gateways
gateway payment Acquirer
Avatar
0
nov 22
3030
Comunidad
  • Tutoriales
  • Documentación
  • Foro
Código abierto
  • Descargar
  • GitHub
  • Runbot
  • Traducciones
Servicios
  • Alojamiento Odoo.sh
  • Ayuda
  • Actualizar
  • Desarrollos personalizados
  • Educación
  • Encontrar un asesor fiscal
  • Encontrar un partner
  • Convertirse en partner
Sobre nosotros
  • Nuestra empresa
  • Activos de marca
  • Contacta con nosotros
  • Puestos de trabajo
  • Eventos
  • Podcast
  • Blog
  • Clientes
  • Información 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 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