- Create a calendar event
- Add invitees
The invitees receive a mail so they can accept/decline. When clicking,
the page is always displayed in the language of the administrator.
Since the `request` object is not directly associated to the attendee,
the template is not rendered in his language. Since (i) the template
should not be rendered lazily (see comment in code) and (ii)
`request.render()` does not allow the rendering in an arbitraty
language, we do a manual call to `render_template`.
opw-694718
1. Set up BoM component A with cost of $1 per kg
2. Create a BoM which uses 1t of component A
3. Execute the BOM Cost report
Cost of component A is $1, while it should be $1000.
opw-695014
The function _get_pl_partner_order must also return the available
pricelists on the website with promo code. In this way, the user
can use promo code on the website.
opw:694556
The decimal precision `Account` no longer exist.
This check is therefore pointless, and prevent
to change the rounding of the currency of the main company
Since revision 458aaca328,
the `groups` args of the method `_notification_recipients`
is a list of tuple, and no longer a dict.
The code here has not been adapted to this change.
It is now.
opw-695300
Rev. d6e1d41128 removed old API
compatibility layer, but failed to preserve the ability to
call certain public methods from the RPC layer, when extra
browse_record parameters were required.
In particular the @api.v7 version of
`prepare_move_lines_for_reconciliation_widget` was dropped
and there was no way to call it with a `target_currency` RPC
parameter anymore.
Call was done in ajax to speed up the moderation and don't wait refresh at each accpet/refuse post.
But the problem is that when you refuse a post, you need to be redirected to a new page to ask more
infos about the reason.
The fix is to do the request in ajax only when it is an 'accepted' post.
This commits fixes odoo/odoo@14462
When we enable in the settings 'Get 2 levels of approvals' with a
'Double validation amount', and then create a request for quotation.
When we confirm it, even if the total amount of the request for
quotation is below the amount set in the settings, the purchase order
needs to be approved.
We excpect that if a purchase order has a total amount below the
validation amount setting, the purchase order is automatically
confirmed.
So to fix it, we compare the amount when the user click on the button
confirm. And immediatly call the function 'button_approve' if the amount
is below the double validation amount set in settings.
Bug introduced in rev: https://github.com/odoo/odoo/commit/9d4efc81a
opw - 694381
I hereby confirm I have signed the CLA and read the PR guidelines at
www.odoo.com/submit-pr
(yes, github mutilates nicknames with underscores)
Closes#13875
The module `payment_stripe` was apparently not designed to work with
module `website_payment`, althought the payment method is available. For
example:
- Go to '/my/home', select "Pay Now" on an invoice
- Try to pay with Stripe ==> nothing happens
This commit brings the necessary modifications to make it compatible
with `website_payment`. Moreover, it prevents the creation of 2
`payment.transactions`, which was not necessary.
opw-693421
During the conversion to the new api,
the method `product.uom`.`_compute_price` has had its signature
changed.
Formerly, it was:
`def _compute_price(self, cr, uid, from_uom_id, price, to_uom_id=False):`
Now, it is:
`def _compute_price(self, price, to_unit):`
Basically:
- the first argument `from_uom_id` is removed, and you now should
call this method from the model record directly
- the last argument is no longer a kwargs
Some calls to this method were still done the former way:
- Some have been added during forward ports
- Some are oversights when this method has been converted to the new api
This revision corrects the calls that were still done the former way
to the new way.
opw-694871
When refunding a supplier invoice with tax cash basis and no cash flow,
a movement for the cash basis tax was created.
Only entries with cash flow must be created for cash basis taxes.
opw:693453
children_quant_ids is a computed field that does a search based on current
record id. However this causes a traceback when creating a record as
there is no id. This commit fixes this issue.
Those fields were stored computed fields before. However store has been
removed while migrating to the new API. We need a search function if we
want to be able to search on those fields and to use domains.
Domains are necessary to take packages from the right source locations.
The computation is done by searching the packages with the
"location/owner/..." domain and by returning a parent-of domain
in order to include all parent packages too.
When on a page event for example, when the user choose "Edit menu",
a modal is first opened to ask which menu to edit (the top menu or
the event menu ?).
This feature was broken with a web_editor refactoring. Indeed, the
dialog was converted to use the standard dialog class but the
widget was still inserted in the DOM thanks to "appendTo" instead of
the modal built-in "open" method, preventing it to be properly opened.
Commit 0b87f76628 introduced in 9 some new
controllers in hr holidays. They are used to activate some workflow signals
through dedicated controllers.
However hr holidays workflow have been removed meanwhile at commit
6a8e4c6119. This commit fixes the forward-port
by correctling calling methods instead of trigerring workflow signals.
With a9bd9ab1 the access action was refined depending on the user.
But when sending a mail about a sale order, this lead to an issue since
a mail template is rendered with the current user and not the mail
recipients.
So in the case of a sale order, the recipient could not have a button
leading to /my/orders/{order_id} whilst he should have, because the
user used to render the mail was the sender (which was an employee and
not a share user).
This commit adds a context key "force_website" which force the action to
an available /my/orders even if the sender is not a share user.
opw-691040
In some cases, when the destoy method of 'Tip' calls the off() function on
'$breathing', even if this one is not defined.
To fix this error, we check that '$breathing' is not 'undefined' before
calling off() on it.
When we are trying to use the button 'set date to all order lines, we
get a traceback saying, that update cannot be done, because it ensure
that there's only one record. (After 9.0, there is no more this
'ensure_one').
This bug has been introduced in rev: https://github.com/odoo/odoo/commit/401a3cfaf6fd09f594e45c181e908900acba3777
To fix it, we iterate over the order lines, and do the update of each
line.
When tax cash basis is used, the user might face the error "Wrong credit
or debit value in accounting entry !". A detailed use case can be found
in issue #14158.
The reason is that a float representation of `1.0` of the field
`matched_percentage` will become `1.000...2` when used in Python.
Therefore, such an expression such as `line.credit_cash_basis -
line.credit * matched_percentage` might lead to a slightly negative
value for the credit/debit, which will not pass the condition `CHECK
(credit+debit>=0)`.
Fixes#14158
opw-692797
More information from https://en.wikipedia.org/wiki/Decimal_mark section:
"examples of use"
`The following examples show the decimal mark and the thousands separator in
various countries that use the Arabic numeral system.`
`Style: 1,234,567.89 Countries: Malaysia, Mexico, New Zealand, Pakistan,
Philippines, Singapore, Taiwan, Thailand, United Kingdom, United States`
Closes#14402