İçereği Atla
Odoo Menü
  • Portal
  • Ücretsiz deneyin
  • Uygulamalar
    Finans
    • Muhasebe
    • Faturalama
    • Masraf Yönetimi
    • Elektronik Çizelge (BI)
    • Belgeler
    • İmza
    Satış
    • Müşteri İlişkileri Yönetimi (CRM)
    • Satış
    • Satış Noktası Mağaza
    • Satış Noktası Restoran
    • Abonelikler
    • Kiralama
    Web Sitesi
    • Web Sitesi Oluşturucu
    • eTicaret
    • Blog
    • Forum
    • Canlı Sohbet
    • eÖğrenme
    Tedarik Zinciri
    • Envanter
    • Üretim
    • Ürün Yaşam Döngüsü Yönetimi
    • Satın Alma
    • Bakım
    • Kalite
    İnsan Kaynakları
    • Çalışanlar
    • İşe Alım
    • İzin
    • Değerlendirme
    • Referans
    • Filo Yönetimi
    Pazarlama
    • Sosyal Medyada Pazarlama
    • E-posta ile Pazarlama
    • SMS ile Pazarlama
    • Etkinlikler
    • Pazarlama Otomasyonu
    • Anket
    Hizmetler
    • Proje Yönetimi
    • Çalışma Çizelgeleri
    • Saha Hizmeti
    • Yardım Masası
    • Planlama
    • Randevular
    Verimlilik
    • Sohbet
    • Onay
    • Nesnelerin İnterneti
    • VoIP
    • Bilgi Bankası
    • WhatsApp
    Üçüncü taraf uygulamalar Odoo Stüdyo Odoo Bulut Platformu
  • Sektörler
    Perakende satış
    • Kitapçı
    • Giyim Mağazası
    • Mobilya Mağazası
    • Gıda Marketi
    • Hırdavat Dükkanı
    • Oyuncak Dükkanı
    Gıda ve Konaklama
    • Bar ve Pub
    • Restoran
    • Fast Food Restoranı
    • Konuk Evi
    • İçecek Distribütörü
    • Otel
    Gayrimenkul
    • Emlak Acentesi
    • Mimarlık Firması
    • İnşaat
    • Emlak Yönetimi
    • Bahçe Tasarımı
    • Mülk Sahipleri Derneği
    Uzmanlık
    • Muhasebe Firması
    • Odoo Partner
    • Pazarlama Ajansı
    • Hukuk Firması
    • Yetenek Kazanımı
    • Denetim ve Belgelendirme
    Üretim
    • Tekstil
    • Metal
    • Mobilyalar
    • Gıda
    • Bira fabrikası
    • Kurumsal Hediye
    Sağlık ve Spor
    • Spor Kulübü
    • Optik Mağazası
    • Fitness Merkezi
    • Sağlıklı Yaşam Merkezi
    • Eczane
    • Kuaför Salonu
    Ticaret
    • Tamirci
    • BT Donanım & Destek
    • Güneş Enerjisi Sistemleri
    • Ayakkabı İmalatçısı
    • Temizlik Hizmetleri
    • HVAC Hizmetleri
    Diğerleri
    • Kar Amacı Gütmeyen Kuruluş
    • Çevre Ajansı
    • Reklam Panosu Kiralama
    • Fotoğrafçılık
    • Bisiklet Kiralama
    • Yazılım Bayisi
    Tüm Sektörlere Göz Atın
  • Topluluk
    Öğrenim
    • Eğitim Araçları
    • Dokümantasyon
    • Sertifikasyonlar
    • Eğitim Etkinlikleri
    • Blog
    • Podcast
    Eğitim ve Gelişim
    • Eğitim Programı
    • Scale Up! İşletme Oyunu
    • Odoo'yu Ziyaret Edin
    Yazılım
    • İndirin
    • Sürümleri Kıyaslayın
    • Sürümler
    İş Birliği
    • Github
    • Forum
    • Etkinlikler
    • Çeviriler
    • Partner Olun
    • Partnerler için Hizmetler
    • Muhasebe Firmanızı Kaydettirin
    Hizmetler
    • Partner Bulun
    • Muhasebeci Bulun
    • Bir danışmanla görüşün
    • Kurulum Hizmetleri
    • Müşteri Referansları
    • Destek
    • Sürüm Yükseltme
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Demo randevusu alın
  • Fiyatlandırma
  • Yardım

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

  • Müşteri İlişkileri Yönetimi
  • e-Commerce
  • Muhasebe
  • Envanter
  • PoS
  • Proje Yönetimi
  • MRP
All apps
You need to be registered to interact with the community.
All Posts People Badges
Etiketler (View all)
odoo accounting v14 pos v15
About this forum
You need to be registered to interact with the community.
All Posts People Badges
Etiketler (View all)
odoo accounting v14 pos v15
About this forum
Yardım

Help understanding inline_form

Abone Ol

Get notified when there's activity on this post

