Before this commit, the time to compute all counters was making the rendering
of the portal page slow.
Now the count is done in rpc after the loading of the page.
Now you can decide which part you want to show on the portal, and only compute
for these one.
It is not because you have purchase installed for your internal process, that
it means that your supplier use your portal and it avoid the computation for
all end users.
We parallelize the counters in arbitrary 3 rpcs.
closesodoo/odoo#55999
Related: odoo/enterprise#12456
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
Before this commit, the template to generate 'New' panel generates .exists()
queries for each env.ref, now only one by module.
We could still improve it, deferring this rendering on click only.
For now, each time you are editor, we render it, even if you don't plan to
create anything.
+ use some xmlid_to_res_id instead of ref to avoid useless exists query.
Courtesy of @Feyensv for the tips
This commit simply removes the default filter on the calendar.events when
clicking on the crm.lead stat button to access "Meetings".
The filtering was not handy because the user could not easily see when a slot
was available to schedule a new meeting.
The events that are related to that crm.lead are highlighted anyway (current
behavior), which should be sufficiently clear.
Task ID 2289295
closesodoo/odoo#55050
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Before this commit there is no label shown at the top of the invite if
the user hasn't done anything with the invite or if he chose
'Tentative'. Now it always shows the informative label. This commit
also adds the description of a meeting subject as it can be
interesting and important in many cases.
closesodoo/odoo#43121
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Added edi.documents representing an electronic document for a move and an edi.format.
A format can be asynchronous if it needs to call a web-service to generate the document, it will then be generated by the CRON (otherwise it's generated in post).
The formats can support payments if needed (can be generated immediately or by the CRON).
Added support for errors and related views.
Setting defaults format on a journal can be done automatically (based on a hook).
Added tests : xml comparaison with diff and helpers to test a EDI import/export
--task: 2247368
- removed simple check vat for columbia
- removed document type field from partner
- document type will be managed by latam type
- updated city name for colombia
- added data for for latam identification type
- Added depdencies
- base_address_city
- account_debit_note
- l10n_latam_base
task- 2190843closesodoo/odoo#53040
Related: odoo/upgrade#1589
Related: odoo/enterprise#9567
Signed-off-by: Josse Colpaert <jco@openerp.com>
If floor screen (iface_floorplan) is not active in the pos.config,
product screen should follow the tip screen and not an error.
closesodoo/odoo#55998
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
Aside from new look, we also move the email option from payment
screen to receipt screen. This allows emailing the receipt to a
customer that is not in the contact list.
We also removed invoicing in the receipt screen during failed invoicing
from payment screen as it is removed in here: bc48e0033eclosesodoo/odoo#55868
Related: odoo/enterprise#12395
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
The old implementation manually sets 'display' to 'none' to the elements
we don't want to see in the print. This is tedious because we need
to identify every element to be hidden when in fact we know the only
element that we want to print -- the receipt.
So in this commit, we set the 'visibility' of all elements to 'hidden'
and only the element tree of the receipt is set to visible.
Show partner commercial name and contact name in the inovice report
instead of just the partner contact name. For the example of
Adhoc (Commercial Partner)
- Katherine Zaoral (contact)
The invoice report was showing: Katherine Zaoral (partner name).
Now will show: Adhoc (the commercial partner name)
closesodoo/odoo#55202closesodoo/odoo#54193
Related: odoo/enterprise#11717
Signed-off-by: Josse Colpaert <jco@openerp.com>
Change padding right in the header of the report to ensure that the data
to show take advantage of the most space possible without overlapping
the header data with the report content.
closesodoo/odoo#55212
Signed-off-by: Josse Colpaert <jco@openerp.com>
Port foward from 13.0 branch. Also update the _get_name_invoice_report()
method to match the one in account module.
Also update the name of payment field that has been change in master version
* o.invoice_payment_ref is now o.payment_reference
port foward from 13.0 branch, also remove the logic of _get_name_invoice_report()
method already added in account module and remove the not needed latam
report templates.
* merge report_invoice_document and report_invoice_document_with_payments templates
* define new generic method _get_name_invoice_report that let us to
print a different report, this method can be inherited by each localization
to set their custom report
* change report templates to use the new method.
Allow configuring a webhook in Stripe to send s2s notifications to Odoo
when a Checkout payment is completed. Note that SetupIntent and
PaymentIntent events are not listened to, since they are handled 'live'
with the customer actively present; the main use case for Stripe
webhooks is a Checkout session that gets interrupted before the customer
is redirected to Odoo (e.g. network loss, browser crash, closing the
tab, etc.)
The webhook should be configured to send its events to
<base_url>/payment/stripe/webhook and should only subscribe to
checkout.session.completed events to avoid spamming the Odoo server with
useless notifications.
closesodoo/odoo#52754
Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
Extend support for all currencies listed in the SIPS documentation,
including the decimal numbers per currency. Move this hardcoded data
is a less annoying place.
Remove unnecessary code (e.g. checking if there is more than one payment
with the same reference, which can't happen due to a SQL unique
constraint from the payment module).
Code clarity while I'm at it.
Task-2259942
closesodoo/odoo#51473
Related: odoo/upgrade#1216
Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
Prior to this revision, setting the provider to the 'test' mode caused
hardcoded values for merchantId, secret and keyVersion to be used
without any possibility to override them.
While somewhat useful, it was quite limiting since it used the 'simu'
environment of Atos Wordline, preventing you from testing any other
platform and from using the 'test' environment for Atos.
This revision removes these hardcoded values, which gives more
flexibility as far as testing goes at the cost of a bit more setup
(since you might need to change some values manually, notably the
keyVersion).
Task-2259942
The config param 'sips.key_version' was introduced "some time ago"
in revision a62480ad0f to allow setting the `keyVersion` POST param
to an arbitrary value, allowing other SIPS-comptatible providers to be
used with this module.
This revision (finally) converts this fix to a proper field.
Task-2259942
PURPOSE
Currently it does two RPCs to refresh followers on thread:
1) To get follower ids
2) To get followers detail
SPECIFICATION
While refreshing followers on the thread, perform only one RPC call.
LINKS
Task-2243180
PR https://github.com/odoo/odoo/pull/54437closesodoo/odoo#55989
X-original-commit: 1fd445fb55810b97ed7a6dfe694e471891c6a3bc
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit adds a trash icon on the snippet overlay to delete the
snippet without using the left panel button.
task-2314805
closesodoo/odoo#55612
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
The `PackageLoader` jinja's loader purpose is to discover template files
given a python module path. It was necessary to register a special hook
into the import scheme of Odoo to support `import crm`, `import openerp`
and `import openerp.addons` like module path.
Since the support for those old module paths is deprecated since v13 and
the jinja's team shows desire to remove support to `pkg_resource` utils
as highlighted by #50552, it is better to remove it.
closesodoo/odoo#53515
Task: 2282681
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
* Not sure how the tour passed during merge as it would not be looking
for the button in the right tab, it would fail locally, fix this
issue by properly switching to the Account Security tab
* add the missing test of RPC (which should not work on an account
with totp enabled)
* also reorder ops & fix comments: turns out `totp_login_enabled`
checks that totp is enabled *then disables it*
closesodoo/odoo#55979
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Setting the totp secret is a significant change to the user's
auth-ability, and as such should be taken in account for the session's
validity.
For convenience, update the user's session in-place to avoid logging
them out.
Remove all acccess rights on `ir.actions.*` models.
Interacting with the models is done using sudo or via the `/web/action/load` controller.
Part of task 8203
closesodoo/odoo#53335
Related: odoo/enterprise#11797
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Use _for_xml_id to replace all the self.env.ref().read()[0]
This has the advantage of having a single point of control and to add
the fields filtering and model verification.
Add sudo for other operations on ir.actions.*
/web/action/load is the public controller that Should be used by the
webclient to fetch actions
_for_xml_id is the default access method on actions that implements
fields filtering to avoid leaking server action code or other
information not needed by the webclient
Implementing whitelist of fields that can be access per model
To trigger a run of a server action, one must have a group specified
or a write access on the model.
CRM: only access lead, crm.team is readable by employees
Website: all users can access, action_dashboard_redirect takes care of the group
Browse in sudo and allow to access and run in sudo if the user belongs
to the groups defined.
If the user does not belong to the group, the run must be called in
sudo or with a priviledged user.
If no group is defined, the user can execute the action if he can
write on the target model.
Safe actions (e.g. crm.action_your_pipeline) need to have the correct
group on it.
Inspired by the logic of access to ir.ui.view, all records are private
by default except if explicitly specify a group value.
A single anglo saxon line was created in the pos.session journal
entries, even if some products were returned. We now distinguish
positive from negative lines.
E.g. Selling 10 Product1 (cost=10) and returning 5 Product1 used to
create the following line:
```
Stock Interim Account (Delivered) 0 50
```
and now creates the following lines:
```
Stock Interim Account (Delivered) 0 100
Stock Interim Account (Delivered) 50 0
```
Task ID: 2126521
closesodoo/odoo#55086
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
b8359c55e6e57035ffa3b10bfa5294e22a74e837
An user with recruitment/officer (user) permission on hr_recruitment
could not create applications anymore because doing so imply a write to
hr.recruitment.stage
opw-2305646
closesodoo/odoo#55805
X-original-commit: 01fbb34213358f216011ae5b1c1fd6ec8dd80bdf
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: agr-odoo <agr-odoo@users.noreply.github.com>
`struct_rusage.ru_utime` and `struct_rusage.ru_stime` are float
seconds.
`setrlimit()` takes a tuple of *integers*, and recent versions of
Python have started triggering warnings:
DeprecationWarning: an integer is required (got type
float). Implicit conversion to integers using __int__ is
deprecated, and may be removed in a future version of Python.
Convert the soft cpu time limit to an integer explicitly to suppress
the warning.
closesodoo/odoo#49710
Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
PURPOSE
Make sure the Rainbowman animation is rightly triggered whichever way the user
marks the opportunity as won. Especially relevant for the onboarding as we want
to show the first rainbowman to users completing the tour.
SPECIFICATIONS
Now the rainbowman and its finely-tuned message are displayed to the user when
he uses the statusbar, mark lead as won using action buttons or drag and drop
a lead in the won stage in kanban view.
LINKS
Task ID-2287758
PR #54553
Steps to reproduce:
- Go to the website shop
- Add a product in the cart
- Add your address and click on checkout
- On the checkout, enable Terms & conditions
Bug:
The button was always enabled even if the check box with the terms & conditions were not
checked.
opw:2313437
closesodoo/odoo#55821
X-original-commit: 0415da51960819ec9c989e15a9229bd6d583ba1b
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
- Adds support for two-factor authentication (2FA) via time-based one-time-passwords (TOTP),
compatible with mainstream authenticators like Google Auth, 1Password, etc.
- Add support for personal API key that can be used for non-interactive RPC scripting, including
when 2FA is enabled (password-based non-interactive RPC auth gets disabled by 2FA)
- Both features can only be enabled/disabled after an extra password check, made possible
by a new "identitycheck" feature.
- Adapt user profile and portal to allow managing those new security settings.
closesodoo/odoo#33928
Related: odoo/enterprise#9112
Signed-off-by: Olivier Dony (odo) <odo@openerp.com>
New module for supporting two-factor authentication via time-base
one-time-password (TOTP).
Users (including portal users) can choose to enable two-factor auth in
their user account settings, by scanning a QR code and adding it to an
authenticator app, such as Google Auth, 1Password, etc.
When two-factor is enabled, password-based non-interactive RPC is only
possible by using API keys.
Co-authored-by: Olivier Dony <odo@odoo.com>