Currently when the payment is initiated there is a message in
sale order for waiting for confirmation.
But when the payment returns an error there is no message on
sales order so it's not clear for the end user that payment
is still pending.
Related Task ID : 58741
- The method `_get_available_payment_input` that returns the available
payments acquirers and the payments tokens for a specific user never
returns the payments tokens linked to a non s2s payment acquirers.
This is wrong, the payments tokens should always appears no matter
what are the acquirers' payment flow.
The payment flow is used only to specify where the customer should
input his credit cards details, either on Odoo or on the payment
acquirer's website (or popup).
Once a token is created, it is safe to process it since no credits cards
details are stored on the Odoo database.
closesodoo/odoo#30258
The field partner id is not a required field in payment transaction, and
we try to read its value in the dictionnary given to the create
function, so if a transaction is created without the partner_id, it will
raise a KeyError.
So to fix it, we only complete the pratner values on the payment
transaction if a partner_id is given.
- The payment transaction processing cron retrieves all the transactions
that need to be processed.
In some cases, it can causes issues when trying to process payments
that are being process by the payment polling page after returning
from the payment acquirer.
To avoid this concurrency issues, the cron will only process payments
that have been validated for at least 10 minutes.
closesodoo/odoo#29317
- When a payment is done through a `payment.transaction` the
communication should be the transaction's reference instead of its
invoices reference.
closesodoo/odoo#29187
Purpose is to clean the use of tracking parameters on fields. Parameters are
merged and is now tracking=<int> or tracking=True.
This commit is linked to task ID 1903814 and PR #28430.
Check that it makes custom binary fields into attachment as that's the
main reason for the change: when users create binary fields via Studio,
they're necessarily db-stored (as the interface doesn't allow altering
the attachment attribute and it's unclear how we'd handle users
switching it on/off every time), which significantly bloats their
database (and burns storage & backup space), especially as the primary
use case for binary fields is adding images and documents to records.
* check that binary fields are properly created as attachment=True
* add attachment=False on fields where that seems relevant (most but not
all of the fields previously using the default)
* remove occurrences of attachment=True
closesodoo/odoo#29308
- Before this commit when a transaction failed, the code doesn't
rollback and continue to process the other transaction, thus creating
record that should be rollbacked.
closesodoo/odoo#28748
Transfer accounts created for payment acquirers was ignoring the prefix of the main transfer accounts and was always creating accounts with code 000001, 000002, etc.
The reason is because the method was called on an empty recordset
closesodoo/odoo#28789
This commit adapts the business code to changes introduced by
the parent commit in order to keep the same behaviour as before.
All readonly=False fields will have to be checked afterwards to confirm
that the business case requires write access to the source field.
Purpose of this commit is to give description more "business oriented"
because those descriptions appears in Odoo Studio which is supposed to be used by end users, not only by developers.
Related Task ID : 37311
Purpose
=======
- Add the SwissQR Code on the invoice in aim to replace the actual ISR
- Improve the settings of the SEPA QR Code to make it more user friendly
Specifications
==============
- ln_ch:
- Add a SwissQR Code on the invoice to fit the Switzerland QR-Bill Format
- Use the "partner_bank_id" field to generate the QR Code
- Add function to get the address number out of the field "street" and "street2"
- account:
- Remove the SEPA QR Code's journal settings from the general setting
- Display the "partner_bank_id" field on the invoice "Other info" page
- Use the "partner_bank_id" field to generate the QR Code
- website_sale:
- Add a check box on the payment acquirers to use the SEPA QR Code on the e-commerce
- Use the payment acquirer "journal_id" field to generate the SEPA QR Code
This commit aims to improve the user experience when using payment acquirers. There currently are no error feedback with some acquirers, which leaves the user wondering what is going on and what is the real status of its payment.
In some cases, the user is currently being redirected to the home page even though the payment has failed. We want to make it more obvious to the user that something unexpected has happened by redirecting to an intermediate page that will provide good feedback on payments status.
Another goal of this commit is to order acquirers by sequence instead of by flow and to select the first acquirer by default. This feature was already implmented in commit fe294fd43e521bd2d339e962f43acf46c3d4cb97, some UI adaptations were needed though.
Related to task #36680Closes#26958
- payment.acquirer have many fields with 'required_if_provider'
attribute and while saving form it gave an error like "Required
fields not filled", so it was confusing to know which required fields were empty.
- after this commit, it is displayed like "Required fields not filled (field name)"
opw:1881054
- We extract some code logic to methods to allow to override them.
This is needed for the subscription module where a payment token need
to be copied from a transaction to a subscription.
The subscriptions is created from a sale order and before the
payment.transaction holding the payment.token id is validated.
Since the payment.transaction is not validated, the subscription
module doesn't find the correct transaction.
By extracting this code logic, we can override exactly when it should
be.
- The method to compute the reference of a payment.transaction and avoid
duplicate was missing some edge cases (for example if there was a '-'
in the reference).
- The creation of transactions in the route /website_payment/pay was not
checking for duplicate payment.transaction.
Like invoices, a reference is now computed on sales orders.
The configuration of such reference is done through the Wire Transfer acquirer.
The usability of the communication feature (on invoices/SO) has been a bit improved to be more clear.
Was task: 1870121
Was PR #26152
Add an onboarding panel for invoicing, it appears above the invoice
list.
After going through the steps the system should be all set to send real invoices.
In the payment module, add a payment acquirer step and add it to the invoice onboarding panel.
task: 60668
- When clicking on the invoices stat button on payment transactions via
the form view a traceback is displayed.
This is due to the fact that the code is trying to access to a
member/field named "id" on an integer.
"invoice" is an integer, not a record/object.
Purpose
=======
The Contact form is one of the most used/important view. It is quite
important to find the piece of information easily and to navigate in
a few clicks to the related views.
Specification
=============
Stat buttons
------------
- Restructure stat buttons with the following order:
Opportunities -> sales user
Meetings -> sales users
Sales -> Sales users
POS Sales -> pos users
Subscriptions -> Subscription users
Events -> event user
Tasks -> project user
TIckets -> helpdesk user
Purchases -> purchase user
Due -> billing: user
Invoiced -> billing: user
Vendor Bills -> billing: user
Customer/Vendor Partner Ledger -> accounting: billing
Analytic Accounts -> accounting: billing
Credit Cards -> sales user
Direct Debit Mandates -> accounting: billing user
Publish
- Use better/more relevant icons
- Check that the proper access rights are set
- Remove the bank accounts stat buttons and replace it by a one2many
tree on the Invoicing page.
Fields
------
Move some res.partner fields from the "Accouting" page to the
"sale & Purchase" page:
- Fiscal positions
- Payment terms
Miscellaneous
-------------
- Remove dead code.
- Display nothing instead "Please complete customer's informations and email"
on the popup when sending an email to a contact without email address.
.. & hide transaction list + page numbers on HTML report.
1. Before this commit:
Portal Invoices were displaying the total amount instead of the residual
amount. The pay button would also trigger a payment for the total amount
Now:
If part of the invoice is already paid, we show the residual amount and
payment transaction amount are set to residual amount so the client is asked
to pay what he really needs to pay.
2. Processed transaction results in a bootstrap alert message displayed at the
top of the page, showing warning, success or alert depending of the result.
This alert is supposed to show thank message `post_msg` only if it set.
Before this commit:
Since `post_msg` is an html field and editable through summernote, it will
never be empty. Indeed, empty field with summernote are replaced by a `br` tag
inside a `p` tag.
The condition would never be false, resulting in an empty `p` with a `br`
inside being displayed at the bottom of the alert, making it looks like it is
bugged.
Now:
The condition also consider summernote's empty string as such.
3. Remove the transaction list from the invoice portal template since it is not
an important information to the client.
Some client would not even understand what it is.
4. Hide page numbers on HTML report since they are not split in pages and page
number remains empty, resulting in `Page: /` (Or empty square with the
'clean layout.)
It was very confusing for the user to distinct account.payment and payment.transaction. From now on, the transactions are
technical objects and, in the backend, we only refer to it in log messages (Front end will be adapted in the same fashion
later on). They are hidden in debug mode in accounting\configuration\payments as their purpose is now purely technical/log
This commit also aims to reduce the gap between the accounting app and the transactions: account.payment objects are
created/validated upon completion of transaction.
To ease the capture/voiding of pending transactions, the related buttons are now displayed directly on the SO/invoice
instead of the transactions.
Was task: https://www.odoo.com/web#id=35857&view_type=form&model=project.task&action=333&active_id=967&menu_id=4720
Was PR #24043
[FIX] add domain based on journal to payment tokens
Was opw: https://www.odoo.com/web?debug#id=1828206&view_type=form&model=project.task&menu_id=5200
The field `transactionReference` of Sips must contain only
alphanumerical characters. Previous commit 31dc6b888e solved
the special case of several attempts to pay, but a much simpler case may
appear in v11. Paying an invoice is likely to fail since the reference
contains by default `/`.
In the previous commit, we could simply modify the common `payment`
module code. In this specific case, however, we only change the
reference if the acquirer is Sips.
opw-1841483
This commit adds the auto-creation journal for installed acquirers.
This is not easy because:
- The acquirers are created on the 'payment' module but are enabled only when the specific module
is installed. E.g. Paypal is enabled with 'payment_paypal'.
- To create a journal, a chart of accounts is required. However, the post_init_hook on the
'account' module makes the installation order harder. E.g install payment_paypal directly:
The module are installed in the order: account -> payment -> payment_paypal -> l10n_generic_coa.
To fix the problem, the journals are created at two moments:
- During the installation of the chart of accounts.
- At the installation of an acquirer module. E.g. payment_paypal.
Was PR #23904
Was task: 1831620
Until now invoice_id is filled on the transaction only when we make
payments through invoice. However if we make payments through sale order
then invoice_id is not filled.
This commit fixes that issue. As there is no common point between
sale_payment and account_payment except payment, a void method is added
in payment and an override done in account_payment. That was when both
modules are installed code is correctly triggered.
This commit is related to task ID 1813602. Closes#22746 .
This was already the intended behavior, but in Python a return inside
of a try...finally does not behave this way. From the Python
documentation [1]:
When a return, break or continue statement is executed in the try
suite of a try...finally statement, the finally clause is also
executed ‘on the way out.’
This can cause issues because some payment acquirers will return an
error when refunding a pending transaction. This puts the transaction
in the 'error' state which means it won't be refunded anymore.
Additionally, putting s2s_do_transaction in a try...except like this
hides any traceback that occurs which makes troubleshooting harder.
[1] https://docs.python.org/3/reference/compound_stmts.html#finally