Commit Graph
1377 Commits
Author SHA1 Message Date
Bruno Boi 78ac086539 [REF] web,*: raw_value as ISO8601 in kanban templates
This commit will make date(time) raw_value an ISO string
instead of a native JS Date.

- Before this commit
In kanban templates:
  - the raw_value property of a record's date/datetime field is
    a native JS Date object.

The problem with raw_value is that JS Dates toString
method depends on the system locale and timezone.
In the code base, the usage of raw_value for date/datetime fields
usually parse the raw_value into a luxon DateTime object
in order generally to display it in a specific format, or in order
to compare it to another luxon DateTime object (e.g. the now instant).

- After this commit
The raw_value property of a record's date/datetime field
has become an ISO8601 string, instead of native JSDate toString
format (which I recall depends on system's locale and timezone).
The ISO8601 format is easier to work with.

Part-of: odoo/odoo#98980
2022-09-01 17:10:59 +02:00
Raphael Collet b38a5f78b6 [FIX] *: avoid non-searchable field dependencies
closes odoo/odoo#98562

Related: odoo/enterprise#30639
Signed-off-by: Raphael Collet <rco@odoo.com>
2022-08-29 22:43:11 +02:00
Denis Ledoux 8b91cab67f [IMP] base: remove groups_id from ir.ui.view
The goal of this revision is to get rid of the `groups_id` field of the model `ir.ui.view`.

- This feature wasn't really known or used by most developers,
   and not straight-forward to understand.
   Removing it allows one less complicated thing to learn for developers.
   Besides, thanks to odoo/odoo#95729,
   changing the behavior of the `groups=` attribute,
   we can easily get rid of this `groups_id` feature
   by simply adding `groups=` in the elements of the views
   using the `groups_id` field, it will have the same effect:
   adding the elements in the view only for the users part of the specified group.

- By getting rid of the groups_id many2many field on ir.ui.view,
   it makes possible to cache the view architecture without
   requiring to use the groups in the cache key.
   Currently, if we want to cache the view architecture,
  it would be required to use the intersection of the user
  groups with the groups_id groups of the view,
  making it costly to compute the cache key,
  therefore altering the performance point to cache the view
  architectures.

Part-of: odoo/odoo#98551
2022-08-29 22:42:50 +02:00
Thibault Delavallée d13d251a2f [MOV] various: move and split mail data
Just doing the summer file cleaning. Move mail data into files named based on
their model, easing maintenance and searching for those data.

Spotted during Task-2207626 (Rating: Delay rating notification to ease feedback)

Part-of: odoo/odoo#98661
2022-08-25 10:31:56 +02:00
Denis Ledoux 0501bbd62e [IMP] base: uniform "groups" in back-end view
This revision is to make uniform the behavior of the `groups` attribute
on the Python model fields
and on the node in the view architecture.
In both cases, remove the node from the view completely.

Before this revision,

in a back-end view:
 - In the Python model, if a field has the `groups` attribute set
   and the user is not part of
   the groups, the field is removed, completely, from the view.
 - In the view architecture, if a node has the `groups` attribute set
   and the user is not part of
   the groups, the node is made invisible (not completely removed, just
   made invisible).

in a front-end view:
 - if a node has a "groups" or "t-groups" set and the user
   is not part of the groups, the node is removed from the view.

So it's 2/3 cases removing nodes restricted to a group.
and 1/3 case making invisible nodes restricted to a group.
It's simpler to have a uniform behavior for the 3 cases,
simpler to understandard for developers.

In addition, this will help for the goal to cache back-end views.
It makes possible to convert views using the `groups_id` field
by moving the content of these views directly
in the view to which they add content which is suppose to be completely
removed when the user has not the according group.
By getting rid of the `groups_id` many2many field on `ir.ui.view`,
it makes possible to cache the view architecture without
requiring to use the groups in the cache key.
Currently, if we want to cache the view architecture,
it would be required to use the intersection of the user
groups with the `groups_id` groups of the view,
making it costly to compute the cache key,
therefore altering the performance point to cache the view
architectures.

closes odoo/odoo#95729

Related: odoo/enterprise#29592
Signed-off-by: Denis Ledoux (dle) <dle@odoo.com>
2022-08-19 19:10:39 +02:00
Romain Derie a462d87c4b [FIX] *: set correct type on html field in xml created records
When a record is created through xml data, its HTML fields should
receive a `type="html"` attribute, not a `type="xml"` attribute.

When important XML data with XML type instead of HTML type will have 2
differences:
- The field value will be prefixed by `<?xml version="1.0"/>`
- If the HTML contains multiple root nodes, the value will be wrapped in
  a `<data/>` tag.

See `_fix_multiple_roots()` and the `xml_import` class for more details.

closes odoo/odoo#98239

Related: odoo/enterprise#30491
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2022-08-19 11:52:49 +02:00
Yannick Tivisse 61c9f6aec0 [IMP] (hr_)fleet: Improve vehicle search view
Purpose
=======

Avoid having too many search for, lead the end user to use the main one.

closes odoo/odoo#98096

Taskid: 2937036
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2022-08-16 08:07:13 +02:00
Martin Trigaux b821961236 [I18N] *: sync fr_BE translation terms
Only for terms containing Credit Note and expenses

closes odoo/odoo#97840

X-original-commit: 1754b094a66476a0bdb29fe60dc5583c03336c3f
Related: odoo/enterprise#30262
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2022-08-10 03:11:53 +02:00
Michael (mcm) df966f5fde [IMP] web,fleet: convert FleetFormController
This commit converts FleetFormController with the new FormController

closes odoo/odoo#96781

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-08-03 02:26:39 +02:00
Fabien Pinckaers 3363e55cac [IMP] cleanup of help messages in all modules
This commit aims at removing unuseful help message to:
1/ reduce translators work, to focus on more useful translations
2/ not sending unuseful information in load_views
3/ reduce help message to useful messages, so that we can mark
   fields having a tooltip in the future UI.
4/ some cleanup of existing messages too

The main use cases:
- REMOVED: help redundant with the field name, providing no extra info
- MOVED TO COMMENT: technical help messages, that should not be in UX

closes odoo/odoo#97279

Signed-off-by: Fabien Pinckaers <fp@odoo.com>
2022-08-02 00:26:53 +02:00
Kevin Baptiste 9c6f20a853 [FIX] fleet: properly archive Contract/Services
When archiving a vehicle, the active state of its Contracts/Services
were toggled, which was confusing (an archived Contract would suddently
become unarchived on an archived vehicle).

Now we only archive the Contracts/Services when the Vehicle is archived,
and no unarchiving is done.

task-2898104

closes odoo/odoo#95650

X-original-commit: 0be40d67c28b8575613f59ca5b4d8d6ea99638cb
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-07-08 14:34:30 +02: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
Victor Feyens fba6ea5a47 [IMP] *: do not force admins to be app admins
For bugfix purposes, app administration groups have been given to
(implied by) the "Settings" group because without those rights,
opening/saving the settings crashed.

1) Do not load hidden view content

