Commit Graph
3105 Commits
Author SHA1 Message Date
Xavier Dubuc 607ac6e912 [FIX] mail: do not show new messages separator for own messages
Also fix compute of local counter in some specific situations.

task-2341740

closes odoo/odoo#58866

X-original-commit: 0df66708defd0fcb288979b1431d8180831e43d3
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-29 18:36:38 +00:00
Xavier Dubuc 52dfe6a4e1 [IMP] mail, website_livechat: bring back visitor banner in discuss
task-2276589

closes odoo/odoo#58858

X-original-commit: 65dbe1c4760e2ffe104426f9aa41007a10dc32f0
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-29 17:39:13 +00:00
Didier (did) 5be44732cb [FIX] mail: guard the thread name and test the fallback
task-2343800

closes odoo/odoo#58848

X-original-commit: 13d78eda1243a5a625473adbae981b2891221ffc
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-29 15:36:10 +00:00
Didier (did) 91f9520ef0 [FIX] mail: avoid loading state when a new message is posted
task-2346786

closes odoo/odoo#58849

X-original-commit: cfc280f5386de44ffac1c1c27e8a0a7d928a8424
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-29 15:37:39 +00:00
Sébastien Theys 45818cc1aa [FIX] mail: fix tour to allow public or private channel selection
task-2313321

closes odoo/odoo#58838

X-original-commit: 07ef748c542cb20fdab4f0d9c02a87fb07bede3c
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-29 14:55:17 +00:00
Sébastien Theys 5d3686556f [FIX] mail: properly clear chatter id on new record
task-2348372

closes odoo/odoo#58824

X-original-commit: 189ff0af0ac209624910a7674f543d2d58ecb94f
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-29 14:09:35 +00:00
Sébastien Theys a409fbdc5a [FIX] mail: prevent sync fold state for non-channels
task-2346650

closes odoo/odoo#58801

X-original-commit: f5b6e78e77eac27af3b3812ac3818a67acaa1c85
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-29 11:45:53 +00:00
Alexandre Kühn 7a0aecfca9 [FIX] im_livechat, mail, website_livechat: open chat website visitor
Also fix an issue with livechats not being considered in 'chat'
filter of messaging menu.

Task-Id 2282426

closes odoo/odoo#58468

X-original-commit: 631e52536964763bbfe857305f023e5e67084e95
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-24 18:25:12 +00:00
Romain Estievenart 17b6674ca2 [FIX] mail: Mailbox is half loaded on mobile
Before this commit on mobile when you come to odoo from a notification
url like:
https://my_domain/web#action=mail.action_discuss&active_id=1&menu_id=93
a traceback occurs on mobile discuss wasn't loaded correctly and the
content didn't appear.

With this commit, it's open the related discuss thread.
It's also ensure the return to the chat tab when you close a chat and
the return to the channel tab when you close a channel conversation.

We also ensure the loading of the inbox items when you navigating on
the mobile discuss button.

Steps to reproduce:

1. Open a chat from a mobile notification
2. A traceback occurs

opw-2310319

closes odoo/odoo#58431

X-original-commit: 8ca5024bef246c93bbb7522d77aca4c4ba7a33b4
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-24 13:14:40 +00:00
Priyanka Kakadiya b0e2894161 [FIX] mail: fix tracking value issue when value is 0
Before this commit:

When a tracking field is set to 0, the mail tracking value doesn't display 0 in
the chatter. It is empty instead
i.e:  Field Name: 1 ->

After this commit:

Tracking value will show the changed value even if it is false or 0
i.e: Field name: 1 -> 0

closes odoo/odoo#58423

Task: 2334048
Closes: https://github.com/odoo/odoo/pull/57342
X-original-commit: 57f4018694a895fd804b51e8206503e3d1d3c5d4
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-24 12:27:05 +00:00
Xavier Dubuc 9e60f0d3f3 [FIX] mail: use compute fields for identifying relations
(in message seen indicators)

task-2335647

closes odoo/odoo#58375

X-original-commit: 3d4ff42f4474a5761c9e0737297d973992a2fcc2
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-23 19:17:36 +00:00
Didier (did)andSébastien Theys add71e94b5 [FIX] mail: compute display_name for partner and user
task-2322135

closes odoo/odoo#58374

X-original-commit: d9bdbde95c3694ecdaccd58b5475631137c22e93
Related: odoo/enterprise#13478
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Co-authored-by: Sébastien Theys <seb@odoo.com>
2020-09-23 18:59:24 +00:00
Sébastien Theys 7574797589 [FIX] mail: prevent unnecessary fold state RPC
When the pending value is the same as the current server value, the pending
value should be ignored and no RPC should be done.

