On the website, when the widget "Latest Posts - Big Images" or "Latest
Posts - List" is added a 404 error is raised in the console.
This is because the regular expression of the background image is too
'greedy' and also match the trailing double quote, e.g.:
`website_blog.blog_post_cover_02"` instead of
`website_blog.blog_post_cover_02`.
By making it match the minimum pattern, the trailing double quote is not
selected.
opw-2061596
closesodoo/odoo#36622
X-original-commit: 0797a4ab90ec4d9be55e16d917da98909ce0ece4
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Before this commit, a french translated term missed the string format symbol
It crashed when making a so with a downpayment and issuing invoices
After this commit, the term is corrected, and no crash occurs
OPW 2069089
closesodoo/odoo#36574
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
In case the last location of a user was NULL in databse, lunch was
crashing because lunch_kanban was adding an undefined leaf to the load
domain.
closesodoo/odoo#36571
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
This translation causes a traceback when opening accounting app in
arabic.
opw-2068360
opw-2068513
opw-2069010
closes#36570
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Step to reproduce :
For small screens
> enter the debug mode
> go to the calendar app
> access one of your meetings
> access the tab "invitations"
> try to change the state of attendance
It's due to the missing kanban view used by the o2m field 'attendee_ids'
We had to create this missing kanban view to allow theses actions on mobile.
opw-2058770
closesodoo/odoo#36501
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
The response profile of an ACH transaction won't contain a credit card
number since ACH transactions use bank accounts instead. It looks like
this:
<getCustomerPaymentProfileResponse
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd">
<messages>
...
</messages>
<paymentProfile>
<billTo>
<firstName>XXX</firstName>
<lastName>XXXX</lastName>
<address>XXX XXX XXX</address>
<city>XXX</city>
<state>XX</state>
<zip>XXXXX</zip>
<country>XXX</country>
<phoneNumber>XXXXXXXXX</phoneNumber>
</billTo>
<customerProfileId>XXXXXXXXX</customerProfileId>
<customerPaymentProfileId>XXXXXXXXX</customerPaymentProfileId>
<payment>
<bankAccount>
<accountType>checking</accountType>
<routingNumber>XXXXXXXX</routingNumber>
<accountNumber>XXXXXXXX</accountNumber>
<nameOnAccount>XXX</nameOnAccount>
<echeckType>WEB</echeckType>
</bankAccount>
</payment>
</paymentProfile>
</getCustomerPaymentProfileResponse>
This causes the transaction not to get confirmed in Odoo:
...
File ".../authorize_request.py", line 241, in create_customer_profile_from_tx
res['name'] = response_profile.find('paymentProfile/payment/creditCard/cardNumber').text
AttributeError: 'NoneType' object has no attribute 'text' - - -
To solve it fall back on the accountNumber if there's no cardNumber.
opw-2062784
closesodoo/odoo#36298
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Before this commit, printing an invoice crashed
This was because of the refactoring of taxes
After this commit, the invoice prints well
and the specific taxes amount appear in the right columns
OPW 2060259
closesodoo/odoo#36244
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
The previous version of this verification was buggy and inadequate. It was for example impossible to post an account.move before the tax lock date, even if it did not impact the tax report in any way.
closesodoo/odoo#36289
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
Determine `model._rec_name` before the dependencies of the fields. The
compute method of the automatic field `display_name` uses a callable
depends that retrieves `model._rec_name`.
closesodoo/odoo#36479
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
Determine `model._rec_name` before the dependencies of the fields. The
compute method of the automatic field `display_name` uses a callable
depends that retrieves `model._rec_name`.
closesodoo/odoo#36480
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
Those values are only used on the website navbar when the user is in both groups
so the vast majority of the time they are done for no reason.
This reduces the number of queries by 2 on every page when the user is not admin
and/or multi website is not enabled.
Part of task-2061122
closesodoo/odoo#36483
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
Commit 6b6d290a5b made sure that the list of candidates was not
empty to avoid a zero division. However, it might still happen that the
`total_residual` is zero.
We make sure to avoid the zero division in this case.
opw-2058784
closesodoo/odoo#36482
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
— create a bom which uses 5.6 units of a product;
— make a production order;
— reserve the materials (all materials should be available);
— print the production order report.
Before this commit, a warning message in the report that says : 'All
components could not be reserved. Click on the "Check Availability
button" to try to reserve components'. This warning message is shown
despite the fact that all the components are reserved. This occurs
because of a rounding error.
Now, the warning message only when a component could not be reserved.
opw-2058921
closesodoo/odoo#36462
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Steps to reproduce the bug:
Let's consider two storable products P1 and P2 where P1 is tracked by serial number
- Create a BOM B for P1 where P2 is a component
- Create a serial numberv SN for P1 with no quantity
- Create a MO M1 for P1 and click on button "Produce"
- In the view MRP Product Produce, SN is selectable in the field lot_id
- Now change B and set a routing on it
- Create a new MO M2 for P1 and click on produce
- At least one WO has been created, click on the first one
Bug:
- SN is not selectable in the field final_lot_id
The domain set on the field final_lot_id:
"['|', '&', ('product_id', '=', product_id), ('product_id.tracking', '!=', 'serial'), ('use_next_on_work_order_id', '=', id)]"
didn't allow to chose SN.
With this fix, it's now possible to chose SN on the first WO created for M2
opw:2059745
closesodoo/odoo#36425
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
The condition needs to be fined-tuned, so revert for now.
This reverts commit 40487aca5c.
closesodoo/odoo#36470
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Create two expense and put them into one sheet
Post the sheet
Make One partial payment with the wizard (Register Payment)
Do it again for the residual amount
Before this commit, it crashed because the second payment tried to reconcile
itself with an already reconciled line
After this commit, all the lines that need to be reconciled
actually are without crash
OPW 2065501
closesodoo/odoo#36454
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Create a pricelist with a temporary discount on some product only for today.
Go to the shop. The discount is applied on the product.
Add the product to the cart.
Go to the cart page (review order): the price does not use the discount.
Because the query getting the pricelist item is some handwritten SQL,
it only works for dates, and not e.g. in the case of datetimes.
So the pricelist item encoding the discount is not retrieved, and thus not used.
It turns out e.g. in _website_product_id_change it gives a datetime in context,
explaining why sometimes the discount is applied, and sometimes not.
We use fields.Date.to_date as it should work on all date formats we shall pass.
Co-written with @sbbaro
opw 2054881
closesodoo/odoo#36453
Signed-off-by: Nans Lefebvre (len) <len@odoo.com>
Before this commit, if you had defined multiple attendances for the
morning or for the afternoon, the system would only use the first
attendance defined for either morning or afternoon.
This lead to wrong computations of the real leave length.
This commit fixes this issue by getting the min(hour_from) and
max(hour_to) for the attendances using a read_group.
closesodoo/odoo#36413
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Steps to reproduce the bug:
- Let's consider the following currency rates: 1.00 for USD and 0.50 for EUR
- Create invoice I with the same currency of your company (USD) and amount due = 100$
- Validate I
- Create refund R with a diffenrent currency of your company (EUR) and amount due = 1€
- Validate R
- Reconcile R with I
Bug:
The amount due of I was 196$ instead of 98$
PS: The root of this issue was coming from function assign_outstanding_credit that was called when
reconciling R with I. This function changes the currency_id and the amount_currency of the account move line.
So the function _amount_residual defined on model account.move.line was triggered as
the currency_id was changed. In _amount_residual, the residual_amount_currency was computed.
Forward-port up to saas-11.3
Closes#36252
opw:2062103
closesodoo/odoo#36412
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
Slovenian language, as many others languages, is not present in the
beta/master projects in Transifex.
For some reason, Transiflex removed all current translations, this was
already fixed in 12, but as there are not automatic forward-port for
translations, this is a manual forward-port.
opw-2060055
closesodoo/odoo#36374
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
We need to unpatch the view as soon as we correcly applied the
`groupedBy` attribute to avoid sub views to also be patched.
closesodoo/odoo#36486
Signed-off-by: Christophe Simonis <chs@odoo.com>
Before this commit, when using a promotion program ('I have a promo
code') in the shopping cart in the e-commerce, the image of the
promotion product is only shown if the user is connected.
opw-2056968
closesodoo/enterprise#5343
X-port/Cherry-pick of odoo/enterprise@88e1ab31d2
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Before this commit, when being on the sale coupon program form view
in French, it was impossible to click on the record found by the domains
this was because the widget domains were displayed in line, which made long
text overlap
After this commit, we display the widgets in the "in_dialog" mode, which
makes more vertical blocs
OPW 2061859closesodoo/enterprise#5363
X-port/Cherry-pick of odoo/enterprise@ffb86687a3
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
In case there is a lot of stock_moves and/or lot of
stock_quants, the function _get_qty_procurement
takes a lot of time because there is no index defined
on most accessed fields.
I.E. OPW-2027183
closesodoo/odoo#36113
Signed-off-by: Richard Mathot (rim) <rim@openerp.com>
On purchase journals, there is the possibility to set up an alias to
automatically create vendor bills from incoming email.
Three types of emails can send the bill:
- the vendor, with email matching a partner in database
- an internal user, possibly forwarding the bill he received from the vendor
- an unknown address
In the third case, the address will be ignored.
In the first, we found the vendor, so he can be set as partner_id of the bill.
The tricky one is the second case, where we try to guess the vendor.
Before, the code would take only the first email found in the body;
if it found a matching partner, then it used that partner anyway,
even if that partner belonged to a user and was skipped before.
After the fix, we get the partners for all emails
and take arbitrarily the first vendor, then backup on the first non-user.
Note also that email_addresses would duplicate every address read in the body;
we make a set to avoid duplicate processing.
opw 1885070
closesodoo/odoo#36399
Signed-off-by: Nans Lefebvre (len) <len@odoo.com>
Steps to reproduce the bug:
- Let's consider the following currency rates: 1.00 for USD and 0.50 for EUR
- Create invoice I with the same currency of your company (USD) and amount due = 100$
- Validate I
- Create refund R with a diffenrent currency of your company (EUR) and amount due = 1€
- Validate R
- Reconcile R with I
Bug:
The amount due of I was 196$ instead of 98$
PS: The root of this issue was coming from function assign_outstanding_credit that was called when
reconciling R with I. This function changes the currency_id and the amount_currency of the account move line.
So the function _amount_residual defined on model account.move.line was triggered as
the currency_id was changed. In _amount_residual, the residual_amount_currency was computed.
opw:2062103
closesodoo/odoo#36379
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
... and switching to 'edit' mode before the write RPC returns.
For instance, on a project task form view, in readonly, change the
state by clicking on the bullet, and directly switch to 'edit'
mode: when the RPC returns, the view is switched back in readonly.
Task 2065443
closesodoo/odoo#36400
Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
In grouped editable list, get rid of the groups
Edit one record in the editable list
In a M2O, click on search more
In search's list, group by a field
Expand a group in the search's list
Before this commit, it crashes because the event was propagated
onto the first main list
After this commit, it doesn't crash and the group is expanded
OPW 2064156
closesodoo/odoo#36383
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Before this commit, the allow cancelling entries field
was invisible when the journal was of type general
After this commit, the field is visible for every journal
OPW 2062875
closesodoo/odoo#36358
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Before this commit, when using website livechat with multiple tabs,
it may duplicate messages in the chat window.
This happens due to registering messages twice:
- once, from `/mail/chat_history`
- second, from receiving notification from master tab, via local
storage.
This commit fixes the issue by not registering messages that have
already been registered (i.e. unique ID).
opw-2052960
closesodoo/odoo#36370
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Steps to reproduce the bug:
- When trying to publish the sips payment acquirer not in debug mode
Bug:
It raised a access rights error because the fields: sips_test_url, sips_prod_url, sips_version
were not readable in function _check_required_if_provider and a default value was set for all
these fields.
opw:2061123
closesodoo/odoo#36346
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
Steps to reproduce the bug:
- Create a MO with a product with a normal bom B
- Save the MO
- Change the type of B to phantom
- Try to produce the MO
Bug:
It was impossible to cancel or confirm the MO.
It's not allowed to produce a MO with phantom bom.
opw:2061958
closesodoo/odoo#36329
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>