This commit uses the conditional inheritance of views
(depending on user groups) to avoid loading unnecessary view
& record content client-side.

This improves performance for admins without the specific application
admin rights, but also fixes the main bugfix problem,
caused by the webclient querying name_get for the records in relational
fields content.

Example:

sale_management adds a res.config.settings field to specify
the default sale.order.template for the current company.

If a 'Settings' user without 'sale.group_sale_manager' opens the
settings, he won't see this setting, but if a default template is
specified for the current company, the webclient will still request
the name_get of this template to the server, because the field
was present in the view, only hidden with a groups attribute.

With this commit change in sale, the field won't be in the view unless
you have the Sale manager group, avoiding the error/traceback/bug.

2) Remove implied application administration groups

Do not force the specific application groups on all 'Settings' user,
they globally do not need those rights, and if they need it, they
can add it to their account themselves.

3) Add a test to make sure settings user are able to manage settings.

4) Enforce 'settings' -> 'access rights' -> 'internal user' groups

As the previous test highlighted some 'false positives' because
it considered a settings user unable to read `crm.team`
and `stock.warehouse` records, we also took the opportunity to enforce
the fact that 'Settings' & 'Access rights' users must be internal users.

It makes no sense for a portal/public user to have access to the
settings, and didn't work anyway.