In particular this prevents a non-main tab from calling the RPC when receiving
a bus notification that would lead to closing a chat window, which in turn used
to call the close RPC again before this commit.
This led to inconsistencies especially on the main tab, if the chat window was
requested to be open again after the initial close, but before the "secondary"
close, it would end up closing instead of opening.

The current commit reduces the issue and prevents as many unnecessary RPC as
there are tabs open, which is a good improvement.

But it does not negate it completely. Indeed, when quickly closing then opening
the same chat window, it might still happen for network reasons that the RPC or
the corresponding bus notifications are received in the wrong order. This is
less frequent both functionally (to click so fast) and technically (to have the
network that slow) at the same time, so it is considering acceptable / out of
scope.

The opportunity is taken to clean up the code by removing unnecessary fields and
making use of compute and flux specific RPC instead of `_updateAfter`.

task-2273658
task-2329521

closes odoo/odoo#58369

X-original-commit: cbb1d855c7af5f78819db3cd476dbe0f985bc214
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-23 17:30:41 +00:00
Sébastien Theys 8f857def1d [FIX] mail: add emoji popover max width
Emoji popover should be rather narrow, it doesn't look good to have one line
of emojis taking the whole screen. The goal is too keep the choices in close
range of the open button for quick selection.

Part of task-2270731

X-original-commit: 75d742f4e48c836f74bc7beee10c89ea544173eb
2020-09-23 17:32:34 +00:00
Sébastien Theys 0ff9eb7307 [FIX] web, mail: recompute popover on content change
Because the position of the popover depends on the size of its content.

Part of task-2270731

X-original-commit: 3066a946ef1ca0973503207d0486515798168fa2
2020-09-23 17:32:33 +00:00
Didier (did) 3c12f91fda [FIX] mail: avoid flicker when uploading multiple attachement
task-2282327

closes odoo/odoo#58358

X-original-commit: 413c6c406eac52048b9a0b80c7ee46efe5b061c4
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-23 14:27:20 +00:00
Sébastien Theys ff209a8b36 [FIX] mail: allow to open record thread in chat window
task-2171885

closes odoo/odoo#58324

X-original-commit: af6e68c2c5bd819402af0126c87f375e096c8d0d
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-23 11:01:18 +00:00
Sébastien Theys 44b557777f [FIX] mail: ignore undefined in JS fields create/write
Passing a field containing `undefined` should lead to the same result as not
passing the field.

Fields that relied on `undefined` as a value have been changed to use the newly
introduced `clear` command, that resets a field to its default value (often
that is equal to `undefined`).

task-2336491

closes odoo/odoo#58314

X-original-commit: b18824485483564d2ab80f41914a3548aa528ae0
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-23 10:19:14 +00:00
Didier (did) eb1ddf99cb [FIX] mail: align the chatter topbar height and form view statusbar
task-2341787

closes odoo/odoo#58262

X-original-commit: 37a0203c1cfb2567c418016424cd04dea27e2557
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-22 16:01:37 +00:00
Didier (did) c8b1353841 [FIX] mail: do not show "load more" on temporary thread
task-2341690

closes odoo/odoo#58251

X-original-commit: 9b56c82d3a4b07730490816a67911cbf60900158
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-22 15:14:33 +00:00
Julien Giannone 9fc3fe1dba [IMP] mail: reintroduce channel mentions, canned responses, commands
task-2280308

closes odoo/odoo#58167

X-original-commit: b63d0d2ee5f3bff24a5e1e1cd962d59bebef082d
Related: odoo/enterprise#13393
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-21 21:12:22 +00:00
Didier (did) d68bdf8720 [FIX] mail: restore the "to followers" feature
Before this commit, the "to followers" message inside the chatter composer was
missing.
Fix also some padding issue.

This also restore the form dialog when you try to send a message to a suggested
recipient that doesn't have a partner (someone in CC email for eg).
But now, suggested recipient without partner are unchecked by default and the
form open when the user try to check them. If the user discard the form dialog,
the suggested recipient isn't checked.
This is better since only a partner will receive a notification.

task-2280157

closes odoo/odoo#58162

X-original-commit: 67d151cc36871d87b92676357a31a70de5a92fce
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-21 17:12:43 +00:00
Xavier Dubuc 356a5448fe [FIX] mail: fix notification partners display in popover
Handle notification creation in convertData correctly.

task-2324260

closes odoo/odoo#58013

