Commit Graph
1443 Commits
Author SHA1 Message Date
Louis (wil) 3f6f949fa5 [I18N] export sources
closes odoo/odoo#140002

Related: odoo/enterprise#49687
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-10-27 08:36:16 +00:00
Aman Patel a56dfd43a2 [FIX] fleet: change Co2 text to CO2
Steps:
- Install fleet.
- Create new. Select a car.
- Goto `Model` page.
- Below CO2 Emissions string there is Co2 Standard string.

Issue:
- In the Engine section, there is a `CO2 Emissions` and a `Co2 Standard` field.
If these are both referring to carbon dioxide, then they should be written
consistently in the same format (CO2). Currently, one has a lowercase `o` while
the other (correct) one has a capital `O`.

Fix:
We are adding the necessary string.

task-3498197

closes odoo/odoo#139761

X-original-commit: 8b4a22baa92f196361f1ef622b55312015cf8128
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2023-10-25 20:56:16 +00:00
Yannick Tivisse 7ebafb1eb7 [IMP] base: Remove manager rights to user demo
closes odoo/odoo#139731

Related: odoo/enterprise#49562
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2023-10-25 20:56:11 +00:00
Xavier Morel 9ebbfdac73 [FIX] *: incorrect translations markings
Fixes a large number of cases where strings are translated then
formatted, instead of letting `_()` do the formatting internally,
which allows it to recover from incorrect translations (missing,
broken, or extra placeholders).

Also

- removes translation markers entirely when there's nothing to
  translate e.g. `_("%s - %s")` is not useful
