Part of the overall v16 SCSS optimization/restyle, task-2704984.
task-2731819
closesodoo/odoo#83092
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
This is not a big deal, but by passing a widget instance or a DOM
node as message to a QUnit.assert function, QUnit keeps a reference
to that instance or DOM element, and it can never be garbage
collected (nor its bound handlers in the case of a DOM element).
For the mail case, this was a bit more critical as we didn't check
what the author of the test actually wanted to check.
closesodoo/odoo#83384
X-original-commit: 692fd6ecee602f7ceaae093b855aff65d50ca797
Signed-off-by: Samuel Degueldre <sad@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Before this commit, implementation of `useXToModel` performed
essentially 2 updates in succession, even when ref or component
hasn't changed.
This is a problem, especially when 2 components in hierarchy make
use of `useXToComponents`, as this could lead to infinite loops.
closesodoo/odoo#83344
X-original-commit: 95cb2648484f8529947e2bed14d86a20e6ad37b6
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
With this commit, when you perform a search in the command palette,
the part of the commandItem's name that matches the searchValue will
be highlighted.
closesodoo/odoo#82407
Task-id: 2741837
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
In the next version of Owl, all exported terms are directly available
from the top level `owl` object. This commit aims to adapt existing
imports to this new system. This is done by importing any Owl property
used in files at the top, right after the `import` or `require`
statements.
closesodoo/odoo#82736
Related: odoo/enterprise#23609
Signed-off-by: Géry Debongnie <ged@odoo.com>
Prior to this commit the 'o_Activity_details' element was using a
discontinued bootstrap class, causing the layout to brake.
task#2731819.
closesodoo/odoo#82893
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Before this PR the only purpose of the file_uploader component was to inject a
`<input type="file">` inside the DOM.
We can now create this input directly inside the FileUploader model without
register a component.
task-2727815
closesodoo/odoo#82213
Related: odoo/enterprise#23261
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit will change the setting of the emptyMessage and the
footer of the main command palette.
In order to make the command palette footer more customizable, we will
replace it with a Component. For example, using a footerComponent in the
main command palette allows us to adapt its text based on the namespaces
used.
Setting up an empty message:
Before:
```
registry.category("command_empty_list")
.add("@", _lt("No user found"));
```
After:
```
registry.category("command_setup")
.add("@", {
emptyMessage: _lt("No user found"),
});
```
With this commit, it is possible to add a namespace to the footer tips:
```
registry.category("command_setup")
.add("@", {
name: _lt("channels"),
});
```
closesodoo/odoo#82541
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
With the idea of maybe merging the concepts of causal relations and
identifying fields, change the identifying fields so that their inverses
are the only fields with `isCausal: true`.
closesodoo/odoo#82521
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
- Move extra class to field to avoid reliance on specific template.
- Rename prop to be generic.
- Remove extra margin-top in message view outside of thread view (bonus fix).
- Move code using message view component out of message list update to break
infinite loop.
task-2728107
closesodoo/odoo#82415
X-original-commit: c002adeedeffa23190c7853a9d9643da7825ea33
Related: odoo/enterprise#23331
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Before this commit, attachments in attachment box (chatter) had no
left padding.
Mistakenly introduced by https://github.com/odoo/odoo/pull/80060
which changes classname passing from parent component to child
component with `t-attf-class`. AttachmentCard and AttachmentImage
components did not `t-attf-class` not on root node, which caused
the broken style that this commit fixes.
closesodoo/odoo#82515
X-original-commit: 429bcbcaad5164e9ecf6f518d4e5b0d1ada0bc4a
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Previously, relational required fields had their auto-generated inverses
defined with `isCausal: true`, which seemed logical: if a record is
deleted, all the records that depend on it must be deleted too.
In practice, it turned out to be a bad idea since there are some cases
where you don't want the dependent records to be deleted. For example,
there is no point in deleting the current record when a required field
is replaced by another one.
Furthermore, this actually led to the introduction of new bugs, as the
one described in task-2730667.
Fixes bug described in task-2730667.
Reverts some of these changes: https://github.com/odoo/odoo/pull/81679closesodoo/odoo#82437
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
This PR make the activity popover test use the mock model and a chatter as
component.
closesodoo/odoo#82143
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
* When a user is already muted when setting their state as deafened
the mute state should remain after the deafen state is removed.
* When a user clicks the microphone (mute/unmute) button while being in
the deaf state, the user should end up undeafen and unmute.
task-2720026
closesodoo/odoo#82197
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit fixes a case where the track could be left enabled when
transitioning from voice activation to push-to-talk (the track would
still properly be disabled on the next release of the push-to-talk key).
part of task-2720026
closesodoo/odoo#82273
X-original-commit: 96804f4eba76ce3c016ae34a9829f88ab8c7e0f3
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit renames the isMuted variable into isSelfMuted to reflect the
user action of self muting, as opposed to the state of being mute,
which will be distinct in an upcoming commit.
part of task-2720026
closesodoo/odoo#82199
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Before this PR, the guest that just connect wouldn't receive the longpolling
message before the current one expire.
task-2664831
closesodoo/odoo#82170
X-original-commit: 0006123dba46d32d062a581e9a16f433f3ce05f3
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Before this commit temporary id could match an existing attachment id and
replace that attachment by the new uploaded one.
Even if this is very unlikly, using a negative id avoid it completly.
closesodoo/odoo#82185
X-original-commit: c18705d1ced6a9b1d6bb8c33049a1248ae83cf18
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Before the PR, when replying to an empty (only attachment) nothing was display
in the message reply preview. This PR introduce a placeholder to handle this
case.
Also taking to opportunity to add missing translations.
task-2664815
closesodoo/odoo#81996
X-original-commit: 60f68512fdc9ebfb2d9331790be5884a86cce67b
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Step to reproduce:
- Settings -> Mail channel -> any chat-type channel
- Go to Members
- Add an user
- Refresh the page
Current Behaviour:
- Traceback
- Chat are designed for 2 users and you should not be able to add more
Behaviour after PR:
- Can only edit members of channel if it's not a chat
- User error if try to add more user
- Fix traceback if there is too much users
opw-2717341
closesodoo/odoo#82044
X-original-commit: 85f7b7c1304222966610833dc325bc47f1c13158
Related: odoo/enterprise#23156
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Invalid data provided at record creation were silently skipped by the
framework without triggering an error. This commit ensures that data are
no longer accidentally filtered and therefore that an error will be
raised if a key that does not match an actual field is provided.
This commit also removes the dead code that was detected thanks to these
changes.
closesodoo/odoo#81909
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
In preparation for using OWL v2 in discuss code.
(shouldUpdateBasedOnProps will be removed)
Solution consists of introducing MobileMessagingNavbarView model.
Task-2695743
closesodoo/odoo#80617
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>