X-original-commit: ca457e990c87cd0405a2b7416a6c8064a9a83e21
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-18 09:42:09 +00:00
Xavier Dubuc b2d9170aef [FIX] mail: fix "New messages" separator and channel_seen behaviour
- channel_seen is now called even for own message and only when needed
- channel_seen is now called with a message_id which transfer the
  decision of what is seen to the client which makes more sense

task-2282235
task-2282248

closes odoo/odoo#57956

X-original-commit: 04edfa50ccea305050d017c4a1996e561bc7bd57
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-17 13:45:35 +00:00
Didier (did) 711e8addf5 [FIX] mail: send the correct args to the message_unsubscribe method
Before this commit it was not possible to remove a channel from the followers.

task-2324263

closes odoo/odoo#57817

X-original-commit: 9a065048bbdd09072084d03e67fd012766ddbe23
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-16 10:41:17 +00:00
Alexandre Kühn 74ae95db22 [FIX] mail: do not fetch attachment style in QUnit tests
Task-2339931

closes odoo/odoo#57875

X-original-commit: 7586f7756859bb0711eee8a82bf728a039ad0d72
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-16 15:28:00 +00:00
Francois (fge) ab59d0bf09 [FIX] mail: no longer display unlinked attachments in chatter
Task-2337952

closes odoo/odoo#57631

X-original-commit: 55cb4a82ce2b59bc73ea05afa5971c96989b6159
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-14 11:01:15 +00:00
Xavier Dubuc 06aef5e05f [FIX] mail: allow temporary attachment to be canceled
task-2324065

closes odoo/odoo#57623

X-original-commit: 9f774d4fb512017ab5f99981255afc8d2c35113c
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-14 10:08:50 +00:00
Didier (did) 6c54a5c6d2 [FIX] mail: avoid star flicker when hovering a message
task-2278441

closes odoo/odoo#57575

X-original-commit: 35e1a675803e64eda0fdae402cbddb56d5c0b1d8
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-11 16:55:29 +00:00
Didier (did) 9bc4d91960 [FIX] mail: fix image ratio on composer and thread preview
task-2318662

closes odoo/odoo#57522

X-original-commit: 1cd5712ff7f04b2fdb185f4fe78dbd3f4f75b801
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-11 11:52:19 +00:00
Alexandre Kühn 8be77ece37 [FIX] im_livechat, mail, website_livechat: invite button in livechats
Task-2334724

closes odoo/odoo#57511

X-original-commit: 5316c91c27e48bfaa3ebf3fb97e35220fabc986e
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-11 11:07:12 +00:00
Didier (did) 7352aa6e26 [FIX] mail: move attachment icon on the right (chatter top bar)
task-2333122

closes odoo/odoo#57453

X-original-commit: 0708b38d2512900d3456a9560673171c1286e571
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-10 15:38:12 +00:00
Xavier Dubuc 48bce60f02 [FIX] mail: remove no more needed root div node in moderation dialogs
task-2310610

closes odoo/odoo#57448

X-original-commit: 76c2eb1590b360a874ef5ccb0df7edf0f1b84bab
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-10 15:02:33 +00:00
Didier (did) 2559787fc9 [FIX] mail: allow overflow on the chatter
task-2333128

closes odoo/odoo#57447

X-original-commit: d04d2933d72376c80ceb2f1e6769d4a5785f08dc
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-10 15:02:07 +00:00
Sébastien Theys 618c77259b [FIX] mail: allow tests to await specific events
task-2333915

closes odoo/odoo#57187

X-original-commit: 699106ce65a87f7a24f04e1d8f232b5a6b4e210a
Related: odoo/enterprise#13018
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-07 13:16:18 +00:00
Didier (did) 0cde1189c6 [FIX] mail: chatwindow scroll to the last message when posting
Before this commit, when a user posted a message from a chatwindow, the scroll
did not move to the last message.

task-2314409

closes odoo/odoo#57183

X-original-commit: 8e4f133890b08e7e9a909abbc97b89bb5409119a
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-07 12:17:39 +00:00
Xavier Dubuc 8d96bfd080 [FIX] mail, sms, snailmail: prevent message_fetch for hidden threads
Automatically load messages from a thread cache only if the thread cache is used
in at least one thread view.

Ensure thread viewer don't keep thread view records alive when they are not
displayed.

This change is particularly important for performance, to avoid spamming RPC at
init if many threads are opened in chat windows.

task-2310623

closes odoo/odoo#57121

X-original-commit: 8d3413ff647de8d98c6858062dd07dde4160af95
Related: odoo/enterprise#12979
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-04 17:01:43 +00:00
Alexandre Kühn f20adc19d2 [FIX] mail:tests: "Timeout: the render didn't stop."
These tests assert that some user interactions didn't do something.
The user interactions were mistakenly expecting to trigger some
re-render.