Part-of: odoo/odoo#91909
2022-06-23 23:48:29 +02:00
Kevin Baptiste 45b175a18d [IMP] (hr_)fleet: usability changes (b2b)
Minor usability changes:

  * Reorganize menu to be more consistent with other HR apps;
  * Tweak several views;
  * Don't expire contract when date is set to Today - they will be
    automatically expired the next day;
  * Show contract name on form view.

closes odoo/odoo#92604

Related: odoo/enterprise#27919
Taskid: 2856135
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-06-23 17:16:57 +02:00
Yannick Tivisse a7b84cb8ef [IMP] fleet: Add default CO2 on fleet vehicle model
Taskid: 2881009
Part-of: odoo/odoo#93684
2022-06-16 11:25:01 +02:00
Martin Trigaux 5acb6db891 [I18N] *: export saas-15.4 source terms
closes odoo/odoo#93246

X-original-commit: 5ff6d185f70650c26c28a6aef7dd37c859ab58d2
Related: odoo/enterprise#28218
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2022-06-10 07:27:26 +02:00
Géry Debongnie 8313a66a52 [REF] *: remove some kanbanrecord .includes
The kanban view was recently improved to add the support of 'action' and
'type' attributes on the kanban arch.  This commit takes advantage of
that change to simplify a few views in various addons.

Part-of: odoo/odoo#92071
2022-05-25 20:31:41 +02:00
Leonardo Pavan Rocha 5dba452227 [IMP] fleet, hr_fleet: improve assignment logs view
Assignment logs list view can be accessed both from fleet and from hr_fleet,
however they show many repeating fields and, for this reason, this commit
improves these views by leaving the repeating fields as optional="hide".

task-2742923

Part-of: odoo/odoo#83755
2022-05-24 15:59:56 +02:00
Kevin Baptiste 7061bacf6a [IMP] fleet: count archived services on vehicle
When a vehicle is archived, its corresponding services/contracts are archived
as well. However, the corresponding records were no longer counted for
the stat buttons.

closes odoo/odoo#90406

Taskid: 2841384
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-05-12 13:42:43 +02:00
Dossogne Bertrand a63a271768 [FIX] fleet: fix fuel types
There shouldn't be a distinction between full hybrids.
'hybrid' and 'full_hybrid_gasoline' are replaced in this commit by a unique 'full_hybrid'.
fixes task 2629318

taskID 2753096

closes odoo/odoo#90413

Related: odoo/enterprise#26886
Related: odoo/upgrade#3494
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-05-12 09:19:04 +02:00
sofiagvaladze 0476f084a1 [IMP] fleet: add category_id to the vehicle from model
category_id field is populated from the model, but it can be edited.

task - 2828459

closes odoo/odoo#89282

Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-05-11 19:46:00 +02:00
Dossogne Bertrand 605a3c1e44 [IMP] hr_*: uniformize group category
*:
approvals
hr_apprasaisal
hr_payroll
hr_referral
fleet
hr
hr_attendance
hr_holidays
hr_recruitment
lunch

Change various access rights names to improve understandability for users.
Addition of an officer role in fleet with intermediate accesses

TaskID 2742855

closes odoo/odoo#87545

Related: odoo/enterprise#25741
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-05-03 14:38:19 +02:00
Victor Feyens c3b9c0d8a2 [FIX] *: typos in translated strings
closes odoo/odoo#89718

Related: odoo/enterprise#26630
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-05-02 21:36:40 +02:00
Kevin Baptiste 1078226f9f [IMP] fleet: add tracking on fields
closes odoo/odoo#89102

Taskid: 2826804
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-04-22 09:03:04 +02:00
william 3155c3e425 [IMP] core,*: add helper for name_search
Most of the extensions of `_name_get` are very similar and only want to
search for the given string in multiple fields.
A lot of extensions also don't take into account the negative operators.
Some implementations were also really outdated and needlessly
complicated.

closes odoo/odoo#86588

Related: odoo/enterprise#25608
Signed-off-by: Raphael Collet <rco@odoo.com>
2022-04-06 18:37:39 +02:00
Yannick Tivisse 62f72d1819 [FIX] fleet: Compute counts using read_group
Divides by 2 the kanban view loading on odoo.com

