With this commit, if realpath is not available (for exemple on macos),
the script is directly stopped.
closesodoo/odoo#90522
X-original-commit: 7857c577948d55842a5697ca6d91bb6ea656ef6e
Signed-off-by: Samuel Degueldre <sad@odoo.com>
Signed-off-by: Pierre Rousseau (pro) <pro@odoo.com>
Since fcf2e2210a639adfcdb9236c24cfb31046b6dead, the path of enterprise
is derived from the tooling path instead of the community path.
X-original-commit: 4ff8f62aa1e10d27189ebbdd22a01711c700ea32
Part-of: odoo/odoo#90522
When fakeEl is empty, firstChild and lastChild both equal null.
task-2842638
closesodoo/odoo#90523
X-original-commit: 626caa89cf290f226b19dfa73bc4ab41c7f95fc0
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
Avoid living `<li>` tags without a `<ul>` or `<ol>` parent
in the editable html.
task-2842638
closesodoo/odoo#90518
X-original-commit: c6660d9ae1c931da3ad442b30f610db463ede894
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
Current behavior:
When clicking multiple times on the print invoice button of an order
the customer rank would not update correctly
Steps to reproduce:
- Have PoS installed
- Start a PoS session, and select customer A
- Create an order, make the payment
- Go in the order tab and select the order you just made
- Click on the Print invoice button multiple times
- Customer rank isn't updated correctly
opw-2813512
closesodoo/odoo#90515
X-original-commit: 695c3dfd46d4e421a06f6dd33861e42bdb03efe0
Signed-off-by: Masereel Pierre <pim@odoo.com>
Signed-off-by: Engels Robin (roen) <roen@odoo.com>
Currently if a user is having huge number of karma/xp (for example
10000), when viewing the website profile, these numbers overlap the
design of a next rank layout card.
This commit formats the karma/xp into decimal number (allowing up
to two decimal points so that the information is meaningful) and
thus reducing the space being occupied by large numbers.
task-2792149
closesodoo/odoo#87996
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Currently if a user is having huge number of karma/xp (for example
10000), when viewing the website profile, these numbers overlap the
design of a next rank layout card.
This commit formats the karma/xp into decimal number (allowing up
to two decimal points so that the information is meaningful) and
thus reducing the space being occupied by large numbers.
task-2792149
Part-of: odoo/odoo#87996
Currently, we can format the number into decimal points with help of
the `format_decimalized_number` option of `ir.qweb.field.integer`
class. However, sometimes we need to decide how many decimal points
we need to display, which is not possible with current implementation.
This commit improves the above option and now allows to pass the number
of decimal points, with a new option `precision_digits`, which defaults
to one decimal point.
task-2792149
Part-of: odoo/odoo#87996
This commit introduces models that define records being 1:1 map with components,
as a step to move further to having essentially all business code in models.
Having code in models is desirable to have very maintainable code, thanks to
robust and declarative code with an ORM-like architecture.
Task-2831082
closesodoo/odoo#90427
Related: odoo/enterprise#26928
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
The xml we generate for factur-x is no longer compliant with all
the latest standards. With these changes, we are providing the tools
to make it work once again and make sure it is validated by the
factur-x and zugferd validators in all aspect (PDFA/3, XMP, XML)
It should also be valid to be sent to Chorus pro if applicable.
This adds a mapping to the UNECE unit of measure codes for uom, that
are required for factur-x.
It will also calculate a category for each taxes as such:
- If the tax is an export from EU to outside EU, G.
- If the supplier and customer are both in EU but different country,
K
- If both are in EU, in the same country but the tax amount is 0, E
- Otherwise, it will be S.
See https://unece.org/fileadmin/DAM/trade/untdid/d16b/tred/tred5305.htm
opw-2714544
closesodoo/odoo#90105
X-original-commit: e1bfb363bccd7b84f660d1e6c5b1e4d4fe02d398
Signed-off-by: Laurent Smet <las@odoo.com>
Before this change, we bringed to the user the posibility to select the option “Unified Book” (boolean) on journals with type “Sales” and Pre-printed Invoice “AFIP POS System”. This allowed all documents with the same letter document to use the same sequence, and it does not matter if they are invoices, credit notes or debit notes for example.
Now that functionality is deleted and all documents will have their own sequence regardless of the letter document of each receipt.
closesodoo/odoo#88129
Signed-off-by: Josse Colpaert <jco@odoo.com>
This is an attempt at fixing a runbot race condition.
It was executed succesfully without any error on Multi build around
200 times on runbot.
Since [1] the reset button could be clicked before the HTML editor was
reloaded.
The `MutationObserver` in `tour_service.js` is debounced. Because of
this the states used to detect tour steps triggers might differ between
executions.
With the Reset button of the HTML editor not being hidden in the
rendered template, it might be detected before it gets hidden during
the `start` of `ace.js`.
This commit makes sure the the editor is both closed then reopened with
the Reset button visible before clicking on it, and also makes sure the
Reset button is not visible by default upon rendering.
[1]: https://github.com/odoo/odoo/commit/d20468c3463927a54c34688769a22b3949c5c465
runbot-3674
closesodoo/odoo#90453
X-original-commit: b35f127c86c1d271a76dae7186a96190e8558c73
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
When started with the CLI option --dev=werkzeug, errors in controllers
are caught by a friendly web debugger. This debugger should not be
started in case of error in a JSON-RPC controller.
closesodoo/odoo#90420
Task: 2837457
X-original-commit: 711a29e76f55e87d73dad89ddbef889dd5c7af10
Signed-off-by: Julien Castiaux <juc@odoo.com>
Current behavior :
When a Google Agenda event is created with "Show as" set to Available,
Show as (`show_as`) isn't set accordingly
Steps :
- Install Calendar
- setup and activate Google Calendar sync
- Create an event and set "Show as" on Available
- Refresh Odoo calendar to sync it
-> Created event "show as" is set to Busy
OPW-2805096
closesodoo/odoo#90261
X-original-commit: ff56f8126e105f2196843fed1646a3081f25aff3
Signed-off-by: Arnaud Joset <arj@odoo.com>
Signed-off-by: Claude Thibault (thcl) <thcl@odoo.com>
Current behavior :
When a Google Agenda event is created with a meeting, the Meeting URL
(`videocall_location`) isn't set at creation.
Steps :
- Install Calendar
- setup and activate Google Calendar sync
- Create an event with a meeting via Google Calendar
- Refresh Odoo calendar to sync it
-> Created event doesn't contains a Meeting URL
OPW-2805096
X-original-commit: f85dfa2b3cb1fa03dcaa10b93fc5309b3a04eae6
Part-of: odoo/odoo#90261
As done with the "done" state, if a single picking in a batch is
cancelled while the other pickings aren't, this picking is removed from
the batch, as it would create inconsistencies between the states of the
pickings in a single batch.
closesodoo/odoo#90449
X-original-commit: 1f2813e59970cd2eb078b514cd7d563837f175a1
Signed-off-by: Arnold Moyaux <arm@odoo.com>
Signed-off-by: Quentin Wolfs (quwo) <quwo@odoo.com>
Before this commit, when spawning a LegacyWidget with the standaloneAdapter,
the legacyWidget couldn't re-trigger an OdooEvent (trigger_up) in the DOM
forbidding any attempts to, for instance, execute an action button (a stat button in form view)
After this commit, not only standaloneAdapter takes an optional owl ref to trigger onto
(defaults to document.body), but the last resort legacy_provider handles execute-action
DOM event.
closesodoo/odoo#90172
X-original-commit: 616d0761a8e15dfe49db9bacdfa6f7df75587dff
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
The current datepicker implementation uses Luxon to send and receive
dates from the client and Moment to create and communicate with the
bootstrap datepicker.
Before this commit: the current database date/time format was used to
convert dates from one system to the other. However there are
inconsistencies in notation for some formats, for which the conversion
could not be made properly.
Now: a static format is used to translate dates and the actual database
format is applied only after both systems have been notified of a date
change.
Tasks 2794506, 2797949
closesodoo/odoo#90422
X-original-commit: 174bc1dfa7b2894f35c288373f5130ec2992a8e8
Signed-off-by: Julien Mougenot (jum) <jum@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
This fixes former pull request odoo/odoo#78287.
The language installation wizard was invoking toggle_active() on the
target languages, which loads translations for those languages (with
overwrite=False), and then loading translations again (with expected
parameter overwrite).
Simply don't use toggle_active(), and directly set the active field
instead, in order to load translations once with the expected parameter
overwrite.
closesodoo/odoo#90421
X-original-commit: 3e4733859fbe2465c386ec65b7be995b152c8c48
Signed-off-by: Raphael Collet <rco@odoo.com>
Purpose of this commit to improve generic usage of project
app.
So, in this commit done following changes:
- add 'my department' filter in project search view.
- add 'my department's tasks' and 'my department's projects filter
in task search view.
- add quick search, filter and groupby in task analysis report search view
to make task analysis report search view same as task's search view.
- improve portal template of my/tasks page.
- project.task form view > timesheets: display the employee avatar
on mobile.
- make 'Task: Rating Request' template auto_delete false.
- settings: make following features disabled by default: sub-tasks,
task dependencies, recurring tasks.
- project.update kanban list: align the stat buttons with the kanban
list cards.
- add sample data to the project stages > list view.
- project.task quickcreate: enable the creation of new users on the
fly.
- move tags quick search below project.
- add title to show project full name on hover of project name in kanban
view of project.
- copy user_ids for task in recurrence.
- improve UI visibility of planned_hours and subtask_planned_hours field in
timesheet page of task form view.
- improve project sharing wizard and project.collaborator tree
view.
- add grid,kanban,pivot and graph views to 'hours spent on
sub-tasks' button's action.
closes: #83482
task-2742725
Related: odoo/enterprise#23788
Related: odoo/upgrade#3480
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
This PR prepares the ground for the one introducing the new environment in the
mail module. Indeed, the mail_bot messaging_initializer relies on the session
in order to known when to initiaze odoobot. With the new env, we won't be able
to access the session but will instead override init_messaging to automatically
initialize odoobot. Doing this first reduces the noise in the main PR.
task-2582313
closesodoo/odoo#90291
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Before this Commit,
There is an extra space at the top of the SMS composer.
After this Commit,
we have improved the UX of the SMS composer.
1/ Remove additional space on top of the SMS composer.
2/ Remove the additional space below the validation message.
3/ Improve the validation message of the invalid phone number.
Task-2710478
closesodoo/odoo#83062
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Before this commit:
After selecting an image and clicking on crop button, crop widget displays and
vanish immediately and crop does not work. After clicking on screen, it raises
an error (Cannot read properties of null (reading 'removeChild').
After this commit:
The crop button works fine without raising any traceback.
Task-2804892
X-original-commit: 1ab1c15386f778b04eb78f26b1e0934f3329c6af
Part-of: odoo/odoo#90401
As the "Big Box" snippet contain two divs that have a background
it is invisible to change the background of the "Big Box"
Instead of choosing a background for the "Big Box", choose a background
for it's child divs.
Task-2678999
Forward-port-of: #81064
X-original-commit: e495544722a5d96f390d84452d0c84869a34391c
Part-of: odoo/odoo#90394
When clickbot opens a modal dialog, it should be detected and closed
properly. The `open` attribute was removed from the modal dialogs but
the clickbot test were successful by accident. Even though the modal was
not found, the script was still able to continue by clicking on other
elements.
By disabling the ability to click on other elements while a dialog is
open , this 590fa18cafe2c commit revealed the truth.
closesodoo/odoo#90393
X-original-commit: c5e2300cbb89519e002cf1784a8d6c6f68197742
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
*:
approvals
hr_apprasaisal
hr_payroll
hr_referral
fleet
hr
hr_attendance
hr_holidays
hr_recruitment
lunch
Change various access rights names to improve understandability for users.
Addition of an officer role in fleet with intermediate accesses
TaskID 2742855
closesodoo/odoo#87545
Related: odoo/enterprise#25741
Signed-off-by: Kevin Baptiste <kba@odoo.com>
Previously, we were setting the ref to a component on ComponentWrapper
inside the onPatched hook, however, when mounting a component outside
the document (eg in a fragment) the patched hook is not supposed to be
called, but we need the ref to be set.
This commit fixes the issue by setting the componentRef in onRendered so
that it's available even when the component is mounted in a fragment.
closesodoo/odoo#90375
X-original-commit: 3013d89bcfe04be0207932b237d0e8ff8fb1d52b
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Before this commit:
redirect_url may have never been asssigned before being read
opw-2827002
closesodoo/odoo#90374
X-original-commit: 1aa35cba14528f413e9813707c406f31bfb07967
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
Fixing docstring of new get_view method (odoo/odoo#87522),
to include it in the doc (and replace reference to the deprecated
method fields_view_get).
models.py:docstring of odoo.models.BaseModel.get_view:8: WARNING: Unexpected indentation.
models.py:docstring of odoo.models.BaseModel.get_view:9: WARNING: Block quote ends without a blank line; unexpected unindent.
+ some little improvements to the docstring
closesodoo/odoo#90372
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Step to reproduce:
- As mitchell admin
- Change user's/employee tz to something != UTC
- Go to time off
- Click on the calendar
Current behaviour:
- Wizard Popup with a timezone warning
- If the same thing is done with the 'New Time Off' button, the
warning is not present
Behaviour after PR:
- No Warning
- `request_unit_custom` should be False if `holiday_status_id` is
set which might happen in default_values.
opw-2828936
closesodoo/odoo#90357
X-original-commit: 5565eb9f3dc4259f1304373eff83f7d54a0db7be
Signed-off-by: Kevin Baptiste <kba@odoo.com>
Remove most values uselessly specified because giving the same value as
the default one (see _DEFAULT_MANIFEST in odoo/modules/module.py)
* auto_install is Falsy by default
* author is Odoo SA by default
* summary & description are empty strings by default
* application is False by default
* test, demo, depends and data are empty lists by default
This will reduce noise/inconsistencies between manifests specifications,
simplify analysis of manifests content, ...
closesodoo/odoo#90209
Related: odoo/enterprise#26807
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
*: hr, im_livechat, snailmail, website_livechat.
This PR prepares the ground for the one introducing the new environment in the
discuss app. Indeed, tests will now use the mainComponentRegistry in order to mount
those components. Doing so, the parameters has{Discuss/Dialog/ChatWindow} will become
obsolete. Removing those parameters now helps reducing the noise in the main PR.
task-2582313
closesodoo/odoo#90120
Related: odoo/enterprise#26759
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Model pattern was too permissive, separator is the literal `.`
character, not any random thing.
Also remove unnecessary bracket expression, it's unnecessary when
matching a single item.
OPW-2836106
closesodoo/odoo#90107
X-original-commit: 320cdb4e85cb86915fa25cfda8f17e0a372e765e
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Signed-off-by: Raphael Collet <rco@odoo.com>
Current behavior:
When opening the giftcard popup in a PoS the focus would always
always go back to the first input field after typing in any other
input field.
Steps to reproduce:
- Install PoS and activate gift card
- Activate option "Scan an existing barcode and set a price"
- Start a PoS session
- Access the giftcard popup
- Select "Scan and set price on gift card"
- Type anything in the second input field
- The focus will go back on the first input field
opw-2825163
closesodoo/odoo#90081
X-original-commit: 84c129c7e05bb22e5dde272ab0a7cf8d4e1c2011
Signed-off-by: Grazioso Andrea (agr) <agr@odoo.com>
Signed-off-by: Engels Robin (roen) <roen@odoo.com>
Description of the bug :
Registering a payment for two confirmed bills/invoices from different partners would result in a stack trace.
Steps to reproduce :
Create a bill from a specific partner and confirm it.
Create another from another partner, confirm it.
From the list view, select both those documents, click Register Payment.
The StackTrace appears.
FIX :
handled the case by setting the payment_difference field to 0.0 if the wizard contains multiple payment batches.
Modified some tests to detect this behaviour in the future.
closesodoo/odoo#89757
X-original-commit: def467e82b12c5ec7284ed9c966bb13ab3a77298
Signed-off-by: Laurent Smet <las@odoo.com>
The base model is modified in order to be able to make comparisons between
recordsets contained in lazy values. The isinstance method will always
return an error, so we consider that we receive a recordset and try to
access the `_name` and `_ids`. If an error is triggered, it was not a
recordset.
This way of doing it involves little change in performance (improvement
when it is good and decrease when there is an error) because we do not
test if it is a recordset before comparing it.
closesodoo/odoo#89141
Signed-off-by: Rémy Voet <ryv@odoo.com>
The test 'test_inactive_related_product_update' raises a ValueError
"Wrong value for product.template.detailed_type: 'product'".
(which causes the L10n nightly build many fails)
See https://github.com/odoo/odoo/pull/89468closesodoo/odoo#90339
X-original-commit: d0ff5fe311cd69a3068593142aff66b09f13c43d
Signed-off-by: Laurent Smet <las@odoo.com>
Signed-off-by: Julien Van Roy <juvr@odoo.com>
Previously, the useAssets hook would load the templates from the given
bundles into the qweb instance that was in the environment. In owl 2,
qweb is no longer in the environment, and templates need to be loaded in
the app.
This commit fixes that by exporting a function to load templates in the
main app from assets.js, when the main app is created, it should be
written on the function in a similar vein to renderToString, so that all
further calls to the function will load the templates in that app.
This commit also adds an actual lazy-loading test in the
test_assetsbundle module, as we don't want to pollute the manifest of
web with bundles that only exist for one specific test.
closesodoo/odoo#90122
Related: odoo/enterprise#26776
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>