Task-2333810

closes odoo/odoo#57091

X-original-commit: b4c4086104d815442ff6f2e92f80513f2ffad5ab
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-04 12:08:18 +00:00
Xavier Dubuc 09c77f6c89 [FIX] mail: allow composer text input to send message with ctrl+enter
Also allow meta+enter

task-2296863

closes odoo/odoo#57050

X-original-commit: 6bad3666be3d3631eaadae409d0cabcdd02661a8
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-03 15:01:39 +00:00
Sébastien Theys e338dc82a6 [FIX] mail: add open chat when clicking on author im status icon
task-2329538

closes odoo/odoo#57015

X-original-commit: bfb8d99baaadedb2d0492b6f378b13b3330d496a
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-03 10:00:23 +00:00
Sébastien Theys c4c1f20862 [FIX] mail: prevent crash when switching mailbox in discuss mobile
task-2327203

closes odoo/odoo#56939

X-original-commit: 612a8f7edf3d01ec2b854839ee60be418cb141a7
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-02 11:36:05 +00:00
Sébastien Theys a0c7b35237 [FIX] mail: display subject of mailing channels in italic
task-2321974

closes odoo/odoo#56928

X-original-commit: 7b06b094bd4ee4008fa29dd8d3db79275d4cde1f
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-02 09:38:06 +00:00
Alexandre Kühn de57a2db14 [FIX] mail: message/activity link with dataset oe-id and oe-model
Task-2328718

closes odoo/odoo#56872

X-original-commit: 430aa0c2ffe242992fb935733d81f6e05a6d2458
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-01 11:28:05 +00:00
Sébastien Theys 590a088750 [FIX] mail, *: fix opens and redirects, adapt messaging menu close
task-2244279
task-2262862
task-2274993
task-2277537
task-2282238

closes odoo/odoo#56755

X-original-commit: 17611f4adc5e950b0a75a2a6615b1da3c956387f
Related: odoo/enterprise#12769
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-28 17:34:13 +00:00
Sébastien Theys 6d9499fcce [FIX] mail, *: rename thread viewer to thread view
The "viewer" should be the "parent" not the view itself. This distinction will
become important in a future commit to allow viewers to not display the view in
some situations.

Rename done as a standalone commit to ease diff readability.

Part of task-2310623

closes odoo/odoo#56751

X-original-commit: f9ee1cf5f904116e4d1d70a8eaf4ee1d58b18a3a
Related: odoo/enterprise#12764
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-28 15:34:40 +00:00
Sébastien Theys 9965e35490 [FIX] mail: prevent "record created" from being twice in the chatter
task-2280184

closes odoo/odoo#56694

X-original-commit: 1af2cc1b2190623739085de83870fb415cbdccf1
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-27 17:14:52 +00:00
Alexandre Kühn b18ec3b024 [FIX] mail: 'Cannot read messagingMenu of undefined' traceback
Before this commit, on page reload, sometimes web client crashed with
`Cannot read 'messagingMenu' of undefined`.

This happens due to messaging components making use of `messaging` in
`env` as if it was always set. In some rare cases, this is false,
hence the crash. This happens on root components of messaging such as
the messaging menu.

Creation of `env.messaging` has to be async, in other to ensure all
JS module that patches messaging are applied. The mounting of
messaging root components depends on other parts of the web client
like the SystrayMenu. So the proper fix is to guard `env.messaging`
on these root components.

Task-2238245

closes odoo/odoo#56684

X-original-commit: d1483ff3c83bb3146e80e5d65a27915c5b2a2bf9
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-27 15:53:02 +00:00
Didier (did) bc5654f0a4 [IMP] mail, mail_bot: move notif request and OdooBot name into mail
task-2282334

closes odoo/odoo#56616

X-original-commit: bde23b82029507e525cf55d11b050af5f820a06b
Related: odoo/upgrade#1705
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-26 15:49:21 +00:00
Didier (did) 14d6393594 [FIX] mail: fix margin issue when an activity is marked done
task-2280172

closes odoo/odoo#56538

X-original-commit: 16f705d8c9434bbbdf8a8987edb2ba325aa9f307
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-08-25 16:21:51 +00:00
Didier (did) db0e95e368 [FIX] mail: reduce vertical spacing for tracking messages
task-2282385

closes odoo/odoo#56492

X-original-commit: c80ed69bb5b06d3df18a6491c1b889fcdb0de741
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-08-25 10:31:52 +00:00