X-original-commit: 5fa89995f010964e3d5d5a1417b23965735136e9
2022-03-30 17:04:50 +02:00
Vincent Schippefilt 05fc9a6733 [IMP] *: use _read_group instead of read_group
This commit modifies most of the usages of read_group and uses
_read_group instead. _read_group doesn't join automatically on the
many2one fields when no order_by is specified, making it more performant
when the "name" of the many2one is not relevant, which is the case for
most back-end cases

closes odoo/odoo#84908

Task-id: 2479334
Related: odoo/enterprise#24877
Signed-off-by: Raphael Collet <rco@odoo.com>
2022-03-02 17:10:48 +00:00
Thibault Francois 4340a7e4d2 [FIX] fleet: fix search method for contract_renewal*
the search method of contract_renewal_due_soon and
contract_renewal_overdue return a domain
id in res_ids where res_ids are id of contract
not vehicle

So it return random result

Solution
--------
Get the vehicle_id from the contract record set

closes odoo/odoo#84987

X-original-commit: 975841953adaa6b7adc8016fb96cc6efc8891613
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-02-21 13:13:52 +00:00
Fabien Pinckaers 10a5796d4b [IMP] speed up load_menus() by using SVG icons instead of png
Reduces load_menus answer size by 32% (between 20kb and 200kb savings
for the initial loading of the backend, depending on the number of apps
installed). Support for SVG icons in the web client for menus/apps.

Reduced PNG icons for apps list (8 bits PNG instead of 24 as our icons
don't need more colors as they are flat designs)

closes odoo/odoo#84280

Related: odoo/enterprise#24200
Signed-off-by: Fabien Pinckaers <fp@odoo.com>
2022-02-12 08:55:18 +00:00
William Braeckman 556c1237a2 [IMP] fleet: reorder/reword fuel types
There was some confusion about all the types of hybrid vehicles.
Also changes the order in which they are displayed.

TaskId-2629318

closes odoo/odoo#82672

X-original-commit: 73171da60059c85355e8675061db485e84aedb05
Related: odoo/enterprise#23460
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2022-01-13 09:30:56 +00:00
Kevin Baptiste a7754e77a9 [FIX] fleet: fleet cost report
Steps to reproduce:
- Install Fleet
- Go on report-cost
- Click on a specifi vehicles
-> The cost associated are not correct

Solution:
Correction of the SQL-query which was not correct (id not unique)

closes odoo/odoo#81688

X-original-commit: e06114b3b7e188d8ce293f77d8395592193eb83d
Signed-off-by: yosa-odoo <yosa@odoo.com>
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-01-03 12:33:54 +00:00
Florian Damhaut c81d5607dc [FIX] hr_fleet: no duplicate contract renewal activity reminder
Step to reproduce:
- Have a fleet contract that need renewal

Current Behaviour:
- A new activity is created everytime the scheduler is called

Behaviour after PR:
- A new activity is only created if there is no current renewal activity present when the scheduler is called

opw-2713537

closes odoo/odoo#81919

X-original-commit: 3610069ea2c10fccf8fcc82c384a2194c4702e06
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Damhaut Florian (flda) <flda@odoo.com>
2021-12-28 08:07:47 +00:00
Kevin Baptiste 3acd3a08f7 [FIX] fleet: fix missing compute method
The PR #75475 removed the method `_compute_manager_id` without removing
the reference in the field.

closes odoo/odoo#81766

X-original-commit: a4e1477d120c336ace405421ddb860a72cfeafe1
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2021-12-22 07:50:51 +00:00
Yannick TivisseandVictor Feyens 18952cdc76 [IMP] *: Convert single create method into multi
Taskid: 2703085
Part-of: odoo/odoo#80824
Co-authored-by: Victor Feyens <vfe@odoo.com>
2021-12-14 19:13:18 +00:00
Martin Trigaux d99cfd9416 [I18N] *: export saas-15.1 source terms
closes odoo/odoo#80964

X-original-commit: 0663892a34896980008eb0de69aeb58019a67e89
Related: odoo/enterprise#22759
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-12-07 13:48:53 +00:00
Yannick Tivisse 6a7c1c51ce Revert "[FIX] hr_fleet: Don't notify future_driver_id as Changed Driver"
This reverts commit 2e58d23e760313dbf58ce6a90f26b7160db460d8.

Actually the fleet officers want to be notified.

The correct way to handle the original issue is to ping the employees
via their documents, instead of on the fleet.vehicle, to avoid setting
them as followers of the car.

closes odoo/odoo#78716

X-original-commit: 437bd8cc54d999a40ee2d83e2fef9c0ced19f47e
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-10-28 12:21:19 +00:00
Kevin Baptiste c715ecb38b [IMP] fleet: add Write Off Date on vehicle
Add the Write Off Date on vehicle.

closes odoo/odoo#77464

Related: odoo/enterprise#21299
Related: odoo/upgrade#2878
Taskid: 2657561
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2021-10-19 07:12:04 +00:00
Kevin Baptiste 67a07865d1 [IMP] (hr_)fleet: improve Claim Car Report
The "Claim Car Report" action was not working as expected.
Now the statbutton "Cars" will show the car history of a specific
driver.

closes odoo/odoo#76550

Related: odoo/upgrade#2882
Taskid: 2646113
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2021-10-04 11:29:55 +00:00
Philippe Wauthy 52e9668e99 [FIX] fleet: clean service type demo data
Description of the issue/feature this PR addresses:
In fleet, the demo data for service type have two entries for summer tires
The service types are sorted by alphabetical orders instead of id

Current behavior before PR:
The summer tires service type is appearing twice in the demo data
The service types are sorted by id

Desired behavior after PR is merged:
The summer tires service type is unique in the list
The services types are sorted by alphabetical order

task-2641484

closes odoo/odoo#76403

Signed-off-by: Kevin Baptiste <kba@odoo.com>
2021-09-21 08:08:47 +00:00
Martin Trigaux ef8ad324b0 [I18N] *: export 15.0 source terms
closes odoo/odoo#76542

X-original-commit: 63e6807437295519a0f4705fb88644d6d557ca3a
Related: odoo/enterprise#20882
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-09-16 07:17:40 +00:00
Mathieu Duckerts-Antoine 7545913020 [REF] *: graph archs cleaning
We clean various graph archs taking into consideration that:
 - the default type of a graph is "bar".
 - a bar chart is by default stacked.
 - the field attributes type="row" and type="col" does not make sense for
   a graph view (since its implementation was separated from the pivot
   implementation a long time ago))
 - the boolean attributes should now take 1 or 0 as value (but the other
   values are accepted for retrocompatibility).

