=== ISSUE 1 ===
When the Control Panel breadcrumb was not displayed (eg. after reloading
the page), the name of the last element was used. In this case, the name
was not truncated and could create a layout issue if it was too long.
=== ISSUE 2 ===
The breadcrumb was clipped on Firefox, letters such as "p", "j" or "y"
where partially hidden. This was due to the combination of a too small
line-height and the `overflow: hidden` applied on `breadcrumb-item > a`.
This commit fixes these issues.
task-3420194
Part of task-3326263
closesodoo/odoo#128582
X-original-commit: abbbaee7bd591285cef98275da931fd8a8f073cd
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Prior this commit, `.o_arrow_button`'s arrow didn't have the same
transition as the button itself which created a glitch on hover
task-3419220
part of task-3326263
closesodoo/odoo#128581
X-original-commit: 81adc9a1769171a8f1c3e59e0841186904fc7ebd
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Before this commit the `mail.shortcut` search view was
only available when installing `website_livechat_helpdesk`.
This search view focuses on classical `mail.shortcut` field
and could be used accross the different modules that use
this view.
This commit moves the search view to the mail module in order
to do so.
closesodoo/odoo#128120
Related: odoo/enterprise#43976
Related: odoo/upgrade#4925
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Steps to reproduce:
- Install website_sale, contact, l10n_ch
- make sure your company is in Switzerland and has all the address information
- in settings, activate QR
- in Accounting/Journals/Bank:add a bank account (iban: CH4431999123000889012; qr-iban: CH11 3000 5228 1308 3501 F)
- install and enable the provider "Wire Transfer"
- From the Website, create an order and make sure the customer set an Invoicing address in Switzerland (address + Country)
- Validate the order
- In Website/unpaid orders: select your order and Confirm the order
- Create and confirm the invoice
- Print the invoice
Issue:
User Error is raised
Cause:
With Swiss QR code you need to have a valid payment reference. That is, an ISR reference such as in
https://github.com/odoo/odoo/blob/c6631df1c5b0b6d4c2268a826ca150edd0ca653e/addons/l10n_ch/models/account_invoice.py#L90
But when you create an order from the website, it creates an automatic reference "SO0001" which, when converted to an invoice, stays the same.
Since the reference is prepoluted, the `_compute_l10n_ch_isr_number` will not be triggered and therefore will raise an error when trying to print the invoice.
Solution:
Check if the Customer Invoice Journal uses the swiss reference model, then we know that the swiss loca is installed and can call the correct function to compute the reference/
Note:
In the test we check that `payment_custom` is installed. It is because the `_set_pending` method checks taht the payment_provider.code is "custom"="wire_transfer" in which case the sale order reference is computed
https://github.com/odoo/odoo/blob/b4ed9537895ecee48ed146add4257af0aebeb3f4/addons/sale/models/payment_transaction.py#L54-L56
opw-3334534
closesodoo/odoo#127338
X-original-commit: dfa4844e57b67d16b181e1e58813cdbbc7efa956
Signed-off-by: Yolann Sabaux (yosa) <yosa@odoo.com>
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
Co-authored-by: flvr-odoo <flvr@odoo.com>
* Generate account payments (and require a journal)
* Be displayed as their custom mode instead of always 'Custom'
...
Commit also includes some side bugfixes/cleanup
task-3347338
closesodoo/odoo#126929
Related: odoo/enterprise#43418
Related: odoo/upgrade#4944
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
This commit's purpose is to allow the user to set the company_id of a project to False, meaning the project is no longer restricted for the user who does not have access to the company of the project. This change induces a lot of other small behavior changes/approximation. Since some fields (currency_id, resource_calendar_id, etc) were company dependent, we had to updates some use cases.
task-3084819
closesodoo/odoo#122144
Related: odoo/enterprise#41363
Related: odoo/upgrade#4947
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
5 new mail templates have been created :
2 designed templates ("Graphic" (now "Training") and "Coffeebreak")
3 text-heavy templates
XML added in mass_mailing_themes/views/mass_mailing_themes_templates.xml
Images added in mass_mailing_themes/static/src/img
Some templates names were adapted :
Newsletter -> Event
Tech -> Blogging
VIP -> Coupon
Bold -> Magazine
Solar -> Promotion
Task-2714386
closesodoo/odoo#99311
Related: odoo/upgrade#4035
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Co-authored-by: Elisabeth Dickinson <edi@odoo.com>
Add 'training' theme, which is absolutely not something to use to train
yourself writing themes, but actually to sell trainings, like software
trainings to learn to write themes.
Task-2714386
Part-of: odoo/odoo#99311
Add a 'newsletter' theme that contains notably a photo of Fgi and Al, which
is probably the best motivational to use it.
Task-2714386
Part-of: odoo/odoo#99311
Some mail themes had to be renamed to fix inconsistencies and prepare future
changes
* Newsletter -> Event
* Tech -> Blogging
* VIP -> Coupon
* Bold -> Magazine
* Solar -> Promotion
Also bump version, as new themes imply quite a bit change for this module.
Task-2714386
Part-of: odoo/odoo#99311
Before this commit:
When returning a transfer in AVCO/FIFO, the return's value is not always
the same as the original delivery. The unit cost for the return was
rounded, which introduced rounding errors.
After this commit:
When returning a transfer in AVCO/FIFO, the return's unit cost is not
rounded, allowing the correct value to be set.
Steps to reproduce:
1. Create a product and change its category costing method to AVCO
2. Purchase the product qty: 1 price: 13.13
3. Purchase the product qty: 1 price: 12.20
4. Sell the 2 product and deliver it
5. Create a return for the delivery
6. The value on the delivery is 25.33, but 25.34 on the return
opw-3358531
closesodoo/odoo#129025
X-original-commit: 5043b4b5099dc395234c1d5d8422b8fa7f1d94c8
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
When the user adds the "Title" or "Certificate" in a large number of
characters, the content goes beyond the window.
Technical:
By using this class it applies width 100%, which resolves the issue.
Now, the content stays within the sheet.
Task-3368902
closesodoo/odoo#129014
X-original-commit: 44720aa6e7080ce849af329d8c92681489e093fb
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
In a sale order, an error is raised when selecting a product
(`product.template`) that has an archived variant if the product has a
single active attribute
Steps to reproduce:
1. Install Sales
2. Create a new product 'TEST'
3. Add the attribute 'Legs' with values 'Steel' and 'Aluminium'
4. Create a new sale order for any customer with product 'TEST' and
variant 'Steel' and confirm it
5. Open the form of product 'TEST', remove the attribute 'Legs' and add
the attribute 'Color' with values 'White' and 'Black'
6. Create a new sale order and try to add the product 'TEST', an error
is raised
Solution:
Exclude `product.template.attribute.value` from the ptavList only if it
is present in the ptavList
Problem:
If a product has an archived variant that uses the same attributes than
an existing active variants except one, we will try to exclude the
different attribute but because it has been archived, it is not present
and cannot be excluded.
opw-3420616
closesodoo/odoo#129012
X-original-commit: 907aba0f54f65788c78c1370a573fbe9b69be8c5
Signed-off-by: Guillaume Merlin (megu) <megu@odoo.com>
Bug
===
Since 69f911d994 , the body needs to be a
Markup object if we don't want to escape it. So, when we log an email
from the mail plugin, because we just log the string, it gets escaped.
Task-3387100
closesodoo/odoo#128984
X-original-commit: ef068b3b0d7df9f2e064889c62623b34f31e156b
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Previously, users could not cancel/delete their order once it had begun.
Only order lines not sent to the server could be deleted one by one.
Now, a "cancel" button has been added to the self shopping cart screen.
This button only appears when the order has not yet been sent to the
server. If the order has already been sent, it can only be cancelled
from a PoS.
closesodoo/odoo#128044
Signed-off-by: Adrien Guilliams (adgu) <adgu@odoo.com>
This commit makes hotkey uses more coherent throughout the entire
codebase by setting alt+q as main shortcurt for confirm and default
actions and alt+x for cancel actions.
task-3370463
closesodoo/odoo#127469
Related: odoo/enterprise#43694
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
* = crm,hr_work_entry_holidays
This commit changes the value of the "QueryCount" as `mail_enterprise`
executes a new query to search for devices associated with the partner.
Task ID: 3123678
closesodoo/odoo#127198
Related: odoo/enterprise#43577
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
This commit allows the domain field to become foldable such that it will
display its domain in the form of facets (similar to the search bar's
ones) when it is folded. Also applies this functionality directly to the
mass_mailing form view.
task-3339512
closesodoo/odoo#126789
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
Better tag selection
====================
The block was originally hooked onto the `external` tag under the
assumption that this was the tag used to allow external requests.
It's not, it's the tag for the "external" test suite, which is only
one of the test suites allowed to perform external calls. Hook again
onto `standard`, this might have some false positives (allow requests
which we'd rather block), but it should have a lot less false
negatives (block requests we want to allow).
Make Overrides Easier
=====================
Currently `_request_handler` raises a regular `ConnectionError`, this
is an issue because it passes some requests through, which could
themselves trigger genuine `ConnectionError`.
When overriding `_request_handler` to implement fallbacks for bespoke
URL mocks, these two cases need to be distinguishable as overrides
likely want to handle blocked requests, not actual failures.
Therefore `_request_handler` should a dedicated exception. This
exception should be a subclass of `ConnectionError`, so that blocked
requests are treated as regular connection failures by normal Odoo
code.
Class-scope
===========
Originally `_request_handler` was scoped on the instance with the idea
that it'd be a `mock` object, which individual tests could
`configure_mock`. This turned out not to work correctly, because
`Mock.side_effect` does not receive a `self`, hence the `Session` was
inaccessible and it was not possible to passthrough local requests.
While I moved to a regular `lambda` (because a direct method didn't
work either), I forgot to remove the `request_mock` attribute, and
didn't think that the block could now be lifted up to the class
scope. Doing this, requests performed during a "standard" test case's
`setUpClass` are now also blocked, which they very much should be.
closesodoo/odoo#128977
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
The goal of this commit is to prepare ground to remove
lazytranslate function _lt() and keep only _t()
for a better understanding of the use of the translation function.
In this commit,
the translate function _t() has been updated to return the translation
if they are loaded. If not, it throws an error.
the lazytranslate function _lt() returns _t() function.
Corollaries :
Steps in test tours are now a function that returns an array of steps
to avoid any interpolation of _t in this ones before translations has
been loaded.
Example :
registry.category("web_tour.tours").add("example", {
test: true,
steps: () => [
{...},
{...},
],
});
task-3292454
closesodoo/odoo#124157
Related: odoo/enterprise#43153
Signed-off-by: Samuel Degueldre (sad) <sad@odoo.com>
The Reserve Bank of India (RBI) issued a directive (amended subsequently
in December 2020 and March 2021) that introduces additional security
measures for recurring payments on India-issued cards. These measures
include:
- Banks must register cardholders and create an e-mandate through a
one-time process, using additional factor authentication (AFA)
like 3D Secure (3DS).
- Banks must alert cardholders at least 24 hours before charges take
place and give them the ability to opt out of transactions.
- Recurring transactions over 15,000 INR (or equivalent in other
currencies) must go through AFA each time.
Stripe has worked with a partner platform to support that, but we must
manipulate the PaymentIntent and SetupIntent objects directly through
their dedicated API, which the Checkout API does not allow. Therefore,
we must now integrate with the Elements API and implement a direct
payment flow instead of the current payment with a redirection flow
powered by the Checkout API.
After this commit, Stripe will create an e-Mandate for every
Indian-based card newly saved in Odoo.
task-3322020
closesodoo/odoo#123573
Related: odoo/documentation#4719
Related: odoo/upgrade#4748
Related: odoo/enterprise#42196
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
When the loader takes a long time before having a website ready to be
shown (due to many features selected), it is confusing for users who
think the page stopped working. They tend to refresh the page, provoking
bugs. To improve the UX, this commit adds:
- a browser warning to prevent the user from closing the tab/refreshing
- several waiting sentences, depending on the features chosen by the
user (the screen switches between them every 10 seconds)
- a loading bar whose progression shows the number of installed modules
- a solid background instead of a transparent one as there is no value
in seeing the preceding background at that point
This commit also removes the secondary loader, once the website has been
created, to avoid the bad UX of having one long loading, then a refresh,
then another loading with the same look.
task-3100223
closesodoo/odoo#118525
Signed-off-by: Soukéina Bojabza (sobo) <sobo@odoo.com>
*: web_tour, website
When no transformation is applied on an image, changing the quality
sometimes increases its storage size.
This commit makes sure that the original image remains used if only the
image quality is modified and if this makes its storage size bigger.
Fixes#61619
task-2835144
closesodoo/odoo#103398
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
This commit extracts the calculation of the number of bytes within a
base64 data URL to a method named `getDataURLBinarySize`.
task-2835144
Part-of: odoo/odoo#103398
With ab4f45b, the domain validation done
on confirmation in the domain selector dialog was removed. Now that we
have a new route /web/domain/validate (see previous commit) that allows
us to quickly check the validity of a domain, we can reintroduce the
validation.
closesodoo/odoo#128913
X-original-commit: fa7788fac3c48e95dcbe78abb66ac5c284d27c56
Related: odoo/enterprise#44291
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
When a domain field value is edited via the debug textarea, no
search_count is done for performance reasons. A single exception is done
when saving the record. Then we check the validity of the domain created
in the debug textarea in order to avoid to save an invalid domain in db
(and get tracebacks,..). The problem is that a search_count can take a
very long time to be executed if the domain is valid. Here we introduce
a route /web/domain/validate in order to quickly check the validity of a
domain and use it in domain field in order to fix the above mentionned
performance issue. Note that the search_count is still done if it useful
but does not have to be waited anymore.
X-original-commit: 40288221c39ff8fba41cd6ac231ab33600dc0cd4
Part-of: odoo/odoo#128913
Co-authored-by: Oliver Dony <odo@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Currently, users cannot deregister from Peppol.
There is an option to migrate away (i.e. request a migration key) but not every provider supports migration.
It is not straightforward to deregister from Peppol once a participant is marked as "prepared for migration",
so the users really should deregister instead.
Also, it is important to run the cron one last time for the user to fetch new documents/message status updates
they've received since the last time the cron ran.
closesodoo/odoo#128867
Signed-off-by: Laurent Smet (las) <las@odoo.com>
Step to produce:
=================
- Create MO of serial tracking product.
- Start workorder.
- Click on continue consumption button.
- Enter quantity to consume then click on validate button.
- Then when we click on Continue button quantity become zero or negative.
Issue:
========
If the product tracking is serial and quantity is already set to 1 in this case
it write the same 1 value in serial tracking order because of that it calls
'_update_component_quantity' method again it will make the quantity zero.
After this commit:
=====================
Prevent the quantity becoming zero.
Task id: 3212121
closesodoo/odoo#128665
X-original-commit: 907129be7efba2a0b68f9bef14c6a22c1be8861a
Related: odoo/enterprise#44183
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
The goal of this PR is to remove all dependency to legacy assets in the wysiwyg because the wysiwyg is loaded on a lot of form view through the html_field, thus defeating the purpose of the legacy assets being lazy loaded.
To remove the dependencies, all the legacy widget that the wysiwyg uses had to
be converted to owl. In order to finish the PR faster, only a partial conversion
of the widgets is done, changing only the part of the code that was necessary
for it to work instead of rewriting the whole widget from scratch. Another pass
should be done to convert all those widgets to fully embrace the owl paradigm.
task-3175256
closesodoo/odoo#118966
Related: odoo/upgrade#4750
Related: odoo/enterprise#42141
Signed-off-by: Geelen Sébastien (sge) <sge@odoo.com>
The goal of this commit is to remove all dependency to legacy in the
wysiwyg because the wysiwyg has to be loaded on a lot of form view
(through the html_field).
To remove the dependencies, all the legacy widget that the wysiwyg
uses had to be converted to owl. In order to finish the PR faster,
only a partial conversion of the widgets is done, changing only the
part of the code that was necessary for it to work instead of
rewriting the whole widget from scratch. Another pass should be done
to convert all those widgets to fully embrace the owl paradigm.
task-3175256
Part-of: odoo/odoo#118966
In a subsequent commit, the ImageCropWidget will be converted into
an Owl component called ImageCrop. To match the new name, this commit
rename the file.
task-3175256
Part-of: odoo/odoo#118966
In order to match the filename with the only classname of that file,
this commit rename `wysiwyg.js` to `MassMailingWysiwyg.js`.
task-3175256
Part-of: odoo/odoo#118966
Before this commit, when recurring meeting were created with alarms, there were
as many cron trigger created as there were events in the recurrence.
After this commit, only one trigger is created for the first event starting in the
future and the next cron trigger is created once the trigger of the first event is
called by the cron.
closesodoo/odoo#118738
Taskid: 3270442
Related: odoo/upgrade#4706
Signed-off-by: Arnaud Joset (arj) <arj@odoo.com>
Before this commit, when a ir.cron was walling _trigger, the ir.cron.trigger
records were not returned. it would prevent to use them later easily without
making a search.
Taskid: 3270442
Part-of: odoo/odoo#118738
Before this commit: Body content is the same as tmeplate
After: Body content is the same as the template
*: hr_recruitement, sale, survey, website_slides
closesodoo/odoo#128953
X-original-commit: 388e340a52fd5775c1702f8952a1e959fa5cef48
Related: odoo/enterprise#44309
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
To reproduce:
1. Create a new mail group with privacy "Everyone"
(menu: Website / Configuration / Mailing Lists / Mailing Lists)
2. As an anonymous user, go to /groups and click on its name
3. A 403 Forbidden error is displayed:
`You are not allowed to access 'Email Aliases' (mail.alias) records.`
This commit is a followup of odoo/odoo@cd2f330bec where global
mail.alias access rights were revoked, so we have to check if alias
is valid as superuser.
closesodoo/odoo#128915
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Before this commit, only the cross icon "x" top right of the popup would
be able to properly close the popup and set a cookie to prevent that
popup to open again later.
There is no way through the UI to make a button in the popup do the same
behavior.
This commit now add this behavior to any `.btn-primary` element inside
the popup, except a few ones like the newsletter input group button and
the website form submit one.
Note that we have a way in stable to do that, but it's through code.
People have to add the `js_close_popup` class to the button. This class
is there for this reason, but it's obviously limited to tech people
only or our support.
task-3377306
opw-3328135
closesodoo/odoo#124432
Signed-off-by: Arthur Detroux (ard) <ard@odoo.com>
**Description of the issue/feature this PR addresses:**
- Increase user experience in creating website themes
- Eliminate redundant creation of 1 record leading to unnecessary model
`ir_model_data` contraints error
**Recreate the Situation**
- Install the website module
- Choose `a business website` in line 1, `fashion designer` in line 2,
`get lead` in line 3 on `configurator - step 2`
- Choose random paletee on `configurator - step 3`
- `Build my website` on `configurator - step 4`
- Suppose in this step that we have a bad connection to the api
`https://website.api.odoo.com`, the error `duplicate key value violates
unique constraint` will appear.
**Reason**
- When a user creates a website, the `configurator_apply` function is
called to the api `https://website.api.odoo.com`. If the connection time
exceeds 5s, the `configurator_apply` function will be called again.
Maximum of 3 times
- Each time `configurator_apply` function runs, will create records of
model `ir_model_data` at `set_images` function. This function will
create records with a name field like
`configurator_1_s_cover_default_image`.
- If this function runs again for the second time, it will also generate
a `configurator_1_s_cover_default_image` for the second time. This will
result in a `duplicate key value violates unique constraint` error.
**Before commit:**
- When creating a website theme by industry, if the user's connection to
odoo's api has a delay, it will cause an api contraints error of model
`ir_model_data`
**After commit:**
- Check if the record of model `ir_model_data` has been created before,
if created then skip
closesodoo/odoo#128959
X-original-commit: 56ccf4efeb946e2e0b6ef54b977b6d8b070306ee
Signed-off-by: Benoit Socias (bso) <bso@odoo.com>
In Switzerland, states are really important. Each state has its rules, its
language, its culture, its parliament, etc. It's quite frowned upon to send an
invoice/offer or even to have backend management using German terms when we're
in a very French-speaking state.
So in this PR, we will add states in the missing languages
closesodoo/odoo#128954
Task: 3268058
X-original-commit: f309fd06cd46a767fee742ec9f634b46a2edf70f
Signed-off-by: John Laterre (jol) <jol@odoo.com>
Before this commit, livechats in mobile were shown in the "Chat"
tab in both discuss app and messaging menu. This is alright, but
there's a dedicated tab for "Livechat", which was empty as a result.
The intended showing in mobile is to keep livechat away from "Chat",
and instead populate the "Livechat" filter.
Task-3430253
closesodoo/odoo#128934
X-original-commit: cf4b72582bbb52c7cd4bc17733f4dbbc84f9b321
Signed-off-by: Matthieu Stockbauer (tsm) <tsm@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>