When a dialog is closed, the focus is meant to be restored to the
previous focused element.
Before this commit, it did not work for the ConfirmationDialog when the
confirm button was clicked. This was because the focus was lost **before**
the dialog was closed (because the confirm button is disabled when
clicked), and thus the previous focused element was not in the el of the
dialog anymore, and thus the focus was not restored.
closesodoo/odoo#134456
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Commit 80f8281 introduced an unwanted padding on the right in
`o_list_selection_box` on large screen.
This commit adapts the spacing of this element to maintain the same
rendering whatever the screen size.
task-3454841
closesodoo/odoo#134384
X-original-commit: ed29d31ab7bb8d697c6515f3383a8b687f486e8e
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Before this commit, the useragent was harcoded as an Odoo one and if it was
blacklisted by the osmfoundation policy https://operations.osmfoundation.org/policies/nominatim/
all Odoo instances were forbidden to access the service.
This parameter allows to override the user agent with a system parameter.
closesodoo/odoo#134376
X-original-commit: 160e8bfbf72a3e5d7cc8d8cbe7bc4f310f298baa
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: Arnaud Joset (arj) <arj@odoo.com>
Since https://github.com/odoo/odoo/pull/122085, on the sale
order form (with website_sale installed), changing the "Customer"
changes the "Invoice Address" & "Delivery Address". But the latter
are displayed with the partner name, but also with the full
partner address. This last information makes the form uglier than
before and are useless.
The old `display_name` of `res.partner` was stored in the DB and
did not depend on the context. Also, onchange calls add the
context of the source field (the one being changed). In this case,
`'show_address': 1` is added, and then `display_name` of
`partner_invoice_id`/`partner_shipping_id` is also read with this
context.
We cannot easily fix this in saas16-4 because it was not possible
to change the read context of a particular field. With the new
specification of onchange, we can override the read context on a
particular field.
closesodoo/odoo#134304
Signed-off-by: Raphael Collet <rco@odoo.com>
Before this commit:
===================
In the back-end, there is only one field "date_order" is used, while on the
frontend side, there are two separate fields: "creation_date" and
"validation_date," which causes confusion in the code flow and leads to
redundancies.
After this commit:
==================
Revised the order date flow by eliminating the confusion stemming from the
separate "creation_date" and "validation_date" fields. Both have been
consolidated into the "date_order" field, offering clarity to the order date
process.
task - 3482072
closesodoo/odoo#133293
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
When sending an bill to sii services, the registration
date is set as today, instead of the accounting date.
This is because the registration date is automatically
set to today when sending the bill.
With this commit, we add registration_date field
to teh account_move view in other infos tab, to allow
the user to manually set it.
Steps:
- Install l10n_es_edi_sii
- Set a tax agency in Accounting > Configuration > Settings
- Create a bill, with date and accounting date in the past
- Confirm and send to sii services
-> In the file, 'FechaRegContable' is set to today
opw-3478079
closesodoo/odoo#134370
X-original-commit: 325857efcfc8060666b3860ae61c5321baab5462
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Guillaume Vanleynseele (guva) <guva@odoo.com>
New module is created (`l10n_it_edi_pa`) to add fields that are required to handle Split Payment, and it will be merged in master.
- `l10n_it_origin_document_type`
- `l10n_it_origin_document_date`
- `l10n_it_origin_document_name`
- `l10n_it_cup`
- `l10n_it_cig`
These fields are required to track money used that comes from funding to the Public Administration business for purchases, be it ordinary or project based spending.
They also need to be exported in XML during the EDI phase, in different
XML nodes depending on the `l10n_it_origin_document_type` field
ref: https://fex-app.com/FatturaElettronica/FatturaElettronicaBody/DatiGenerali/DatiOrdineAcquisto
Task link: https://www.odoo.com/web#id=2823645&model=project.task
task-2823645
X-original-commit: e07fb2503f28af1f23ef74efec6741f9623ce401
Part-of: odoo/odoo#134348
When an Italian company bills a PA business (for example they're selling cleaning services for a public building) the PA business will send the VAT to the Tax Agency themselves, while generally the VAT is collected and sent to the Tax Agency by the buyer (the PA business). This is done to avoid VAT fraud as the PA doesn't trust the business will actually pay the VAT. That's very common in Italy.
A new module will be created (`l10n_it_edi_pa`) in the next commit to add fields that are required to handle Split Payment, and it will be merged in master.
- New Split Payment related accounts are created: 2607, 2608
- New tax report data to target the VE tax chart grid
- Split Payment account.taxes are Groups of Taxes whose children target VE38 tax grid
- account_tax's l10n_it_vat_due_date is no more, we base ourselves on the VE38 tax grid
- The Group of Taxes includes normal VAT and a reversed VAT entry (for sale)
- Tax checks on the invoice now also check group of taxes with flatten_taxes_hierarchy()
- New Split Payment tax group has been added to build the correct totals in the move form view
- account.taxes and account.fiscal.position has been added to change from VAT to VAT Split Payment automatically when you select a res.partner that features the fiscal position.
- The Fiscal Position also has the law-required note that has to be featured on invoices that use Split Payment
- A PA business demo partner is added to showcase the new fiscal position
- `l10n_it_stock_ddt` tests are minimally modified because the Form component didn't let you use 'like' in the move form view
Task link: https://www.odoo.com/web#id=2823645&model=project.task
task-2823645
X-original-commit: 90d9250c66d59184a795041b8f1b7849c3b6db5f
Part-of: odoo/odoo#134348
Steps to reproduce the issue:
- Go to the To-do app
- Open a task and try to convert it to a task
- Look for P
Bug:
P was not suggested
opw:3478943
X-original-commit: e0e3d35c7f53b9a87de366bf2cca96c1ca3be960
Part-of: odoo/odoo#134346
This commit allows you to change the title of the social media block
after the first save. If an element is in a parent that has the class
`o_not_editable` then it is only editable if it has the contenteditable
attribute set to true. We rightfully remove this attribute at saving but
without putting it back when we return to edit mode. This commit allows
to fix this case. Note that we have to improve this system in the future
(so we can get rid of this patch).
This part of the fix is very similar to [this other fix] for the team
block.
[this other fix]: https://github.com/odoo/odoo/commit/b7d53d2fcb20a447fd3098adf94ffb33bc49dda9
task-3073171
closesodoo/odoo#134281
Part-of: odoo/odoo#105964
X-original-commit: 44b0bcbdd67721e3b45567d26da00e4a3910f541
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
Signed-off-by: Guillaume Dieleman (gdi) <gdi@odoo.com>
This commit allows you to change the icons of custom links of the social
media block after the first save. Thanks to [this other commit], there
is now a class that permits to inform the editor that a media is
editable even if it is a non-editable parent. This commit permits to use
the new class to fix the issue.
Steps to reproduce the bug:
- Drop a social media block on a page
- Add a custom social media
- Save
- Edit
- Try to change the icon of the custom social media with a double-click
=> The icon cannot be changed.
Note that [another commit] had already been made and fixed the problem
halfway (the icon change didn't work on double-click). This commit
reverts it and fixes the problem correctly with the new system.
[this other commit]: https://github.com/odoo/odoo/commit/6ead397f33512c918f51feb2b32fb3e15ffedf34
[another commit]: https://github.com/odoo/odoo/commit/bb291b35e46e42ca098aa3e04ac0b473f72be423
Fixes https://github.com/odoo/odoo/issues/104048
task-3073171
X-original-commit: b844351b9814ff2167d2183ab3216e2d1ec1d216
Part-of: odoo/odoo#134281
Before this commit, creating a new allocation based on accruals
and setting a start date prior to the creation date would compute
the amount of days that should already have been accrued during that time.
However, the lastcall field is not updated and running the accrual cron
leads to a wrong duration.
How to recreate the issue:
- create an accrual plan
- create an allocation set on that accrual
- set a start date in the past for that allocation
- the duration should be automatically set to a value above 0
- save and validate
- run the accrual cron
- the allocation now has its duration doubled
After this commit, the lastcall should be set to the allocation creation
date. This way, running the cron will correctly keep the value of the amount
of days.
closesodoo/odoo#134251
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Before this commit, sometimes this test crash with the following log
on runbot:
```
Trying to set result to failed (None) but found the future settled (<Future at 0x7fdd859df910 state=finished returned bool>)
```
This problem usually happens when some RPCs are triggered after the
end of the test. This test on livechat support page is small and just
checks that there are no issues in loading JS modules. We do not care
on RPCs triggered from auto-opening of livechat that may result to
this error on runbot.
This commit disables console logging after the test, so that it won't
fail if it passes the check on loading JS files.
closesodoo/odoo#134234
Related: odoo/enterprise#46849
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
odoo/enterprise#46143
Before this commit, messages of type email were not rendered properly in the chatter. For example, the email may display text with dark color even when in dark theme or the layout of bootstrap elements like btn might not look correct.
These style issues are caused by combining the style in content of the email (e.g. inline styles) with the style of the webclient, giving the impression that the original visual of the email is buggy.
This commit fixes the issue by showing a slightly transformed style of email messages in chatter that is readable and looks nice with the Odoo theme at hand. In particular with dark theme, the background color matches the bubble color and the text is white.
Sometimes the exact visual of the original email is desired. A button "Show Original Email" in the top-right corner of the message bubble allows seeing the visual of email in its original intention.
Task-3437069
Forward-port-of: #133545
Forward-port-of: #131202
Part-of: odoo/odoo#134234
Using the POS app, one can buy a combo consisting of multiple products.
In this PR we implement this functionality in the `pos_self_order`.
A user can now navigate to a combo product, select each combo choice
and order the desired combo directly from the `pos_self_order` app.
In this commit we also change the values displayed in the orderlines
of the `pos_self_order`, such that they better reflect the values
that would be shown by the POS for the same respective orderlines.
Ex: when buying 5 units of an item that has unit price 138.58, the
POS ( and also the invoicing app, etc ) would display a total price
of 692.88. The self order now does the same, but before it was showing
692.90 for the same situation.
closesodoo/odoo#134169
Task: 3437447
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
In the frontend of project, the bus service is not available.
Since #129785, the test `portal_project_sharing_tour` crash
because `this.busService` is `undefined` when we try to access
it in `Wysiwyg.setupCollaboration`.
task-3434068
closesodoo/odoo#133477
Related: odoo/enterprise#46479
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
In website, there is a patch of the LinkDialog (see
website/static/src/js/editor/editor.js) that require the utils.js.
Thus, when website is installed, this bundle need to have the utils.js
in its assets otherwise there will be an unmet dependency.
task-3434068
X-original-commit: 9bbb43c6be24ce8cd46e78b292779d3915cffd3e
Part-of: odoo/odoo#133477
Since #118966, the `web_editor.assets_wysiwyg` assets are not lazy
loaded anymore and therefore need to be included in
`project.webclient`.
task-3434068
X-original-commit: 10d50d6b02b3c9ad43cf54c9580b901f7e92dfa8
Part-of: odoo/odoo#133477
This commit ensures that when the user opens a calendar view in day or
week mode the view will be scrolled so that 6am is at the top of the view.
task-3460517
closesodoo/odoo#132288
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
The goal of this task is to help user manage their sale_order
by having a summary view of all their next activities.
Sale calendar view is now based on the next activity for each
sale_order.
closesodoo/odoo#132287
Task-id: 3463325
Related: odoo/enterprise#45945
Signed-off-by: Arnaud Joset (arj) <arj@odoo.com>
before this commit, in resume we are able to put end date less than start date
which is not possible in real life.
inside form view add daterange widget to start date field so user not able to
select end date less than start date. switch the position of Display Type and
Certification or Course field to show the additional field below the Display
type when Display type is selected.
task-3397726
closesodoo/odoo#128269
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
When having a payment terms with several lines,
the payment term lines are not displayed when
printing the invoice if this one has been
partially paid.
opw-3482256
closesodoo/odoo#134343
X-original-commit: 26a63a94fe167944fc24de2191c9abb2f502219a
Signed-off-by: de Wouters de Bouchout Jean-Benoît (jbw) <jbw@odoo.com>
Signed-off-by: Guillaume Vanleynseele (guva) <guva@odoo.com>
When having an attachment to the qr-bill report,
an error is raised when printing the report:
"the report's template does not contains the
attributes 'data-oe-model' and 'data-oe-id' on
the div with 'article' classname."
Steps:
- With a Swiss company
- Activate QR code on customer invoices
- Go to Settings>Technical>Reports and select QR-bill
- In Advanced Properties tab, set an attachment
- Create an invoice for a swiss customer, confirm
and print the QR-bill
-> Error
We this commit, we simply add oe-data-model and
oe-data-id to the div with the article class
in the template, as indicated in the error message.
opw-3480179
closesodoo/odoo#134337
X-original-commit: 55aea3e851c61e1ad138937c1d40372f7ba7cf26
Signed-off-by: Laurent Smet (las) <las@odoo.com>
Signed-off-by: Guillaume Vanleynseele (guva) <guva@odoo.com>
This commit change the name of the option noReload to reload, this is to
avoid having negative variables names for boolean. This is a general
known best practice, and in this case it's important to have a better
readability of the code (specially when a negation of a negative
variable occurs).
closesodoo/odoo#134317
Related: odoo/enterprise#46913
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Steps to reproduce:
- set a tax lock date
- create a new move
- set the accounting date prior to the tax lock date
- set an invoice_line with a tax
Issue:
The banner teeling you information about the tax lock date won't appear unless the move is created.
opw-3370727
closesodoo/odoo#134388
X-original-commit: d67aa6a798d9f7359549bbf56ec6fa2913f930ec
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Yolann Sabaux (yosa) <yosa@odoo.com>
Currently when the pos.config is set to "Skip Preview", when printing a
receipt, the receipt or bill screen shows very quickly and disappears.
This is not good UX.
Now, the receipt is printed from the payment screen itself. We don't
need to show the receipt screen at all.
closesodoo/odoo#132550
Taskid: 3441238
Related: odoo/enterprise#46187
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
- Add the registration answers of the attendee in the registration
summary.
- Add a mobile kanban view for answers on the attendee form to
make them more visible.
task-3491881
closesodoo/odoo#134404
X-original-commit: 35ed7ccfd24ea31df86f9c863e75f1cb0fb77f0d
Related: odoo/enterprise#46957
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Signed-off-by: Jérémy Hennecart (jeh) <jeh@odoo.com>
In the portal view of tasks, we set a default groupby in _prepare_task_values to project.
However, since this method is called every time we change the groupby, it is effectively
impossible to group by anything other than project.
This commit fixes this so that it is possible to select other groupbys.
Task-3438490
closesodoo/odoo#134378
X-original-commit: 02629788f24efb4646703cf94f1a8c603179e185
Related: odoo/enterprise#46945
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
When viewing an individual project in the portal, despite there being a single project,
we still want to group by project when that project has shared documents, so that the
"Documents" button is displayed.
This commit adds a method meant to be overriden in documents_project so that behavior can
be readded for project with shared documents only.
Task-3438490
X-original-commit: b8e68f35fe151d59bd60510ccd3a43c0a92e1190
Part-of: odoo/odoo#134378
Steps to reproduce:
- Create a PO (fifo automated product)
- Recieve product
- Create the bill and add the landed cost product to it
- Create the landed cost before posting the bill
- Post the bill
Bug:
when creating the landed costs if the bill is already posted
the created amls are reconciled otherwise they aren't
Fix:
reconcile the landed costs amls after posting the bill
opw-3377088
closesodoo/odoo#134349
X-original-commit: 233699522c48dce9b541a79db756cc478ed71592
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Walid Hanniche (waha) <waha@odoo.com>
Before this commit:
* A delete at the end of an empty block just before a table (unbreakable), nothing happened.
After this commit:
* A delete at the end of an empty block just before an unbreakable block, the empty paragraph should be removed and the selection put at the beginning of the unbreakable block.
task-3186679
task-3252775
closesodoo/odoo#125211closesodoo/odoo#134327
X-original-commit: 70a03c931438fd549d167deb9ad500f3fc8b6024
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
Signed-off-by: Geelen Sébastien (sge) <sge@odoo.com>
Before this commit:
* A backspace at the beginning of a List Item (LI), the indentation of the list item was reduced by 1 unit.
If not possible, the current LI was merge with the previous LI.
* A delete at the end of a LI, first we remove one unit of indentation from the next LI,
only when not possible anymore we merge next LI in the current LI.
After this commit:
* A backspace at the beginning toggle off the current LI ( the LI tag is remove and popped out of the List )
The parent List is splitted if needed.
* A delete at the end of a LI directly merge next element inside the current LI.
task-3186679
X-original-commit: b177c29ee0df8c7edf72b177c59c5dff6bd0d270
Part-of: odoo/odoo#134327
Co-authored-by: Aashish Thakur <aath@odoo.com>
Before this commit:
On backspace current node is removed and it's content were moved to it's
preceding node.
After this commit:
Now keeping the current node it removes preceding node if empty and if not empty
then merge current node to previous node.
Task-2909314
task-3186679
X-original-commit: bca7f0455ce56268a592c924ac22f9f2dc6541db
Part-of: odoo/odoo#134327
Co-authored-by: Sanjay Sharma <shsa@odoo.com>
Before this commit, static methods on discuss models like `.get()`
or `.new()` where not properly documented.
The superclass `Record` documents `@returns`, but jsdoc failed to
deduce these static methods return subclass instances. We tried to
find a way to define things once in `Record` and let typedoc deduce
things automatically without overriding in each models just for the
sake of type. However typedoc still sucks in 2023 despite requests
for improvements to support this specific case since 2016, 7 years
ago.
This commit fixes the issue by overriding static method in all discuss
models so that the `@returns` is properly documented.
closesodoo/odoo#134316
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Previously before the bootstrap refactoring the skip line color was
`#7F82AC` which is a dark purple. After the refactoring the color was
changed to `text-secondary` color which is a light gray.
This commit changes the color to `#7F82AC` again to keep the same
behavior as before the refactoring.
closesodoo/odoo#134305
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Before this commit, trying to delete a recurrent event that was already synced with Google Calendar or Microsoft Calendar was raising a traceback and not showing the User Error which forbids this action to be done.
After this commit, the traceback is not shown anymore and the User Error is correctly presented to the user while trying to delete a recurrent event (with Microsoft synchronization active).
Traceback snippet:
result = _call_kw_multi(method, model, args, kwargs)
File '/data/build/odoo/odoo/api.py', line 448, in _call_kw_multi
result = method(recs, *args, **kwargs)
File '/data/build/odoo/addons/microsoft_calendar/models/calendar.py', line 168, in action_mass_archive
if self._check_microsoft_sync_status() and any(self.microsoft_id):
TypeError: 'bool' object is not iterable
The above server error caused the following client error:
RPC_ERROR: Odoo Server Error
closesodoo/odoo#134293
Issue: 3468190
Task-id: 3473180
Signed-off-by: Arnaud Joset (arj) <arj@odoo.com>
Signed-off-by: Gabriel de Paula Felix (gdpf) <gdpf@odoo.com>
Before this commit, calling `record.delete` twice would
result in a crash. This is due to `this.Model`being cleared
once the delete is done. This commit skips the deletion if
it was already done: calling delete will result in the desired
state anyway.
This can be easily reproduced:
- Throttle your network
- Send a message on the discuss app
- A crash occurs
closesodoo/odoo#134254
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
For mysterious or logical reasons, the test classes inherit
the test tags from each other. This means that the TBai external
test will have the post_install_l10n tag inherited and are currently
run when staging. It should not block our staging when they are
down, ... by accident.
https://runbot.odoo.com/runbot/build/50405024closesodoo/odoo#134286
X-original-commit: 7ebc8cc5771d069b32722d493dd0ae5341e54c96
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
Signed-off-by: Josse Colpaert <jco@odoo.com>
Before this PR the link preview formatter was creating an unnecessary complex
object in the message key.
This PR simplify the payload by using a message_id key and remove the
unnecessary object.
closesodoo/odoo#134283
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Be in an ungrouped list or kanban view. The "limit" number of
records is displayed (by default 80). Apply a group by. The same
limit is applied for the number of groups, whereas there's a
specific parameter ("groups_limit") for the number of groups to
fetch and display. The same problem occurs the other way around
(going from grouped to ungrouped), as in this case the groups_limit
is kept when the view is no longer grouped.
This commit fixes the issue by forcing a reset of the limit when
we go from grouped to ungrouped and from ungrouped to grouped.
We also add a test to ensure that the "groups_limit" is taken into
account even when there're multiple groupbys, which wasn't the
case in previous versions, but which is working as expected with
the new model.
closesodoo/odoo#134253
Signed-off-by: Francois Georis (fge) <fge@odoo.com>
Before this commit, performing a search in a Many2manyTagsAvatarFields
and selecting an element does not remove the search value from the input.
Why not?
The value passed to Autocomplete is the default ''.
As this value never changes, onWillUpdateProps is never called and cannot
empty the input.
Solution:
Use the resetOnSelect option to force the input to be reset at each select
if props.value is the default value.
closesodoo/odoo#134242
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Before this commit, recipient list in chatter when using composer
in "Send message" mode where listing emails of all followers, instead
of only subscribers of "Send message" (= `mail.mt_comment`).
This commit solves this issue by loading and showing followers
that are recipients in this list. Because this feature and follower
list lazy-load some data, they need to manage they own list for
the "load-more" aspect. That's why the diff shows some duplicated
code as with `followers` field of JS thread model.
closesodoo/odoo#134225
X-original-commit: ba43502b22f8f00e7a2318b341302b809e7129dc
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>