Commit Graph
11 Commits
Author SHA1 Message Date
Gorash 774a3fad0e [REF] base,all: Update modifier syntax: view migration
Apply of the migration script to update all view modifiers.

Part-of: odoo/odoo#104741
2023-08-18 09:49:13 +02:00
Julien Carion (juca) 6c412be2ea [IMP] *: coherent hotkey uses
This commit makes hotkey uses more coherent throughout the entire
codebase by setting alt+q as main shortcurt for confirm and default
actions and alt+x for cancel actions.

task-3370463

closes odoo/odoo#127469

Related: odoo/enterprise#43694
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
2023-07-19 18:24:15 +02:00
Victor Feyens 24ccf7d9b0 [CLN] *: useless type info for actions
The type fields of actions already defaults to
the model name in the base model definition.

Therefore, specifying `ir.actions.server`, `ir.actions.act_window`
& so on as type is useless (and adds noise since it's the same as
the action model).

closes odoo/odoo#114539

Related: odoo/enterprise#37855
Signed-off-by: Julien Castiaux (juc) <juc@odoo.com>
2023-03-08 17:33:37 +01:00
Pierre-Yves Dufays a556b54c89 [IMP] mail: standardize template preview form
Small refactor of the template preview form to use regular group and field tags
instead of custom layout using bootstrap.

Technical note: we weren't able to keep the model name in the label of
resource_ref so we have replaced the label with a static one: "Test Record:".
The reasons why we weren't able to keep the dynamic label are:
- a div instead a label tag is rendered with a style of width:50% which breaks
the layout (even when adding class="o_form_label"). Here we can keep the
dynamic part but we get a broken layout.
- when using a label tag for the label, the system forces us to use a "for"
attribute. But the "for" attribute replace the text content of the label by the
standard field label (here "Record"). Here we have a good layout but the label
is “Record”.
- we can override the standard field label with the attribute "string" but in
that case it is not possible to make it dynamic with the model name (field
model_id). Here it is the best we can get: a good layout and a decent label.
Unfortunately, we can't have the dynamic part of the label (the model name
here).

Task-3098782

closes odoo/odoo#109560

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2023-01-20 20:58:15 +01:00
Thibault Delavallée 7b96e7cb22 [FIX] mail: correctly display errors when previewing templates
In this commit we correctly set 'error_msg' field as computed. As it was not
defined as computed, it was not really updated and therefore not displayed
in the preview form view. It is now the case.

ValueError are now also catched, for example when having badly configured
'partner_ids' field we may face this kind of error, which is now logged
in the preview wizard.

Task-2710804 (Mail: Clean MailThread Posting API)

Part-of: odoo/odoo#99482
2023-01-17 20:58:30 +01:00
Pierre-Yves Dufays bcccd4fefb [FIX] mail: fix template preview layout
Enlarge selection fields of record and language in the template preview form so
that the labels are not truncated.

Task-3098782

closes odoo/odoo#110075

X-original-commit: f1ac110cb71d982acd9d6cdbccaf6d2415a38736
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2023-01-17 10:21:10 +01:00
niyasraphy bdd47f07ef [FIX] mail: add a placeholder on language selection
Add a placeholder to beautify the UX of mail preview wizard. Field is currently
a bit hard to sport with the new UI.

closes odoo/odoo#105751

X-original-commit: fd5a5bc38bad09e3e8e99ff22e64a5dda60e32aa
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-11-15 13:01:35 +01:00
Romeo Fragomeli 1fcd098af5 [REF] *: BS5: migration
Automated change made by a lot of RegEx to change all think that is
possible to automate.

https://getbootstrap.com/docs/5.1/migration

Task ID: 2766483

Part-of: odoo/odoo#95450
2022-07-07 13:30:24 +02:00
Julien Banken 0040a7b609 [REF] sms,mail: remove no_edit attribute from fields
It turns out that the 'no_edit' attribute of the fields is deprecated
and doesn't do anything (there is no JavaScript or Python code using it).
We will hence remove that attribute from the views to clean them.

task-2686290

closes odoo/odoo#81210

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-12-13 09:49:04 +00:00
Kevin Baptiste 86aa7b78aa [IMP] *: introduce data-hotkey on form and modal views
Define `data-hotkey` on most used action buttons.

For the modals, the following keys are dedicated for "special"
actions:
 - Alt+G: add
 - Alt+V: save
 - Alt+Z: cancel

closes odoo/odoo#73275

Taskid: 2588233
Related: odoo/enterprise#19464
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2021-07-15 08:39:49 +00:00
ryv-odoo 47ff160b42 [REF] mail: improve and refactor mail template preview
PURPOSE

Improve mail template preview wizard by improve its views and displaying
more rendered fields. It helps users knowing what will be sent to customers.

SPECIFICATIONS

Rename template model to mail_template_preview to better match the mail
template namespace.

Remove _inherit on mail.template and instead choose fields to compute
and display. Indeed lot of fields are unnecessary or badly computed.
Instead just add fields on the wizard that depends on mail template
and will be computed based on mail_template_id field of wizard.

Improve error management.

LINKS

Task 2085912
PR #38708

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-12-02 10:51:02 +00:00