Bu soru işaretlendi
inlinepayment-providers
2 Cevaplar
1807 Görünümler
Avatar
Van Hullebusch Tanguy

Hello, I am as of now trying to make a module that introduce a new Payment Provider, and so I took inspiration from module that are already in Odoo like Stripe or Adyen.

However, as I am trying to make the inline form work, I have a hard time understanding this bit of code : 

def _adyen_get_inline_form_values(self, pm_code, amount=None, currency=None):
""" Return a serialized JSON of the required values to render the inline form.

Note: `self.ensure_one()`

:param str pm_code: The code of the payment method whose inline form to render.
:param float amount: The transaction amount.
:param res.currency currency: The transaction currency.
:return: The JSON serial of the required values to render the inline form.
:rtype: str
"""
self.ensure_one()

inline_form_values = {
'client_key': self.adyen_client_key,
'adyen_pm_code': const.PAYMENT_METHODS_MAPPING.get(pm_code, pm_code),
'formatted_amount': self._adyen_get_formatted_amount(amount, currency),
}
return json.dumps(inline_form_values)

No, I understand what it does. My problem is to know what the required values are. Do they change between providers? Where do I find them?



0
Avatar
Vazgeç
Avatar
Van Hullebusch Tanguy
Üretici En İyi Yanıt

Thank you Christoph, it helps a lot.

0
Avatar
Vazgeç
Avatar
Christoph Farnleitner
En İyi Yanıt

Yes, these arguments vary from provider to provider, see for example this regex search for files having _.*_get_inline_form_values


Now, for Ayden for example, going up the stream, the method in question is called from within template (payment_adyen.method_form) inherited from payment.method_form. This template in return is called within payment.form which provides the following comments:

<!-- Form customization parameters:
            - mode: The operation mode of the form: `payment` or `validation`; default: `payment`.
            - allow_token_selection: Whether tokens can be selected for payment or assignation (through the `assign_token_route` parameter); default: `True`.
            - allow_token_deletion: Whether tokens can be deleted (archived); default: `False`.
            - default_token_id: The id of the token that should be pre-selected; default: `None`.
            - show_tokenize_input_mapping: For each provider, whether the tokenization checkbox is shown; used only in `payment` mode.
            - display_submit_button: Whether the submit button is displayed; default: `True`.
            - submit_button_label: The label of the submit button; default: 'Pay'/'Save'.
        -->
        <!-- Payment context:
            - reference_prefix: The custom prefix to compute the full transaction reference.
            - amount: The amount to pay.
            - currency: The currency of the payment, as a `res.currency` record.
            - partner_id: The id of the partner on behalf of whom the payment should be made.
            - providers_sudo: The compatible providers, as a sudoed `payment.provider` recordset.
            - payment_methods_sudo: The compatible payment methods, as a sudoed `payment.method`recordset.
            - tokens_sudo: The available payment tokens, as a sudoed `payment.token` recordset.
            - transaction_route: The route to call to create the transaction.
            - assign_token_route: The route to call to assign a new or existing token to a record.
            - landing_route: The route the user is redirected to after payment.
            - access_token: The access token used to authenticate the partner.
        -->


You may want to check out the module payment_custom as well.

What exactly you want or need to do depends on the payment provider you're trying to integrate.

0
Avatar
Vazgeç
Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Üye Ol
İlgili Gönderiler Cevaplar Görünümler Aktivite
What do I need to do so I can see Payment Providers in Odoo? Çözüldü
payment-providers
Avatar
Avatar
1
Eyl 25
3472
Newly created Payement provider not working Çözüldü
payment-providers
Avatar
Avatar
Avatar
2
Şub 24
3541
Payment provider
payment-providers
Avatar
Avatar
Avatar
2
Şub 24
8409
Develop new payment provider v16
payment payment-providers
Avatar
Avatar
Avatar
3
Şub 25
6408
Custom inline content blocks, Odoo 16 Çözüldü
widget inline
Avatar
1
Nis 24
1853
Topluluk
  • Eğitim Araçları
  • Dokümantasyon
  • Forum
Açık Kaynak
  • İndirin
  • Github
  • Runbot
  • Çeviriler
Hizmetler
  • Odoo.sh Hosting
  • Destek
  • Sürüm Yükseltme
  • Özel Geliştirmeler
  • Eğitim
  • Muhasebeci Bulun
  • Partner Bulun
  • Partner Olun
Hakkında
  • Şirketimiz
  • Pazarlama Gereçleri
  • İletişim
  • Kariyer
  • Etkinlikler
  • Podcast
  • Blog
  • Müşteriler
  • Hukuki • Gizlilik
  • Güvenlik
الْعَرَبيّة 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, müşteri ilişkileri yönetimi, eTicaret, muhasebe, envanter, satış noktası, proje yönetimi gibi şirketinizin tüm ihtiyaçlarını karşılayan bir açık kaynak işletme uygulamaları paketidir.

Odoo’nun eşsiz değer önermesi, aynı anda hem kullanımının çok kolay olup hem de tamamen entegre olmasıdır.

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