Steps to reproduce:
- install sales
- create a new quotation
Previous behavior:
the avatar next to the author's name is empty in the mailthread
Current behavior:
avatar is displayed as expected
opw-2187231
closesodoo/odoo#44407
X-original-commit: 24ba9f9954a71eba46d44fe242cd2e6dba125da6
Signed-off-by: mightyjol <jhk-odoo@users.noreply.github.com>
Follow up on 255f7219a9
The issue is still happening.
With the current commit, we will be able to know for sure if it happens because
we don't wait long enough, or because the messages are never appearing.
closesodoo/odoo#44471
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
`AccessError` requires the argument `msg`. Therefore, even if this error
is catched, we need to provide one, otherwise a `TypeError` is raised.
opw-2183184
closesodoo/odoo#44452
X-original-commit: cdefbf8d66e42d88d845dd621e0306cb55c5f79a
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Currently, 'Exception' ativity type is visible in dropdown list of schedule
activity. It is used by the system to generate warning activities on records.
It is not meant to be used by the user when scheduling activities manually.
By, giving active=false on mail.mail_activity_data_warning, we can hide
'Exception' activity type in dropdown list for user but available for the
system to generate warning.
task-2168569
closesodoo/odoo#43549
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Before this commit, when clicking on a channel mention from a chat
window, it crashed with the following error:
`TypeError: channel.detach is not a function`
This happens due to `MailService.joinChannel()` returning a promise
that is resolved with channel ID, instead of a channel object.
`channel.detach()` becomes `<Number>.detach()`, which is treated
like `undefined()`, hence crash.
closesodoo/odoo#44329
X-original-commit: 710fda06c3b30ff2267fcc1d123f15ce031b6f3a
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Before this commit, the CSS rule handling the "activity" of the modals
(their z-index compared to the one of their backdrop) was global and would
interfere with front-end or custom modals which do not use the static Dialog
methods giving them the "active" class.
Now, the rule has been inverted: the z-index of a modal is only changed when
it is given an "inactive" class, thus only impacting the modals instantiated
via Dialog or Owl Dialog classes.
closesodoo/odoo#44067
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
When simply need to parse a domain, it is easier
Add .strip() on ir.ui.view as ast.literal_eval produces an syntax
error if the node starts with spaces (as done in the xpath of
hr_attendance.view_employee_form_inherit_hr_attendance)
closesodoo/odoo#43831
Related: odoo/enterprise#7894
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
In order to prepare the future, we want to convert everything in Owl.
This commit converts the activity renderer.
closesodoo/odoo#42278
Task: 2149408
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Purpose
=======
Clean the context to get rid of residual default_* keys
that could cause issues afterward during the mail.message
generation. Example: 'default_parent_id' would refer to
the parent_id of the current record that was used during
its creation, but could refer to wrong parent message id,
leading to a traceback in case the related message_id
doesn't exist
closesodoo/odoo#43830
Taskid: 2176445
X-original-commit: 82d2d581a2590a9c782cbc71b5005a4198b70d77
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Task 2092079
Accounting firms that want to give access to their customers avoiding
mistakes and risks will love this profile that can't do anything
wrong... Maybe as well as companies auditors..?
closesodoo/odoo#39860
Related: odoo/enterprise#6576
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
Purpose of this commit is to improve model of followers, notably management
code and its use in routes. Indeed it is quite an old model and code had
to be cleaned a bit to improve code readability and maintenance.
In this commit we
* remove unnecessary code examples in gamification about followers: using
that model as example of code for goals is probably not a good idea as it
is technical;
* rewrite routes called by JS are simplified to better match JS
implementation;
* introduce computed fields to fetch related partner or channel name,
email (partner only) and active status;
LINKS
Task 1933771
Task 2078313
closesodoo/odoo#39808
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Co-authored-by: Remy Voet <ryv@odoo.com>
Co-authored-by: jgi-odoo <jgi@odoo.com>
Co-authored-by: Xavier-Do <xdo@odoo.com>
Purpose of this commit is to always call followers API with explicit parameters
about existing followers management (check_existing and existing_policy
parameters). It makes code easier to read and maintain.
LINKS
Task 1933771
Task 2078313
Co-Authored-By: Thibault Delavallée <tde@odoo.com>
Co-Authored-By: Rémy Voet <ryv@odoo.com>
Addition of this optional 'domain' value for systray activity related
lines allows the restriction of which activities will be included in
the view opened when the line is clicked on.
One use case is when a model is split between 2 systray activity lines.
In this case we most likely do not want the same activities of the
model to show up when we click on either line. For example, say we
have 2 modules using the same model, but the module instances of that
model are distingushed by a field.Selection value. Then we would only
want to show the activities related to each module when we click on
their appropriate systray activity lines based on that field.Selection
value.
Task: 2169498
This was incorrectly reverted during 116057b26e71db4692280463669f3e80d813ddcc
closesodoo/odoo#43564
X-original-commit: 73e3afca18fae954552d8cbecb6afddf1b08539b
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Issue
- Install Time Off
- Marc Demo > Create leave request
- Admin > Validate the leave request
- Marc Demo > Add an attachment
Nothing happens
Cause
There is a access right issue that is not handled in the
JS.
Solution
Handle it by doing a do_warn.
OPW-2171791
closesodoo/odoo#43484
X-original-commit: 6a98c75ebfca694e1e68fa09eca95e47472bed92
Signed-off-by: Jason Van Malder <jvm-odoo@users.noreply.github.com>
Before this commit, when a user joined, left, or was invited to a
channel with "Send by email", it sent an email notification to every
member.
This commit disables email notification on subscribe/unsubscribe on
a channel, while still showing messages on join/leave.
Task-Id 2003281
closesodoo/odoo#35142
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
With this commit, when changing subtype subscription from a parent
record (e.g. project of task), then it does not update subtype
subscription of existing records. Changes on parent record should
only affect new record afterwards.
Task-Id 1974055
Closes#34150
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
With this commit, when the user subscribes to internal subtypes
(i.e. activities and notes) on a parent record (e.g. project of
tasks), then the user follows them by default on every record
creation (e.g. all new tasks of this project).
Task-Id 1974055
Closes#34150
When using emoji widget in a multi language environment, button for emoji
is displayed twice.
This is due to having in the widget both the input and a translation box
holding the translation button. Emoji button is incorrectly added to both
elements, which is fixed in this commit.
We also adjust vertical position so that button is aligned with the language
button.
Task #2168338closesodoo/odoo#42827
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Before this commit, chatter without messages did not display
attachment counter, even though attachments could be uploaded from
attachment box.
This commit now displays the attachment counter in this case.
Task-Id 2149348
closesodoo/odoo#42672
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Steps to reproduce:
- install crm
- set your computer timezone to GMT-6 (Mexico city)
- go to crm > change the view to activity view
Current behavior:
all activities are one day off from their actual deadline
(an activity set to be due on the 7th of January shows as
6 Jan on the view)
Current behavior:
activities are displayed properly according to their due date
opw-2162579
closesodoo/odoo#43223
X-original-commit: 0735547086aaab819369b1a08e6810baeac3783d
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
This commit enables archived mail channels.
Archiving one also removes it from channel list in Discuss.
Task-Id 2155386
closesodoo/odoo#42743
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit adds "Next Activities" on kanban card of partners,
like on the app Contact.
Task-Id 2152180
closesodoo/odoo#41793
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Before this commit, the test 'all messages in "Inbox" in "History"
after marked all as read' had non-deterministic failures.
More precisely, it crashed on either assertion "there should be 30
messages in History" or "there should be 40 messages in History",
both resulting to 0 messages in History instead.
Unfortunately, as of the date of this commit, we still do not
understand why it rarely fails. In the meantime, we have decided to
make these errors less likely to happen, by waiting much longer
before the assertions. We are aware that this is a poor solution,
but this is much better than skipping the test, until we find and fix
this issue at a later moment.
Closes#43072
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
The test may fail non-deterministically from intercepting an
heartbeat in the local storage. Only a document thread window fold
state change from the local storage should be intercepted.
Closes#43072
Issue
- Install CRM for example
- Add 41 leads
- Create an activity on each of them
Everything ok, load more shows up
- Add another activity on one of them
Load more doesn't shows up
Cause
The uniquify method:
https://github.com/odoo/odoo/blob/saas-12.3/odoo/models.py#L4187:#L4191
Consider the second activity as a duplicate and removes it.
So, in `web_search_read`:
`len(records) <= limit` is `True` and we ignore all
the others records
Solution
Add `force_search_count` in the context when using this action
to avoid uniquify to falsify the records length.
I added the tree view for this action too. It improves UX.
OPW-2165455
closesodoo/odoo#43149
X-original-commit: 13ec3503fbfb5d3d2b1e824059737bd866a3a9f4
Signed-off-by: Jason Van Malder <jvm-odoo@users.noreply.github.com>
Revision on https://github.com/odoo/odoo/commit/a55c78836f172dba1cfa6db3df0e927a9c7e6471
Before this commit, marking all messages as read from Discuss inbox
did not update the UI correctly, hence requiring a page reload.
This bug comes from a typo in the commit above, which passed a list
of mail_notification instead of message ids, so that messages were
handled as marked as read by the web client.
Task-Id 2158452
closesodoo/odoo#43109
X-original-commit: 3cc03ee3db90c310dc60fe7ea18e0e6abe741ffa
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
At model level, activity_type_id is not a mandatory field on mail.activity.
Indeed required is added in views, meaning people could have activities
without type.
This make the activity views crash with `TypeError: 'bool' object is not
subscriptable` error when computing aggregated activity data. This commit
fixes that error.
Activities without type are still not displayed in the activity view as
columns are based on available activity types. It means activities without
type have no column to be displayed. As this is a corner case that should
not happen when using activities using the interface this is considered
as a limitation of current implementation.
closesodoo/odoo#42991
X-original-commit: 77f0dd8936df3dddfa3df8041d4b7f7c62595430
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Before this commit, opening the messaging menu might be slow.
This was caused by the parsing of bodies of messages with lots of
HTML nodes. Indeed, the body of a message is linkified and inlined,
and both processes were quite slow due to their implementation: each
node in the HTML were recursively parsed and re-assigning
`innerHTML`. As a result, each node was triggering an HTML parse,
which is very slow on complex nodes.
This commit fixes this performance issue by speeding up inlining and
linkifying of html strings. In the case of linkify, it now triggers
an HTML parse only when necessary, while inlining now relies on its
textContent value.
These changes should drastically improve the speed of opening and
rendering messaging menu, almost ten times faster.
Task-Id 2076299
closesodoo/odoo#42949
X-original-commit: 8db0afb50ce0853a6a8ab7ee11dd5ed876abab64
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Steps to reproduce:
-install base_automation and contacts
-go to settings > technical > automated actions
-create an automated action on new contact creation
-set your action to "create next activity"
-leave the activity due type to blank
-trigger the automated action by creating a new contact
Previous behavior:
you get a traceback error
"TypeError: __init__() keywords must be strings"
Current behavior:
the field is required when activity_date_deadline_range is not 0
and does not allow a blank type
opw-2159755
closesodoo/odoo#42503
X-original-commit: 04dff5ad6c5935f899c7946cb1924afaea9e547c
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Method was added at cf505c3 but not used, missing cleanup according to
xdo-odoo
closesodoo/odoo#42443
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Of the rename conversation dialog
closesodoo/odoo#42630
X-original-commit: f9479456c0924c12c098edaebc2013418c09590c
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Before this commit, when "Send message" composer was open with some
suggested recipients, and then editing and saving data related to
the suggested recipients, the suggested recipients were not updated
on composer until some user interactions like page reload.
Steps to reproduce:
- Open an opportunity in CRM;
- Open "Send message" composer;
- Change "Email" field;
- Save changes;
> Suggested recipient above composer textarea is not updated with
newly saved email adress.
It becomes updated only after some user interactions, such as toggle
"Log note" then "Send message" or with a page reload.
This commit fixes the issue by updating the suggested recipients on
the composer in real-time when clicking on "Save".
Task-Id 2089816
closesodoo/odoo#40033
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Co-authored-by: Mohammed Shekha <msh@odoo.com>
Co-authored-by: Alexandre Kühn <aku@odoo.com>
Steps to reproduce:
-install projects
-go to projects > configuration > check the sub-tasks option
-create a project with a sub-task and add an activity on the sub-task
Previous behavior:
attempting to mark an activity as done directly from the chatter
will raise an error similar to
"Records does not exist or has been deleted (Record: mail.message (x), User: y)"
Current behavior:
activity can be marked as done trough the feedback button
opw-2126704
closesodoo/odoo#42383
X-original-commit: 06d72a1ab84f3685f547c8a04a2d3e1405e5d188
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Before this task, the default description and the scheduled date were placed in the left column. A lot of space was lost.
closesodoo/odoo#41090
Taskid: 2119620
Related: odoo/enterprise#6960
Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
We now also support formatting a return path when emulating incoming emails.
Purpose is to integrate some more tests in a near future about incoming
emails, notably in CRM.
This commit is a preliminary cleaning coming from task 2088565 about CRM
onchange to compute methods update.
LINKS
Task ID 2088565
Community PR #42344
Enterprise PR odoo/enterprise#7403
An override of toggle_active was present to ensure that activities
would be removed before archiving records; this commit adapts this
mechanism to take custom active fields into account, since they are
now supported at ORM-level by getting the active field through the
`_active_name` model attribute instead of blindly using the `active`
hard-coded field that was used until now..
closesodoo/odoo#40109
Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
Without demo data, for the odoo-master transifex project
closesodoo/odoo#41935
X-original-commit: dab7670b73506fb3a835695ee3bd735e0c5e5c2b
Related: odoo/enterprise#7287
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
PURPOSE
Allow to use the text field with integrated emojis support in other apps
notably mass mailing
SPECIFICATIONS
In this commit we somehow clean code related to emojis widgets
* simplify some code bits;
* update comments;
* add an option on the emojis widget to trigger ``onchange`` on a ``keydown``
event;
LINKS
Task #2117238
PR #40045
Enterprise PR odoo/enterprise#6630
PURPOSE
Allow to use the text field with integrated emojis support in other apps
notably mass mailing
SPECIFICATIONS
Currently there is one emojis enabled widget which is based on text widget.
It is therefore limited to ``<textarea/>``.
In this commit we propose to support emojis in char fields, aka using an
``<input/>``.
We therefore move most of the code within a ``FieldEmojiCommon`` and then
creates two widgets based on it
* ``text_emojis`` inherits from ``FieldText``
* ``char_emojis`` inherits from ``FieldChar``
LINKS
Task #2117238
PR #40045
Enterprise PR odoo/enterprise#6630
PURPOSE
Allow to use the text field with integrated emojis support in other apps
notably mass mailing
SPECIFICATIONS
Move emojis mixin and FieldTextEmojis field definition from social to mail
application. Rename emojis namespace accordingly.
LINKS
Task #2117238
PR #40045
Enterprise PR odoo/enterprise#6630
Timer test relies on setTimeout(..., 0) for its execution and its
verification. However it seems that in the browser there is *not always*
a guarantee that 2 setTimeout(...,0) will execute in a specific order.
Delaying the verification by 1 ms : setTimeout(..., 1) should force the
order of execution.
closesodoo/odoo#41732
Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
When editing the followers, the "pencil" icon that leads to the edition
of subtypes should be always be displayed, and not only when "debug"
mode is activated. This commit restores this behaviour, as it was not
the case any more.
opw-2144399
closesodoo/odoo#41643
X-original-commit: fd65f85e755eb0b732e0876c1849a0f4806968f1
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>