Part-of: odoo/odoo#76065
2021-09-07 15:50:14 +00:00
Yannick Tivisse 24713b76b5 [REV] fleet: Revert multiple fleet mechanism
I don't get why you don't get it...

Partial revert of the taskID: 2415309
Com PR: https://github.com/odoo/odoo/pull/70313
Ent PR: https://github.com/odoo/enterprise/pull/18114
Upg PR: https://github.com/odoo/upgrade/pull/2447

closes odoo/odoo#75475

Related: odoo/enterprise#20406
Related: odoo/upgrade#2765
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-08-25 12:20:39 +00:00
Martin Trigaux d9e3aab69b [FIX] mail: convert res_model_id to selection
Following the removal of read access on ir.model (odoo/odoo#69120),
the mail.activity.type model was not accessible to non-admin users due
to the res_model_id many2one field.

Before this commit, a project user could not access the Activity Type
menu.

Convert it to a selection field with the selection values being
computed in sudo.

closes odoo/odoo#74981

Related: odoo/enterprise#20214
Related: odoo/upgrade#2734
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-08-23 06:56:00 +00:00
prro-odoo 5c4a971d89 [FIX] fleet: display only current companies' fleet
How to reproduce the problem:
- Install the Fleet app.
- Create a user that has access to 2 or more companies (e.g. Mitchell Admin).
- Log in as this user. Go to fleet -> Vehicles -> Vehicles Costs/Contracts/Fuel Logs/Services Logs
- Uncheck one of your companies.
- The user still has access to the fleet of the other companies, even if they are unchecked.

Cause of the problem : missing record rules

Solution : added multi-companies rules

opw-2518188

closes odoo/odoo#73925

X-original-commit: 41828bc22b5cf663b96196371f412ad2bfbbfb22
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-08-17 07:25:48 +00:00
Anjali 7c5bfb42d4 [IMP] various: add list views for some important reporting models
Currently, there are many useful pivot views on reporting models but most
of them lacks the dedicated list view. Dedicated list views will allow users
to see useful information when one directly drill down to the records from
the pivot table in odoo spreadsheet [1].

With this commit

  1. we remove 'disabled_linking' attribute from the very important pivot
     and graph views (see the full list on task pad);
  2. we added dedicated list views for the following reporting models

    - account.invoice.report
    - fleet.vehicle.cost.report
    - hr.timesheet.attendance.report
    - purchase.report
    - project.profitability.report
    - report.membership
    - report.pos.order
    - report.project.task.user
    - sale.report

Task-2547881

[1] See task-2506116

closes odoo/odoo#72394

Related: odoo/enterprise#19122
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-07-29 09:33:56 +00:00
Adrien Widart b97d360ade [FIX] fleet: always include current month in costs report
When consulting the costs reports, if the beginning of the dates range
has a day greater than the day of today (e.g., start date: 2021/02/25,
today: 2021/07/10 => 25 > 10), the costs of the current month won't be
include in the report.

To reproduce the issue:
(DB without any demo data. Let X be the day of the month for today)
1. Create a vehicle V
2. Add a service S1 for V
    - The category of the service type does not matter
    - Cost: 500
    - Date: today
3. Add a second service S2 for V
    - Same service type
    - Cost: 250
    - Date: Last month with a day > X (so if today is 2021/07/26, date
could be 2021/06/27)
4. Fleet > Reporting > Costs

Error: The report does not include S1

When generating the dates range, the current date is used as the end of
the interval. Since the interval step is '1 month', it will lead to an
issue in the above case:
Suppose today is 2021/07/26, the interval starts on 2021/06/27. Then, if
we add one month to this date, we have 2021/07/27, which is after the
end of the interval (2021/07/26), so the date is ignored. As a result,
current month won't be included in the report.

Note: A similar issue can happen with the contracts

OPW-2477004

closes odoo/odoo#74273

X-original-commit: 7ea6300f951bd426c94d721bb56e6ad85a58bd30
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2021-07-26 17:03:06 +00:00
Adrien Widart 5c10ffe284 [FIX] fleet: use services dates in report start date computation
When adding some services to a vehicle that does not have any
immatriculation date, the costs report does not consider these services.

To reproduce the error:
(DB without any demo data)
1. Create a vehicle V
    - Remove the Immatriculation Date
2. Add a service for V
    - The category of the service type does not matter
    - Cost > 0
    - Date: today
3. Fleet > Reporting > Costs

Error: Costs Analysis is empty, the service is not considered

In the SQL view, the date used as start point is the oldest
immatriculation date. Therefore, if the vehicle doesn't have this date,
the report lines won't be generated.

OPW-2477004

X-original-commit: 8d362af654c1905535d78fbf8d73677633b65d63
2021-07-26 17:03:04 +00:00
Xavier-Do 288595f558 [FIX] *: add explicit license to all manifest
The license is missing in most enterprise manifest so
the decision was taken to make it explicit in all cases.
When not defined, a warning will be triggered starting from
14.0 when falling back on the default LGPL-3.

closes odoo/odoo#74245

Related: odoo/design-themes#48
Related: odoo/enterprise#19862
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2021-07-26 13:09:57 +00:00
Munaf Khan df59f75966 [IMP] fleet,website: avoid duplicate menu items
Currently, some business object related menus have the
same names with the technical menus and it creates
confusion among users.

This commit renames the following menus:

 - in fleet app, 'Models' menu is renamed to 'Vehicle Models'
 - in website app, 'Views' menu is renamed to 'Page Views'

Apart from that, to be consistent with menu item, this commit
also renames the action 'website_visitor_view_action' from
'Views' to 'Page Views'.

TaskId-2595993

closes odoo/odoo#73755

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-07-19 09:43:13 +00:00
William Braeckman c80002f660 [IMP] fleet: Improve general UX (Back2basics)
Overall UI review of the fleet app.

Also changes the behaviour of shared fields between vehicles and vehicle
models.

Task ID: 2468228

closes odoo/odoo#72943

Related: odoo/upgrade#2601
Related: odoo/enterprise#19356
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-07-14 14:40:54 +00:00