Previously, all costs allocated to a task were associated, if set, to
the analytic account of their project.
This commit adds a deeper level of granularity, as the user will be able
to override the project analytic account and add analytic tags.
When creating timesheets or creating account move line related to SO
linked to a task, the analytic account of the task is now taken into
account rather than the one defined on the project. If an analytic
account is set on the SO, it remains the default account used.
If a task is related to an SOL and an invoice line is created from this
SOL, the analytic tags of the task are also given to the account move
line.
If different analytic account are linked to a same SOL through the
project using this SOL or the tasks using this SOL, than no default
analytic account is set on the invoice line.
PR : #70527
task-2458135
Previously when a user added products to a task, when invoicing the
customer, in default case, no analytic account was defined on the
invoice line generated for the sale order line.
With this commit, we define a default analytic account based on the
information of the sale order line.
If the sale order line has a generated task or project associated to
it, we set the project analytic account.
If the sale order line is used on tasks or projects which all use the
same analytic account, then the invoice line created will take this
unique analytic account as default value.
If a sale order line is used in distinct project or tasks
from distinct project, then no default analytic account is defined.
PR : #70527
task-2458135
This commit improves the view inheritance priority and xpaths for
the inherited form views of event to arrange the stat buttons in
logical manner, regardless of installation order of the modules.
The stat button order should always be:
- Attendees
- Leads
- Sales
- Tracks
- Sponsors
- Rooms
Task-2585998
EnterprisePR-https://github.com/odoo/enterprise/pull/20082closesodoo/odoo#74203
Related: odoo/enterprise#20082
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Since we change the editor for the comments on invoices,
The layout was a bit broken with some unwanted spacings.
task-2586137
Part-of: odoo/odoo#75863
Make the default height of the editor quite smaller in res.partner view.
To avoid "breaking" the design and prevent scrollbars
task-2586137
Part-of: odoo/odoo#75863
In editor, CTRL+K was changed to CTRL+M to edit link.
This was done to free CTRL+K for the command palette in the backend.
The issue is that CTRL+K is an universal keybind to edit links, and we should
not remove it, especially to add another behavior on it that could very well
fit on another key.
Validated by FP/AL at
https://discord.com/channels/678381219515465750/687338152372994236/880465980986368050closesodoo/odoo#75848
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
When a product's has a kits bom, we consider it a kits product.
When a product is a kits product, we count its "on hand" and "forecast"
qty by caculating how many can be produced according to the bom.
We add status button to the show the qty on kit product form.
Task-2444000
COM PR odoo/odoo#75555
ENT PR odoo/enterprise#20440
UPG PR odoo/upgrade#2783
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
When recieving a kits product, it will be decomponent in the picking. In
this commit, we add a column in the picking to show the info of the kits
in picking.
Task-2444000
COM PR odoo/odoo#75555
ENT PR odoo/enterprise#20440
UPG PR odoo/upgrade#2783
Before this commit the search bar was specific to products. This generalises the search bar so it can be added to any model.
A snippet is provided, and used to replace the old search bars of blog, courses, event, forum, page and shop. The search results of these pages and the autocomplete of the search bar run through the same search mechanism.
A new hybrid results page has also been created as a target of a search on "Everything".
In each involved module, `website._get_search_details()` is implemented to return search metadata for every model related to the `search_type` parameter. Search metadata for a single model is returned by `_get_search_detail()` on that specific model.
The autocomplete runs through the additional `website._render_search_results()` pre-rendering step that prepares the data to fit in the autocomplete template.
This PR also introduces a fuzzy search mechanism: if the searched term is not found then the search is performed on a resembling term. The similarity is obtained from a Levenshtein distance combined with ratios of common and different letters.
By default the dictionary against which the search term is matched is based on the content of the search fields containing a word that starts with the first letter of the search term.
If the `pg_trgm` Postgresql extension is installed the dictionary is built from matches obtained using the `word_similarity` function.
task-2379555
odoo/upgrade#2186closesodoo/odoo#65871
Signed-off-by: Benoit Socias (bso) <bso-odoo@users.noreply.github.com>
Before this commit the search on pages was only done in the main
language.
After this commit the search on pages is based on the translated "arch"
field.
task-2379555
https://github.com/odoo/odoo/pull/65871
Part-of: odoo/odoo#65871
Before this commit the `_search_get_detail` result contained callback
functions to handle special behavior during fetching and rendering.
After this commit a `website.searchable.mixin` is introduced that must
be inherited by models that participate in website-based searches.
Custom behavior previously achieved with callbacks is now achieved by
overloading methods of this mixin.
task-2379555
https://github.com/odoo/odoo/pull/65871
Part-of: odoo/odoo#65871
Before this commit searched terms were the ones entered by the end-user.
After this commit if the searched term is not found then the search is
performed on a resembling term.
The similarity is obtained from a Levenshtein distance combined with
ratios of common and different letters.
By default the dictionary against which the search term is matched is
based on the content of the search fields containing a word that starts
with the first letter of the search term.
If the `pg_trgm` Postgresql extension is installed the dictionary is
built from matches using the `<%%` operator (similar to the
`word_similarity` function).
Several approaches were benchmarked during development, those results
are available through the task record.
task-2379555
https://github.com/odoo/odoo/pull/65871
Part-of: odoo/odoo#65871
(*: website_blog, website_event, website_forum, website_sale,
website_slides)
Before this commit the search bar was specific to products.
After this commit a generic search bar is available as a general feature
of website which can be configured to inspect specific models.
The snippet is used to replace the old search bar in blog, courses,
event, forum, page and shop.
The search results of these pages and the autocomplete of the search bar
run through the same search mechanism.
A new hybrid results page has also been created as a target of a search
on "Everything".
In each involved module, `website._search_get_details()` is implemented
to return search metadata for every model related to the `search_type`
parameter.
Search metadata for a single model is returned by `_search_get_detail()`
on that specific model.
The autocomplete runs through the additional
`website._search_render_results()` pre-rendering step that prepares the
data to fit in the autocomplete template.
task-2379555
https://github.com/odoo/odoo/pull/65871
Part-of: odoo/odoo#65871
The service is called `notifications` when mocked in tests,
instead of `notification`
closesodoo/odoo#75859
Related: odoo/enterprise#20554
Signed-off-by: Vincent Schippefilt (vsc) <vsc@odoo.com>
In the spreadsheet app, we need the exact same values which are saved
for "ir.filter" records.
This commit refactor a bit things to allows getting those values without
actually creating the "ir.filter" record.
Task 2572184
Part-of: odoo/odoo#75859
Co-authored-by: LucasLefevre <lul@odoo.com>
In multivat setup, we need to create taxes in foreign countries to map them with domestic taxes. Before this commit, this was only possible manually, even though all the necessary information lies in Odoo's account.tax.template objects created by l10n modules.
We now display a banner on top of foreign vat fiscal positions with a button allowing instantiating those templates directly from them when it's appropriate.
closesodoo/odoo#75803
Task: 2453325
Related: odoo/enterprise#20553
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
This commit allows users to "delete" their messages in discuss, as well
as their notes on other records. Admins can delete anyone discuss
messages or notes. Tracking messages such as a change in stage or other
cannot be deleted.
This "delete" is a "soft-delete" in that it only empties the message's
content, so that it is no longer displayed in the UI, but remains in the
database so that people who got notified by email can still reply to the
message, among other things.
task-2365646
closesodoo/odoo#74857
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Before this commit amount updates were not taken into account during the
payment operation.
After this commit amount updates are taken into account for the actual
payment operation and payment fees are updated according to the amount
and the partner country.
Part of #63133
task-2398403
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
This commit adds /donation/* routes to perform the donation:
- /pay: shows the form with the contact details and donation details
- /transaction: creates the partner_id if missing and executes the
transaction
- /confirm: displays the payment success page
PR-63133
task-2398403
Part-of: odoo/odoo#63133
As the descriptions of the donation snippet will be in hidden inputs,
we added the possibility to translate these inputs in translate mode.
PR-63133
task-2398403
Part-of: odoo/odoo#63133
There were two issues when cloning a website_form field:
1/ Cloning is not done
Steps to reproduce :
Drop a form from the editor, save
Click on edit, select the field
Click on the clone option without hovering the label position option
2/ A traceback is thrown
Drop a form from the editor, save
Click on edit, select the field
Click on the clone option after hovering the label position option
Some FieldEditor options modify directly the dom and replace the field
node, which the editor will detect as a change of unbreakables. As a
result a rollback will be required in the next call to
odooEitor.historyStep(), done in SnippetEditor.clone().
To solve that we skip potential rollbacks while recording a history step
during a clone.
task-2485093
closesodoo/odoo#75908
X-original-commit: 7a75f295087cb02f162477a9df3b138b6780dbdd
Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
When cloning a website_form field, we rerender the cloned field to
reassign its elements ids and for attributes with a unique ID instead of
the old ones.
Rerendering the list also removes an issue with Selection fields that
were not visible after a clone and a save, as it was usually done after
a _rerenderXML, not executed after a clone.
Also, _renderField docstring was wrong, and its return values
terminology have been replaced with correct one.
task-2485093
X-original-commit: 92bacc8907fa9577805b28a11894e7a006b2a5bf
Part-of: odoo/odoo#75908
Changes on cover attributes (bg-color, size) were not saved properly
when no other option where changed on the object.
task-2547729
closesodoo/odoo#75890
X-original-commit: 6d00c5ac0346beb57eef2192fe21a45a1158d87e
Signed-off-by: Antoine Guenet <Zinston@users.noreply.github.com>
This allows to solve the following use case:
* we are in March
* a SO created during January shows currently a delivered quantity (timesheet on service or delivered goods on storable products): timesheets/pickings were done in February
* creating the accrued entry for January 31 should display accordingly an amount of 0 by default since everything was done in February
Invoices invoice_dates are also taken into account:
* day 0 : delivered 10
* day 2 : 5 invoiced
* accrued entries for 10 if accrual date = day 1, accrued entries for 5 if accrual date = day 3,
followup of task 2255642
closesodoo/odoo#75886
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
Two changes:
- The `barcode_rule_gs1_16` was renamed `barcode_rule_gs1_17` (and its
AI was changed too) as the AI 16 is about the sale by date, not the
expiration date;
- The `qty_done` rule type was changed for `quantity` as `qty_done`
refers to the move field, but the rule isn't only about this field as
it could be used by other model like `stock.quant`.
closesodoo/odoo#75699
Related: odoo/enterprise#20482
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
Before this commit, multiple package types can have the same barcode.
As it makes no sense and could lead to confusion, it's no more possible.
task-2627002
Part-of: odoo/odoo#75699
For `stock`, adds package type demo data (pallet and box).
For `barcodes_gs1_nomenclature`, adds a custom rule (AI 91) to recognize
the package type in the Barcode Application.
As there is no standard GS1 nomenclature's rule for the package as
defined by Odoo and there is a bunch of free-to-use AI (from 91 to 99),
using one of them for the package type could be useful to be able to
scan a new package and create it on the fly with the wanted type.
task-2627002
Part-of: odoo/odoo#75699
Before this commit, editing a mail.activity with the "meeting" category would
open a modal form for the mail.activity, which did not make much sense.
When editing a mail.activity that is linked to a calendar.event, you will now
jump on the calendar view to edit the related event, which is much more
convenient.
In addition, when scheduling such an activity, the "Edit" button in the chatter
is renamed to "Reschedule", to show the user that he will land on the calendar
view.
Furthermore, trying to delete an activity that is linked to a meeting will now
prompt a confirmation dialog warning the user that the meeting will be deleted
as well.
Finally, we moved the 'phonecall' activity category from the 'voip' module
(enterprise) to the base 'mail' module.
Scheduling a phonecall activity will let the user choose if he wants to:
- Simply save the activity, which will schedule a regular mail.activity
- Open the calendar to create a related calendar.event
Used typically when you want your colleagues to see that you are busy in your
calendar during this call.
Task-2486126
ENT PR odoo/enterprise#20431
UPG PR odoo/upgrade#2775closesodoo/odoo#75530
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Co-authored-by: Aurélien Warnon <awa@odoo.com>
This PR brings UX improvements in the Services Apps (Planning, Timesheets, Project, Helpdesk, Field Service)
task-2615316
Related: odoo/enterprise#20426
Related: odoo/upgrade#2773
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
closesodoo/odoo#75524
Signed-off-by: LTU-Odoo <IT-Ideas@users.noreply.github.com>
* Move the action to "technical feature" debug mode group instead of
group "advisor"
* Set the action in noupdate="1" to facilitate customization of right
task-2604155
closesodoo/odoo#75819
Related: odoo/upgrade#2794
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
Before 660dc0ebaf it was possible to use Authorize to pay via your bank
account using the "Redirection to payment acquirer" option. Since the
refactor removed the redirect it was no longer possible. This commit
reintroduces that feature.
It does so by adding new form elements that accept bank account
information. Additionally it reintroduces the `billTo` and `customer`
parameters that Authorize requires when processing ACH payments.
task-2628318
closesodoo/odoo#75289
Signed-off-by: Antoine Vandevenne (anv) <AntoineVDV@users.noreply.github.com>
A new field on tax groups makes it now possible for this group to be displayed under a subtotal label. If not set, this defaults instead to "Untaxed Amount", keeping the traditional behavior. This is intended for withholding taxes, which can now be implemented with negative taxes and a tax group with this field set.
To do that, this commit entirely refactors the way amount_by_group worked, and replaces it with a more complete json field called tax_totals_json. It also streamlines the way taxe totals are displayed on invoices, PO and SO and makes it so that a common code is called instead of copy-pasting the same block 3 times as before.
[IMP] purchase: always display tax totals by groups on purchases orders
Before, tax totals on purchase.order's form were not shown by group, and were instead all aggregated in a single "Taxes" category. The same went for the pdf export. The portal view, though, did show the totals by group. We now display the tax groups in the same way all the time.
closesodoo/odoo#74138
Task: 2457374
Related: odoo/enterprise#19802
Related: odoo/upgrade#2670
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
The tax_exigible field of account.move.line made it impossible to mix 'on_payment' and 'on_invoice' taxes on the same invoice line, as the base line couldn't be be tax exigible and non-tax exigible at the same time. However, this use case is needed by some countries in order to implement withholding taxes.
To solve that, we totally remove the tax_exigible field from account.move.line and instead compute it on the fly with a domain (also passed to the query_get for SQL queries). An 'always_tax_exigible' stored computed field is also added on account.move, in order to still allow (like before) putting cash basis taxes on a miscellaneous operation without any payable/receivable line and still see it become exigible without needing any payment.
[IMP] account: improve cash basis traceability
A smart button is now available on invoices generating cash basis entries, so see them all at once. The move originally creating cash basis entries is also shown as a field on them.
Task: 2457374
Part-of: odoo/odoo#74138
Refactor the tax group widget with the new JavaScript Odoo Framework:
OWL. This widget has 2 different components, one representing a tax group
and one representing the list of tax groups.
Task ID: #2312900
Initial Task ID: #1986412
Part-of: odoo/odoo#74138
Based on their path, we retrieve snippets assets, assuming that it will
be in the form : /snippets/{snippet_id}/{version}.{scss|js}
Then we check the template definition uses that version, or if any views
or html fields contains a snippet with such version exist.
If not, the asset is deactivated.
For that, we are looking for the data-snippet attribute in snippets
already dropped. For the template definition, we look at the first class
definition if a data version attribute is also defined.
task-2212216
closesodoo/odoo#73005
Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
The WebsiteAnimate option was triggering a resize on the window in its
start method, which would lead to a scroll on the wrapwrap and closing
the megamenu dropdown if it was open. Besides that, animations were not
working when selected on a section in a dropdown menu.
Now, an open dropdown that has animated content is considered as the
scrolling element so that its animations are rendered correctly and it
is not closed because of a scroll elsewhere.
The "Launch animation at first time/always" option is hidden for
dropdowns as bootstrap will launch it anytime a dropdown is open.
Part of https://github.com/odoo/odoo/pull/71143
task-2502208
closesodoo/odoo#71143
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
This prevents dropping main snippets in the mega menus, but it is still
possible to move the elements inside it or drop inline snippets.
Part of https://github.com/odoo/odoo/pull/71143
task-2502208
Part-of: odoo/odoo#71143
A new class has been added for snippets that should not display their
parents options: o_no_parent_editor.
With that class the editors for the parents of this snippet won't be
created.
Part of https://github.com/odoo/odoo/pull/71143
task-2502208
Part-of: odoo/odoo#71143
*: web_editor
As the mega menu templates are now displayed as an option of the mega
menu snippet, opening the mega menu dropdown in edit mode will display
the options.
Part of https://github.com/odoo/odoo/pull/71143
task-2502208
Part-of: odoo/odoo#71143
*: web_editor
The masonry templates selection SnippetOption has been abstracted so
that mega menus content can also be replaced with template content.
Part of https://github.com/odoo/odoo/pull/71143
task-2502208
Part-of: odoo/odoo#71143