- fixes a few messes which lead to only partial translatability
  (DRY is generally a bad idea when translations are involved, even
  more so when you don't make the variable part translatable)
- fixes a few nearby issues noticed at the same time
- replaces a few `"%s"` by `%r`, which should automatically quote
  strings relatively appropriately
- fixes translated strings which use `\` to escape a newline (in order
  to fill-paragraph): `\` escapes only the newline, if the
  continuation string is indented this results in a bunch of spaces
  ending in the string to translate, which is pretty garbage for the
  translator, using implicit concatenation works much better

Note: some of the updates revert f-string parameters to %, because
babel (2.9) apparently has trouble with f-strings and blows up trying
to extract them.

Not in scope:

Helping translators fix translatable strings e.g. any translation
string with more than one placeholder probably should use keyword
placeholders

- Provides more context / data to the translator to make sense of the
  sentence.
- Allows reordering the translated terms, which can be necessary
  depending on the sentence and language.

closes odoo/odoo#139314

Related: odoo/enterprise#49311
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2023-10-23 16:45:09 +00:00
Adrien Schoffeniels 31af631607 [IMP] *: add properties fields to various models
Purpose:
--------
This commit adds properties (and related properties definitions) on the
following models:
- hr.employee (hr.department)
- hr_recruitment.hr_applicant (hr_recruitment.hr_job)
- product.product (product.category)
- stock.picking (stock.picking_type)

These have been added to the related form, kanban and calendar views when
applicable.

Properties have also been added to kanban and calendar views of
- crm.lead
- event.event
- project.task
(Properties had already been added on these models and form views)

Task-3458627

Part-of: odoo/odoo#132578
2023-10-20 11:21:56 +00:00
Adrien Schoffeniels b8b450544c [IMP] web: remove hideKanbanOption from properties field
Purpose:
--------
This commit removes the "hideKanbanOption" from the properties field.
This option allowed to prevent users to make properties visible on cards
(kanban cards and calendar popovers).
The rationale being that there is no reason to prevent users of adding
properties on cards now that they have been redesigned (see commit [1]).

Task-3458627

[1]: https://github.com/odoo/odoo/commit/25e8fbe0a1327c289df826cf6eb7882098a4c325

Part-of: odoo/odoo#132578
2023-10-20 11:21:56 +00:00
Pierre-Yves Dufays 725e7ffae3 [IMP] various: improve custom activity views
The following summary view of the record in the activity views have been
improved:
- project_task: task state added
- project_project: project manager added
- event_event: responsible and the dates (date_begin_located and
date_end_located) added
- account_move: total amount, customer and state added
- sale_order: total amount and the state added
- purchase_order: total amount and the state added
- crm_lead: customer and stage added
- hr_applicant (hr_recruitment): recruiter added
- survey_survey: responsible added
- maintenance.request: added equipment and responsible
- stock.picking: added scheduled_date
- repair.order: responsible, schedule_date and product_id added
- mrp.production: added responsible
- hr_leave (hr_holidays): status is added and default deadline modified see
below

Ensures that "Schedule activity" is in one line by adding a colspan.

hr_leave activity: When a time off approval activity is created as a
consequence of the creation of a hr.leave, the deadline of the activity is set
to the date_from of the hr.leave minus activity type delay_count (default 15)
except if it leads to a date anterior to today. In that case it is set to
today. That way, in the activity view, the time off approval activities are
more or less sorted by related hr.leave date_from and the cell date is an
indication of when the time off is planned.

Technical note: on most activity view, the activity record was not occupying
all the horizontal space. To solve that problem the css has been modified and
the max-width (200) that was imposed on the sub div has been removed. And as
it was impossible to impose a max-width for a flex div (which is the common
case for the activity record), the max width is imposed on each text that might
be too long using the class o_text_block. That class has been modified to
impose a max-width. That's why that class has been added in most view.
Alternativly, we could have modified the activity compiler to add that class
when the attribute full was set (not done because not sure of the consequence).

Task-3300854

Part-of: odoo/odoo#138135
2023-10-19 19:08:12 +00:00
Brieuc-brd 538fdab99b [IMP] *: fine-tune app icons
The aim of this commit is to improve the impact and rendering of app
icons in bright and dark mode. It also reduces the size of svg files.

To achieve that, this commit updates the colors to flat colors. This
change will make the icons stand out and improve their readability.

task-3072562

X-original-commit: 667a19162b74fb6554a2389ba9c6e69de4ff5113
Part-of: odoo/odoo#138279
2023-10-16 09:21:17 +00:00
rupa-odoo 0441f7c0d0 [IMP] fleet: changed tree view to editable
Before these commit :
field are not editable in the tree view when we click on
the field its open the form view.
After these commit :
Now the fields are editable through the checkbox in tree view.

task-3487625

closes odoo/odoo#134132

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2023-10-12 16:11:53 +00:00
Adrien Schoffeniels 2d7a49dab1 [IMP] web: move properties field's "add a property" btn in the cog menu
Purpose:
--------
When the property field is added into a form view, the "add a property"
button is shown by default.
However, most of the time the users won't add properties when opening a
form view, making this button take up space for nothing.

To alleviate this issue, commit [1] added an option that allows to hide
this button, and added actions to allow adding properties from the cog
menu instead.

Now that properties are being added into several views, one would like
this "add properties" button to be hidden by default, and show an entry
in the cogmenu allowing add properties by default, without needing to
create an action for every view using a property field.
Therefore, a new static action "Add Properties" has been added in the form
controller that is available if a properties field has been encountered
during the parsing of the form view's arch.

The "hideAddButton" has been changed into "showAddButton" and now allows
to show the "Add a Property" by default.

Task-3458627

[1]: https://github.com/odoo/odoo/commit/1f80810e39f811122a65e11cd8cac99aa39a7960

Part-of: odoo/odoo#137589
2023-10-11 17:02:02 +00:00
Louis Wicket (wil) 4adaeabc22 [I18N] fleet: replace “immatriculation” with “registration”
The word “immatriculation” doesn't exist in English.
This commit replaces its occurrences with “registration”.

closes odoo/odoo#137755

X-original-commit: 740979ef152f5cc89682004f9453a03e565bf6ec
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-10-09 13:25:38 +00:00
shag-odoo dd5e3b97f0 [IMP] fleet: improve length of model field
Improvement:
Following this commit the length of model field inside form view of vehicle is
expanded.

closes odoo/odoo#133431

Taskid: 3477830
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
2023-09-29 16:08:44 +00:00
Thomas Lefebvre (thle) dbd9942c21 [FIX] fleet: manage recurring yearly costs in report
Issue:
------
Contracts with a "Yearly" recurring cost
are not applied every year in the report.

Cause:
------
We use truncation to compare dates.

The following condition:
```sql
date_trunc('month', coy.date) = date_trunc('month', d)
```
can be read as:
"When year and month are the same".

The `date_trunc` function sets to "zero" the parts of the date we want to truncate.

This is why the recurrence only appears for one year.

Solution:
---------
Use the date comparison provided with postgresql
and use `date_part` function to check the month.

opw-3468253

closes odoo/odoo#137060

X-original-commit: f2ed4a179bb10cbca1d095389deac75dd8ca054f
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Signed-off-by: Thomas Lefebvre (thle) <thle@odoo.com>
2023-09-29 10:41:50 +00:00
stefanorigano (SRI)andBrieuc-brd 46dca09cc4 [FIX] web, crm, fleet, sale: font-weight
Establish a set of target font-weight values (may not directly match the
final result on screen).
Enable the system to naturally utilize the "bolder" font-weight.
Remove previous customizations designed for "Roboto" that clashed
with certain system-fonts.
Enforce the "normal" font-weight for icons, regardless by their parent
design.
Adapts some kanban titles.

closes odoo/odoo#134824

X-original-commit: 74fce06cad4000a3894757d4fef9074b64153b7b
Related: odoo/enterprise#47140
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Co-authored-by: Brieuc-brd <brd@odoo.com>
2023-09-13 12:19:04 +00:00
shag-odoo fce75633ed [IMP] fleet: track state
Purpose:
Prior state was not tracked for 'Services for vehicles' and
it was not possible to know when service started and when it was done.

task-3469567

closes odoo/odoo#132338

Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
2023-09-06 16:19:51 +00:00
shag-odoo f581d4ad17 [IMP] fleet: improve the search positioning and add filter_domain
Before this commit, the 'Current Driver(Employee)' option was present within the
search menu and appeared as the last choice in the search list.

IMP:
Following this commit, the 'Current Driver(Employee)' is been
removed and all its functionality is implemented in Driver.

closes odoo/odoo#131512

Taskid: 3459896
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
2023-09-05 19:58:00 +00:00
Elisabeth Dickinson bd755e6ac6 [FIX] fleet, hr_*: fix many2one_avatar_user occurrences
*: attendance, expense, holidays

In commit d832fcf, the
`many2one_avatar_user` widget has been added in various places,
sometimes repeating the avatar where it isn't needed.

Some occurrences come next to the avatar's name which is called via a
`t-esc`, but the option `display_avatar_name` is available and has been
used instead.

task-3470340
part of task-3326263

closes odoo/odoo#133150

X-original-commit: 0b268a9e3c31d5b57bb9f60ea93153289d02ddf9
Related: odoo/enterprise#46286
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-08-30 09:25:10 +00:00
Jurgen (jugj) 6673a5b304 [FIX] l10n_be_hr_payroll_(fleet): Fix Bike tax deduction computation
closes odoo/odoo#133243

X-original-commit: 7bdb6e66e8d34b7a9af824817b51c7b307686fef
Related: odoo/enterprise#46362
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Signed-off-by: Jurgen Gjini (jugj) <jugj@odoo.com>
2023-08-28 23:14:01 +00:00
abd-msyukyu-odoo 44b53f6de3 [IMP] *: add name to Form notebook pages to be used in Knowledge
Knowledge macros rely on the `name` attribute of a notebook page to switch
between tabs in a Form notebook. That attribute is not mandatory, so some views
with a valid `html_field` did not have one. This commit adds the `name`
attribute so those fields can now be manipulated by Knowledge macros.

See `searchInXmlDocNotebookTab` in `abstract_macro.js` for more details about
the usage of the `name` attribute in Knowledge macros.

task-3410128

closes odoo/odoo#132824

Related: odoo/enterprise#46146
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2023-08-24 18:37:51 +02:00
Jurgen (jugj) 7edde43100 [FIX] fleet: Take into account vehicle type when applying new drivers
In this PR we fix the current behavior :
When you apply a new driver to a vehicle, all other vehicles having that driver as current driver will have their
driver_id set to false, but if we are applying a new driver to a bike, we don't want his car, if he has one to be unassigned from him.
task-3463518

closes odoo/odoo#131840

X-original-commit: 7649f45ee45aea152224e4ff0fe9b9430ad3c9f8
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
2023-08-21 12:39:14 +02:00
Pierre Pulinckx (pipu) c07181b20b [REF] *: Replace env._t() by _t()
In this commit, all usages of env._t() are replaced by _t().
In templates files, env._t() didn't work because terms used
in attributes where not extracted into the translation files.
Only string are exported from .xml files to translation files.
So, to make it works, we set a variable that is then used
in attributes.
For example :

<t t-set="string_to_translate">String to translate</t>
<Dialog title="string_to_translate>...</Dialog>

task-3292454

closes odoo/odoo#131390

Related: odoo/enterprise#45631
Signed-off-by: Michaël Mattiello (mcm) <mcm@odoo.com>
2023-08-18 19:17:16 +02:00
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
Yannick Tivisse 743d75206c [IMP] fleet: Improve vehicle creation + general UX
Purpose
=======

When you create a vehicle, there is no sense in adding it to the
"registered column", you always start at the first stage. And this
is also very subjective to create a contract for one year. Why ?
In addition, the contract is empty, excepted for the date.

Specification
=============

- When you create a vehicle, his stage is : New Request

- On the contract form view, make the vehicle's field editable,
  the driver is always related to the vehicle.

- Allow to add property fields on vehicle and model

closes odoo/odoo#127298

Taskid: 3349871
Related: odoo/enterprise#43627
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2023-08-17 18:42:15 +02:00
Jurgen (jugj) f1e17a30f7 [IMP] fleet : Add D.E.A history view for Belgium
In this PR we add the automatic encoding of disallowed expenses rates for fleet based on tax deduction
task-3186404

closes odoo/odoo#125548

Related: odoo/enterprise#42768
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
2023-08-02 15:59:33 +02:00
Louis Wicket (wil) 7da30c7d14 [FIX] mail, *: fix grammar error in field help
This commit fixes a really old grammar error in the help message of the
message_needaction_counter field.

Before this commit: “Number of messages which requires an action”
After: “Number of messages requiring action”

The subject of “require” is “messages”, which is third-person plural, so
it can't take the -s suffix.

closes odoo/odoo#129468

X-original-commit: 0d10cfeaa56d5df23df05f436d353978043f4a71
Related: odoo/enterprise#44509
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-07-25 17:36:08 +02:00
william-andre 0479b2b594 [IMP] account,*: manage subsidiary companies
Allow sharing records between company
* accounts
* taxes
* fiscal positions
* products
* ...and some related models

These records can be read and used in children companies.

This can be used to
* have different branding for different businesses
* allow more complex security rules
* consolidate branches differently
* manage different tax reports with different tax ids in the same
  country

task-3371677

closes odoo/odoo#125642

Related: odoo/enterprise#43215
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2023-07-20 11:49:06 +02:00
prye-odoo 7694f012cd [FIX] *: handle unlink/create access for reporting views
*: account,event_sale,fleet,hr_attendance,hr_contract,hr_timesheet,
im_livechat,point_of_sale,project

When the user tries to delete a record(s) from the reporting views,  this
traceback will be generated.

Steps to produce (Example only):

- Settings > Technical > Actions > Window Actions
- Search for the Work Entries Analysis. Open it and add a 'tree' as view_mode
in that action.
- Payroll > Reporting > Work Entries Analysis menu and select the tree view.
- Select one or more records and try to delete these records.

Error: A traceback appears: "cannot delete from view "hr_work_entry_report"

Handled the unlink access by using their model access of the reporting models.
similarly, this issue resolves in other reporting models.

Sentry-3975590063

closes odoo/odoo#125697

X-original-commit: 209d8c76ce9bb1d6cc7084d55b5623e939af8fbc
Related: odoo/enterprise#42825
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2023-07-03 21:55:48 +02:00
Rémy Voet (ryv) c5cb357d90 [IMP] *: add dependencies to display_name field
The previous commit introduced an optimization to reduce the number of
queries and fields fetched when we call `name_search`. But it works much
better when the dependencies of `display_name` contain field names used
in the calculation (on the same record/model).

Then, to improve the performance and the cache coherency, add `depends`
and `depends_context` depending on the custom `_compute_display_name`.
Add only the first level of dependencies (never traverse relational
field) because only these have a positive impact on the previous
optimization and the cost is very low (see `modified`).
About `depends_context`, we don't include `lang` because (when `_` is
used by example) it is unlikely to get the same display_name in the same
request with two different lang.

closes odoo/odoo#122085

Related: odoo/documentation#4639
Related: odoo/enterprise#42599
Related: odoo/upgrade#4780
Signed-off-by: Raphael Collet <rco@odoo.com>
2023-06-28 17:41:19 +02:00
Rémy Voet (ryv) 3c62ca1eb9 [REM] core: remove name_get API
Rationale
=========

Since v8, the `display_name` field is present on all models. By default,
`display_name` uses `name_get` which has pretty much the same purpose
(return record name used by the web client). Gradually, many (backend)
developers (and the ORM: https://github.com/odoo/odoo/commit/6da1c3ac4c036eac289597602976538e243cb939)
started using `display_name` (more convenient than
`record.name_get()[0][1]`) but it still had the `name_get` override.
It becomes more complex than necessary and poeple start to misunderstand
the two (and sometimes override both, leading to inconstiencies between
`display_name`/`name_get`).

To simplify the ORM and the API, we decided to keep only one of them,
the `display_name` field:
- It is much more convenient from a backend point of view
(`record.name_get()[0][1]` vs `record.display_name`)
- It is cached during the same transaction (and invalidated if
its dependencies change)
- It can be overridden like any other compute field (override
`_compute_display_name` with any extra dependencies)
- `name_get` is replaced by `read(['display_name'])`
(API perceptive), which can actually be more efficient
(if `display_name`'s depends are correct, the ORM will only fetch the
fields it needs instead of every prefetchable field)

Changes
=======

- Deprecates `name_get` for the v17 and based the method on
`display_name` (the opposite of before)
- Converts all usage of `name_get`
- Overrides of `name_get` are now overrides of `_compute_display_name`
- For `res.partner`, rename the field store `display_name` into
`complete_name` because `display_name` context-dependent and it makes
no sense to have a compute store that is context-dependent.
- Previously, it was possible to return multiple names for the same
record with `name_get`, but it was tricky and most of the usage of
this `name_get` didn't take this into account. The only example of
this is the `name_get` of `product.product`
(now use `", ".join(<names>)`).

Part-of: odoo/odoo#122085
2023-06-28 17:41:19 +02:00
Jurgen (jugj) 4f3e1af489 [IMP] hr: Increase usability of the plans
This PR makes the following changes :
- In the demo data, add a fleet manager to the vehicle linked to Marc Demo & add a domain to that field to only list users from the selected company(ies)
- On the Launch Plan window change the dropdownlist for a radiobutton widget
- Remove the quick create and quick edit option on the launch plan screen
- Add a due date on the launch plan screen, the activities will be created on launch plan and the due date will be the one selected in the field
- On the activity type, hide the Schedule field if no value are defined on the previous field (suggest/trigger)
task-3337922

closes odoo/odoo#122298

Signed-off-by: Kevin Baptiste <kba@odoo.com>
2023-06-15 10:45:06 +02:00
Yannick Tivisse 1191b5733f [IMP] hr: Improve trial onboarding
PURPOSE
=======

When you start a new trial of an app without demo data, you
want to have everything perfect and ready for your own configuration

closes odoo/odoo#122308

Taskid: 3328654
Related: odoo/enterprise#41423
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2023-06-06 16:22:45 +02:00
Martin Trigaux 2afdda2576 [I18N] *: export saas-16.3 source terms
closes odoo/odoo#123046

X-original-commit: 137f5ca0cb703ee953cb01db525362f7a778e6bd
Related: odoo/enterprise#41703
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-06-01 11:43:51 +02:00
stcc-odoo c1690d3cd1 [FIX] fleet: select vehicle model on mobile
Steps to reproduce:

- Install fleet
- Switch to mobile view
- Create new vehicle
- Click on model field > Select a model

Issue:

Clicking on a car model does not perform any action.

Solution:

Add class `oe_kanban_global_click` to kanban items in order to capture user clicks.

opw-3188104

closes odoo/odoo#122567

X-original-commit: 7b56586f256461d19a4c8999d7dab05a6e33b1e2
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: Stefan-Calin Crainiciuc (stcc) <stcc@odoo.com>
2023-05-26 11:40:49 +02:00
Louis Wicket (wil) 04189318cc [I18N] *: update master translations
Currently, only stable releases see their translations updated. This has
resulted in master accumulating outdated stuff for years, which can be
confusing for users testing master on runbot.

This one-shot commit resynchronizes master translations based on the
content from 16.0 and removes empty PO files (i.e. no longer containing
translations).

closes odoo/odoo#121629

Related: odoo/enterprise#41171
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-05-22 17:52:07 +02:00
Brieuc-brd fa60bac197 [IMP] *: app icons : add viewBox attribute
Prior to this commit, the SVG's viewBox attribute was missing, which
prevented svgs from being scaled.

This commit fixes this issue.

task-3326633
Part of task-3326263

X-original-commit: 30300c373ad1c63a6cf8b035cae0785a09c6933f
Part-of: odoo/odoo#121886
2023-05-22 13:54:08 +02:00
Brieuc-brd ee75969979 [IMP] *: app icons: replace svg to png
The introduction of Milk has brought new app icons.
Using the svg format creates a lack of anti-aliasing on the edges of the
shapes, which makes the icons look bad.
Since the png size has been reduced, we can afford to use the png format
to have the best possible quality without having a lack of performance.

task-3326633
Part of task-3326263

X-original-commit: e07cb722f2b11407a3ad093bd688b7d37afd5a88
Part-of: odoo/odoo#121886
2023-05-22 13:54:07 +02:00
Martin Trigaux 077bbd0b0b [I18N] *: export master source terms
closes odoo/odoo#121563

Related: odoo/enterprise#41140
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-05-17 10:34:00 +02:00
Elisabeth Dickinson b2ef35a431 [IMP] *: replace .bg-color by .text-bg-color on ribbons
Also remove unnecessary CSS on ribbons.

Part-of: odoo/odoo#116641
2023-05-12 22:59:16 +02:00
Brieuc-brdandElisabeth Dickinson 21d87a3da5 [REF] *: milk graphical assets
- apps icons
- base: replace demo avatars Mitchell, Marc and Joel
- mail: replace odoobot avatar

Part-of: odoo/odoo#116641
Co-authored-by: Elisabeth Dickinson <edi@odoo.com>
2023-05-12 22:59:14 +02:00
Jurgen (jugj) ceba69f3ed [IMP] (l10n_be_hr_payroll)_fleet : Improve the visual of fleet contracts
task - 3247012

closes odoo/odoo#120865

X-original-commit: 88cc0f78dd9f7f7f8d0c29c54ca4ffbd8a9a0911
Related: odoo/enterprise#40829
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2023-05-09 11:57:44 +02:00
Alexandre Kühn 9f115fce17 [FIX] mail,*: fix style in 1st column of activity view
Task-3290752

closes odoo/odoo#120189

X-original-commit: a97c86a2b962f56955e3c16b7ad99cabb0b13b9c
Related: odoo/enterprise#40564
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-05-03 17:24:58 +02:00
Rémy Voet (ryv) 302c7baa87 [REM] core,*: remove name_get_uid parameter from _name_search.
`name_get_uid` is unused (at least since v14) and the
documentation about it, is wrong.

closes odoo/odoo#117819

Related: odoo/enterprise#39483
Signed-off-by: Rémy Voet <ryv@odoo.com>
2023-04-28 16:04:27 +02:00
Bruno Boi f22961ad07 [FIX] web,*: repair root class attr
*: web + adaptations in base, fleet, hr, hr_expense, hr_recruitment,
   loyalty, lunch, mail, mass_mailing, note, project, stock, survey,
   web_tour

**Foreword**
Since d19037e141 the rootnode class attribute for form/list views was
copied two times:
- on the o_view_controller div
- and on the root node of the view renderer.

Examples:

<form class="foo">...</form>

    gives

<div class="o_view_controller o_form_view foo">
    <div class="o_control_panel">...</div>
    <div class="o_content">
        <div class="foo o_form_editable ...">...</div>
    </div>
</div>

and

<list class="foo">...</list>

    gives

<div class="o_view_controller o_list_view foo">
    <div class="o_control_panel">...</div>
    <div class="o_content">
        <div class="o_list_renderer foo ...">...</div>
    </div>
</div>

**Issue**
This could lead to confusion and also unexpected styling issues.
See this PR #119815 to read a message JS Framework team has received.
See also another a fix that had to be made for x2m fields: 980244fa8

**Introduced Changes**
- in the form compiler, the root node attributes are no more copied to
  the root div node of the compiled template the form renderer receives
- the root div node generated by the form compiler now has the
  "o_form_renderer" class, which was removed during the recent form view
  refactoring.
- the list renderer no more adds the root node class attribute to its
  "o_list_renderer" div
- the X2ManyFieldDialog has been adapted too
- since View, X2ManyField & X2ManyFieldDialog both need to compute view
  classnames derivated from the arch root node, an util has been
  introduced to avoid duplicating code
- the whole codebase has been checked and adapted.

Related: odoo/enterprise#40418
Signed-off-by: Mathieu Duckerts-Antoine <dam@odoo.com>
2023-04-27 16:10:30 +02:00
Rémy Voet (ryv) 234db70d86 [IMP] *: Use the new API of _read_group for backend use
Part-of: odoo/odoo#110737
2023-04-19 21:58:27 +02:00
Rémy Voet (ryv) 603c16b1a0 [FIX] core,fleet: remove group_operator for Many2oneReference
The default `group_operator` of `Many2oneReference` is 'sum' (inherited
from the parent class `Integer`), it doesn't make any functional sense
to sum ids.

Also set group_operator to None on `co2` instead of override read_group
for the same result.

Part-of: odoo/odoo#110737
2023-04-19 21:58:26 +02:00
Jurgen (jugj) 1902beb621 [IMP] fleet : Add default contract types for vehicles and expand name_search to manufacturer name
This PR :
- Adds 2 new default contract types to the data : Omnium and Leasing
- Lets the user search models by manufacturer name and model name

task - 3249291

closes odoo/odoo#117059

Signed-off-by: Kevin Baptiste <kba@odoo.com>
2023-04-19 12:13:30 +02:00
Julien Carion (juca) 1f6c655cbc [IMP] web, *: Add lazy loading for images in kanban
This commit adds the loading="lazy" attribute to every img tags compiled
by the kanban compiler and modifies some kanban archs in order to use
img tags instead of divs with background-image style to load images
(this allows again the loading="lazy" attribute to work).
The purpose is to avoid loading images that are outside the user viewport
at all time in order to reduce the load on the network when new images are
loaded.
Steps to test: find all views that are using the o_kanban_image or o_kanban_image_fill_left
class and ensure all the images in these views appear in the network tab of devtools
when they enter the user viewport. Example: res.partners, hr.employee, ...

task-3102207

closes odoo/odoo#117049

Related: odoo/enterprise#39560
Signed-off-by: Géry Debongnie <ged@odoo.com>
2023-04-14 15:05:56 +02:00
dasz d832fcf0ce [IMP] hr_*: standardise UI displaying of employees accross all hr apps by using the widget avatar_user
Appraisal: done, fix  chat widget issue
Employee: done, removed unused view
Attendance: done
Expense: done
Time Off: done
Fleet: done
Payroll: done
Referall: done
Lunch: done

task-313272

closes odoo/odoo#111817

Related: odoo/enterprise#36663
Related: odoo/upgrade#4310
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2023-04-13 15:25:46 +02:00
niyasraphy f4fab2d10c [FIX] fleet: missing avatar image for model and vehicle field
before this commit, in the list view of
fleet (fleet.vehicle),
services (fleet.vehicle.log.services) and
odometer(fleet.vehicle.odometer) the vehicle_id
and model_id field with many2one_avatar is
not showing the image of vehicle and model.

* open fleet -> fleet -> fleet
* switch to list view
* model field will be with empty image
* similarly in services and odometer menus

after this commit, the widget will be removed
from the field as the avatar field doesn't
exists in the model level.

closes odoo/odoo#117752

X-original-commit: e57b6f898775a0e432ae1a21266a0f4bf82c0242
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2023-04-05 10:45:57 +02:00
Louis Wicket (wil) 0c53d28133 [IMP] *: remove "French spacing"
According to Wiktionary, French spacing is "the archaic practice (though
still current in French) of inserting a space around colons, semicolons,
question marks, and exclamation marks". This is not standard practice in
English and most languages of the world.

The purpose of this commit is to start purging the code from this typo,
as it may reflect poorly on the software for some people.

closes odoo/odoo#116167

Related: odoo/enterprise#38542
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-03-24 12:50:13 +01:00